aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--drivers/gpio/Kconfig1
-rw-r--r--drivers/gpio/gpio-tc3589x.c3
-rw-r--r--drivers/input/keyboard/tc3589x-keypad.c9
-rw-r--r--drivers/mfd/Kconfig1
-rw-r--r--drivers/mfd/tc3589x.c9
5 files changed, 2 insertions, 21 deletions
diff --git a/drivers/gpio/Kconfig b/drivers/gpio/Kconfig
index c1e2ca3d9a51..dc1aaa83a347 100644
--- a/drivers/gpio/Kconfig
+++ b/drivers/gpio/Kconfig
@@ -669,6 +669,7 @@ config GPIO_STP_XWAY
669config GPIO_TC3589X 669config GPIO_TC3589X
670 bool "TC3589X GPIOs" 670 bool "TC3589X GPIOs"
671 depends on MFD_TC3589X 671 depends on MFD_TC3589X
672 depends on OF_GPIO
672 select GPIOLIB_IRQCHIP 673 select GPIOLIB_IRQCHIP
673 help 674 help
674 This enables support for the GPIOs found on the TC3589X 675 This enables support for the GPIOs found on the TC3589X
diff --git a/drivers/gpio/gpio-tc3589x.c b/drivers/gpio/gpio-tc3589x.c
index 11aed2671065..31b244cffabb 100644
--- a/drivers/gpio/gpio-tc3589x.c
+++ b/drivers/gpio/gpio-tc3589x.c
@@ -260,10 +260,7 @@ static int tc3589x_gpio_probe(struct platform_device *pdev)
260 tc3589x_gpio->chip.ngpio = tc3589x->num_gpio; 260 tc3589x_gpio->chip.ngpio = tc3589x->num_gpio;
261 tc3589x_gpio->chip.dev = &pdev->dev; 261 tc3589x_gpio->chip.dev = &pdev->dev;
262 tc3589x_gpio->chip.base = -1; 262 tc3589x_gpio->chip.base = -1;
263
264#ifdef CONFIG_OF_GPIO
265 tc3589x_gpio->chip.of_node = np; 263 tc3589x_gpio->chip.of_node = np;
266#endif
267 264
268 /* Bring the GPIO module out of reset */ 265 /* Bring the GPIO module out of reset */
269 ret = tc3589x_set_bits(tc3589x, TC3589x_RSTCTRL, 266 ret = tc3589x_set_bits(tc3589x, TC3589x_RSTCTRL,
diff --git a/drivers/input/keyboard/tc3589x-keypad.c b/drivers/input/keyboard/tc3589x-keypad.c
index ae90df3468e0..31c606a4dd31 100644
--- a/drivers/input/keyboard/tc3589x-keypad.c
+++ b/drivers/input/keyboard/tc3589x-keypad.c
@@ -318,7 +318,6 @@ static void tc3589x_keypad_close(struct input_dev *input)
318 tc3589x_keypad_disable(keypad); 318 tc3589x_keypad_disable(keypad);
319} 319}
320 320
321#ifdef CONFIG_OF
322static const struct tc3589x_keypad_platform_data * 321static const struct tc3589x_keypad_platform_data *
323tc3589x_keypad_of_probe(struct device *dev) 322tc3589x_keypad_of_probe(struct device *dev)
324{ 323{
@@ -368,14 +367,6 @@ tc3589x_keypad_of_probe(struct device *dev)
368 367
369 return plat; 368 return plat;
370} 369}
371#else
372static inline const struct tc3589x_keypad_platform_data *
373tc3589x_keypad_of_probe(struct device *dev)
374{
375 return ERR_PTR(-ENODEV);
376}
377#endif
378
379 370
380static int tc3589x_keypad_probe(struct platform_device *pdev) 371static int tc3589x_keypad_probe(struct platform_device *pdev)
381{ 372{
diff --git a/drivers/mfd/Kconfig b/drivers/mfd/Kconfig
index 38356e39adba..476e63745742 100644
--- a/drivers/mfd/Kconfig
+++ b/drivers/mfd/Kconfig
@@ -1210,6 +1210,7 @@ config MFD_TIMBERDALE
1210config MFD_TC3589X 1210config MFD_TC3589X
1211 bool "Toshiba TC35892 and variants" 1211 bool "Toshiba TC35892 and variants"
1212 depends on I2C=y 1212 depends on I2C=y
1213 depends on OF
1213 select MFD_CORE 1214 select MFD_CORE
1214 help 1215 help
1215 Support for the Toshiba TC35892 and variants I/O Expander. 1216 Support for the Toshiba TC35892 and variants I/O Expander.
diff --git a/drivers/mfd/tc3589x.c b/drivers/mfd/tc3589x.c
index aacb3720065c..cf356395c9e9 100644
--- a/drivers/mfd/tc3589x.c
+++ b/drivers/mfd/tc3589x.c
@@ -318,7 +318,6 @@ static int tc3589x_device_init(struct tc3589x *tc3589x)
318 return ret; 318 return ret;
319} 319}
320 320
321#ifdef CONFIG_OF
322static const struct of_device_id tc3589x_match[] = { 321static const struct of_device_id tc3589x_match[] = {
323 /* Legacy compatible string */ 322 /* Legacy compatible string */
324 { .compatible = "tc3589x", .data = (void *) TC3589X_UNKNOWN }, 323 { .compatible = "tc3589x", .data = (void *) TC3589X_UNKNOWN },
@@ -359,14 +358,6 @@ tc3589x_of_probe(struct device *dev, enum tc3589x_version *version)
359 358
360 return pdata; 359 return pdata;
361} 360}
362#else
363static inline struct tc3589x_platform_data *
364tc3589x_of_probe(struct device *dev, enum tc3589x_version *version)
365{
366 dev_err(dev, "no device tree support\n");
367 return ERR_PTR(-ENODEV);
368}
369#endif
370 361
371static int tc3589x_probe(struct i2c_client *i2c, 362static int tc3589x_probe(struct i2c_client *i2c,
372 const struct i2c_device_id *id) 363 const struct i2c_device_id *id)