25 Oct, 2020

1 commit

  • Pull ARM SoC-related driver updates from Olof Johansson:
    "Various driver updates for platforms. A bulk of this is smaller fixes
    or cleanups, but some of the new material this time around is:

    - Support for Nvidia Tegra234 SoC

    - Ring accelerator support for TI AM65x

    - PRUSS driver for TI platforms

    - Renesas support for R-Car V3U SoC

    - Reset support for Cortex-M4 processor on i.MX8MQ

    There are also new socinfo entries for a handful of different SoCs and
    platforms"

    * tag 'armsoc-drivers' of git://git.kernel.org/pub/scm/linux/kernel/git/soc/soc: (131 commits)
    drm/mediatek: reduce clear event
    soc: mediatek: cmdq: add clear option in cmdq_pkt_wfe api
    soc: mediatek: cmdq: add jump function
    soc: mediatek: cmdq: add write_s_mask value function
    soc: mediatek: cmdq: add write_s value function
    soc: mediatek: cmdq: add read_s function
    soc: mediatek: cmdq: add write_s_mask function
    soc: mediatek: cmdq: add write_s function
    soc: mediatek: cmdq: add address shift in jump
    soc: mediatek: mtk-infracfg: Fix kerneldoc
    soc: amlogic: pm-domains: use always-on flag
    reset: sti: reset-syscfg: fix struct description warnings
    reset: imx7: add the cm4 reset for i.MX8MQ
    dt-bindings: reset: imx8mq: add m4 reset
    reset: Fix and extend kerneldoc
    reset: reset-zynqmp: Added support for Versal platform
    dt-bindings: reset: Updated binding for Versal reset driver
    reset: imx7: Support module build
    soc: fsl: qe: Remove unnessesary check in ucc_set_tdm_rxtx_clk
    soc: fsl: qman: convert to use be32_add_cpu()
    ...

    Linus Torvalds
     

02 Sep, 2020

1 commit

  • If CONFIG_OF is not set, make W=1 warns:

    drivers/memory/omap-gpmc.c:987:12: warning: ‘gpmc_cs_remap’ defined but not used [-Wunused-function]
    drivers/memory/omap-gpmc.c:926:20: warning: ‘gpmc_cs_get_name’ defined but not used [-Wunused-function]
    drivers/memory/omap-gpmc.c:919:13: warning: ‘gpmc_cs_set_name’ defined but not used [-Wunused-function]

    Move them to #ifdef CONFIG_OF block to fix this.

    Signed-off-by: YueHaibing
    Acked-by: Roger Quadros
    Link: https://lore.kernel.org/r/20200901112832.3084-1-yuehaibing%40huawei.com
    Signed-off-by: Krzysztof Kozlowski

    YueHaibing
     

28 Aug, 2020

1 commit

  • If CONFIG_OF is n, gcc fails:

    drivers/memory/omap-gpmc.o: In function `gpmc_omap_onenand_set_timings':
    omap-gpmc.c:(.text+0x2a88): undefined reference to `gpmc_read_settings_dt'

    Add gpmc_read_settings_dt() helper function, which zero the gpmc_settings
    so the caller doesn't proceed with random/invalid settings.

    Fixes: a758f50f10cf ("mtd: onenand: omap2: Configure driver from DT")
    Signed-off-by: YueHaibing
    Acked-by: Roger Quadros
    Link: https://lore.kernel.org/r/20200827125316.20780-1-yuehaibing@huawei.com
    Signed-off-by: Krzysztof Kozlowski

    YueHaibing
     

27 Aug, 2020

1 commit

  • These comparisons should be >= instead of > to prevent reading one
    element beyond the end of the gpmc_cs[] array.

    Fixes: cdd6928c589a ("ARM: OMAP2+: Add device-tree support for NOR flash")
    Fixes: f37e4580c409 ("ARM: OMAP2: Dynamic allocator for GPMC memory space")
    Signed-off-by: Dan Carpenter
    Acked-by: Roger Quadros
    Link: https://lore.kernel.org/r/20200825104707.GB278587@mwanda
    Signed-off-by: Krzysztof Kozlowski

    Dan Carpenter
     

24 Aug, 2020

1 commit

  • Replace the existing /* fall through */ comments and its variants with
    the new pseudo-keyword macro fallthrough[1]. Also, remove unnecessary
    fall-through markings when it is the case.

    [1] https://www.kernel.org/doc/html/v5.7/process/deprecated.html?highlight=fallthrough#implicit-switch-case-fall-through

    Signed-off-by: Gustavo A. R. Silva

    Gustavo A. R. Silva
     

