diff mbox series

ACPI: PCC: make pcc_ctx static

Message ID 20220113161846.1932-1-jiapeng.chong@linux.alibaba.com
State New
Headers show
Series ACPI: PCC: make pcc_ctx static | expand

Commit Message

Jiapeng Chong Jan. 13, 2022, 4:18 p.m. UTC
This symbol is not used outside of acpi_pcc.c, so marks it static.

Fix the following sparse warning:

drivers/acpi/acpi_pcc.c:34:22: warning: symbol 'pcc_ctx' was not
declared. Should it be static?

Reported-by: Abaci Robot <abaci@linux.alibaba.com>
Signed-off-by: Jiapeng Chong <jiapeng.chong@linux.alibaba.com>
---
 drivers/acpi/acpi_pcc.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Sudeep Holla Jan. 14, 2022, 10:30 a.m. UTC | #1
On Fri, Jan 14, 2022 at 12:18:46AM +0800, Jiapeng Chong wrote:
> This symbol is not used outside of acpi_pcc.c, so marks it static.
> 
> Fix the following sparse warning:
> 
> drivers/acpi/acpi_pcc.c:34:22: warning: symbol 'pcc_ctx' was not
> declared. Should it be static?
> 
> Reported-by: Abaci Robot <abaci@linux.alibaba.com>

The fix is now already applied [1]
diff mbox series

Patch

diff --git a/drivers/acpi/acpi_pcc.c b/drivers/acpi/acpi_pcc.c
index 41e3ebd204ff..a12b55d81209 100644
--- a/drivers/acpi/acpi_pcc.c
+++ b/drivers/acpi/acpi_pcc.c
@@ -31,7 +31,7 @@  struct pcc_data {
 	struct acpi_pcc_info ctx;
 };
 
-struct acpi_pcc_info pcc_ctx;
+static struct acpi_pcc_info pcc_ctx;
 
 static void pcc_rx_callback(struct mbox_client *cl, void *m)
 {