Merge tag 'pull-stable-struct_fd' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs
Pull 'struct fd' updates from Al Viro: "Just the 'struct fd' layout change, with conversion to accessor helpers" * tag 'pull-stable-struct_fd' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs: add struct fd constructors, get rid of __to_fd() struct fd: representation change introduce fd_file(), convert all accessors to it.
This commit is contained in:
@@ -6968,10 +6968,10 @@ struct cgroup *cgroup_v1v2_get_from_fd(int fd)
|
||||
{
|
||||
struct cgroup *cgrp;
|
||||
struct fd f = fdget_raw(fd);
|
||||
if (!f.file)
|
||||
if (!fd_file(f))
|
||||
return ERR_PTR(-EBADF);
|
||||
|
||||
cgrp = cgroup_v1v2_get_from_file(f.file);
|
||||
cgrp = cgroup_v1v2_get_from_file(fd_file(f));
|
||||
fdput(f);
|
||||
return cgrp;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user