-LINUX_VERSION-5.15 = .85
-LINUX_KERNEL_HASH-5.15.85 = 2c0bae29fac98e0a9408914a4551b2971365ac0000351cb255d6bd9aa0849808
+LINUX_VERSION-5.15 = .86
+LINUX_KERNEL_HASH-5.15.86 = 80fcd9efa443502de9e2750f6dfb59e8de43a5d87a6d2be09dca748d79b5f2ee
--- a/drivers/mtd/spi-nor/core.c
+++ b/drivers/mtd/spi-nor/core.c
-@@ -3095,6 +3095,7 @@ int spi_nor_scan(struct spi_nor *nor, co
+@@ -3096,6 +3096,7 @@ int spi_nor_scan(struct spi_nor *nor, co
struct device *dev = nor->dev;
struct mtd_info *mtd = &nor->mtd;
struct device_node *np = spi_nor_get_flash_node(nor);
int ret;
int i;
-@@ -3149,7 +3150,12 @@ int spi_nor_scan(struct spi_nor *nor, co
+@@ -3150,7 +3151,12 @@ int spi_nor_scan(struct spi_nor *nor, co
if (ret)
return ret;
mtd->type = MTD_NORFLASH;
--- a/drivers/mtd/mtdcore.c
+++ b/drivers/mtd/mtdcore.c
-@@ -845,6 +845,17 @@ out_error:
+@@ -847,6 +847,17 @@ out_error:
*/
static void mtd_set_dev_defaults(struct mtd_info *mtd)
{
--- a/drivers/mfd/Kconfig
+++ b/drivers/mfd/Kconfig
-@@ -2174,6 +2174,14 @@ config RAVE_SP_CORE
+@@ -2175,6 +2175,14 @@ config RAVE_SP_CORE
Select this to get support for the Supervisory Processor
device found on several devices in RAVE line of hardware.
--- a/drivers/spi/spidev.c
+++ b/drivers/spi/spidev.c
-@@ -402,7 +402,6 @@ spidev_ioctl(struct file *filp, unsigned
+@@ -413,7 +413,6 @@ spidev_ioctl(struct file *filp, unsigned
else
retval = get_user(tmp, (u32 __user *)arg);
if (retval == 0) {
u32 save = spi->mode;
if (tmp & ~SPI_MODE_MASK) {
-@@ -410,10 +409,6 @@ spidev_ioctl(struct file *filp, unsigned
+@@ -421,10 +420,6 @@ spidev_ioctl(struct file *filp, unsigned
break;
}
--- a/drivers/spi/spidev.c
+++ b/drivers/spi/spidev.c
-@@ -747,7 +747,7 @@ static int spidev_probe(struct spi_devic
+@@ -758,7 +758,7 @@ static int spidev_probe(struct spi_devic
* compatible string, it is a Linux implementation thing
* rather than a description of the hardware.
*/
--- a/drivers/tty/serial/amba-pl011.c
+++ b/drivers/tty/serial/amba-pl011.c
-@@ -2744,7 +2744,12 @@ static int pl011_setup_port(struct devic
+@@ -2756,7 +2756,12 @@ static int pl011_setup_port(struct devic
if (IS_ERR(base))
return PTR_ERR(base);
--- a/drivers/tty/serial/amba-pl011.c
+++ b/drivers/tty/serial/amba-pl011.c
-@@ -1727,6 +1727,23 @@ static void pl011_put_poll_char(struct u
+@@ -1730,6 +1730,23 @@ static void pl011_put_poll_char(struct u
#endif /* CONFIG_CONSOLE_POLL */
static int pl011_hwinit(struct uart_port *port)
{
struct uart_amba_port *uap =
-@@ -1743,7 +1760,7 @@ static int pl011_hwinit(struct uart_port
+@@ -1746,7 +1763,7 @@ static int pl011_hwinit(struct uart_port
if (retval)
return retval;
/* Clear pending error and receive interrupts */
pl011_write(UART011_OEIS | UART011_BEIS | UART011_PEIS |
-@@ -2440,7 +2457,7 @@ static int pl011_console_setup(struct co
+@@ -2452,7 +2469,7 @@ static int pl011_console_setup(struct co
plat->init();
}
if (uap->vendor->fixed_options) {
baud = uap->fixed_baud;
-@@ -2657,6 +2674,7 @@ static struct uart_driver amba_reg = {
+@@ -2669,6 +2686,7 @@ static struct uart_driver amba_reg = {
.cons = AMBA_CONSOLE,
};
static int pl011_probe_dt_alias(int index, struct device *dev)
{
struct device_node *np;
-@@ -2688,6 +2706,7 @@ static int pl011_probe_dt_alias(int inde
+@@ -2700,6 +2718,7 @@ static int pl011_probe_dt_alias(int inde
return ret;
}
--- a/drivers/tty/serial/amba-pl011.c
+++ b/drivers/tty/serial/amba-pl011.c
-@@ -1432,6 +1432,7 @@ static bool pl011_tx_char(struct uart_am
+@@ -1435,6 +1435,7 @@ static bool pl011_tx_char(struct uart_am
return false; /* unable to transmit character */
pl011_write(c, uap, REG_DR);
- reg
--- a/drivers/tty/serial/amba-pl011.c
+++ b/drivers/tty/serial/amba-pl011.c
-@@ -2835,6 +2835,11 @@ static int pl011_probe(struct amba_devic
+@@ -2847,6 +2847,11 @@ static int pl011_probe(struct amba_devic
if (IS_ERR(uap->clk))
return PTR_ERR(uap->clk);
--- a/drivers/tty/serial/amba-pl011.c
+++ b/drivers/tty/serial/amba-pl011.c
-@@ -1493,6 +1493,10 @@ static bool pl011_tx_chars(struct uart_a
+@@ -1496,6 +1496,10 @@ static bool pl011_tx_chars(struct uart_a
if (likely(from_irq) && count-- == 0)
break;
static DEFINE_MUTEX(transaction_lock);
static void response_callback(struct mbox_client *cl, void *msg)
-@@ -279,6 +281,7 @@ static int rpi_firmware_probe(struct pla
+@@ -280,6 +282,7 @@ static int rpi_firmware_probe(struct pla
kref_init(&fw->consumers);
platform_set_drvdata(pdev, fw);
rpi_firmware_print_firmware_revision(fw);
rpi_register_hwmon_driver(dev, fw);
-@@ -307,6 +310,7 @@ static int rpi_firmware_remove(struct pl
+@@ -308,6 +311,7 @@ static int rpi_firmware_remove(struct pl
rpi_clk = NULL;
rpi_firmware_put(fw);
return 0;
}
-@@ -381,7 +385,18 @@ static struct platform_driver rpi_firmwa
+@@ -382,7 +386,18 @@ static struct platform_driver rpi_firmwa
.shutdown = rpi_firmware_shutdown,
.remove = rpi_firmware_remove,
};
--- a/drivers/input/joystick/Kconfig
+++ b/drivers/input/joystick/Kconfig
-@@ -399,4 +399,12 @@ config JOYSTICK_N64
+@@ -400,4 +400,12 @@ config JOYSTICK_N64
Say Y here if you want enable support for the four
built-in controller ports on the Nintendo 64 console.
static void
rpi_firmware_print_firmware_revision(struct rpi_firmware *fw)
{
-@@ -386,15 +407,32 @@ static struct platform_driver rpi_firmwa
+@@ -387,15 +408,32 @@ static struct platform_driver rpi_firmwa
.remove = rpi_firmware_remove,
};
}
static void
-@@ -338,6 +375,7 @@ static int rpi_firmware_probe(struct pla
+@@ -339,6 +376,7 @@ static int rpi_firmware_probe(struct pla
g_pdev = pdev;
rpi_firmware_print_firmware_revision(fw);
MODULE_DESCRIPTION("BCM2835 clock driver");
--- a/drivers/firmware/raspberrypi.c
+++ b/drivers/firmware/raspberrypi.c
-@@ -498,7 +498,7 @@ out2:
+@@ -499,7 +499,7 @@ out2:
out1:
return ret;
}
+++ /dev/null
-From cf7d5f766e0a9eeb09271c36f546ac0a1fdc0444 Mon Sep 17 00:00:00 2001
-From: Dave Stevenson <dave.stevenson@raspberrypi.com>
-Date: Fri, 24 Jan 2020 14:22:06 +0000
-Subject: [PATCH] drm/fourcc: Add packed 10bit YUV 4:2:0 format
-
-Adds a format that is 3 10bit YUV 4:2:0 samples packed into
-a 32bit work (with 2 spare bits).
-
-Supported on Broadcom BCM2711 chips.
-
-Signed-off-by: Dave Stevenson <dave.stevenson@raspberrypi.com>
----
- drivers/gpu/drm/drm_fourcc.c | 3 +++
- include/uapi/drm/drm_fourcc.h | 11 +++++++++++
- 2 files changed, 14 insertions(+)
-
---- a/drivers/gpu/drm/drm_fourcc.c
-+++ b/drivers/gpu/drm/drm_fourcc.c
-@@ -266,6 +266,9 @@ const struct drm_format_info *__drm_form
- .num_planes = 3, .char_per_block = { 2, 2, 2 },
- .block_w = { 1, 1, 1 }, .block_h = { 1, 1, 1 }, .hsub = 0,
- .vsub = 0, .is_yuv = true },
-+ { .format = DRM_FORMAT_P030, .depth = 0, .num_planes = 2,
-+ .char_per_block = { 4, 4, 0 }, .block_w = { 3, 0, 0 }, .block_h = { 1, 0, 0 },
-+ .hsub = 2, .vsub = 2, .is_yuv = true},
- };
-
- unsigned int i;
---- a/include/uapi/drm/drm_fourcc.h
-+++ b/include/uapi/drm/drm_fourcc.h
-@@ -325,6 +325,13 @@ extern "C" {
- #define DRM_FORMAT_Q401 fourcc_code('Q', '4', '0', '1')
-
- /*
-+ * 2 plane YCbCr MSB aligned, 3 pixels packed into 4 bytes.
-+ * index 0 = Y plane, [31:0] x:Y2:Y1:Y0 2:10:10:10 little endian
-+ * index 1 = Cr:Cb plane, [63:0] x:Cr2:Cb2:Cr1:x:Cb1:Cr0:Cb0 [2:10:10:10:2:10:10:10] little endian
-+ */
-+#define DRM_FORMAT_P030 fourcc_code('P', '0', '3', '0') /* 2x2 subsampled Cr:Cb plane 10 bits per channel packed */
-+
-+/*
- * 3 plane YCbCr
- * index 0: Y plane, [7:0] Y
- * index 1: Cb plane, [7:0] Cb
-@@ -842,6 +849,10 @@ drm_fourcc_canonicalize_nvidia_format_mo
- * and UV. Some SAND-using hardware stores UV in a separate tiled
- * image from Y to reduce the column height, which is not supported
- * with these modifiers.
-+ *
-+ * The DRM_FORMAT_MOD_BROADCOM_SAND128_COL_HEIGHT modifier is also
-+ * supported for DRM_FORMAT_P030 where the columns remain as 128 bytes
-+ * wide, but as this is a 10 bpp format that translates to 96 pixels.
- */
-
- #define DRM_FORMAT_MOD_BROADCOM_SAND32_COL_HEIGHT(v) \
/* Device and char device-related information */
static DEFINE_IDA(gpio_ida);
static dev_t gpio_devt;
-@@ -2392,8 +2394,8 @@ int gpiod_direction_output(struct gpio_d
+@@ -2395,8 +2397,8 @@ int gpiod_direction_output(struct gpio_d
value = !!value;
/* GPIOs used for enabled IRQs shall not be set as output */
gpiod_err(desc,
"%s: tried to set a GPIO tied to an IRQ as output\n",
__func__);
-@@ -3211,8 +3213,8 @@ int gpiochip_lock_as_irq(struct gpio_chi
+@@ -3213,8 +3215,8 @@ int gpiochip_lock_as_irq(struct gpio_chi
}
/* To be valid for IRQ the line needs to be input or open drain */
--- a/drivers/spi/spidev.c
+++ b/drivers/spi/spidev.c
-@@ -669,6 +669,7 @@ static const struct file_operations spid
+@@ -680,6 +680,7 @@ static const struct file_operations spid
static struct class *spidev_class;
static const struct spi_device_id spidev_spi_ids[] = {
xhci_err(xhci, "Tried to move enqueue past ring segment\n");
return;
}
-@@ -3153,7 +3156,7 @@ irqreturn_t xhci_irq(struct usb_hcd *hcd
+@@ -3159,7 +3162,7 @@ irqreturn_t xhci_irq(struct usb_hcd *hcd
* that clears the EHB.
*/
while (xhci_handle_event(xhci) > 0) {
continue;
xhci_update_erst_dequeue(xhci, event_ring_deq);
event_ring_deq = xhci->event_ring->dequeue;
-@@ -3295,7 +3298,8 @@ static int prepare_ring(struct xhci_hcd
+@@ -3301,7 +3304,8 @@ static int prepare_ring(struct xhci_hcd
}
}
st7701->dsi = dsi;
- st7701->desc = desc;
- return mipi_dsi_attach(dsi);
- }
-@@ -397,21 +639,115 @@ static int st7701_dsi_remove(struct mipi
+ ret = mipi_dsi_attach(dsi);
+ if (ret)
+@@ -405,21 +647,115 @@ static int st7701_dsi_remove(struct mipi
return 0;
}
}
static int spi_gpio_setup(struct spi_device *spi)
-@@ -289,6 +297,7 @@ static int spi_gpio_request(struct devic
+@@ -299,6 +307,7 @@ static int spi_gpio_request(struct devic
if (IS_ERR(spi_gpio->miso))
return PTR_ERR(spi_gpio->miso);
if (pdev->vendor == PCI_VENDOR_ID_ASMEDIA &&
--- a/drivers/usb/host/xhci-ring.c
+++ b/drivers/usb/host/xhci-ring.c
-@@ -3608,14 +3608,15 @@ int xhci_queue_bulk_tx(struct xhci_hcd *
+@@ -3614,14 +3614,15 @@ int xhci_queue_bulk_tx(struct xhci_hcd *
unsigned int num_trbs;
unsigned int start_cycle, num_sgs = 0;
unsigned int enqd_len, block_len, trb_buff_len, full_len;
full_len = urb->transfer_buffer_length;
/* If we have scatter/gather list, we use it. */
if (urb->num_sgs && !(urb->transfer_flags & URB_DMA_MAP_SINGLE)) {
-@@ -3652,6 +3653,17 @@ int xhci_queue_bulk_tx(struct xhci_hcd *
+@@ -3658,6 +3659,17 @@ int xhci_queue_bulk_tx(struct xhci_hcd *
start_cycle = ring->cycle_state;
send_addr = addr;
/* Queue the TRBs, even if they are zero-length */
for (enqd_len = 0; first_trb || enqd_len < full_len;
enqd_len += trb_buff_len) {
-@@ -3664,6 +3676,11 @@ int xhci_queue_bulk_tx(struct xhci_hcd *
+@@ -3670,6 +3682,11 @@ int xhci_queue_bulk_tx(struct xhci_hcd *
if (enqd_len + trb_buff_len > full_len)
trb_buff_len = full_len - enqd_len;
--- a/drivers/usb/host/xhci-ring.c
+++ b/drivers/usb/host/xhci-ring.c
-@@ -3608,7 +3608,7 @@ int xhci_queue_bulk_tx(struct xhci_hcd *
+@@ -3614,7 +3614,7 @@ int xhci_queue_bulk_tx(struct xhci_hcd *
unsigned int num_trbs;
unsigned int start_cycle, num_sgs = 0;
unsigned int enqd_len, block_len, trb_buff_len, full_len;
u32 field, length_field, remainder, maxpacket;
u64 addr, send_addr;
-@@ -3654,14 +3654,9 @@ int xhci_queue_bulk_tx(struct xhci_hcd *
+@@ -3660,14 +3660,9 @@ int xhci_queue_bulk_tx(struct xhci_hcd *
send_addr = addr;
if (xhci->quirks & XHCI_VLI_SS_BULK_OUT_BUG &&
}
/* Queue the TRBs, even if they are zero-length */
-@@ -3676,7 +3671,7 @@ int xhci_queue_bulk_tx(struct xhci_hcd *
+@@ -3682,7 +3677,7 @@ int xhci_queue_bulk_tx(struct xhci_hcd *
if (enqd_len + trb_buff_len > full_len)
trb_buff_len = full_len - enqd_len;
--- a/drivers/hwmon/Kconfig
+++ b/drivers/hwmon/Kconfig
-@@ -1684,6 +1684,19 @@ config SENSORS_EMC2103
+@@ -1685,6 +1685,19 @@ config SENSORS_EMC2103
This driver can also be built as a module. If so, the module
will be called emc2103.
}
--- a/drivers/gpio/gpiolib.c
+++ b/drivers/gpio/gpiolib.c
-@@ -1799,7 +1799,8 @@ int gpiochip_add_pingroup_range(struct g
+@@ -1802,7 +1802,8 @@ int gpiochip_add_pingroup_range(struct g
list_add_tail(&pin_range->node, &gdev->pin_ranges);
}
EXPORT_SYMBOL_GPL(gpiochip_add_pingroup_range);
-@@ -1856,7 +1857,7 @@ int gpiochip_add_pin_range(struct gpio_c
+@@ -1859,7 +1860,7 @@ int gpiochip_add_pin_range(struct gpio_c
list_add_tail(&pin_range->node, &gdev->pin_ranges);
}
static struct clk clk_pcie = {
-@@ -548,6 +562,21 @@ static struct clk_lookup bcm6368_clks[]
+@@ -550,6 +564,21 @@ static struct clk_lookup bcm6368_clks[]
CLKDEV_INIT(NULL, "ipsec", &clk_ipsec),
};
#define HSSPI_PLL_HZ_6328 133333333
#define HSSPI_PLL_HZ_6362 400000000
-@@ -580,6 +609,10 @@ static int __init bcm63xx_clk_init(void)
+@@ -582,6 +611,10 @@ static int __init bcm63xx_clk_init(void)
case BCM6368_CPU_ID:
clkdev_add_table(bcm6368_clks, ARRAY_SIZE(bcm6368_clks));
break;
mask = CKCTL_6328_HSSPI_EN;
else if (BCMCPU_IS_6362())
mask = CKCTL_6362_HSSPI_EN;
-@@ -456,6 +458,19 @@ static struct clk_lookup bcm3368_clks[]
+@@ -458,6 +460,19 @@ static struct clk_lookup bcm3368_clks[]
CLKDEV_INIT("bcm63xx_enet.1", "enet", &clk_enet1),
};
static struct clk_lookup bcm6328_clks[] = {
/* fixed rate clocks */
CLKDEV_INIT(NULL, "periph", &clk_periph),
-@@ -577,6 +592,7 @@ static struct clk_lookup bcm63268_clks[]
+@@ -579,6 +594,7 @@ static struct clk_lookup bcm63268_clks[]
CLKDEV_INIT(NULL, "pcie", &clk_pcie),
};
#define HSSPI_PLL_HZ_6328 133333333
#define HSSPI_PLL_HZ_6362 400000000
-@@ -586,6 +602,10 @@ static int __init bcm63xx_clk_init(void)
+@@ -588,6 +604,10 @@ static int __init bcm63xx_clk_init(void)
case BCM3368_CPU_ID:
clkdev_add_table(bcm3368_clks, ARRAY_SIZE(bcm3368_clks));
break;
--- a/arch/mips/bcm63xx/clk.c
+++ b/arch/mips/bcm63xx/clk.c
-@@ -501,6 +501,8 @@ static struct clk_lookup bcm3368_clks[]
+@@ -503,6 +503,8 @@ static struct clk_lookup bcm3368_clks[]
CLKDEV_INIT(NULL, "periph", &clk_periph),
CLKDEV_INIT("bcm63xx_uart.0", "refclk", &clk_periph),
CLKDEV_INIT("bcm63xx_uart.1", "refclk", &clk_periph),
/* gated clocks */
CLKDEV_INIT(NULL, "enet0", &clk_enet0),
CLKDEV_INIT(NULL, "enet1", &clk_enet1),
-@@ -517,7 +519,9 @@ static struct clk_lookup bcm6318_clks[]
+@@ -519,7 +521,9 @@ static struct clk_lookup bcm6318_clks[]
/* fixed rate clocks */
CLKDEV_INIT(NULL, "periph", &clk_periph),
CLKDEV_INIT("bcm63xx_uart.0", "refclk", &clk_periph),
/* gated clocks */
CLKDEV_INIT(NULL, "enetsw", &clk_enetsw),
CLKDEV_INIT(NULL, "usbh", &clk_usbh),
-@@ -531,7 +535,10 @@ static struct clk_lookup bcm6328_clks[]
+@@ -533,7 +537,10 @@ static struct clk_lookup bcm6328_clks[]
CLKDEV_INIT(NULL, "periph", &clk_periph),
CLKDEV_INIT("bcm63xx_uart.0", "refclk", &clk_periph),
CLKDEV_INIT("bcm63xx_uart.1", "refclk", &clk_periph),
/* gated clocks */
CLKDEV_INIT(NULL, "enetsw", &clk_enetsw),
CLKDEV_INIT(NULL, "usbh", &clk_usbh),
-@@ -544,6 +551,7 @@ static struct clk_lookup bcm6338_clks[]
+@@ -546,6 +553,7 @@ static struct clk_lookup bcm6338_clks[]
/* fixed rate clocks */
CLKDEV_INIT(NULL, "periph", &clk_periph),
CLKDEV_INIT("bcm63xx_uart.0", "refclk", &clk_periph),
/* gated clocks */
CLKDEV_INIT(NULL, "enet0", &clk_enet0),
CLKDEV_INIT(NULL, "enet1", &clk_enet1),
-@@ -558,6 +566,7 @@ static struct clk_lookup bcm6345_clks[]
+@@ -560,6 +568,7 @@ static struct clk_lookup bcm6345_clks[]
/* fixed rate clocks */
CLKDEV_INIT(NULL, "periph", &clk_periph),
CLKDEV_INIT("bcm63xx_uart.0", "refclk", &clk_periph),
/* gated clocks */
CLKDEV_INIT(NULL, "enet0", &clk_enet0),
CLKDEV_INIT(NULL, "enet1", &clk_enet1),
-@@ -572,6 +581,7 @@ static struct clk_lookup bcm6348_clks[]
+@@ -574,6 +583,7 @@ static struct clk_lookup bcm6348_clks[]
/* fixed rate clocks */
CLKDEV_INIT(NULL, "periph", &clk_periph),
CLKDEV_INIT("bcm63xx_uart.0", "refclk", &clk_periph),
/* gated clocks */
CLKDEV_INIT(NULL, "enet0", &clk_enet0),
CLKDEV_INIT(NULL, "enet1", &clk_enet1),
-@@ -588,6 +598,8 @@ static struct clk_lookup bcm6358_clks[]
+@@ -590,6 +600,8 @@ static struct clk_lookup bcm6358_clks[]
CLKDEV_INIT(NULL, "periph", &clk_periph),
CLKDEV_INIT("bcm63xx_uart.0", "refclk", &clk_periph),
CLKDEV_INIT("bcm63xx_uart.1", "refclk", &clk_periph),
/* gated clocks */
CLKDEV_INIT(NULL, "enet0", &clk_enet0),
CLKDEV_INIT(NULL, "enet1", &clk_enet1),
-@@ -607,7 +619,10 @@ static struct clk_lookup bcm6362_clks[]
+@@ -609,7 +621,10 @@ static struct clk_lookup bcm6362_clks[]
CLKDEV_INIT(NULL, "periph", &clk_periph),
CLKDEV_INIT("bcm63xx_uart.0", "refclk", &clk_periph),
CLKDEV_INIT("bcm63xx_uart.1", "refclk", &clk_periph),
/* gated clocks */
CLKDEV_INIT(NULL, "enetsw", &clk_enetsw),
CLKDEV_INIT(NULL, "usbh", &clk_usbh),
-@@ -623,6 +638,8 @@ static struct clk_lookup bcm6368_clks[]
+@@ -625,6 +640,8 @@ static struct clk_lookup bcm6368_clks[]
CLKDEV_INIT(NULL, "periph", &clk_periph),
CLKDEV_INIT("bcm63xx_uart.0", "refclk", &clk_periph),
CLKDEV_INIT("bcm63xx_uart.1", "refclk", &clk_periph),
/* gated clocks */
CLKDEV_INIT(NULL, "enetsw", &clk_enetsw),
CLKDEV_INIT(NULL, "usbh", &clk_usbh),
-@@ -637,7 +654,10 @@ static struct clk_lookup bcm63268_clks[]
+@@ -639,7 +656,10 @@ static struct clk_lookup bcm63268_clks[]
CLKDEV_INIT(NULL, "periph", &clk_periph),
CLKDEV_INIT("bcm63xx_uart.0", "refclk", &clk_periph),
CLKDEV_INIT("bcm63xx_uart.1", "refclk", &clk_periph),
* Internal peripheral clock
*/
static struct clk clk_periph = {
-@@ -624,6 +641,7 @@ static struct clk_lookup bcm6362_clks[]
+@@ -626,6 +643,7 @@ static struct clk_lookup bcm6362_clks[]
CLKDEV_INIT("bcm63xx-hsspi.0", "pll", &clk_hsspi_pll),
CLKDEV_INIT("10001000.spi", "pll", &clk_hsspi_pll),
/* gated clocks */
CLKDEV_INIT(NULL, "enetsw", &clk_enetsw),
CLKDEV_INIT(NULL, "usbh", &clk_usbh),
CLKDEV_INIT(NULL, "usbd", &clk_usbd),
-@@ -641,6 +659,7 @@ static struct clk_lookup bcm6368_clks[]
+@@ -643,6 +661,7 @@ static struct clk_lookup bcm6368_clks[]
CLKDEV_INIT("10000100.serial", "refclk", &clk_periph),
CLKDEV_INIT("10000120.serial", "refclk", &clk_periph),
/* gated clocks */
CLKDEV_INIT(NULL, "enetsw", &clk_enetsw),
CLKDEV_INIT(NULL, "usbh", &clk_usbh),
CLKDEV_INIT(NULL, "usbd", &clk_usbd),
-@@ -659,6 +678,7 @@ static struct clk_lookup bcm63268_clks[]
+@@ -661,6 +680,7 @@ static struct clk_lookup bcm63268_clks[]
CLKDEV_INIT("bcm63xx-hsspi.0", "pll", &clk_hsspi_pll),
CLKDEV_INIT("10001000.spi", "pll", &clk_hsspi_pll),
/* gated clocks */
}
--- a/kernel/fork.c
+++ b/kernel/fork.c
-@@ -1080,6 +1080,7 @@ static struct mm_struct *mm_init(struct
+@@ -1083,6 +1083,7 @@ static struct mm_struct *mm_init(struct
goto fail_nocontext;
mm->user_ns = get_user_ns(user_ns);
return mm;
fail_nocontext:
-@@ -1122,6 +1123,7 @@ static inline void __mmput(struct mm_str
+@@ -1125,6 +1126,7 @@ static inline void __mmput(struct mm_str
}
if (mm->binfmt)
module_put(mm->binfmt->module);
mmdrop(mm);
}
-@@ -2617,6 +2619,13 @@ pid_t kernel_clone(struct kernel_clone_a
+@@ -2622,6 +2624,13 @@ pid_t kernel_clone(struct kernel_clone_a
get_task_struct(p);
}
+ mtd_check_of_node(mtd);
of_node_get(mtd_get_of_node(mtd));
error = device_register(&mtd->dev);
- if (error)
+ if (error) {
--- a/drivers/mtd/mtdcore.c
+++ b/drivers/mtd/mtdcore.c
-@@ -1227,6 +1227,34 @@ int __get_mtd_device(struct mtd_info *mt
+@@ -1229,6 +1229,34 @@ int __get_mtd_device(struct mtd_info *mt
EXPORT_SYMBOL_GPL(__get_mtd_device);
/**
#include <linux/mtd/mtd.h>
#include <linux/mtd/partitions.h>
-@@ -746,6 +747,17 @@ int add_mtd_device(struct mtd_info *mtd)
+@@ -748,6 +749,17 @@ int add_mtd_device(struct mtd_info *mtd)
not->add(mtd);
mutex_unlock(&mtd_table_mutex);
static inline void
--- a/include/linux/netdevice.h
+++ b/include/linux/netdevice.h
-@@ -863,6 +863,7 @@ enum net_device_path_type {
+@@ -870,6 +870,7 @@ enum net_device_path_type {
DEV_PATH_BRIDGE,
DEV_PATH_PPPOE,
DEV_PATH_DSA,
};
struct net_device_path {
-@@ -888,6 +889,12 @@ struct net_device_path {
+@@ -895,6 +896,12 @@ struct net_device_path {
int port;
u16 proto;
} dsa;
stmmac_clear_tx_descriptors(priv, queue);
stmmac_init_tx_chan(priv, priv->ioaddr, priv->plat->dma_cfg,
-@@ -7398,6 +7393,25 @@ int stmmac_suspend(struct device *dev)
+@@ -7400,6 +7395,25 @@ int stmmac_suspend(struct device *dev)
}
EXPORT_SYMBOL_GPL(stmmac_suspend);
/**
* stmmac_reset_queues_param - reset queue parameters
* @priv: device pointer
-@@ -7408,22 +7422,11 @@ static void stmmac_reset_queues_param(st
+@@ -7410,22 +7424,11 @@ static void stmmac_reset_queues_param(st
u32 tx_cnt = priv->plat->tx_queues_to_use;
u32 queue;
if (netif_running(dev))
ret = stmmac_open(dev);
-@@ -7344,7 +7348,7 @@ int stmmac_suspend(struct device *dev)
+@@ -7346,7 +7350,7 @@ int stmmac_suspend(struct device *dev)
stmmac_disable_all_queues(priv);
for (chan = 0; chan < priv->plat->tx_queues_to_use; chan++)
if (priv->eee_enabled) {
priv->tx_path_in_lpi_mode = false;
-@@ -7395,7 +7399,7 @@ EXPORT_SYMBOL_GPL(stmmac_suspend);
+@@ -7397,7 +7401,7 @@ EXPORT_SYMBOL_GPL(stmmac_suspend);
static void stmmac_reset_rx_queue(struct stmmac_priv *priv, u32 queue)
{
rx_q->cur_rx = 0;
rx_q->dirty_rx = 0;
-@@ -7403,7 +7407,7 @@ static void stmmac_reset_rx_queue(struct
+@@ -7405,7 +7409,7 @@ static void stmmac_reset_rx_queue(struct
static void stmmac_reset_tx_queue(struct stmmac_priv *priv, u32 queue)
{
stmmac_set_rx_tail_ptr(priv, priv->ioaddr, tail, i);
stmmac_start_rx(priv, priv->ioaddr, i);
-@@ -1680,7 +1680,7 @@ cleanup:
+@@ -1684,7 +1684,7 @@ cleanup:
static int __stmmac_test_jumbo(struct stmmac_priv *priv, u16 queue)
{
struct stmmac_packet_attrs attr = { };
attr.dst = priv->dev->dev_addr;
attr.max_size = size - ETH_FCS_LEN;
-@@ -1763,7 +1763,7 @@ static int stmmac_test_tbs(struct stmmac
+@@ -1767,7 +1767,7 @@ static int stmmac_test_tbs(struct stmmac
/* Find first TBS enabled Queue, if any */
for (i = 0; i < priv->plat->tx_queues_to_use; i++)
dma_desc_error:
return ret;
}
-@@ -7490,7 +7606,7 @@ int stmmac_resume(struct device *dev)
+@@ -7492,7 +7608,7 @@ int stmmac_resume(struct device *dev)
stmmac_reset_queues_param(priv);
stmmac_free_tx_skbufs(priv);
#include "mtdcore.h"
-@@ -1079,6 +1080,8 @@ int mtd_device_parse_register(struct mtd
+@@ -1081,6 +1082,8 @@ int mtd_device_parse_register(struct mtd
ret = mtd_otp_nvmem_add(mtd);
--- a/drivers/mtd/mtdcore.c
+++ b/drivers/mtd/mtdcore.c
-@@ -759,7 +759,8 @@ int add_mtd_device(struct mtd_info *mtd)
+@@ -761,7 +761,8 @@ int add_mtd_device(struct mtd_info *mtd)
mutex_unlock(&mtd_table_mutex);
--- a/include/linux/netdevice.h
+++ b/include/linux/netdevice.h
-@@ -1669,6 +1669,10 @@ enum netdev_priv_flags {
+@@ -1676,6 +1676,10 @@ enum netdev_priv_flags {
IFF_TX_SKB_NO_LINEAR = BIT_ULL(31),
};
#define IFF_802_1Q_VLAN IFF_802_1Q_VLAN
#define IFF_EBRIDGE IFF_EBRIDGE
#define IFF_BONDING IFF_BONDING
-@@ -1701,6 +1705,7 @@ enum netdev_priv_flags {
+@@ -1708,6 +1712,7 @@ enum netdev_priv_flags {
#define IFF_L3MDEV_RX_HANDLER IFF_L3MDEV_RX_HANDLER
#define IFF_LIVE_RENAME_OK IFF_LIVE_RENAME_OK
#define IFF_TX_SKB_NO_LINEAR IFF_TX_SKB_NO_LINEAR
/* Specifies the type of the struct net_device::ml_priv pointer */
enum netdev_ml_priv_type {
-@@ -2002,6 +2007,7 @@ struct net_device {
+@@ -2009,6 +2014,7 @@ struct net_device {
/* Read-mostly cache-line for fast-path access */
unsigned int flags;
unsigned int priv_flags;
const struct net_device_ops *netdev_ops;
int ifindex;
unsigned short gflags;
-@@ -2062,6 +2068,11 @@ struct net_device {
+@@ -2069,6 +2075,11 @@ struct net_device {
const struct tlsdev_ops *tlsdev_ops;
#endif
const struct header_ops *header_ops;
unsigned char operstate;
-@@ -2136,6 +2147,10 @@ struct net_device {
+@@ -2143,6 +2154,10 @@ struct net_device {
struct mctp_dev __rcu *mctp_ptr;
#endif
{
--- a/include/linux/gpio/consumer.h
+++ b/include/linux/gpio/consumer.h
-@@ -715,6 +715,7 @@ static inline void devm_acpi_dev_remove_
+@@ -712,6 +712,7 @@ static inline void devm_acpi_dev_remove_
#if IS_ENABLED(CONFIG_GPIOLIB) && IS_ENABLED(CONFIG_GPIO_SYSFS)
int gpiod_export(struct gpio_desc *desc, bool direction_may_change);
int gpiod_export_link(struct device *dev, const char *name,
struct gpio_desc *desc);
-@@ -722,6 +723,13 @@ void gpiod_unexport(struct gpio_desc *de
+@@ -719,6 +720,13 @@ void gpiod_unexport(struct gpio_desc *de
#else /* CONFIG_GPIOLIB && CONFIG_GPIO_SYSFS */
+++ /dev/null
-From d3c5b26768dbe990c4e1bd79e420c11ce7491d51 Mon Sep 17 00:00:00 2001
-From: OpenWrt community <openwrt-devel@lists.openwrt.org>
-Date: Wed, 13 Jul 2022 11:36:00 +0200
-Subject: [PATCH] swab: use stddefs.h instead of compiler.h
-
-Fix an issue with kernel headers that broke perf.
-
----
- include/uapi/linux/swab.h | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
---- a/include/uapi/linux/swab.h
-+++ b/include/uapi/linux/swab.h
-@@ -3,7 +3,7 @@
- #define _UAPI_LINUX_SWAB_H
-
- #include <linux/types.h>
--#include <linux/compiler.h>
-+#include <linux/stddef.h>
- #include <asm/bitsperlong.h>
- #include <asm/swab.h>
-
--- a/drivers/spi/spidev.c
+++ b/drivers/spi/spidev.c
-@@ -696,6 +696,7 @@ static const struct of_device_id spidev_
+@@ -707,6 +707,7 @@ static const struct of_device_id spidev_
{ .compatible = "menlo,m53cpld" },
{ .compatible = "cisco,spi-petra" },
{ .compatible = "micron,spi-authenta" },
return !!nor->params->erase_map.uniform_erase_type;
}
-@@ -2388,6 +2390,7 @@ static int spi_nor_select_erase(struct s
+@@ -2389,6 +2391,7 @@ static int spi_nor_select_erase(struct s
{
struct spi_nor_erase_map *map = &nor->params->erase_map;
const struct spi_nor_erase_type *erase = NULL;
struct mtd_info *mtd = &nor->mtd;
u32 wanted_size = nor->info->sector_size;
int i;
-@@ -2420,8 +2423,9 @@ static int spi_nor_select_erase(struct s
+@@ -2421,8 +2424,9 @@ static int spi_nor_select_erase(struct s
*/
for (i = SNOR_ERASE_TYPE_MAX - 1; i >= 0; i--) {
if (map->erase_type[i].size) {
}
}
-@@ -2429,6 +2433,9 @@ static int spi_nor_select_erase(struct s
+@@ -2430,6 +2434,9 @@ static int spi_nor_select_erase(struct s
return -EINVAL;
mtd->erasesize = erase->size;
--- a/include/linux/netdevice.h
+++ b/include/linux/netdevice.h
-@@ -2089,6 +2089,8 @@ struct net_device {
+@@ -2096,6 +2096,8 @@ struct net_device {
struct netdev_hw_addr_list mc;
struct netdev_hw_addr_list dev_addrs;
/*
* Define if arch has non-standard setup. This is a _PCI_ standard
-@@ -888,6 +891,12 @@ struct ata_port {
+@@ -894,6 +897,12 @@ struct ata_port {
#ifdef CONFIG_ATA_ACPI
struct ata_acpi_gtm __acpi_init_gtm; /* use ata_acpi_init_gtm() */
#endif
+++ /dev/null
-From 2acc3260050cf17d72ec5fb7a00cd91cf53ef5b6 Mon Sep 17 00:00:00 2001
-From: Christian Marangi <ansuelsmth@gmail.com>
-Date: Fri, 23 Sep 2022 18:42:29 +0200
-Subject: [PATCH 1/4] clk: qcom: clk-krait: fix wrong div2 functions
-
-Currently div2 value is applied to the wrong bits. This is caused by a
-bug in the code where the shift is done only for lpl, for anything
-else the mask is not shifted to the correct bits.
-
-Fix this by correctly shift if lpl is not supported.
-
-Fixes: 4d7dc77babfe ("clk: qcom: Add support for Krait clocks")
-Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
----
- drivers/clk/qcom/clk-krait.c | 2 ++
- 1 file changed, 2 insertions(+)
-
---- a/drivers/clk/qcom/clk-krait.c
-+++ b/drivers/clk/qcom/clk-krait.c
-@@ -114,6 +114,8 @@ static int krait_div2_set_rate(struct cl
-
- if (d->lpl)
- mask = mask << (d->shift + LPL_SHIFT) | mask << d->shift;
-+ else
-+ mask <<= d->shift;
-
- spin_lock_irqsave(&krait_clock_reg_lock, flags);
- val = krait_get_l2_indirect_reg(d->offset);
/* check we are the Master VPE */
local_irq_save(flags);
-@@ -417,6 +418,8 @@ int __init vpe_module_init(void)
+@@ -416,6 +417,8 @@ int __init vpe_module_init(void)
}
v->ntcs = hw_tcs - aprp_cpu_index();
--- a/arch/arm/boot/dts/armada-385-turris-omnia.dts
+++ b/arch/arm/boot/dts/armada-385-turris-omnia.dts
-@@ -390,7 +390,8 @@
+@@ -396,7 +396,8 @@
phy1: ethernet-phy@1 {
compatible = "ethernet-phy-ieee802.3-c22";
reg = <1>;
--- a/arch/arm/boot/dts/armada-385-turris-omnia.dts
+++ b/arch/arm/boot/dts/armada-385-turris-omnia.dts
-@@ -188,15 +188,13 @@
+@@ -194,15 +194,13 @@
reg = <0x2b>;
#address-cells = <1>;
#size-cells = <0>;
* - there are 3 LEDs connected via MCU to PCIe
* ports. One of these ports supports mSATA.
* There is no mSATA nor PCIe function.
-@@ -207,7 +205,6 @@
+@@ -213,7 +211,6 @@
* B. Again there is no such function defined.
* For now we use LED_FUNCTION_INDICATOR
*/
--- a/drivers/mfd/Kconfig
+++ b/drivers/mfd/Kconfig
-@@ -2187,6 +2187,15 @@ config SGI_MFD_IOC3
+@@ -2188,6 +2188,15 @@ config SGI_MFD_IOC3
If you have an SGI Origin, Octane, or a PCI IOC3 card,
then say Y. Otherwise say N.
--- a/include/linux/libata.h
+++ b/include/linux/libata.h
-@@ -917,6 +917,8 @@ struct ata_port_operations {
+@@ -923,6 +923,8 @@ struct ata_port_operations {
enum ata_completion_errors (*qc_prep)(struct ata_queued_cmd *qc);
unsigned int (*qc_issue)(struct ata_queued_cmd *qc);
bool (*qc_fill_rtf)(struct ata_queued_cmd *qc);
/*
* Configuration and exception handling
-@@ -1007,6 +1009,9 @@ struct ata_port_operations {
+@@ -1013,6 +1015,9 @@ struct ata_port_operations {
void (*phy_reset)(struct ata_port *ap);
void (*eng_timeout)(struct ata_port *ap);
-
--- a/drivers/staging/mt7621-pci/pci-mt7621.c
+++ /dev/null
-@@ -1,600 +0,0 @@
+@@ -1,601 +0,0 @@
-// SPDX-License-Identifier: GPL-2.0+
-/*
- * BRIEF MODULE DESCRIPTION
- * reset lines are inverted.
- */
-struct mt7621_pcie {
-- void __iomem *base;
- struct device *dev;
+- void __iomem *base;
- struct list_head ports;
- bool resets_inverted;
-};
- writel_relaxed(val, port->base + reg);
-}
-
--static inline u32 mt7621_pci_get_cfgaddr(unsigned int bus, unsigned int slot,
+-static inline u32 mt7621_pcie_get_cfgaddr(unsigned int bus, unsigned int slot,
- unsigned int func, unsigned int where)
-{
- return (((where & 0xF00) >> 8) << 24) | (bus << 16) | (slot << 11) |
- unsigned int devfn, int where)
-{
- struct mt7621_pcie *pcie = bus->sysdata;
-- u32 address = mt7621_pci_get_cfgaddr(bus->number, PCI_SLOT(devfn),
+- u32 address = mt7621_pcie_get_cfgaddr(bus->number, PCI_SLOT(devfn),
- PCI_FUNC(devfn), where);
-
- writel_relaxed(address, pcie->base + RALINK_PCI_CONFIG_ADDR);
- return pcie->base + RALINK_PCI_CONFIG_DATA + (where & 3);
-}
-
--struct pci_ops mt7621_pci_ops = {
+-struct pci_ops mt7621_pcie_ops = {
- .map_bus = mt7621_pcie_map_bus,
- .read = pci_generic_config_read,
- .write = pci_generic_config_write,
-
-static u32 read_config(struct mt7621_pcie *pcie, unsigned int dev, u32 reg)
-{
-- u32 address = mt7621_pci_get_cfgaddr(0, dev, 0, reg);
+- u32 address = mt7621_pcie_get_cfgaddr(0, dev, 0, reg);
-
- pcie_write(pcie, address, RALINK_PCI_CONFIG_ADDR);
- return pcie_read(pcie, RALINK_PCI_CONFIG_DATA);
-static void write_config(struct mt7621_pcie *pcie, unsigned int dev,
- u32 reg, u32 val)
-{
-- u32 address = mt7621_pci_get_cfgaddr(0, dev, 0, reg);
+- u32 address = mt7621_pcie_get_cfgaddr(0, dev, 0, reg);
-
- pcie_write(pcie, address, RALINK_PCI_CONFIG_ADDR);
- pcie_write(pcie, val, RALINK_PCI_CONFIG_DATA);
-{
- struct mt7621_pcie *pcie = pci_host_bridge_priv(host);
-
-- host->ops = &mt7621_pci_ops;
+- host->ops = &mt7621_pcie_ops;
- host->sysdata = pcie;
- return pci_host_probe(host);
-}
-
--static const struct soc_device_attribute mt7621_pci_quirks_match[] = {
-- { .soc_id = "mt7621", .revision = "E2" }
+-static const struct soc_device_attribute mt7621_pcie_quirks_match[] = {
+- { .soc_id = "mt7621", .revision = "E2" },
+- { /* sentinel */ }
-};
-
--static int mt7621_pci_probe(struct platform_device *pdev)
+-static int mt7621_pcie_probe(struct platform_device *pdev)
-{
- struct device *dev = &pdev->dev;
- const struct soc_device_attribute *attr;
- platform_set_drvdata(pdev, pcie);
- INIT_LIST_HEAD(&pcie->ports);
-
-- attr = soc_device_match(mt7621_pci_quirks_match);
+- attr = soc_device_match(mt7621_pcie_quirks_match);
- if (attr)
- pcie->resets_inverted = true;
-
- return err;
-}
-
--static int mt7621_pci_remove(struct platform_device *pdev)
+-static int mt7621_pcie_remove(struct platform_device *pdev)
-{
- struct mt7621_pcie *pcie = platform_get_drvdata(pdev);
- struct mt7621_pcie_port *port;
- return 0;
-}
-
--static const struct of_device_id mt7621_pci_ids[] = {
+-static const struct of_device_id mt7621_pcie_ids[] = {
- { .compatible = "mediatek,mt7621-pci" },
- {},
-};
--MODULE_DEVICE_TABLE(of, mt7621_pci_ids);
+-MODULE_DEVICE_TABLE(of, mt7621_pcie_ids);
-
--static struct platform_driver mt7621_pci_driver = {
-- .probe = mt7621_pci_probe,
-- .remove = mt7621_pci_remove,
+-static struct platform_driver mt7621_pcie_driver = {
+- .probe = mt7621_pcie_probe,
+- .remove = mt7621_pcie_remove,
- .driver = {
- .name = "mt7621-pci",
-- .of_match_table = of_match_ptr(mt7621_pci_ids),
+- .of_match_table = of_match_ptr(mt7621_pcie_ids),
- },
-};
--builtin_platform_driver(mt7621_pci_driver);
+-builtin_platform_driver(mt7621_pcie_driver);
--- /dev/null
+++ b/drivers/pci/controller/pcie-mt7621.c
@@ -0,0 +1,600 @@
#include <asm/bootinfo.h>
#include <asm/mipsregs.h>
-@@ -24,6 +26,35 @@
-
+@@ -25,6 +27,35 @@
static u32 detect_magic __initdata;
+ static struct ralink_soc_info *soc_info_ptr;
+int pcibios_root_bridge_prepare(struct pci_host_bridge *bridge)
+{
--- /dev/null
+From 19098934f910b4d47cb30251dd39ffa57bef9523 Mon Sep 17 00:00:00 2001
+From: John Thomson <git@johnthomson.fastmail.com.au>
+Date: Tue, 6 Dec 2022 06:46:45 +1000
+Subject: [PATCH] PCI: mt7621: Add sentinel to quirks table
+
+Current driver is missing a sentinel in the struct soc_device_attribute
+array, which causes an oops when assessed by the
+soc_device_match(mt7621_pcie_quirks_match) call.
+
+This was only exposed once the CONFIG_SOC_MT7621 mt7621 soc_dev_attr
+was fixed to register the SOC as a device, in:
+
+commit 7c18b64bba3b ("mips: ralink: mt7621: do not use kzalloc too early")
+
+Fix it by adding the required sentinel.
+
+Link: https://lore.kernel.org/lkml/26ebbed1-0fe9-4af9-8466-65f841d0b382@app.fastmail.com
+Link: https://lore.kernel.org/r/20221205204645.301301-1-git@johnthomson.fastmail.com.au
+Fixes: b483b4e4d3f6 ("staging: mt7621-pci: add quirks for 'E2' revision using 'soc_device_attribute'")
+Signed-off-by: John Thomson <git@johnthomson.fastmail.com.au>
+Signed-off-by: Lorenzo Pieralisi <lpieralisi@kernel.org>
+Acked-by: Sergio Paracuellos <sergio.paracuellos@gmail.com>
+---
+ drivers/pci/controller/pcie-mt7621.c | 3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
+--- a/drivers/pci/controller/pcie-mt7621.c
++++ b/drivers/pci/controller/pcie-mt7621.c
+@@ -471,7 +471,8 @@ static int mt7621_pcie_register_host(str
+ }
+
+ static const struct soc_device_attribute mt7621_pcie_quirks_match[] = {
+- { .soc_id = "mt7621", .revision = "E2" }
++ { .soc_id = "mt7621", .revision = "E2" },
++ { /* sentinel */ }
+ };
+
+ static int mt7621_pcie_probe(struct platform_device *pdev)