From 3a2c16d1d23a4a178089db73748e4f7c0c384887 Mon Sep 17 00:00:00 2001 From: Rui Salvaterra Date: Wed, 15 Sep 2021 10:31:37 +0100 Subject: kernel: bump 5.10 to 5.10.65 Manually refreshed: generic/pending-5.10/800-bcma-get-SoC-device-struct-copy-its-DMA-params-to-th.patch bcm27xx/patches-5.10/950-0053-firmware-bcm2835-Support-ARCH_BCM270x.patch bcm27xx/patches-5.10/950-0087-firmware-raspberrypi-Add-backward-compatible-get_thr.patch Signed-off-by: Rui Salvaterra --- ...053-firmware-bcm2835-Support-ARCH_BCM270x.patch | 38 +++++++++++++++------- 1 file changed, 26 insertions(+), 12 deletions(-) (limited to 'target/linux/bcm27xx/patches-5.10/950-0053-firmware-bcm2835-Support-ARCH_BCM270x.patch') diff --git a/target/linux/bcm27xx/patches-5.10/950-0053-firmware-bcm2835-Support-ARCH_BCM270x.patch b/target/linux/bcm27xx/patches-5.10/950-0053-firmware-bcm2835-Support-ARCH_BCM270x.patch index 08d1e2af2d..d5ffe71018 100644 --- a/target/linux/bcm27xx/patches-5.10/950-0053-firmware-bcm2835-Support-ARCH_BCM270x.patch +++ b/target/linux/bcm27xx/patches-5.10/950-0053-firmware-bcm2835-Support-ARCH_BCM270x.patch @@ -27,8 +27,8 @@ Signed-off-by: Noralf Trønnes --- a/drivers/firmware/raspberrypi.c +++ b/drivers/firmware/raspberrypi.c -@@ -29,6 +29,8 @@ struct rpi_firmware { - u32 enabled; +@@ -32,6 +32,8 @@ struct rpi_firmware { + struct kref consumers; }; +static struct platform_device *g_pdev; @@ -36,32 +36,46 @@ Signed-off-by: Noralf Trønnes static DEFINE_MUTEX(transaction_lock); static void response_callback(struct mbox_client *cl, void *msg) -@@ -249,6 +251,7 @@ static int rpi_firmware_probe(struct pla - init_completion(&fw->c); +@@ -272,6 +274,7 @@ static int rpi_firmware_probe(struct pla + kref_init(&fw->consumers); platform_set_drvdata(pdev, fw); + g_pdev = pdev; rpi_firmware_print_firmware_revision(fw); rpi_register_hwmon_driver(dev, fw); -@@ -276,6 +279,7 @@ static int rpi_firmware_remove(struct pl - platform_device_unregister(rpi_clk); - rpi_clk = NULL; - mbox_free_channel(fw->chan); -+ g_pdev = NULL; +@@ -301,6 +304,8 @@ static int rpi_firmware_remove(struct pl + + rpi_firmware_put(fw); ++ g_pdev = NULL; ++ return 0; } -@@ -288,7 +292,7 @@ static int rpi_firmware_remove(struct pl + +@@ -314,7 +319,7 @@ static int rpi_firmware_remove(struct pl */ struct rpi_firmware *rpi_firmware_get(struct device_node *firmware_node) { - struct platform_device *pdev = of_find_device_by_node(firmware_node); + struct platform_device *pdev = g_pdev; + struct rpi_firmware *fw; if (!pdev) - return NULL; -@@ -312,7 +316,18 @@ static struct platform_driver rpi_firmwa +@@ -327,12 +332,9 @@ struct rpi_firmware *rpi_firmware_get(st + if (!kref_get_unless_zero(&fw->consumers)) + goto err_put_device; + +- put_device(&pdev->dev); +- + return fw; + + err_put_device: +- put_device(&pdev->dev); + return NULL; + } + EXPORT_SYMBOL_GPL(rpi_firmware_get); +@@ -352,7 +354,18 @@ static struct platform_driver rpi_firmwa .shutdown = rpi_firmware_shutdown, .remove = rpi_firmware_remove, }; -- cgit v1.2.3