Re: [PATCH] fs: Assert on module file_operations without an owner

2016-10-07 Thread Calvin Owens
On Friday 10/07 at 17:18 -0400, Calvin Owens wrote: > On Friday 10/07 at 21:48 +0100, Al Viro wrote: > > On Fri, Oct 07, 2016 at 01:35:52PM -0700, Calvin Owens wrote: > > > Omitting the owner field in file_operations declared in modules is an > > > easy mistake to make, and can result in crashes

Re: [PATCH] fs: Assert on module file_operations without an owner

2016-10-07 Thread Calvin Owens
On Friday 10/07 at 17:18 -0400, Calvin Owens wrote: > On Friday 10/07 at 21:48 +0100, Al Viro wrote: > > On Fri, Oct 07, 2016 at 01:35:52PM -0700, Calvin Owens wrote: > > > Omitting the owner field in file_operations declared in modules is an > > > easy mistake to make, and can result in crashes

Re: [PATCH] fs: Assert on module file_operations without an owner

2016-10-07 Thread Calvin Owens
On Friday 10/07 at 21:48 +0100, Al Viro wrote: > On Fri, Oct 07, 2016 at 01:35:52PM -0700, Calvin Owens wrote: > > Omitting the owner field in file_operations declared in modules is an > > easy mistake to make, and can result in crashes when the module is > > unloaded while userspace is poking the

Re: [PATCH] fs: Assert on module file_operations without an owner

2016-10-07 Thread Calvin Owens
On Friday 10/07 at 21:48 +0100, Al Viro wrote: > On Fri, Oct 07, 2016 at 01:35:52PM -0700, Calvin Owens wrote: > > Omitting the owner field in file_operations declared in modules is an > > easy mistake to make, and can result in crashes when the module is > > unloaded while userspace is poking the

Re: [PATCH] fs: Assert on module file_operations without an owner

2016-10-07 Thread Al Viro
On Fri, Oct 07, 2016 at 01:35:52PM -0700, Calvin Owens wrote: > Omitting the owner field in file_operations declared in modules is an > easy mistake to make, and can result in crashes when the module is > unloaded while userspace is poking the file. > > This patch modifies fops_get() to WARN when

Re: [PATCH] fs: Assert on module file_operations without an owner

2016-10-07 Thread Al Viro
On Fri, Oct 07, 2016 at 01:35:52PM -0700, Calvin Owens wrote: > Omitting the owner field in file_operations declared in modules is an > easy mistake to make, and can result in crashes when the module is > unloaded while userspace is poking the file. > > This patch modifies fops_get() to WARN when

[PATCH] fs: Assert on module file_operations without an owner

2016-10-07 Thread Calvin Owens
Omitting the owner field in file_operations declared in modules is an easy mistake to make, and can result in crashes when the module is unloaded while userspace is poking the file. This patch modifies fops_get() to WARN when it encounters a NULL owner, since in this case it cannot take a

[PATCH] fs: Assert on module file_operations without an owner

2016-10-07 Thread Calvin Owens
Omitting the owner field in file_operations declared in modules is an easy mistake to make, and can result in crashes when the module is unloaded while userspace is poking the file. This patch modifies fops_get() to WARN when it encounters a NULL owner, since in this case it cannot take a