Re: [PATCH v2] fs: O_* bit numbers uniqueness check

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

 



 > Yeah, I chose the boot time check because of hweight32()..

One could do something like

#define HWEIGHT32(x) (!!((x) & (1u <<  0)) +
		      !!((x) & (1u <<  1)) +
//...
		      !!((x) & (1u << 31)));

that would probably work with BUILD_BUG_ON().

But as I said maybe it's too ugly.

 - R.
--
To unsubscribe from this list: send the line "unsubscribe linux-fsdevel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Ext4 Filesystem]     [Union Filesystem]     [Filesystem Testing]     [Ceph Users]     [Ecryptfs]     [AutoFS]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux Cachefs]     [Reiser Filesystem]     [Linux RAID]     [Samba]     [Device Mapper]     [CEPH Development]
  Powered by Linux