18 Aug, 2020

6 commits

  • The driver already uses 'if (!res)' pattern in the probe function so be
    consistent.

    Signed-off-by: Krzysztof Kozlowski
    Link: https://lore.kernel.org/r/20200724182328.3348-11-krzk@kernel.org

    Krzysztof Kozlowski
     
  • Since driver tracks reserved memory, freeing a non-reserved GPMC should
    not be fatal and crash the system. Printing a warning is friendlier.

    Signed-off-by: Krzysztof Kozlowski
    Link: https://lore.kernel.org/r/20200724182328.3348-9-krzk@kernel.org

    Krzysztof Kozlowski
     
  • The GPMC_SET_ONE_CD_MAX macro uses return statement and variable 'cs'
    coming from called scope. This is not a good practice. Also
    checkpatch complained:

    WARNING: Macros with flow control statements should be avoided
    ERROR: Macros starting with if should be enclosed by a do - while
    loop to avoid possible if/else logic defects

    Since GPMC_SET_ONE_CD_MAX macro just calls one function, it can be open
    coded. The difference with original code is that function will exit on
    error not after every register set, but after a group of sets.

    Signed-off-by: Krzysztof Kozlowski
    Link: https://lore.kernel.org/r/20200724074038.5597-22-krzk@kernel.org

    Krzysztof Kozlowski
     
  • The callers of gpmc_cs_set_timings() expect to receive -ERRNO on errors
    and they pass further what they have received.

    However gpmc_cs_set_timings() was returning -1 (equal to -EPERM) which
    does not make sense in this context.

    Signed-off-by: Krzysztof Kozlowski
    Link: https://lore.kernel.org/r/20200724074038.5597-21-krzk@kernel.org

    Krzysztof Kozlowski
     
  • The file-scope variables phys_base and mem_size are assigned in
    gpmc_probe() but never read.

    This fixes build error when compile testing on x86_64 architecture:

    drivers/memory/omap-gpmc.c:246:24: error: conflicting types for ‘phys_base’
    static resource_size_t phys_base, mem_size;
    In file included from arch/x86/include/asm/page.h:12:0,
    from arch/x86/include/asm/thread_info.h:12,
    from include/linux/thread_info.h:38,
    from arch/x86/include/asm/preempt.h:7,
    from include/linux/preempt.h:78,
    from include/linux/spinlock.h:51,
    from include/linux/irq.h:14,
    from drivers/memory/omap-gpmc.c:12:
    arch/x86/include/asm/page_64.h:12:22: note: previous declaration of ‘phys_base’ was here
    extern unsigned long phys_base;

    Signed-off-by: Krzysztof Kozlowski
    Link: https://lore.kernel.org/r/20200724074038.5597-3-krzk@kernel.org

    Krzysztof Kozlowski
     
  • The driver does not use macros from asm/mach-types.h (neither MACH_TYPE
    nor machine_is_xxx()). Removal of this include allows compile testing
    on non-ARM architectures which lack this header.

    Signed-off-by: Krzysztof Kozlowski
    Link: https://lore.kernel.org/r/20200724074038.5597-2-krzk@kernel.org

    Krzysztof Kozlowski
     

27 Jul, 2020

5 commits


24 Jul, 2020

2 commits


10 Jul, 2019

1 commit

  • Pull GPIO updates from Linus Walleij:
    "This is the big slew of GPIO changes for the v5.3 kernel cycle. This
    is mostly incremental work this time.

    Three important things:

    - The FMC subsystem is deleted through my tree. This happens through
    GPIO as its demise was discussed in relation to a patch decoupling
    its GPIO implementation from the standard way of handling GPIO. As
    it turns out, that is not the only subsystem it reimplements and
    the authors think it is better do scratch it and start over using
    the proper kernel subsystems than try to polish the rust shiny. See
    the commit (ACKed by the maintainers) for details.

    - Arnd made a small devres patch that was ACKed by Greg and goes into
    the device core.

    - SPDX header change colissions may happen, because at times I've
    seen that quite a lot changed during the -rc:s in regards to SPDX.
    (It is good stuff, tglx has me convinced, and it is worth the
    occasional pain.)

    Apart from this is is nothing controversial or problematic.

    Summary:

    Core:

    - When a gpio_chip request GPIOs from itself, it can now fully
    control the line characteristics, both machine and consumer flags.
    This makes a lot of sense, but took some time before I figured out
    that this is how it has to work.

    - Several smallish documentation fixes.

    New drivers:

    - The PCA953x driver now supports the TI TCA9539.

    - The DaVinci driver now supports the K3 AM654 SoCs.

    Driver improvements:

    - Major overhaul and hardening of the OMAP driver by Russell King.

    - Starting to move some drivers to the new API passing irq_chip along
    with the gpio_chip when adding the gpio_chip instead of adding it
    separately.

    Unrelated:

    - Delete the FMC subsystem"

    * tag 'gpio-v5.3-1' of git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-gpio: (87 commits)
    Revert "gpio: tegra: Clean-up debugfs initialisation"
    gpiolib: Use spinlock_t instead of struct spinlock
    gpio: stp-xway: allow compile-testing
    gpio: stp-xway: get rid of the #include dependency
    gpio: stp-xway: improve module clock error handling
    gpio: stp-xway: simplify error handling in xway_stp_probe()
    gpiolib: Clarify use of non-sleeping functions
    gpiolib: Fix references to gpiod_[gs]et_*value_cansleep() variants
    gpiolib: Document new gpio_chip.init_valid_mask field
    Documentation: gpio: Fix reference to gpiod_get_array()
    gpio: pl061: drop duplicate printing of device name
    gpio: altera: Pass irqchip when adding gpiochip
    gpio: siox: Use devm_ managed gpiochip
    gpio: siox: Add struct device *dev helper variable
    gpio: siox: Pass irqchip when adding gpiochip
    drivers: gpio: amd-fch: make resource struct const
    devres: allow const resource arguments
    gpio: ath79: Pass irqchip when adding gpiochip
    gpio: tegra: Clean-up debugfs initialisation
    gpio: siox: Switch to IRQ_TYPE_NONE
    ...

    Linus Torvalds
     

19 Jun, 2019

1 commit

  • Based on 2 normalized pattern(s):

    this program is free software you can redistribute it and or modify
    it under the terms of the gnu general public license version 2 as
    published by the free software foundation

    this program is free software you can redistribute it and or modify
    it under the terms of the gnu general public license version 2 as
    published by the free software foundation #

    extracted by the scancode license scanner the SPDX license identifier

    GPL-2.0-only

    has been chosen to replace the boilerplate/reference in 4122 file(s).

    Signed-off-by: Thomas Gleixner
    Reviewed-by: Enrico Weigelt
    Reviewed-by: Kate Stewart
    Reviewed-by: Allison Randal
    Cc: linux-spdx@vger.kernel.org
    Link: https://lkml.kernel.org/r/20190604081206.933168790@linutronix.de
    Signed-off-by: Greg Kroah-Hartman

    Thomas Gleixner
     

08 Jun, 2019

1 commit

  • When a gpio_chip wants to request a descriptor from itself
    using gpiochip_request_own_desc() it needs to be able to specify
    fully how to use the descriptor, notably line inversion
    semantics. The workaround in the gpiolib.c can be removed
    and cases (such as SPI CS) where we need at times to request
    a GPIO with line inversion semantics directly on a chip for
    workarounds, can be fully supported with this call.

    Fix up some users of the API that weren't really using the
    last flag to set up the line as input or output properly
    but instead just calling direction setting explicitly
    after requesting the line.

    Cc: Martin Sperl
    Signed-off-by: Linus Walleij

    Linus Walleij
     

01 Jan, 2019

1 commit

  • Pull ARM SoC driver updates from Olof Johansson:
    "Misc driver updates for platforms, many of them power related.

    - Rockchip adds power domain support for rk3066 and rk3188

    - Amlogic adds a power measurement driver

    - Allwinner adds SRAM support for three platforms (F1C100, H5, A64
    C1)

    - Wakeup and ti-sysc (platform bus) fixes for OMAP/DRA7

    - Broadcom fixes suspend/resume with Thumb2 kernels, and improves
    stability of a handful of firmware/platform interfaces

    - PXA completes their conversion to dmaengine framework

    - Renesas does a bunch of PM cleanups across many platforms

    - Tegra adds support for suspend/resume on T186/T194, which includes
    some driver cleanups and addition of wake events

    - Tegra also adds a driver for memory controller (EMC) on Tegra2

    - i.MX tweaks power domain bindings, and adds support for i.MX8MQ in
    GPC

    - Atmel adds identifiers and LPDDR2 support for a new SoC, SAM9X60

    and misc cleanups across several platforms"

    * tag 'armsoc-drivers' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc: (73 commits)
    ARM: at91: add support in soc driver for new SAM9X60
    ARM: at91: add support in soc driver for LPDDR2 SiP
    memory: omap-gpmc: Use of_node_name_eq for node name comparisons
    bus: ti-sysc: Check for no-reset and no-idle flags at the child level
    ARM: OMAP2+: Check also the first dts child for hwmod flags
    soc: amlogic: meson-clk-measure: Add missing REGMAP_MMIO dependency
    soc: imx: gpc: Increase GPC_CLK_MAX to 7
    soc: renesas: rcar-sysc: Fix power domain control after system resume
    soc: renesas: rcar-sysc: Merge PM Domain registration and linking
    soc: renesas: rcar-sysc: Remove rcar_sysc_power_{down,up}() helpers
    soc: renesas: r8a77990-sysc: Fix initialization order of 3DG-{A,B}
    dt-bindings: sram: sunxi: Add compatible for the A64 SRAM C1
    dt-bindings: sram: sunxi: Add bindings for the H5 with SRAM C1
    dt-bindings: sram: Add Allwinner suniv F1C100s
    soc: sunxi: sram: Add support for the H5 SoC system control
    soc: sunxi: sram: Enable EMAC clock access for H3 variant
    soc: imx: gpcv2: add support for i.MX8MQ SoC
    soc: imx: gpcv2: move register access table to domain data
    soc: imx: gpcv2: prefix i.MX7 specific defines
    dmaengine: pxa: make the filter function internal
    ...

    Linus Torvalds
     

29 Dec, 2018

1 commit

  • Pull Devicetree updates from Rob Herring:
    "The biggest highlight here is the start of using json-schema for DT
    bindings. Being able to validate bindings has been discussed for years
    with little progress.

    - Initial support for DT bindings using json-schema language. This is
    the start of converting DT bindings from free-form text to a
    structured format.

    - Reworking of initrd address initialization. This moves to using the
    phys address instead of virt addr in the DT parsing code. This
    rework was motivated by CONFIG_DEV_BLK_INITRD causing unnecessary
    rebuilding of lots of files.

    - Fix stale phandle entries in phandle cache

    - DT overlay validation improvements. This exposed several memory
    leak bugs which have been fixed.

    - Use node name and device_type helper functions in DT code

    - Last remaining conversions to using %pOFn printk specifier instead
    of device_node.name directly

    - Create new common RTC binding doc and move all trivial RTC devices
    out of trivial-devices.txt.

    - New bindings for Freescale MAG3110 magnetometer, Cadence Sierra
    PHY, and Xen shared memory

    - Update dtc to upstream version v1.4.7-57-gf267e674d145"

    * tag 'devicetree-for-4.21' of git://git.kernel.org/pub/scm/linux/kernel/git/robh/linux: (68 commits)
    of: __of_detach_node() - remove node from phandle cache
    of: of_node_get()/of_node_put() nodes held in phandle cache
    gpio-omap.txt: add reg and interrupts properties
    dt-bindings: mrvl,intc: fix a trivial typo
    dt-bindings: iio: magnetometer: add dt-bindings for freescale mag3110
    dt-bindings: Convert trivial-devices.txt to json-schema
    dt-bindings: arm: mrvl: amend Browstone compatible string
    dt-bindings: arm: Convert Tegra board/soc bindings to json-schema
    dt-bindings: arm: Convert ZTE board/soc bindings to json-schema
    dt-bindings: arm: Add missing Xilinx boards
    dt-bindings: arm: Convert Xilinx board/soc bindings to json-schema
    dt-bindings: arm: Convert VIA board/soc bindings to json-schema
    dt-bindings: arm: Convert ST STi board/soc bindings to json-schema
    dt-bindings: arm: Convert SPEAr board/soc bindings to json-schema
    dt-bindings: arm: Convert CSR SiRF board/soc bindings to json-schema
    dt-bindings: arm: Convert QCom board/soc bindings to json-schema
    dt-bindings: arm: Convert TI nspire board/soc bindings to json-schema
    dt-bindings: arm: Convert TI davinci board/soc bindings to json-schema
    dt-bindings: arm: Convert Calxeda board/soc bindings to json-schema
    dt-bindings: arm: Convert Altera board/soc bindings to json-schema
    ...

    Linus Torvalds
     

18 Dec, 2018

1 commit

  • Commit 21abf103818a
    ("gpio: Pass a flag to gpiochip_request_own_desc()")
    started to pass an enum gpiod_flags but this file is
    not including the header file that defines that enum
    and the compiler spits:

    drivers/memory/omap-gpmc.c: In function
    'gpmc_probe_generic_child':
    drivers/memory/omap-gpmc.c:2174:9: error: type of formal
    parameter 4 is incomplete
    0);
    ^

    Cc: Ladislav Michl
    Cc: Janusz Krzysztofik
    Reported-by: Stephen Rothwell
    Fixes: 21abf103818a ("gpio: Pass a flag to gpiochip_request_own_desc()")
    Acked-by: Tony Lindgren
    Signed-off-by: Linus Walleij

    Linus Walleij
     

