- 01 10月, 2013 2 次提交
-
-
由 Javier Martinez Canillas 提交于
The OMAP GPIO controller HW requires a pin to be configured in GPIO input mode in order to operate as an interrupt input. Since drivers should not be aware of whether an interrupt pin is also a GPIO or not, the HW should be fully configured/enabled as an IRQ if a driver solely uses IRQ APIs such as request_irq(), and never calls any GPIO-related APIs. As such, add the missing HW setup to the OMAP GPIO controller's irq_chip driver. Since this bypasses the GPIO subsystem we have to ensure that another driver won't be able to request the same GPIO pin that is used as an IRQ and set its direction as output. Requesting the GPIO and setting its direction as input is allowed though. This fixes smsc911x ethernet support for tobi and igep OMAP3 boards and OMAP4 SDP SPI based ethernet that use a GPIO as an interrupt line. Cc: stable@vger.kernel.org Acked-by: NStephen Warren <swarren@nvidia.com> Tested-by: NGeorge Cherian <george.cherian@ti.com> Tested-by: NAaro Koskinen <aaro.koskinen@iki.fi> Tested-by: NLars Poeschel <poeschel@lemonage.de> Reviewed-by: NKevin Hilman <khilman@linaro.org> Tested-by: NKevin Hilman <khilman@linaro.org> Acked-by: NSantosh Shilimkar <santosh.shilimkar@ti.com> Acked-by: NTony Lindgren <tony@atomide.com> Signed-off-by: NJavier Martinez Canillas <javier.martinez@collabora.co.uk> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Javier Martinez Canillas 提交于
The GPIO OMAP controller pins can be used as IRQ and GPIO independently so is necessary to keep track GPIO pins and IRQ lines usage separately to make sure that the bank will always be enabled while being used. Also move gpio_is_input() definition in preparation for the next patch that setups the controller's irq_chip driver when a caller requests an interrupt line. Cc: stable@vger.kernel.org Acked-by: NStephen Warren <swarren@nvidia.com> Tested-by: NGeorge Cherian <george.cherian@ti.com> Tested-by: NAaro Koskinen <aaro.koskinen@iki.fi> Tested-by: NLars Poeschel <poeschel@lemonage.de> Reviewed-by: NKevin Hilman <khilman@linaro.org> Tested-by: NKevin Hilman <khilman@linaro.org> Acked-by: NSantosh Shilimkar <santosh.shilimkar@ti.com> Acked-by: NTony Lindgren <tony@atomide.com> Signed-off-by: NJavier Martinez Canillas <javier.martinez@collabora.co.uk> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
- 22 9月, 2013 1 次提交
-
-
由 Laurent Pinchart 提交于
Commit a1bc260b ("gpio: clean up gpio-ranges documentation") deprecated the #gpio-range-cells property. Replace its usage with a hardcoded value in the gpio-rcar driver. Signed-off-by: NLaurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Acked-by: NLinus Walleij <linus.walleij@linaro.org> Signed-off-by: NSimon Horman <horms+renesas@verge.net.au>
-
- 13 9月, 2013 1 次提交
-
-
由 Martin Schwidefsky 提交于
After the last architecture switched to generic hard irqs the config options HAVE_GENERIC_HARDIRQS & GENERIC_HARDIRQS and the related code for !CONFIG_GENERIC_HARDIRQS can be removed. Signed-off-by: NMartin Schwidefsky <schwidefsky@de.ibm.com>
-
- 04 9月, 2013 1 次提交
-
-
由 Linus Walleij 提交于
It appears some drivers are using gpio_set_debounce() opportunistically, i.e. without knowing whether it works or not. (Example: input/keyboard/gpio_keys.c) to account for this use case, return -ENOTSUPP and do not print any warnings in this case. Took a round over the other gpio_set_debounce() consumers to make sure that none of them are relying on the returned error code to be something specific. Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
- 03 9月, 2013 1 次提交
-
-
由 Linus Walleij 提交于
At several places the gpiolib will proceed to handle a GPIO descriptor even if it's ->chip member is NULL and no gpiochip is associated. Fix this by checking that both the descriptor cookie *and* the chip pointer are valid. Also bail out earlier with more specific diagnostic messages on missing operations for setting as input/output or debounce. ChangeLog v1->v2: - Also return -EIO on gpiod_set_debounce() with missing operations in the vtable - Fix indentations. Suggested-by: NAlexandre Courbot <acourbot@nvidia.com> Acked-by: NAlexandre Courbot <acourbot@nvidia.com> Reviewed-by: NFrank Rowand <frank.rowand@sonymobile.com> Cc: Tim Bird <tim.bird@sonymobile.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
- 30 8月, 2013 4 次提交
-
-
由 Simon Guinot 提交于
This patch adds support for the GPIOs found on the Fintek super-I/O chips F71882FG and F71889F. A super-I/O is a legacy I/O controller embedded on x86 motherboards. It is used to connect the low-bandwidth devices. Among others functions the F71882FG/F71889F provides: a parallel port, two serial ports, a keyboard controller, an hardware monitoring controller and some GPIO pins. Note that this super-I/Os are embedded on some Atom-based LaCie NASes. The GPIOs are used to control the LEDs and the hard drive power. Changes since v3: - Use request_muxed_region to protect the I/O ports against concurrent accesses. Changes since v2: - Remove useless NULL setters for driver data. Changes since v1: - Enhance the commit message by describing what is a Super-I/O. - Use self-explanatory names for the GPIO register macros. - Add a comment to explain the platform device and driver registration. - Fix gpio_get when GPIO is configured in input mode. I only had the hardware to check this mode recently... Signed-off-by: NSimon Guinot <simon.guinot@sequanux.org> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Lars Poeschel 提交于
The device tree property should be more descriptive. microchip seems more reasonable than mcp. The old mcp prefix is still supported but marked as deprecated. Users of mcp have to switch to the microchip prefix. Acked-by: NMark Rutland <mark.rutland@arm.com> Signed-off-by: NLars Poeschel <poeschel@lemonage.de> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Stephen Warren 提交于
Use the new of_parse_phandle_with_fixed_args() to implement the corrected gpio-ranges DT property definition. Signed-off-by: NStephen Warren <swarren@nvidia.com> Acked-by: NMark Rutland <mark.rutland@arm.com> Acked-by: NLinus Walleij <linus.walleij@linaro.org> Signed-off-by: NGrant Likely <grant.likely@linaro.org>
-
由 Vivien Didelot 提交于
This patch moves the pca953x.h header from include/linux/i2c to include/linux/platform_data and updates existing support accordingly. Acked-by: NLinus Walleij <linus.walleij@linaro.org> Acked-by: NH Hartley Sweeten <hsweeten@visionengravers.com> Signed-off-by: NVivien Didelot <vivien.didelot@savoirfairelinux.com> Signed-off-by: NOlof Johansson <olof@lixom.net>
-
- 29 8月, 2013 1 次提交
-
-
由 Tomasz Figa 提交于
GPIO support on Exynos SoCs is provided by pinctrl-samsung driver, leaving all the support code in gpio-samsung driver unused. This dead code can be safely removed and so it is done by this patch. Signed-off-by: NTomasz Figa <t.figa@samsung.com> Signed-off-by: NKyungmin Park <kyungmin.park@samsung.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
- 26 8月, 2013 1 次提交
-
-
由 David Daney 提交于
The SOCs in the OCTEON family have 16 (or in some cases 20) on-chip GPIO pins, this driver handles them all. Configuring the pins as interrupt sources is handled elsewhere (OCTEON's irq handling code). Signed-off-by: NDavid Daney <david.daney@cavium.com> Reviewed-by: NLinus Walleij <linus.walleij@linaro.org> Cc: linux-gpio@vger.kernel.org Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/5633/Signed-off-by: NRalf Baechle <ralf@linux-mips.org>
-
- 24 8月, 2013 3 次提交
-
-
由 Laurent Pinchart 提交于
The argument is not used, remove it. No board registers a pcf857x device with an IRQ without specifying platform data, IRQ domain registration behaviour is thus not affected by this change. Signed-off-by: NLaurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Laurent Pinchart 提交于
This makes checking for duplicates when adding a new #include easier. Signed-off-by: NLaurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Christophe Leroy 提交于
This patch reverts commit 047b93a3 which breaks MAX7301 GPIO driver because that commit was dependant on a rejected patch that was implementing selection of SPI speed from the Device Tree. Signed-off-by: NChristophe Leroy <christophe.leroy@c-s.fr> Acked-by: NRoland Stigge <stigge@antcom.de> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
- 16 8月, 2013 13 次提交
-
-
由 Brunner Michael 提交于
This patch fixes the bit masking within the GPIO driver. The masking is basically done twice which causes the wrong GPIOs to be addressed. Signed-off-by: NMichael Brunner <michael.brunner@kontron.com> Signed-off-by: NGuenter Roeck <linux@roeck-us.net> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Andrew Ruder 提交于
This change fixes a regression introduced by commit f5f0b7aa (gpio: pca953x: make the register access by GPIO bank) When the pca953x driver was converted to using 8-bit reads/writes the bitmask in pca953x_gpio_get_value wasn't adjusted with a modulus BANK_SZ and consequently looks at the wrong bits in the input register. Signed-off-by: NAndrew Ruder <andrew.ruder@elecsyscorp.com> Reviewed-by: NGregory CLEMENT <gregory.clement@free-electrons.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Julia Lawall 提交于
Remove unneeded error handling on the result of a call to platform_get_resource when the value is passed to devm_ioremap_resource. Move the call to platform_get_resource adjacent to the call to devm_ioremap_resource to make the connection between them more clear. A simplified version of the semantic patch that makes this change is as follows: (http://coccinelle.lip6.fr/) // <smpl> @@ expression pdev,res,n,e,e1; expression ret != 0; identifier l; @@ - res = platform_get_resource(pdev, IORESOURCE_MEM, n); ... when != res - if (res == NULL) { ... \(goto l;\|return ret;\) } ... when != res + res = platform_get_resource(pdev, IORESOURCE_MEM, n); e = devm_ioremap_resource(e1, res); // </smpl> Signed-off-by: NJulia Lawall <Julia.Lawall@lip6.fr> Acked-by: NViresh Kumar <viresh.kumar@linaro.org> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Julia Lawall 提交于
Replace a comma between expression statements by a semicolon. This changes the semantics of the code, but given the current indentation appears to be what is intended. A simplified version of the semantic patch that performs this transformation is as follows: (http://coccinelle.lip6.fr/) // <smpl> @r@ expression e1,e2,e; type T; identifier i; @@ e1 -, +; e2; // </smpl> Signed-off-by: NJulia Lawall <Julia.Lawall@lip6.fr> Acked-by: NKevin Hilman <khilman@linaro.org> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Mathias Nyman 提交于
Missing pm_runtime_disable call in driver remove path caused an unbalanaced pm_runtime_enable warning when driver was reloaded Signed-off-by: NMathias Nyman <mathias.nyman@linux.intel.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Michael Brunner 提交于
This patch changes the driver name to be consistent with the name that is registered as cell name in the MFD driver. Otherwise the driver won't load. Reviewed-by: NGuenter Roeck <linux@roeck-us.net> Acked-by: NKevin Strasser <strassek@engr.orst.edu> Signed-off-by: NMichael Brunner <michael.brunner@kontron.com>
-
由 Lars Poeschel 提交于
In case request_threaded_irq inside adnp_irq_setup fails, the driver segfaults. This is because irq_domain_remove is called twice with the same pointer. First time in adnp_irq_setup and then a second time after leaving adnp_irq_setup in the error path of adnp_i2c_probe inside adnp_teardown. This fixes this by removing the call to irq_domain_remove from adnp_irq_setup. Signed-off-by: NLars Poeschel <poeschel@lemonage.de> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Jingoo Han 提交于
The local variable 'msm_gpio' is used only in this file. Fix the following sparse warning: drivers/gpio/gpio-msm-v2.c:109:21: warning: symbol 'msm_gpio' was not declared. Should it be static? Signed-off-by: NJingoo Han <jg1.han@samsung.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Lothar Waßmann 提交于
Signed-off-by: NLothar Waßmann <LW@KARO-electronics.de> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Jingoo Han 提交于
Use the wrapper function for retrieving the platform data instead of accessing dev->platform_data directly. Signed-off-by: NJingoo Han <jg1.han@samsung.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Uwe Kleine-König 提交于
Similar to commit 0e44b6ec (gpio/mxc: add chained_irq_enter/exit() to mx3_gpio_irq_handler()) . It doesn't seem to be critical to make the irqs work, but still it is more correct. Signed-off-by: NUwe Kleine-König <u.kleine-koenig@pengutronix.de> Acked-by: NShawn Guo <shawn.guo@linaro.org> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Daniel M. Weeks 提交于
The call to gpiochip_add made by this driver is capable of auto-selecting a base if one is not provided. However, it was not called unless there was already a DT entry or platform data. This patch calls it even if the base is not already known so that gpiochip_add can attempt to find a usable base. Signed-off-by: NDaniel M. Weeks <dan@danweeks.net> Acked-by: NLars Poeschel <poeschel@lemonage.de> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Andrew Chew 提交于
It seems that the value read back from the PALMAS_GPIO_DATA_IN register isn't valid if the GPIO direction is out. When that's the case, we can read back the PALMAS_GPIO_DATA_OUT register to get the proper output value. Signed-off-by: NAndrew Chew <achew@nvidia.com> Acked-by: NLaxman Dewangan <ldewangan@nvidia.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
- 31 7月, 2013 4 次提交
-
-
由 Stephen Boyd 提交于
drivers/gpio/gpio-msm-v1.c: In function 'gpio_msm_v1_probe': drivers/gpio/gpio-msm-v1.c:656:2: error: implicit declaration of function 'IS_ERR' [-Werror=implicit-function-declaration] drivers/gpio/gpio-msm-v1.c:657:3: error: implicit declaration of function 'PTR_ERR' [-Werror=implicit-function-declaration] This driver failed to compile after commit 68515bbe (gpio_msm: Convert to use devm_ioremap_resource, 2013-06-10). Acked-by: NTushar Behera <tushar.behera@linaro.org> Signed-off-by: NStephen Boyd <sboyd@codeaurora.org> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Linus Walleij 提交于
This reverts commit 0e970cec. Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Linus Walleij 提交于
This reverts commit b4419e1a. Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Linus Walleij 提交于
This reverts commit 949eb1a4. Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
- 30 7月, 2013 1 次提交
-
-
由 Laxman Dewangan 提交于
Add of_device_id table for Palma GPIO to be enable the driver from DT file. The driver can be registered from DT file as: palmas: tps65913@58 { ::::::::::: palmas_gpio: palmas_gpio { compatible = "ti,palmas-gpio"; gpio-controller; #gpio-cells = <2>; }; }; Signed-off-by: NLaxman Dewangan <ldewangan@nvidia.com> Acked-by: NStephen Warren <swarren@nvidia.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
- 23 7月, 2013 1 次提交
-
-
由 Fabio Estevam 提交于
Commit 8cd73e4e (gpio: gpio-mxc: Use devm functions) causes the following build error on imx_v4_v7_defconfig: drivers/gpio/gpio-mxc.c:414:2: error: implicit declaration of function 'IS_ERR' [-Werror=implicit-function-declaration] drivers/gpio/gpio-mxc.c:415:3: error: implicit declaration of function 'PTR_ERR' [-Werror=implicit-function-declaration] Note: imx_v6_v7_defconfig does not give this build error, probably due to some indirect header file inclusion. Reported-by: NOlof Johansson <olof@lixom.net> Signed-off-by: NFabio Estevam <fabio.estevam@freescale.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
- 22 7月, 2013 1 次提交
-
-
由 Daniel Mack 提交于
Commit f8731174 ("ARM: mmp: add more compatible names in gpio driver") changed the driver logic to determine the number of available GPIOs from the compatible string, and hence obsoleted the (undocumented) child nodes that were previously necessary. However, it left some remainder which can be safely removed now. Also, this patch makes pxa_gpio_probe_dt() return the correct value in case irq_alloc_descs() fails. Signed-off-by: NDaniel Mack <zonque@gmail.com> Cc: Haojian Zhuang <haojian.zhuang@linaro.org> Cc: Linus Walleij <linus.walleij@linaro.org> Cc: Arnd Bergmann <arnd@arndb.de> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
- 21 7月, 2013 5 次提交
-
-
由 Magnus Damm 提交于
Register the GPIO pin range, and request and free GPIO pins using the pinctrl API. The pctl_name platform data member should be used by platform devices to point out which pinctrl device to use. Follows same style as "dc3465a9 gpio-rcar: Add pinctrl support", by Laurent Pinchart, thanks to him. Signed-off-by: NMagnus Damm <damm@opensource.se> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Guenter Roeck 提交于
Add gpio support for the on-board PLD found on some Kontron embedded modules. Originally-from: Michael Brunner <michael.brunner@kontron.com> Signed-off-by: NGuenter Roeck <linux@roeck-us.net> Signed-off-by: NKevin Strasser <kevin.strasser@linux.intel.com> Acked-by: NDarren Hart <dvhart@linux.intel.com> Reviewed-by: NLinus Walleij <linus.walleij@linaro.org> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Jingoo Han 提交于
The usage of strict_strtol() is not preferred, because strict_strtol() is obsolete. Thus, kstrtol() should be used. Signed-off-by: NJingoo Han <jg1.han@samsung.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Rohit Vaswani 提交于
of_property_read_u32 return 0 on success. The check was using a ! to return error. Fix the if condition. Signed-off-by: NRohit Vaswani <rvaswani@codeaurora.org> Acked-by: NLinus Walleij <linus.walleij@linaro.org> Reviewed-by: NPankaj Jangra <jangra.pankaj9@gmail.com> Cc: "Bird, Tim" <Tim.Bird@sonymobile.com> Signed-off-by: NDavid Brown <davidb@codeaurora.org> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Peter Ujfalusi 提交于
TWL6040 is used only with OMAP4/5 SoCs and they can only boot in in DT mode. The support for pdata/legacy boot can be removed. Signed-off-by: NPeter Ujfalusi <peter.ujfalusi@ti.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-