08 Mar, 2020

1 commit

  • Merge Linux stable release v5.4.24 into imx_5.4.y

    * tag 'v5.4.24': (3306 commits)
    Linux 5.4.24
    blktrace: Protect q->blk_trace with RCU
    kvm: nVMX: VMWRITE checks unsupported field before read-only field
    ...

    Signed-off-by: Jason Liu

    Conflicts:
    arch/arm/boot/dts/imx6sll-evk.dts
    arch/arm/boot/dts/imx7ulp.dtsi
    arch/arm64/boot/dts/freescale/fsl-ls1028a.dtsi
    drivers/clk/imx/clk-composite-8m.c
    drivers/gpio/gpio-mxc.c
    drivers/irqchip/Kconfig
    drivers/mmc/host/sdhci-of-esdhc.c
    drivers/mtd/nand/raw/gpmi-nand/gpmi-nand.c
    drivers/net/can/flexcan.c
    drivers/net/ethernet/freescale/dpaa/dpaa_eth.c
    drivers/net/ethernet/mscc/ocelot.c
    drivers/net/ethernet/stmicro/stmmac/stmmac_main.c
    drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c
    drivers/net/phy/realtek.c
    drivers/pci/controller/mobiveil/pcie-mobiveil-host.c
    drivers/perf/fsl_imx8_ddr_perf.c
    drivers/tee/optee/shm_pool.c
    drivers/usb/cdns3/gadget.c
    kernel/sched/cpufreq.c
    net/core/xdp.c
    sound/soc/fsl/fsl_esai.c
    sound/soc/fsl/fsl_sai.c
    sound/soc/sof/core.c
    sound/soc/sof/imx/Kconfig
    sound/soc/sof/loader.c

    Jason Liu
     

15 Feb, 2020