14 Dec, 2018

1 commit

  • Before things go out of hand, make it possible to pass
    flags when requesting "own" descriptors from a gpio_chip.
    This is necessary if the chip wants to request a GPIO with
    active low semantics, for example.

    Cc: Janusz Krzysztofik
    Cc: Thomas Petazzoni
    Cc: Jason Cooper
    Cc: Jiri Kosina
    Cc: Roger Quadros
    Reviewed-by: Gregory CLEMENT
    Signed-off-by: Linus Walleij

    Linus Walleij
     

12 Dec, 2018

1 commit

  • Convert string compares of DT node names to use of_node_name_eq helper
    instead. This removes direct access to the node name pointer.

    For instances using of_node_cmp, this has the side effect of now using
    case sensitive comparisons. This should not matter for any FDT based
    system which this is.

    Cc: Roger Quadros
    Cc: Tony Lindgren
    Cc: linux-omap@vger.kernel.org
    Signed-off-by: Rob Herring
    Signed-off-by: Tony Lindgren

    Rob Herring
     

28 Nov, 2018

1 commit

  • In preparation to remove the node name pointer from struct device_node,
    convert printf users to use the %pOFn format specifier.

    Cc: Roger Quadros
    Cc: Kukjin Kim
    Cc: Jonathan Hunter
    Cc: linux-omap@vger.kernel.org
    Cc: linux-arm-kernel@lists.infradead.org
    Cc: linux-samsung-soc@vger.kernel.org
    Cc: linux-tegra@vger.kernel.org
    Acked-by: Thierry Reding
    Acked-by: Tony Lindgren
    Acked-by: Krzysztof Kozlowski
    Signed-off-by: Rob Herring

    Rob Herring
     

24 Apr, 2018

1 commit


12 Jan, 2018

1 commit

  • Move away from platform data configuration and use pure DT approach.

    Use generic probe function to deal with OneNAND node and remove now useless
    gpmc_probe_onenand_child function. Import sync mode timing calculation
    function from mach-omap2/gpmc-onenand.c

    Signed-off-by: Ladislav Michl
    Reviewed-by: Peter Ujfalusi
    Tested-by: Tony Lindgren
    Tested-by: Aaro Koskinen
    Acked-by: Roger Quadros
    Signed-off-by: Boris Brezillon

    Ladislav Michl
     

01 Dec, 2017

1 commit


03 Nov, 2017

1 commit


17 Oct, 2017

1 commit


17 Aug, 2017

1 commit

  • Now that we have a custom printf format specifier, convert users of
    full_name to use %pOF instead. This is preparation to remove storing
    of the full path string for each node.

    Signed-off-by: Rob Herring
    Acked-by: Alexandre Belloni
    Acked-by: Roger Quadros
    Cc: Nicolas Ferre
    Cc: Alexandre Belloni
    Cc: Tony Lindgren
    Cc: linux-arm-kernel@lists.infradead.org
    Cc: linux-omap@vger.kernel.org
    Signed-off-by: Arnd Bergmann

    Rob Herring
     

19 Jun, 2017

1 commit

  • …nel/git/tmlind/linux-omap into next/drivers

    Few improvments for GPMC (General Purpose Memory Controller)
    found on TI SoCs to produce an error for missing bank-width
    and to make the bootloader timing debug output usable for
    device tree timings.

    * tag 'omap-for-v4.13/gpmc-signed' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap:
    memory: omap-gpmc: add error message if bank-width property is absent
    memory: omap-gpmc: make dts snippet include semicolon

    Signed-off-by: Olof Johansson <olof@lixom.net>

    Olof Johansson
     

01 Jun, 2017

2 commits


16 May, 2017

1 commit


01 Mar, 2017

1 commit


03 Sep, 2016

1 commit


29 Aug, 2016

1 commit

  • We get 1 warning when build kernel with W=1:
    drivers/memory/omap-gpmc.c:354:14: warning: no previous prototype for 'gpmc_clk_ticks_to_ns' [-Wmissing-prototypes]

    In fact, this function is only used in the file in which it is declared
    and don't need a declaration, but can be made static.
    so this patch marks it 'static'.

    Signed-off-by: Baoyou Xie
    Signed-off-by: Roger Quadros

    Baoyou Xie