From: Paul Gortmaker Date: Mon, 1 Oct 2012 15:43:49 +0000 (-0400) Subject: tg3: unconditionally select HWMON support when tg3 is enabled. X-Git-Tag: omap-for-v3.7-rc1/fixes-cpufreq-signed~47^2~12 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=de0a41484c47d783dd4d442914815076aa2caac2;p=pandora-kernel.git tg3: unconditionally select HWMON support when tg3 is enabled. There is the seldom used corner case where HWMON=m at the same time as TIGON3=y (typically randconfigs) which will cause a link fail like: drivers/built-in.o: In function `tg3_close': tg3.c:(.text+0x16bd86): undefined reference to `hwmon_device_unregister' drivers/built-in.o: In function `tg3_hwmon_open': tg3.c:(.text+0x16fc4b): undefined reference to `hwmon_device_register' make[1]: *** [vmlinux] Error 1 Fix it as suggested by DaveM[1] by having the Kconfig logic simply select HWMON when TIGON3 is selected. This gets rid of all the extra IS_ENABLED ifdeffery in tg3.c as a side benefit. [1] http://marc.info/?l=linux-netdev&m=134250573718151&w=2 Cc: Michael Chan Reported-by: Benjamin Herrenschmidt Reported-by: Anisse Astier Suggested-by: David S. Miller Signed-off-by: Paul Gortmaker Signed-off-by: David S. Miller --- Reading git-diff-tree failed