diff mbox series

[2/2] platform/x86/intel/pmc: Mark lnl_d3_fixup() and lnl_resume() as static

Message ID 20231222-intel-pmc-missing-prototypes-v1-2-3f0d47377d4c@kernel.org (mailing list archive)
State Accepted, archived
Headers show
Series platform/x86/intel/pmc: Fix recent instances of -Wmissing-prototypes | expand

Commit Message

Nathan Chancellor Dec. 22, 2023, 6:27 p.m. UTC
With -Wmissing-prototypes, there are two instances flagged with no
prototypes:

  drivers/platform/x86/intel/pmc/lnl.c:503:6: error: no previous prototype for 'lnl_d3_fixup' [-Werror=missing-prototypes]
    503 | void lnl_d3_fixup(void)
        |      ^~~~~~~~~~~~
  drivers/platform/x86/intel/pmc/lnl.c:509:5: error: no previous prototype for 'lnl_resume' [-Werror=missing-prototypes]
    509 | int lnl_resume(struct pmc_dev *pmcdev)
        |     ^~~~~~~~~~
  cc1: all warnings being treated as errors

These functions are not used outside of this translation unit, so mark
them as static to fix the warning.

Fixes: 119652b855e6 ("platform/x86/intel/pmc: Add Lunar Lake M support to intel_pmc_core driver")
Reported-by: Stephen Rothwell <sfr@canb.auug.org.au>
Closes: https://lore.kernel.org/all/20231222135412.6bd796cc@canb.auug.org.au/
Signed-off-by: Nathan Chancellor <nathan@kernel.org>
---
 drivers/platform/x86/intel/pmc/lnl.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
diff mbox series

Patch

diff --git a/drivers/platform/x86/intel/pmc/lnl.c b/drivers/platform/x86/intel/pmc/lnl.c
index 88b35931f5df..b5de569e6662 100644
--- a/drivers/platform/x86/intel/pmc/lnl.c
+++ b/drivers/platform/x86/intel/pmc/lnl.c
@@ -500,13 +500,13 @@  const struct pmc_reg_map lnl_socm_reg_map = {
  * Set power state of select devices that do not have drivers to D3
  * so that they do not block Package C entry.
  */
-void lnl_d3_fixup(void)
+static void lnl_d3_fixup(void)
 {
 	pmc_core_set_device_d3(LNL_IPU_PCI_DEV);
 	pmc_core_set_device_d3(LNL_NPU_PCI_DEV);
 }
 
-int lnl_resume(struct pmc_dev *pmcdev)
+static int lnl_resume(struct pmc_dev *pmcdev)
 {
 	lnl_d3_fixup();
 	return pmc_core_resume_common(pmcdev);