[PATCH] OSS: Use ARRAY_SIZE macro when appropriate (2)
[sfrench/cifs-2.6.git] / sound / oss / au1550_ac97.c
index 219795171c714796df5aaa51f740abd75fad7116..a339f0c0d5129323068a89831adb19fcbefa38cc 100644 (file)
@@ -1354,11 +1354,11 @@ au1550_ioctl(struct inode *inode, struct file *file, unsigned int cmd,
                ((file->f_mode & FMODE_READ) && s->dma_adc.mapped);
 
 #ifdef DEBUG
-       for (count=0; count<sizeof(ioctl_str)/sizeof(ioctl_str[0]); count++) {
+       for (count = 0; count < ARRAY_SIZE(ioctl_str); count++) {
                if (ioctl_str[count].cmd == cmd)
                        break;
        }
-       if (count < sizeof(ioctl_str) / sizeof(ioctl_str[0]))
+       if (count < ARRAY_SIZE(ioctl_str))
                pr_debug("ioctl %s, arg=0x%lxn", ioctl_str[count].str, arg);
        else
                pr_debug("ioctl 0x%x unknown, arg=0x%lx\n", cmd, arg);