17 Oct, 2015

1 commit

  • Replace all trivial request/free callbacks that do nothing but call into
    pinctrl code with the generic versions.

    Signed-off-by: Jonas Gorski
    Acked-by: Bjorn Andersson
    Acked-by: Heiko Stuebner
    Acked-by: Eric Anholt
    Acked-by: Mika Westerberg
    Acked-by: Andrew Bresticker
    Acked-by: Baruch Siach
    Acked-by: Matthias Brugger
    Acked-by: Lee Jones
    Acked-by: Laxman Dewangan
    Acked-by: Maxime Ripard
    Signed-off-by: Linus Walleij

    Jonas Gorski
     

16 Sep, 2015

1 commit

  • Most interrupt flow handlers do not use the irq argument. Those few
    which use it can retrieve the irq number from the irq descriptor.

    Remove the argument.

    Search and replace was done with coccinelle and some extra helper
    scripts around it. Thanks to Julia for her help!

    Signed-off-by: Thomas Gleixner
    Cc: Julia Lawall
    Cc: Jiang Liu

    Thomas Gleixner
     

05 Sep, 2015

1 commit

  • Pull pin control updates from Linus Walleij:
    "This is the bulk of pin control changes for the v4.3 development
    cycle.

    Like with GPIO it's a lot of stuff. If my subsystems are any sign of
    the overall tempo of the kernel v4.3 will be a gigantic diff.

    [ It looks like 4.3 is calmer than 4.2 in most other subsystems, but
    we'll see - Linus ]

    Core changes:

    - It is possible configure groups in debugfs.

    - Consolidation of chained IRQ handler install/remove replacing all
    call sites where irq_set_handler_data() and
    irq_set_chained_handler() were done in succession with a combined
    call to irq_set_chained_handler_and_data(). This series was
    created by Thomas Gleixner after the problem was observed by
    Russell King.

    - Tglx also made another series of patches switching
    __irq_set_handler_locked() for irq_set_handler_locked() which is
    way cleaner.

    - Tglx also wrote a good bunch of patches to make use of
    irq_desc_get_xxx() accessors and avoid looking up irq_descs from
    IRQ numbers. The goal is to get rid of the irq number from the
    handlers in the IRQ flow which is nice.

    Driver feature enhancements:

    - Power management support for the SiRF SoC Atlas 7.

    - Power down support for the Qualcomm driver.

    - Intel Cherryview and Baytrail: switch drivers to use raw spinlocks
    in IRQ handlers to play nice with the realtime patch set.

    - Rework and new modes handling for Qualcomm SPMI-MPP.

    - Pinconf power source config for SH PFC.

    New drivers and subdrivers:

    - A new driver for Conexant Digicolor CX92755.

    - A new driver for UniPhier PH1-LD4, PH1-Pro4, PH1-sLD8, PH1-Pro5,
    ProXtream2 and PH1-LD6b SoC pin control support.

    - Reverse-egineered the S/PDIF settings for the Allwinner sun4i
    driver.

    - Support for Qualcomm Technologies QDF2xxx ARM64 SoCs

    - A new Freescale i.mx6ul subdriver.

    Cleanup:

    - Remove platform data support in a number of SH PFC subdrivers"

    * tag 'pinctrl-v4.3-1' of git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-pinctrl: (95 commits)
    pinctrl: at91: fix null pointer dereference
    pinctrl: mediatek: Implement wake handler and suspend resume
    pinctrl: mediatek: Fix multiple registration issue.
    pinctrl: sh-pfc: r8a7794: add USB pin groups
    pinctrl: at91: Use generic irq_{request,release}_resources()
    pinctrl: cherryview: Use raw_spinlock for locking
    pinctrl: baytrail: Use raw_spinlock for locking
    pinctrl: imx6ul: Remove .owner field
    pinctrl: zynq: Fix typos in smc0_nand_grp and smc0_nor_grp
    pinctrl: sh-pfc: Implement pinconf power-source param for voltage switching
    clk: rockchip: add pclk_pd_pmu to the list of rk3288 critical clocks
    pinctrl: sun4i: add spdif to pin description.
    pinctrl: atlas7: clear ugly branch statements for pull and drivestrength
    pinctrl: baytrail: Serialize all register access
    pinctrl: baytrail: Drop FSF mailing address
    pinctrl: rockchip: only enable gpio clock when it setting
    pinctrl/mediatek: fix spelling mistake in dev_err error message
    pinctrl: cherryview: Serialize all register access
    pinctrl: UniPhier: PH1-Pro5: add I2C ch6 pin-mux setting
    pinctrl: nomadik: reflect current input value
    ...

    Linus Torvalds
     

11 Aug, 2015

1 commit


28 Jul, 2015

1 commit


27 Jul, 2015

2 commits

  • We no longer have to do GPIO initialization before the
    pinctrl initialization, instead we can initialize the pinctrl
    portions of the driver first and then the GPIO. Thus we can
    move GPIO initialization to a subsystem_initcall(), but
    not yet to a device_initcall().

    Signed-off-by: Linus Walleij

    Linus Walleij
     
  • This gets the GPIO ranges out of the driver and into the device
    tree where they belong. Standard DT bindings already exist for
    this. Since no systems with this are deployed we can just augment
    all device trees and the drivers at the same time and simplify
    the world.

    This also defines the array of GPIO chips related to the pin
    controller.

    Cc: arm@kernel.org
    Acked-by: Olof Johansson
    Signed-off-by: Linus Walleij

    Linus Walleij
     

23 Jul, 2015

3 commits


20 Jul, 2015

1 commit

  • Commit a21763a0b1e5a5ab8310f581886d04beadc16616
    "pinctrl: nomadik: activate strict mux mode"
    put all Nomadik pin controllers to strict mode. This was
    not good on the Snowball platform: the muxing of GPIOs to
    different pins is done with hogs in the DTS file, and then
    these GPIOs are used by offset, relying on hogs to mux the
    pins. Since that means the pin controller "owns" the pins
    and at the same time we have a GPIO user, this pin controller
    is by definition not strict.

    Signed-off-by: Linus Walleij

    Linus Walleij
     

18 Jul, 2015

1 commit


10 Jun, 2015

1 commit

  • Currently, pinctrl_register() just returns NULL on error, so the
    callers can not know the exact reason of the failure.

    Some of the pinctrl drivers return -EINVAL, some -ENODEV, and some
    -ENOMEM on error of pinctrl_register(), although the error code
    might be different from the real cause of the error.

    This commit reworks pinctrl_register() to return the appropriate
    error code and modifies all of the pinctrl drivers to use IS_ERR()
    for the error checking and PTR_ERR() for getting the error code.

    Signed-off-by: Masahiro Yamada
    Acked-by: Patrice Chotard
    Acked-by: Thierry Reding
    Acked-by: Heiko Stuebner
    Tested-by: Mika Westerberg
    Acked-by: Mika Westerberg
    Acked-by: Lee Jones
    Acked-by: Sören Brinkmann
    Acked-by: Laurent Pinchart
    Acked-by: Ray Jui
    Acked-by: Antoine Tenart
    Acked-by: Hongzhou Yang
    Acked-by: Wei Chen
    Signed-off-by: Linus Walleij

    Masahiro Yamada
     

01 Jun, 2015

1 commit


06 May, 2015

2 commits


15 Apr, 2015

2 commits

  • There was some mess in the dependencies in the pinctrl
    Kconfig for compile tests under allmodconfig. Mea Culpa.

    Reported-by: Linus Torvalds
    Signed-off-by: Linus Walleij

    Linus Walleij
     
  • Pull trivial tree from Jiri Kosina:
    "Usual trivial tree updates. Nothing outstanding -- mostly printk()
    and comment fixes and unused identifier removals"

    * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/trivial:
    goldfish: goldfish_tty_probe() is not using 'i' any more
    powerpc: Fix comment in smu.h
    qla2xxx: Fix printks in ql_log message
    lib: correct link to the original source for div64_u64
    si2168, tda10071, m88ds3103: Fix firmware wording
    usb: storage: Fix printk in isd200_log_config()
    qla2xxx: Fix printk in qla25xx_setup_mode
    init/main: fix reset_device comment
    ipwireless: missing assignment
    goldfish: remove unreachable line of code
    coredump: Fix do_coredump() comment
    stacktrace.h: remove duplicate declaration task_struct
    smpboot.h: Remove unused function prototype
    treewide: Fix typo in printk messages
    treewide: Fix typo in printk messages
    mod_devicetable: fix comment for match_flags

    Linus Torvalds
     

07 Mar, 2015

1 commit


12 Jan, 2015

1 commit

  • Additionally to the generic DT parameters, allow drivers to provide
    driver-specific DT parameters to be used with the generic parser
    infrastructure.

    To achieve this 'struct pinctrl_desc' is extended to pass custom pinconf
    option to the core. In order to pass this kind of information, the
    related data structures - 'struct pinconf_generic_dt_params',
    'pin_config_item' - are moved from pinconf internals to the
    pinconf-generic header.

    Additionally pinconfg-generic is refactored to not only iterate over the
    generic pinconf parameters but also take the parameters into account
    that are provided through the driver's 'struct pinctrl_desc'.
    In particular 'pinconf_generic_parse_dt_config()' and
    'pinconf_generic_dump' helpers are split into two parts each. In order
    to have a more generic helper that can be used to process the generic
    parameters as well as the driver-specific ones.

    v2:
    - fix typo
    - add missing documentation for @conf_items member in struct
    - rebase to pinctrl/devel: conflict in abx500
    - rename _pinconf_generic_dump() to pinconf_generic_dump_one()
    - removed '_' from _parse_dt_cfg()
    - removed BUG_ONs, error condition is handled in if statements
    - removed pinconf_generic_dump_group() & pinconf_generic_dump_pin
    helpers
    - fixed up corresponding call sites
    - renamed pinconf_generic_dump() to pinconf_generic_dump_pins()
    - added kernel-doc to pinconf_generic_dump_pins()
    - add kernel-doc
    - more verbose commit message

    Signed-off-by: Soren Brinkmann
    Tested-by: Andreas Färber
    Signed-off-by: Linus Walleij

    Soren Brinkmann
     

15 Dec, 2014

1 commit

  • Pull driver core update from Greg KH:
    "Here's the set of driver core patches for 3.19-rc1.

    They are dominated by the removal of the .owner field in platform
    drivers. They touch a lot of files, but they are "simple" changes,
    just removing a line in a structure.

    Other than that, a few minor driver core and debugfs changes. There
    are some ath9k patches coming in through this tree that have been
    acked by the wireless maintainers as they relied on the debugfs
    changes.

    Everything has been in linux-next for a while"

    * tag 'driver-core-3.19-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core: (324 commits)
    Revert "ath: ath9k: use debugfs_create_devm_seqfile() helper for seq_file entries"
    fs: debugfs: add forward declaration for struct device type
    firmware class: Deletion of an unnecessary check before the function call "vunmap"
    firmware loader: fix hung task warning dump
    devcoredump: provide a one-way disable function
    device: Add dev__once variants
    ath: ath9k: use debugfs_create_devm_seqfile() helper for seq_file entries
    ath: use seq_file api for ath9k debugfs files
    debugfs: add helper function to create device related seq_file
    drivers/base: cacheinfo: remove noisy error boot message
    Revert "core: platform: add warning if driver has no owner"
    drivers: base: support cpu cache information interface to userspace via sysfs
    drivers: base: add cpu_device_create to support per-cpu devices
    topology: replace custom attribute macros with standard DEVICE_ATTR*
    cpumask: factor out show_cpumap into separate helper function
    driver core: Fix unbalanced device reference in drivers_probe
    driver core: fix race with userland in device_add()
    sysfs/kernfs: make read requests on pre-alloc files use the buffer.
    sysfs/kernfs: allow attributes to request write buffer be pre-allocated.
    fs: sysfs: return EGBIG on write if offset is larger than file size
    ...

    Linus Torvalds
     

20 Oct, 2014

8 commits


10 Oct, 2014

1 commit

  • Pull GPIO changes from Linus Walleij:
    "This is the bulk of GPIO changes for the v3.18 development cycle:

    - Increase the default ARCH_NR_GPIO from 256 to 512. This was done
    to avoid having a custom header for the x86
    architecture - GPIO is custom and complicated enough as it is
    already! We want to move to a radix to store the descriptors going
    forward, and finally get rid of this fixed array size altogether.

    - Endgame patching of the gpio_remove() semantics initiated by
    Abdoulaye Berthe. It is not accepted by the system that the
    removal of a GPIO chip fails during eg reboot or shutdown, and
    therefore the return value has now painfully been refactored away.
    For special cases like GPIO expanders on a hot-pluggable bus like
    USB, we may later add some gpiochip_try_remove() call, but for the
    cases we have now, return values are moot.

    - Some incremental refactoring of the gpiolib core and ACPI GPIO
    library for more descriptor usage.

    - Refactor the chained IRQ handler set-up method to handle also
    threaded, nested interrupts and set up the parent IRQ correctly.
    Switch STMPE and TC3589x drivers to use this registration method.

    - Add a .irq_not_threaded flag to the struct gpio_chip, so that also
    GPIO expanders that block but are still not using threaded IRQ
    handlers.

    - New drivers for the ARM64 X-Gene SoC GPIO controller.

    - The syscon GPIO driver has been improved to handle the "DSP GPIO"
    found on the TI Keystone 2 SoC:s.

    - ADNP driver switched to use gpiolib irqchip helpers.

    - Refactor the DWAPB driver to support being instantiated from and
    MFD cell (platform device).

    - Incremental feature improvement in the Zynq, MCP23S08, DWAPB, OMAP,
    Xilinx and Crystalcove drivers.

    - Various minor fixes"

    * tag 'gpio-v3.18-1' of git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-gpio: (52 commits)
    gpio: pch: Build context save/restore only for PM
    pinctrl: abx500: get rid of unused variable
    gpio: ks8695: fix 'else should follow close brace '}''
    gpio: stmpe: add verbose debug code
    gpio: stmpe: fix up interrupt enable logic
    gpio: staticize xway_stp_init()
    gpio: handle also nested irqchips in the chained handler set-up
    gpio: set parent irq on chained handlers
    gpiolib: irqchip: use irq_find_mapping while removing irqchip
    gpio: crystalcove: support virtual GPIO
    pinctrl: bcm281xx: make Kconfig dependency more strict
    gpio: kona: enable only on BCM_MOBILE or for compile testing
    gpio, bcm-kona, LLVMLinux: Remove use of __initconst
    gpio: Fix ngpio in gpio-xilinx driver
    gpio: dwapb: fix pointer to integer cast
    gpio: xgene: Remove unneeded #ifdef CONFIG_OF guard
    gpio: xgene: Remove unneeded forward declation for struct xgene_gpio
    gpio: xgene: Fix missing spin_lock_init()
    gpio: ks8695: fix switch case indentation
    gpiolib: add irq_not_threaded flag to gpio_chip
    ...

    Linus Torvalds
     

