lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <20241228090852.2049321-1-carlos.song@nxp.com>
Date: Sat, 28 Dec 2024 17:08:52 +0800
From: Carlos Song <carlos.song@....com>
To: frank.li@....com,
	aisheng.dong@....com,
	andi.shyti@...nel.org,
	shawnguo@...nel.org,
	s.hauer@...gutronix.de,
	kernel@...gutronix.de,
	festevam@...il.com
Cc: linux-i2c@...r.kernel.org,
	imx@...ts.linux.dev,
	linux-arm-kernel@...ts.infradead.org,
	linux-kernel@...r.kernel.org,
	Carlos Song <carlos.song@....com>,
	kernel test robot <lkp@...el.com>
Subject: [PATCH] i2c: imx-lpi2c: fix build warning "function defined but not used"

lpi2c_resume_noirq() and lpi2c_suspend_noirq() are defined but it maybe
unused, so should add __maybe_unused to both functions to avoid build
warning.

Fixes: fa89723f7a78 ("i2c: imx-lpi2c: add target mode support")
Reported-by: kernel test robot <lkp@...el.com>
Closes: https://lore.kernel.org/oe-kbuild-all/202412280835.LRAV3z0g-lkp@intel.com/
Signed-off-by: Carlos Song <carlos.song@....com>
---
 drivers/i2c/busses/i2c-imx-lpi2c.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/i2c/busses/i2c-imx-lpi2c.c b/drivers/i2c/busses/i2c-imx-lpi2c.c
index 02361274fcaa..dc25d7dfe1ab 100644
--- a/drivers/i2c/busses/i2c-imx-lpi2c.c
+++ b/drivers/i2c/busses/i2c-imx-lpi2c.c
@@ -1422,12 +1422,12 @@ static int __maybe_unused lpi2c_runtime_resume(struct device *dev)
 	return 0;
 }
 
-static int lpi2c_suspend_noirq(struct device *dev)
+static int __maybe_unused lpi2c_suspend_noirq(struct device *dev)
 {
 	return pm_runtime_force_suspend(dev);
 }
 
-static int lpi2c_resume_noirq(struct device *dev)
+static int __maybe_unused lpi2c_resume_noirq(struct device *dev)
 {
 	struct lpi2c_imx_struct *lpi2c_imx = dev_get_drvdata(dev);
 	int ret;
-- 
2.34.1


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