Re: [PATCH v2] fs: fix undefined behavior in bit shift for SB_NOUSER

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

 



On Mon, Oct 31, 2022 at 01:53:29PM +0000, Matthew Wilcox wrote:
> On Mon, Oct 31, 2022 at 09:48:11PM +0800, Gaosheng Cui wrote:
> > +++ b/include/linux/fs.h
> > @@ -1384,19 +1384,19 @@ extern int send_sigurg(struct fown_struct *fown);
> >  #define SB_NOATIME	1024	/* Do not update access times. */
> >  #define SB_NODIRATIME	2048	/* Do not update directory access times */
> >  #define SB_SILENT	32768
> 
> Shouldn't those ^^^ also be marked as unsigned?  And it's confusing to
> have the style change halfway through the sequence; can you convert them
> to (1U << n) as well?

I was planning on just sending a followup instead of blowing up the
scope even more, but yes - they should.



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

  Powered by Linux