08 Oct, 2014

1 commit

  • Pull pin control changes from Linus Walleij:
    "This is the bulk of pin control changes for the v3.18 development
    series:

    - New drivers for the Freescale i.MX21, Qualcomm APQ8084 pin
    controllers.

    - Incremental new features on the Rockchip, atlas 6, OMAP, AM437x,
    APQ8064, prima2, AT91, Tegra, i.MX, Berlin and Nomadik.

    - Push Freescale drivers down into their own subdirectory.

    - Assorted sprays of syntax and semantic fixes"

    * tag 'pinctrl-v3.18-1' of git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-pinctrl: (48 commits)
    pinctrl: specify bindings for pins and groups
    pinctrl: nomadik: improve GPIO debug prints
    pinctrl: abx500: refactor DT parser to take two paths
    pinctrl: abx500: use helpers for map allocation/free
    pinctrl: alter device tree bindings for functions
    pinctrl: nomadik: refactor DT parser to take two paths
    pinctrl: nomadik: use utils map free function
    pinctrl: nomadik: use util function to reserve maps
    pinctrl: qcom: use restart_notifier mechanism for ps_hold
    pinctrl: sh-pfc: sh73a0: Remove unnecessary SoC data allocation
    pinctrl: berlin: fix the dt_free_map function
    pinctrl: at91: disable PD or PU before enabling PU or PD
    pinctrl: st: remove gpiochip in failure cases
    pinctrl: at91: Fix error handling while doing gpiochio_irqchip_add
    pinctrl: at91: Fix failure path in at91_gpio_probe path
    pinctrl: lantiq: Release gpiochip resources in fail case
    pinctrl: imx: detect uninitialized pins
    pinctrl: tegra: Add MIPI pad control
    pinctrl: at91: Switch to using managed clk_get
    pinctrl: adi2: Remove duplicate gpiochip_remove_pin_ranges
    ...

    Linus Torvalds
     

