11 Nov, 2015

1 commit

  • Pull ARM SoC driver updates from Olof Johansson:
    "As we've enabled multiplatform kernels on ARM, and greatly done away
    with the contents under arch/arm/mach-*, there's still need for
    SoC-related drivers to go somewhere.

    Many of them go in through other driver trees, but we still have
    drivers/soc to hold some of the "doesn't fit anywhere" lowlevel code
    that might be shared between ARM and ARM64 (or just in general makes
    sense to not have under the architecture directory).

    This branch contains mostly such code:

    - Drivers for qualcomm SoCs for SMEM, SMD and SMD-RPM, used to
    communicate with power management blocks on these SoCs for use by
    clock, regulator and bus frequency drivers.

    - Allwinner Reduced Serial Bus driver, again used to communicate with
    PMICs.

    - Drivers for ARM's SCPI (System Control Processor). Not to be
    confused with PSCI (Power State Coordination Interface). SCPI is
    used to communicate with the assistant embedded cores doing power
    management, and we have yet to see how many of them will implement
    this for their hardware vs abstracting in other ways (or not at all
    like in the past).

    - To make confusion between SCPI and PSCI more likely, this release
    also includes an update of PSCI to interface version 1.0.

    - Rockchip support for power domains.

    - A driver to talk to the firmware on Raspberry Pi"

    * tag 'armsoc-drivers' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc: (57 commits)
    soc: qcom: smd-rpm: Correct size of outgoing message
    bus: sunxi-rsb: Add driver for Allwinner Reduced Serial Bus
    bus: sunxi-rsb: Add Allwinner Reduced Serial Bus (RSB) controller bindings
    ARM: bcm2835: add mutual inclusion protection
    drivers: psci: make PSCI 1.0 functions initialization version dependent
    dt-bindings: Correct paths in Rockchip power domains binding document
    soc: rockchip: power-domain: don't try to print the clock name in error case
    soc: qcom/smem: add HWSPINLOCK dependency
    clk: berlin: add cpuclk
    ARM: berlin: dts: add CLKID_CPU for BG2Q
    ARM: bcm2835: Add the Raspberry Pi firmware driver
    soc: qcom: smem: Move RPM message ram out of smem DT node
    soc: qcom: smd-rpm: Correct the active vs sleep state flagging
    soc: qcom: smd: delete unneeded of_node_put
    firmware: qcom-scm: build for correct architecture level
    soc: qcom: smd: Correct SMEM items for upper channels
    qcom-scm: add missing prototype for qcom_scm_is_available()
    qcom-scm: fix endianess issue in __qcom_scm_is_call_available
    soc: qcom: smd: Reject send of too big packets
    soc: qcom: smd: Handle big endian CPUs
    ...

    Linus Torvalds
     

26 Oct, 2015

1 commit

  • Reduced Serial Bus (RSB) is an Allwinner proprietery interface
    used to communicate with PMICs and other peripheral ICs.

    RSB is a two-wire push-pull serial bus that supports 1 master
    device and up to 15 active slave devices.

    Signed-off-by: Chen-Yu Tsai
    Reviewed-by: Mark Brown
    Acked-by: Arnd Bergmann
    Signed-off-by: Maxime Ripard
    Signed-off-by: Olof Johansson

    Chen-Yu Tsai
     

15 Oct, 2015

2 commits


29 Sep, 2015

1 commit


09 Sep, 2015

1 commit

  • Pull regmap updates from Mark Brown:
    "This has been a busy release for regmap.

    By far the biggest set of changes here are those from Markus Pargmann
    which implement support for block transfers in smbus devices. This
    required quite a bit of refactoring but leaves us better able to
    handle odd restrictions that controllers may have and with better
    performance on smbus.

    Other new features include:

    - Fix interactions with lockdep for nested regmaps (eg, when a device
    using regmap is connected to a bus where the bus controller has a
    separate regmap). Lockdep's default class identification is too
    crude to work without help.

    - Support for must write bitfield operations, useful for operations
    which require writing a bit to trigger them from Kuniori Morimoto.

    - Support for delaying during register patch application from Nariman
    Poushin.

    - Support for overriding cache state via the debugfs implementation
    from Richard Fitzgerald"

    * tag 'regmap-v4.3' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regmap: (25 commits)
    regmap: fix a NULL pointer dereference in __regmap_init
    regmap: Support bulk reads for devices without raw formatting
    regmap-i2c: Add smbus i2c block support
    regmap: Add raw_write/read checks for max_raw_write/read sizes
    regmap: regmap max_raw_read/write getter functions
    regmap: Introduce max_raw_read/write for regmap_bulk_read/write
    regmap: Add missing comments about struct regmap_bus
    regmap: No multi_write support if bus->write does not exist
    regmap: Split use_single_rw internally into use_single_read/write
    regmap: Fix regmap_bulk_write for bus writes
    regmap: regmap_raw_read return error on !bus->read
    regulator: core: Print at debug level on debugfs creation failure
    regmap: Fix regmap_can_raw_write check
    regmap: fix typos in regmap.c
    regmap: Fix integertypes for register address and value
    regmap: Move documentation to regmap.h
    regmap: Use different lockdep class for each regmap init call
    thermal: sti: Add parentheses around bridge->ops->regmap_init call
    mfd: vexpress: Add parentheses around bridge->ops->regmap_init call
    regmap: debugfs: Fix misuse of IS_ENABLED
    ...

    Linus Torvalds
     

03 Sep, 2015

1 commit

  • Weak header file declarations are error-prone because they make every
    definition weak, and the linker chooses one based on link order (see
    10629d711ed7 ("PCI: Remove __weak annotation from pcibios_get_phb_of_node
    decl")).

    mips_cdmm_phys_base() is defined only in arch/mips/mti-malta/malta-memory.c
    so there's no problem with multiple definitions. But it works better to
    have a weak default implementation and allow a strong function to override
    it. Then we don't have to test whether a definition is present, and if
    there are ever multiple strong definitions, we get a link error instead of
    calling a random definition.

    Add a weak mips_cdmm_phys_base() definition and remove the weak annotation
    from the declaration in arch/mips/include/asm/cdmm.h.

    Signed-off-by: Bjorn Helgaas
    Reviewed-by: James Hogan
    Cc: Andrew Bresticker
    Cc: linux-mips@linux-mips.org
    Cc: linux-kernel@vger.kernel.org
    Patchwork: https://patchwork.linux-mips.org/patch/10688/
    Signed-off-by: Ralf Baechle

    Bjorn Helgaas
     

07 Aug, 2015

1 commit


27 Jun, 2015

2 commits

  • Pull ARM SoC driver updates from Kevin Hilman:
    "Some of these are for drivers/soc, where we're now putting
    SoC-specific drivers these days. Some are for other driver subsystems
    where we have received acks from the appropriate maintainers.

    Some highlights:

    - simple-mfd: document DT bindings and misc updates
    - migrate mach-berlin to simple-mfd for clock, pinctrl and reset
    - memory: support for Tegra132 SoC
    - memory: introduce tegra EMC driver for scaling memory frequency
    - misc. updates for ARM CCI and CCN busses"

    * tag 'armsoc-drivers' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc: (48 commits)
    drivers: soc: sunxi: Introduce SoC driver to map SRAMs
    arm-cci: Add aliases for PMU events
    arm-cci: Add CCI-500 PMU support
    arm-cci: Sanitise CCI400 PMU driver specific code
    arm-cci: Abstract handling for CCI events
    arm-cci: Abstract out the PMU counter details
    arm-cci: Cleanup PMU driver code
    arm-cci: Do not enable CCI-400 PMU by default
    firmware: qcom: scm: Add HDCP Support
    ARM: berlin: add an ADC node for the BG2Q
    ARM: berlin: remove useless chip and system ctrl compatibles
    clk: berlin: drop direct of_iomap of nodes reg property
    ARM: berlin: move BG2Q clock node
    ARM: berlin: move BG2CD clock node
    ARM: berlin: move BG2 clock node
    clk: berlin: prepare simple-mfd conversion
    pinctrl: berlin: drop SoC stub provided regmap
    ARM: berlin: move pinctrl to simple-mfd nodes
    pinctrl: berlin: prepare to use regmap provided by syscon
    reset: berlin: drop arch_initcall initialization
    ...

    Linus Torvalds
     
  • Pull ARM SoC platform support updates from Kevin Hilman:
    "Our SoC branch usually contains expanded support for new SoCs and
    other core platform code. Some highlights from this round:

    - sunxi: SMP support for A23 SoC
    - socpga: big-endian support
    - pxa: conversion to common clock framework
    - bcm: SMP support for BCM63138
    - imx: support new I.MX7D SoC
    - zte: basic support for ZX296702 SoC"

    * tag 'armsoc-soc' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc: (134 commits)
    ARM: zx: Add basic defconfig support for ZX296702
    ARM: dts: zx: add an initial zx296702 dts and doc
    clk: zx: add clock support to zx296702
    dt-bindings: Add #defines for ZTE ZX296702 clocks
    ARM: socfpga: fix build error due to secondary_startup
    MAINTAINERS: ARM64: EXYNOS: Extend entry for ARM64 DTS
    ARM: ep93xx: simone: support for SPI-based MMC/SD cards
    MAINTAINERS: update Shawn's email to use kernel.org one
    ARM: socfpga: support suspend to ram
    ARM: socfpga: add CPU_METHOD_OF_DECLARE for Arria 10
    ARM: socfpga: use CPU_METHOD_OF_DECLARE for socfpga_cyclone5
    ARM: EXYNOS: register power domain driver from core_initcall
    ARM: EXYNOS: use PS_HOLD based poweroff for all supported SoCs
    ARM: SAMSUNG: Constify platform_device_id
    ARM: EXYNOS: Constify irq_domain_ops
    ARM: EXYNOS: add coupled cpuidle support for Exynos3250
    ARM: EXYNOS: add exynos_get_boot_addr() helper
    ARM: EXYNOS: add exynos_set_boot_addr() helper
    ARM: EXYNOS: make exynos_core_restart() less verbose
    ARM: EXYNOS: fix exynos_boot_secondary() return value on timeout
    ...

    Linus Torvalds
     

24 Jun, 2015

1 commit

  • Pull power management and ACPI updates from Rafael Wysocki:
    "The rework of backlight interface selection API from Hans de Goede
    stands out from the number of commits and the number of affected
    places perspective. The cpufreq core fixes from Viresh Kumar are
    quite significant too as far as the number of commits goes and because
    they should reduce CPU online/offline overhead quite a bit in the
    majority of cases.

    From the new featues point of view, the ACPICA update (to upstream
    revision 20150515) adding support for new ACPI 6 material to ACPICA is
    the one that matters the most as some new significant features will be
    based on it going forward. Also included is an update of the ACPI
    device power management core to follow ACPI 6 (which in turn reflects
    the Windows' device PM implementation), a PM core extension to support
    wakeup interrupts in a more generic way and support for the ACPI _CCA
    device configuration object.

    The rest is mostly fixes and cleanups all over and some documentation
    updates, including new DT bindings for Operating Performance Points.

    There is one fix for a regression introduced in the 4.1 cycle, but it
    adds quite a number of lines of code, it wasn't really ready before
    Thursday and you were on vacation, so I refrained from pushing it on
    the last minute for 4.1.

    Specifics:

    - ACPICA update to upstream revision 20150515 including basic support
    for ACPI 6 features: new ACPI tables introduced by ACPI 6 (STAO,
    XENV, WPBT, NFIT, IORT), changes related to the other tables (DTRM,
    FADT, LPIT, MADT), new predefined names (_BTH, _CR3, _DSD, _LPI,
    _MTL, _PRR, _RDI, _RST, _TFP, _TSN), fixes and cleanups (Bob Moore,
    Lv Zheng).

    - ACPI device power management core code update to follow ACPI 6
    which reflects the ACPI device power management implementation in
    Windows (Rafael J Wysocki).

    - rework of the backlight interface selection logic to reduce the
    number of kernel command line options and improve the handling of
    DMI quirks that may be involved in that and to make the code
    generally more straightforward (Hans de Goede).

    - fixes for the ACPI Embedded Controller (EC) driver related to the
    handling of EC transactions (Lv Zheng).

    - fix for a regression related to the ACPI resources management and
    resulting from a recent change of ACPI initialization code ordering
    (Rafael J Wysocki).

    - fix for a system initialization regression related to ACPI
    introduced during the 3.14 cycle and caused by running the code
    that switches the platform over to the ACPI mode too early in the
    initialization sequence (Rafael J Wysocki).

    - support for the ACPI _CCA device configuration object related to
    DMA cache coherence (Suravee Suthikulpanit).

    - ACPI/APEI fixes and cleanups (Jiri Kosina, Borislav Petkov).

    - ACPI battery driver cleanups (Luis Henriques, Mathias Krause).

    - ACPI processor driver cleanups (Hanjun Guo).

    - cleanups and documentation update related to the ACPI device
    properties interface based on _DSD (Rafael J Wysocki).

    - ACPI device power management fixes (Rafael J Wysocki).

    - assorted cleanups related to ACPI (Dominik Brodowski, Fabian
    Frederick, Lorenzo Pieralisi, Mathias Krause, Rafael J Wysocki).

    - fix for a long-standing issue causing General Protection Faults to
    be generated occasionally on return to user space after resume from
    ACPI-based suspend-to-RAM on 32-bit x86 (Ingo Molnar).

    - fix to make the suspend core code return -EBUSY consistently in all
    cases when system suspend is aborted due to wakeup detection (Ruchi
    Kandoi).

    - support for automated device wakeup IRQ handling allowing drivers
    to make their PM support more starightforward (Tony Lindgren).

    - new tracepoints for suspend-to-idle tracing and rework of the
    prepare/complete callbacks tracing in the PM core (Todd E Brandt,
    Rafael J Wysocki).

    - wakeup sources framework enhancements (Jin Qian).

    - new macro for noirq system PM callbacks (Grygorii Strashko).

    - assorted cleanups related to system suspend (Rafael J Wysocki).

    - cpuidle core cleanups to make the code more efficient (Rafael J
    Wysocki).

    - powernv/pseries cpuidle driver update (Shilpasri G Bhat).

    - cpufreq core fixes related to CPU online/offline that should reduce
    the overhead of these operations quite a bit, unless the CPU in
    question is physically going away (Viresh Kumar, Saravana Kannan).

    - serialization of cpufreq governor callbacks to avoid race
    conditions in some cases (Viresh Kumar).

    - intel_pstate driver fixes and cleanups (Doug Smythies, Prarit
    Bhargava, Joe Konno).

    - cpufreq driver (arm_big_little, cpufreq-dt, qoriq) updates (Sudeep
    Holla, Felipe Balbi, Tang Yuantian).

    - assorted cleanups in cpufreq drivers and core (Shailendra Verma,
    Fabian Frederick, Wang Long).

    - new Device Tree bindings for representing Operating Performance
    Points (Viresh Kumar).

    - updates for the common clock operations support code in the PM core
    (Rajendra Nayak, Geert Uytterhoeven).

    - PM domains core code update (Geert Uytterhoeven).

    - Intel Knights Landing support for the RAPL (Running Average Power
    Limit) power capping driver (Dasaratharaman Chandramouli).

    - fixes related to the floor frequency setting on Atom SoCs in the
    RAPL power capping driver (Ajay Thomas).

    - runtime PM framework documentation update (Ben Dooks).

    - cpupower tool fix (Herton R Krzesinski)"

    * tag 'pm+acpi-4.2-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm: (194 commits)
    cpuidle: powernv/pseries: Auto-promotion of snooze to deeper idle state
    x86: Load __USER_DS into DS/ES after resume
    PM / OPP: Add binding for 'opp-suspend'
    PM / OPP: Allow multiple OPP tables to be passed via DT
    PM / OPP: Add new bindings to address shortcomings of existing bindings
    ACPI: Constify ACPI device IDs in documentation
    ACPI / enumeration: Document the rules regarding the PRP0001 device ID
    ACPI / video: Make acpi_video_unregister_backlight() private
    acpi-video-detect: Remove old API
    toshiba-acpi: Port to new backlight interface selection API
    thinkpad-acpi: Port to new backlight interface selection API
    sony-laptop: Port to new backlight interface selection API
    samsung-laptop: Port to new backlight interface selection API
    msi-wmi: Port to new backlight interface selection API
    msi-laptop: Port to new backlight interface selection API
    intel-oaktrail: Port to new backlight interface selection API
    ideapad-laptop: Port to new backlight interface selection API
    fujitsu-laptop: Port to new backlight interface selection API
    eeepc-laptop: Port to new backlight interface selection API
    dell-wmi: Port to new backlight interface selection API
    ...

    Linus Torvalds
     

23 Jun, 2015

1 commit

  • Pull crypto update from Herbert Xu:
    "Here is the crypto update for 4.2:

    API:

    - Convert RNG interface to new style.

    - New AEAD interface with one SG list for AD and plain/cipher text.
    All external AEAD users have been converted.

    - New asymmetric key interface (akcipher).

    Algorithms:

    - Chacha20, Poly1305 and RFC7539 support.

    - New RSA implementation.

    - Jitter RNG.

    - DRBG is now seeded with both /dev/random and Jitter RNG. If kernel
    pool isn't ready then DRBG will be reseeded when it is.

    - DRBG is now the default crypto API RNG, replacing krng.

    - 842 compression (previously part of powerpc nx driver).

    Drivers:

    - Accelerated SHA-512 for arm64.

    - New Marvell CESA driver that supports DMA and more algorithms.

    - Updated powerpc nx 842 support.

    - Added support for SEC1 hardware to talitos"

    * git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6: (292 commits)
    crypto: marvell/cesa - remove COMPILE_TEST dependency
    crypto: algif_aead - Temporarily disable all AEAD algorithms
    crypto: af_alg - Forbid the use internal algorithms
    crypto: echainiv - Only hold RNG during initialisation
    crypto: seqiv - Add compatibility support without RNG
    crypto: eseqiv - Offer normal cipher functionality without RNG
    crypto: chainiv - Offer normal cipher functionality without RNG
    crypto: user - Add CRYPTO_MSG_DELRNG
    crypto: user - Move cryptouser.h to uapi
    crypto: rng - Do not free default RNG when it becomes unused
    crypto: skcipher - Allow givencrypt to be NULL
    crypto: sahara - propagate the error on clk_disable_unprepare() failure
    crypto: rsa - fix invalid select for AKCIPHER
    crypto: picoxcell - Update to the current clk API
    crypto: nx - Check for bogus firmware properties
    crypto: marvell/cesa - add DT bindings documentation
    crypto: marvell/cesa - add support for Kirkwood and Dove SoCs
    crypto: marvell/cesa - add support for Orion SoCs
    crypto: marvell/cesa - add allhwsupport module parameter
    crypto: marvell/cesa - add support for all armada SoCs
    ...

    Linus Torvalds
     

19 Jun, 2015

1 commit

  • * pm-sleep:
    PM / sleep: trace_device_pm_callback coverage in dpm_prepare/complete
    PM / wakeup: add a dummy wakeup_source to record statistics
    PM / sleep: Make suspend-to-idle-specific code depend on CONFIG_SUSPEND
    PM / sleep: Return -EBUSY from suspend_enter() on wakeup detection
    PM / tick: Add tracepoints for suspend-to-idle diagnostics
    PM / sleep: Fix symbol name in a comment in kernel/power/main.c
    leds / PM: fix hibernation on arm when gpio-led used with CPU led trigger
    ARM: omap-device: use SET_NOIRQ_SYSTEM_SLEEP_PM_OPS
    bus: omap_l3_noc: add missed callbacks for suspend-to-disk
    PM / sleep: Add macro to define common noirq system PM callbacks
    PM / sleep: Refine diagnostic messages in enter_state()
    PM / wakeup: validate wakeup source before activating it.

    * pm-runtime:
    PM / Runtime: Update last_busy in rpm_resume
    PM / runtime: add note about re-calling in during device probe()

    Rafael J. Wysocki
     

01 Jun, 2015

3 commits

  • Merge "changes for Broadcom SoCs":

    - Dan fixes an error path in the BCM63xx SMP code

    - Ray adds the relevant Kconfig selects to enable the Broadcom NAND driver on Cygnus

    - Kevin provides a change to the Broadcom GISB arbiter driver to make it work with
    MIPS-based big-endian STB SoCs (this was a long-standing change that had dependencies on
    code in drivers/of/*)

    - Gregory enables the use of GPIOLIB for brcmstb SoCs and bumps the number of GPIOs for
    these platforms

    * tag 'arm-soc/for-4.2/soc-part2' of http://github.com/broadcom/stblinux:
    ARM: brcmstb: Add default gpio number
    ARM: brcmstb: Select ARCH_WANT_OPTIONAL_GPIOLIB
    bus: brcmstb_gisb: Honor the "big-endian" and "native-endian" DT properties
    ARM: BCM: Enable NAND support for iProc SoCs
    ARM: BCM63xx: fix an error path in bcm63xx_pmb_power_on_cpu()

    Arnd Bergmann
     
  • Merge "mvebu drivers change for 4.2" from Gregory CLEMENT:

    mvebu-mbus: add mv_mbus_dram_info_nooverlap() needed for the new
    Marvell crypto driver

    * tag 'mvebu-drivers-4.2' of git://git.infradead.org/linux-mvebu:
    bus: mvebu-mbus: add mv_mbus_dram_info_nooverlap()

    Based on the earlier bug fixes branch, which contains six other
    patches already merged into 4.1.

    Arnd Bergmann
     
  • Merge "mvebu fixes for 4.1 (part 3)" from Gregory CLEMENT:

    Disable unused internal RTC for Mamba from linksys (Armada XP)
    And 2 commits fixing regressions on mvebu-mbus:
    - the first one for Kirkwood or Orion SoC
    - the second one for DMA when the platform have more than 4GB (only
    possible on Armada XP as far as I know)

    * tag 'mvebu-fixes-4.1-3' of git://git.infradead.org/linux-mvebu:
    Revert "bus: mvebu-mbus: make sure SDRAM CS for DMA don't overlap the MBus bridge window"
    bus: mvebu-mbus: do not set WIN_CTRL_SYNCBARRIER on non io-coherent platforms.
    ARM: mvebu: armada-xp-linksys-mamba: Disable internal RTC

    Arnd Bergmann
     

29 May, 2015

8 commits

  • Each CCI model have different event/source codes and formats. This
    patch exports this information via the sysfs, which includes the
    aliases for the events. The aliases are listed by 'perf list', helping
    the users to specify the name of the event instead of the binary
    config values.

    Each event alias must accompany the 'source' code except for the
    following cases :

    1) CCI-400 - cycles event, doesn't relate to an interface.
    2) CCI-500 - Global events to the CCI. (Fixed source code = 0xf)

    Each CCI model provides two sets of attributes(format and event),
    which are dynamically populated before registering the PMU, to
    allow for the appropriate information.

    Cc: Punit Agrawal
    Cc: Will Deacon
    Cc: Pawel Moll
    Cc: Mark Rutland
    Signed-off-by: Suzuki K. Poulose
    Acked-by: Punit Agrawal
    Signed-off-by: Arnd Bergmann

    Suzuki K. Poulose
     
  • CCI-500 provides 8 event counters which can count any of the
    supported events independently. The PMU event id is a 9-bit
    value made of two parts.
    bits [8:5] - Source port
    0x0-0x6 Slave Ports
    0x8-0xD Master Ports
    0xf Global Events to CCI
    0x7,0xe Reserved
    bits [0:4] - Event code (specific to each type of port)

    The generic CCI-500 controlling interface remains the same with CCI-400.
    However there are some differences in the PMU event counters.
    - No cycle counter
    - Upto 8 counters(4 in CCI-400)
    - Each counter area is 64K(4K in CCI400)
    - The counter0 starts at offset 0x10000 from the base of CCI

    Cc: Punit Agrawal
    Cc: Mark Rutland
    Cc: Will Deacon
    Cc: devicetree@vger.kernel.org
    Signed-off-by: Suzuki K. Poulose
    Acked-by: Punit Agrawal
    Signed-off-by: Arnd Bergmann

    Suzuki K. Poulose
     
  • Rename CCI400 specific defintions from CCI_xxx to CCI400_xxx.

    Introduce generic ARM_CCI_PMU to cover common code for handling
    the CCI PMU.

    Cc: Mark Rutland
    Cc: Will Deacon
    Cc: Punit Agrawal
    Signed-off-by: Suzuki K. Poulose
    Acked-by: Punit Agrawal
    Signed-off-by: Arnd Bergmann

    Suzuki K. Poulose
     
  • Given that each CCI has different set of interfaces and
    its associated events, it is good to abstract the validation of the
    event codes to make it easier to add support for a new CCI model.

    This patch also abstracts the mapping of a given event to a counter,
    as there are some special counters for certain specific events.

    We assume that the fixed hardware counters are always at the beginning,
    so that we can use cci_model->fixed_hw_events as an upper bound to given
    idx to check if we need to program the counter for an event.

    Cc: Punit Agrawal
    Cc: Mark Rutland
    Cc: Will Deacon
    Signed-off-by: Suzuki K. Poulose
    Acked-by: Punit Agrawal
    Signed-off-by: Arnd Bergmann

    Suzuki K. Poulose
     
  • Adds the PMU model specific counters to the PMU model
    abstraction to make it easier to add a new PMU.

    The patch cleans up the naming convention used all over
    the code.
    e.g, CCI_PMU_MAX_HW_EVENTS => maximum number of events that
    can be counted at any time, which is in fact the maximum
    number of counters available.

    Change all such namings to use 'counters' instead of events.

    This patch also abstracts the following:

    1) Size of a PMU event counter area.
    2) Maximum number of programmable counters supported by the PMU model
    3) Number of counters which counts fixed events (e.g, cycle
    counter on CCI-400).

    Also changes some of the static allocation of the data
    structures to dynamic, to accommodate the number of events
    supported by a PMU.

    Gets rid ofthe CCI_PMU_* defines for the model. All such
    data should be accessed via the model abstraction.

    Limits the number of counters to the maximum supported
    by the 'model'.

    Cc: Punit Agrawal
    Cc: Mark Rutland
    Cc: Will Deacon
    Signed-off-by: Suzuki K. Poulose
    Acked-by: Punit Agrawal
    Signed-off-by: Arnd Bergmann

    Suzuki K. Poulose
     
  • This patch gets rid of the global struct cci_pmu variable and makes
    the code use the cci_pmu explicitly. Makes code a bit more robust
    and reader friendly.

    Cc: Punit Agrawal
    Cc: Mark Rutland
    Cc: Will Deacon
    Signed-off-by: Suzuki K. Poulose
    Acked-by: Punit Agrawal
    Signed-off-by: Arnd Bergmann

    Suzuki K. Poulose
     
  • Do not enable CCI-400 PMU by default and fix the dependency on PERF_EVENTS
    than HW_PERF_EVENTS.

    Reported-by: Russell King
    Cc: Will Deacon
    Cc: arm@kernel.org
    Cc: Russell King
    Signed-off-by: Suzuki K. Poulose
    Signed-off-by: Arnd Bergmann

    Suzuki K. Poulose
     
  • On chips strapped for BE, we'll need to use ioread32be/iowrite32be instead of
    ioread32/iowrite32.

    Signed-off-by: Kevin Cernekee
    Signed-off-by: Florian Fainelli

    Kevin Cernekee
     

28 May, 2015

3 commits

  • This commit introduces a variant of the mv_mbus_dram_info() function
    called mv_mbus_dram_info_nooverlap(). Both functions are used by
    Marvell drivers supporting devices doing DMA, and provide them a
    description the DRAM ranges that they need to configure their DRAM
    windows.

    The ranges provided by the mv_mbus_dram_info() function may overlap
    with the I/O windows if there is a lot (>= 4 GB) of RAM
    installed. This is not a problem for most of the DMA masters, except
    for the upcoming new CESA crypto driver because it does DMA to the
    SRAM, which is mapped through an I/O window. For this unit, we need to
    have DRAM ranges that do not overlap with the I/O windows.

    A first implementation done in commit 1737cac69369 ("bus: mvebu-mbus:
    make sure SDRAM CS for DMA don't overlap the MBus bridge window"),
    changed the information returned by mv_mbus_dram_info() to match this
    requirement. However, it broke the requirement of the other DMA
    masters than the DRAM ranges should have power of two sizes.

    To solve this situation, this commit introduces a new
    mv_mbus_dram_info_nooverlap() function, which returns the same
    information as mv_mbus_dram_info(), but guaranteed to not overlap with
    the I/O windows.

    In the end, it gives us two variants of the mv_mbus_dram_info*()
    functions:

    - The normal one, mv_mbus_dram_info(), which has been around for many
    years. This function returns the raw DRAM ranges, which are
    guaranteed to use power of two sizes, but will overlap with I/O
    windows. This function will therefore be used by all DMA masters
    (SATA, XOR, Ethernet, etc.) except the CESA crypto driver.

    - The new 'nooverlap' variant, mv_mbus_dram_info_nooverlap(). This
    function returns DRAM ranges after they have been "tweaked" to make
    sure they don't overlap with I/O windows. By doing this tweaking,
    we remove the power of two size guarantee. This variant will be
    used by the new CESA crypto driver.

    Signed-off-by: Thomas Petazzoni
    Signed-off-by: Gregory CLEMENT

    Thomas Petazzoni
     
  • This reverts commit 1737cac69369 ("bus: mvebu-mbus: make sure SDRAM CS
    for DMA don't overlap the MBus bridge window"), because it breaks DMA
    on platforms having more than 2 GB of RAM.

    This commit changed the information reported to DMA masters device
    drivers through the mv_mbus_dram_info() function so that the returned
    DRAM ranges do not overlap with I/O windows.

    This was necessary as a preparation to support the new CESA Crypto
    Engine driver, which will use DMA for cryptographic operations. But
    since it does DMA with the SRAM which is mapped as an I/O window,
    having DRAM ranges overlapping with I/O windows was problematic.

    To solve this, the above mentioned commit changed the mvebu-mbus to
    adjust the DRAM ranges so that they don't overlap with the I/O
    windows. However, by doing this, we re-adjust the DRAM ranges in a way
    that makes them have a size that is no longer a power of two. While
    this is perfectly fine for the Crypto Engine, which supports DRAM
    ranges with a granularity of 64 KB, it breaks basically all other DMA
    masters, which expect power of two sizes for the DRAM ranges.

    Due to this, if the installed system memory is 4 GB, in two
    chip-selects of 2 GB, the second DRAM range will be reduced from 2 GB
    to a little bit less than 2 GB to not overlap with the I/O windows, in
    a way that results in a DRAM range that doesn't have a power of two
    size. This means that whenever you do a DMA transfer with an address
    located in the [ 2 GB ; 4 GB ] area, it will freeze the system. Any
    serious DMA activity like simply running:

    for i in $(seq 1 64) ; do dd if=/dev/urandom of=file$i bs=1M count=16 ; done

    in an ext3 partition mounted over a SATA drive will freeze the system.

    Since the new CESA crypto driver that uses DMA has not been merged
    yet, the easiest fix is to simply revert this commit. A follow-up
    commit will introduce a different solution for the CESA crypto driver.

    Signed-off-by: Thomas Petazzoni
    Fixes: 1737cac69369 ("bus: mvebu-mbus: make sure SDRAM CS for DMA don't overlap the MBus bridge window")
    Cc: # v4.0+
    Signed-off-by: Gregory CLEMENT

    Thomas Petazzoni
     
  • Commit a0b5cd4ac2d6 ("bus: mvebu-mbus: use automatic I/O
    synchronization barriers") enabled the usage of automatic I/O
    synchronization barriers by enabling bit WIN_CTRL_SYNCBARRIER in the
    control registers of MBus windows, but on non io-coherent platforms
    (orion5x, kirkwood and dove) the WIN_CTRL_SYNCBARRIER bit in
    the window control register is either reserved (all windows except 6
    and 7) or enables read-only protection (windows 6 and 7).

    Signed-off-by: Nicolas Schichan
    Reviewed-by: Thomas Petazzoni
    Cc: # v4.0+
    Fixes: a0b5cd4ac2d6 ("bus: mvebu-mbus: use automatic I/O synchronization barriers")
    Signed-off-by: Thomas Petazzoni
    Signed-off-by: Gregory CLEMENT

    Nicolas Schichan
     

26 May, 2015

1 commit

  • The MIPS Common Device Memory Map (CDMM) is internal to the core and has
    native endianness. There is therefore no need to byte swap the accesses
    on big endian targets, so convert the CDMM bus driver to use
    __raw_readl() rather than readl().

    Fixes: 8286ae03308c ("MIPS: Add CDMM bus support")
    Signed-off-by: James Hogan
    Cc: linux-mips@linux-mips.org
    Patchwork: https://patchwork.linux-mips.org/patch/9904/
    Signed-off-by: Ralf Baechle

    James Hogan
     

14 May, 2015

1 commit

  • hrtimer_start() will no longer defer already expired timers to the
    softirq in 4.2, and the __hrtimer_start_range_ns() function is
    getting removed, causing build errors when both the tip tree and
    the arm-ccn changes are merged.

    This changes the code back to using hrtimer_start, which will
    do the right thing after this branch gets merged with the
    timers update from tip.

    As pointed out after a discussion on the mailing list, the result will
    not be worse than the what was there before you pulled my updates, as
    the code was using normal hrtimer_start(). It's just when I realised
    that it should be pinned I looked at what x86 uncore pmu is doing and
    shamelessly (and probably a bit mindlessly) copied the "do not wakeup"
    version from there.

    [arnd: update commit message]
    Reported-by: Mark Brown
    Signed-off-by: Pawel Moll
    Signed-off-by: Arnd Bergmann

    Pawel Moll
     

13 May, 2015

1 commit


12 May, 2015

1 commit

  • Pull "Set of ARM CCN PMU driver updates" from Pawel Moll:

    - fixed a nasty bitfield mangling bug
    - added new hints to the perf userspace tool
    - pinned events processing to a single PMU
    - modified events initialisation so they can be rotated now

    * tag 'ccn/updates-for-4.2' of git://git.linaro.org/people/pawel.moll/linux:
    bus: arm-ccn: Allocate event when it is being added, not initialised
    bus: arm-ccn: Do not group CCN events with other PMUs
    bus: arm-ccn: Provide required event arguments
    bus: arm-ccn: cpumask attribute
    bus: arm-ccn: Fix node->XP config conversion

    Arnd Bergmann
     

08 May, 2015

1 commit

  • Currently in validate_group(), there is a static initializer
    for fake_pmu.used_mask which is based on CPU_BITS_NONE but
    the used_mask array size is based on CCI_PMU_MAX_HW_EVENTS.
    CCI_PMU_MAX_HW_EVENTS is not based on NR_CPUS, so CPU_BITS_NONE
    is not correct and will cause a build failure if NR_CPUS
    is set high enough to make CPU_BITS_NONE larger than used_mask.

    Reviewed-by: Mark Rutland
    Signed-off-by: Mark Salter
    Signed-off-by: Arnd Bergmann

    Mark Salter
     

05 May, 2015

2 commits

  • The L3 Error handling on OMAP5 for the most part is very similar
    to that of OMAP4, and had leveraged common data structures and
    register layout definitions so far. Upon closer inspection, there
    are a few minor differences causing an incorrect decoding and
    reporting of the master NIU upon an error:

    1. The L3_TARG_STDERRLOG_MSTADDR.STDERRLOG_MSTADDR occupies
    11 bits on OMAP5 as against 8 bits on OMAP4, with the master
    NIU connID encoded in the 6 MSBs of the STDERRLOG_MSTADDR
    field.
    2. The CLK3 FlagMux component has 1 input source on OMAP4 and 3
    input sources on OMAP5. The common DEBUGSS source is at a
    different input on each SoC.

    Fix the above issues by using a OMAP5-specific compatible property
    and using SoC-specific data where there are differences.

    Signed-off-by: Suman Anna
    Acked-by: Nishanth Menon
    Signed-off-by: Tony Lindgren

    Suman Anna
     
  • The base address for DRA7 CLK1_HOST_CLK1_2 host instance is
    0x44800000, so correct offset is 0x800000. DRA7 TRM rev X(fewb 2015)
    has updates for this information.

    With wrong offset these errors are not correctly cleared by the L3
    IRQ handler and cause an continuous interrupt scenario and system lockup.

    Signed-off-by: Illia Smyrnov
    Signed-off-by: Nishanth Menon
    Signed-off-by: Tony Lindgren

    Illia Smyrnov
     

02 May, 2015

5 commits

  • To make events rotation possible, they should be allocated when event
    is being ->added(), not during initialisation. This patch moves the
    respective code.

    Signed-off-by: Pawel Moll

    Pawel Moll
     
  • Groups must not mix events from different PMUs (software events are
    allowed). Unfortunately the core does not ensures that, so it is
    necessary to validate the group at the PMU driver level.

    Signed-off-by: Pawel Moll

    Pawel Moll
     
  • Since 688d4dfcdd624192cbf03c08402e444d1d11f294 "perf tools: Support
    parsing parameterized events" the perf userspace tools understands
    "argument=?" syntax in the events file, making sure that required
    arguments are provided by the user and not defaulting to 0, causing
    confusion.

    This patch adds the required arguments lists for CCN events.

    Signed-off-by: Pawel Moll

    Pawel Moll
     
  • This patch adds a "cpumask" attribute to CCN's event_source class sysfs
    directory. Perf user tool uses it to restrict events to the
    processor(s) enumerated in this mask.

    This patch provides a single CPU mask, making it possible to run "-a"
    perf session (previously it would request the same CCN event, for
    example cycle counter, on each available core and most likely fail).
    Initially the mask is set to the CPU that happened to probe the driver,
    but it will be changed when it is hot-un-plugged (active events are
    migrated to another CPU then).

    Example:

    Performance counter stats for 'system wide':

    CPU0 2968148 cycles
    CPU1 2236736 cycles
    CPU2 1797968 cycles
    CPU3 1831715 cycles
    CPU1 1201850868 ccn/cycles/

    1.001241383 seconds time elapsed

    Signed-off-by: Pawel Moll

    Pawel Moll
     
  • Events defined as watchpoints on nodes must have their config values
    converted so that they apply to the respective node's XP. The
    function setting new values was using wrong mask for the "port" field,
    resulting in corrupted value. Fixed now.

    Cc: stable@vger.kernel.org # 3.17+
    Signed-off-by: Pawel Moll

    Pawel Moll
     

23 Apr, 2015

1 commit

  • Pull ARM SoC driver updates from Olof Johansson:
    "Driver updates for v4.1. Some of these are for drivers/soc, where we
    find more and more SoC-specific drivers these days. Some are for
    other driver subsystems where we have received acks from the
    appropriate maintainers.

    The larger parts of this branch are:

    - MediaTek support for their PMIC wrapper interface, a high-level
    interface for talking to the system PMIC over a dedicated I2C
    interface.

    - Qualcomm SCM driver has been moved to drivers/firmware. It's used
    for CPU up/down and needs to be in a shared location for arm/arm64
    common code.

    - cleanup of ARM-CCI PMU code.

    - another set of cleanusp to the OMAP GPMC code"

    * tag 'armsoc-drivers' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc: (43 commits)
    soc/mediatek: Remove unused variables
    clocksource: atmel-st: select MFD_SYSCON
    soc: mediatek: Add PMIC wrapper for MT8135 and MT8173 SoCs
    arm-cci: Fix CCI PMU event validation
    arm-cci: Split the code for PMU vs driver support
    arm-cci: Get rid of secure transactions for PMU driver
    arm-cci: Abstract the CCI400 PMU specific definitions
    arm-cci: Rearrange code for splitting PMU vs driver code
    drivers: cci: reject groups spanning multiple HW PMUs
    ARM: at91: remove useless include
    clocksource: atmel-st: remove mach/hardware dependency
    clocksource: atmel-st: use syscon/regmap
    ARM: at91: time: move the system timer driver to drivers/clocksource
    ARM: at91: properly initialize timer
    ARM: at91: at91rm9200: remove deprecated arm_pm_restart
    watchdog: at91rm9200: implement restart handler
    watchdog: at91rm9200: use the system timer syscon
    mfd: syscon: Add atmel system timer registers definition
    ARM: at91/dt: declare atmel,at91rm9200-st as a syscon
    soc: qcom: gsbi: Add support for ADM CRCI muxing
    ...

    Linus Torvalds