- 08 4月, 2015 1 次提交
-
-
由 Huacai Chen 提交于
Improve Loongson-2's GPIO driver to support Loongson-3A/3B, and update Loongson-3's default config file. Acked-by: NRalf Baechle <ralf@linux-mips.org> Signed-off-by: NHuacai Chen <chenhc@lemote.com> Reviewed-by: NAlexandre Courbot <acourbot@nvidia.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
- 07 4月, 2015 2 次提交
-
-
由 Huacai Chen 提交于
Move Loongson-2's GPIO driver to drivers/gpio and add Kconfig options. Acked-by: NRalf Baechle <ralf@linux-mips.org> Signed-off-by: NHuacai Chen <chenhc@lemote.com> Reviewed-by: NAlexandre Courbot <acourbot@nvidia.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Huacai Chen 提交于
This cleanup is prepare to move the driver to drivers/gpio. Custom definitions of gpio_get_value()/gpio_set_value() are dropped. Acked-by: NRalf Baechle <ralf@linux-mips.org> Signed-off-by: NHuacai Chen <chenhc@lemote.com> Reviewed-by: NAlexandre Courbot <acourbot@nvidia.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
- 27 3月, 2015 10 次提交
-
-
由 Dmitry Torokhov 提交于
Even if bus is not hot-pluggable, the devices can be unbound from the driver via sysfs, so we should not be using __exit annotations on remove() methods. The only exception is drivers registered with platform_driver_probe() which specifically disables sysfs bind/unbind attributes. Signed-off-by: NDmitry Torokhov <dmitry.torokhov@gmail.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Grygorii Strashko 提交于
Now OMAP GPIO driver prepared for GPIO_INDEX() macro removing. Do It ;) Tested-by: NTony Lindgren <tony@atomide.com> Tested-by: NAaro Koskinen <aaro.koskinen@iki.fi> Acked-by: NSantosh Shilimkar <ssantosh@kernel.org> Acked-by: NJavier Martinez Canillas <javier@dowhile0.org> Signed-off-by: NGrygorii Strashko <grygorii.strashko@linaro.org> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Grygorii Strashko 提交于
Now OMAP GPIO driver prepared for omap_irq_to_gpio() removing. Do it ;) Tested-by: NTony Lindgren <tony@atomide.com> Tested-by: NAaro Koskinen <aaro.koskinen@iki.fi> Acked-by: NSantosh Shilimkar <ssantosh@kernel.org> Acked-by: NJavier Martinez Canillas <javier@dowhile0.org> Signed-off-by: NGrygorii Strashko <grygorii.strashko@linaro.org> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Grygorii Strashko 提交于
Now OMAP GPIO driver prepared for GPIO_BIT() macro removing. Do it ;) Tested-by: NTony Lindgren <tony@atomide.com> Tested-by: NAaro Koskinen <aaro.koskinen@iki.fi> Acked-by: NSantosh Shilimkar <ssantosh@kernel.org> Acked-by: NJavier Martinez Canillas <javier@dowhile0.org> Signed-off-by: NGrygorii Strashko <grygorii.strashko@linaro.org> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Grygorii Strashko 提交于
Convert GPIO IRQ functions to use GPIO offset instead of system GPIO numbers. This allows to drop unneeded conversations between system GPIO <-> GPIO offset which are done in many places and many times. It is safe to do now because: - gpiolib always passes GPIO offset to GPIO controller - OMAP GPIO driver converted to use IRQ domain, so struct irq_data->hwirq contains GPIO offset This is preparation step before removing: #define GPIO_INDEX(bank, gpio) #define GPIO_BIT(bank, gpio) int omap_irq_to_gpio() Tested-by: NTony Lindgren <tony@atomide.com> Tested-by: NAaro Koskinen <aaro.koskinen@iki.fi> Acked-by: NSantosh Shilimkar <ssantosh@kernel.org> Acked-by: NJavier Martinez Canillas <javier@dowhile0.org> Signed-off-by: NGrygorii Strashko <grygorii.strashko@linaro.org> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Grygorii Strashko 提交于
The 'gpio' parameter isn't needed any more as it duplicates 'offset' parameter, so drop it. Tested-by: NTony Lindgren <tony@atomide.com> Tested-by: NAaro Koskinen <aaro.koskinen@iki.fi> Acked-by: NSantosh Shilimkar <ssantosh@kernel.org> Acked-by: NJavier Martinez Canillas <javier@dowhile0.org> Signed-off-by: NGrygorii Strashko <grygorii.strashko@linaro.org> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Grygorii Strashko 提交于
Convert debounce functions to use GPIO offset instead of system GPIO numbers. This allows to drop unneeded conversations between system GPIO <-> GPIO offset which are done in many places and many times. It is safe to do now because: - gpiolib always passes GPIO offset to GPIO controller - OMAP GPIO driver converted to use IRQ domain This is preparation step before removing: #define GPIO_INDEX(bank, gpio) #define GPIO_BIT(bank, gpio) int omap_irq_to_gpio() Tested-by: NTony Lindgren <tony@atomide.com> Tested-by: NAaro Koskinen <aaro.koskinen@iki.fi> Acked-by: NSantosh Shilimkar <ssantosh@kernel.org> Acked-by: NJavier Martinez Canillas <javier@dowhile0.org> Signed-off-by: NGrygorii Strashko <grygorii.strashko@linaro.org> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Grygorii Strashko 提交于
Both functions omap_set_gpio_dataout_reg() and omap_set_gpio_dataout_mask() accept GPIO offset as 'gpio' input parameter, so rename it to 'offset' and drop usage of GPIO_BIT() macro. Tested-by: NTony Lindgren <tony@atomide.com> Tested-by: NAaro Koskinen <aaro.koskinen@iki.fi> Acked-by: NSantosh Shilimkar <ssantosh@kernel.org> Acked-by: NJavier Martinez Canillas <javier@dowhile0.org> Signed-off-by: NGrygorii Strashko <grygorii.strashko@linaro.org> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Grygorii Strashko 提交于
Convert omap_gpio_is_input() to use GPIO offset instead of mask and, in such way, make code simpler and remove few lines of code. Tested-by: NTony Lindgren <tony@atomide.com> Tested-by: NAaro Koskinen <aaro.koskinen@iki.fi> Acked-by: NSantosh Shilimkar <ssantosh@kernel.org> Acked-by: NJavier Martinez Canillas <javier@dowhile0.org> Signed-off-by: NGrygorii Strashko <grygorii.strashko@linaro.org> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 kbuild test robot 提交于
Signed-off-by: NFengguang Wu <fengguang.wu@intel.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
- 26 3月, 2015 4 次提交
-
-
由 Geert Uytterhoeven 提交于
When the GPIO module is needed for wake-up, it's module clock must not be disabled. Hence implement irq_chip.irq_set_wake(), which increments/decrements the clock's enable_count when needed, and forwards the wake-up state to the upstream interrupt controller. This fixes wake-up from s2ram using gpio-keys when using a PM Domain to manage the module clock. Signed-off-by: NGeert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Geert Uytterhoeven 提交于
Signed-off-by: NGeert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Geert Uytterhoeven 提交于
The existing variable gpio_chip already points to the gpiochip instance, hence use it everywhere. Signed-off-by: NGeert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Shobhit Kumar 提交于
Export PANEL_EN/DISABLE (offset 0x52) as additional GPIO. Needed by display driver to enable the DSI panel on BYT platform where the Panel EN/Disable control is routed thorugh CRC PMIC CC: Samuel Ortiz <sameo@linux.intel.com> Cc: Linus Walleij <linus.walleij@linaro.org> Cc: Alexandre Courbot <gnurou@gmail.com> Cc: Thierry Reding <thierry.reding@gmail.com> Acked-by: NDaniel Vetter <daniel@ffwll.ch> Signed-off-by: NShobhit Kumar <shobhit.kumar@intel.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
- 19 3月, 2015 4 次提交
-
-
由 Andy Shevchenko 提交于
The Intel Quark SoC contains the DW GPIO on board. While fixing the build error the commit 1972c97d (gpio: dwapb: fix compile errors) disables the possibility to build the driver on X86, i.e. Intel Quark. The patch reenables it for Intel Quark as well. Since we have Intel Quark SoC introduced in 4.0-rc1 I would like to make this fix available there as well, though the actual MFD driver [1] is applied only for next version. [1] https://lkml.org/lkml/2015/2/1/217 Fixes: 1972c97d (gpio: dwapb: fix compile errors) Signed-off-by: NAndy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Rafael J. Wysocki 提交于
In acpi_gpiochip_request_interrupts() the handle local variable already contains the value that we want to pass to acpi_walk_resources(), so it is better to use that variable instead of evaluating ACPI_HANDLE() once more for the same device. Signed-off-by: NRafael J. Wysocki <rafael.j.wysocki@intel.com> Acked-by: NMika Westerberg <mika.westerberg@linux.intel.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Rafael J. Wysocki 提交于
If dev is NULL in __gpiod_get_index() and both ACPI and OF are enabled, it will be checked twice before the code decides to give up with DT/ACPI lookup, so avoid that. Also use the observation that ACPI_COMPANION() is much more efficient than ACPI_HANDLE(), because the latter uses the former and carries out a check and a pointer dereference on top of it, so replace the ACPI_HANDLE() check with an ACPI_COMPANION() one which does not require the additional IS_ENABLED(CONFIG_ACPI) check too. Signed-off-by: NRafael J. Wysocki <rafael.j.wysocki@intel.com> Reviewed-by: NHanjun Guo <hanjun.guo@linaro.org> Acked-by: NMika Westerberg <mika.westerberg@linux.intel.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Linus Walleij 提交于
These functions do not belong in <asm-generic/gpio.h> since the split into separate GPIO headers under <linux/gpio/*>. Move them to <linux/gpio/driver.h> as is apropriate. Acked-by: NAlexandre Courbot <acourbot@nvidia.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
- 18 3月, 2015 4 次提交
-
-
由 Andreas Bofjall 提交于
Add support for the GPIOs found on the Fintek SuperI/O chip F71869A, such as the one found on the Jetway JNF99-525 motherboard, to the f7188x gpio driver. Signed-off-by: NAndreas Bofjall <andreas@gazonk.org> Reviewed-by: NAlexandre Courbot <acourbot@nvidia.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Andreas Bofjall 提交于
Add support for the GPIOs found on the Fintek SuperI/O chip F71869, such as the one found on the Jetway NF96u-525 motherboard, to the f7188x gpio driver. Signed-off-by: NAndreas Bofjall <andreas@gazonk.org> Tested-by: NLes Schaffer <schaffer@optonline.net> Reviewed-by: NAlexandre Courbot <acourbot@nvidia.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Andreas Bofjall 提交于
The company is called "Fintek", not "Fintech". Fix it. Signed-off-by: NAndreas Bofjall <andreas@gazonk.org> Reviewed-by: NAlexandre Courbot <acourbot@nvidia.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Linus Walleij 提交于
Commit 1feb57a2 "gpio: add parameter to allow the use named gpios" includes a double-consted array. What we want is not const const * but const * const (const pointer to const data). Fix this. Reported-by: NDan Carpenter <dan.carpenter@oracle.com> Cc: Olliver Schinagl <oliver@schinagl.nl> Cc: Rojhalat Ibrahim <imr@rtschenk.de> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
- 10 3月, 2015 2 次提交
-
-
由 Grygorii Strashko 提交于
GPIOLib core implemnts irqchip->irq_request/release_resources callbacks internally and these callbacks already contain clalls of gpiochip_lock/unlock_as_irq(). Hence, remove unnecessary call of gpiochip_unlock_as_irq() from omap_gpio_irq_shutdown(). Signed-off-by: NGrygorii Strashko <grygorii.strashko@linaro.org> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Rojhalat Ibrahim 提交于
Extend the documentation for the gpiod_set_array() functions and elaborate a bit on possible use cases. Signed-off-by: NRojhalat Ibrahim <imr@rtschenk.de> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
- 09 3月, 2015 3 次提交
-
-
由 Josh Wu 提交于
fix typo in the document. Signed-off-by: NJosh Wu <josh.wu@atmel.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Rob Herring 提交于
The macro BANK_OFF which calculates the base offset for each GPIO port. The macro is needlessly complex and unreadable. Simplify the calculation to a simple math operation. Signed-off-by: NRob Herring <robh@kernel.org> Cc: linux-gpio@vger.kernel.org Reviewed-by: NAlexandre Courbot <acourbot@nvidia.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Kefeng Wang 提交于
Hisilicon arm64 soc uses designWare gpio, re-enable it after commit 1972c97d(gpio: dwapb: fix compile errors). Signed-off-by: NKefeng Wang <wangkefeng.wang@huawei.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
- 08 3月, 2015 2 次提交
-
-
由 Tien Hock Loh 提交于
Adds a new driver device tree binding for Altera soft GPIO IP Signed-off-by: NTien Hock Loh <thloh@altera.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Tien Hock Loh 提交于
Adds a new driver for Altera soft GPIO IP. The driver is able to do read/write and allows GPIO to be a interrupt controller. Tested on Altera GHRD on interrupt handling and IO. v10: - Updated conflicting device tree parameters - Removed unused headers - Used macro instead of magic numbers for ngpio - Code readability cleanup using ?: and temporal variables - Removed leftover garbage and unnecessary function calls - Checked bgpio_init but unusable because Altera GPIO may not be a multiple of 8 bits v9: - Removed duplicated initialization on set_type using temporals to improve code readability in calling generic_handle_irq - Using ?: ternary to reduce code size v8: - Using for_each_set_bit - Added const for struct definition - Removed naggy pr_err - Sort alpha header - Remove unused macros - Use fixed width data types instead of unsigned long - Whitespace issue fixes - Removed _relaxed function for better compatibility across different CPU - Changed irq_create_mapping to platform_get_irq updated implementation to use gpiochip_irqchip_add - Reserve interrupt-cells number 2 in device tree binding for future use - Remove confusing sections on devicetree bindings - Added tristate Kconfig help text v7: - Used dev_warn instead of pr_warn - Clean up unnecesarry if else indentation v6: - Added irq_startup and irq_shutdown - Changed bitwise clamping style - Cleanup bitwise operation to improve readability change naming of mapped irqs from virq to mapped_irq v5: - Dispose irq_domain mapping correctly - Update optional binding description in binding docs v4: - Added vendor prefix to devicetree binding for IP specific properties using MMIO GPIO helper library instead of manually map PIO to memory - altera_gpio_chip inline struct documentation to kerneldoc - Using dev_ print to print a better failure message v2, v3: - Do not reference NO_IRQ - Updated irq_set_type to only allow the hardware configured irq type Signed-off-by: NTien Hock Loh <thloh@altera.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
- 06 3月, 2015 1 次提交
-
-
由 Axel Lin 提交于
Signed-off-by: NAxel Lin <axel.lin@ingics.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
- 05 3月, 2015 3 次提交
-
-
由 Rojhalat Ibrahim 提交于
Add device managed variants of gpiod_get_array() / gpiod_put_array() functions for conveniently obtaining and disposing of an entire array of GPIOs with one function call. Signed-off-by: NRojhalat Ibrahim <imr@rtschenk.de> Reviewed-by: NAlexandre Courbot <acourbot@nvidia.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Rojhalat Ibrahim 提交于
Introduce new functions for conveniently obtaining and disposing of an entire array of GPIOs with one function call. ACPI parts tested by Mika Westerberg, DT parts tested by Rojhalat Ibrahim. Change log: v5: move the ACPI functions to gpiolib-acpi.c v4: - use shorter names for members of struct gpio_descs - rename lut_gpio_count to platform_gpio_count for clarity - add check for successful memory allocation - use ERR_CAST() v3: - rebase on current linux-gpio devel branch - fix ACPI GPIO counting - allow for zero-sized arrays - make the flags argument mandatory for the new functions - clarify documentation v2: change interface Suggested-by: NAlexandre Courbot <acourbot@nvidia.com> Signed-off-by: NRojhalat Ibrahim <imr@rtschenk.de> Reviewed-by: NAlexandre Courbot <acourbot@nvidia.com> Reviewed-by: NMika Westerberg <mika.westerberg@linux.intel.com> Tested-by: NMika Westerberg <mika.westerberg@linux.intel.com> Tested-by: NRojhalat Ibrahim <imr@rtschenk.de> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Rojhalat Ibrahim 提交于
Avoid multiple identical definitions of the gpio suffix strings by putting them into a global constant array. Signed-off-by: NRojhalat Ibrahim <imr@rtschenk.de> Reviewed-by: NAlexandre Courbot <acourbot@nvidia.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
- 04 3月, 2015 4 次提交
-
-
由 Olliver Schinagl 提交于
The gpio binding document says that new code should always use named gpios. Patch 40b73183 added support to parse a list of gpios from child nodes, but does not make it possible to use named gpios. This patch adds the con_id property and implements it is done in gpiolib.c, where the old-style of using unnamed gpios still works. Signed-off-by: NOlliver Schinagl <oliver@schinagl.nl> Acked-by: NBryan Wu <cooloney@gmail.com> Acked-by: NDmitry Torokhov <dmitry.torokhov@gmail.com> Reviewed-by: NAlexandre Courbot <acourbot@nvidia.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Geert Uytterhoeven 提交于
The pcf857x GPIO and interrupt controller uses dummy_irq_chip, which does not implement irq_chip.irq_set_wake() and does not set IRQCHIP_SKIP_SET_WAKE. This causes two s2ram issues if wake-up is enabled for the pcf857x GPIO pins: 1. During resume from s2ram, the following warning is printed: WARNING: CPU: 0 PID: 1046 at kernel/irq/manage.c:537 irq_set_irq_wake+0x9c/0xf8() Unbalanced IRQ 113 wake disable 2. Wake-up through the pcf857x GPIO pins may fail, as the parent interrupt controller may be suspended. Migrate the pcf857x GPIO and interrupt controller from dummy_irq_chip to its own irq_chip. This irq chip implements irq_chip.irq_set_wake() to propagate its wake-up setting to the parent interrupt controller. This fixes wake-up through gpio-keys on sh73a0/kzm9g, where the pcf857x interrupt is cascaded to irq-renesas-intc-irqpin, and the latter must not be suspended when wake-up is enabled. Signed-off-by: NGeert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Geert Uytterhoeven 提交于
Switch the PCF857x GPIO driver to use the gpiolib irqchip helpers. This driver uses a nested threaded interrupt, hence handle_nested_irq() and gpiochip_set_chained_irqchip() must be used. Note that this removes the checks added in commit 21fd3cd1 ("gpio: pcf857x: call the gpio user handler iff gpio_to_irq is done"), as the interrupt mappings are no longer created on-demand by the driver, but by gpiochip_irqchip_add() during initialization. Signed-off-by: NGeert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-
由 Benoit Parrot 提交于
Add GPIO hogging documentation to gpio.txt Signed-off-by: NBenoit Parrot <bparrot@ti.com> Reviewed-by: NAlexandre Courbot <acourbot@nvidia.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
-