diff mbox series

[-next] gpiolib: of: Make of_gpio_spi_cs_get_count static

Message ID 20191129085336.15968-1-yuehaibing@huawei.com
State New
Headers show
Series [-next] gpiolib: of: Make of_gpio_spi_cs_get_count static | expand

Commit Message

YueHaibing Nov. 29, 2019, 8:53 a.m. UTC
Fix sparse warning:

drivers/gpio/gpiolib-of.c:35:5: warning: symbol 'of_gpio_spi_cs_get_count' was not declared. Should it be static?

Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: YueHaibing <yuehaibing@huawei.com>
---
 drivers/gpio/gpiolib-of.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Linus Walleij Nov. 29, 2019, 9:46 a.m. UTC | #1
On Fri, Nov 29, 2019 at 9:53 AM YueHaibing <yuehaibing@huawei.com> wrote:

> Fix sparse warning:
>
> drivers/gpio/gpiolib-of.c:35:5: warning: symbol 'of_gpio_spi_cs_get_count' was not declared. Should it be static?
>
> Reported-by: Hulk Robot <hulkci@huawei.com>
> Signed-off-by: YueHaibing <yuehaibing@huawei.com>

Reviewed-by: Linus Walleij <linus.walleij@linaro.org>

Mark merged my patch causing this warning into the SPI tree,
would you mind resending it to him including my Reviewed-by tag
and a note to apply it to the SPI tree?

Yours,
Linus Walleij
YueHaibing Nov. 29, 2019, 9:53 a.m. UTC | #2
On 2019/11/29 17:46, Linus Walleij wrote:
> On Fri, Nov 29, 2019 at 9:53 AM YueHaibing <yuehaibing@huawei.com> wrote:
> 
>> Fix sparse warning:
>>
>> drivers/gpio/gpiolib-of.c:35:5: warning: symbol 'of_gpio_spi_cs_get_count' was not declared. Should it be static?
>>
>> Reported-by: Hulk Robot <hulkci@huawei.com>
>> Signed-off-by: YueHaibing <yuehaibing@huawei.com>
> 
> Reviewed-by: Linus Walleij <linus.walleij@linaro.org>
> 
> Mark merged my patch causing this warning into the SPI tree,
> would you mind resending it to him including my Reviewed-by tag
> and a note to apply it to the SPI tree?

Ok, will resend it.
> 
> Yours,
> Linus Walleij
> 
>
diff mbox series

Patch

diff --git a/drivers/gpio/gpiolib-of.c b/drivers/gpio/gpiolib-of.c
index 610c6622f62d..b696e4598a24 100644
--- a/drivers/gpio/gpiolib-of.c
+++ b/drivers/gpio/gpiolib-of.c
@@ -32,7 +32,7 @@ 
  * the counting of "cs-gpios" to count "gpios" transparent to the
  * driver.
  */
-int of_gpio_spi_cs_get_count(struct device *dev, const char *con_id)
+static int of_gpio_spi_cs_get_count(struct device *dev, const char *con_id)
 {
 	struct device_node *np = dev->of_node;