From: kernel test robot <lkp@intel.com>
To: kbuild-all@lists.01.org
Subject: [linux-next:master 1232/1691] drivers/mtd/nand/raw/tango_nand.c:348:35: warning: Clarify calculation precedence for '&' and
Date: Tue, 16 Jun 2020 20:54:36 +0800 [thread overview]
Message-ID: <202006162032.PMTpbd4e%lkp@intel.com> (raw)
[-- Attachment #1: Type: text/plain, Size: 1917 bytes --]
tree: https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git master
head: 27f70ec4fa0e0f419031f1b8d61b1a788244e313
commit: d8ed345a4c622657638b740415c6f73b26bfd132 [1232/1691] mtd: rawnand: tango: Convert the driver to exec_op()
compiler: gcc-9 (Debian 9.3.0-13) 9.3.0
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>
cppcheck warnings: (new ones prefixed by >>)
>> drivers/mtd/nand/raw/tango_nand.c:348:35: warning: Clarify calculation precedence for '&' and '?'. [clarifyCalculation]
return status & NAND_STATUS_FAIL ? -EIO : 0;
^
vim +348 drivers/mtd/nand/raw/tango_nand.c
319
320 static int tango_write_page(struct nand_chip *chip, const u8 *buf,
321 int oob_required, int page)
322 {
323 struct mtd_info *mtd = nand_to_mtd(chip);
324 struct tango_nfc *nfc = to_tango_nfc(chip->controller);
325 const struct nand_sdr_timings *timings;
326 int err, len = mtd->writesize;
327 u8 status;
328
329 /* Calling tango_write_oob() would send PAGEPROG twice */
330 if (oob_required)
331 return -ENOTSUPP;
332
333 tango_select_target(chip, chip->cur_cs);
334 writel_relaxed(0xffffffff, nfc->mem_base + METADATA);
335 err = do_dma(nfc, DMA_TO_DEVICE, NFC_WRITE, buf, len, page);
336 if (err)
337 return err;
338
339 timings = nand_get_sdr_timings(&chip->data_interface);
340 err = tango_waitrdy(chip, PSEC_TO_MSEC(timings->tR_max));
341 if (err)
342 return err;
343
344 err = nand_status_op(chip, &status);
345 if (err)
346 return err;
347
> 348 return status & NAND_STATUS_FAIL ? -EIO : 0;
349 }
350
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org
reply other threads:[~2020-06-16 12:54 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=202006162032.PMTpbd4e%lkp@intel.com \
--to=lkp@intel.com \
--cc=kbuild-all@lists.01.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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.