2018-04-17 19:55:35

by kernel test robot

[permalink] [raw]
Subject: [spi:for-4.18 12/12] drivers/spi/spi-pxa2xx.c:914:5: sparse: symbol 'pxa2xx_spi_transfer_one' was not declared. Should it be static?

tree: https://git.kernel.org/pub/scm/linux/kernel/git/broonie/spi.git for-4.18
head: d5898e19c0d74cd41b9f5c8c8ea87e559c3fe0c1
commit: d5898e19c0d74cd41b9f5c8c8ea87e559c3fe0c1 [12/12] spi: pxa2xx: Use core message processing loop
reproduce:
# apt-get install sparse
git checkout d5898e19c0d74cd41b9f5c8c8ea87e559c3fe0c1
make ARCH=x86_64 allmodconfig
make C=1 CF=-D__CHECK_ENDIAN__


sparse warnings: (new ones prefixed by >>)

drivers/spi/spi-pxa2xx.c:877:16: sparse: expression using sizeof(void)
drivers/spi/spi-pxa2xx.c:877:16: sparse: expression using sizeof(void)
>> drivers/spi/spi-pxa2xx.c:914:5: sparse: symbol 'pxa2xx_spi_transfer_one' was not declared. Should it be static?
drivers/spi/spi-pxa2xx.c:1672:42: sparse: expression using sizeof(void)
drivers/spi/spi-pxa2xx.c:1672:42: sparse: expression using sizeof(void)

Please review and possibly fold the followup patch.

---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all Intel Corporation


2018-04-17 19:56:10

by kernel test robot

[permalink] [raw]
Subject: [RFC PATCH spi] spi: pxa2xx: pxa2xx_spi_transfer_one() can be static


Fixes: d5898e19c0d7 ("spi: pxa2xx: Use core message processing loop")
Signed-off-by: Fengguang Wu <[email protected]>
---
spi-pxa2xx.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/drivers/spi/spi-pxa2xx.c b/drivers/spi/spi-pxa2xx.c
index c852ea5..40f1346 100644
--- a/drivers/spi/spi-pxa2xx.c
+++ b/drivers/spi/spi-pxa2xx.c
@@ -911,9 +911,9 @@ static bool pxa2xx_spi_can_dma(struct spi_controller *master,
xfer->len >= chip->dma_burst_size;
}

-int pxa2xx_spi_transfer_one(struct spi_controller *master,
- struct spi_device *spi,
- struct spi_transfer *transfer)
+static int pxa2xx_spi_transfer_one(struct spi_controller *master,
+ struct spi_device *spi,
+ struct spi_transfer *transfer)
{
struct driver_data *drv_data = spi_controller_get_devdata(master);
struct spi_message *message = master->cur_msg;

2018-04-18 06:06:19

by Jarkko Nikula

[permalink] [raw]
Subject: Re: [RFC PATCH spi] spi: pxa2xx: pxa2xx_spi_transfer_one() can be static

On 04/17/18 22:53, kbuild test robot wrote:
>
> Fixes: d5898e19c0d7 ("spi: pxa2xx: Use core message processing loop")
> Signed-off-by: Fengguang Wu <[email protected]>
> ---
> spi-pxa2xx.c | 6 +++---
> 1 file changed, 3 insertions(+), 3 deletions(-)
>
> diff --git a/drivers/spi/spi-pxa2xx.c b/drivers/spi/spi-pxa2xx.c
> index c852ea5..40f1346 100644
> --- a/drivers/spi/spi-pxa2xx.c
> +++ b/drivers/spi/spi-pxa2xx.c
> @@ -911,9 +911,9 @@ static bool pxa2xx_spi_can_dma(struct spi_controller *master,
> xfer->len >= chip->dma_burst_size;
> }
>
> -int pxa2xx_spi_transfer_one(struct spi_controller *master,
> - struct spi_device *spi,
> - struct spi_transfer *transfer)
> +static int pxa2xx_spi_transfer_one(struct spi_controller *master,
> + struct spi_device *spi,
> + struct spi_transfer *transfer)

Thanks Fengguang. I don't understand how I managed to drop "static"
while doing manual s/pump_transfers/pxa2xx_spi_transfer_one/ :-)

Reviewed-by: Jarkko Nikula <[email protected]>

2018-04-18 11:43:13

by Mark Brown

[permalink] [raw]
Subject: Applied "spi: pxa2xx: pxa2xx_spi_transfer_one() can be static" to the spi tree

The patch

spi: pxa2xx: pxa2xx_spi_transfer_one() can be static

has been applied to the spi tree at

https://git.kernel.org/pub/scm/linux/kernel/git/broonie/spi.git

All being well this means that it will be integrated into the linux-next
tree (usually sometime in the next 24 hours) and sent to Linus during
the next merge window (or sooner if it is a bug fix), however if
problems are discovered then the patch may be dropped or reverted.

You may get further e-mails resulting from automated or manual testing
and review of the tree, please engage with people reporting problems and
send followup patches addressing any issues that are reported if needed.

If any updates are required or you are submitting further changes they
should be sent as incremental updates against current git, existing
patches will not be replaced.

Please add any relevant lists and maintainers to the CCs when replying
to this mail.

Thanks,
Mark

From 71293a60e38f44b1d18c14803f0dd2744f6b9a12 Mon Sep 17 00:00:00 2001
From: kbuild test robot <[email protected]>
Date: Wed, 18 Apr 2018 03:53:23 +0800
Subject: [PATCH] spi: pxa2xx: pxa2xx_spi_transfer_one() can be static

Fixes: d5898e19c0d7 ("spi: pxa2xx: Use core message processing loop")
Signed-off-by: Fengguang Wu <[email protected]>
Reviewed-by: Jarkko Nikula <[email protected]>
Signed-off-by: Mark Brown <[email protected]>
---
drivers/spi/spi-pxa2xx.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/drivers/spi/spi-pxa2xx.c b/drivers/spi/spi-pxa2xx.c
index c852ea5c28c6..40f1346b8188 100644
--- a/drivers/spi/spi-pxa2xx.c
+++ b/drivers/spi/spi-pxa2xx.c
@@ -911,9 +911,9 @@ static bool pxa2xx_spi_can_dma(struct spi_controller *master,
xfer->len >= chip->dma_burst_size;
}

-int pxa2xx_spi_transfer_one(struct spi_controller *master,
- struct spi_device *spi,
- struct spi_transfer *transfer)
+static int pxa2xx_spi_transfer_one(struct spi_controller *master,
+ struct spi_device *spi,
+ struct spi_transfer *transfer)
{
struct driver_data *drv_data = spi_controller_get_devdata(master);
struct spi_message *message = master->cur_msg;
--
2.17.0