02 Oct, 2014

1 commit

  • commit 2fcea6cecbc965b4e02a39537d9d939f5251bbbd
    "pinctrl: remove remaining users of gpiochip_remove() retval"
    removed the use of the return value from gpiochip_remove()
    but missed to delete the dangling "err" variable:

    drivers/pinctrl/nomadik/pinctrl-abx500.c:
    In function 'abx500_gpio_probe':
    drivers/pinctrl/nomadik/pinctrl-abx500.c:1208:11:
    warning: unused variable 'err' [-Wunused-variable]

    Fix this by getting rid of the dangling variable.

    Reported-by: Arnd Bergmann
    Signed-off-by: Linus Walleij

    Linus Walleij
     

30 Sep, 2014

3 commits


29 Sep, 2014

3 commits


23 Sep, 2014

1 commit


04 Sep, 2014

1 commit

  • commit 2243a87d90b42eb38bc281957df3e57c712b5e56
    "pinctrl: avoid duplicated calling enable_pinmux_setting for a pin"
    removed the .disable callback from the struct pinmux_ops,
    making the .enable() callback the only remaining callback.

    However .enable() is a bad name as it seems to imply that a
    muxing can also be disabled. Rename the callback to .set_mux()
    and also take this opportunity to clean out any remaining
    mentions of .disable() from the documentation.

    Acked-by: Stephen Warren
    Acked-by: Bjorn Andersson
    Acked-by: Fan Wu
    Signed-off-by: Linus Walleij

    Linus Walleij