From ec693fe5287e1791f4d206e81ebdfdc7d1f8f6b9 Mon Sep 17 00:00:00 2001 From: Jean Delvare Date: Wed, 25 May 2011 20:43:33 +0200 Subject: hwmon: (abituguru) Depend on DMI The abituguru drivers are only built on X86, where DMI support is now enabled by default. So let these drivers depend on DMI, for the following gains: * Robustness and safety. Detection of these devices is weak and uses non-standard methods, it should really be limited to Abit boards unless the user explicitly asks otherwise. * Code simplicity. The code is easier to read without ifdefs. * Better build testing coverage. Now there's only one way to build the drivers, so no risk of build failure on exotic systems. Signed-off-by: Jean Delvare Acked-by: Guenter Roeck Acked-by: Alistair John Strachan Acked-by: Hans de Goede --- drivers/hwmon/abituguru.c | 3 --- 1 file changed, 3 deletions(-) (limited to 'drivers/hwmon/abituguru.c') diff --git a/drivers/hwmon/abituguru.c b/drivers/hwmon/abituguru.c index e7d4c46..65a35cf 100644 --- a/drivers/hwmon/abituguru.c +++ b/drivers/hwmon/abituguru.c @@ -1448,15 +1448,12 @@ static int __init abituguru_init(void) { int address, err; struct resource res = { .flags = IORESOURCE_IO }; - -#ifdef CONFIG_DMI const char *board_vendor = dmi_get_system_info(DMI_BOARD_VENDOR); /* safety check, refuse to load on non Abit motherboards */ if (!force && (!board_vendor || strcmp(board_vendor, "http://www.abit.com.tw/"))) return -ENODEV; -#endif address = abituguru_detect(); if (address < 0) -- cgit v1.1