18 Mar, 2016

1 commit

  • Pull dmaengine updates from Vinod Koul:
    "This is smallish update with minor changes to core and new driver and
    usual updates. Nothing super exciting here..

    - We have made slave address as physical to enable driver to do the
    mapping.

    - We now expose the maxburst for slave dma as new capability so
    clients can know this and program accordingly

    - addition of device synchronize callbacks on omap and edma.

    - pl330 updates to support DMAFLUSHP for Rockchip platforms.

    - Updates and improved sg handling in Xilinx VDMA driver.

    - New hidma qualcomm dma driver, though some bits are still in
    progress"

    * tag 'dmaengine-4.6-rc1' of git://git.infradead.org/users/vkoul/slave-dma: (40 commits)
    dmaengine: IOATDMA: revise channel reset workaround on CB3.3 platforms
    dmaengine: add Qualcomm Technologies HIDMA channel driver
    dmaengine: add Qualcomm Technologies HIDMA management driver
    dmaengine: hidma: Add Device Tree binding
    dmaengine: qcom_bam_dma: move to qcom directory
    dmaengine: tegra: Move of_device_id table near to its user
    dmaengine: xilinx_vdma: Remove unnecessary variable initializations
    dmaengine: sirf: use __maybe_unused to hide pm functions
    dmaengine: rcar-dmac: clear pertinence number of channels
    dmaengine: sh: shdmac: don't open code of_device_get_match_data()
    dmaengine: tegra: don't open code of_device_get_match_data()
    dmaengine: qcom_bam_dma: Make driver work for BE
    dmaengine: sun4i: support module autoloading
    dma/mic_x100_dma: IS_ERR() vs PTR_ERR() typo
    dmaengine: xilinx_vdma: Use readl_poll_timeout instead of do while loop's
    dmaengine: xilinx_vdma: Simplify spin lock handling
    dmaengine: xilinx_vdma: Fix issues with non-parking mode
    dmaengine: xilinx_vdma: Improve SG engine handling
    dmaengine: pl330: fix to support the burst mode
    dmaengine: make slave address physical
    ...

    Linus Torvalds
     

11 Mar, 2016

1 commit


10 Mar, 2016

2 commits


09 Mar, 2016

3 commits


06 Mar, 2016

1 commit


05 Mar, 2016

1 commit

  • Rockchip_spi_set_cs could be called by spi_setup, but
    spi_setup may be called by device driver after runtime suspend.
    Then the spi clock is closed, rockchip_spi_set_cs may access the
    spi registers, which causes cpu block in some socs.

    Fixes: 64e36824b32 ("spi/rockchip: add driver for Rockchip RK3xxx")
    Signed-off-by: Huibin Hong
    Signed-off-by: Mark Brown

    Huibin Hong
     

18 Feb, 2016

1 commit


16 Feb, 2016

1 commit


15 Feb, 2016

2 commits


09 Feb, 2016

1 commit

  • Generic dma controller on Rockchips' platform cannot support
    DMAFLUSHP instruction which make dma to flush the req of non-aligned
    or non-multiple of what we need. That will cause an unrecoverable
    dma bus error. The saftest way is to set dma max burst to 1.

    Signed-off-by: Addy ke
    Fixes: 64e36824b32b06 ("spi/rockchip: add driver for Rockchip...")
    Signed-off-by: Shawn Lin
    cc: Heiko Stuebner
    cc: Olof Johansson
    cc: Doug Anderson
    cc: Sonny Rao

    Acked-by: Mark Brown
    Signed-off-by: Caesar Wang
    Signed-off-by: Vinod Koul

    Addy Ke
     

07 Jul, 2015

1 commit


12 Apr, 2015

1 commit


27 Mar, 2015

