[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <1394487298-14459-2-git-send-email-ptyser@xes-inc.com>
Date: Mon, 10 Mar 2014 16:34:52 -0500
From: Peter Tyser <ptyser@...-inc.com>
To: linux-kernel@...r.kernel.org
Cc: Peter Tyser <ptyser@...-inc.com>,
Guenter Roeck <linux@...ck-us.net>,
James Ralston <james.d.ralston@...el.com>,
Samuel Ortiz <sameo@...ux.intel.com>,
Lee Jones <lee.jones@...aro.org>
Subject: [PATCH 2/8] mfd: lpc_ich: Only configure watchdog or GPIO when present
Some chipsets don't currently have GPIO support enabled. For these
chipsets don't go through the process of initializing the GPIO region.
Make the same change for the watchdog initialization for chipsets which
may not enable the WDT in the future.
Signed-off-by: Peter Tyser <ptyser@...-inc.com>
Tested-by: Rajat Jain <rajatjain@...iper.net>
Cc: Guenter Roeck <linux@...ck-us.net>
Cc: James Ralston <james.d.ralston@...el.com>
Cc: Samuel Ortiz <sameo@...ux.intel.com>
Cc: Lee Jones <lee.jones@...aro.org>
---
drivers/mfd/lpc_ich.c | 16 ++++++++++------
1 files changed, 10 insertions(+), 6 deletions(-)
diff --git a/drivers/mfd/lpc_ich.c b/drivers/mfd/lpc_ich.c
index be10ad4..e247e7e 100644
--- a/drivers/mfd/lpc_ich.c
+++ b/drivers/mfd/lpc_ich.c
@@ -967,13 +967,17 @@ static int lpc_ich_probe(struct pci_dev *dev,
pci_set_drvdata(dev, priv);
- ret = lpc_ich_init_wdt(dev);
- if (!ret)
- cell_added = true;
+ if (lpc_chipset_info[priv->chipset].iTCO_version) {
+ ret = lpc_ich_init_wdt(dev);
+ if (!ret)
+ cell_added = true;
+ }
- ret = lpc_ich_init_gpio(dev);
- if (!ret)
- cell_added = true;
+ if (lpc_chipset_info[priv->chipset].gpio_version) {
+ ret = lpc_ich_init_gpio(dev);
+ if (!ret)
+ cell_added = true;
+ }
/*
* We only care if at least one or none of the cells registered
--
1.7.7.GIT
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists