- 23 9月, 2016 7 次提交
-
-
由 Nava kishore Manne 提交于
This patch adds zynq specific check for bank 0 pins 7 and 8 are special and cannot be used as inputs Signed-off-by: NNava kishore Manne <navam@xilinx.com> Reported-by: NJonas Karlsson <Jonas.d.karlsson@gmail.com> Acked-by: NSören Brinkmann <soren.brinkmann@xilinx.com> Acked-by: NMichal Simek <michal.simek@xilinx.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Maxime Ripard 提交于
Implement the get_direction callback for the GPIOs found in the AXP209 PMIC. Due to the way they are implemented, in the same register you have the muxing options, GPIO directions and GPIO values. Since you have no control over what value is there at reset, simply use output as the default. Signed-off-by: NMaxime Ripard <maxime.ripard@free-electrons.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Wei Yongjun 提交于
Remove unneeded error handling on the result of a call to platform_get_resource() when the value is passed to devm_ioremap_resource(). Signed-off-by: NWei Yongjun <weiyongjun1@huawei.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Wei Yongjun 提交于
Remove unneeded error handling on the result of a call to platform_get_resource() when the value is passed to devm_ioremap_resource(). Signed-off-by: NWei Yongjun <weiyongjun1@huawei.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Linus Walleij 提交于
-
由 Mika Westerberg 提交于
When using GPIO irqchip helpers to setup irqchip for a gpiolib based driver, it is not possible to select which GPIOs to add to the IRQ domain. Instead it just adds all GPIOs which is not always desired. For example there might be GPIOs that for some reason cannot generated normal interrupts at all. To support this we add a flag irq_need_valid_mask to struct gpio_chip. When this flag is set the core allocates irq_valid_mask that holds one bit for each GPIO the chip has. By default all bits are set but drivers can manipulate this using set_bit() and clear_bit() accordingly. Then when gpiochip_irqchip_add() is called, this mask is checked and all GPIOs with bit is set are added to the IRQ domain created for the GPIO chip. Suggested-by: NLinus Walleij <linus.walleij@linaro.org> Signed-off-by: NMika Westerberg <mika.westerberg@linux.intel.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Linus Walleij 提交于
commit d47529b2 "gpio: don't include module.h in shared driver header" removed <linux/module.h> from the <linux/gpio/driver.h> header. It seems arch/arm/mach-omap2/board-rx51-peripherals.c is using __initdata_or_module from <linux/module.h> through <linux/gpio.h> to <linux/gpio/driver.h>, so break this dependency so that we get a clean compile. Cc: Paul Gortmaker <paul.gortmaker@windriver.com> Cc: Tony Lindgren <tony@atomide.com> Fixes: d47529b2 ("gpio: don't include module.h in shared driver header") Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
- 19 9月, 2016 2 次提交
-
-
由 Linus Walleij 提交于
A bunch of variables were just declared "unsigned" and should be "unsigned int". Fix it up for this driver. Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Linus Walleij 提交于
This adds a .get_direction() callback to the TC3589x and renames the function for setting single-ended mode to be more to the point. Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
- 18 9月, 2016 2 次提交
-
-
由 Amitesh Singh 提交于
gpiochip_add_data is already used to add data pointer and chip. Lets rely on gpiochip_get_data which is getting used in other gpio_chip functions. Signed-off-by: NAmitesh Singh <singh.amitesh@gmail.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Wei Yongjun 提交于
Use devm_gpiochip_add_data() for GPIO registration and remove the need of driver callback .remove. Signed-off-by: NWei Yongjun <weiyongjun1@huawei.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
- 15 9月, 2016 9 次提交
-
-
由 Wei Yongjun 提交于
In case of error, the function devm_ioremap_resource() returns ERR_PTR() and never returns NULL. The NULL test in the return value check should be replaced with IS_ERR(). Signed-off-by: NWei Yongjun <weiyongjun1@huawei.com> Acked-by: NJoel Stanley <joel@jms.id.au> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Paul Gortmaker 提交于
Most shared headers in include/linux don't need to know what the internals of a struct module are; all they care about is that it is a struct and hence they may require a pointer to one. The advantage in this is that module.h is including a lot of stuff itself, and an otherwise empty C file that just contains module.h will result in ~750kB from CPP (compared to say 12kB from init.h) So we have approximately 50 instances of "struct module;" in the various include/linux headers already that help us keep module.h out of other headers; here we do the same for gpio. Cc: Linus Walleij <linus.walleij@linaro.org> Cc: Alexandre Courbot <gnurou@gmail.com> Cc: linux-gpio@vger.kernel.org Signed-off-by: NPaul Gortmaker <paul.gortmaker@windriver.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Paul Gortmaker 提交于
The Kconfig for this file is: drivers/gpio/Kconfig:config GPIO_WHISKEY_COVE drivers/gpio/Kconfig: tristate "GPIO support for Whiskey Cove PMIC" ...but however it does not include module.h -- it in turn gets it from another header (gpio/driver.h) and we'd like to replace that with a forward delcaration of "struct module;" but if we do, this file will fail to compile. So we fix this first to avoid putting build failures into the bisect commit history. Cc: Ajay Thomas <ajay.thomas.david.rajamanickam@intel.com> Cc: Bin Gao <bin.gao@intel.com> Cc: Andy Shevchenko <andy.shevchenko@gmail.com> Cc: Mika Westerberg <mika.westerberg@linux.intel.com> Cc: Linus Walleij <linus.walleij@linaro.org> Cc: Alexandre Courbot <gnurou@gmail.com> Cc: linux-gpio@vger.kernel.org Signed-off-by: NPaul Gortmaker <paul.gortmaker@windriver.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Paul Gortmaker 提交于
The Kconfig for this file is: drivers/gpio/Kconfig:config GPIO_LOONGSON1 drivers/gpio/Kconfig: tristate "Loongson1 GPIO support" ...but however it does not include module.h -- it in turn gets it from another header (gpio/driver.h) and we'd like to replace that with a forward delcaration of "struct module;" but if we do, this file will fail to compile. So we fix this first to avoid putting build failures into the bisect commit history. Cc: Keguang Zhang <keguang.zhang@gmail.com> Cc: Linus Walleij <linus.walleij@linaro.org> Cc: Alexandre Courbot <gnurou@gmail.com> Cc: linux-mips@linux-mips.org Cc: linux-gpio@vger.kernel.org Signed-off-by: NPaul Gortmaker <paul.gortmaker@windriver.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Paul Gortmaker 提交于
The Kconfig for this file is: drivers/gpio/Kconfig:config GPIO_ATH79 drivers/gpio/Kconfig: tristate "Atheros AR71XX/AR724X/AR913X GPIO support" ...but however it does not include module.h -- it in turn gets it from another header (gpio/driver.h) and we'd like to replace that with a forward delcaration of "struct module;" but if we do, this file will fail to compile. So we fix this first to avoid putting build failures into the bisect commit history. Cc: Linus Walleij <linus.walleij@linaro.org> Cc: Alexandre Courbot <gnurou@gmail.com> Cc: linux-gpio@vger.kernel.org Signed-off-by: NPaul Gortmaker <paul.gortmaker@windriver.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Paul Gortmaker 提交于
The Kconfig for this file is: drivers/gpio/Kconfig:config GPIO_ALTERA drivers/gpio/Kconfig: tristate "Altera GPIO" ...but however it does not include module.h -- it in turn gets it from another header (gpio/driver.h) and we'd like to replace that with a forward delcaration of "struct module;" but if we do, this file will fail to compile. So we fix this first to avoid putting build failures into the bisect commit history. Cc: Linus Walleij <linus.walleij@linaro.org> Cc: Alexandre Courbot <gnurou@gmail.com> Cc: linux-gpio@vger.kernel.org Signed-off-by: NPaul Gortmaker <paul.gortmaker@windriver.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Paul Gortmaker 提交于
The Kconfig for this file is: drivers/gpio/Kconfig:config GPIO_TS4800 drivers/gpio/Kconfig: tristate "TS-4800 DIO blocks and compatibles" ...but however it does not include module.h -- it in turn gets it from another header (gpio/driver.h) and we'd like to replace that with a forward delcaration of "struct module;" but if we do, this file will fail to compile. So we fix this first to avoid putting build failures into the bisect commit history. Cc: Linus Walleij <linus.walleij@linaro.org> Cc: Alexandre Courbot <gnurou@gmail.com> Cc: linux-gpio@vger.kernel.org Signed-off-by: NPaul Gortmaker <paul.gortmaker@windriver.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Paul Gortmaker 提交于
This file is currently getting module.h from a global gpio header and it will faii to build once we remove module.h from that. However, the driver is controlled with the following Kconfig: drivers/gpio/Kconfig:config GPIO_SX150X drivers/gpio/Kconfig: bool "Semtech SX150x I2C GPIO expander" and hence the two lines of MODULE_DEVICE_TABLE are no-ops that can simply be deleted. Cc: Linus Walleij <linus.walleij@linaro.org> Cc: Alexandre Courbot <gnurou@gmail.com> Cc: linux-gpio@vger.kernel.org Signed-off-by: NPaul Gortmaker <paul.gortmaker@windriver.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Paul Gortmaker 提交于
This file is currently getting module.h from a global gpio header and it will fail to build once we remove module.h from that. However, the driver is controlled with the following Kconfig: drivers/gpio/Kconfig:config GPIO_PALMAS drivers/gpio/Kconfig: bool "TI PALMAS series PMICs GPIO" and hence the line of MODULE_DEVICE_TABLE is a no-op that can simply be deleted. In fact it should have been removed in an earlier commit that did demodularization, however the unseen include prevented my build testing from detecting it. Cc: Linus Walleij <linus.walleij@linaro.org> Cc: Alexandre Courbot <gnurou@gmail.com> Cc: linux-gpio@vger.kernel.org Signed-off-by: NPaul Gortmaker <paul.gortmaker@windriver.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
- 13 9月, 2016 7 次提交
-
-
由 Linus Walleij 提交于
This reverts commit 313b9a99. This was already fixed by commit bf62efeb "gpio: pca954x: fix undefined error code from remove" The latter is a better fix since it makes it easier to detect erronous code by not assigning a default error code. Reported-by: NArnd Bergmann <arnd@arndb.de> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Linus Walleij 提交于
The build complains about missing MODULE_LICENSE() in the Aspeed GPIO driver. The license is evident from the file header, put in "GPL". Reported-by: NStephen Rothwell <sfr@canb.auug.org.au> Cc: Alistair Popple <alistair@popple.id.au> Cc: Jeremy Kerr <jk@ozlabs.org> Cc: Andrew Jeffery <andrew@aj.id.au> Acked-by: NJoel Stanley <joel@jms.id.au> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Mika Westerberg 提交于
Follow DT and forbid default trigger if the GPIO irqchip device is enumerated from ACPI. Triggering for these devices will be configured automatically from ACPI interrupt resources provided by the BIOS. Suggested-by: NLinus Walleij <linus.walleij@linaro.org> Signed-off-by: NMika Westerberg <mika.westerberg@linux.intel.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Julia Lawall 提交于
These structures are only used to copy into other structures, so declare them as const. The semantic patch that makes this change is as follows: (http://coccinelle.lip6.fr/) // <smpl> @r disable optional_qualifier@ identifier i; position p; @@ static struct gpio_chip i@p = { ... }; @ok@ identifier r.i; expression e; position p; @@ e = i@p; @bad@ position p != {r.p,ok.p}; identifier r.i; struct gpio_chip e; @@ e@i@p @depends on !bad disable optional_qualifier@ identifier r.i; @@ static +const struct gpio_chip i = { ... }; // </smpl> Signed-off-by: NJulia Lawall <Julia.Lawall@lip6.fr> Acked-by: NJoachim Eastwood <manabian@gmail.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Wei Yongjun 提交于
Use devm_gpiochip_add_data() for GPIO registration and remove the need of driver callback .remove. Signed-off-by: NWei Yongjun <weiyongjun1@huawei.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Linus Walleij 提交于
Merge tag 'ib-mfd-gpio-regulator-v4.9' of git://git.kernel.org/pub/scm/linux/kernel/git/lee/mfd into devel Immutable branch between MFD, GPIO and Regulator due for the v4.9 merge window
-
由 Linus Walleij 提交于
Linux 4.8-rc2
-
- 12 9月, 2016 10 次提交
-
-
由 Colin Ian King 提交于
ret is not initialized so it contains garbage. Ensure garbage is not returned in the case that pdata && pdata->teardown is false by initializing ret to 0. Signed-off-by: NColin Ian King <colin.king@canonical.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Alexander Shiyan 提交于
This patch switches the driver to use the generic GPIO MMIO functions that removes a bit of redundant and duplicate code. Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Amitesh Singh 提交于
Both gpio_export and gpio_free APIs are obsolete now. Signed-off-by: NAmitesh Singh <singh.amitesh@gmail.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Bartosz Golaszewski 提交于
pca953x_gpio_set_multiple() has some coding style issues that make it harder to read. Tweak the code a bit. Signed-off-by: NBartosz Golaszewski <bgolaszewski@baylibre.com> Reviewed-by: NAndy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Bartosz Golaszewski 提交于
The chip_type variable in struct pca953x_chip is no longer required. Remove it. Signed-off-by: NBartosz Golaszewski <bgolaszewski@baylibre.com> Reviewed-by: NAndy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Bartosz Golaszewski 提交于
Avoid the unnecessary if-else in pca953x_read_regs() by spltting the routine into smaller, specialized functions and calling the right one via a function pointer held in struct pca953x. Signed-off-by: NBartosz Golaszewski <bgolaszewski@baylibre.com> Reviewed-by: NAndy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Bartosz Golaszewski 提交于
Avoid the unnecessary if-else in pca953x_write_regs() by splitting the routine into smaller, specialized functions and calling the right one via a function pointer held in struct pca953x_chip. Signed-off-by: NBartosz Golaszewski <bgolaszewski@baylibre.com> Reviewed-by: NAndy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Bartosz Golaszewski 提交于
There are multiple places in the driver code where a switch (chip->chip_type) is used to determine the proper register offset. Unduplicate the code by adding a simple structure holding the possible offsets that differ between the pca953x and pca957x chip families and use it to avoid the checks. Signed-off-by: NBartosz Golaszewski <bgolaszewski@baylibre.com> Reviewed-by: NAndy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Vladimir Zapolskiy 提交于
ARM LPC32xx platform is device-tree only, there is no need to keep a file with GPIO platform data structures, however some of macro definitions should be moved to the driver code, which is the only user of the removed header file. Signed-off-by: NVladimir Zapolskiy <vz@mleia.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Marc Zyngier 提交于
Using a default trigger is a bad idea if using DT to configure interrupts, as the device's interrupt specifier will always contain the trigger configuration. Let's warn about that particular situation, and revert to not having a default. Hopefully, the couple of drivers still using this feature will quickly be fixed. Signed-off-by: NMarc Zyngier <marc.zyngier@arm.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
- 08 9月, 2016 2 次提交
-
-
由 Simon Horman 提交于
R-Car Gen3's GPIO blocks are identical to Gen2's in every respect. Based on work for the r8a7795 (R-Car H3) by Ulrich Hecht. Cc: Ulrich Hecht <ulrich.hecht+renesas@gmail.com> Signed-off-by: NSimon Horman <horms+renesas@verge.net.au> Reviewed-by: NGeert Uytterhoeven <geert+renesas@glider.be> Reviewed-by: NLaurent Pinchart <laurent.pinchart@ideasonboard.com> Tested-by: NLaurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Baruch Siach 提交于
The Orion GPIO controller binding description in mrvl-gpio.txt is obsolete, and duplicates the description in gpio-mvebu.txt. Signed-off-by: NBaruch Siach <baruch@tkos.co.il> Reviewed-by: NAndrew Lunn <andrew@lunn.ch> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
- 07 9月, 2016 1 次提交
-
-
由 Joel Stanley 提交于
The Aspeed SoCs contain GPIOs banked by letter, where each bank contains 8 pins. The GPIO banks are then grouped in sets of four in the register layout. The implementation exposes multiple banks through the one driver and requests and releases pins via the pinctrl subsystem. The hardware supports generation of interrupts from all GPIO-capable pins. A number of hardware features are not yet supported: Configuration of interrupt direction (ARM or LPC), debouncing, and WDT reset tolerance for output ports. Signed-off-by: NJoel Stanley <joel@jms.id.au> Signed-off-by: NAlistair Popple <alistair@popple.id.au> Signed-off-by: NJeremy Kerr <jk@ozlabs.org> Signed-off-by: NAndrew Jeffery <andrew@aj.id.au> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-