public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* drivers/i3c/internals.h:54:9: error: passing 'const void *' to parameter of type 'void *' discards qualifiers
@ 2025-08-06 20:40 kernel test robot
  0 siblings, 0 replies; 5+ messages in thread
From: kernel test robot @ 2025-08-06 20:40 UTC (permalink / raw)
  To: Wolfram Sang
  Cc: llvm, oe-kbuild-all, linux-kernel, Alexandre Belloni, Frank Li

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head:   cca7a0aae8958c9b1cd14116cb8b2f22ace2205e
commit: 3b661ca549b9e5bb11d0bc97ada6110aac3282d2 i3c: add missing include to internal header
date:   7 days ago
config: sparc64-randconfig-002-20250807 (https://download.01.org/0day-ci/archive/20250807/202508070438.TZZA3f2S-lkp@intel.com/config)
compiler: clang version 22.0.0git (https://github.com/llvm/llvm-project 7b8dea265e72c3037b6b1e54d5ab51b7e14f328b)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20250807/202508070438.TZZA3f2S-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/202508070438.TZZA3f2S-lkp@intel.com/

All errors (new ones prefixed by >>):

   In file included from drivers/i3c/master.c:21:
>> drivers/i3c/internals.h:54:9: error: passing 'const void *' to parameter of type 'void *' discards qualifiers [-Werror,-Wincompatible-pointer-types-discards-qualifiers]
      54 |         readsl(addr, buf, nbytes / 4);
         |                ^~~~
   arch/sparc/include/asm/io_64.h:265:41: note: passing argument to parameter 'port' here
     265 | static inline void readsl(void __iomem *port, void *buf, unsigned long count)
         |                                         ^
   1 error generated.


vim +54 drivers/i3c/internals.h

733b439375b494 Jorge Marques 2025-06-24  44  
733b439375b494 Jorge Marques 2025-06-24  45  /**
733b439375b494 Jorge Marques 2025-06-24  46   * i3c_readl_fifo - Read data buffer from 32bit FIFO
733b439375b494 Jorge Marques 2025-06-24  47   * @addr: FIFO Address to read from
733b439375b494 Jorge Marques 2025-06-24  48   * @buf: Pointer to the buffer to store read bytes
733b439375b494 Jorge Marques 2025-06-24  49   * @nbytes: Number of bytes to read
733b439375b494 Jorge Marques 2025-06-24  50   */
733b439375b494 Jorge Marques 2025-06-24  51  static inline void i3c_readl_fifo(const void __iomem *addr, void *buf,
733b439375b494 Jorge Marques 2025-06-24  52  				  int nbytes)
733b439375b494 Jorge Marques 2025-06-24  53  {
733b439375b494 Jorge Marques 2025-06-24 @54  	readsl(addr, buf, nbytes / 4);
733b439375b494 Jorge Marques 2025-06-24  55  	if (nbytes & 3) {
733b439375b494 Jorge Marques 2025-06-24  56  		u32 tmp;
733b439375b494 Jorge Marques 2025-06-24  57  
733b439375b494 Jorge Marques 2025-06-24  58  		tmp = readl(addr);
733b439375b494 Jorge Marques 2025-06-24  59  		memcpy(buf + (nbytes & ~3), &tmp, nbytes & 3);
733b439375b494 Jorge Marques 2025-06-24  60  	}
733b439375b494 Jorge Marques 2025-06-24  61  }
733b439375b494 Jorge Marques 2025-06-24  62  

:::::: The code at line 54 was first introduced by commit
:::::: 733b439375b494e8a6950ab47d18a4b615b73cb3 i3c: master: Add inline i3c_readl_fifo() and i3c_writel_fifo()

:::::: TO: Jorge Marques <jorge.marques@analog.com>
:::::: CC: Alexandre Belloni <alexandre.belloni@bootlin.com>

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

^ permalink raw reply	[flat|nested] 5+ messages in thread

* drivers/i3c/internals.h:54:9: error: passing 'const void *' to parameter of type 'void *' discards qualifiers
@ 2025-09-21 15:54 kernel test robot
  2025-09-21 21:48 ` Alexandre Belloni
  0 siblings, 1 reply; 5+ messages in thread
From: kernel test robot @ 2025-09-21 15:54 UTC (permalink / raw)
  To: Wolfram Sang
  Cc: llvm, oe-kbuild-all, linux-kernel, Alexandre Belloni, Frank Li

Hi Wolfram,

FYI, the error/warning still remains.

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head:   f975f08c2e899ae2484407d7bba6bb7f8b6d9d40
commit: 3b661ca549b9e5bb11d0bc97ada6110aac3282d2 i3c: add missing include to internal header
date:   8 weeks ago
config: sparc64-randconfig-001-20250921 (https://download.01.org/0day-ci/archive/20250921/202509212320.yCuqvnVn-lkp@intel.com/config)
compiler: clang version 22.0.0git (https://github.com/llvm/llvm-project 7c861bcedf61607b6c087380ac711eb7ff918ca6)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20250921/202509212320.yCuqvnVn-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/202509212320.yCuqvnVn-lkp@intel.com/

All errors (new ones prefixed by >>):

   In file included from drivers/i3c/master.c:21:
>> drivers/i3c/internals.h:54:9: error: passing 'const void *' to parameter of type 'void *' discards qualifiers [-Werror,-Wincompatible-pointer-types-discards-qualifiers]
      54 |         readsl(addr, buf, nbytes / 4);
         |                ^~~~
   arch/sparc/include/asm/io_64.h:265:41: note: passing argument to parameter 'port' here
     265 | static inline void readsl(void __iomem *port, void *buf, unsigned long count)
         |                                         ^
   1 error generated.


vim +54 drivers/i3c/internals.h

733b439375b494 Jorge Marques 2025-06-24  44  
733b439375b494 Jorge Marques 2025-06-24  45  /**
733b439375b494 Jorge Marques 2025-06-24  46   * i3c_readl_fifo - Read data buffer from 32bit FIFO
733b439375b494 Jorge Marques 2025-06-24  47   * @addr: FIFO Address to read from
733b439375b494 Jorge Marques 2025-06-24  48   * @buf: Pointer to the buffer to store read bytes
733b439375b494 Jorge Marques 2025-06-24  49   * @nbytes: Number of bytes to read
733b439375b494 Jorge Marques 2025-06-24  50   */
733b439375b494 Jorge Marques 2025-06-24  51  static inline void i3c_readl_fifo(const void __iomem *addr, void *buf,
733b439375b494 Jorge Marques 2025-06-24  52  				  int nbytes)
733b439375b494 Jorge Marques 2025-06-24  53  {
733b439375b494 Jorge Marques 2025-06-24 @54  	readsl(addr, buf, nbytes / 4);
733b439375b494 Jorge Marques 2025-06-24  55  	if (nbytes & 3) {
733b439375b494 Jorge Marques 2025-06-24  56  		u32 tmp;
733b439375b494 Jorge Marques 2025-06-24  57  
733b439375b494 Jorge Marques 2025-06-24  58  		tmp = readl(addr);
733b439375b494 Jorge Marques 2025-06-24  59  		memcpy(buf + (nbytes & ~3), &tmp, nbytes & 3);
733b439375b494 Jorge Marques 2025-06-24  60  	}
733b439375b494 Jorge Marques 2025-06-24  61  }
733b439375b494 Jorge Marques 2025-06-24  62  

:::::: The code at line 54 was first introduced by commit
:::::: 733b439375b494e8a6950ab47d18a4b615b73cb3 i3c: master: Add inline i3c_readl_fifo() and i3c_writel_fifo()

:::::: TO: Jorge Marques <jorge.marques@analog.com>
:::::: CC: Alexandre Belloni <alexandre.belloni@bootlin.com>

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

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: drivers/i3c/internals.h:54:9: error: passing 'const void *' to parameter of type 'void *' discards qualifiers
  2025-09-21 15:54 drivers/i3c/internals.h:54:9: error: passing 'const void *' to parameter of type 'void *' discards qualifiers kernel test robot
@ 2025-09-21 21:48 ` Alexandre Belloni
  2025-09-22  0:17   ` Philip Li
  0 siblings, 1 reply; 5+ messages in thread
From: Alexandre Belloni @ 2025-09-21 21:48 UTC (permalink / raw)
  To: kernel test robot
  Cc: Wolfram Sang, llvm, oe-kbuild-all, linux-kernel, Frank Li

Hello,

On 21/09/2025 23:54:32+0800, kernel test robot wrote:
> Hi Wolfram,
> 
> FYI, the error/warning still remains.
> 

As replied multiple times, the error is in the sparc64 code, not i3c.

> tree:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
> head:   f975f08c2e899ae2484407d7bba6bb7f8b6d9d40
> commit: 3b661ca549b9e5bb11d0bc97ada6110aac3282d2 i3c: add missing include to internal header
> date:   8 weeks ago
> config: sparc64-randconfig-001-20250921 (https://download.01.org/0day-ci/archive/20250921/202509212320.yCuqvnVn-lkp@intel.com/config)
> compiler: clang version 22.0.0git (https://github.com/llvm/llvm-project 7c861bcedf61607b6c087380ac711eb7ff918ca6)
> reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20250921/202509212320.yCuqvnVn-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/202509212320.yCuqvnVn-lkp@intel.com/
> 
> All errors (new ones prefixed by >>):
> 
>    In file included from drivers/i3c/master.c:21:
> >> drivers/i3c/internals.h:54:9: error: passing 'const void *' to parameter of type 'void *' discards qualifiers [-Werror,-Wincompatible-pointer-types-discards-qualifiers]
>       54 |         readsl(addr, buf, nbytes / 4);
>          |                ^~~~
>    arch/sparc/include/asm/io_64.h:265:41: note: passing argument to parameter 'port' here
>      265 | static inline void readsl(void __iomem *port, void *buf, unsigned long count)
>          |                                         ^
>    1 error generated.
> 
> 
> vim +54 drivers/i3c/internals.h
> 
> 733b439375b494 Jorge Marques 2025-06-24  44  
> 733b439375b494 Jorge Marques 2025-06-24  45  /**
> 733b439375b494 Jorge Marques 2025-06-24  46   * i3c_readl_fifo - Read data buffer from 32bit FIFO
> 733b439375b494 Jorge Marques 2025-06-24  47   * @addr: FIFO Address to read from
> 733b439375b494 Jorge Marques 2025-06-24  48   * @buf: Pointer to the buffer to store read bytes
> 733b439375b494 Jorge Marques 2025-06-24  49   * @nbytes: Number of bytes to read
> 733b439375b494 Jorge Marques 2025-06-24  50   */
> 733b439375b494 Jorge Marques 2025-06-24  51  static inline void i3c_readl_fifo(const void __iomem *addr, void *buf,
> 733b439375b494 Jorge Marques 2025-06-24  52  				  int nbytes)
> 733b439375b494 Jorge Marques 2025-06-24  53  {
> 733b439375b494 Jorge Marques 2025-06-24 @54  	readsl(addr, buf, nbytes / 4);
> 733b439375b494 Jorge Marques 2025-06-24  55  	if (nbytes & 3) {
> 733b439375b494 Jorge Marques 2025-06-24  56  		u32 tmp;
> 733b439375b494 Jorge Marques 2025-06-24  57  
> 733b439375b494 Jorge Marques 2025-06-24  58  		tmp = readl(addr);
> 733b439375b494 Jorge Marques 2025-06-24  59  		memcpy(buf + (nbytes & ~3), &tmp, nbytes & 3);
> 733b439375b494 Jorge Marques 2025-06-24  60  	}
> 733b439375b494 Jorge Marques 2025-06-24  61  }
> 733b439375b494 Jorge Marques 2025-06-24  62  
> 
> :::::: The code at line 54 was first introduced by commit
> :::::: 733b439375b494e8a6950ab47d18a4b615b73cb3 i3c: master: Add inline i3c_readl_fifo() and i3c_writel_fifo()
> 
> :::::: TO: Jorge Marques <jorge.marques@analog.com>
> :::::: CC: Alexandre Belloni <alexandre.belloni@bootlin.com>
> 
> -- 
> 0-DAY CI Kernel Test Service
> https://github.com/intel/lkp-tests/wiki

-- 
Alexandre Belloni, co-owner and COO, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: drivers/i3c/internals.h:54:9: error: passing 'const void *' to parameter of type 'void *' discards qualifiers
  2025-09-21 21:48 ` Alexandre Belloni
@ 2025-09-22  0:17   ` Philip Li
  2025-09-22  6:31     ` Geert Uytterhoeven
  0 siblings, 1 reply; 5+ messages in thread
From: Philip Li @ 2025-09-22  0:17 UTC (permalink / raw)
  To: Alexandre Belloni
  Cc: kernel test robot, Wolfram Sang, llvm, oe-kbuild-all,
	linux-kernel, Frank Li

On Sun, Sep 21, 2025 at 11:48:05PM +0200, Alexandre Belloni wrote:
> Hello,
> 
> On 21/09/2025 23:54:32+0800, kernel test robot wrote:
> > Hi Wolfram,
> > 
> > FYI, the error/warning still remains.
> > 
> 
> As replied multiple times, the error is in the sparc64 code, not i3c.

Sorry about this, the bot will be configured to ignore this issue to
avoid further reports.

> 
> > tree:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
> > head:   f975f08c2e899ae2484407d7bba6bb7f8b6d9d40
> > commit: 3b661ca549b9e5bb11d0bc97ada6110aac3282d2 i3c: add missing include to internal header
> > date:   8 weeks ago
> > config: sparc64-randconfig-001-20250921 (https://download.01.org/0day-ci/archive/20250921/202509212320.yCuqvnVn-lkp@intel.com/config)
> > compiler: clang version 22.0.0git (https://github.com/llvm/llvm-project 7c861bcedf61607b6c087380ac711eb7ff918ca6)
> > reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20250921/202509212320.yCuqvnVn-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/202509212320.yCuqvnVn-lkp@intel.com/
> > 
> > All errors (new ones prefixed by >>):
> > 
> >    In file included from drivers/i3c/master.c:21:
> > >> drivers/i3c/internals.h:54:9: error: passing 'const void *' to parameter of type 'void *' discards qualifiers [-Werror,-Wincompatible-pointer-types-discards-qualifiers]
> >       54 |         readsl(addr, buf, nbytes / 4);
> >          |                ^~~~
> >    arch/sparc/include/asm/io_64.h:265:41: note: passing argument to parameter 'port' here
> >      265 | static inline void readsl(void __iomem *port, void *buf, unsigned long count)
> >          |                                         ^
> >    1 error generated.
> > 
> > 
> > vim +54 drivers/i3c/internals.h
> > 
> > 733b439375b494 Jorge Marques 2025-06-24  44  
> > 733b439375b494 Jorge Marques 2025-06-24  45  /**
> > 733b439375b494 Jorge Marques 2025-06-24  46   * i3c_readl_fifo - Read data buffer from 32bit FIFO
> > 733b439375b494 Jorge Marques 2025-06-24  47   * @addr: FIFO Address to read from
> > 733b439375b494 Jorge Marques 2025-06-24  48   * @buf: Pointer to the buffer to store read bytes
> > 733b439375b494 Jorge Marques 2025-06-24  49   * @nbytes: Number of bytes to read
> > 733b439375b494 Jorge Marques 2025-06-24  50   */
> > 733b439375b494 Jorge Marques 2025-06-24  51  static inline void i3c_readl_fifo(const void __iomem *addr, void *buf,
> > 733b439375b494 Jorge Marques 2025-06-24  52  				  int nbytes)
> > 733b439375b494 Jorge Marques 2025-06-24  53  {
> > 733b439375b494 Jorge Marques 2025-06-24 @54  	readsl(addr, buf, nbytes / 4);
> > 733b439375b494 Jorge Marques 2025-06-24  55  	if (nbytes & 3) {
> > 733b439375b494 Jorge Marques 2025-06-24  56  		u32 tmp;
> > 733b439375b494 Jorge Marques 2025-06-24  57  
> > 733b439375b494 Jorge Marques 2025-06-24  58  		tmp = readl(addr);
> > 733b439375b494 Jorge Marques 2025-06-24  59  		memcpy(buf + (nbytes & ~3), &tmp, nbytes & 3);
> > 733b439375b494 Jorge Marques 2025-06-24  60  	}
> > 733b439375b494 Jorge Marques 2025-06-24  61  }
> > 733b439375b494 Jorge Marques 2025-06-24  62  
> > 
> > :::::: The code at line 54 was first introduced by commit
> > :::::: 733b439375b494e8a6950ab47d18a4b615b73cb3 i3c: master: Add inline i3c_readl_fifo() and i3c_writel_fifo()
> > 
> > :::::: TO: Jorge Marques <jorge.marques@analog.com>
> > :::::: CC: Alexandre Belloni <alexandre.belloni@bootlin.com>
> > 
> > -- 
> > 0-DAY CI Kernel Test Service
> > https://github.com/intel/lkp-tests/wiki
> 
> -- 
> Alexandre Belloni, co-owner and COO, Bootlin
> Embedded Linux and Kernel engineering
> https://bootlin.com
> 

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: drivers/i3c/internals.h:54:9: error: passing 'const void *' to parameter of type 'void *' discards qualifiers
  2025-09-22  0:17   ` Philip Li
@ 2025-09-22  6:31     ` Geert Uytterhoeven
  0 siblings, 0 replies; 5+ messages in thread
From: Geert Uytterhoeven @ 2025-09-22  6:31 UTC (permalink / raw)
  To: Philip Li
  Cc: Alexandre Belloni, kernel test robot, Wolfram Sang, llvm,
	oe-kbuild-all, linux-kernel, Frank Li

On Mon, 22 Sept 2025 at 02:17, Philip Li <philip.li@intel.com> wrote:
> On Sun, Sep 21, 2025 at 11:48:05PM +0200, Alexandre Belloni wrote:
> > On 21/09/2025 23:54:32+0800, kernel test robot wrote:
> > > FYI, the error/warning still remains.
> >
> > As replied multiple times, the error is in the sparc64 code, not i3c.
>
> Sorry about this, the bot will be configured to ignore this issue to
> avoid further reports.

It is expected to be fixed shortly:
https://lore.kernel.org/all/fbb1a96c-d913-4bdf-b40c-c8981601bbf9@gaisler.com/

> > > tree:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
> > > head:   f975f08c2e899ae2484407d7bba6bb7f8b6d9d40
> > > commit: 3b661ca549b9e5bb11d0bc97ada6110aac3282d2 i3c: add missing include to internal header
> > > date:   8 weeks ago
> > > config: sparc64-randconfig-001-20250921 (https://download.01.org/0day-ci/archive/20250921/202509212320.yCuqvnVn-lkp@intel.com/config)
> > > compiler: clang version 22.0.0git (https://github.com/llvm/llvm-project 7c861bcedf61607b6c087380ac711eb7ff918ca6)
> > > reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20250921/202509212320.yCuqvnVn-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/202509212320.yCuqvnVn-lkp@intel.com/
> > >
> > > All errors (new ones prefixed by >>):
> > >
> > >    In file included from drivers/i3c/master.c:21:
> > > >> drivers/i3c/internals.h:54:9: error: passing 'const void *' to parameter of type 'void *' discards qualifiers [-Werror,-Wincompatible-pointer-types-discards-qualifiers]
> > >       54 |         readsl(addr, buf, nbytes / 4);
> > >          |                ^~~~
> > >    arch/sparc/include/asm/io_64.h:265:41: note: passing argument to parameter 'port' here
> > >      265 | static inline void readsl(void __iomem *port, void *buf, unsigned long count)
> > >          |                                         ^
> > >    1 error generated.


Gr{oetje,eeting}s,

                        Geert

-- 
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
                                -- Linus Torvalds

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2025-09-22  6:32 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-09-21 15:54 drivers/i3c/internals.h:54:9: error: passing 'const void *' to parameter of type 'void *' discards qualifiers kernel test robot
2025-09-21 21:48 ` Alexandre Belloni
2025-09-22  0:17   ` Philip Li
2025-09-22  6:31     ` Geert Uytterhoeven
  -- strict thread matches above, loose matches on Subject: below --
2025-08-06 20:40 kernel test robot

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox