Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

Input: ads7846 - use IS_ENABLED() macro

Using the IS_ENABLED() macro can make the code shorter and simpler

Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com>
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>

authored by

Fabio Estevam and committed by
Dmitry Torokhov
c52b4fc7 976358e2

+2 -2
+2 -2
drivers/input/touchscreen/ads7846.c
··· 101 101 struct spi_device *spi; 102 102 struct regulator *reg; 103 103 104 - #if defined(CONFIG_HWMON) || defined(CONFIG_HWMON_MODULE) 104 + #if IS_ENABLED(CONFIG_HWMON) 105 105 struct attribute_group *attr_group; 106 106 struct device *hwmon; 107 107 #endif ··· 421 421 return status; 422 422 } 423 423 424 - #if defined(CONFIG_HWMON) || defined(CONFIG_HWMON_MODULE) 424 + #if IS_ENABLED(CONFIG_HWMON) 425 425 426 426 #define SHOW(name, var, adjust) static ssize_t \ 427 427 name ## _show(struct device *dev, struct device_attribute *attr, char *buf) \