From: kernel test robot <lkp@intel.com>
To: Hui-Ping Chen <hpchen0nvt@gmail.com>,
miquel.raynal@bootlin.com, richard@nod.at, vigneshr@ti.com,
robh@kernel.org, krzk+dt@kernel.org, conor+dt@kernel.org,
sumit.semwal@linaro.org, christian.koenig@amd.com,
esben@geanix.com
Cc: oe-kbuild-all@lists.linux.dev,
linux-arm-kernel@lists.infradead.org,
linux-mtd@lists.infradead.org, devicetree@vger.kernel.org,
linux-kernel@vger.kernel.org, linux-media@vger.kernel.org,
dri-devel@lists.freedesktop.org, linaro-mm-sig@lists.linaro.org,
Hui-Ping Chen <hpchen0nvt@gmail.com>
Subject: Re: [PATCH v2 2/2] mtd: rawnand: nuvoton: add new driver for the Nuvoton MA35 SoC
Date: Tue, 20 Aug 2024 13:47:27 +0800 [thread overview]
Message-ID: <202408201329.v0SoF3eS-lkp@intel.com> (raw)
In-Reply-To: <20240819092037.110260-3-hpchen0nvt@gmail.com>
Hi Hui-Ping,
kernel test robot noticed the following build warnings:
[auto build test WARNING on mtd/nand/next]
[also build test WARNING on linus/master v6.11-rc4 next-20240820]
[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#_base_tree_information]
url: https://github.com/intel-lab-lkp/linux/commits/Hui-Ping-Chen/dt-bindings-mtd-nuvoton-ma35d1-nand-add-new-bindings/20240819-172155
base: https://git.kernel.org/pub/scm/linux/kernel/git/mtd/linux.git nand/next
patch link: https://lore.kernel.org/r/20240819092037.110260-3-hpchen0nvt%40gmail.com
patch subject: [PATCH v2 2/2] mtd: rawnand: nuvoton: add new driver for the Nuvoton MA35 SoC
config: parisc-randconfig-r123-20240820 (https://download.01.org/0day-ci/archive/20240820/202408201329.v0SoF3eS-lkp@intel.com/config)
compiler: hppa-linux-gcc (GCC) 14.1.0
reproduce: (https://download.01.org/0day-ci/archive/20240820/202408201329.v0SoF3eS-lkp@intel.com/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@intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202408201329.v0SoF3eS-lkp@intel.com/
sparse warnings: (new ones prefixed by >>)
drivers/mtd/nand/raw/nuvoton_ma35d1_nand.c:231:20: sparse: sparse: cast removes address space '__iomem' of expression
>> drivers/mtd/nand/raw/nuvoton_ma35d1_nand.c:736:20: sparse: sparse: incorrect type in initializer (different address spaces) @@ expected unsigned char [usertype] *ptr @@ got unsigned char [noderef] [usertype] __iomem * @@
drivers/mtd/nand/raw/nuvoton_ma35d1_nand.c:736:20: sparse: expected unsigned char [usertype] *ptr
drivers/mtd/nand/raw/nuvoton_ma35d1_nand.c:736:20: sparse: got unsigned char [noderef] [usertype] __iomem *
>> drivers/mtd/nand/raw/nuvoton_ma35d1_nand.c:764:22: sparse: sparse: incorrect type in initializer (different address spaces) @@ expected char *ptr @@ got char [noderef] __iomem * @@
drivers/mtd/nand/raw/nuvoton_ma35d1_nand.c:764:22: sparse: expected char *ptr
drivers/mtd/nand/raw/nuvoton_ma35d1_nand.c:764:22: sparse: got char [noderef] __iomem *
drivers/mtd/nand/raw/nuvoton_ma35d1_nand.c:803:22: sparse: sparse: incorrect type in initializer (different address spaces) @@ expected char *ptr @@ got char [noderef] __iomem * @@
drivers/mtd/nand/raw/nuvoton_ma35d1_nand.c:803:22: sparse: expected char *ptr
drivers/mtd/nand/raw/nuvoton_ma35d1_nand.c:803:22: sparse: got char [noderef] __iomem *
drivers/mtd/nand/raw/nuvoton_ma35d1_nand.c:506:28: sparse: sparse: incorrect type in initializer (different address spaces) @@ expected unsigned char [usertype] *ptr @@ got unsigned char [noderef] [usertype] __iomem * @@
drivers/mtd/nand/raw/nuvoton_ma35d1_nand.c:506:28: sparse: expected unsigned char [usertype] *ptr
drivers/mtd/nand/raw/nuvoton_ma35d1_nand.c:506:28: sparse: got unsigned char [noderef] [usertype] __iomem *
drivers/mtd/nand/raw/nuvoton_ma35d1_nand.c:506:28: sparse: sparse: incorrect type in initializer (different address spaces) @@ expected unsigned char [usertype] *ptr @@ got unsigned char [noderef] [usertype] __iomem * @@
drivers/mtd/nand/raw/nuvoton_ma35d1_nand.c:506:28: sparse: expected unsigned char [usertype] *ptr
drivers/mtd/nand/raw/nuvoton_ma35d1_nand.c:506:28: sparse: got unsigned char [noderef] [usertype] __iomem *
drivers/mtd/nand/raw/nuvoton_ma35d1_nand.c:506:28: sparse: sparse: incorrect type in initializer (different address spaces) @@ expected unsigned char [usertype] *ptr @@ got unsigned char [noderef] [usertype] __iomem * @@
drivers/mtd/nand/raw/nuvoton_ma35d1_nand.c:506:28: sparse: expected unsigned char [usertype] *ptr
drivers/mtd/nand/raw/nuvoton_ma35d1_nand.c:506:28: sparse: got unsigned char [noderef] [usertype] __iomem *
drivers/mtd/nand/raw/nuvoton_ma35d1_nand.c:506:28: sparse: sparse: incorrect type in initializer (different address spaces) @@ expected unsigned char [usertype] *ptr @@ got unsigned char [noderef] [usertype] __iomem * @@
drivers/mtd/nand/raw/nuvoton_ma35d1_nand.c:506:28: sparse: expected unsigned char [usertype] *ptr
drivers/mtd/nand/raw/nuvoton_ma35d1_nand.c:506:28: sparse: got unsigned char [noderef] [usertype] __iomem *
vim +736 drivers/mtd/nand/raw/nuvoton_ma35d1_nand.c
731
732 static int ma35_nand_write_page_hwecc(struct nand_chip *chip, const u8 *buf,
733 int oob_required, int page)
734 {
735 struct ma35_nand_info *nand = nand_get_controller_data(chip);
> 736 u8 *ptr = (u8 __iomem *)(nand->regs + MA35_NFI_REG_NANDRA0);
737 struct mtd_info *mtd = nand_to_mtd(chip);
738 u8 *ecc_calc = chip->ecc.calc_buf;
739
740 memset((void *)ptr, 0xFF, mtd->oobsize);
741 memcpy((void *)ptr, (void *)chip->oob_poi, mtd->oobsize - chip->ecc.total);
742
743 ma35_nand_command(chip, NAND_CMD_SEQIN, 0, page);
744 ma35_nand_dma_transfer(chip, buf, mtd->writesize, 0x1);
745 ma35_nand_command(chip, NAND_CMD_PAGEPROG, -1, -1);
746 ma35_waitfunc(chip);
747
748 /* Copy parity code in NANDRA to calc */
749 memcpy((void *)ecc_calc,
750 (void *)(ptr + (mtd->oobsize - chip->ecc.total)),
751 chip->ecc.total);
752
753 /* Copy parity code in calc to oob_poi */
754 memcpy((void *)(chip->oob_poi + (mtd->oobsize - chip->ecc.total)),
755 (void *)ecc_calc, chip->ecc.total);
756
757 return 0;
758 }
759
760 static int ma35_nand_read_page_hwecc_oob_first(struct nand_chip *chip, u8 *buf,
761 int oob_required, int page)
762 {
763 struct ma35_nand_info *nand = nand_get_controller_data(chip);
> 764 char *ptr = (char __iomem *)(nand->regs + MA35_NFI_REG_NANDRA0);
765 struct mtd_info *mtd = nand_to_mtd(chip);
766
767 /* 1. read the OOB area */
768 ma35_nand_command(chip, NAND_CMD_READOOB, 0, page);
769 ma35_nand_read_buf(chip, chip->oob_poi, mtd->oobsize);
770
771 /* 2. copy OOB data to NANDRA for page read */
772 memcpy((void *)ptr, (void *)chip->oob_poi, mtd->oobsize);
773
774 if ((*(ptr+2) != 0) && (*(ptr+3) != 0))
775 memset((void *)buf, 0xff, mtd->writesize);
776 else {
777 /* 3. read data from nand */
778 ma35_nand_command(chip, NAND_CMD_READ0, 0, page);
779 ma35_nand_dma_transfer(chip, buf, mtd->writesize, 0x0);
780
781 /* 4. restore OOB data from SMRA */
782 memcpy((void *)chip->oob_poi, (void *)ptr, mtd->oobsize);
783 }
784
785 return 0;
786 }
787
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
prev parent reply other threads:[~2024-08-20 5:48 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-08-19 9:20 [PATCH v2 0/2] Add support for nuvoton ma35 nand controller Hui-Ping Chen
2024-08-19 9:20 ` [PATCH v2 1/2] dt-bindings: mtd: nuvoton,ma35d1-nand: add new bindings Hui-Ping Chen
2024-08-19 11:15 ` Krzysztof Kozlowski
2024-08-19 9:20 ` [PATCH v2 2/2] mtd: rawnand: nuvoton: add new driver for the Nuvoton MA35 SoC Hui-Ping Chen
2024-08-19 11:19 ` Krzysztof Kozlowski
2024-08-20 5:35 ` Hui-Ping Chen
2024-08-20 5:47 ` kernel test robot [this message]
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=202408201329.v0SoF3eS-lkp@intel.com \
--to=lkp@intel.com \
--cc=christian.koenig@amd.com \
--cc=conor+dt@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=dri-devel@lists.freedesktop.org \
--cc=esben@geanix.com \
--cc=hpchen0nvt@gmail.com \
--cc=krzk+dt@kernel.org \
--cc=linaro-mm-sig@lists.linaro.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-media@vger.kernel.org \
--cc=linux-mtd@lists.infradead.org \
--cc=miquel.raynal@bootlin.com \
--cc=oe-kbuild-all@lists.linux.dev \
--cc=richard@nod.at \
--cc=robh@kernel.org \
--cc=sumit.semwal@linaro.org \
--cc=vigneshr@ti.com \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).