Messages in this thread | | | Date | Sun, 06 Dec 2009 02:41:29 +0100 | From | Emese Revfy <> | Subject | Re: [PATCH 28/31] Constify struct super_operations for 2.6.32 v1 |
| |
Al Viro wrote: > On Fri, Dec 04, 2009 at 11:47:15PM +0100, Emese Revfy wrote: >> From: Emese Revfy <re.emese@gmail.com> >> >> Constify struct super_operations. > > What the _hell_ is that? > >> + struct inode *(* const alloc_inode)(struct super_block *sb); > > This is ugly and has all marks of cargo-cult patches. NAKed at least > until you give exceptionally good reasons for doing that.
My idea was that since each instance of super_operations is const, I figured that there is an implicit policy of not wanting writable super_operations structures in the kernel. If this is actually the case then my patch makes the compiler enforce this policy, otherwise please ignore it. -- Emese
| |