[PATCH linux dev-4.10] hwmon (occ): Fix kconfig and makefile

Joel Stanley joel at jms.id.au
Mon Jun 5 18:49:54 AEST 2017


The OCC driver was not buildable. Clean up the makefile and kconfig.

Signed-off-by: Joel Stanley <joel at jms.id.au>
---
 drivers/hwmon/Makefile     |  2 +-
 drivers/hwmon/occ/Kconfig  | 15 +--------------
 drivers/hwmon/occ/Makefile |  8 +-------
 3 files changed, 3 insertions(+), 22 deletions(-)

diff --git a/drivers/hwmon/Makefile b/drivers/hwmon/Makefile
index f03dd0a15933..2e803f56446e 100644
--- a/drivers/hwmon/Makefile
+++ b/drivers/hwmon/Makefile
@@ -46,6 +46,7 @@ obj-$(CONFIG_SENSORS_ADT7475)	+= adt7475.o
 obj-$(CONFIG_SENSORS_APPLESMC)	+= applesmc.o
 obj-$(CONFIG_SENSORS_ARM_SCPI)	+= scpi-hwmon.o
 obj-$(CONFIG_SENSORS_ASC7621)	+= asc7621.o
+obj-$(CONFIG_SENSORS_OCC_P9_SBE) += occ/
 obj-$(CONFIG_SENSORS_ATXP1)	+= atxp1.o
 obj-$(CONFIG_SENSORS_CORETEMP)	+= coretemp.o
 obj-$(CONFIG_SENSORS_DA9052_ADC)+= da9052-hwmon.o
@@ -170,7 +171,6 @@ obj-$(CONFIG_SENSORS_WM8350)	+= wm8350-hwmon.o
 obj-$(CONFIG_SENSORS_XGENE)	+= xgene-hwmon.o
 
 obj-$(CONFIG_PMBUS)		+= pmbus/
-obj-$(CONFIG_SENSORS_OCC)	+= occ/
 
 ccflags-$(CONFIG_HWMON_DEBUG_CHIP) := -DDEBUG
 
diff --git a/drivers/hwmon/occ/Kconfig b/drivers/hwmon/occ/Kconfig
index 34488de15900..8196b50c1693 100644
--- a/drivers/hwmon/occ/Kconfig
+++ b/drivers/hwmon/occ/Kconfig
@@ -2,23 +2,10 @@
 # On-Chip Controller configuration
 #
 
-menuconfig SENSORS_OCC
-	tristate "POWER On-Chip Controller"
-	help
-	  If you say yes here you get support for monitoring the IBM POWER
-	  processor sensors via the On-Chip Controller (OCC).
-
-	  This driver can also be built as a module. If so, the module will be
-	  called occ-hwmon.
-
-if SENSORS_OCC
-
 config SENSORS_OCC_P9_SBE
 	bool "POWER9 OCC via SBE"
-	depends on SBEFIFO_OCC
+	depends on OCCFIFO
 	help
 	  If you say yes here you get support for monitoring the POWER9
 	  processor sensors via the OCC, from a service processor, over SBE
 	  engine on FSI bus.
-
-endif
diff --git a/drivers/hwmon/occ/Makefile b/drivers/hwmon/occ/Makefile
index adc7a9c458d6..3b0ddc6c1e52 100644
--- a/drivers/hwmon/occ/Makefile
+++ b/drivers/hwmon/occ/Makefile
@@ -1,7 +1 @@
-occ-hwmon-objs := common.o
-
-ifeq ($(CONFIG_SENSORS_OCC_P9_SBE), y)
-occ-hwmon-objs += p9.o p9_sbe.o
-endif
-
-obj-$(CONFIG_SENSORS_OCC) += occ-hwmon.o
+obj-y += p9.o p9_sbe.o common.o
-- 
2.11.0



More information about the openbmc mailing list