All of lore.kernel.org
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: Miquel Raynal <miquel.raynal@bootlin.com>
Cc: llvm@lists.linux.dev, oe-kbuild-all@lists.linux.dev
Subject: [mtd:mtd/spi-mem-cont-read 4/6] drivers/spi/spi-intel.c:817:37: error: incompatible pointer types passing 'struct spi_mem_op **' to parameter of type 'const struct spi_mem_op *'; remove &
Date: Thu, 30 Apr 2026 07:06:20 +0800	[thread overview]
Message-ID: <202604300653.PchLEPCg-lkp@intel.com> (raw)

Hi Miquel,

FYI, the error/warning was bisected to this commit, please ignore it if it's irrelevant.

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/mtd/linux.git mtd/spi-mem-cont-read
head:   6e3e2ce14a3c0a111736dc9140a3200363ab704f
commit: 56b2c08482734182d867bf853bce5233d78df796 [4/6] spi: spi-mem: Transform the read operation template
config: hexagon-randconfig-002-20260430 (https://download.01.org/0day-ci/archive/20260430/202604300653.PchLEPCg-lkp@intel.com/config)
compiler: clang version 23.0.0git (https://github.com/llvm/llvm-project 5bac06718f502014fade905512f1d26d578a18f3)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20260430/202604300653.PchLEPCg-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/202604300653.PchLEPCg-lkp@intel.com/

All errors (new ones prefixed by >>):

>> drivers/spi/spi-intel.c:817:37: error: incompatible pointer types passing 'struct spi_mem_op **' to parameter of type 'const struct spi_mem_op *'; remove & [-Wincompatible-pointer-types]
     817 |         iop = intel_spi_match_mem_op(ispi, &desc->info.op_tmpl);
         |                                            ^~~~~~~~~~~~~~~~~~~
   drivers/spi/spi-intel.c:744:73: note: passing argument to parameter 'op' here
     744 | intel_spi_match_mem_op(struct intel_spi *ispi, const struct spi_mem_op *op)
         |                                                                         ^
   drivers/spi/spi-intel.c:830:20: error: initializing 'struct spi_mem_op' with an expression of incompatible type 'struct spi_mem_op *'; dereference with *
     830 |         struct spi_mem_op op = desc->info.op_tmpl;
         |                           ^    ~~~~~~~~~~~~~~~~~~
         |                                *
   drivers/spi/spi-intel.c:847:20: error: initializing 'struct spi_mem_op' with an expression of incompatible type 'struct spi_mem_op *'; dereference with *
     847 |         struct spi_mem_op op = desc->info.op_tmpl;
         |                           ^    ~~~~~~~~~~~~~~~~~~
         |                                *
   3 errors generated.
--
   drivers/spi/spi-mxic.c:406:67: error: member reference type 'struct spi_mem_op *' is a pointer; did you mean to use '->'?
     406 |         writel(mxic_spi_prep_hc_cfg(desc->mem->spi, 0, desc->info.op_tmpl.data.swap16),
         |                                                        ~~~~~~~~~~~~~~~~~~^
         |                                                                          ->
>> drivers/spi/spi-mxic.c:409:34: error: incompatible pointer types passing 'struct spi_mem_op **' to parameter of type 'const struct spi_mem_op *'; remove & [-Wincompatible-pointer-types]
     409 |         writel(mxic_spi_mem_prep_op_cfg(&desc->info.op_tmpl, len),
         |                                         ^~~~~~~~~~~~~~~~~~~
   drivers/spi/spi-mxic.c:319:62: note: passing argument to parameter 'op' here
     319 | static u32 mxic_spi_mem_prep_op_cfg(const struct spi_mem_op *op,
         |                                                              ^
   drivers/spi/spi-mxic.c:414:38: error: member reference type 'struct spi_mem_op *' is a pointer; did you mean to use '->'?
     414 |         writel(LMODE_CMD0(desc->info.op_tmpl.cmd.opcode) |
         |                           ~~~~~~~~~~~~~~~~~~^
         |                                             ->
   drivers/spi/spi-mxic.c:103:25: note: expanded from macro 'LMODE_CMD0'
     103 | #define LMODE_CMD0(x)           (x)
         |                                  ^
   drivers/spi/spi-mxic.c:419:56: error: member reference type 'struct spi_mem_op *' is a pointer; did you mean to use '->'?
     419 |         if (mxic->ecc.use_pipelined_conf && desc->info.op_tmpl.data.ecc) {
         |                                             ~~~~~~~~~~~~~~~~~~^
         |                                                               ->
   include/linux/compiler.h:55:47: note: expanded from macro 'if'
      55 | #define if(cond, ...) if ( __trace_if_var( !!(cond , ## __VA_ARGS__) ) )
         |                                               ^~~~
   include/linux/compiler.h:57:52: note: expanded from macro '__trace_if_var'
      57 | #define __trace_if_var(cond) (__builtin_constant_p(cond) ? (cond) : __trace_if_value(cond))
         |                                                    ^~~~
   drivers/spi/spi-mxic.c:419:56: error: member reference type 'struct spi_mem_op *' is a pointer; did you mean to use '->'?
     419 |         if (mxic->ecc.use_pipelined_conf && desc->info.op_tmpl.data.ecc) {
         |                                             ~~~~~~~~~~~~~~~~~~^
         |                                                               ->
   include/linux/compiler.h:55:47: note: expanded from macro 'if'
      55 | #define if(cond, ...) if ( __trace_if_var( !!(cond , ## __VA_ARGS__) ) )
         |                                               ^~~~
   include/linux/compiler.h:57:61: note: expanded from macro '__trace_if_var'
      57 | #define __trace_if_var(cond) (__builtin_constant_p(cond) ? (cond) : __trace_if_value(cond))
         |                                                             ^~~~
   drivers/spi/spi-mxic.c:419:56: error: member reference type 'struct spi_mem_op *' is a pointer; did you mean to use '->'?
     419 |         if (mxic->ecc.use_pipelined_conf && desc->info.op_tmpl.data.ecc) {
         |                                             ~~~~~~~~~~~~~~~~~~^
         |                                                               ->
   include/linux/compiler.h:55:47: note: expanded from macro 'if'
      55 | #define if(cond, ...) if ( __trace_if_var( !!(cond , ## __VA_ARGS__) ) )
         |                                               ^~~~
   include/linux/compiler.h:57:86: note: expanded from macro '__trace_if_var'
      57 | #define __trace_if_var(cond) (__builtin_constant_p(cond) ? (cond) : __trace_if_value(cond))
         |                                                                                      ^~~~
   include/linux/compiler.h:68:3: note: expanded from macro '__trace_if_value'
      68 |         (cond) ?                                        \
         |          ^~~~
   drivers/spi/spi-mxic.c:451:67: error: member reference type 'struct spi_mem_op *' is a pointer; did you mean to use '->'?
     451 |         writel(mxic_spi_prep_hc_cfg(desc->mem->spi, 0, desc->info.op_tmpl.data.swap16),
         |                                                        ~~~~~~~~~~~~~~~~~~^
         |                                                                          ->
   drivers/spi/spi-mxic.c:454:34: error: incompatible pointer types passing 'struct spi_mem_op **' to parameter of type 'const struct spi_mem_op *'; remove & [-Wincompatible-pointer-types]
     454 |         writel(mxic_spi_mem_prep_op_cfg(&desc->info.op_tmpl, len),
         |                                         ^~~~~~~~~~~~~~~~~~~
   drivers/spi/spi-mxic.c:319:62: note: passing argument to parameter 'op' here
     319 | static u32 mxic_spi_mem_prep_op_cfg(const struct spi_mem_op *op,
         |                                                              ^
   drivers/spi/spi-mxic.c:459:38: error: member reference type 'struct spi_mem_op *' is a pointer; did you mean to use '->'?
     459 |         writel(LMODE_CMD0(desc->info.op_tmpl.cmd.opcode) |
         |                           ~~~~~~~~~~~~~~~~~~^
         |                                             ->
   drivers/spi/spi-mxic.c:103:25: note: expanded from macro 'LMODE_CMD0'
     103 | #define LMODE_CMD0(x)           (x)
         |                                  ^
   drivers/spi/spi-mxic.c:464:56: error: member reference type 'struct spi_mem_op *' is a pointer; did you mean to use '->'?
     464 |         if (mxic->ecc.use_pipelined_conf && desc->info.op_tmpl.data.ecc) {
         |                                             ~~~~~~~~~~~~~~~~~~^
         |                                                               ->
   include/linux/compiler.h:55:47: note: expanded from macro 'if'
      55 | #define if(cond, ...) if ( __trace_if_var( !!(cond , ## __VA_ARGS__) ) )
         |                                               ^~~~
   include/linux/compiler.h:57:52: note: expanded from macro '__trace_if_var'
      57 | #define __trace_if_var(cond) (__builtin_constant_p(cond) ? (cond) : __trace_if_value(cond))
         |                                                    ^~~~
   drivers/spi/spi-mxic.c:464:56: error: member reference type 'struct spi_mem_op *' is a pointer; did you mean to use '->'?
     464 |         if (mxic->ecc.use_pipelined_conf && desc->info.op_tmpl.data.ecc) {
         |                                             ~~~~~~~~~~~~~~~~~~^
         |                                                               ->
   include/linux/compiler.h:55:47: note: expanded from macro 'if'
      55 | #define if(cond, ...) if ( __trace_if_var( !!(cond , ## __VA_ARGS__) ) )
         |                                               ^~~~
   include/linux/compiler.h:57:61: note: expanded from macro '__trace_if_var'
      57 | #define __trace_if_var(cond) (__builtin_constant_p(cond) ? (cond) : __trace_if_value(cond))
         |                                                             ^~~~
   drivers/spi/spi-mxic.c:464:56: error: member reference type 'struct spi_mem_op *' is a pointer; did you mean to use '->'?
     464 |         if (mxic->ecc.use_pipelined_conf && desc->info.op_tmpl.data.ecc) {
         |                                             ~~~~~~~~~~~~~~~~~~^
         |                                                               ->
   include/linux/compiler.h:55:47: note: expanded from macro 'if'
      55 | #define if(cond, ...) if ( __trace_if_var( !!(cond , ## __VA_ARGS__) ) )
         |                                               ^~~~
   include/linux/compiler.h:57:86: note: expanded from macro '__trace_if_var'
      57 | #define __trace_if_var(cond) (__builtin_constant_p(cond) ? (cond) : __trace_if_value(cond))
         |                                                                                      ^~~~
   include/linux/compiler.h:68:3: note: expanded from macro '__trace_if_value'
      68 |         (cond) ?                                        \
         |          ^~~~
   drivers/spi/spi-mxic.c:512:43: error: incompatible pointer types passing 'struct spi_mem_op **' to parameter of type 'const struct spi_mem_op *'; remove & [-Wincompatible-pointer-types]
     512 |         if (!mxic_spi_mem_supports_op(desc->mem, &desc->info.op_tmpl))
         |                                                  ^~~~~~~~~~~~~~~~~~~
   include/linux/compiler.h:55:47: note: expanded from macro 'if'
      55 | #define if(cond, ...) if ( __trace_if_var( !!(cond , ## __VA_ARGS__) ) )


vim +817 drivers/spi/spi-intel.c

e23e5a05d1fd947 Mika Westerberg 2022-02-09  811  
c2b5a40c9e50651 Mika Westerberg 2022-04-20  812  static int intel_spi_dirmap_create(struct spi_mem_dirmap_desc *desc)
c2b5a40c9e50651 Mika Westerberg 2022-04-20  813  {
5fa0ade1851f776 Yang Yingliang  2023-08-07  814  	struct intel_spi *ispi = spi_controller_get_devdata(desc->mem->spi->controller);
c2b5a40c9e50651 Mika Westerberg 2022-04-20  815  	const struct intel_spi_mem_op *iop;
c2b5a40c9e50651 Mika Westerberg 2022-04-20  816  
c2b5a40c9e50651 Mika Westerberg 2022-04-20 @817  	iop = intel_spi_match_mem_op(ispi, &desc->info.op_tmpl);
c2b5a40c9e50651 Mika Westerberg 2022-04-20  818  	if (!iop)
c2b5a40c9e50651 Mika Westerberg 2022-04-20  819  		return -EOPNOTSUPP;
c2b5a40c9e50651 Mika Westerberg 2022-04-20  820  
c2b5a40c9e50651 Mika Westerberg 2022-04-20  821  	desc->priv = (void *)iop;
c2b5a40c9e50651 Mika Westerberg 2022-04-20  822  	return 0;
c2b5a40c9e50651 Mika Westerberg 2022-04-20  823  }
c2b5a40c9e50651 Mika Westerberg 2022-04-20  824  

:::::: The code at line 817 was first introduced by commit
:::::: c2b5a40c9e50651a29ee9d110f7ebc41b8720efa spi: intel: Implement dirmap hooks

:::::: TO: Mika Westerberg <mika.westerberg@linux.intel.com>
:::::: CC: Mark Brown <broonie@kernel.org>

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

                 reply	other threads:[~2026-04-29 23:07 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=202604300653.PchLEPCg-lkp@intel.com \
    --to=lkp@intel.com \
    --cc=llvm@lists.linux.dev \
    --cc=miquel.raynal@bootlin.com \
    --cc=oe-kbuild-all@lists.linux.dev \
    /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.