18 Mar, 2020

1 commit

  • snprintf() is a hard-to-use function, it's especially difficult to use
    it for concatenating substrings in a buffer with a limited size.
    Since snprintf() returns the would-be-output size, not the actual
    size, the subsequent use of snprintf() may point to the incorrect
    position easily. Although the current code doesn't actually overflow
    the buffer, it's an incorrect usage.

    This patch replaces such snprintf() calls with a safer version,
    scnprintf().

    Acked-by: Mark Rutland
    Signed-off-by: Takashi Iwai
    Signed-off-by: Will Deacon

    Takashi Iwai
     

28 Oct, 2019

1 commit


01 Oct, 2019

1 commit


31 May, 2019

1 commit

  • Based on 1 normalized pattern(s):

    this program is free software you can redistribute it and or modify
    it under the terms of the gnu general public license version 2 as
    published by the free software foundation this program is
    distributed in the hope that it will be useful but without any
    warranty without even the implied warranty of merchantability or
    fitness for a particular purpose see the gnu general public license
    for more details

    extracted by the scancode license scanner the SPDX license identifier

    GPL-2.0-only

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

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

    Thomas Gleixner
     

23 Apr, 2019

1 commit

  • Like arm-cci, arm-ccn has the same issue of disabling preemption around
    operations which can take mutexes. Again, remove the definite bug by
    simply not trying to fight the theoretical races. And since we are
    touching the hotplug handling code, take the opportunity to streamline
    it, as there's really no need to store a full-sized cpumask to keep
    track of a single CPU ID.

    Reviewed-by: Suzuki K Poulose
    Signed-off-by: Robin Murphy
    Signed-off-by: Will Deacon

    Robin Murphy
     

21 Jan, 2019

1 commit

  • PERF_PMU_CAP_NO_EXCLUDE capability. This ensures that perf will
    prevent us from handling events where any exclusion flags are set.
    Let's also remove the now unnecessary check for exclusion flags.

    Signed-off-by: Andrew Murray
    Signed-off-by: Peter Zijlstra (Intel)
    Acked-by: Will Deacon
    Cc: Arnaldo Carvalho de Melo
    Cc: Benjamin Herrenschmidt
    Cc: Borislav Petkov
    Cc: Ivan Kokshaysky
    Cc: Linus Torvalds
    Cc: Mark Rutland
    Cc: Matt Turner
    Cc: Michael Ellerman
    Cc: Paul Mackerras
    Cc: Peter Zijlstra
    Cc: Richard Henderson
    Cc: Russell King
    Cc: Sascha Hauer
    Cc: Shawn Guo
    Cc: Thomas Gleixner
    Cc: linux-arm-kernel@lists.infradead.org
    Cc: linuxppc-dev@lists.ozlabs.org
    Cc: robin.murphy@arm.com
    Cc: suzuki.poulose@arm.com
    Link: https://lkml.kernel.org/r/1547128414-50693-8-git-send-email-andrew.murray@arm.com
    Signed-off-by: Ingo Molnar

    Andrew Murray
     

19 Aug, 2018

1 commit

  • Pull char/misc driver updates from Greg KH:
    "Here is the bit set of char/misc drivers for 4.19-rc1

    There is a lot here, much more than normal, seems like everyone is
    writing new driver subsystems these days... Anyway, major things here
    are:

    - new FSI driver subsystem, yet-another-powerpc low-level hardware
    bus

    - gnss, finally an in-kernel GPS subsystem to try to tame all of the
    crazy out-of-tree drivers that have been floating around for years,
    combined with some really hacky userspace implementations. This is
    only for GNSS receivers, but you have to start somewhere, and this
    is great to see.

    Other than that, there are new slimbus drivers, new coresight drivers,
    new fpga drivers, and loads of DT bindings for all of these and
    existing drivers.

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

    * tag 'char-misc-4.19-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/char-misc: (255 commits)
    android: binder: Rate-limit debug and userspace triggered err msgs
    fsi: sbefifo: Bump max command length
    fsi: scom: Fix NULL dereference
    misc: mic: SCIF Fix scif_get_new_port() error handling
    misc: cxl: changed asterisk position
    genwqe: card_base: Use true and false for boolean values
    misc: eeprom: assignment outside the if statement
    uio: potential double frees if __uio_register_device() fails
    eeprom: idt_89hpesx: clean up an error pointer vs NULL inconsistency
    misc: ti-st: Fix memory leak in the error path of probe()
    android: binder: Show extra_buffers_size in trace
    firmware: vpd: Fix section enabled flag on vpd_section_destroy
    platform: goldfish: Retire pdev_bus
    goldfish: Use dedicated macros instead of manual bit shifting
    goldfish: Add missing includes to goldfish.h
    mux: adgs1408: new driver for Analog Devices ADGS1408/1409 mux
    dt-bindings: mux: add adi,adgs1408
    Drivers: hv: vmbus: Cleanup synic memory free path
    Drivers: hv: vmbus: Remove use of slow_virt_to_phys()
    Drivers: hv: vmbus: Reset the channel callback in vmbus_onoffer_rescind()
    ...

    Linus Torvalds
     

26 Jul, 2018

1 commit

  • Instead of checking the return value of platform_get_resource(), we can
    use devm_ioremap_resource() which has the NULL pointer check and the
    memory region requesting. devm_ioremap_resource is designed to replace
    calls to devm_request_mem_region followed by devm_ioremap, so let's use
    the same.

    Cc: Will Deacon
    Cc: Mark Rutland
    Signed-off-by: Sudeep Holla
    Signed-off-by: Will Deacon

    Sudeep Holla
     

07 Jul, 2018

1 commit

  • At over 4000 #includes, is the 9th most
    #included header file in the Linux kernel. It does not need
    , so drop that header and explicitly add
    to source files that need it.

    4146 #include

    After this patch, there are 225 files that use ,
    for a reduction of around 3900 times that
    does not have to be read & parsed.

    225 #include

    This patch was build-tested on 20 different arch-es.

    It also makes these drivers SubmitChecklist#1 compliant.

    Signed-off-by: Randy Dunlap
    Reported-by: kbuild test robot # drivers/media/platform/vimc/
    Reported-by: kbuild test robot # drivers/pinctrl/pinctrl-u300.c
    Signed-off-by: Greg Kroah-Hartman

    Randy Dunlap
     

22 May, 2018

2 commits

  • The ARM CCN PMU driver uses dev_warn() to complain about parameters in
    the user-provided perf_event_attr. This means that under normal
    operation (e.g. a single invocation of the perf tool), a number of
    messages warnings may be logged to dmesg.

    Tools may issue multiple syscalls to probe for feature support, and
    multiple applications (from multiple users) can attempt to open events
    simultaneously, so this is not very helpful, even if a user happens to
    have access to dmesg. Worse, this can push important information out of
    the dmesg ring buffer, and can significantly slow down syscall fuzzers,
    vastly increasing the time it takes to find critical bugs.

    Demote the dev_warn() instances to dev_dbg(), as is the case for all
    other PMU drivers under drivers/perf/. Users who wish to debug PMU event
    initialisation can enable dynamic debug to receive these messages.

    Signed-off-by: Mark Rutland
    Cc: Pawel Moll
    Cc: Will Deacon
    Signed-off-by: Will Deacon

    Mark Rutland
     
  • The CCI/CCN drivers are licensed under GPLv2, but the MODULE_LICENSE()
    tags are using the bare "GPL" string implying GPLv2 or later. Fix them
    to match their actual file license.

    Acked-by: Pawel Moll
    Acked-by: Suzuki K Poulose
    Signed-off-by: Robin Murphy
    Signed-off-by: Will Deacon

    Robin Murphy
     

06 Apr, 2018

1 commit

  • Pull ARM SoC driver updates from Arnd Bergmann:
    "The main addition this time around is the new ARM "SCMI" framework,
    which is the latest in a series of standards coming from ARM to do
    power management in a platform independent way.

    This has been through many review cycles, and it relies on a rather
    interesting way of using the mailbox subsystem, but in the end I
    agreed that Sudeep's version was the best we could do after all.

    Other changes include:

    - the ARM CCN driver is moved out of drivers/bus into drivers/perf,
    which makes more sense. Similarly, the performance monitoring
    portion of the CCI driver are moved the same way and cleaned up a
    little more.

    - a series of updates to the SCPI framework

    - support for the Mediatek mt7623a SoC in drivers/soc

    - support for additional NVIDIA Tegra hardware in drivers/soc

    - a new reset driver for Socionext Uniphier

    - lesser bug fixes in drivers/soc, drivers/tee, drivers/memory, and
    drivers/firmware and drivers/reset across platforms"

    * tag 'armsoc-drivers' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc: (87 commits)
    reset: uniphier: add ethernet reset control support for PXs3
    reset: stm32mp1: Enable stm32mp1 reset driver
    dt-bindings: reset: add STM32MP1 resets
    reset: uniphier: add Pro4/Pro5/PXs2 audio systems reset control
    reset: imx7: add 'depends on HAS_IOMEM' to fix unmet dependency
    reset: modify the way reset lookup works for board files
    reset: add support for non-DT systems
    clk: scmi: use devm_of_clk_add_hw_provider() API and drop scmi_clocks_remove
    firmware: arm_scmi: prevent accessing rate_discrete uninitialized
    hwmon: (scmi) return -EINVAL when sensor information is unavailable
    amlogic: meson-gx-socinfo: Update soc ids
    soc/tegra: pmc: Use the new reset APIs to manage reset controllers
    soc: mediatek: update power domain data of MT2712
    dt-bindings: soc: update MT2712 power dt-bindings
    cpufreq: scmi: add thermal dependency
    soc: mediatek: fix the mistaken pointer accessed when subdomains are added
    soc: mediatek: add SCPSYS power domain driver for MediaTek MT7623A SoC
    soc: mediatek: avoid hardcoded value with bus_prot_mask
    dt-bindings: soc: add header files required for MT7623A SCPSYS dt-binding
    dt-bindings: soc: add SCPSYS binding for MT7623 and MT7623A SoC
    ...

    Linus Torvalds
     

07 Mar, 2018

1 commit

  • The arm-ccn driver is purely a perf driver for the CCN PMU, not a bus
    driver in the sense of the other residents of drivers/bus/, so let's
    move it to the appropriate place for SoC PMU drivers. Not to mention
    moving the documentation accordingly as well.

    Acked-by: Pawel Moll
    Acked-by: Will Deacon
    Signed-off-by: Robin Murphy
    Signed-off-by: Arnd Bergmann

    Robin Murphy