2 commits

  • We have found that we can sometimes see read failures on boards with
    high-capacitance SPI lines. It seems that the controller samples the Rx
    data line too early, and its register interface has an "Rx Sample Delay"
    setting to fine-tune against this issue.

    This patch adds a new optional device tree entry that can configure this
    delay in terms of nanoseconds. The kernel will calculate the
    best-fitting amount of parent clock ticks to program the controller with
    based on that.

    Signed-off-by: Julius Werner
    Signed-off-by: Mark Brown

    Julius Werner
     
  • The Rockchip SPI driver currently calculates its clock rate divisor by
    integer dividing the parent rate by the target rate, and then rounding
    the result up to the next even number (since the divisor must be
    even).

    Clock rate divisors should always be rounded up, so that the resulting
    frequency is lower or equal to the target. This is correctly done in the
    second step here but not in the first, so we still have a risk of
    exceeding the desired target frequency (e.g. setting spi-max-frequency
    to 40000000 with a parent clock of 99000000 could lead to a divisor of
    99000000 / 40000000 == 2 (which is even) that then results in an
    effective frequency of 99000000 / 2 == 49500000 (potentially exceeding
    the flash chip's specifications).

    This patch changes the division to round up to fix this problem.

    Signed-off-by: Julius Werner
    Signed-off-by: Mark Brown

    Julius Werner
     

07 Mar, 2015

1 commit


29 Jan, 2015

1 commit

  • We currently get a warning about potentially uninitialized variables
    in the rockchip spi driver, at least in certain toolchain versions:

    spi/spi-rockchip.c: In function 'rockchip_spi_prepare_dma':
    include/linux/dmaengine.h:796:2: warning: 'txdesc' may be used uninitialized in this function
    include/linux/dmaengine.h:796:2: warning: 'rxdesc' may be used uninitialized in this function

    The reason seems to be that gcc cannot know whether the value
    of the rs->rx and rs->tx variables change between the two points
    these are accessed.

    The code is actually correct, but to make this clearer to the
    compiler, this changes the conditionals to test for the local
    rxdesc/txdesc variables instead, which it knows won't change.

    Signed-off-by: Arnd Bergmann
    Signed-off-by: Mark Brown

    Arnd Bergmann
     

19 Dec, 2014

1 commit

  • Pull more ACPI and power management updates from Rafael Wysocki:
    "These are regression fixes (leds-gpio, ACPI backlight driver,
    operating performance points library, ACPI device enumeration
    messages, cpupower tool), other bug fixes (ACPI EC driver, ACPI device
    PM), some cleanups in the operating performance points (OPP)
    framework, continuation of CONFIG_PM_RUNTIME elimination, a couple of
    minor intel_pstate driver changes, a new MAINTAINERS entry for it and
    an ACPI fan driver change needed for better support of thermal
    management in user space.

    Specifics:

    - Fix a regression in leds-gpio introduced by a recent commit that
    inadvertently changed the name of one of the properties used by the
    driver (Fabio Estevam).

    - Fix a regression in the ACPI backlight driver introduced by a
    recent fix that missed one special case that had to be taken into
    account (Aaron Lu).

    - Drop the level of some new kernel messages from the ACPI core
    introduced by a recent commit to KERN_DEBUG which they should have
    used from the start and drop some other unuseful KERN_ERR messages
    printed by ACPI (Rafael J Wysocki).

    - Revert an incorrect commit modifying the cpupower tool (Prarit
    Bhargava).

    - Fix two regressions introduced by recent commits in the OPP library
    and clean up some existing minor issues in that code (Viresh
    Kumar).

    - Continue to replace CONFIG_PM_RUNTIME with CONFIG_PM throughout the
    tree (or drop it where that can be done) in order to make it
    possible to eliminate CONFIG_PM_RUNTIME (Rafael J Wysocki, Ulf
    Hansson, Ludovic Desroches).

    There will be one more "CONFIG_PM_RUNTIME removal" batch after this
    one, because some new uses of it have been introduced during the
    current merge window, but that should be sufficient to finally get
    rid of it.

    - Make the ACPI EC driver more robust against race conditions related
    to GPE handler installation failures (Lv Zheng).

    - Prevent the ACPI device PM core code from attempting to disable
    GPEs that it has not enabled which confuses ACPICA and makes it
    report errors unnecessarily (Rafael J Wysocki).

    - Add a "force" command line switch to the intel_pstate driver to
    make it possible to override the blacklisting of some systems in
    that driver if needed (Ethan Zhao).

    - Improve intel_pstate code documentation and add a MAINTAINERS entry
    for it (Kristen Carlson Accardi).

    - Make the ACPI fan driver create cooling device interfaces witn
    names that reflect the IDs of the ACPI device objects they are
    associated with, except for "generic" ACPI fans (PNP ID "PNP0C0B").

    That's necessary for user space thermal management tools to be able
    to connect the fans with the parts of the system they are supposed
    to be cooling properly. From Srinivas Pandruvada"

    * tag 'pm+acpi-3.19-rc1-2' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm: (32 commits)
    MAINTAINERS: add entry for intel_pstate
    ACPI / video: update the skip case for acpi_video_device_in_dod()
    power / PM: Eliminate CONFIG_PM_RUNTIME
    NFC / PM: Replace CONFIG_PM_RUNTIME with CONFIG_PM
    SCSI / PM: Replace CONFIG_PM_RUNTIME with CONFIG_PM
    ACPI / EC: Fix unexpected ec_remove_handlers() invocations
    Revert "tools: cpupower: fix return checks for sysfs_get_idlestate_count()"
    tracing / PM: Replace CONFIG_PM_RUNTIME with CONFIG_PM
    x86 / PM: Replace CONFIG_PM_RUNTIME in io_apic.c
    PM: Remove the SET_PM_RUNTIME_PM_OPS() macro
    mmc: atmel-mci: use SET_RUNTIME_PM_OPS() macro
    PM / Kconfig: Replace PM_RUNTIME with PM in dependencies
    ARM / PM: Replace CONFIG_PM_RUNTIME with CONFIG_PM
    sound / PM: Replace CONFIG_PM_RUNTIME with CONFIG_PM
    phy / PM: Replace CONFIG_PM_RUNTIME with CONFIG_PM
    video / PM: Replace CONFIG_PM_RUNTIME with CONFIG_PM
    tty / PM: Replace CONFIG_PM_RUNTIME with CONFIG_PM
    spi: Replace CONFIG_PM_RUNTIME with CONFIG_PM
    ACPI / PM: Do not disable wakeup GPEs that have not been enabled
    ACPI / utils: Drop error messages from acpi_evaluate_reference()
    ...

    Linus Torvalds
     

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
     

13 Dec, 2014

1 commit

  • After commit b2b49ccbdd54 (PM: Kconfig: Set PM_RUNTIME if PM_SLEEP is
    selected) PM_RUNTIME is always set if PM is set, so #ifdef blocks
    depending on CONFIG_PM_RUNTIME may now be changed to depend on
    CONFIG_PM.

    Replace CONFIG_PM_RUNTIME with CONFIG_PM everywhere under
    drivers/spi/.

    Signed-off-by: Rafael J. Wysocki
    Acked-by: Mark Brown

    Rafael J. Wysocki
     

08 Dec, 2014

1 commit


12 Nov, 2014

1 commit


04 Nov, 2014

1 commit


20 Oct, 2014

1 commit


17 Oct, 2014

1 commit


15 Oct, 2014

2 commits


03 Oct, 2014

1 commit


25 Sep, 2014

1 commit


17 Sep, 2014

1 commit


05 Sep, 2014

2 commits

  • The reference manual from Rockchip claims this about the BSF (SPI Busy
    Flag):
    * 0 - SPI is idle or disabled
    * 1 - SPI is actively transferring data

    The above doesn't quite appear to be true. Specifically I found the
    busy bit set when SPI was disabled. Let's change the WARN_ON() so we
    only check the busy bit if the controller was enabled.

    Signed-off-by: Doug Anderson
    Signed-off-by: Mark Brown

    Doug Anderson
     
  • The wait_for_idle() could get unlucky and timeout too quickly.
    Specifically, the old calculation was effectively:
    timeout = jiffies + 1;
    if (jiffies >= timeout) print warning;

    From the above it should be obvious that if jiffies ticks in just the
    wrong place then we'll have an effective timeout of 0.

    Fix this by effectively changing the above ">=" to a ">". That gives
    us an extra jiffy to finish.

    Signed-off-by: Doug Anderson
    Signed-off-by: Mark Brown

    Doug Anderson
     

29 Aug, 2014

1 commit

  • If our client is requesting a clock that is above the maximum clock
    then the following division will result in 0:
    rs->max_freq / rs->speed

    We'll then program 0 into the SPI_BAUDR register. The Rockchip TRM
    says: "If the value is 0, the serial output clock (sclk_out) is
    disabled."

    It's much better to end up with the fastest possible clock rather than
    a clock that is off, so enforce a minimum value.

    Signed-off-by: Doug Anderson
    Signed-off-by: Mark Brown

    Doug Anderson
     

20 Aug, 2014

1 commit


26 Jul, 2014

3 commits