[lkml]   [2018]   [Mar]   [12]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: [PATCH 2/3 v4] devpts: resolve devpts bind-mounts
On Mon, Mar 12, 2018 at 5:01 PM, Christian Brauner
<> wrote:
> ChangeLog v3->v4:
> * simplify if condition

Ok, I definitely prefer this simpler version.

We could simplify it even more, though. That end could be just

if (!err) {
if (DEVPTS_SB(path.mnt->mnt_sb) == fsi)
return path.mnt;
err = -ENODEV;

return ERR_PTR(err);


And it might be worth adding a comment that devpts_ptmx_path() always
returns a DEVPTS filesystem of an error. I already wrote out "that's
not right, you can't do DEVPTS_SB() without checking s_magic", but
devpts_ptmx_path() will have done that already.


 \ /
  Last update: 2018-03-13 01:38    [W:0.047 / U:2.760 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site