aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChang Rebecca Swee Fun <rebecca.swee.fun.chang@intel.com>2014-12-08 04:38:10 -0500
committerLinus Walleij <linus.walleij@linaro.org>2015-01-15 11:23:12 -0500
commit920214902502ceb0445a25b530dfe4c465cf8575 (patch)
treeb65a1c9adfc8ed1641a73c9f9def2f34e348b278
parentae9ca493ee2adaebc2bccd60fb6ccf93a214262c (diff)
gpio: sch: Add support for Intel Quark X1000 SoC
Intel Quark X1000 provides a total of 16 GPIOs. The GPIOs are split between the legacy I/O bridge and the GPIO controller. GPIO-SCH is the GPIO pins on legacy bridge for Intel Quark SoC. Intel Quark X1000 has 2 GPIOs powered by the core power well and 6 from the suspend power well. This piece of work is derived from Dan O'Donovan's initial work for Quark X1000 enabling. Signed-off-by: Chang Rebecca Swee Fun <rebecca.swee.fun.chang@intel.com> Reviewed-by: Mika Westerberg <mika.westerberg@linux.intel.com> Reviewed-by: Alexandre Courbot <acourbot@nvidia.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
-rw-r--r--drivers/gpio/Kconfig11
-rw-r--r--drivers/gpio/gpio-sch.c6
2 files changed, 15 insertions, 2 deletions
diff --git a/drivers/gpio/Kconfig b/drivers/gpio/Kconfig
index d5ee1710d1ff..cb235f3691bc 100644
--- a/drivers/gpio/Kconfig
+++ b/drivers/gpio/Kconfig
@@ -395,25 +395,32 @@ config GPIO_VR41XX
395 Say yes here to support the NEC VR4100 series General-purpose I/O Uint 395 Say yes here to support the NEC VR4100 series General-purpose I/O Uint
396 396
397config GPIO_SCH 397config GPIO_SCH
398 tristate "Intel SCH/TunnelCreek/Centerton GPIO" 398 tristate "Intel SCH/TunnelCreek/Centerton/Quark X1000 GPIO"
399 depends on PCI && X86 399 depends on PCI && X86
400 select MFD_CORE 400 select MFD_CORE
401 select LPC_SCH 401 select LPC_SCH
402 help 402 help
403 Say yes here to support GPIO interface on Intel Poulsbo SCH, 403 Say yes here to support GPIO interface on Intel Poulsbo SCH,
404 Intel Tunnel Creek processor or Intel Centerton processor. 404 Intel Tunnel Creek processor, Intel Centerton processor or
405 Intel Quark X1000 SoC.
406
405 The Intel SCH contains a total of 14 GPIO pins. Ten GPIOs are 407 The Intel SCH contains a total of 14 GPIO pins. Ten GPIOs are
406 powered by the core power rail and are turned off during sleep 408 powered by the core power rail and are turned off during sleep
407 modes (S3 and higher). The remaining four GPIOs are powered by 409 modes (S3 and higher). The remaining four GPIOs are powered by
408 the Intel SCH suspend power supply. These GPIOs remain 410 the Intel SCH suspend power supply. These GPIOs remain
409 active during S3. The suspend powered GPIOs can be used to wake the 411 active during S3. The suspend powered GPIOs can be used to wake the
410 system from the Suspend-to-RAM state. 412 system from the Suspend-to-RAM state.
413
411 The Intel Tunnel Creek processor has 5 GPIOs powered by the 414 The Intel Tunnel Creek processor has 5 GPIOs powered by the
412 core power rail and 9 from suspend power supply. 415 core power rail and 9 from suspend power supply.
416
413 The Intel Centerton processor has a total of 30 GPIO pins. 417 The Intel Centerton processor has a total of 30 GPIO pins.
414 Twenty-one are powered by the core power rail and 9 from the 418 Twenty-one are powered by the core power rail and 9 from the
415 suspend power supply. 419 suspend power supply.
416 420
421 The Intel Quark X1000 SoC has 2 GPIOs powered by the core
422 power well and 6 from the suspend power well.
423
417config GPIO_ICH 424config GPIO_ICH
418 tristate "Intel ICH GPIO" 425 tristate "Intel ICH GPIO"
419 depends on PCI && X86 426 depends on PCI && X86
diff --git a/drivers/gpio/gpio-sch.c b/drivers/gpio/gpio-sch.c
index 0a0cf1307d2f..0271022a66f6 100644
--- a/drivers/gpio/gpio-sch.c
+++ b/drivers/gpio/gpio-sch.c
@@ -230,6 +230,12 @@ static int sch_gpio_probe(struct platform_device *pdev)
230 sch->chip.ngpio = 30; 230 sch->chip.ngpio = 30;
231 break; 231 break;
232 232
233 case PCI_DEVICE_ID_INTEL_QUARK_X1000_ILB:
234 sch->core_base = 0;
235 sch->resume_base = 2;
236 sch->chip.ngpio = 8;
237 break;
238
233 default: 239 default:
234 return -ENODEV; 240 return -ENODEV;
235 } 241 }