Edward O'Callaghan (eocallaghan@alterapraxis.com) just uploaded a new patch set to gerrit, which you can find at http://review.coreboot.org/5841
-gerrit
commit a6b2784ec20cfc631f141c2e43854183e29152a9 Author: Edward O'Callaghan eocallaghan@alterapraxis.com Date: Sat May 24 14:43:03 2014 +1000
superio/fintek/f71869ad: Make SIO HWM conf conditional
Not everyone may like to enable the Super I/O HWM on their board or for their purposes. Hence, make hwm configuration conditional in Kconfig.
Change-Id: I8f75bda30a1df4d6f33b73f3d0e6dd2e5dc9963f Signed-off-by: Edward O'Callaghan eocallaghan@alterapraxis.com --- src/mainboard/jetway/nf81-t56n-lf/Kconfig | 1 + src/superio/fintek/Kconfig | 20 ++++++++++++++++++++ src/superio/fintek/f71869ad/Makefile.inc | 4 ++-- src/superio/fintek/f71869ad/chip.h | 2 ++ src/superio/fintek/f71869ad/superio.c | 2 ++ 5 files changed, 27 insertions(+), 2 deletions(-)
diff --git a/src/mainboard/jetway/nf81-t56n-lf/Kconfig b/src/mainboard/jetway/nf81-t56n-lf/Kconfig index d90e7a1..bcb95f6 100644 --- a/src/mainboard/jetway/nf81-t56n-lf/Kconfig +++ b/src/mainboard/jetway/nf81-t56n-lf/Kconfig @@ -26,6 +26,7 @@ config BOARD_SPECIFIC_OPTIONS # dummy select NORTHBRIDGE_AMD_AGESA_FAMILY14 select SOUTHBRIDGE_AMD_CIMX_SB800 select SUPERIO_FINTEK_F71869AD + select SUPERIO_FINTEK_F71869AD_HWM select HAVE_OPTION_TABLE select HAVE_PIRQ_TABLE select HAVE_MP_TABLE diff --git a/src/superio/fintek/Kconfig b/src/superio/fintek/Kconfig index f577898..43f4b4d 100644 --- a/src/superio/fintek/Kconfig +++ b/src/superio/fintek/Kconfig @@ -39,6 +39,26 @@ config SUPERIO_FINTEK_F71869AD bool select SUPERIO_FINTEK_COMMON_ROMSTAGE
+choice + prompt "Super I/O Hardware Monitor" + default SUPERIO_NO_HWM + help + Select the method of hardware monitor fan control to be used. + +config SUPERIO_NO_HWM + bool "None" + help + No Super I/O Fan control - Do not set up the HWM fan control registers. + +config SUPERIO_FINTEK_F71869AD_HWM + bool "Fintek F71869AD HWM" + depends on SUPERIO_FINTEK_F71869AD + help + Configure the Fintek Super I/O hardware monitor fan control registers in + devicetree.cb. + +endchoice + config SUPERIO_FINTEK_F71872 bool select SUPERIO_FINTEK_COMMON_ROMSTAGE diff --git a/src/superio/fintek/f71869ad/Makefile.inc b/src/superio/fintek/f71869ad/Makefile.inc index 1d8cc6a..4de156d 100644 --- a/src/superio/fintek/f71869ad/Makefile.inc +++ b/src/superio/fintek/f71869ad/Makefile.inc @@ -18,6 +18,6 @@ ## Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA ##
-ramstage-$(CONFIG_SUPERIO_FINTEK_F71869AD) += f71869ad_multifunc.c -ramstage-$(CONFIG_SUPERIO_FINTEK_F71869AD) += f71869ad_hwm.c +ramstage-$(CONFIG_SUPERIO_FINTEK_F71869AD_HWM) += f71869ad_multifunc.c +ramstage-$(CONFIG_SUPERIO_FINTEK_F71869AD_HWM) += f71869ad_hwm.c ramstage-$(CONFIG_SUPERIO_FINTEK_F71869AD) += superio.c diff --git a/src/superio/fintek/f71869ad/chip.h b/src/superio/fintek/f71869ad/chip.h index e12e51d..4c6c5d7 100644 --- a/src/superio/fintek/f71869ad/chip.h +++ b/src/superio/fintek/f71869ad/chip.h @@ -24,6 +24,7 @@ #include <stdint.h>
struct superio_fintek_f71869ad_config { +#ifdef CONFIG_SUPERIO_FINTEK_F71869AD_HWM /* Member variables are defined in devicetree.cb. */ uint8_t multi_function_register_1; uint8_t multi_function_register_2; @@ -41,6 +42,7 @@ struct superio_fintek_f71869ad_config { uint8_t hwm_fan1_seg2_speed_count; uint8_t hwm_fan1_seg3_speed_count; uint8_t hwm_fan1_temp_map_sel; +#endif /* CONFIG_SUPERIO_FINTEK_F71869AD_HWM */ };
#endif /* SUPERIO_FINTEK_F71869AD_CHIP_H */ diff --git a/src/superio/fintek/f71869ad/superio.c b/src/superio/fintek/f71869ad/superio.c index 2664f99..82ad9e0 100644 --- a/src/superio/fintek/f71869ad/superio.c +++ b/src/superio/fintek/f71869ad/superio.c @@ -40,10 +40,12 @@ static void f71869ad_init(device_t dev) case F71869AD_KBC: pc_keyboard_init(); break; +#ifdef CONFIG_SUPERIO_FINTEK_F71869AD_HWM case F71869AD_HWM: f71869ad_multifunc_init(dev); f71869ad_hwm_init(dev); break; +#endif /* CONFIG_SUPERIO_FINTEK_F71869AD_HWM */ } }