Re: [spi:for-5.3 41/41] drivers/spi/spi-synquacer.c:153:3: error: implicit declaration of function 'readsb'; did you mean 'readb'?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Jun 4, 2019 at 6:59 PM kbuild test robot <lkp@xxxxxxxxx> wrote:
>
> tree:   https://git.kernel.org/pub/scm/linux/kernel/git/broonie/spi.git for-5.3
> head:   b0823ee35cf9bc6b9a5403c12f12bd3e0b490045
> commit: b0823ee35cf9bc6b9a5403c12f12bd3e0b490045 [41/41] spi: Add spi driver for Socionext SynQuacer platform
> config: alpha-allyesconfig (attached as .config)
> compiler: alpha-linux-gcc (GCC) 7.4.0
> reproduce:
>         wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
>         chmod +x ~/bin/make.cross
>         git checkout b0823ee35cf9bc6b9a5403c12f12bd3e0b490045
>         # save the attached .config to linux build tree
>         GCC_VERSION=7.4.0 make.cross ARCH=alpha
>

It seems false positive.
kbuild bot has to be fixed,

> If you fix the issue, kindly add following tag
> Reported-by: kbuild test robot <lkp@xxxxxxxxx>
>
> All errors (new ones prefixed by >>):
>
>    drivers/spi/spi-synquacer.c: In function 'read_fifo':
> >> drivers/spi/spi-synquacer.c:153:3: error: implicit declaration of function 'readsb'; did you mean 'readb'? [-Werror=implicit-function-declaration]
>       readsb(sspi->regs + SYNQUACER_HSSPI_REG_RX_FIFO, buf, len);
>       ^~~~~~
>       readb
> >> drivers/spi/spi-synquacer.c:160:3: error: implicit declaration of function 'readsw'; did you mean 'readw'? [-Werror=implicit-function-declaration]
>       readsw(sspi->regs + SYNQUACER_HSSPI_REG_RX_FIFO, buf, len);
>       ^~~~~~
>       readw
> >> drivers/spi/spi-synquacer.c:169:3: error: implicit declaration of function 'readsl'; did you mean 'readl'? [-Werror=implicit-function-declaration]
>       readsl(sspi->regs + SYNQUACER_HSSPI_REG_RX_FIFO, buf, len);
>       ^~~~~~
>       readl
>    drivers/spi/spi-synquacer.c: In function 'write_fifo':
> >> drivers/spi/spi-synquacer.c:194:3: error: implicit declaration of function 'writesb'; did you mean 'writeb'? [-Werror=implicit-function-declaration]
>       writesb(sspi->regs + SYNQUACER_HSSPI_REG_TX_FIFO, buf, len);
>       ^~~~~~~
>       writeb
> >> drivers/spi/spi-synquacer.c:201:3: error: implicit declaration of function 'writesw'; did you mean 'writew'? [-Werror=implicit-function-declaration]
>       writesw(sspi->regs + SYNQUACER_HSSPI_REG_TX_FIFO, buf, len);
>       ^~~~~~~
>       writew
> >> drivers/spi/spi-synquacer.c:210:3: error: implicit declaration of function 'writesl'; did you mean 'writel'? [-Werror=implicit-function-declaration]
>       writesl(sspi->regs + SYNQUACER_HSSPI_REG_TX_FIFO, buf, len);
>       ^~~~~~~
>       writel
>    cc1: some warnings being treated as errors
>
> vim +153 drivers/spi/spi-synquacer.c
>
>    140
>    141  static int read_fifo(struct synquacer_spi *sspi)
>    142  {
>    143          u32 len = readl(sspi->regs + SYNQUACER_HSSPI_REG_DMSTATUS);
>    144
>    145          len = (len >> SYNQUACER_HSSPI_DMSTATUS_RX_DATA_SHIFT) &
>    146                 SYNQUACER_HSSPI_DMSTATUS_RX_DATA_MASK;
>    147          len = min(len, sspi->rx_words);
>    148
>    149          switch (sspi->bpw) {
>    150          case 8: {
>    151                  u8 *buf = sspi->rx_buf;
>    152
>  > 153                  readsb(sspi->regs + SYNQUACER_HSSPI_REG_RX_FIFO, buf, len);
>    154                  sspi->rx_buf = buf + len;
>    155                  break;
>    156          }
>    157          case 16: {
>    158                  u16 *buf = sspi->rx_buf;
>    159
>  > 160                  readsw(sspi->regs + SYNQUACER_HSSPI_REG_RX_FIFO, buf, len);
>    161                  sspi->rx_buf = buf + len;
>    162                  break;
>    163          }
>    164          case 24:
>    165                  /* fallthrough, should use 32-bits access */
>    166          case 32: {
>    167                  u32 *buf = sspi->rx_buf;
>    168
>  > 169                  readsl(sspi->regs + SYNQUACER_HSSPI_REG_RX_FIFO, buf, len);
>    170                  sspi->rx_buf = buf + len;
>    171                  break;
>    172          }
>    173          default:
>    174                  return -EINVAL;
>    175          }
>    176
>    177          sspi->rx_words -= len;
>    178          return 0;
>    179  }
>    180
>    181  static int write_fifo(struct synquacer_spi *sspi)
>    182  {
>    183          u32 len = readl(sspi->regs + SYNQUACER_HSSPI_REG_DMSTATUS);
>    184
>    185          len = (len >> SYNQUACER_HSSPI_DMSTATUS_TX_DATA_SHIFT) &
>    186                 SYNQUACER_HSSPI_DMSTATUS_TX_DATA_MASK;
>    187          len = min(SYNQUACER_HSSPI_FIFO_DEPTH - len,
>    188                      sspi->tx_words);
>    189
>    190          switch (sspi->bpw) {
>    191          case 8: {
>    192                  const u8 *buf = sspi->tx_buf;
>    193
>  > 194                  writesb(sspi->regs + SYNQUACER_HSSPI_REG_TX_FIFO, buf, len);
>    195                  sspi->tx_buf = buf + len;
>    196                  break;
>    197          }
>    198          case 16: {
>    199                  const u16 *buf = sspi->tx_buf;
>    200
>  > 201                  writesw(sspi->regs + SYNQUACER_HSSPI_REG_TX_FIFO, buf, len);
>    202                  sspi->tx_buf = buf + len;
>    203                  break;
>    204          }
>    205          case 24:
>    206                  /* fallthrough, should use 32-bits access */
>    207          case 32: {
>    208                  const u32 *buf = sspi->tx_buf;
>    209
>  > 210                  writesl(sspi->regs + SYNQUACER_HSSPI_REG_TX_FIFO, buf, len);
>    211                  sspi->tx_buf = buf + len;
>    212                  break;
>    213          }
>    214          default:
>    215                  return -EINVAL;
>    216          }
>    217
>    218          sspi->tx_words -= len;
>    219          return 0;
>    220  }
>    221
>
> ---
> 0-DAY kernel test infrastructure                Open Source Technology Center
> https://lists.01.org/pipermail/kbuild-all                   Intel Corporation



-- 
With Best Regards,
Andy Shevchenko



[Index of Archives]     [Linux Kernel]     [Linux ARM (vger)]     [Linux ARM MSM]     [Linux Omap]     [Linux Arm]     [Linux Tegra]     [Fedora ARM]     [Linux for Samsung SOC]     [eCos]     [Linux Fastboot]     [Gcc Help]     [Git]     [DCCP]     [IETF Announce]     [Security]     [Linux MIPS]     [Yosemite Campsites]

  Powered by Linux