diff for duplicates of <202207132125.6mLS6KnE-lkp@intel.com> diff --git a/a/1.txt b/N1/1.txt index 3cc7725..bb3c08f 100644 --- a/a/1.txt +++ b/N1/1.txt @@ -1,15 +1,6 @@ -CC: kbuild-all(a)lists.01.org -BCC: lkp(a)intel.com -CC: linux-kernel(a)vger.kernel.org -TO: Arnd Bergmann <arnd@arndb.de> -CC: Christoph Hellwig <hch@lst.de> - tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master head: b047602d579b4fb028128a525f056bbdc890e7f0 commit: a97b693c3712f040c5802f32b2d685352e08cefa uaccess: fix nios2 and microblaze get_user_8() -date: 5 months ago -:::::: branch date: 14 hours ago -:::::: commit date: 5 months ago config: nios2-randconfig-m031-20220712 (https://download.01.org/0day-ci/archive/20220713/202207132125.6mLS6KnE-lkp(a)intel.com/config) compiler: nios2-linux-gcc (GCC) 11.3.0 @@ -20,12 +11,8 @@ Reported-by: Dan Carpenter <dan.carpenter@oracle.com> New smatch warnings: fs/nfsd/nfs4recover.c:814 __cld_pipe_inprogress_downcall() error: uninitialized symbol 'princhashlen'. -Old smatch warnings: -arch/nios2/include/asm/thread_info.h:71 current_thread_info() error: uninitialized symbol 'sp'. - vim +/princhashlen +814 fs/nfsd/nfs4recover.c -f3f8014862d813c Jeff Layton 2012-03-21 788 74725959c33c141 Scott Mayhew 2019-03-26 789 static ssize_t 6ee95d1c899186c Scott Mayhew 2019-09-09 790 __cld_pipe_inprogress_downcall(const struct cld_msg_v2 __user *cmsg, 74725959c33c141 Scott Mayhew 2019-03-26 791 struct nfsd_net *nn) @@ -51,12 +38,28 @@ f3f8014862d813c Jeff Layton 2012-03-21 788 6ee95d1c899186c Scott Mayhew 2019-09-09 811 return -EFAULT; 6ee95d1c899186c Scott Mayhew 2019-09-09 812 name.len = namelen; 6ee95d1c899186c Scott Mayhew 2019-09-09 813 get_user(princhashlen, &ci->cc_princhash.cp_len); + +No error checking on get_user() leads to uninitialized variable bug. + +It's weird that we're only just now catching a 2019 bug but I guess +the "uaccess: fix nios2 and microblaze get_user_8()" patch makes the +function easy enough for Smatch to parse it on that architecture. On +x86 it's done in assembly so Smatch doesn't track error paths. + +This bug is still present upstream. + 6ee95d1c899186c Scott Mayhew 2019-09-09 @814 if (princhashlen > 0) { 6ee95d1c899186c Scott Mayhew 2019-09-09 815 princhash.data = memdup_user( 6ee95d1c899186c Scott Mayhew 2019-09-09 816 &ci->cc_princhash.cp_data, 6ee95d1c899186c Scott Mayhew 2019-09-09 817 princhashlen); 6ee95d1c899186c Scott Mayhew 2019-09-09 818 if (IS_ERR_OR_NULL(princhash.data)) 6ee95d1c899186c Scott Mayhew 2019-09-09 819 return -EFAULT; + +The memdup_user() function cannot return NULL, btw. (When a function +returns both a mix of error pointers and NULL that generally means it +is an optional feature like LEDs or power management. The NULL is not +an error but means that it has been deliberately disabled). + 6ee95d1c899186c Scott Mayhew 2019-09-09 820 princhash.len = princhashlen; 6ee95d1c899186c Scott Mayhew 2019-09-09 821 } else 6ee95d1c899186c Scott Mayhew 2019-09-09 822 princhash.len = 0; @@ -85,13 +88,6 @@ f3f8014862d813c Jeff Layton 2012-03-21 788 74725959c33c141 Scott Mayhew 2019-03-26 845 } 74725959c33c141 Scott Mayhew 2019-03-26 846 return -EFAULT; 74725959c33c141 Scott Mayhew 2019-03-26 847 } -74725959c33c141 Scott Mayhew 2019-03-26 848 - -:::::: The code at line 814 was first introduced by commit -:::::: 6ee95d1c899186c0798cafd25998d436bcdb9618 nfsd: add support for upcall version 2 - -:::::: TO: Scott Mayhew <smayhew@redhat.com> -:::::: CC: J. Bruce Fields <bfields@redhat.com> -- 0-DAY CI Kernel Test Service diff --git a/a/content_digest b/N1/content_digest index 336e6bf..0be91d2 100644 --- a/a/content_digest +++ b/N1/content_digest @@ -1,21 +1,12 @@ - "From\0kernel test robot <lkp@intel.com>\0" + "From\0Dan Carpenter <dan.carpenter@oracle.com>\0" "Subject\0fs/nfsd/nfs4recover.c:814 __cld_pipe_inprogress_downcall() error: uninitialized symbol 'princhashlen'.\0" - "Date\0Wed, 13 Jul 2022 21:49:18 +0800\0" - "To\0kbuild@lists.01.org\0" + "Date\0Wed, 13 Jul 2022 17:33:30 +0300\0" + "To\0kbuild-all@lists.01.org\0" "\01:1\0" "b\0" - "CC: kbuild-all(a)lists.01.org\n" - "BCC: lkp(a)intel.com\n" - "CC: linux-kernel(a)vger.kernel.org\n" - "TO: Arnd Bergmann <arnd@arndb.de>\n" - "CC: Christoph Hellwig <hch@lst.de>\n" - "\n" "tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master\n" "head: b047602d579b4fb028128a525f056bbdc890e7f0\n" "commit: a97b693c3712f040c5802f32b2d685352e08cefa uaccess: fix nios2 and microblaze get_user_8()\n" - "date: 5 months ago\n" - ":::::: branch date: 14 hours ago\n" - ":::::: commit date: 5 months ago\n" "config: nios2-randconfig-m031-20220712 (https://download.01.org/0day-ci/archive/20220713/202207132125.6mLS6KnE-lkp(a)intel.com/config)\n" "compiler: nios2-linux-gcc (GCC) 11.3.0\n" "\n" @@ -26,12 +17,8 @@ "New smatch warnings:\n" "fs/nfsd/nfs4recover.c:814 __cld_pipe_inprogress_downcall() error: uninitialized symbol 'princhashlen'.\n" "\n" - "Old smatch warnings:\n" - "arch/nios2/include/asm/thread_info.h:71 current_thread_info() error: uninitialized symbol 'sp'.\n" - "\n" "vim +/princhashlen +814 fs/nfsd/nfs4recover.c\n" "\n" - "f3f8014862d813c Jeff Layton 2012-03-21 788 \n" "74725959c33c141 Scott Mayhew 2019-03-26 789 static ssize_t\n" "6ee95d1c899186c Scott Mayhew 2019-09-09 790 __cld_pipe_inprogress_downcall(const struct cld_msg_v2 __user *cmsg,\n" "74725959c33c141 Scott Mayhew 2019-03-26 791 \t\tstruct nfsd_net *nn)\n" @@ -57,12 +44,28 @@ "6ee95d1c899186c Scott Mayhew 2019-09-09 811 \t\t\t\treturn -EFAULT;\n" "6ee95d1c899186c Scott Mayhew 2019-09-09 812 \t\t\tname.len = namelen;\n" "6ee95d1c899186c Scott Mayhew 2019-09-09 813 \t\t\tget_user(princhashlen, &ci->cc_princhash.cp_len);\n" + "\n" + "No error checking on get_user() leads to uninitialized variable bug.\n" + "\n" + "It's weird that we're only just now catching a 2019 bug but I guess\n" + "the \"uaccess: fix nios2 and microblaze get_user_8()\" patch makes the\n" + "function easy enough for Smatch to parse it on that architecture. On\n" + "x86 it's done in assembly so Smatch doesn't track error paths.\n" + "\n" + "This bug is still present upstream.\n" + "\n" "6ee95d1c899186c Scott Mayhew 2019-09-09 @814 \t\t\tif (princhashlen > 0) {\n" "6ee95d1c899186c Scott Mayhew 2019-09-09 815 \t\t\t\tprinchash.data = memdup_user(\n" "6ee95d1c899186c Scott Mayhew 2019-09-09 816 \t\t\t\t\t\t&ci->cc_princhash.cp_data,\n" "6ee95d1c899186c Scott Mayhew 2019-09-09 817 \t\t\t\t\t\tprinchashlen);\n" "6ee95d1c899186c Scott Mayhew 2019-09-09 818 \t\t\t\tif (IS_ERR_OR_NULL(princhash.data))\n" "6ee95d1c899186c Scott Mayhew 2019-09-09 819 \t\t\t\t\treturn -EFAULT;\n" + "\n" + "The memdup_user() function cannot return NULL, btw. (When a function\n" + "returns both a mix of error pointers and NULL that generally means it\n" + "is an optional feature like LEDs or power management. The NULL is not\n" + "an error but means that it has been deliberately disabled).\n" + "\n" "6ee95d1c899186c Scott Mayhew 2019-09-09 820 \t\t\t\tprinchash.len = princhashlen;\n" "6ee95d1c899186c Scott Mayhew 2019-09-09 821 \t\t\t} else\n" "6ee95d1c899186c Scott Mayhew 2019-09-09 822 \t\t\t\tprinchash.len = 0;\n" @@ -91,16 +94,9 @@ "74725959c33c141 Scott Mayhew 2019-03-26 845 \t}\n" "74725959c33c141 Scott Mayhew 2019-03-26 846 \treturn -EFAULT;\n" "74725959c33c141 Scott Mayhew 2019-03-26 847 }\n" - "74725959c33c141 Scott Mayhew 2019-03-26 848 \n" - "\n" - ":::::: The code at line 814 was first introduced by commit\n" - ":::::: 6ee95d1c899186c0798cafd25998d436bcdb9618 nfsd: add support for upcall version 2\n" - "\n" - ":::::: TO: Scott Mayhew <smayhew@redhat.com>\n" - ":::::: CC: J. Bruce Fields <bfields@redhat.com>\n" "\n" "-- \n" "0-DAY CI Kernel Test Service\n" https://01.org/lkp -43c2735ee3d9ee6039e79468bcb9e7af6b528769fd1e4e962421a2046b4728f0 +d7d1a2ca01d35f6ec65afcfe3d00349486c4fca6e3f29f44c3d3f7246e84b18a
diff --git a/a/1.txt b/N2/1.txt index 3cc7725..6aa2b05 100644 --- a/a/1.txt +++ b/N2/1.txt @@ -1,16 +1,7 @@ -CC: kbuild-all(a)lists.01.org -BCC: lkp(a)intel.com -CC: linux-kernel(a)vger.kernel.org -TO: Arnd Bergmann <arnd@arndb.de> -CC: Christoph Hellwig <hch@lst.de> - tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master head: b047602d579b4fb028128a525f056bbdc890e7f0 commit: a97b693c3712f040c5802f32b2d685352e08cefa uaccess: fix nios2 and microblaze get_user_8() -date: 5 months ago -:::::: branch date: 14 hours ago -:::::: commit date: 5 months ago -config: nios2-randconfig-m031-20220712 (https://download.01.org/0day-ci/archive/20220713/202207132125.6mLS6KnE-lkp(a)intel.com/config) +config: nios2-randconfig-m031-20220712 (https://download.01.org/0day-ci/archive/20220713/202207132125.6mLS6KnE-lkp@intel.com/config) compiler: nios2-linux-gcc (GCC) 11.3.0 If you fix the issue, kindly add following tag where applicable @@ -20,12 +11,8 @@ Reported-by: Dan Carpenter <dan.carpenter@oracle.com> New smatch warnings: fs/nfsd/nfs4recover.c:814 __cld_pipe_inprogress_downcall() error: uninitialized symbol 'princhashlen'. -Old smatch warnings: -arch/nios2/include/asm/thread_info.h:71 current_thread_info() error: uninitialized symbol 'sp'. - vim +/princhashlen +814 fs/nfsd/nfs4recover.c -f3f8014862d813c Jeff Layton 2012-03-21 788 74725959c33c141 Scott Mayhew 2019-03-26 789 static ssize_t 6ee95d1c899186c Scott Mayhew 2019-09-09 790 __cld_pipe_inprogress_downcall(const struct cld_msg_v2 __user *cmsg, 74725959c33c141 Scott Mayhew 2019-03-26 791 struct nfsd_net *nn) @@ -51,12 +38,28 @@ f3f8014862d813c Jeff Layton 2012-03-21 788 6ee95d1c899186c Scott Mayhew 2019-09-09 811 return -EFAULT; 6ee95d1c899186c Scott Mayhew 2019-09-09 812 name.len = namelen; 6ee95d1c899186c Scott Mayhew 2019-09-09 813 get_user(princhashlen, &ci->cc_princhash.cp_len); + +No error checking on get_user() leads to uninitialized variable bug. + +It's weird that we're only just now catching a 2019 bug but I guess +the "uaccess: fix nios2 and microblaze get_user_8()" patch makes the +function easy enough for Smatch to parse it on that architecture. On +x86 it's done in assembly so Smatch doesn't track error paths. + +This bug is still present upstream. + 6ee95d1c899186c Scott Mayhew 2019-09-09 @814 if (princhashlen > 0) { 6ee95d1c899186c Scott Mayhew 2019-09-09 815 princhash.data = memdup_user( 6ee95d1c899186c Scott Mayhew 2019-09-09 816 &ci->cc_princhash.cp_data, 6ee95d1c899186c Scott Mayhew 2019-09-09 817 princhashlen); 6ee95d1c899186c Scott Mayhew 2019-09-09 818 if (IS_ERR_OR_NULL(princhash.data)) 6ee95d1c899186c Scott Mayhew 2019-09-09 819 return -EFAULT; + +The memdup_user() function cannot return NULL, btw. (When a function +returns both a mix of error pointers and NULL that generally means it +is an optional feature like LEDs or power management. The NULL is not +an error but means that it has been deliberately disabled). + 6ee95d1c899186c Scott Mayhew 2019-09-09 820 princhash.len = princhashlen; 6ee95d1c899186c Scott Mayhew 2019-09-09 821 } else 6ee95d1c899186c Scott Mayhew 2019-09-09 822 princhash.len = 0; @@ -85,13 +88,6 @@ f3f8014862d813c Jeff Layton 2012-03-21 788 74725959c33c141 Scott Mayhew 2019-03-26 845 } 74725959c33c141 Scott Mayhew 2019-03-26 846 return -EFAULT; 74725959c33c141 Scott Mayhew 2019-03-26 847 } -74725959c33c141 Scott Mayhew 2019-03-26 848 - -:::::: The code at line 814 was first introduced by commit -:::::: 6ee95d1c899186c0798cafd25998d436bcdb9618 nfsd: add support for upcall version 2 - -:::::: TO: Scott Mayhew <smayhew@redhat.com> -:::::: CC: J. Bruce Fields <bfields@redhat.com> -- 0-DAY CI Kernel Test Service diff --git a/a/content_digest b/N2/content_digest index 336e6bf..e3457f5 100644 --- a/a/content_digest +++ b/N2/content_digest @@ -1,22 +1,19 @@ - "From\0kernel test robot <lkp@intel.com>\0" + "From\0Dan Carpenter <dan.carpenter@oracle.com>\0" "Subject\0fs/nfsd/nfs4recover.c:814 __cld_pipe_inprogress_downcall() error: uninitialized symbol 'princhashlen'.\0" - "Date\0Wed, 13 Jul 2022 21:49:18 +0800\0" - "To\0kbuild@lists.01.org\0" - "\01:1\0" + "Date\0Wed, 13 Jul 2022 17:33:30 +0300\0" + "To\0kbuild@lists.01.org" + Scott Mayhew <smayhew@redhat.com> + " Arnd Bergmann <arnd@arndb.de>\0" + "Cc\0lkp@intel.com" + kbuild-all@lists.01.org + linux-kernel@vger.kernel.org + " J. Bruce Fields <bfields@redhat.com>\0" + "\00:1\0" "b\0" - "CC: kbuild-all(a)lists.01.org\n" - "BCC: lkp(a)intel.com\n" - "CC: linux-kernel(a)vger.kernel.org\n" - "TO: Arnd Bergmann <arnd@arndb.de>\n" - "CC: Christoph Hellwig <hch@lst.de>\n" - "\n" "tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master\n" "head: b047602d579b4fb028128a525f056bbdc890e7f0\n" "commit: a97b693c3712f040c5802f32b2d685352e08cefa uaccess: fix nios2 and microblaze get_user_8()\n" - "date: 5 months ago\n" - ":::::: branch date: 14 hours ago\n" - ":::::: commit date: 5 months ago\n" - "config: nios2-randconfig-m031-20220712 (https://download.01.org/0day-ci/archive/20220713/202207132125.6mLS6KnE-lkp(a)intel.com/config)\n" + "config: nios2-randconfig-m031-20220712 (https://download.01.org/0day-ci/archive/20220713/202207132125.6mLS6KnE-lkp@intel.com/config)\n" "compiler: nios2-linux-gcc (GCC) 11.3.0\n" "\n" "If you fix the issue, kindly add following tag where applicable\n" @@ -26,12 +23,8 @@ "New smatch warnings:\n" "fs/nfsd/nfs4recover.c:814 __cld_pipe_inprogress_downcall() error: uninitialized symbol 'princhashlen'.\n" "\n" - "Old smatch warnings:\n" - "arch/nios2/include/asm/thread_info.h:71 current_thread_info() error: uninitialized symbol 'sp'.\n" - "\n" "vim +/princhashlen +814 fs/nfsd/nfs4recover.c\n" "\n" - "f3f8014862d813c Jeff Layton 2012-03-21 788 \n" "74725959c33c141 Scott Mayhew 2019-03-26 789 static ssize_t\n" "6ee95d1c899186c Scott Mayhew 2019-09-09 790 __cld_pipe_inprogress_downcall(const struct cld_msg_v2 __user *cmsg,\n" "74725959c33c141 Scott Mayhew 2019-03-26 791 \t\tstruct nfsd_net *nn)\n" @@ -57,12 +50,28 @@ "6ee95d1c899186c Scott Mayhew 2019-09-09 811 \t\t\t\treturn -EFAULT;\n" "6ee95d1c899186c Scott Mayhew 2019-09-09 812 \t\t\tname.len = namelen;\n" "6ee95d1c899186c Scott Mayhew 2019-09-09 813 \t\t\tget_user(princhashlen, &ci->cc_princhash.cp_len);\n" + "\n" + "No error checking on get_user() leads to uninitialized variable bug.\n" + "\n" + "It's weird that we're only just now catching a 2019 bug but I guess\n" + "the \"uaccess: fix nios2 and microblaze get_user_8()\" patch makes the\n" + "function easy enough for Smatch to parse it on that architecture. On\n" + "x86 it's done in assembly so Smatch doesn't track error paths.\n" + "\n" + "This bug is still present upstream.\n" + "\n" "6ee95d1c899186c Scott Mayhew 2019-09-09 @814 \t\t\tif (princhashlen > 0) {\n" "6ee95d1c899186c Scott Mayhew 2019-09-09 815 \t\t\t\tprinchash.data = memdup_user(\n" "6ee95d1c899186c Scott Mayhew 2019-09-09 816 \t\t\t\t\t\t&ci->cc_princhash.cp_data,\n" "6ee95d1c899186c Scott Mayhew 2019-09-09 817 \t\t\t\t\t\tprinchashlen);\n" "6ee95d1c899186c Scott Mayhew 2019-09-09 818 \t\t\t\tif (IS_ERR_OR_NULL(princhash.data))\n" "6ee95d1c899186c Scott Mayhew 2019-09-09 819 \t\t\t\t\treturn -EFAULT;\n" + "\n" + "The memdup_user() function cannot return NULL, btw. (When a function\n" + "returns both a mix of error pointers and NULL that generally means it\n" + "is an optional feature like LEDs or power management. The NULL is not\n" + "an error but means that it has been deliberately disabled).\n" + "\n" "6ee95d1c899186c Scott Mayhew 2019-09-09 820 \t\t\t\tprinchash.len = princhashlen;\n" "6ee95d1c899186c Scott Mayhew 2019-09-09 821 \t\t\t} else\n" "6ee95d1c899186c Scott Mayhew 2019-09-09 822 \t\t\t\tprinchash.len = 0;\n" @@ -91,16 +100,9 @@ "74725959c33c141 Scott Mayhew 2019-03-26 845 \t}\n" "74725959c33c141 Scott Mayhew 2019-03-26 846 \treturn -EFAULT;\n" "74725959c33c141 Scott Mayhew 2019-03-26 847 }\n" - "74725959c33c141 Scott Mayhew 2019-03-26 848 \n" - "\n" - ":::::: The code at line 814 was first introduced by commit\n" - ":::::: 6ee95d1c899186c0798cafd25998d436bcdb9618 nfsd: add support for upcall version 2\n" - "\n" - ":::::: TO: Scott Mayhew <smayhew@redhat.com>\n" - ":::::: CC: J. Bruce Fields <bfields@redhat.com>\n" "\n" "-- \n" "0-DAY CI Kernel Test Service\n" https://01.org/lkp -43c2735ee3d9ee6039e79468bcb9e7af6b528769fd1e4e962421a2046b4728f0 +dc09ef156c0514e1007b27badd5ca652da5efa2fde307729310efee38af5f8ee
This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.