1 commit

  • commit cb7a374a5e7a5af3f8c839f74439193add6d0589 upstream.

    MAX77650 MFD driver uses regmap_irq API but doesn't select the required
    REGMAP_IRQ option in Kconfig. This can cause the following build error
    if regmap irq is not enabled implicitly by someone else:

    ld: drivers/mfd/max77650.o: in function `max77650_i2c_probe':
    max77650.c:(.text+0xcb): undefined reference to `devm_regmap_add_irq_chip'
    ld: max77650.c:(.text+0xdb): undefined reference to `regmap_irq_get_domain'
    make: *** [Makefile:1079: vmlinux] Error 1

    Fix it by adding the missing option.

    Fixes: d0f60334500b ("mfd: Add new driver for MAX77650 PMIC")
    Reported-by: Paul Gazzillo
    Signed-off-by: Bartosz Golaszewski
    Signed-off-by: Lee Jones
    Signed-off-by: Greg Kroah-Hartman

    Bartosz Golaszewski
     

11 Feb, 2020

4 commits

  • commit 2f3dc25c0118de03a00ddc88b61f7216854f534d upstream.

    There is a bit which gets cleared after conversion.

    Fixes: 9bb9e29c78f8 ("mfd: Add Ricoh RN5T618 PMIC core driver")
    Signed-off-by: Andreas Kemnade
    Signed-off-by: Lee Jones
    Signed-off-by: Greg Kroah-Hartman

    Andreas Kemnade
     
  • commit 1112ba02ff1190ca9c15a912f9269e54b46d2d82 upstream.

    The watchdog driver compatible is "dlg,da9062-watchdog" and not
    "dlg,da9062-wdt". Therefore the mfd-core can't populate the of_node and
    fwnode. As result the watchdog driver can't parse the devicetree.

    Fixes: 9b40b030c4ad ("mfd: da9062: Supply core driver")
    Signed-off-by: Marco Felsch
    Acked-by: Guenter Roeck
    Reviewed-by: Adam Thomson
    Signed-off-by: Lee Jones
    Signed-off-by: Greg Kroah-Hartman

    Marco Felsch
     
  • commit dc91c3b6fe66a13ac76f6cb3b2100c0779cd3350 upstream.

    On AXP288 and newer PMICs, bit 7 of AXP20X_VBUS_IPSOUT_MGMT can be set
    to prevent using the VBUS input. However, when the VBUS unplugged and
    plugged back in, the bit automatically resets to zero.

    We need to set the register as volatile to prevent regmap from caching
    that bit. Otherwise, regcache will think the bit is already set and not
    write the register.

    Fixes: cd53216625a0 ("mfd: axp20x: Fix axp288 volatile ranges")
    Cc: stable@vger.kernel.org
    Signed-off-by: Samuel Holland
    Reviewed-by: Chen-Yu Tsai
    Signed-off-by: Lee Jones
    Signed-off-by: Greg Kroah-Hartman

    Samuel Holland
     
  • commit 2b8bd606b1e60ca28c765f69c1eedd7d2a2e9dca upstream.

    It is not enough to check for the number of endpoints.
    The types must also be correct.

    Reported-and-tested-by: syzbot+48a2851be24583b864dc@syzkaller.appspotmail.com
    Signed-off-by: Oliver Neukum
    Reviewed-by: Greg Kroah-Hartman
    Signed-off-by: Lee Jones
    Signed-off-by: Greg Kroah-Hartman

    Oliver Neukum
     

01 Feb, 2020

1 commit


26 Jan, 2020

1 commit

  • commit 3f31bc67e4dc6a555341dffefe328ddd58e8b431 upstream.

    It turned out Intel Gemini Lake doesn't use the same I2C timing
    parameters as Broxton.

    I got confirmation from the Windows team that Gemini Lake systems should
    use updated timing parameters that differ from those used in Broxton
    based systems.

    Fixes: f80e78aa11ad ("mfd: intel-lpss: Add Intel Gemini Lake PCI IDs")
    Tested-by: Chris Chiu
    Signed-off-by: Jarkko Nikula
    Acked-by: Andy Shevchenko
    Signed-off-by: Lee Jones
    Signed-off-by: Greg Kroah-Hartman

    Jarkko Nikula
     

18 Jan, 2020

1 commit

  • Some of the i.MX SoCs have a IP for interfacing the audio dedicated IPs with
    clocks, resets and interrupts, plus some DSP specific control registers.
    To allow the functionality to be split between drivers, this MFD driver is
    added that has only two purposes: register the devices and map the entire
    register addresses. Everything else is left to the dedicated drivers that will
    bind to the registered devices.

    Signed-off-by: Abel Vesa
    Reviewed-by: Leonard Crestez

    Abel Vesa
     

02 Dec, 2019

2 commits

  • * regulator/next: (14 commits)
    MLK-22824-2: regulator: pca9450: add pca9450 regulator driver
    MLK-22824-1: mfd: pca9450: add pca9450 mfd driver
    LF-53: regulator: pf1550-regulator-rpmsg: fix ldo2 voltage changing failure
    MLK-13638-4 regulator: fixed: add system pm routines for pinctrl
    regulator: fixed: add off-on-delay
    ...

    Dong Aisheng
     
  • * mxc/next: (119 commits)
    mxc: hdmi-cec: Add imx6 hdmi cec driver
    driver: mfd: hdmi: Add hdmi core driver
    MLK-22399 mxc IPUv3: cpmem: Get 0 u/v_offset in __ipu_ch_offset_calc() for some pfmts
    mxc: IPU3: Fix not including uapi/linux/sched/types.h
    media: platform: mxc: output: Forward IPUv3 V4L2 output driver from imx_4.19.y
    ...

    Dong Aisheng
     

29 Nov, 2019

1 commit


25 Nov, 2019

11 commits

  • There is issue that system can't enter suspend while the si476x is
    working.

    The reason is that with the workqueue thread is still working after
    i2c enter suspend, then cause the cpu_suspend function failed.

    This patch is to use the system_freezable_wq instead of the system_wq,
    that the workqueue will be freeze before system enter suspend.

    Signed-off-by: Shengjiu Wang
    Reviewed-by: Viorel Suman

    Shengjiu Wang
     
  • The si476x_core_get_revision_info will send i2c command to FM module, if it
    return error, there is no FM modules attached, so we need't to register the
    sound card. otherwise, the pulseaudio will access this sound card, but
    return a lot of i2c error.

    Signed-off-by: Shengjiu Wang
    (cherry picked from commit 4c8e9916128f05f9b4115e1ee1af4a1e7d800c4a)
    Signed-off-by: Vipul Kumar

    Shengjiu Wang
     
  • Currently, si476x-rev1.0 and si476x-rev4.0 board just support A10
    compatible command set. For si476x-rev1.0 board, its firmware revision is
    unsupported and will revert to A10 compatible function. For si476x-rev4.0
    board, its firmware revision is two and will use A30 function, but A30
    command set function can't work for the rev4.0 board.
    So make the command set configurable in dts. If "revision-a10" is present,
    set the revision to SI476X_REVISION_A10 to use A10 compatible commit set.
    Otherwise, get the revision from si476x register.

    Signed-off-by: Zidan Wang
    (cherry picked from commit b648714c3b71ee084188ae04b1e6a6f2554fe2cb)
    Signed-off-by: Vipul Kumar

    Zidan Wang
     
  • Add of_compatible for si476x-codec, then si476x-codec driver will have
    codec_of_node, So machine driver can use the codec_of_node.

    Signed-off-by: Shengjiu Wang
    (cherry picked from commit e2ec44f91a21b127e155e8317d06e8ead7fd2678)
    (cherry picked from commit ac6decaf5414e784ae81a524edc2f32060061b59)
    Signed-off-by: Vipul Kumar

    Shengjiu Wang
     
  • cherry-pick below patch from imx_3.14.y
    ENGR00276567-6 mfd: si476x: Use default configuration when no platform data

    This would allow the driver to work normally without specific platform
    data, when using devicetree for example.

    Signed-off-by: Nicolin Chen
    (cherry picked from commit 23e369b88b546d7b699ca9ec46e195a05c61b717)
    (cherry picked from commit a2449e1d303e341f32556fb7f4ebc7dcbdd9ead1)
    Signed-off-by: Vipul Kumar

    Nicolin Chen
     
  • cherry-pick below patch from imx_3.14.y
    ENGR00276567-4 mfd: si476x: Fix power up failure

    This's some logical error in power-up code, thus fix it.

    Signed-off-by: Nicolin Chen
    (cherry picked from commit 77d97ad1bb77c0e3c60b9781a06b61d4b4667de1)
    (cherry picked from commit b656522da2685ef9a4da2229b6786d5cd0c12189)
    Signed-off-by: Vipul Kumar
    Signed-off-by: Shengjiu Wang

    Nicolin Chen
     
  • Add imx6 hdmi code driver.
    This patch forwards imx6 HDMI code driver from imx_4.19.y kernel.

    Signed-off-by: Sandor Yu

    Sandor Yu
     
  • in 5451781dadf85000665e0e2c3288e9e0f34b860a commit, it added the check that
    the regulator need to be disabled before calling regulator_put().
    If not do so, the kernel will print warning message as below.

    To fix this, need to disable regulator before probe function return if this
    PMIC is not found. regulator_put() will be called when probe fails in this case
    as devm_regulator_get() already called in probe function.

    [ 0.269916] i2c i2c-2: Max17135 PMIC not found!
    [ 0.270004] ------------[ cut here ]------------
    [ 0.270145] WARNING: CPU: 0 PID: 1 at drivers/regulator/core.c:2039 _regulator_put.part.4+0x100/0x120
    [ 0.270166] Modules linked in:
    [ 0.270196] CPU: 0 PID: 1 Comm: swapper/0 Not tainted 5.3.0-rc3-next-20190809-02777-g23dc3ed #22
    [ 0.270214] Hardware name: Freescale i.MX6 Quad/DualLite (Device Tree)
    [ 0.270250] [] (unwind_backtrace) from [] (show_stack+0x10/0x14)
    [ 0.270281] [] (show_stack) from [] (dump_stack+0xd8/0x110)
    [ 0.270310] [] (dump_stack) from [] (__warn.part.3+0xa8/0xe8)
    [ 0.270335] [] (__warn.part.3) from [] (warn_slowpath_null+0x40/0x4c)
    [ 0.270361] [] (warn_slowpath_null) from [] (_regulator_put.part.4+0x100/0x120)
    [ 0.270385] [] (_regulator_put.part.4) from [] (regulator_put+0x2c/0x3c)
    [ 0.270414] [] (regulator_put) from [] (release_nodes+0x1ac/0x1f8)
    [ 0.270444] [] (release_nodes) from [] (really_probe+0x104/0x340)
    [ 0.270467] [] (really_probe) from [] (driver_probe_device+0x84/0x194)
    [ 0.270492] [] (driver_probe_device) from [] (bus_for_each_drv+0x7c/0xc4)
    [ 0.270516] [] (bus_for_each_drv) from [] (__device_attach+0xcc/0x140)
    [ 0.270539] [] (__device_attach) from [] (bus_probe_device+0x88/0x90)
    [ 0.270563] [] (bus_probe_device) from [] (device_add+0x608/0x754)
    [ 0.270591] [] (device_add) from [] (i2c_new_client_device+0x12c/0x20c)
    [ 0.270615] [] (i2c_new_client_device) from [] (i2c_new_device+0x8/0x14)
    [ 0.270641] [] (i2c_new_device) from [] (of_i2c_register_devices+0x90/0x110)
    [ 0.270666] [] (of_i2c_register_devices) from [] (i2c_register_adapter+0x148/0x3ec)
    [ 0.270691] [] (i2c_register_adapter) from [] (i2c_imx_probe+0x37c/0x830)
    [ 0.270719] [] (i2c_imx_probe) from [] (platform_drv_probe+0x48/0x98)
    [ 0.270747] [] (platform_drv_probe) from [] (really_probe+0x1dc/0x340)
    [ 0.270773] [] (really_probe) from [] (driver_probe_device+0x84/0x194)
    [ 0.270797] [] (driver_probe_device) from [] (device_driver_attach+0x58/0x60)
    [ 0.270821] [] (device_driver_attach) from [] (__driver_attach+0x58/0xd0)
    [ 0.270844] [] (__driver_attach) from [] (bus_for_each_dev+0x70/0xb4)
    [ 0.270867] [] (bus_for_each_dev) from [] (bus_add_driver+0x198/0x1d0)
    [ 0.270890] [] (bus_add_driver) from [] (driver_register+0x74/0x108)
    [ 0.270916] [] (driver_register) from [] (do_one_initcall+0x80/0x338)
    [ 0.270946] [] (do_one_initcall) from [] (kernel_init_freeable+0x2fc/0x3d8)
    [ 0.270973] [] (kernel_init_freeable) from [] (kernel_init+0x8/0x110)
    [ 0.270997] [] (kernel_init) from [] (ret_from_fork+0x14/0x20)
    [ 0.271015] Exception stack(0xec0e9fb0 to 0xec0e9ff8)
    [ 0.271038] 9fa0: 00000000 00000000 00000000 00000000
    [ 0.271059] 9fc0: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
    [ 0.271077] 9fe0: 00000000 00000000 00000000 00000000 00000013 00000000
    [ 0.271094] irq event stamp: 70901
    [ 0.271125] hardirqs last enabled at (70909): [] console_unlock+0x418/0x5f4
    [ 0.271149] hardirqs last disabled at (70916): [] console_unlock+0x88/0x5f4
    [ 0.271173] softirqs last enabled at (69156): [] __do_softirq+0x2c4/0x514
    [ 0.271198] softirqs last disabled at (68881): [] irq_exit+0x100/0x188
    [ 0.271268] ---[ end trace 579e47ca40f2be36 ]---

    Signed-off-by: Robby Cai

    Robby Cai
     
  • export symbols to fix build error as a module:

    ERROR: "max17135_reg_read" [drivers/hwmon/max17135-hwmon.ko] undefined!

    Signed-off-by: Julien Olivain
    Acked-by: Robby Cai

    Julien Olivain
     
  • i2c device client shouldn't be freed by i2c device driver, there have
    problems in below cases:
    - one device match to different drivers, the second matched driver will
    cannot access i2c device client if it is freed by the first matched
    driver.
    - one module driver insmod: the first insmod fail free client due to system
    low memory, after kswapd system free pages and has enough free pages, the
    second insmod will cause match failed.

    Signed-off-by: Fugang Duan
    Signed-off-by: Vipul Kumar

    Fugang Duan
     
  • Add PMIC 'MAX17135' module drivers to 4.1.y kernel. These are necessary
    to supply power for E-ink panel display functions.

    Signed-off-by: Robby Cai
    Signed-off-by: Vipul Kumar

    Robby Cai
     

24 Oct, 2019

1 commit

  • Part 3 from this series [1] was not merged due to wrong splitting
    and breaks mt6323 pmic on bananapi-r2

    dmesg prints this line and at least switch is not initialized on bananapi-r2

    mt6397 1000d000.pwrap:mt6323: unsupported chip: 0x0

    this patch contains only the probe-changes and chip_data structs
    from original part 3 by Hsin-Hsiung Wang

    [1] https://patchwork.kernel.org/project/linux-mediatek/list/?series=164155

    Fixes: a4872e80ce7d ("mfd: mt6397: Extract IRQ related code from core driver")
    Signed-off-by: Frank Wunderlich
    Signed-off-by: Lee Jones

    Frank Wunderlich
     

30 Sep, 2019

1 commit

  • Pull thermal SoC updates from Eduardo Valentin:
    "This is a really small pull in the midst of a lot of pending patches.

    We are in the middle of restructuring how we are maintaining the
    thermal subsystem, as per discussion in our last LPC. For now, I am
    sending just some changes that were pending in my tree. Looking
    forward to get a more streamlined process in the next merge window"

    * 'linus' of git://git.kernel.org/pub/scm/linux/kernel/git/evalenti/linux-soc-thermal:
    thermal: db8500: Rewrite to be a pure OF sensor
    thermal: db8500: Use dev helper variable
    thermal: db8500: Finalize device tree conversion
    thermal: thermal_mmio: remove some dead code

    Linus Torvalds
     

25 Sep, 2019

1 commit

  • At some point there was an attempt to convert the DB8500
    thermal sensor to device tree: a probe path was added
    and the device tree was augmented for the Snowball board.
    The switchover was never completed: instead the thermal
    devices came from from the PRCMU MFD device and the probe
    on the Snowball was confused as another set of configuration
    appeared from the device tree.

    Move over to a device-tree only approach, as we fixed up
    the device trees.

    Cc: Vincent Guittot
    Acked-by: Lee Jones
    Reviewed-by: Daniel Lezcano
    Signed-off-by: Linus Walleij
    Signed-off-by: Eduardo Valentin

    Linus Walleij
     

24 Sep, 2019

1 commit

  • Pull MFD updates from Lee Jones:
    "New Drivers:
    - Add support for Merrifield Basin Cove PMIC

    New Device Support:
    - Add support for Intel Tiger Lake to Intel LPSS PCI
    - Add support for Intel Sky Lake to Intel LPSS PCI
    - Add support for ST-Ericsson DB8520 to DB8500 PRCMU

    New Functionality:
    - Add RTC and PWRC support to MT6323

    Fix-ups:
    - Clean-up include files; davinci_voicecodec, asic3, sm501, mt6397
    - Ignore return values from debugfs_create*(); ab3100-*, ab8500-debugfs, aat2870-core
    - Device Tree changes; rn5t618, mt6397
    - Use new I2C API; tps80031, 88pm860x-core, ab3100-core, bcm590xx,
    da9150-core, max14577, max77693, max77843, max8907,
    max8925-i2c, max8997, max8998, palmas, twl-core,
    - Remove obsolete code; da9063, jz4740-adc
    - Simplify semantics; timberdale, htc-i2cpld
    - Add 'fall-through' tags; omap-usb-host, db8500-prcmu
    - Remove superfluous prints; ab8500-debugfs, db8500-prcmu, fsl-imx25-tsadc,
    intel_soc_pmic_bxtwc, qcom_rpm, sm501
    - Trivial rename/whitespace/typo fixes; mt6397-core, MAINTAINERS
    - Reorganise code structure; mt6397-*
    - Improve code consistency; intel-lpss
    - Use MODULE_SOFTDEP() helper; intel-lpss
    - Use DEFINE_RES_*() helpers; mt6397-core

    Bug Fixes:
    - Clean-up resources; max77620
    - Prevent input events being dropped on resume; intel-lpss-pci
    - Prevent sleeping in IRQ context; ezx-pcap"

    * tag 'mfd-next-5.4' of git://git.kernel.org/pub/scm/linux/kernel/git/lee/mfd: (48 commits)
    mfd: mt6323: Add MT6323 RTC and PWRC
    mfd: mt6323: Replace boilerplate resource code with DEFINE_RES_* macros
    mfd: mt6397: Add mutex include
    dt-bindings: mfd: mediatek: Add MT6323 Power Controller
    dt-bindings: mfd: mediatek: Update RTC to include MT6323
    dt-bindings: mfd: mediatek: mt6397: Change to relative paths
    mfd: db8500-prcmu: Support the higher DB8520 ARMSS
    mfd: intel-lpss: Use MODULE_SOFTDEP() instead of implicit request
    mfd: htc-i2cpld: Drop check because i2c_unregister_device() is NULL safe
    mfd: sm501: Include the GPIO driver header
    mfd: intel-lpss: Add Intel Skylake ACPI IDs
    mfd: intel-lpss: Consistently use GENMASK()
    mfd: Add support for Merrifield Basin Cove PMIC
    mfd: ezx-pcap: Replace mutex_lock with spin_lock
    mfd: asic3: Include the right header
    MAINTAINERS: altera-sysmgr: Fix typo in a filepath
    mfd: mt6397: Extract IRQ related code from core driver
    mfd: mt6397: Rename macros to something more readable
    mfd: Remove dev_err() usage after platform_get_irq()
    mfd: db8500-prcmu: Mark expected switch fall-throughs
    ...

    Linus Torvalds
     

23 Sep, 2019

1 commit

  • Pull MIPS updates from Paul Burton:
    "Main MIPS changes:

    - boot_mem_map is removed, providing a nice cleanup made possible by
    the recent removal of bootmem.

    - Some fixes to atomics, in general providing compiler barriers for
    smp_mb__{before,after}_atomic plus fixes specific to Loongson CPUs
    or MIPS32 systems using cmpxchg64().

    - Conversion to the new generic VDSO infrastructure courtesy of
    Vincenzo Frascino.

    - Removal of undefined behavior in set_io_port_base(), fixing the
    behavior of some MIPS kernel configurations when built with recent
    clang versions.

    - Initial MIPS32 huge page support, functional on at least Ingenic
    SoCs.

    - pte_special() is now supported for some configurations, allowing
    among other things generic fast GUP to be used.

    - Miscellaneous fixes & cleanups.

    And platform specific changes:

    - Major improvements to Ingenic SoC support from Paul Cercueil,
    mostly enabled by the inclusion of the new TCU (timer-counter unit)
    drivers he's spent a very patient year or so working on. Plus some
    fixes for X1000 SoCs from Zhou Yanjie.

    - Netgear R6200 v1 systems are now supported by the bcm47xx platform.

    - DT updates for BMIPS, Lantiq & Microsemi Ocelot systems"

    * tag 'mips_5.4' of git://git.kernel.org/pub/scm/linux/kernel/git/mips/linux: (89 commits)
    MIPS: Detect bad _PFN_SHIFT values
    MIPS: Disable pte_special() for MIPS32 with RiXi
    MIPS: ralink: deactivate PCI support for SOC_MT7621
    mips: compat: vdso: Use legacy syscalls as fallback
    MIPS: Drop Loongson _CACHE_* definitions
    MIPS: tlbex: Remove cpu_has_local_ebase
    MIPS: tlbex: Simplify r3k check
    MIPS: Select R3k-style TLB in Kconfig
    MIPS: PCI: refactor ioc3 special handling
    mips: remove ioremap_cachable
    mips/atomic: Fix smp_mb__{before,after}_atomic()
    mips/atomic: Fix loongson_llsc_mb() wreckage
    mips/atomic: Fix cmpxchg64 barriers
    MIPS: Octeon: remove duplicated include from dma-octeon.c
    firmware: bcm47xx_nvram: Allow COMPILE_TEST
    firmware: bcm47xx_nvram: Correct size_t printf format
    MIPS: Treat Loongson Extensions as ASEs
    MIPS: Remove dev_err() usage after platform_get_irq()
    MIPS: dts: mscc: describe the PTP ready interrupt
    MIPS: dts: mscc: describe the PTP register range
    ...

    Linus Torvalds
     

20 Sep, 2019

1 commit

  • …ernel/git/chrome-platform/linux

    Pull chrome platform updates from Benson Leung:
    "CrOS EC / MFD Migration:
    - Move cros_ec core driver from mfd into chrome platform.

    Wilco EC:
    - Add batt_ppid_info command to Wilco telemetry driver.

    CrOS EC:
    - cros_ec_rpmsg : Add support to inform EC of suspend/resume status
    - cros_ec_rpmsg : Fix race condition on probe failed
    - cros_ec_chardev : Add a poll handler to receive MKBP events

    Misc:
    - bugfixes in cros_usbpd_logger and cros_ec_ishtp"

    * tag 'tag-chrome-platform-for-v5.4' of git://git.kernel.org/pub/scm/linux/kernel/git/chrome-platform/linux:
    platform/chrome: cros_usbpd_logger: null check create_singlethread_workqueue
    platform/chrome: cros_ec_chardev: Add a poll handler to receive MKBP events
    platform/chrome: cros_ec_rpmsg: Fix race with host command when probe failed
    platform/chrome: chromeos_tbmc: Report wake events
    mfd: cros_ec: Use mfd_add_hotplug_devices() helper
    mfd: cros_ec: Add convenience struct to define autodetectable CrOS EC subdevices
    mfd: cros_ec: Add convenience struct to define dedicated CrOS EC MCUs
    mfd: cros_ec: Use kzalloc and cros_ec_cmd_xfer_status helper
    mfd / platform: cros_ec: Reorganize platform and mfd includes
    mfd / platform: cros_ec: Rename config to a better name
    mfd: cros_ec: Switch to use the new cros-ec-chardev driver
    mfd / platform: cros_ec: Miscellaneous character device to talk with the EC
    mfd / platform: cros_ec: Move cros-ec core driver out from MFD
    mfd / platform: cros_ec: Handle chained ECs as platform devices
    platform/chrome: cros_ec_rpmsg: Add host command AP sleep state support
    platform/chrome: chromeos_laptop: drop checks of NULL-safe functions
    platform/chrome: wilco_ec: Add batt_ppid_info command to telemetry driver

    Linus Torvalds
     

19 Sep, 2019

2 commits

  • Pull USB updates from Greg KH:
    "Here is the big set of USB patches for 5.4-rc1.

    Two major chunks of code are moving out of the tree and into the
    staging directory, uwb and wusb (wireless USB support), because there
    are no devices that actually use this protocol anymore, and what we
    have today probably doesn't work at all given that the maintainers
    left many many years ago. So move it to staging where it will be
    removed in a few releases if no one screams.

    Other than that, lots of little things. The usual gadget and xhci and
    usb serial driver updates, along with a bunch of sysfs file cleanups
    due to the driver core changes to support that. Nothing really major,
    just constant forward progress.

    All of these have been in linux-next for a while with no reported
    issues"

    * tag 'usb-5.4-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb: (159 commits)
    USB: usbcore: Fix slab-out-of-bounds bug during device reset
    usb: cdns3: Remove redundant dev_err call in cdns3_probe()
    USB: rio500: Fix lockdep violation
    USB: rio500: simplify locking
    usb: mtu3: register a USB Role Switch for dual role mode
    usb: common: add USB GPIO based connection detection driver
    usb: common: create Kconfig file
    usb: roles: get usb-role-switch from parent
    usb: roles: Add fwnode_usb_role_switch_get() function
    device connection: Add fwnode_connection_find_match()
    usb: roles: Introduce stubs for the exiting functions in role.h
    dt-bindings: usb: mtu3: add properties about USB Role Switch
    dt-bindings: usb: add binding for USB GPIO based connection detection driver
    dt-bindings: connector: add optional properties for Type-B
    dt-binding: usb: add usb-role-switch property
    usbip: Implement SG support to vhci-hcd and stub driver
    usb: roles: intel: Enable static DRD mode for role switch
    xhci-ext-caps.c: Add property to disable Intel SW switch
    usb: dwc3: remove generic PHY calibrate() calls
    usb: core: phy: add support for PHY calibration
    ...

    Linus Torvalds
     
  • Pull driver core updates from Greg Kroah-Hartman:
    "Here is the big driver core update for 5.4-rc1.

    There was a bit of a churn in here, with a number of core and OF
    platform patches being added to the tree, and then after much
    discussion and review and a day-long in-person meeting, they were
    decided to be reverted and a new set of patches is currently being
    reviewed on the mailing list.

    Other than that churn, there are two "persistent" branches in here
    that other trees will be pulling in as well during the merge window.
    One branch to add support for drivers to have the driver core
    automatically add sysfs attribute files when a driver is bound to a
    device so that the driver doesn't have to manually do it (and then
    clean it up, as it always gets it wrong).

    There's another branch in here for generic lookup helpers for the
    driver core that lots of busses are starting to use. That's the
    majority of the non-driver-core changes in this patch series.

    There's also some on-going debugfs file creation cleanup that has been
    slowly happening over the past few releases, with the goal to
    hopefully get that done sometime next year.

    All of these have been in linux-next for a while now with no reported
    issues"

    [ Note that the above-mentioned generic lookup helpers branch was
    already brought in by the LED merge (commit 4feaab05dc1e) that had
    shared it.

    Also note that that common branch introduced an i2c bug due to a bad
    conversion, which got fixed here. - Linus ]

    * tag 'driver-core-5.4-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core: (49 commits)
    coccinelle: platform_get_irq: Fix parse error
    driver-core: add include guard to linux/container.h
    sysfs: add BIN_ATTR_WO() macro
    driver core: platform: Export platform_get_irq_optional()
    hwmon: pwm-fan: Use platform_get_irq_optional()
    driver core: platform: Introduce platform_get_irq_optional()
    Revert "driver core: Add support for linking devices during device addition"
    Revert "driver core: Add edit_links() callback for drivers"
    Revert "of/platform: Add functional dependency link from DT bindings"
    Revert "driver core: Add sync_state driver/bus callback"
    Revert "of/platform: Pause/resume sync state during init and of_platform_populate()"
    Revert "of/platform: Create device links for all child-supplier depencencies"
    Revert "of/platform: Don't create device links for default busses"
    Revert "of/platform: Fix fn definitons for of_link_is_valid() and of_link_property()"
    Revert "of/platform: Fix device_links_supplier_sync_state_resume() warning"
    Revert "of/platform: Disable generic device linking code for PowerPC"
    devcoredump: fix typo in comment
    devcoredump: use memory_read_from_buffer
    of/platform: Disable generic device linking code for PowerPC
    device.h: Fix warnings for mismatched parameter names in comments
    ...

    Linus Torvalds
     

18 Sep, 2019

1 commit

  • …anaszewski/linux-leds

    Pull LED updates from Jacek Anaszewski:
    "In this cycle we've finally managed to contribute the patch set
    sorting out LED naming issues. Besides that there are many changes
    scattered among various LED class drivers and triggers.

    LED naming related improvements:

    - add new 'function' and 'color' fwnode properties and deprecate
    'label' property which has been frequently abused for conveying
    vendor specific names that have been available in sysfs anyway

    - introduce a set of standard LED_FUNCTION* definitions

    - introduce a set of standard LED_COLOR_ID* definitions

    - add a new {devm_}led_classdev_register_ext() API with the
    capability of automatic LED name composition basing on the
    properties available in the passed fwnode; the function is
    backwards compatible in a sense that it uses 'label' data, if
    present in the fwnode, for creating LED name

    - add tools/leds/get_led_device_info.sh script for retrieving LED
    vendor, product and bus names, if applicable; it also performs
    basic validation of an LED name

    - update following drivers and their DT bindings to use the new LED
    registration API:

    - leds-an30259a, leds-gpio, leds-as3645a, leds-aat1290, leds-cr0014114,
    leds-lm3601x, leds-lm3692x, leds-lp8860, leds-lt3593, leds-sc27xx-blt

    Other LED class improvements:

    - replace {devm_}led_classdev_register() macros with inlines

    - allow to call led_classdev_unregister() unconditionally

    - switch to use fwnode instead of be stuck with OF one

    LED triggers improvements:

    - led-triggers:
    - fix dereferencing of null pointer
    - fix a memory leak bug

    - ledtrig-gpio:
    - GPIO 0 is valid

    Drop superseeded apu2/3 support from leds-apu since for apu2+ a newer,
    more complete driver exists, based on a generic driver for the AMD
    SOCs gpio-controller, supporting LEDs as well other devices:

    - drop profile field from priv data

    - drop iosize field from priv data

    - drop enum_apu_led_platform_types

    - drop superseeded apu2/3 led support

    - add pr_fmt prefix for better log output

    - fix error message on probing failure

    Other misc fixes and improvements to existing LED class drivers:

    - leds-ns2, leds-max77650:
    - add of_node_put() before return

    - leds-pwm, leds-is31fl32xx:
    - use struct_size() helper

    - leds-lm3697, leds-lm36274, leds-lm3532:
    - switch to use fwnode_property_count_uXX()

    - leds-lm3532:
    - fix brightness control for i2c mode
    - change the define for the fs current register
    - fixes for the driver for stability
    - add full scale current configuration
    - dt: Add property for full scale current.
    - avoid potentially unpaired regulator calls
    - move static keyword to the front of declarations
    - fix optional led-max-microamp prop error handling

    - leds-max77650:
    - add of_node_put() before return
    - add MODULE_ALIAS()
    - Switch to fwnode property API

    - leds-as3645a:
    - fix misuse of strlcpy

    - leds-netxbig:
    - add of_node_put() in netxbig_leds_get_of_pdata()
    - remove legacy board-file support

    - leds-is31fl319x:
    - simplify getting the adapter of a client

    - leds-ti-lmu-common:
    - fix coccinelle issue
    - move static keyword to the front of declaration

    - leds-syscon:
    - use resource managed variant of device register

    - leds-ktd2692:
    - fix a typo in the name of a constant

    - leds-lp5562:
    - allow firmware files up to the maximum length

    - leds-an30259a:
    - fix typo

    - leds-pca953x:
    - include the right header"

    * tag 'leds-for-5.4-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/j.anaszewski/linux-leds: (72 commits)
    leds: lm3532: Fix optional led-max-microamp prop error handling
    led: triggers: Fix dereferencing of null pointer
    leds: ti-lmu-common: Move static keyword to the front of declaration
    leds: lm3532: Move static keyword to the front of declarations
    leds: trigger: gpio: GPIO 0 is valid
    leds: pwm: Use struct_size() helper
    leds: is31fl32xx: Use struct_size() helper
    leds: ti-lmu-common: Fix coccinelle issue in TI LMU
    leds: lm3532: Avoid potentially unpaired regulator calls
    leds: syscon: Use resource managed variant of device register
    leds: Replace {devm_}led_classdev_register() macros with inlines
    leds: Allow to call led_classdev_unregister() unconditionally
    leds: lm3532: Add full scale current configuration
    dt: lm3532: Add property for full scale current.
    leds: lm3532: Fixes for the driver for stability
    leds: lm3532: Change the define for the fs current register
    leds: lm3532: Fix brightness control for i2c mode
    leds: Switch to use fwnode instead of be stuck with OF one
    leds: max77650: Switch to fwnode property API
    led: triggers: Fix a memory leak bug
    ...

    Linus Torvalds
     

03 Sep, 2019

2 commits


02 Sep, 2019

6 commits

  • Use mfd_add_hotplug_devices() helper to register the subdevices. The
    helper allows us to reduce the boiler plate and also registers the
    subdevices in the same way as used in other functions used in this
    files.

    Signed-off-by: Enric Balletbo i Serra
    Reviewed-by: Gwendal Grignou
    Tested-by: Gwendal Grignou
    Signed-off-by: Lee Jones

    Enric Balletbo i Serra
     
  • The CrOS EC is gaining lots of subdevices that are autodetectable by
    sending the EC_FEATURE_GET_CMD, it takes fair amount of boiler plate
    code to add those devices. So, add a struct that can be used to quickly
    add new subdevices without having to duplicate code.

    Signed-off-by: Enric Balletbo i Serra
    Acked-by: Andy Shevchenko
    Reviewed-by: Gwendal Grignou
    Tested-by: Gwendal Grignou
    Signed-off-by: Lee Jones

    Enric Balletbo i Serra
     
  • With the increasing use of dedicated CrOS EC MCUs, it takes a fair amount
    of boiler plate code to add those devices, add a struct that can be used
    to specify a dedicated CrOS EC MCU so we can just add a new item to it to
    define a new dedicated MCU.

    Signed-off-by: Enric Balletbo i Serra
    Acked-by: Andy Shevchenko
    Reviewed-by: Gwendal Grignou
    Tested-by: Gwendal Grignou
    Signed-off-by: Lee Jones

    Enric Balletbo i Serra
     
  • This patch makes use of cros_ec_cmd_xfer_status() instead of
    cros_ec_cmd_xfer() so we can remove some redundant code. It also uses
    kzalloc instead of kmalloc so we can remove more redundant code.

    Signed-off-by: Enric Balletbo i Serra
    Acked-by: Andy Shevchenko
    Reviewed-by: Gwendal Grignou
    Tested-by: Gwendal Grignou
    Signed-off-by: Lee Jones

    Enric Balletbo i Serra
     
  • There is a bit of mess between cros-ec mfd includes and platform
    includes. For example, we have a linux/mfd/cros_ec.h include that
    exports the interface implemented in platform/chrome/cros_ec_proto.c. Or
    we have a linux/mfd/cros_ec_commands.h file that is non related to the
    multifunction device (in the sense that is not exporting any function of
    the mfd device). This causes crossed includes between mfd and
    platform/chrome subsystems and makes the code difficult to read, apart
    from creating 'curious' situations where a platform/chrome driver includes
    a linux/mfd/cros_ec.h file just to get the exported functions that are
    implemented in another platform/chrome driver.

    In order to have a better separation on what the cros-ec multifunction
    driver does and what the cros-ec core provides move and rework the
    affected includes doing:

    - Move cros_ec_commands.h to include/linux/platform_data/cros_ec_commands.h
    - Get rid of the parts that are implemented in the platform/chrome/cros_ec_proto.c
    driver from include/linux/mfd/cros_ec.h to a new file
    include/linux/platform_data/cros_ec_proto.h
    - Update all the drivers with the new includes, so
    - Drivers that only need to know about the protocol include
    - linux/platform_data/cros_ec_proto.h
    - linux/platform_data/cros_ec_commands.h
    - Drivers that need to know about the cros-ec mfd device also include
    - linux/mfd/cros_ec.h

    Signed-off-by: Enric Balletbo i Serra
    Acked-by: Andy Shevchenko
    Acked-by: Mark Brown
    Acked-by: Wolfram Sang
    Acked-by: Neil Armstrong
    Acked-by: Alexandre Belloni
    Acked-by: Jonathan Cameron
    Acked-by: Benjamin Tissoires
    Acked-by: Dmitry Torokhov
    Acked-by: Sebastian Reichel
    Acked-by: Chanwoo Choi
    Reviewed-by: Gwendal Grignou
    Tested-by: Gwendal Grignou
    Series changes: 3
    - Fix dereferencing pointer to incomplete type 'struct cros_ec_dev' (lkp)
    Signed-off-by: Lee Jones

    Enric Balletbo i Serra
     
  • The cros-ec-dev is a multifunction device that now doesn't implement any
    chardev communication interface. MFD_CROS_EC_CHARDEV doesn't look
    a good name to describe that device and can cause confusion. Hence
    rename it to CROS_EC_DEV.

    Signed-off-by: Enric Balletbo i Serra
    Acked-by: Andy Shevchenko
    Reviewed-by: Gwendal Grignou
    Tested-by: Gwendal Grignou
    Signed-off-by: Lee Jones

    Enric Balletbo i Serra