X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=fs%2Fcompat_ioctl.c;h=d2c38875ab296e45741c5dcf966da56ec51d8f96;hb=c71d48877e6f3d5e3eb22fcaaa612081bce3d089;hp=7c031f00fd798ede5c3edf885c7d8a6fef51250b;hpb=aca361c1a0dc0165ac3148137983cb4b1458b5c1;p=linux-2.6 diff --git a/fs/compat_ioctl.c b/fs/compat_ioctl.c index 7c031f00fd..d2c38875ab 100644 --- a/fs/compat_ioctl.c +++ b/fs/compat_ioctl.c @@ -1522,8 +1522,7 @@ static struct { { ATM_QUERYLOOP32, ATM_QUERYLOOP } }; -#define NR_ATM_IOCTL (sizeof(atm_ioctl_map)/sizeof(atm_ioctl_map[0])) - +#define NR_ATM_IOCTL ARRAY_SIZE(atm_ioctl_map) static int do_atm_iobuf(unsigned int fd, unsigned int cmd, unsigned long arg) { @@ -1824,7 +1823,7 @@ static struct { { FDWERRORGET32, FDWERRORGET } }; -#define NR_FD_IOCTL_TRANS (sizeof(fd_ioctl_trans_table)/sizeof(fd_ioctl_trans_table[0])) +#define NR_FD_IOCTL_TRANS ARRAY_SIZE(fd_ioctl_trans_table) static int fd_ioctl_trans(unsigned int fd, unsigned int cmd, unsigned long arg) {