From: Andrew Morton security/device_cgroup.c: In function 'devcgroup_access_read': security/device_cgroup.c:280: warning: 'len' may be used uninitialized in this function Cc: "Serge E. Hallyn" Cc: Balbir Singh Cc: Daniel Hokka Zakrisson Cc: James Morris Cc: KAMEZAWA Hiroyuki Cc: Li Zefan Cc: Paul Menage Cc: Serge E. Hallyn Signed-off-by: Andrew Morton --- security/device_cgroup.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff -puN security/device_cgroup.c~cgroups-implement-device-whitelist-v6-fix security/device_cgroup.c --- a/security/device_cgroup.c~cgroups-implement-device-whitelist-v6-fix +++ a/security/device_cgroup.c @@ -277,7 +277,8 @@ static ssize_t devcgroup_access_read(str struct dev_cgroup *devcgroup = cgroup_to_devcgroup(cgroup); int filetype = cft->private; char *buffer; - int len, retval; + int uninitialized_var(len); + int retval; if (filetype != DEVCG_ALLOW) return -EINVAL; _