Re: [PATCH] Staging: rtl8712: rtl871x_security: fixed a camel case variable name coding style issue

From: kernel test robot
Date: Mon Nov 22 2021 - 10:22:59 EST


Hi Zoeb,

Thank you for the patch! Yet something to improve:

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

url: https://github.com/0day-ci/linux/commits/Zoeb-Mithaiwala/Staging-rtl8712-rtl871x_security-fixed-a-camel-case-variable-name-coding-style-issue/20211120-160918
base: https://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging.git 1189d2fb15a4b09b2e8dd01d60a0817d985d933d
config: x86_64-randconfig-a015-20211121 (attached as .config)
reproduce (this is a W=1 build):
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# https://github.com/0day-ci/linux/commit/8c1ab61206da180488d1d32547a73288052736cd
git remote add linux-review https://github.com/0day-ci/linux
git fetch --no-tags linux-review Zoeb-Mithaiwala/Staging-rtl8712-rtl871x_security-fixed-a-camel-case-variable-name-coding-style-issue/20211120-160918
git checkout 8c1ab61206da180488d1d32547a73288052736cd
# save the attached .config to linux build tree
mkdir build_dir
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir ARCH=x86_64 SHELL=/bin/bash

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@xxxxxxxxx>

All errors (new ones prefixed by >>):

>> drivers/staging/rtl8712/rtl871x_security.c:288:44: error: no member named 'n_bytes_in_m' in 'struct mic_data'; did you mean 'nbytes_in_m'?
pmicdata->M |= ((u32)b) << (8 * pmicdata->n_bytes_in_m);
^~~~~~~~~~~~
nbytes_in_m
drivers/staging/rtl8712/rtl871x_security.h:195:7: note: 'nbytes_in_m' declared here
u32 nbytes_in_m; /* # bytes in M */
^
1 error generated.


vim +288 drivers/staging/rtl8712/rtl871x_security.c

284
285 static void secmicappendbyte(struct mic_data *pmicdata, u8 b)
286 {
287 /* Append the byte to our word-sized buffer */
> 288 pmicdata->M |= ((u32)b) << (8 * pmicdata->n_bytes_in_m);
289 pmicdata->nbytes_in_m++;
290 /* Process the word if it is full. */
291 if (pmicdata->nbytes_in_m >= 4) {
292 pmicdata->L ^= pmicdata->M;
293 pmicdata->R ^= ROL32(pmicdata->L, 17);
294 pmicdata->L += pmicdata->R;
295 pmicdata->R ^= ((pmicdata->L & 0xff00ff00) >> 8) |
296 ((pmicdata->L & 0x00ff00ff) << 8);
297 pmicdata->L += pmicdata->R;
298 pmicdata->R ^= ROL32(pmicdata->L, 3);
299 pmicdata->L += pmicdata->R;
300 pmicdata->R ^= ROR32(pmicdata->L, 2);
301 pmicdata->L += pmicdata->R;
302 /* Clear the buffer */
303 pmicdata->M = 0;
304 pmicdata->nbytes_in_m = 0;
305 }
306 }
307

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@xxxxxxxxxxxx

Attachment: .config.gz
Description: application/gzip