Home Home > GIT Browse
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKernel Build Daemon <kbuild@suse.de>2018-10-12 07:06:17 +0200
committerKernel Build Daemon <kbuild@suse.de>2018-10-12 07:06:17 +0200
commit50f2d4590efb830ac71463b53376b24d7773f3e8 (patch)
tree25f8093f3a91f940f70d00ea4fcfc8267f5ac20d
parent40bbe7889b389fc518553455600980883e92ada4 (diff)
parent912dad4fe5c609e3053b5f5d34ddb8a81995c182 (diff)
Merge branch 'SLE15' into SLE12-SP4
-rw-r--r--blacklist.conf3
-rw-r--r--config/arm64/default1
-rw-r--r--patches.drivers/ARM-bcm2835-Add-GET_THROTTLED-firmware-property.patch40
-rw-r--r--patches.drivers/crypto-ccp-add-timeout-support-in-the-sev-command.patch118
-rw-r--r--patches.drivers/firmware-raspberrypi-Register-hwmon-driver.patch71
-rw-r--r--patches.drivers/hwmon-Add-support-for-RPi-voltage-sensor.patch266
-rw-r--r--patches.drivers/hwmon-rpi-add-module-alias-to-raspberrypi-hwmon.patch37
-rw-r--r--patches.fixes/0001-drm-amdgpu-fix-error-handling-in-amdgpu_cs_user_fenc.patch70
-rw-r--r--series.conf6
-rw-r--r--supported.conf1
10 files changed, 613 insertions, 0 deletions
diff --git a/blacklist.conf b/blacklist.conf
index b28b2932bb..030eb78c11 100644
--- a/blacklist.conf
+++ b/blacklist.conf
@@ -518,3 +518,6 @@ ca26cffa4e4aaeb09bb9e308f95c7835cb149248 # might break bpf clang target
a81d1ab3cad77e20c2df8baef0a35a4980fc511c # nfc: revert: not applicable
1051e2c304b5cf17d4117505985f8128c5c64fd9 # devfreq: revert: need rest series
c2ef60fea2dc7f903450926aee1f9c282ea529ca # xhci: revert: no fixes backported
+
+c4ff91dd40e2253ab6dd028011469c2c694e1e19 # drm/amd/pp: initialize result to before or'ing in data
+9c60583c0b0fd6f3a5b61fda3eb604ce218b9d25 # breaks KABI
diff --git a/config/arm64/default b/config/arm64/default
index f4bb670783..cdeecbcefc 100644
--- a/config/arm64/default
+++ b/config/arm64/default
@@ -4041,6 +4041,7 @@ CONFIG_SENSORS_UCD9000=m
CONFIG_SENSORS_UCD9200=m
CONFIG_SENSORS_ZL6100=m
CONFIG_SENSORS_PWM_FAN=m
+CONFIG_SENSORS_RASPBERRYPI_HWMON=m
# CONFIG_SENSORS_SHT15 is not set
# CONFIG_SENSORS_SHT21 is not set
CONFIG_SENSORS_SHT3x=m
diff --git a/patches.drivers/ARM-bcm2835-Add-GET_THROTTLED-firmware-property.patch b/patches.drivers/ARM-bcm2835-Add-GET_THROTTLED-firmware-property.patch
new file mode 100644
index 0000000000..45e0337b22
--- /dev/null
+++ b/patches.drivers/ARM-bcm2835-Add-GET_THROTTLED-firmware-property.patch
@@ -0,0 +1,40 @@
+From: Stefan Wahren <stefan.wahren@i2se.com>
+Date: Fri, 25 May 2018 21:24:34 +0200
+Subject: ARM: bcm2835: Add GET_THROTTLED firmware property
+Git-commit: be3035e3627d2570de4c2c612ecd095968986437
+Patch-mainline: v4.19-rc1
+References: bsc#1108468
+
+Recent Raspberry Pi firmware provides a mailbox property to detect
+under-voltage conditions. Here is the current definition.
+
+The u32 value returned by the firmware is divided into 2 parts:
+ - lower 16-bits are the live value
+ - upper 16-bits are the history or sticky value
+
+ Bits:
+ 0: undervoltage
+ 1: arm frequency capped
+ 2: currently throttled
+ 16: undervoltage has occurred
+ 17: arm frequency capped has occurred
+ 18: throttling has occurred
+
+Signed-off-by: Stefan Wahren <stefan.wahren@i2se.com>
+Signed-off-by: Eric Anholt <eric@anholt.net>
+Reviewed-by: Eric Anholt <eric@anholt.net>
+Signed-off-by: Matthias Brugger <mbrugger@suse.com>
+---
+ include/soc/bcm2835/raspberrypi-firmware.h | 1 +
+ 1 file changed, 1 insertion(+)
+
+--- a/include/soc/bcm2835/raspberrypi-firmware.h
++++ b/include/soc/bcm2835/raspberrypi-firmware.h
+@@ -73,6 +73,7 @@ enum rpi_firmware_property_tag {
+ RPI_FIRMWARE_GET_DISPMANX_RESOURCE_MEM_HANDLE = 0x00030014,
+ RPI_FIRMWARE_GET_EDID_BLOCK = 0x00030020,
+ RPI_FIRMWARE_GET_DOMAIN_STATE = 0x00030030,
++ RPI_FIRMWARE_GET_THROTTLED = 0x00030046,
+ RPI_FIRMWARE_SET_CLOCK_STATE = 0x00038001,
+ RPI_FIRMWARE_SET_CLOCK_RATE = 0x00038002,
+ RPI_FIRMWARE_SET_VOLTAGE = 0x00038003,
diff --git a/patches.drivers/crypto-ccp-add-timeout-support-in-the-sev-command.patch b/patches.drivers/crypto-ccp-add-timeout-support-in-the-sev-command.patch
new file mode 100644
index 0000000000..95ec118d85
--- /dev/null
+++ b/patches.drivers/crypto-ccp-add-timeout-support-in-the-sev-command.patch
@@ -0,0 +1,118 @@
+From: Brijesh Singh <brijesh.singh@amd.com>
+Date: Wed, 15 Aug 2018 16:11:25 -0500
+Subject: crypto: ccp - add timeout support in the SEV command
+Git-commit: 3702a0585e64d70d5bf73bf3e943b8d6005b72c1
+Patch-mainline: v4.19-rc5
+References: bsc#1106838
+
+Currently, the CCP driver assumes that the SEV command issued to the PSP
+will always return (i.e. it will never hang). But recently, firmware bugs
+have shown that a command can hang. Since of the SEV commands are used
+in probe routines, this can cause boot hangs and/or loss of virtualization
+capabilities.
+
+To protect against firmware bugs, add a timeout in the SEV command
+execution flow. If a command does not complete within the specified
+timeout then return -ETIMEOUT and stop the driver from executing any
+further commands since the state of the SEV firmware is unknown.
+
+Cc: Tom Lendacky <thomas.lendacky@amd.com>
+Cc: Gary Hook <Gary.Hook@amd.com>
+Cc: Herbert Xu <herbert@gondor.apana.org.au>
+Cc: linux-kernel@vger.kernel.org
+Signed-off-by: Brijesh Singh <brijesh.singh@amd.com>
+Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
+Acked-by: Borislav Petkov <bp@suse.de>
+---
+ drivers/crypto/ccp/psp-dev.c | 46 ++++++++++++++++++++++++++++++++++++++-----
+ 1 file changed, 41 insertions(+), 5 deletions(-)
+
+--- a/drivers/crypto/ccp/psp-dev.c
++++ b/drivers/crypto/ccp/psp-dev.c
+@@ -32,6 +32,17 @@ static DEFINE_MUTEX(sev_cmd_mutex);
+ static struct sev_misc_dev *misc_dev;
+ static struct psp_device *psp_master;
+
++static int psp_cmd_timeout = 100;
++module_param(psp_cmd_timeout, int, 0644);
++MODULE_PARM_DESC(psp_cmd_timeout, " default timeout value, in seconds, for PSP commands");
++
++static int psp_probe_timeout = 5;
++module_param(psp_probe_timeout, int, 0644);
++MODULE_PARM_DESC(psp_probe_timeout, " default timeout value, in seconds, during PSP device probe");
++
++static bool psp_dead;
++static int psp_timeout;
++
+ static struct psp_device *psp_alloc_struct(struct sp_device *sp)
+ {
+ struct device *dev = sp->dev;
+@@ -76,10 +87,19 @@ done:
+ return IRQ_HANDLED;
+ }
+
+-static void sev_wait_cmd_ioc(struct psp_device *psp, unsigned int *reg)
++static int sev_wait_cmd_ioc(struct psp_device *psp,
++ unsigned int *reg, unsigned int timeout)
+ {
+- wait_event(psp->sev_int_queue, psp->sev_int_rcvd);
++ int ret;
++
++ ret = wait_event_timeout(psp->sev_int_queue,
++ psp->sev_int_rcvd, timeout * HZ);
++ if (!ret)
++ return -ETIMEDOUT;
++
+ *reg = ioread32(psp->io_regs + PSP_CMDRESP);
++
++ return 0;
+ }
+
+ static int sev_cmd_buffer_len(int cmd)
+@@ -125,12 +145,15 @@ static int __sev_do_cmd_locked(int cmd,
+ if (!psp)
+ return -ENODEV;
+
++ if (psp_dead)
++ return -EBUSY;
++
+ /* Get the physical address of the command buffer */
+ phys_lsb = data ? lower_32_bits(__psp_pa(data)) : 0;
+ phys_msb = data ? upper_32_bits(__psp_pa(data)) : 0;
+
+- dev_dbg(psp->dev, "sev command id %#x buffer 0x%08x%08x\n",
+- cmd, phys_msb, phys_lsb);
++ dev_dbg(psp->dev, "sev command id %#x buffer 0x%08x%08x timeout %us\n",
++ cmd, phys_msb, phys_lsb, psp_timeout);
+
+ print_hex_dump_debug("(in): ", DUMP_PREFIX_OFFSET, 16, 2, data,
+ sev_cmd_buffer_len(cmd), false);
+@@ -146,7 +169,18 @@ static int __sev_do_cmd_locked(int cmd,
+ iowrite32(reg, psp->io_regs + PSP_CMDRESP);
+
+ /* wait for command completion */
+- sev_wait_cmd_ioc(psp, &reg);
++ ret = sev_wait_cmd_ioc(psp, &reg, psp_timeout);
++ if (ret) {
++ if (psp_ret)
++ *psp_ret = 0;
++
++ dev_err(psp->dev, "sev command %#x timed out, disabling PSP \n", cmd);
++ psp_dead = true;
++
++ return ret;
++ }
++
++ psp_timeout = psp_cmd_timeout;
+
+ if (psp_ret)
+ *psp_ret = reg & PSP_CMDRESP_ERR_MASK;
+@@ -776,6 +810,8 @@ void psp_pci_init(void)
+
+ psp_master = sp->psp_data;
+
++ psp_timeout = psp_probe_timeout;
++
+ /* Initialize the platform */
+ rc = sev_platform_init(&error);
+ if (rc) {
diff --git a/patches.drivers/firmware-raspberrypi-Register-hwmon-driver.patch b/patches.drivers/firmware-raspberrypi-Register-hwmon-driver.patch
new file mode 100644
index 0000000000..e9ebb2a6a0
--- /dev/null
+++ b/patches.drivers/firmware-raspberrypi-Register-hwmon-driver.patch
@@ -0,0 +1,71 @@
+From: Stefan Wahren <stefan.wahren@i2se.com>
+Date: Fri, 25 May 2018 21:24:36 +0200
+Subject: firmware: raspberrypi: Register hwmon driver
+Git-commit: 70eea1bbb5561154e62b322904b685acb0e52d3e
+Patch-mainline: v4.19-rc1
+References: bsc#1108468
+
+Since the raspberrypi-hwmon driver is tied to the VC4 firmware instead of
+particular hardware its registration should be in the firmware driver.
+
+Signed-off-by: Stefan Wahren <stefan.wahren@i2se.com>
+Signed-off-by: Eric Anholt <eric@anholt.net>
+Signed-off-by: Matthias Brugger <mbrugger@suse.com>
+---
+ drivers/firmware/raspberrypi.c | 19 +++++++++++++++++++
+ 1 file changed, 19 insertions(+)
+
+diff --git a/drivers/firmware/raspberrypi.c b/drivers/firmware/raspberrypi.c
+index 6692888f04cf..0602626bf72d 100644
+--- a/drivers/firmware/raspberrypi.c
++++ b/drivers/firmware/raspberrypi.c
+@@ -21,6 +21,8 @@
+ #define MBOX_DATA28(msg) ((msg) & ~0xf)
+ #define MBOX_CHAN_PROPERTY 8
+
++static struct platform_device *rpi_hwmon;
++
+ struct rpi_firmware {
+ struct mbox_client cl;
+ struct mbox_chan *chan; /* The property channel. */
+@@ -183,6 +185,20 @@ rpi_firmware_print_firmware_revision(struct rpi_firmware *fw)
+ }
+ }
+
++static void
++rpi_register_hwmon_driver(struct device *dev, struct rpi_firmware *fw)
++{
++ u32 packet;
++ int ret = rpi_firmware_property(fw, RPI_FIRMWARE_GET_THROTTLED,
++ &packet, sizeof(packet));
++
++ if (ret)
++ return;
++
++ rpi_hwmon = platform_device_register_data(dev, "raspberrypi-hwmon",
++ -1, NULL, 0);
++}
++
+ static int rpi_firmware_probe(struct platform_device *pdev)
+ {
+ struct device *dev = &pdev->dev;
+@@ -209,6 +225,7 @@ static int rpi_firmware_probe(struct platform_device *pdev)
+ platform_set_drvdata(pdev, fw);
+
+ rpi_firmware_print_firmware_revision(fw);
++ rpi_register_hwmon_driver(dev, fw);
+
+ return 0;
+ }
+@@ -217,6 +234,8 @@ static int rpi_firmware_remove(struct platform_device *pdev)
+ {
+ struct rpi_firmware *fw = platform_get_drvdata(pdev);
+
++ platform_device_unregister(rpi_hwmon);
++ rpi_hwmon = NULL;
+ mbox_free_channel(fw->chan);
+
+ return 0;
+--
+2.19.0
+
diff --git a/patches.drivers/hwmon-Add-support-for-RPi-voltage-sensor.patch b/patches.drivers/hwmon-Add-support-for-RPi-voltage-sensor.patch
new file mode 100644
index 0000000000..7c3145dc66
--- /dev/null
+++ b/patches.drivers/hwmon-Add-support-for-RPi-voltage-sensor.patch
@@ -0,0 +1,266 @@
+From: Stefan Wahren <stefan.wahren@i2se.com>
+Date: Fri, 25 May 2018 21:24:35 +0200
+Subject: hwmon: Add support for RPi voltage sensor
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+Git-commit: 74d1e007915fab590f8be9dc647b19511260210c
+Patch-mainline: v4.19-rc1
+References: bsc#1108468
+
+Currently there is no easy way to detect undervoltage conditions on a
+remote Raspberry Pi. This hwmon driver retrieves the state of the
+undervoltage sensor via mailbox interface. The handling based on
+Noralf's modifications to the downstream firmware driver. In case of
+an undervoltage condition only an entry is written to the kernel log.
+
+CC: "Noralf Trønnes" <noralf@tronnes.org>
+Signed-off-by: Stefan Wahren <stefan.wahren@i2se.com>
+Signed-off-by: Eric Anholt <eric@anholt.net>
+Acked-by: Guenter Roeck <linux@roeck-us.net>
+Signed-off-by: Matthias Brugger <mbrugger@suse.com>
+---
+ Documentation/hwmon/raspberrypi-hwmon | 22 ++++
+ drivers/hwmon/Kconfig | 10 ++
+ drivers/hwmon/Makefile | 1 +
+ drivers/hwmon/raspberrypi-hwmon.c | 166 ++++++++++++++++++++++++++
+ 4 files changed, 199 insertions(+)
+ create mode 100644 Documentation/hwmon/raspberrypi-hwmon
+ create mode 100644 drivers/hwmon/raspberrypi-hwmon.c
+
+diff --git a/Documentation/hwmon/raspberrypi-hwmon b/Documentation/hwmon/raspberrypi-hwmon
+new file mode 100644
+index 000000000000..3c92e2cb52d6
+--- /dev/null
++++ b/Documentation/hwmon/raspberrypi-hwmon
+@@ -0,0 +1,22 @@
++Kernel driver raspberrypi-hwmon
++===============================
++
++Supported boards:
++ * Raspberry Pi A+ (via GPIO on SoC)
++ * Raspberry Pi B+ (via GPIO on SoC)
++ * Raspberry Pi 2 B (via GPIO on SoC)
++ * Raspberry Pi 3 B (via GPIO on port expander)
++ * Raspberry Pi 3 B+ (via PMIC)
++
++Author: Stefan Wahren <stefan.wahren@i2se.com>
++
++Description
++-----------
++
++This driver periodically polls a mailbox property of the VC4 firmware to detect
++undervoltage conditions.
++
++Sysfs entries
++-------------
++
++in0_lcrit_alarm Undervoltage alarm
+diff --git a/drivers/hwmon/Kconfig b/drivers/hwmon/Kconfig
+index f10840ad465c..195154178aff 100644
+--- a/drivers/hwmon/Kconfig
++++ b/drivers/hwmon/Kconfig
+@@ -1298,6 +1298,16 @@ config SENSORS_PWM_FAN
+ This driver can also be built as a module. If so, the module
+ will be called pwm-fan.
+
++config SENSORS_RASPBERRYPI_HWMON
++ tristate "Raspberry Pi voltage monitor"
++ depends on RASPBERRYPI_FIRMWARE || (COMPILE_TEST && !RASPBERRYPI_FIRMWARE)
++ help
++ If you say yes here you get support for voltage sensor on the
++ Raspberry Pi.
++
++ This driver can also be built as a module. If so, the module
++ will be called raspberrypi-hwmon.
++
+ config SENSORS_SHT15
+ tristate "Sensiron humidity and temperature sensors. SHT15 and compat."
+ depends on GPIOLIB || COMPILE_TEST
+diff --git a/drivers/hwmon/Makefile b/drivers/hwmon/Makefile
+index e7d52a36e6c4..a9297703fd6e 100644
+--- a/drivers/hwmon/Makefile
++++ b/drivers/hwmon/Makefile
+@@ -141,6 +141,7 @@ obj-$(CONFIG_SENSORS_PC87427) += pc87427.o
+ obj-$(CONFIG_SENSORS_PCF8591) += pcf8591.o
+ obj-$(CONFIG_SENSORS_POWR1220) += powr1220.o
+ obj-$(CONFIG_SENSORS_PWM_FAN) += pwm-fan.o
++obj-$(CONFIG_SENSORS_RASPBERRYPI_HWMON) += raspberrypi-hwmon.o
+ obj-$(CONFIG_SENSORS_S3C) += s3c-hwmon.o
+ obj-$(CONFIG_SENSORS_SCH56XX_COMMON)+= sch56xx-common.o
+ obj-$(CONFIG_SENSORS_SCH5627) += sch5627.o
+diff --git a/drivers/hwmon/raspberrypi-hwmon.c b/drivers/hwmon/raspberrypi-hwmon.c
+new file mode 100644
+index 000000000000..fb4e4a6bb1f6
+--- /dev/null
++++ b/drivers/hwmon/raspberrypi-hwmon.c
+@@ -0,0 +1,166 @@
++// SPDX-License-Identifier: GPL-2.0+
++/*
++ * Raspberry Pi voltage sensor driver
++ *
++ * Based on firmware/raspberrypi.c by Noralf Trønnes
++ *
++ * Copyright (C) 2018 Stefan Wahren <stefan.wahren@i2se.com>
++ */
++#include <linux/device.h>
++#include <linux/err.h>
++#include <linux/hwmon.h>
++#include <linux/module.h>
++#include <linux/platform_device.h>
++#include <linux/slab.h>
++#include <linux/workqueue.h>
++#include <soc/bcm2835/raspberrypi-firmware.h>
++
++#define UNDERVOLTAGE_STICKY_BIT BIT(16)
++
++struct rpi_hwmon_data {
++ struct device *hwmon_dev;
++ struct rpi_firmware *fw;
++ u32 last_throttled;
++ struct delayed_work get_values_poll_work;
++};
++
++static void rpi_firmware_get_throttled(struct rpi_hwmon_data *data)
++{
++ u32 new_uv, old_uv, value;
++ int ret;
++
++ /* Request firmware to clear sticky bits */
++ value = 0xffff;
++
++ ret = rpi_firmware_property(data->fw, RPI_FIRMWARE_GET_THROTTLED,
++ &value, sizeof(value));
++ if (ret) {
++ dev_err_once(data->hwmon_dev, "Failed to get throttled (%d)\n",
++ ret);
++ return;
++ }
++
++ new_uv = value & UNDERVOLTAGE_STICKY_BIT;
++ old_uv = data->last_throttled & UNDERVOLTAGE_STICKY_BIT;
++ data->last_throttled = value;
++
++ if (new_uv == old_uv)
++ return;
++
++ if (new_uv)
++ dev_crit(data->hwmon_dev, "Undervoltage detected!\n");
++ else
++ dev_info(data->hwmon_dev, "Voltage normalised\n");
++
++ sysfs_notify(&data->hwmon_dev->kobj, NULL, "in0_lcrit_alarm");
++}
++
++static void get_values_poll(struct work_struct *work)
++{
++ struct rpi_hwmon_data *data;
++
++ data = container_of(work, struct rpi_hwmon_data,
++ get_values_poll_work.work);
++
++ rpi_firmware_get_throttled(data);
++
++ /*
++ * We can't run faster than the sticky shift (100ms) since we get
++ * flipping in the sticky bits that are cleared.
++ */
++ schedule_delayed_work(&data->get_values_poll_work, 2 * HZ);
++}
++
++static int rpi_read(struct device *dev, enum hwmon_sensor_types type,
++ u32 attr, int channel, long *val)
++{
++ struct rpi_hwmon_data *data = dev_get_drvdata(dev);
++
++ *val = !!(data->last_throttled & UNDERVOLTAGE_STICKY_BIT);
++ return 0;
++}
++
++static umode_t rpi_is_visible(const void *_data, enum hwmon_sensor_types type,
++ u32 attr, int channel)
++{
++ return 0444;
++}
++
++static const u32 rpi_in_config[] = {
++ HWMON_I_LCRIT_ALARM,
++ 0
++};
++
++static const struct hwmon_channel_info rpi_in = {
++ .type = hwmon_in,
++ .config = rpi_in_config,
++};
++
++static const struct hwmon_channel_info *rpi_info[] = {
++ &rpi_in,
++ NULL
++};
++
++static const struct hwmon_ops rpi_hwmon_ops = {
++ .is_visible = rpi_is_visible,
++ .read = rpi_read,
++};
++
++static const struct hwmon_chip_info rpi_chip_info = {
++ .ops = &rpi_hwmon_ops,
++ .info = rpi_info,
++};
++
++static int rpi_hwmon_probe(struct platform_device *pdev)
++{
++ struct device *dev = &pdev->dev;
++ struct rpi_hwmon_data *data;
++ int ret;
++
++ data = devm_kzalloc(dev, sizeof(*data), GFP_KERNEL);
++ if (!data)
++ return -ENOMEM;
++
++ /* Parent driver assure that firmware is correct */
++ data->fw = dev_get_drvdata(dev->parent);
++
++ /* Init throttled */
++ ret = rpi_firmware_property(data->fw, RPI_FIRMWARE_GET_THROTTLED,
++ &data->last_throttled,
++ sizeof(data->last_throttled));
++
++ data->hwmon_dev = devm_hwmon_device_register_with_info(dev, "rpi_volt",
++ data,
++ &rpi_chip_info,
++ NULL);
++
++ INIT_DELAYED_WORK(&data->get_values_poll_work, get_values_poll);
++ platform_set_drvdata(pdev, data);
++
++ if (!PTR_ERR_OR_ZERO(data->hwmon_dev))
++ schedule_delayed_work(&data->get_values_poll_work, 2 * HZ);
++
++ return PTR_ERR_OR_ZERO(data->hwmon_dev);
++}
++
++static int rpi_hwmon_remove(struct platform_device *pdev)
++{
++ struct rpi_hwmon_data *data = platform_get_drvdata(pdev);
++
++ cancel_delayed_work_sync(&data->get_values_poll_work);
++
++ return 0;
++}
++
++static struct platform_driver rpi_hwmon_driver = {
++ .probe = rpi_hwmon_probe,
++ .remove = rpi_hwmon_remove,
++ .driver = {
++ .name = "raspberrypi-hwmon",
++ },
++};
++module_platform_driver(rpi_hwmon_driver);
++
++MODULE_AUTHOR("Stefan Wahren <stefan.wahren@i2se.com>");
++MODULE_DESCRIPTION("Raspberry Pi voltage sensor driver");
++MODULE_LICENSE("GPL v2");
+--
+2.19.0
+
diff --git a/patches.drivers/hwmon-rpi-add-module-alias-to-raspberrypi-hwmon.patch b/patches.drivers/hwmon-rpi-add-module-alias-to-raspberrypi-hwmon.patch
new file mode 100644
index 0000000000..244c8bbcba
--- /dev/null
+++ b/patches.drivers/hwmon-rpi-add-module-alias-to-raspberrypi-hwmon.patch
@@ -0,0 +1,37 @@
+From: Peter Robinson <pbrobinson@gmail.com>
+Date: Sat, 21 Jul 2018 00:02:12 +0100
+Subject: hwmon: rpi: add module alias to raspberrypi-hwmon
+Git-commit: d07f05fb86439c41dd6967c94be3ba3837b21567
+Patch-mainline: v4.19-rc3
+References: bsc#1108468
+
+The raspberrypi-hwmon driver doesn't automatically load, although it does work
+when loaded, by adding the alias it auto loads as expected when built as a
+module. Tested on RPi2/RPi3 on 32 bit kernel and RPi3B+ on aarch64 with
+Fedora 28 and a patched 4.18 RC kernel.
+
+Fixes: 3c493c885cf ("hwmon: Add support for RPi voltage sensor")
+Signed-off-by: Peter Robinson <pbrobinson@gmail.com>
+CC: Stefan Wahren <stefan.wahren@i2se.com>
+CC: Eric Anholt <eric@anholt.net>
+Acked-by: Guenter Roeck <linux@roeck-us.net>
+Tested-by: Stefan Wahren <stefan.wahren@i2se.com>
+Reviewed-by: Eric Anholt <eric@anholt.net>
+Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
+Signed-off-by: Matthias Brugger <mbrugger@suse.com>
+---
+ drivers/hwmon/raspberrypi-hwmon.c | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/drivers/hwmon/raspberrypi-hwmon.c b/drivers/hwmon/raspberrypi-hwmon.c
+index fb4e4a6bb1f6..be5ba4690895 100644
+--- a/drivers/hwmon/raspberrypi-hwmon.c
++++ b/drivers/hwmon/raspberrypi-hwmon.c
+@@ -164,3 +164,4 @@ module_platform_driver(rpi_hwmon_driver);
+ MODULE_AUTHOR("Stefan Wahren <stefan.wahren@i2se.com>");
+ MODULE_DESCRIPTION("Raspberry Pi voltage sensor driver");
+ MODULE_LICENSE("GPL v2");
++MODULE_ALIAS("platform:raspberrypi-hwmon");
+--
+2.19.0
+
diff --git a/patches.fixes/0001-drm-amdgpu-fix-error-handling-in-amdgpu_cs_user_fenc.patch b/patches.fixes/0001-drm-amdgpu-fix-error-handling-in-amdgpu_cs_user_fenc.patch
new file mode 100644
index 0000000000..b45e34f997
--- /dev/null
+++ b/patches.fixes/0001-drm-amdgpu-fix-error-handling-in-amdgpu_cs_user_fenc.patch
@@ -0,0 +1,70 @@
+From 0165de983272d1fae0809ed9db47c46a412279bc Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Christian=20K=C3=B6nig?= <christian.koenig@amd.com>
+Date: Mon, 10 Sep 2018 15:52:55 +0200
+Subject: drm/amdgpu: fix error handling in amdgpu_cs_user_fence_chunk
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+Git-commit: 0165de983272d1fae0809ed9db47c46a412279bc
+Patch-mainline: v4.19-rc2
+References: bsc#1106110
+
+Slowly leaking memory one page at a time :)
+
+Backporting notes:
+
+ * updated for context changes in amdgpu_cs_user_fence_chunk()
+
+Signed-off-by: Christian König <christian.koenig@amd.com>
+Reviewed-by: Andrey Grodzovsky <andrey.grodzovsky@amd.com>
+Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
+Acked-by: Thomas Zimmermann <tzimmermann@suse.de>
+---
+ drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c | 23 +++++++++++++++--------
+ 1 file changed, 15 insertions(+), 8 deletions(-)
+
+--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c
++++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c
+@@ -108,6 +108,7 @@ static int amdgpu_cs_user_fence_chunk(st
+ {
+ struct drm_gem_object *gobj;
+ unsigned long size;
++ int r;
+
+ gobj = drm_gem_object_lookup(p->filp, data->handle);
+ if (gobj == NULL)
+@@ -119,20 +120,26 @@ static int amdgpu_cs_user_fence_chunk(st
+ p->uf_entry.tv.shared = true;
+ p->uf_entry.user_pages = NULL;
+
+- size = amdgpu_bo_size(p->uf_entry.robj);
+- if (size != PAGE_SIZE || (data->offset + 8) > size)
+- return -EINVAL;
+-
+- *offset = data->offset;
+-
+ drm_gem_object_unreference_unlocked(gobj);
+
++ size = amdgpu_bo_size(p->uf_entry.robj);
++ if (size != PAGE_SIZE || (data->offset + 8) > size) {
++ r = -EINVAL;
++ goto error_unref;
++ }
++
+ if (amdgpu_ttm_tt_get_usermm(p->uf_entry.robj->tbo.ttm)) {
+- amdgpu_bo_unref(&p->uf_entry.robj);
+- return -EINVAL;
++ r = -EINVAL;
++ goto error_unref;
+ }
+
++ *offset = data->offset;
++
+ return 0;
++
++error_unref:
++ amdgpu_bo_unref(&p->uf_entry.robj);
++ return r;
+ }
+
+ int amdgpu_cs_parser_init(struct amdgpu_cs_parser *p, void *data)
diff --git a/series.conf b/series.conf
index 0827503b90..ffe4d616ac 100644
--- a/series.conf
+++ b/series.conf
@@ -17726,6 +17726,9 @@
patches.arch/ARM-hisi-handle-of_iomap-and-fix-missing-of_node_put.patch
patches.arch/ARM-imx-flag-failure-of-of_iomap.patch
patches.arch/ARM-exynos-Clear-global-variable-on-init-error-path.patch
+ patches.drivers/ARM-bcm2835-Add-GET_THROTTLED-firmware-property.patch
+ patches.drivers/hwmon-Add-support-for-RPi-voltage-sensor.patch
+ patches.drivers/firmware-raspberrypi-Register-hwmon-driver.patch
patches.drivers/soc-mediatek-pwrap-fix-cipher-init-setting-error.patch
patches.drivers/IB-hfi1-Invalid-NUMA-node-information-can-cause-a-di.patch
patches.drivers/fbdev-Distinguish-between-interlaced-and-progressive.patch
@@ -17852,6 +17855,7 @@
patches.drivers/i2c-uniphier-f-issue-STOP-only-for-last-message-or-I.patch
patches.drivers/i2c-i801-fix-DNV-s-SMBCTRL-register-offset.patch
patches.drivers/i2c-xiic-Make-the-start-and-the-byte-count-write-ato.patch
+ patches.drivers/hwmon-rpi-add-module-alias-to-raspberrypi-hwmon.patch
patches.arch/kvm-vmx-do-not-allow-reexecute_instruction-when-skipping-mmio-instr
patches.arch/kvm-x86-invert-emulation-re-execute-behavior-to-make-it-opt-in
patches.arch/kvm-x86-merge-emultype_retry-and-emultype_allow_reexecute
@@ -17888,6 +17892,7 @@
patches.drivers/pstore-Fix-incorrect-persistent-ram-buffer-mapping.patch
patches.drivers/drm-i915-gvt-Fix-the-incorrect-length-of-child_devic.patch
patches.drivers/drm-i915-overlay-Allocate-physical-registers-from-st.patch
+ patches.fixes/0001-drm-amdgpu-fix-error-handling-in-amdgpu_cs_user_fenc.patch
patches.drivers/mei-ignore-not-found-client-in-the-enumeration.patch
patches.drivers/USB-add-quirk-for-WORLDE-Controller-KS49-or-Prodipe-.patch
patches.drivers/xhci-Fix-use-after-free-for-URB-cancellation-on-a-re.patch
@@ -17912,6 +17917,7 @@
patches.drivers/bnxt_en-Fix-VF-mac-address-regression.patch
patches.drivers/qmi_wwan-set-DTR-for-modems-in-forced-USB2-mode.patch
patches.drivers/platform-x86-alienware-wmi-Correct-a-memory-leak.patch
+ patches.drivers/crypto-ccp-add-timeout-support-in-the-sev-command.patch
patches.drivers/hwmon-nct6775-Set-weight-source-to-zero-correctly.patch
patches.drivers/ALSA-bebob-use-address-returned-by-kmalloc-instead-o.patch
patches.drivers/ALSA-fireface-fix-memory-leak-in-ff400_switch_fetchi.patch
diff --git a/supported.conf b/supported.conf
index 21054293e7..0a7108c120 100644
--- a/supported.conf
+++ b/supported.conf
@@ -684,6 +684,7 @@
drivers/hwmon/jc42
drivers/hwmon/k10temp # Internal AMD CPU sensors
drivers/hwmon/nct6775
+ drivers/hwmon/raspberrypi-hwmon
drivers/hwmon/smsc47b397
drivers/hwmon/w83627ehf
- drivers/hwmon/*