]> git.proxmox.com Git - grub2.git/commitdiff
unix/getroot: remove unused MAJOR definition
authorAndrei Borzenkov <arvidjaar@gmail.com>
Sat, 7 Nov 2015 14:02:21 +0000 (17:02 +0300)
committerAndrei Borzenkov <arvidjaar@gmail.com>
Sat, 7 Nov 2015 14:02:21 +0000 (17:02 +0300)
We use major() everywhere, these definitions just add to confusion.

grub-core/osdep/unix/getroot.c

index 14d483fb139fc119601052aa99df998eca766fdc..1079a919d112f24a2856f0735a1fdcd097d45c3a 100644 (file)
 #ifdef __linux__
 #include <sys/ioctl.h>         /* ioctl */
 #include <sys/mount.h>
-#ifndef MAJOR
-# ifndef MINORBITS
-#  define MINORBITS    8
-# endif /* ! MINORBITS */
-# define MAJOR(dev)    ((unsigned) ((dev) >> MINORBITS))
-#endif /* ! MAJOR */
 #ifndef FLOPPY_MAJOR
 # define FLOPPY_MAJOR  2
 #endif /* ! FLOPPY_MAJOR */
@@ -73,7 +67,6 @@
 #include <grub/emu/getroot.h>
 
 #if defined(__FreeBSD__) || defined(__FreeBSD_kernel__)
-# define MAJOR(dev) major(dev)
 # define FLOPPY_MAJOR  2
 #endif
 
@@ -90,7 +83,6 @@
 #endif /* defined(__NetBSD__) || defined(__FreeBSD__) || defined(__FreeBSD_kernel__) */
 
 #if defined(__NetBSD__) || defined(__OpenBSD__)
-# define MAJOR(dev) major(dev)
 # ifdef HAVE_GETRAWPARTITION
 #  include <util.h>    /* getrawpartition */
 # endif /* HAVE_GETRAWPARTITION */