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>] [day] [month] [year] [list]
Date:   Wed, 22 Sep 2021 17:19:10 -0000
From:   "tip-bot2 for Randy Dunlap" <tip-bot2@...utronix.de>
To:     linux-tip-commits@...r.kernel.org
Cc:     Arnd Bergmann <arnd@...db.de>,
        Randy Dunlap <rdunlap@...radead.org>,
        Borislav Petkov <bp@...e.de>,
        Guenter Roeck <linux@...ck-us.net>, pali@...nel.org,
        x86@...nel.org, linux-kernel@...r.kernel.org
Subject: [tip: x86/misc] x86/Kconfig: Fix an unused variable error in dell-smm-hwmon

The following commit has been merged into the x86/misc branch of tip:

Commit-ID:     64c76a84337a5678009155fafe98c5cd8ec673f0
Gitweb:        https://git.kernel.org/tip/64c76a84337a5678009155fafe98c5cd8ec673f0
Author:        Randy Dunlap <rdunlap@...radead.org>
AuthorDate:    Fri, 10 Sep 2021 00:19:21 -07:00
Committer:     Borislav Petkov <bp@...e.de>
CommitterDate: Wed, 22 Sep 2021 19:09:56 +02:00

x86/Kconfig: Fix an unused variable error in dell-smm-hwmon

When CONFIG_PROC_FS is not set, there is a build warning (turned
into an error):

  ../drivers/hwmon/dell-smm-hwmon.c: In function 'i8k_init_procfs':
  ../drivers/hwmon/dell-smm-hwmon.c:624:24: error: unused variable 'data' [-Werror=unused-variable]
    struct dell_smm_data *data = dev_get_drvdata(dev);

Make I8K depend on PROC_FS and HWMON (instead of selecting HWMON -- it
is strongly preferred to not select entire subsystems).

Build tested in all possible combinations of SENSORS_DELL_SMM, I8K, and
PROC_FS.

Fixes: 039ae58503f3 ("hwmon: Allow to compile dell-smm-hwmon driver without /proc/i8k")
Reported-by: Arnd Bergmann <arnd@...db.de>
Signed-off-by: Randy Dunlap <rdunlap@...radead.org>
Signed-off-by: Borislav Petkov <bp@...e.de>
Reviewed-by: Arnd Bergmann <arnd@...db.de>
Acked-by: Guenter Roeck <linux@...ck-us.net>
Acked-by: Pali Rohár <pali@...nel.org>
Link: https://lkml.kernel.org/r/20210910071921.16777-1-rdunlap@infradead.org
---
 arch/x86/Kconfig | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/arch/x86/Kconfig b/arch/x86/Kconfig
index dad7f85..e5ba8af 100644
--- a/arch/x86/Kconfig
+++ b/arch/x86/Kconfig
@@ -1256,7 +1256,8 @@ config TOSHIBA
 
 config I8K
 	tristate "Dell i8k legacy laptop support"
-	select HWMON
+	depends on HWMON
+	depends on PROC_FS
 	select SENSORS_DELL_SMM
 	help
 	  This option enables legacy /proc/i8k userspace interface in hwmon

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