diff mbox series

[1/2] platform/x86: lenovo-yoga-tab2-pro-1380-fastcharger: Make symbol static

Message ID 20250304160639.4295-1-ilpo.jarvinen@linux.intel.com (mailing list archive)
State Accepted, archived
Headers show
Series [1/2] platform/x86: lenovo-yoga-tab2-pro-1380-fastcharger: Make symbol static | expand

Commit Message

Ilpo Järvinen March 4, 2025, 4:06 p.m. UTC
Sparse reports:

lenovo-yoga-tab2-pro-1380-fastcharger.c:222:29: warning: symbol
'yt2_1380_fc_serdev_driver' was not declared. Should it be static?

Fix that by making the symbol static.

Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
---
 drivers/platform/x86/lenovo-yoga-tab2-pro-1380-fastcharger.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)


base-commit: 432c2adb9e2f84f81c4b218acb07a2cd3dce64a9

Comments

Mario Limonciello March 4, 2025, 5:21 p.m. UTC | #1
On 3/4/2025 10:06, Ilpo Järvinen wrote:
> Sparse reports:
> 
> lenovo-yoga-tab2-pro-1380-fastcharger.c:222:29: warning: symbol
> 'yt2_1380_fc_serdev_driver' was not declared. Should it be static?
> 
> Fix that by making the symbol static.
> 
> Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>

Fixes: b2ed33e8d486a ("platform/x86: Add 
lenovo-yoga-tab2-pro-1380-fastcharger driver")
Reviewed-by: Mario Limonciello <mario.limonciello@amd.com>

> ---
>   drivers/platform/x86/lenovo-yoga-tab2-pro-1380-fastcharger.c | 2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/platform/x86/lenovo-yoga-tab2-pro-1380-fastcharger.c b/drivers/platform/x86/lenovo-yoga-tab2-pro-1380-fastcharger.c
> index a96b215cd2c5..25933cd018d1 100644
> --- a/drivers/platform/x86/lenovo-yoga-tab2-pro-1380-fastcharger.c
> +++ b/drivers/platform/x86/lenovo-yoga-tab2-pro-1380-fastcharger.c
> @@ -219,7 +219,7 @@ static int yt2_1380_fc_serdev_probe(struct serdev_device *serdev)
>   	return 0;
>   }
>   
> -struct serdev_device_driver yt2_1380_fc_serdev_driver = {
> +static struct serdev_device_driver yt2_1380_fc_serdev_driver = {
>   	.probe = yt2_1380_fc_serdev_probe,
>   	.driver = {
>   		.name = KBUILD_MODNAME,
> 
> base-commit: 432c2adb9e2f84f81c4b218acb07a2cd3dce64a9
Hans de Goede March 5, 2025, 11:22 a.m. UTC | #2
Hi Ilpo,

On 4-Mar-25 5:06 PM, Ilpo Järvinen wrote:
> Sparse reports:
> 
> lenovo-yoga-tab2-pro-1380-fastcharger.c:222:29: warning: symbol
> 'yt2_1380_fc_serdev_driver' was not declared. Should it be static?
> 
> Fix that by making the symbol static.
> 
> Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>

Thanks, patch looks good to me:

Reviewed-by: Hans de Goede <hdegoede@redhat.com>

Regards,

Hans



> ---
>  drivers/platform/x86/lenovo-yoga-tab2-pro-1380-fastcharger.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/platform/x86/lenovo-yoga-tab2-pro-1380-fastcharger.c b/drivers/platform/x86/lenovo-yoga-tab2-pro-1380-fastcharger.c
> index a96b215cd2c5..25933cd018d1 100644
> --- a/drivers/platform/x86/lenovo-yoga-tab2-pro-1380-fastcharger.c
> +++ b/drivers/platform/x86/lenovo-yoga-tab2-pro-1380-fastcharger.c
> @@ -219,7 +219,7 @@ static int yt2_1380_fc_serdev_probe(struct serdev_device *serdev)
>  	return 0;
>  }
>  
> -struct serdev_device_driver yt2_1380_fc_serdev_driver = {
> +static struct serdev_device_driver yt2_1380_fc_serdev_driver = {
>  	.probe = yt2_1380_fc_serdev_probe,
>  	.driver = {
>  		.name = KBUILD_MODNAME,
> 
> base-commit: 432c2adb9e2f84f81c4b218acb07a2cd3dce64a9
Ilpo Järvinen March 5, 2025, 1:09 p.m. UTC | #3
On Tue, 04 Mar 2025 18:06:38 +0200, Ilpo Järvinen wrote:

> Sparse reports:
> 
> lenovo-yoga-tab2-pro-1380-fastcharger.c:222:29: warning: symbol
> 'yt2_1380_fc_serdev_driver' was not declared. Should it be static?
> 
> Fix that by making the symbol static.
> 
> [...]


Thank you for your contribution, it has been applied to my local
review-ilpo-next branch. Note it will show up in the public
platform-drivers-x86/review-ilpo-next branch only once I've pushed my
local branch there, which might take a while.

The list of commits applied:
[1/2] platform/x86: lenovo-yoga-tab2-pro-1380-fastcharger: Make symbol static
      commit: 886ca11a0c70efe5627a18557062e8a44370d78f
[2/2] platform/x86: dell-uart-backlight: Make dell_uart_bl_serdev_driver static
      commit: 4878e0b14c3e31a87ab147bd2dae443394cb5a2c

--
 i.
diff mbox series

Patch

diff --git a/drivers/platform/x86/lenovo-yoga-tab2-pro-1380-fastcharger.c b/drivers/platform/x86/lenovo-yoga-tab2-pro-1380-fastcharger.c
index a96b215cd2c5..25933cd018d1 100644
--- a/drivers/platform/x86/lenovo-yoga-tab2-pro-1380-fastcharger.c
+++ b/drivers/platform/x86/lenovo-yoga-tab2-pro-1380-fastcharger.c
@@ -219,7 +219,7 @@  static int yt2_1380_fc_serdev_probe(struct serdev_device *serdev)
 	return 0;
 }
 
-struct serdev_device_driver yt2_1380_fc_serdev_driver = {
+static struct serdev_device_driver yt2_1380_fc_serdev_driver = {
 	.probe = yt2_1380_fc_serdev_probe,
 	.driver = {
 		.name = KBUILD_MODNAME,