[-mm patch] drivers/block/amiflop.c: fix compilation

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



add-block_device_operationsgetgeo-block-device-method.patch causes the 
following compile error:

<--  snip  -->

...
  CC      drivers/block/amiflop.o
drivers/block/amiflop.c: In function `fd_getgeo':
drivers/block/amiflop.c:1431: warning: implicit declaration of function `minor'
...
  LD      .tmp_vmlinux1
...
drivers/built-in.o(.text+0x215cc): In function `fd_getgeo':
: undefined reference to `minor'
make: *** [.tmp_vmlinux1] Error 1

<--  snip  -->


Signed-off-by: Adrian Bunk <[email protected]>

--- linux-2.6.15-mm2-m68k/drivers/block/amiflop.c.old	2006-01-07 18:22:21.000000000 +0100
+++ linux-2.6.15-mm2-m68k/drivers/block/amiflop.c	2006-01-07 18:22:30.000000000 +0100
@@ -1428,7 +1428,7 @@
 
 static int fd_getgeo(struct block_device *bdev, struct hd_geometry *geo)
 {
-	int drive = minor(bdev->bd_dev) & 3;
+	int drive = MINOR(bdev->bd_dev) & 3;
 
 	geo->heads = unit[drive].type->heads;
 	geo->sectors = unit[drive].dtype->sects * unit[drive].type->sect_mult;

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[Index of Archives]     [Kernel Newbies]     [Netfilter]     [Bugtraq]     [Photo]     [Stuff]     [Gimp]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Video 4 Linux]     [Linux for the blind]     [Linux Resources]
  Powered by Linux