Re: [PATCH] staging: media: atomisp: comprehensive coding style cleanup

From: kernel test robot

Date: Mon Mar 09 2026 - 06:18:37 EST


Hi Laur,

kernel test robot noticed the following build warnings:

[auto build test WARNING on staging/staging-testing]

url: https://github.com/intel-lab-lkp/linux/commits/Laur/staging-media-atomisp-comprehensive-coding-style-cleanup/20260309-055945
base: staging/staging-testing
patch link: https://lore.kernel.org/r/20260308215840.31197-1-laurentiutopai2004%40gmail.com
patch subject: [PATCH] staging: media: atomisp: comprehensive coding style cleanup
config: i386-allmodconfig (https://download.01.org/0day-ci/archive/20260309/202603091804.DdX2VxlO-lkp@xxxxxxxxx/config)
compiler: gcc-14 (Debian 14.2.0-19) 14.2.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20260309/202603091804.DdX2VxlO-lkp@xxxxxxxxx/reproduce)

If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@xxxxxxxxx>
| Closes: https://lore.kernel.org/oe-kbuild-all/202603091804.DdX2VxlO-lkp@xxxxxxxxx/

All warnings (new ones prefixed by >>):

drivers/staging/media/atomisp/pci/atomisp_cmd.c: In function 'copy_from_compatible':
>> drivers/staging/media/atomisp/pci/atomisp_cmd.c:2033:9: warning: this 'if' clause does not guard... [-Wmisleading-indentation]
2033 | if (from_user)
| ^~
In file included from include/linux/string.h:386,
from arch/x86/include/asm/page_32.h:18,
from arch/x86/include/asm/page.h:14,
from arch/x86/include/asm/thread_info.h:12,
from include/linux/thread_info.h:62,
from include/linux/spinlock.h:60,
from include/linux/mmzone.h:8,
from include/linux/gfp.h:7,
from include/linux/firmware.h:8,
from drivers/staging/media/atomisp/pci/atomisp_cmd.c:10:
include/linux/fortify-string.h:624:62: note: ...this statement, but the latter is misleadingly indented as if it were guarded by the 'if'
624 | p_size_field, q_size_field, op) ({ \
| ^
include/linux/fortify-string.h:688:26: note: in expansion of macro '__fortify_memcpy_chk'
688 | #define memcpy(p, q, s) __fortify_memcpy_chk(p, q, s, \
| ^~~~~~~~~~~~~~~~~~~~
drivers/staging/media/atomisp/pci/atomisp_cmd.c:2036:17: note: in expansion of macro 'memcpy'
2036 | memcpy(to, from, n);
| ^~~~~~


vim +/if +2033 drivers/staging/media/atomisp/pci/atomisp_cmd.c

ad85094b293e40e drivers/staging/media/atomisp/pci/atomisp2/atomisp_cmd.c Mauro Carvalho Chehab 2020-04-19 2029
ad85094b293e40e drivers/staging/media/atomisp/pci/atomisp2/atomisp_cmd.c Mauro Carvalho Chehab 2020-04-19 2030 static unsigned int long copy_from_compatible(void *to, const void *from,
ad85094b293e40e drivers/staging/media/atomisp/pci/atomisp2/atomisp_cmd.c Mauro Carvalho Chehab 2020-04-19 2031 unsigned long n, bool from_user)
ad85094b293e40e drivers/staging/media/atomisp/pci/atomisp2/atomisp_cmd.c Mauro Carvalho Chehab 2020-04-19 2032 {
ad85094b293e40e drivers/staging/media/atomisp/pci/atomisp2/atomisp_cmd.c Mauro Carvalho Chehab 2020-04-19 @2033 if (from_user)
ad85094b293e40e drivers/staging/media/atomisp/pci/atomisp2/atomisp_cmd.c Mauro Carvalho Chehab 2020-04-19 2034 return copy_from_user(to, (void __user *)from, n);
acede91286a8c6f drivers/staging/media/atomisp/pci/atomisp_cmd.c Laur 2026-03-08 2035
ad85094b293e40e drivers/staging/media/atomisp/pci/atomisp2/atomisp_cmd.c Mauro Carvalho Chehab 2020-04-19 2036 memcpy(to, from, n);
ad85094b293e40e drivers/staging/media/atomisp/pci/atomisp2/atomisp_cmd.c Mauro Carvalho Chehab 2020-04-19 2037 return 0;
ad85094b293e40e drivers/staging/media/atomisp/pci/atomisp2/atomisp_cmd.c Mauro Carvalho Chehab 2020-04-19 2038 }
ad85094b293e40e drivers/staging/media/atomisp/pci/atomisp2/atomisp_cmd.c Mauro Carvalho Chehab 2020-04-19 2039

--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki