- Jan 27, 2020
-
-
Florian Fainelli authored
Since we do not have interrupts on BCM7216, we cannot have trip point crossing, the thermal subsystem expects us to provide a NULL set_trips operation in that case, so make it possible to provide per-process thermal_zone_of_device_ops Reviewed-by:
Amit Kucheria <amit.kucheria@linaro.org> Signed-off-by:
Florian Fainelli <f.fainelli@gmail.com> Signed-off-by:
Daniel Lezcano <daniel.lezcano@linaro.org> Link: https://lore.kernel.org/r/20200114190607.29339-7-f.fainelli@gmail.com
-
Florian Fainelli authored
If we are successful grabbing the interrupt resource, then register an interrupt handler, this makes it easier to support the interrupt as being optional, which is it for 7216. Reviewed-by:
Amit Kucheria <amit.kucheria@linaro.org> Signed-off-by:
Florian Fainelli <f.fainelli@gmail.com> Signed-off-by:
Daniel Lezcano <daniel.lezcano@linaro.org> Link: https://lore.kernel.org/r/20200114190607.29339-6-f.fainelli@gmail.com
-
Florian Fainelli authored
Match the 7216 compatible string in order to derive the correct 16nm process thermal parameters to obtain correct readings. Reviewed-by:
Amit Kucheria <amit.kucheria@linaro.org> Signed-off-by:
Florian Fainelli <f.fainelli@gmail.com> Signed-off-by:
Daniel Lezcano <daniel.lezcano@linaro.org> Link: https://lore.kernel.org/r/20200114190607.29339-5-f.fainelli@gmail.com
-
Florian Fainelli authored
The driver is currently assuming that it is operating with a 28nm process chip, which has a specific formula to convert temperature to a code and vice versa. Update the code to support providing two key values: offset and multiplier to derive the correct formulas. Signed-off-by:
Florian Fainelli <f.fainelli@gmail.com> Reviewed-by:
Amit Kucheria <amit.kucheria@linaro.org> Signed-off-by:
Daniel Lezcano <daniel.lezcano@linaro.org> Link: https://lore.kernel.org/r/20200114190607.29339-3-f.fainelli@gmail.com
-
Florian Fainelli authored
At the time the brcmstb_thermal driver and its binding were merged, the DT binding did not make the coefficients properties a mandatory one, therefore all users of the brcmstb_thermal driver out there have a non functional implementation with zero coefficients. Even if these properties were provided, the formula used for computation is incorrect. The coefficients are entirely process specific (right now, only 28nm is supported) and not board or SoC specific, it is therefore appropriate to hard code them in the driver given the compatibility string we are probed with which has to be updated whenever a new process is introduced. We remove the existing coefficients definition since subsequent patches are going to add support for a new process and will introduce new coefficients as well. Fixes: 9e03cf1b ("thermal: add brcmstb AVS TMON driver") Signed-off-by:
Florian Fainelli <f.fainelli@gmail.com> Reviewed-by:
Amit Kucheria <amit.kucheria@linaro.org> Signed-off-by:
Daniel Lezcano <daniel.lezcano@linaro.org> Link: https://lore.kernel.org/r/20200114190607.29339-2-f.fainelli@gmail.com
-
Stefan Wahren authored
This adds the thermal sensor driver for the Broadcom BCM2711 SoC, which is placed on the Raspberry Pi 4. The driver only provides SoC temperature reading so far. Signed-off-by:
Stefan Wahren <stefan.wahren@i2se.com> Reviewed-by:
Florian Fainelli <f.fainelli@gmail.com> Reviewed-by:
Nicolas Saenz Julienne <nsaenzjulienne@suse.de> Tested-by:
Nicolas Saenz Julienne <nsaenzjulienne@suse.de> Signed-off-by:
Daniel Lezcano <daniel.lezcano@linaro.org> Link: https://lore.kernel.org/r/1578941778-23321-3-git-send-email-stefan.wahren@i2se.com
-
- Jun 21, 2019
-
-
Greg Kroah-Hartman authored
When calling debugfs functions, there is no need to ever check the return value. The function can work or not, but the code logic should never do something different based on this. Cc: Zhang Rui <rui.zhang@intel.com> Cc: Eduardo Valentin <edubezval@gmail.com> Cc: Daniel Lezcano <daniel.lezcano@linaro.org> Cc: Florian Fainelli <f.fainelli@gmail.com> Cc: Ray Jui <rjui@broadcom.com> Cc: Scott Branden <sbranden@broadcom.com> Cc: bcm-kernel-feedback-list@broadcom.com Cc: linux-pm@vger.kernel.org Signed-off-by:
Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-
- Jun 19, 2019
-
-
Thomas Gleixner authored
Based on 2 normalized pattern(s): this program is free software you can redistribute it and or modify it under the terms of the gnu general public license version 2 as published by the free software foundation this program is free software you can redistribute it and or modify it under the terms of the gnu general public license version 2 as published by the free software foundation # extracted by the scancode license scanner the SPDX license identifier GPL-2.0-only has been chosen to replace the boilerplate/reference in 4122 file(s). Signed-off-by:
Thomas Gleixner <tglx@linutronix.de> Reviewed-by:
Enrico Weigelt <info@metux.net> Reviewed-by:
Kate Stewart <kstewart@linuxfoundation.org> Reviewed-by:
Allison Randal <allison@lohutok.net> Cc: linux-spdx@vger.kernel.org Link: https://lkml.kernel.org/r/20190604081206.933168790@linutronix.de Signed-off-by:
Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-
- Jun 05, 2019
-
-
Thomas Gleixner authored
Based on 1 normalized pattern(s): this software is licensed under the terms of the gnu general public license version 2 as published by the free software foundation and may be copied distributed and modified under those terms 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 285 file(s). Signed-off-by:
Thomas Gleixner <tglx@linutronix.de> Reviewed-by:
Alexios Zavras <alexios.zavras@intel.com> Reviewed-by:
Allison Randal <allison@lohutok.net> Cc: linux-spdx@vger.kernel.org Link: https://lkml.kernel.org/r/20190529141900.642774971@linutronix.de Signed-off-by:
Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-
- May 21, 2019
-
-
Thomas Gleixner authored
Add SPDX license identifiers to all Make/Kconfig files which: - Have no license information of any form These files fall under the project license, GPL v2 only. The resulting SPDX license identifier is: GPL-2.0-only Signed-off-by:
Thomas Gleixner <tglx@linutronix.de> Signed-off-by:
Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-
- May 14, 2019
-
-
Srinath Mannam authored
Unlike DT framework, thermal-zones and its parameters can't be parsed using ACPI framework. So that ACPI support is removed in this driver. Signed-off-by:
Srinath Mannam <srinath.mannam@broadcom.com> Reported-by:
David Woodhouse <dwmw2@infradead.org> Signed-off-by:
Eduardo Valentin <edubezval@gmail.com>
-
- Mar 18, 2019
-
-
Phil Elwell authored
"cat /sys/kernel/debug/bcm2835_thermal/regset" causes a NULL pointer dereference in bcm2835_thermal_debugfs. The driver makes use of the implementation details of the thermal framework to retrieve a pointer to its private data from a struct thermal_zone_device, and gets it wrong - leading to the crash. Instead, store its private data as the drvdata and retrieve the thermal_zone_device pointer from it. Fixes: bcb7dd9e ("thermal: bcm2835: add thermal driver for bcm2835 SoC") Signed-off-by:
Phil Elwell <phil@raspberrypi.org> Signed-off-by:
Zhang Rui <rui.zhang@intel.com>
-
- Feb 06, 2019
-
-
Pramod Kumar authored
Stingray SoC has six temperature sensor and those are configured, controlled and accessed to read temperature and update in DDR memory using m0 firmware. All six sensors has been given 4 bytes of memory in DDR to write temperature in millivolts. This thermal driver read temperature values from DDR because no direct access to sensors. Like this all temparature sensors are monitored and trips at critical temperature. If driver can't handle thermal runaways because of any unknown reason, then firmware in m0 Processor will handle. Reviewed-by:
Ray Jui <ray.jui@broadcom.com> Reviewed-by:
Scott Branden <scott.branden@broadcom.com> Reviewed-by:
Vikram Prakash <vikram.prakash@broadcom.com> Reviewed-by:
Rob Herring <robh@kernel.org> Signed-off-by:
Pramod Kumar <pramod.kumar@broadcom.com> Signed-off-by:
Srinath Mannam <srinath.mannam@broadcom.com> Signed-off-by:
Eduardo Valentin <edubezval@gmail.com>
-
- Jan 02, 2019
-
-
Julia Lawall authored
Using devm_thermal_zone_of_sensor_register allows to simplify some error handling code, drop a label, and drop the remove function. Signed-off-by:
Julia Lawall <Julia.Lawall@lip6.fr> Reviewed-by:
Daniel Lezcano <daniel.lezcano@linaro.org> Signed-off-by:
Eduardo Valentin <edubezval@gmail.com>
-
Matthias Brugger authored
By defaul of-based thermal driver do not enable hwmon. This patch does this explicitly, so that the temperature can be read through the common hwmon sysfs. Signed-off-by:
Matthias Brugger <mbrugger@suse.com> Acked-by:
Stefan Wahren <stefan.wahren@i2se.com> Signed-off-by:
Eduardo Valentin <edubezval@gmail.com>
-
- Dec 05, 2018
-
-
Julia Lawall authored
The thermal_zone_of_device_ops structure can be const as it is only passed as the last argument of thermal_zone_of_sensor_register and the corresponding parameter is declared as const. Done with the help of Coccinelle. Signed-off-by:
Julia Lawall <Julia.Lawall@lip6.fr> Reviewed-by:
Daniel Lezcano <daniel.lezcano@linaro.org> Signed-off-by:
Eduardo Valentin <edubezval@gmail.com>
-
Stefan Wahren authored
Adopt the SPDX license identifier headers to ease license compliance management. Cc: Martin Sperl <kernel@martin.sperl.org> Signed-off-by:
Stefan Wahren <stefan.wahren@i2se.com> Signed-off-by:
Eduardo Valentin <edubezval@gmail.com>
-
- Jun 05, 2018
-
-
Geert Uytterhoeven authored
Printk format "%pCr" will be removed soon, as clk_get_rate() must not be called in atomic context. Replace it by printing the variable that already holds the clock rate. Note that calling clk_get_rate() is safe here, as the code runs in task context. Link: http://lkml.kernel.org/r/1527845302-12159-3-git-send-email-geert+renesas@glider.be To: Jia-Ju Bai <baijiaju1990@gmail.com> To: Jonathan Corbet <corbet@lwn.net> To: Michael Turquette <mturquette@baylibre.com> To: Stephen Boyd <sboyd@kernel.org> To: Zhang Rui <rui.zhang@intel.com> To: Eduardo Valentin <edubezval@gmail.com> To: Eric Anholt <eric@anholt.net> To: Stefan Wahren <stefan.wahren@i2se.com> To: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Cc: Sergey Senozhatsky <sergey.senozhatsky.work@gmail.com> Cc: Petr Mladek <pmladek@suse.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Steven Rostedt <rostedt@goodmis.org> Cc: linux-doc@vger.kernel.org Cc: linux-clk@vger.kernel.org Cc: linux-pm@vger.kernel.org Cc: linux-serial@vger.kernel.org Cc: linux-arm-kernel@lists.infradead.org Cc: linux-renesas-soc@vger.kernel.org Cc: linux-kernel@vger.kernel.org Cc: stable@vger.kernel.org # 4.12+ Signed-off-by:
Geert Uytterhoeven <geert+renesas@glider.be> Acked-by:
Stefan Wahren <stefan.wahren@i2se.com> Signed-off-by:
Petr Mladek <pmladek@suse.com>
-
- Nov 01, 2017
-
-
Brian Norris authored
The AVS TMON core provides temperature readings, a pair of configurable high- and low-temperature threshold interrupts, and an emergency over-temperature chip reset. The driver utilizes the first two to provide temperature readings and high-temperature notifications to applications. The over-temperature reset is not exposed to applications; this reset threshold is critical to the system and should be set with care within the bootloader. Applications may choose to utilize the notification mechanism, the temperature reading mechanism (e.g., through polling), or both. Signed-off-by:
Brian Norris <computersforpeace@gmail.com> Signed-off-by:
Doug Berger <opendmb@gmail.com> Signed-off-by:
Markus Mayer <mmayer@broadcom.com> Signed-off-by:
Eduardo Valentin <edubezval@gmail.com>
-
- Aug 11, 2017
-
-
Julia Lawall authored
The thermal_zone_of_device_ops structure is only passed as the fourth argument to thermal_zone_of_sensor_register, which is declared as const. Thus the thermal_zone_of_device_ops structure itself can be const. Done with the help of Coccinelle. Signed-off-by:
Julia Lawall <Julia.Lawall@lip6.fr> Acked-by:
Stefan Wahren <stefan.wahren@i2se.com> Signed-off-by:
Zhang Rui <rui.zhang@intel.com>
-
- Jun 30, 2017
-
-
Dan Carpenter authored
This causes a static checker because we're passing a valid pointer to PTR_ERR(). "err" is already the correct error code, so we can just delete this line. Fixes: bcb7dd9e ("thermal: bcm2835: add thermal driver for bcm2835 SoC") Acked-by:
Stefan Wahren <stefan.wahren@i2se.com> Signed-off-by:
Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by:
Eduardo Valentin <edubezval@gmail.com>
-
- May 24, 2017
-
-
Jon Mason authored
Tweak the Kconfig description to mention support for NSP and make the default on for iProc based platforms. Signed-off-by:
Jon Mason <jon.mason@broadcom.com> Signed-off-by:
Eduardo Valentin <edubezval@gmail.com>
-
- Apr 23, 2017
-
-
Rafał Miłecki authored
We already have 2 Broadcom drivers and at least 1 more is coming. This made us create broadcom subdirectory where bcm2835 should be moves now. Acked-by:
Florian Fainelli <f.fainelli@gmail.com> Signed-off-by:
Rafał Miłecki <rafal@milecki.pl> Signed-off-by:
Eduardo Valentin <edubezval@gmail.com>
-
Rafał Miłecki authored
Just in case someone uses modinfo to find (blame) me. Signed-off-by:
Rafał Miłecki <rafal@milecki.pl> Signed-off-by:
Eduardo Valentin <edubezval@gmail.com>
-
- Apr 07, 2017
-
-
Rafał Miłecki authored
Northstar is a SoC family commonly used in home routers. This commit adds a driver for checking CPU temperature. As Northstar Plus seems to also have this IP block this new symbol gets ARCH_BCM_IPROC dependency. Signed-off-by:
Rafał Miłecki <rafal@milecki.pl> Signed-off-by:
Jon Mason <jon.mason@broadcom.com> Signed-off-by:
Eduardo Valentin <edubezval@gmail.com>
-