Re: [PATCH 14/33] vfs: Implement a filesystem superblock creation/configuration context [ver #11]

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

 



On (09/19/18 10:12), Sergey Senozhatsky wrote:
> On (09/18/18 07:06), Guenter Roeck wrote:
> > > So the check either better be
> > > 
> > > 	if (fc->ops && fc->ops->reconfigure)
> > > 
> > 
> > Since there are multiple instances of fs_context where fc->ops isn't set,
> > this check would be needed wherever fc->ops is dereferenced.
> 
> Right. If fc is always guaranteed to be properly zeroed-out. This is
> true for kzalloc-ed fc's, but not necessarily so in any other case.

What I mean was something like this

	void foo(void)
	{
		struct fs_context fc;

		fc.purpose   = ...;
		fc.fs_type   = ...;
		fc.root      = ...;
		fc.sb_flags  = ...;

		reconfigure_super(&fc);
	}

	-ss



[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