[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <202104171327.3dhODTvY-lkp@intel.com>
Date: Sat, 17 Apr 2021 13:25:55 +0800
From: kernel test robot <lkp@...el.com>
To: Luiz Sampaio <sampaio.ime@...il.com>, zbr@...emap.net
Cc: kbuild-all@...ts.01.org, corbet@....net,
rikard.falkeborn@...il.com, gregkh@...uxfoundation.org,
linux-kernel@...r.kernel.org, linux-doc@...r.kernel.org,
Luiz Sampaio <sampaio.ime@...il.com>
Subject: Re: [PATCH v7 6/6] w1: ds2438: support for writing to offset register
Hi Luiz,
Thank you for the patch! Perhaps something to improve:
[auto build test WARNING on linus/master]
[also build test WARNING on v5.12-rc7 next-20210416]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch]
url: https://github.com/0day-ci/linux/commits/Luiz-Sampaio/w1-ds2438-fixed-a-coding-style-issue/20210417-071754
base: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git 151501160401e2dc669ea7dac2c599b53f220c33
config: csky-randconfig-m031-20210416 (attached as .config)
compiler: csky-linux-gcc (GCC) 9.3.0
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@...el.com>
smatch warnings:
drivers/w1/slaves/w1_ds2438.c:218 w1_ds2438_change_offset_register() warn: inconsistent indenting
vim +218 drivers/w1/slaves/w1_ds2438.c
195
196 static int w1_ds2438_change_offset_register(struct w1_slave *sl, u8 *value)
197 {
198 unsigned int retries = W1_DS2438_RETRIES;
199 u8 w1_buf[9];
200 u8 w1_page1_buf[DS2438_PAGE_SIZE + 1 /*for CRC*/];
201
202 if (w1_ds2438_get_page(sl, 1, w1_page1_buf) == 0) {
203 memcpy(&w1_buf[2], w1_page1_buf, DS2438_PAGE_SIZE - 1); /* last register reserved */
204 w1_buf[7] = value[0]; /* change only offset register */
205 w1_buf[8] = value[1];
206 while (retries--) {
207 if (w1_reset_select_slave(sl))
208 continue;
209 w1_buf[0] = W1_DS2438_WRITE_SCRATCH;
210 w1_buf[1] = 0x01; /* write to page 1 */
211 w1_write_block(sl->master, w1_buf, 9);
212
213 if (w1_reset_select_slave(sl))
214 continue;
215 w1_buf[0] = W1_DS2438_COPY_SCRATCH;
216 w1_buf[1] = 0x01;
217 w1_write_block(sl->master, w1_buf, 2);
> 218 return 0;
219 }
220 }
221 return -1;
222 }
223
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
Download attachment ".config.gz" of type "application/gzip" (24550 bytes)
Powered by blists - more mailing lists