Refresh pending patches with make target/linux/refresh.
Signed-off-by: Weijie Gao <hackpascal@gmail.com>
88 files changed:
--- a/include/linux/compiler.h
+++ b/include/linux/compiler.h
--- a/include/linux/compiler.h
+++ b/include/linux/compiler.h
-@@ -203,6 +203,8 @@ void ftrace_likely_update(struct ftrace_
+@@ -202,6 +202,8 @@ void ftrace_likely_update(struct ftrace_
--- a/Makefile
+++ b/Makefile
--- a/Makefile
+++ b/Makefile
-@@ -605,7 +605,7 @@ endif
+@@ -599,7 +599,7 @@ endif
# Allows the usage of unstable features in stable compilers.
export RUSTC_BOOTSTRAP := 1
# Allows the usage of unstable features in stable compilers.
export RUSTC_BOOTSTRAP := 1
--- a/drivers/watchdog/max63xx_wdt.c
+++ b/drivers/watchdog/max63xx_wdt.c
--- a/drivers/watchdog/max63xx_wdt.c
+++ b/drivers/watchdog/max63xx_wdt.c
#include <linux/io.h>
#include <linux/slab.h>
#include <linux/property.h>
#include <linux/io.h>
#include <linux/slab.h>
#include <linux/property.h>
#define DEFAULT_HEARTBEAT 60
#define MAX_HEARTBEAT 60
#define DEFAULT_HEARTBEAT 60
#define MAX_HEARTBEAT 60
-@@ -53,6 +54,9 @@ struct max63xx_wdt {
+@@ -50,6 +51,9 @@ struct max63xx_wdt {
void __iomem *base;
spinlock_t lock;
void __iomem *base;
spinlock_t lock;
/* WDI and WSET bits write access routines */
void (*ping)(struct max63xx_wdt *wdt);
void (*set)(struct max63xx_wdt *wdt, u8 set);
/* WDI and WSET bits write access routines */
void (*ping)(struct max63xx_wdt *wdt);
void (*set)(struct max63xx_wdt *wdt, u8 set);
-@@ -158,6 +162,17 @@ static const struct watchdog_info max63x
+@@ -155,6 +159,17 @@ static const struct watchdog_info max63x
.identity = "max63xx Watchdog",
};
.identity = "max63xx Watchdog",
};
static void max63xx_mmap_ping(struct max63xx_wdt *wdt)
{
u8 val;
static void max63xx_mmap_ping(struct max63xx_wdt *wdt)
{
u8 val;
-@@ -225,10 +240,19 @@ static int max63xx_wdt_probe(struct plat
+@@ -222,10 +237,19 @@ static int max63xx_wdt_probe(struct plat
--- a/net/bridge/br_input.c
+++ b/net/bridge/br_input.c
--- a/net/bridge/br_input.c
+++ b/net/bridge/br_input.c
-@@ -222,6 +222,9 @@ static void __br_handle_local_finish(str
+@@ -239,6 +239,9 @@ static void __br_handle_local_finish(str
/* note: already called with rcu_read_lock */
static int br_handle_local_finish(struct net *net, struct sock *sk, struct sk_buff *skb)
{
/* note: already called with rcu_read_lock */
static int br_handle_local_finish(struct net *net, struct sock *sk, struct sk_buff *skb)
{
__br_handle_local_finish(skb);
/* return 1 to signal the okfn() was called so it's ok to use the skb */
__br_handle_local_finish(skb);
/* return 1 to signal the okfn() was called so it's ok to use the skb */
-@@ -390,6 +393,17 @@ forward:
+@@ -408,6 +411,17 @@ forward:
goto defer_stp_filtering;
switch (p->state) {
goto defer_stp_filtering;
switch (p->state) {
--- a/drivers/rtc/rtc-rs5c372.c
+++ b/drivers/rtc/rtc-rs5c372.c
--- a/drivers/rtc/rtc-rs5c372.c
+++ b/drivers/rtc/rtc-rs5c372.c
-@@ -833,6 +833,7 @@ static int rs5c372_probe(struct i2c_clie
+@@ -832,6 +832,7 @@ static int rs5c372_probe(struct i2c_clie
int err = 0;
int smbus_mode = 0;
struct rs5c372 *rs5c372;
int err = 0;
int smbus_mode = 0;
struct rs5c372 *rs5c372;
--- a/init/Kconfig
+++ b/init/Kconfig
--- a/init/Kconfig
+++ b/init/Kconfig
-@@ -1491,6 +1491,17 @@ config SYSCTL_ARCH_UNALIGN_ALLOW
+@@ -1451,6 +1451,17 @@ config SYSCTL_ARCH_UNALIGN_ALLOW
the unaligned access emulation.
see arch/parisc/kernel/unaligned.c for reference
the unaligned access emulation.
see arch/parisc/kernel/unaligned.c for reference
* and return the first char from this token.
--- a/scripts/kallsyms.c
+++ b/scripts/kallsyms.c
* and return the first char from this token.
--- a/scripts/kallsyms.c
+++ b/scripts/kallsyms.c
-@@ -77,6 +77,7 @@ static struct addr_range percpu_range =
+@@ -62,6 +62,7 @@ static struct addr_range percpu_range =
static struct sym_entry **table;
static unsigned int table_size, table_cnt;
static int all_symbols;
static struct sym_entry **table;
static unsigned int table_size, table_cnt;
static int all_symbols;
static int absolute_percpu;
static int base_relative;
static int lto_clang;
static int absolute_percpu;
static int base_relative;
static int lto_clang;
-@@ -608,6 +609,9 @@ static void write_src(void)
+@@ -469,6 +470,9 @@ static void write_src(void)
output_label("kallsyms_token_table");
off = 0;
for (i = 0; i < 256; i++) {
output_label("kallsyms_token_table");
off = 0;
for (i = 0; i < 256; i++) {
-@@ -659,6 +663,9 @@ static unsigned char *find_token(unsigne
+@@ -582,6 +586,9 @@ static unsigned char *find_token(unsigne
for (i = 0; i < len - 1; i++) {
if (str[i] == token[0] && str[i+1] == token[1])
return &str[i];
for (i = 0; i < len - 1; i++) {
if (str[i] == token[0] && str[i+1] == token[1])
return &str[i];
-@@ -731,6 +738,9 @@ static void optimize_result(void)
+@@ -654,6 +661,9 @@ static void optimize_result(void)
/* using the '\0' symbol last allows compress_symbols to use standard
* fast string functions */
for (i = 255; i >= 0; i--) {
/* using the '\0' symbol last allows compress_symbols to use standard
* fast string functions */
for (i = 255; i >= 0; i--) {
-@@ -892,6 +902,7 @@ int main(int argc, char **argv)
+@@ -815,6 +825,7 @@ int main(int argc, char **argv)
{"absolute-percpu", no_argument, &absolute_percpu, 1},
{"base-relative", no_argument, &base_relative, 1},
{"lto-clang", no_argument, <o_clang, 1},
{"absolute-percpu", no_argument, &absolute_percpu, 1},
{"base-relative", no_argument, &base_relative, 1},
{"lto-clang", no_argument, <o_clang, 1},
--- a/lib/vsprintf.c
+++ b/lib/vsprintf.c
--- a/lib/vsprintf.c
+++ b/lib/vsprintf.c
-@@ -985,8 +985,10 @@ char *symbol_string(char *buf, char *end
+@@ -982,8 +982,10 @@ char *symbol_string(char *buf, char *end
struct printf_spec spec, const char *fmt)
{
unsigned long value;
struct printf_spec spec, const char *fmt)
{
unsigned long value;
#endif
if (fmt[1] == 'R')
#endif
if (fmt[1] == 'R')
-@@ -1007,8 +1009,14 @@ char *symbol_string(char *buf, char *end
+@@ -1004,8 +1006,14 @@ char *symbol_string(char *buf, char *end
return string_nocheck(buf, end, sym, spec);
#else
return string_nocheck(buf, end, sym, spec);
#else
--- a/drivers/platform/Kconfig
+++ b/drivers/platform/Kconfig
--- a/drivers/platform/Kconfig
+++ b/drivers/platform/Kconfig
-@@ -16,3 +16,5 @@ source "drivers/platform/olpc/Kconfig"
+@@ -14,3 +14,5 @@ source "drivers/platform/olpc/Kconfig"
source "drivers/platform/surface/Kconfig"
source "drivers/platform/x86/Kconfig"
source "drivers/platform/surface/Kconfig"
source "drivers/platform/x86/Kconfig"
---
--- a/arch/mips/Kconfig
+++ b/arch/mips/Kconfig
---
--- a/arch/mips/Kconfig
+++ b/arch/mips/Kconfig
-@@ -1035,9 +1035,6 @@ config FW_ARC
+@@ -1013,9 +1013,6 @@ config FW_ARC
config ARCH_MAY_HAVE_PC_FDC
bool
config ARCH_MAY_HAVE_PC_FDC
bool
-@@ -3093,6 +3090,18 @@ choice
+@@ -2996,6 +2993,18 @@ choice
bool "Extend builtin kernel arguments with bootloader arguments"
endchoice
bool "Extend builtin kernel arguments with bootloader arguments"
endchoice
--- a/arch/mips/mm/c-r4k.c
+++ b/arch/mips/mm/c-r4k.c
--- a/arch/mips/mm/c-r4k.c
+++ b/arch/mips/mm/c-r4k.c
-@@ -514,6 +514,7 @@ static inline void local_r4k___flush_cac
+@@ -403,6 +403,7 @@ static inline void local_r4k___flush_cac
default:
r4k_blast_dcache();
default:
r4k_blast_dcache();
r4k_blast_icache();
break;
}
r4k_blast_icache();
break;
}
-@@ -594,8 +595,10 @@ static inline void local_r4k_flush_cache
+@@ -483,8 +484,10 @@ static inline void local_r4k_flush_cache
if (cpu_has_dc_aliases || (exec && !cpu_has_ic_fills_f_dc))
r4k_blast_dcache();
/* If executable, blast stale lines from icache */
if (cpu_has_dc_aliases || (exec && !cpu_has_ic_fills_f_dc))
r4k_blast_dcache();
/* If executable, blast stale lines from icache */
}
static void r4k_flush_cache_range(struct vm_area_struct *vma,
}
static void r4k_flush_cache_range(struct vm_area_struct *vma,
-@@ -696,8 +699,13 @@ static inline void local_r4k_flush_cache
+@@ -586,8 +589,13 @@ static inline void local_r4k_flush_cache
if (cpu_has_dc_aliases || (exec && !cpu_has_ic_fills_f_dc)) {
vaddr ? r4k_blast_dcache_page(addr) :
r4k_blast_dcache_user_page(addr);
if (cpu_has_dc_aliases || (exec && !cpu_has_ic_fills_f_dc)) {
vaddr ? r4k_blast_dcache_page(addr) :
r4k_blast_dcache_user_page(addr);
}
if (exec) {
if (vaddr && cpu_has_vtag_icache && mm == current->active_mm) {
}
if (exec) {
if (vaddr && cpu_has_vtag_icache && mm == current->active_mm) {
-@@ -764,6 +772,7 @@ static inline void __local_r4k_flush_ica
+@@ -654,6 +662,7 @@ static inline void __local_r4k_flush_ica
else
blast_dcache_range(start, end);
}
else
blast_dcache_range(start, end);
}
--- a/arch/mips/Makefile
+++ b/arch/mips/Makefile
--- a/arch/mips/Makefile
+++ b/arch/mips/Makefile
-@@ -172,7 +172,7 @@ cflags-$(CONFIG_CPU_R4300) += -march=r43
+@@ -163,7 +163,7 @@ cflags-$(CONFIG_CPU_R4300) += -march=r43
cflags-$(CONFIG_CPU_R4X00) += -march=r4600 -Wa,--trap
cflags-$(CONFIG_CPU_TX49XX) += -march=r4600 -Wa,--trap
cflags-$(CONFIG_CPU_MIPS32_R1) += -march=mips32 -Wa,--trap
cflags-$(CONFIG_CPU_R4X00) += -march=r4600 -Wa,--trap
cflags-$(CONFIG_CPU_TX49XX) += -march=r4600 -Wa,--trap
cflags-$(CONFIG_CPU_MIPS32_R1) += -march=mips32 -Wa,--trap
;----------------------------------------------------------------
--- a/arch/arc/kernel/setup.c
+++ b/arch/arc/kernel/setup.c
;----------------------------------------------------------------
--- a/arch/arc/kernel/setup.c
+++ b/arch/arc/kernel/setup.c
-@@ -495,6 +495,8 @@ static inline bool uboot_arg_invalid(uns
+@@ -450,6 +450,8 @@ static inline bool uboot_arg_invalid(uns
/* We always pass 0 as magic from U-boot */
#define UBOOT_MAGIC_VALUE 0
/* We always pass 0 as magic from U-boot */
#define UBOOT_MAGIC_VALUE 0
void __init handle_uboot_args(void)
{
bool use_embedded_dtb = true;
void __init handle_uboot_args(void)
{
bool use_embedded_dtb = true;
-@@ -533,7 +535,7 @@ void __init handle_uboot_args(void)
+@@ -488,7 +490,7 @@ void __init handle_uboot_args(void)
ignore_uboot_args:
if (use_embedded_dtb) {
ignore_uboot_args:
if (use_embedded_dtb) {
--- a/arch/powerpc/Kconfig
+++ b/arch/powerpc/Kconfig
--- a/arch/powerpc/Kconfig
+++ b/arch/powerpc/Kconfig
-@@ -229,7 +229,7 @@ config PPC
+@@ -251,7 +251,7 @@ config PPC
select HAVE_KERNEL_GZIP
select HAVE_KERNEL_LZMA if DEFAULT_UIMAGE
select HAVE_KERNEL_LZO if DEFAULT_UIMAGE
select HAVE_KERNEL_GZIP
select HAVE_KERNEL_LZMA if DEFAULT_UIMAGE
select HAVE_KERNEL_LZO if DEFAULT_UIMAGE
/*
* MTD methods which simply translate the effective address and pass through
/*
* MTD methods which simply translate the effective address and pass through
-@@ -236,6 +238,147 @@ static int mtd_add_partition_attrs(struc
+@@ -242,6 +244,147 @@ static int mtd_add_partition_attrs(struc
int mtd_add_partition(struct mtd_info *parent, const char *name,
long long offset, long long length)
{
int mtd_add_partition(struct mtd_info *parent, const char *name,
long long offset, long long length)
{
-@@ -274,6 +417,7 @@ int mtd_add_partition(struct mtd_info *p
+@@ -280,6 +423,7 @@ int mtd_add_partition(struct mtd_info *p
if (ret)
goto err_remove_part;
if (ret)
goto err_remove_part;
mtd_add_partition_attrs(child);
return 0;
mtd_add_partition_attrs(child);
return 0;
-@@ -422,6 +566,7 @@ int add_mtd_partitions(struct mtd_info *
+@@ -423,6 +567,7 @@ int add_mtd_partitions(struct mtd_info *
goto err_del_partitions;
}
goto err_del_partitions;
}
mtd_add_partition_attrs(child);
/* Look for subpartitions */
mtd_add_partition_attrs(child);
/* Look for subpartitions */
-@@ -438,31 +583,6 @@ err_del_partitions:
+@@ -439,31 +584,6 @@ err_del_partitions:
--- a/drivers/mtd/mtdcore.c
+++ b/drivers/mtd/mtdcore.c
--- a/drivers/mtd/mtdcore.c
+++ b/drivers/mtd/mtdcore.c
-@@ -519,6 +519,29 @@ static int mtd_nvmem_add(struct mtd_info
+@@ -548,6 +548,29 @@ static int mtd_nvmem_add(struct mtd_info
struct device_node *node = mtd_get_of_node(mtd);
struct nvmem_config config = {};
struct device_node *node = mtd_get_of_node(mtd);
struct nvmem_config config = {};
--- a/drivers/mtd/mtdcore.c
+++ b/drivers/mtd/mtdcore.c
--- a/drivers/mtd/mtdcore.c
+++ b/drivers/mtd/mtdcore.c
-@@ -169,6 +169,15 @@ static ssize_t mtd_erasesize_show(struct
+@@ -198,6 +198,15 @@ static ssize_t mtd_erasesize_show(struct
}
MTD_DEVICE_ATTR_RO(erasesize);
}
MTD_DEVICE_ATTR_RO(erasesize);
static ssize_t mtd_writesize_show(struct device *dev,
struct device_attribute *attr, char *buf)
{
static ssize_t mtd_writesize_show(struct device *dev,
struct device_attribute *attr, char *buf)
{
-@@ -314,6 +323,7 @@ static struct attribute *mtd_attrs[] = {
+@@ -343,6 +352,7 @@ static struct attribute *mtd_attrs[] = {
&dev_attr_flags.attr,
&dev_attr_size.attr,
&dev_attr_erasesize.attr,
&dev_attr_flags.attr,
&dev_attr_size.attr,
&dev_attr_erasesize.attr,
&dev_attr_oobsize.attr,
--- a/drivers/mtd/mtdpart.c
+++ b/drivers/mtd/mtdpart.c
&dev_attr_oobsize.attr,
--- a/drivers/mtd/mtdpart.c
+++ b/drivers/mtd/mtdpart.c
-@@ -41,6 +41,7 @@ static struct mtd_info *allocate_partiti
+@@ -47,6 +47,7 @@ static struct mtd_info *allocate_partiti
struct mtd_info *master = mtd_get_master(parent);
int wr_alignment = (parent->flags & MTD_NO_ERASE) ?
master->writesize : master->erasesize;
struct mtd_info *master = mtd_get_master(parent);
int wr_alignment = (parent->flags & MTD_NO_ERASE) ?
master->writesize : master->erasesize;
u64 parent_size = mtd_is_partition(parent) ?
parent->part.size : parent->size;
struct mtd_info *child;
u64 parent_size = mtd_is_partition(parent) ?
parent->part.size : parent->size;
struct mtd_info *child;
-@@ -165,6 +166,7 @@ static struct mtd_info *allocate_partiti
+@@ -171,6 +172,7 @@ static struct mtd_info *allocate_partiti
} else {
/* Single erase size */
child->erasesize = master->erasesize;
} else {
/* Single erase size */
child->erasesize = master->erasesize;
-@@ -172,26 +174,39 @@ static struct mtd_info *allocate_partiti
+@@ -178,26 +180,39 @@ static struct mtd_info *allocate_partiti
* exposes several regions with different erasesize. Adjust
* wr_alignment accordingly.
*/
* exposes several regions with different erasesize. Adjust
* wr_alignment accordingly.
*/
default y
--- a/drivers/mtd/spi-nor/core.c
+++ b/drivers/mtd/spi-nor/core.c
default y
--- a/drivers/mtd/spi-nor/core.c
+++ b/drivers/mtd/spi-nor/core.c
-@@ -1050,6 +1050,8 @@ static u8 spi_nor_convert_3to4_erase(u8
+@@ -1150,6 +1150,8 @@ static u8 spi_nor_convert_3to4_erase(u8
static bool spi_nor_has_uniform_erase(const struct spi_nor *nor)
{
static bool spi_nor_has_uniform_erase(const struct spi_nor *nor)
{
return !!nor->params->erase_map.uniform_erase_type;
}
return !!nor->params->erase_map.uniform_erase_type;
}
-@@ -2158,6 +2160,7 @@ static int spi_nor_select_erase(struct s
+@@ -2582,6 +2584,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 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;
struct mtd_info *mtd = &nor->mtd;
u32 wanted_size = nor->info->sector_size;
int i;
-@@ -2190,8 +2193,9 @@ static int spi_nor_select_erase(struct s
+@@ -2614,8 +2617,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) {
*/
for (i = SNOR_ERASE_TYPE_MAX - 1; i >= 0; i--) {
if (map->erase_type[i].size) {
-@@ -2199,6 +2203,9 @@ static int spi_nor_select_erase(struct s
+@@ -2623,6 +2627,9 @@ static int spi_nor_select_erase(struct s
return -EINVAL;
mtd->erasesize = erase->size;
return -EINVAL;
mtd->erasesize = erase->size;
#include <linux/slab.h>
#include <linux/mtd/ubi.h>
#include <linux/blkdev.h>
#include <linux/slab.h>
#include <linux/mtd/ubi.h>
#include <linux/blkdev.h>
-@@ -67,10 +68,10 @@ struct ubiblock_pdu {
+@@ -65,10 +66,10 @@ struct ubiblock_pdu {
};
/* Numbers of elements set in the @ubiblock_param array */
};
/* Numbers of elements set in the @ubiblock_param array */
struct ubiblock {
struct ubi_volume_desc *desc;
struct ubiblock {
struct ubi_volume_desc *desc;
-@@ -504,7 +505,7 @@ int ubiblock_remove(struct ubi_volume_in
+@@ -469,7 +470,7 @@ int ubiblock_remove(struct ubi_volume_in
}
/* Found a device, let's lock it so we can check if it's busy */
}
/* Found a device, let's lock it so we can check if it's busy */
if (dev->refcnt > 0) {
ret = -EBUSY;
goto out_unlock_dev;
if (dev->refcnt > 0) {
ret = -EBUSY;
goto out_unlock_dev;
-@@ -567,6 +568,85 @@ static int ubiblock_resize(struct ubi_vo
+@@ -532,6 +533,85 @@ static int ubiblock_resize(struct ubi_vo
static int ubiblock_notify(struct notifier_block *nb,
unsigned long notification_type, void *ns_ptr)
{
static int ubiblock_notify(struct notifier_block *nb,
unsigned long notification_type, void *ns_ptr)
{
-@@ -574,10 +654,7 @@ static int ubiblock_notify(struct notifi
+@@ -539,10 +619,7 @@ static int ubiblock_notify(struct notifi
switch (notification_type) {
case UBI_VOLUME_ADDED:
switch (notification_type) {
case UBI_VOLUME_ADDED:
break;
case UBI_VOLUME_REMOVED:
ubiblock_remove(&nt->vi);
break;
case UBI_VOLUME_REMOVED:
ubiblock_remove(&nt->vi);
-@@ -603,56 +680,6 @@ static struct notifier_block ubiblock_no
+@@ -568,56 +645,6 @@ static struct notifier_block ubiblock_no
.notifier_call = ubiblock_notify,
};
.notifier_call = ubiblock_notify,
};
static void ubiblock_remove_all(void)
{
struct ubiblock *next;
static void ubiblock_remove_all(void)
{
struct ubiblock *next;
-@@ -678,18 +705,7 @@ int __init ubiblock_init(void)
+@@ -643,18 +670,7 @@ int __init ubiblock_init(void)
if (ubiblock_major < 0)
return ubiblock_major;
if (ubiblock_major < 0)
return ubiblock_major;
#include <linux/slab.h>
#include <linux/major.h>
#include "ubi.h"
#include <linux/slab.h>
#include <linux/major.h>
#include "ubi.h"
-@@ -1071,6 +1072,7 @@ out_free:
+@@ -1072,6 +1073,7 @@ out_free:
* ubi_detach_mtd_dev - detach an MTD device.
* @ubi_num: UBI device number to detach from
* @anyway: detach MTD even if device reference count is not zero
* ubi_detach_mtd_dev - detach an MTD device.
* @ubi_num: UBI device number to detach from
* @anyway: detach MTD even if device reference count is not zero
*
* This function destroys an UBI device number @ubi_num and detaches the
* underlying MTD device. Returns zero in case of success and %-EBUSY if the
*
* This function destroys an UBI device number @ubi_num and detaches the
* underlying MTD device. Returns zero in case of success and %-EBUSY if the
-@@ -1080,7 +1082,7 @@ out_free:
+@@ -1081,7 +1083,7 @@ out_free:
* Note, the invocations of this function has to be serialized by the
* @ubi_devices_mutex.
*/
* Note, the invocations of this function has to be serialized by the
* @ubi_devices_mutex.
*/
{
struct ubi_device *ubi;
{
struct ubi_device *ubi;
-@@ -1136,7 +1138,11 @@ int ubi_detach_mtd_dev(int ubi_num, int
+@@ -1137,7 +1139,11 @@ int ubi_detach_mtd_dev(int ubi_num, int
vfree(ubi->peb_buf);
vfree(ubi->fm_buf);
ubi_msg(ubi, "mtd%d is detached", ubi->mtd->index);
vfree(ubi->peb_buf);
vfree(ubi->fm_buf);
ubi_msg(ubi, "mtd%d is detached", ubi->mtd->index);
put_device(&ubi->dev);
return 0;
}
put_device(&ubi->dev);
return 0;
}
-@@ -1213,43 +1219,43 @@ static struct mtd_info * __init open_mtd
+@@ -1214,43 +1220,43 @@ static struct mtd_info * __init open_mtd
/* Attach MTD devices */
for (i = 0; i < mtd_devs; i++) {
/* Attach MTD devices */
for (i = 0; i < mtd_devs; i++) {
-@@ -1297,25 +1303,79 @@ static int __init ubi_init(void)
+@@ -1298,25 +1304,79 @@ static int __init ubi_init(void)
out_slab:
kmem_cache_destroy(ubi_wl_entry_slab);
out_dev_unreg:
out_slab:
kmem_cache_destroy(ubi_wl_entry_slab);
out_dev_unreg:
-@@ -1325,18 +1385,20 @@ out:
+@@ -1326,18 +1386,20 @@ out:
pr_err("UBI error: cannot initialize UBI, error %d\n", err);
return err;
}
pr_err("UBI error: cannot initialize UBI, error %d\n", err);
return err;
}
--- a/drivers/mtd/ubi/block.c
+++ b/drivers/mtd/ubi/block.c
--- a/drivers/mtd/ubi/block.c
+++ b/drivers/mtd/ubi/block.c
-@@ -568,6 +568,29 @@ static int ubiblock_resize(struct ubi_vo
+@@ -533,6 +533,29 @@ static int ubiblock_resize(struct ubi_vo
static bool
match_volume_desc(struct ubi_volume_info *vi, const char *name, int ubi_num, int vol_id)
{
static bool
match_volume_desc(struct ubi_volume_info *vi, const char *name, int ubi_num, int vol_id)
{
-@@ -659,6 +682,9 @@ static int ubiblock_notify(struct notifi
+@@ -624,6 +647,9 @@ static int ubiblock_notify(struct notifi
case UBI_VOLUME_REMOVED:
ubiblock_remove(&nt->vi);
break;
case UBI_VOLUME_REMOVED:
ubiblock_remove(&nt->vi);
break;
break;
--- a/drivers/mtd/ubi/build.c
+++ b/drivers/mtd/ubi/build.c
break;
--- a/drivers/mtd/ubi/build.c
+++ b/drivers/mtd/ubi/build.c
-@@ -89,7 +89,7 @@ static struct ubi_device *ubi_devices[UB
+@@ -91,7 +91,7 @@ static struct ubi_device *ubi_devices[UB
/* Serializes UBI devices creations and removals */
DEFINE_MUTEX(ubi_devices_mutex);
/* Serializes UBI devices creations and removals */
DEFINE_MUTEX(ubi_devices_mutex);
static DEFINE_SPINLOCK(ubi_devices_lock);
/* "Show" method for files in '/<sysfs>/class/ubi/' */
static DEFINE_SPINLOCK(ubi_devices_lock);
/* "Show" method for files in '/<sysfs>/class/ubi/' */
-@@ -258,6 +258,9 @@ struct ubi_device *ubi_get_device(int ub
+@@ -259,6 +259,9 @@ struct ubi_device *ubi_get_device(int ub
spin_lock(&ubi_devices_lock);
ubi = ubi_devices[ubi_num];
spin_lock(&ubi_devices_lock);
ubi = ubi_devices[ubi_num];
if (ubi) {
ubi_assert(ubi->ref_count >= 0);
ubi->ref_count += 1;
if (ubi) {
ubi_assert(ubi->ref_count >= 0);
ubi->ref_count += 1;
-@@ -295,7 +298,7 @@ struct ubi_device *ubi_get_by_major(int
+@@ -296,7 +299,7 @@ struct ubi_device *ubi_get_by_major(int
spin_lock(&ubi_devices_lock);
for (i = 0; i < UBI_MAX_DEVICES; i++) {
ubi = ubi_devices[i];
spin_lock(&ubi_devices_lock);
for (i = 0; i < UBI_MAX_DEVICES; i++) {
ubi = ubi_devices[i];
ubi_assert(ubi->ref_count >= 0);
ubi->ref_count += 1;
get_device(&ubi->dev);
ubi_assert(ubi->ref_count >= 0);
ubi->ref_count += 1;
get_device(&ubi->dev);
-@@ -324,7 +327,7 @@ int ubi_major2num(int major)
+@@ -325,7 +328,7 @@ int ubi_major2num(int major)
for (i = 0; i < UBI_MAX_DEVICES; i++) {
struct ubi_device *ubi = ubi_devices[i];
for (i = 0; i < UBI_MAX_DEVICES; i++) {
struct ubi_device *ubi = ubi_devices[i];
ubi_num = ubi->ubi_num;
break;
}
ubi_num = ubi->ubi_num;
break;
}
-@@ -511,7 +514,7 @@ static void ubi_free_volumes_from(struct
+@@ -512,7 +515,7 @@ static void ubi_free_volumes_from(struct
int i;
for (i = from; i < ubi->vtbl_slots + UBI_INT_VOL_COUNT; i++) {
int i;
for (i = from; i < ubi->vtbl_slots + UBI_INT_VOL_COUNT; i++) {
continue;
ubi_eba_replace_table(ubi->volumes[i], NULL);
ubi_fastmap_destroy_checkmap(ubi->volumes[i]);
continue;
ubi_eba_replace_table(ubi->volumes[i], NULL);
ubi_fastmap_destroy_checkmap(ubi->volumes[i]);
-@@ -1094,10 +1097,10 @@ int ubi_detach_mtd_dev(int ubi_num, int
+@@ -1095,10 +1098,10 @@ int ubi_detach_mtd_dev(int ubi_num, int
return -EINVAL;
spin_lock(&ubi_devices_lock);
return -EINVAL;
spin_lock(&ubi_devices_lock);
spin_unlock(&ubi_devices_lock);
return -EBUSY;
}
spin_unlock(&ubi_devices_lock);
return -EBUSY;
}
-@@ -1105,6 +1108,13 @@ int ubi_detach_mtd_dev(int ubi_num, int
+@@ -1106,6 +1109,13 @@ int ubi_detach_mtd_dev(int ubi_num, int
ubi_err(ubi, "%s reference count %d, destroy anyway",
ubi->ubi_name, ubi->ref_count);
}
ubi_err(ubi, "%s reference count %d, destroy anyway",
ubi->ubi_name, ubi->ref_count);
}
#include "check.h"
static int (*const check_part[])(struct parsed_partitions *) = {
#include "check.h"
static int (*const check_part[])(struct parsed_partitions *) = {
-@@ -298,6 +300,43 @@ static ssize_t whole_disk_show(struct de
+@@ -292,6 +294,43 @@ static ssize_t whole_disk_show(struct de
}
static const DEVICE_ATTR(whole_disk, 0444, whole_disk_show, NULL);
}
static const DEVICE_ATTR(whole_disk, 0444, whole_disk_show, NULL);
/*
* Must be called either with open_mutex held, before a disk can be opened or
* after all disk users are gone.
/*
* Must be called either with open_mutex held, before a disk can be opened or
* after all disk users are gone.
-@@ -380,6 +419,8 @@ static struct block_device *add_partitio
+@@ -374,6 +413,8 @@ static struct block_device *add_partitio
--- a/include/linux/blkdev.h
+++ b/include/linux/blkdev.h
--- a/include/linux/blkdev.h
+++ b/include/linux/blkdev.h
-@@ -87,11 +87,13 @@ struct partition_meta_info {
+@@ -80,11 +80,13 @@ struct partition_meta_info {
* ``GENHD_FL_NO_PART``: partition support is disabled. The kernel will not
* scan for partitions from add_disk, and users can't add partitions manually.
*
* ``GENHD_FL_NO_PART``: partition support is disabled. The kernel will not
* scan for partitions from add_disk, and users can't add partitions manually.
*
--- a/block/Kconfig
+++ b/block/Kconfig
--- a/block/Kconfig
+++ b/block/Kconfig
-@@ -203,6 +203,15 @@ config BLK_INLINE_ENCRYPTION_FALLBACK
+@@ -208,6 +208,15 @@ config BLK_INLINE_ENCRYPTION_FALLBACK
by falling back to the kernel crypto API when inline
encryption hardware is not present.
by falling back to the kernel crypto API when inline
encryption hardware is not present.
config BLK_MQ_PCI
--- a/block/Makefile
+++ b/block/Makefile
config BLK_MQ_PCI
--- a/block/Makefile
+++ b/block/Makefile
-@@ -35,6 +35,7 @@ obj-$(CONFIG_BLK_DEV_ZONED) += blk-zoned
+@@ -34,6 +34,7 @@ obj-$(CONFIG_BLK_DEV_ZONED) += blk-zoned
obj-$(CONFIG_BLK_WBT) += blk-wbt.o
obj-$(CONFIG_BLK_DEBUG_FS) += blk-mq-debugfs.o
obj-$(CONFIG_BLK_DEBUG_FS_ZONED)+= blk-mq-debugfs-zoned.o
obj-$(CONFIG_BLK_WBT) += blk-wbt.o
obj-$(CONFIG_BLK_DEBUG_FS) += blk-mq-debugfs.o
obj-$(CONFIG_BLK_DEBUG_FS_ZONED)+= blk-mq-debugfs-zoned.o
--- a/drivers/mmc/core/bus.c
+++ b/drivers/mmc/core/bus.c
--- a/drivers/mmc/core/bus.c
+++ b/drivers/mmc/core/bus.c
-@@ -363,6 +363,8 @@ int mmc_add_card(struct mmc_card *card)
+@@ -364,6 +364,8 @@ int mmc_add_card(struct mmc_card *card)
mmc_add_card_debugfs(card);
card->dev.of_node = mmc_of_find_child_device(card->host, 0);
mmc_add_card_debugfs(card);
card->dev.of_node = mmc_of_find_child_device(card->host, 0);
--- a/drivers/mmc/core/block.c
+++ b/drivers/mmc/core/block.c
--- a/drivers/mmc/core/block.c
+++ b/drivers/mmc/core/block.c
-@@ -2484,6 +2484,8 @@ static struct mmc_blk_data *mmc_blk_allo
+@@ -2461,6 +2461,8 @@ static struct mmc_blk_data *mmc_blk_allo
int area_type,
unsigned int part_type)
{
int area_type,
unsigned int part_type)
{
struct mmc_blk_data *md;
int devidx, ret;
char cap_str[10];
struct mmc_blk_data *md;
int devidx, ret;
char cap_str[10];
-@@ -2580,6 +2582,13 @@ static struct mmc_blk_data *mmc_blk_allo
+@@ -2557,6 +2559,13 @@ static struct mmc_blk_data *mmc_blk_allo
blk_queue_write_cache(md->queue.queue, cache_enabled, fua_enabled);
blk_queue_write_cache(md->queue.queue, cache_enabled, fua_enabled);
--- a/drivers/mmc/core/block.c
+++ b/drivers/mmc/core/block.c
--- a/drivers/mmc/core/block.c
+++ b/drivers/mmc/core/block.c
-@@ -2538,6 +2538,7 @@ static struct mmc_blk_data *mmc_blk_allo
+@@ -2515,6 +2515,7 @@ static struct mmc_blk_data *mmc_blk_allo
md->disk->major = MMC_BLOCK_MAJOR;
md->disk->minors = perdev_minors;
md->disk->first_minor = devidx * perdev_minors;
md->disk->major = MMC_BLOCK_MAJOR;
md->disk->minors = perdev_minors;
md->disk->first_minor = devidx * perdev_minors;
--- a/drivers/mtd/chips/cfi_cmdset_0002.c
+++ b/drivers/mtd/chips/cfi_cmdset_0002.c
--- a/drivers/mtd/chips/cfi_cmdset_0002.c
+++ b/drivers/mtd/chips/cfi_cmdset_0002.c
-@@ -908,7 +908,7 @@ static int get_chip(struct map_info *map
+@@ -906,7 +906,7 @@ static int get_chip(struct map_info *map
return 0;
case FL_ERASING:
return 0;
case FL_ERASING:
1 file changed, 1 insertion(+)
--- a/drivers/mtd/chips/cfi_cmdset_0002.c
+++ b/drivers/mtd/chips/cfi_cmdset_0002.c
1 file changed, 1 insertion(+)
--- a/drivers/mtd/chips/cfi_cmdset_0002.c
+++ b/drivers/mtd/chips/cfi_cmdset_0002.c
-@@ -2052,6 +2052,7 @@ static int __xipram do_write_buffer(stru
+@@ -2050,6 +2050,7 @@ static int __xipram do_write_buffer(stru
/* Write Buffer Load */
map_write(map, CMD(0x25), cmd_adr);
/* Write Buffer Load */
map_write(map, CMD(0x25), cmd_adr);
--- a/drivers/mtd/spi-nor/macronix.c
+++ b/drivers/mtd/spi-nor/macronix.c
--- a/drivers/mtd/spi-nor/macronix.c
+++ b/drivers/mtd/spi-nor/macronix.c
-@@ -115,6 +115,7 @@ static void macronix_nor_default_init(st
+@@ -114,6 +114,7 @@ static int macronix_nor_late_init(struct
{
if (!nor->params->set_4byte_addr_mode)
nor->params->set_4byte_addr_mode = spi_nor_set_4byte_addr_mode_en4b_ex4b;
{
if (!nor->params->set_4byte_addr_mode)
nor->params->set_4byte_addr_mode = spi_nor_set_4byte_addr_mode_en4b_ex4b;
+};
--- a/drivers/mtd/spi-nor/core.c
+++ b/drivers/mtd/spi-nor/core.c
+};
--- a/drivers/mtd/spi-nor/core.c
+++ b/drivers/mtd/spi-nor/core.c
-@@ -1636,6 +1636,7 @@ static const struct spi_nor_manufacturer
+@@ -2017,6 +2017,7 @@ static const struct spi_nor_manufacturer
&spi_nor_winbond,
&spi_nor_xilinx,
&spi_nor_xmc,
&spi_nor_winbond,
&spi_nor_xilinx,
&spi_nor_xmc,
static const struct flash_info spi_nor_generic_flash = {
--- a/drivers/mtd/spi-nor/core.h
+++ b/drivers/mtd/spi-nor/core.h
static const struct flash_info spi_nor_generic_flash = {
--- a/drivers/mtd/spi-nor/core.h
+++ b/drivers/mtd/spi-nor/core.h
-@@ -633,6 +633,7 @@ extern const struct spi_nor_manufacturer
+@@ -647,6 +647,7 @@ extern const struct spi_nor_manufacturer
extern const struct spi_nor_manufacturer spi_nor_winbond;
extern const struct spi_nor_manufacturer spi_nor_xilinx;
extern const struct spi_nor_manufacturer spi_nor_xmc;
extern const struct spi_nor_manufacturer spi_nor_winbond;
extern const struct spi_nor_manufacturer spi_nor_xilinx;
extern const struct spi_nor_manufacturer spi_nor_xmc;
--- a/drivers/mtd/ubi/build.c
+++ b/drivers/mtd/ubi/build.c
--- a/drivers/mtd/ubi/build.c
+++ b/drivers/mtd/ubi/build.c
-@@ -1263,6 +1263,74 @@ static struct mtd_notifier ubi_mtd_notif
+@@ -1264,6 +1264,74 @@ static struct mtd_notifier ubi_mtd_notif
.remove = ubi_notify_remove,
};
.remove = ubi_notify_remove,
};
static int __init ubi_init_attach(void)
{
int err, i, k;
static int __init ubi_init_attach(void)
{
int err, i, k;
-@@ -1313,6 +1381,12 @@ static int __init ubi_init_attach(void)
+@@ -1314,6 +1382,12 @@ static int __init ubi_init_attach(void)
--- a/drivers/mtd/ubi/block.c
+++ b/drivers/mtd/ubi/block.c
--- a/drivers/mtd/ubi/block.c
+++ b/drivers/mtd/ubi/block.c
-@@ -644,10 +644,47 @@ match_volume_desc(struct ubi_volume_info
+@@ -609,10 +609,47 @@ match_volume_desc(struct ubi_volume_info
struct ubiblock_param *p;
/*
struct ubiblock_param *p;
/*
-@@ -660,6 +697,7 @@ ubiblock_create_from_param(struct ubi_vo
+@@ -625,6 +662,7 @@ ubiblock_create_from_param(struct ubi_vo
if (!match_volume_desc(vi, p->name, p->ubi_num, p->vol_id))
continue;
if (!match_volume_desc(vi, p->name, p->ubi_num, p->vol_id))
continue;
ret = ubiblock_create(vi);
if (ret) {
pr_err(
ret = ubiblock_create(vi);
if (ret) {
pr_err(
-@@ -668,6 +706,10 @@ ubiblock_create_from_param(struct ubi_vo
+@@ -633,6 +671,10 @@ ubiblock_create_from_param(struct ubi_vo
--- a/init/do_mounts.c
+++ b/init/do_mounts.c
--- a/init/do_mounts.c
+++ b/init/do_mounts.c
-@@ -446,7 +446,30 @@ retry:
+@@ -248,7 +248,30 @@ retry:
#ifdef CONFIG_ROOT_NFS
#define NFSROOT_TIMEOUT_MIN 5
#ifdef CONFIG_ROOT_NFS
#define NFSROOT_TIMEOUT_MIN 5
-@@ -408,6 +408,11 @@ void __init mount_root(void)
+@@ -385,6 +408,11 @@ static inline void mount_block_root(char
void __init mount_root(char *root_device_name)
{
void __init mount_root(char *root_device_name)
{
--- a/drivers/mtd/ubi/block.c
+++ b/drivers/mtd/ubi/block.c
--- a/drivers/mtd/ubi/block.c
+++ b/drivers/mtd/ubi/block.c
#include <linux/scatterlist.h>
#include <linux/idr.h>
#include <asm/div64.h>
#include <linux/scatterlist.h>
#include <linux/idr.h>
#include <asm/div64.h>
#include "ubi-media.h"
#include "ubi.h"
#include "ubi-media.h"
#include "ubi.h"
-@@ -460,6 +461,15 @@ int ubiblock_create(struct ubi_volume_in
+@@ -429,6 +430,15 @@ int ubiblock_create(struct ubi_volume_in
dev_info(disk_to_dev(dev->gd), "created from ubi%d:%d(%s)",
dev->ubi_num, dev->vol_id, vi->name);
mutex_unlock(&devices_mutex);
dev_info(disk_to_dev(dev->gd), "created from ubi%d:%d(%s)",
dev->ubi_num, dev->vol_id, vi->name);
mutex_unlock(&devices_mutex);
--- a/drivers/mtd/spi-nor/macronix.c
+++ b/drivers/mtd/spi-nor/macronix.c
--- a/drivers/mtd/spi-nor/macronix.c
+++ b/drivers/mtd/spi-nor/macronix.c
-@@ -115,6 +115,7 @@ static void macronix_nor_default_init(st
+@@ -115,6 +115,7 @@ static int macronix_nor_late_init(struct
{
if (!nor->params->set_4byte_addr_mode)
nor->params->set_4byte_addr_mode = spi_nor_set_4byte_addr_mode_en4b_ex4b;
{
if (!nor->params->set_4byte_addr_mode)
nor->params->set_4byte_addr_mode = spi_nor_set_4byte_addr_mode_en4b_ex4b;
--- a/MAINTAINERS
+++ b/MAINTAINERS
--- a/MAINTAINERS
+++ b/MAINTAINERS
-@@ -21052,6 +21052,12 @@ F: Documentation/filesystems/ubifs-authe
+@@ -22006,6 +22006,12 @@ F: Documentation/filesystems/ubifs-authe
F: Documentation/filesystems/ubifs.rst
F: fs/ubifs/
F: Documentation/filesystems/ubifs.rst
F: fs/ubifs/
L: linux-block@vger.kernel.org
--- a/drivers/block/Kconfig
+++ b/drivers/block/Kconfig
L: linux-block@vger.kernel.org
--- a/drivers/block/Kconfig
+++ b/drivers/block/Kconfig
-@@ -383,6 +383,18 @@ config VIRTIO_BLK
+@@ -354,6 +354,18 @@ config VIRTIO_BLK
This is the virtual block driver for virtio. It can be used with
QEMU based VMMs (like KVM or Xen). Say Y or M.
This is the virtual block driver for virtio. It can be used with
QEMU based VMMs (like KVM or Xen). Say Y or M.
--- a/init/do_mounts.c
+++ b/init/do_mounts.c
--- a/init/do_mounts.c
+++ b/init/do_mounts.c
-@@ -463,7 +463,8 @@ static dev_t __init parse_root_device(char
+@@ -463,7 +463,8 @@ static dev_t __init parse_root_device(ch
exit_dynrubin:
jffs2_dynrubin_exit();
exit_runinmips:
exit_dynrubin:
jffs2_dynrubin_exit();
exit_runinmips:
-@@ -417,6 +422,7 @@ int __init jffs2_compressors_init(void)
+@@ -417,6 +422,7 @@ exit:
int jffs2_compressors_exit(void)
{
/* Unregistering compressors */
int jffs2_compressors_exit(void)
{
/* Unregistering compressors */
#define JFFS2_NODE_ACCURATE 0x2000
--- a/lib/Kconfig
+++ b/lib/Kconfig
#define JFFS2_NODE_ACCURATE 0x2000
--- a/lib/Kconfig
+++ b/lib/Kconfig
-@@ -354,6 +354,12 @@ config ZSTD_DECOMPRESS
+@@ -356,6 +356,12 @@ config ZSTD_DECOMPRESS
# ZLIB_INFLATE; DECOMPRESS_GZIP is just a wrapper.)
--- a/lib/Makefile
+++ b/lib/Makefile
# ZLIB_INFLATE; DECOMPRESS_GZIP is just a wrapper.)
--- a/lib/Makefile
+++ b/lib/Makefile
-@@ -140,6 +140,16 @@ CFLAGS_kobject.o += -DDEBUG
+@@ -145,6 +145,16 @@ CFLAGS_kobject.o += -DDEBUG
CFLAGS_kobject_uevent.o += -DDEBUG
endif
CFLAGS_kobject_uevent.o += -DDEBUG
endif
obj-$(CONFIG_DEBUG_INFO_REDUCED) += debug_info.o
CFLAGS_debug_info.o += $(call cc-option, -femit-struct-debug-detailed=any)
obj-$(CONFIG_DEBUG_INFO_REDUCED) += debug_info.o
CFLAGS_debug_info.o += $(call cc-option, -femit-struct-debug-detailed=any)
-@@ -200,6 +210,8 @@ obj-$(CONFIG_ZSTD_COMPRESS) += zstd/
+@@ -205,6 +215,8 @@ obj-$(CONFIG_ZSTD_COMPRESS) += zstd/
obj-$(CONFIG_ZSTD_DECOMPRESS) += zstd/
obj-$(CONFIG_XZ_DEC) += xz/
obj-$(CONFIG_RAID6_PQ) += raid6/
obj-$(CONFIG_ZSTD_DECOMPRESS) += zstd/
obj-$(CONFIG_XZ_DEC) += xz/
obj-$(CONFIG_RAID6_PQ) += raid6/
#include <net/net_namespace.h>
#ifdef CONFIG_SYSCTL
#include <linux/sysctl.h>
#include <net/net_namespace.h>
#ifdef CONFIG_SYSCTL
#include <linux/sysctl.h>
-@@ -465,6 +466,58 @@ static int ct_cpu_seq_show(struct seq_fi
+@@ -461,6 +462,58 @@ static int ct_cpu_seq_show(struct seq_fi
static const struct seq_operations ct_cpu_seq_ops = {
.start = ct_cpu_seq_start,
.next = ct_cpu_seq_next,
static const struct seq_operations ct_cpu_seq_ops = {
.start = ct_cpu_seq_start,
.next = ct_cpu_seq_next,
-@@ -478,8 +531,9 @@ static int nf_conntrack_standalone_init_
+@@ -474,8 +527,9 @@ static int nf_conntrack_standalone_init_
kuid_t root_uid;
kgid_t root_gid;
kuid_t root_uid;
kgid_t root_gid;
#define IPT_INV_VIA_IN 0x01 /* Invert the sense of IN IFACE. */
--- a/net/ipv4/netfilter/ip_tables.c
+++ b/net/ipv4/netfilter/ip_tables.c
#define IPT_INV_VIA_IN 0x01 /* Invert the sense of IN IFACE. */
--- a/net/ipv4/netfilter/ip_tables.c
+++ b/net/ipv4/netfilter/ip_tables.c
-@@ -50,6 +50,9 @@ ip_packet_match(const struct iphdr *ip,
+@@ -48,6 +48,9 @@ ip_packet_match(const struct iphdr *ip,
if (NF_INVF(ipinfo, IPT_INV_SRCIP,
(ip->saddr & ipinfo->smsk.s_addr) != ipinfo->src.s_addr) ||
NF_INVF(ipinfo, IPT_INV_DSTIP,
if (NF_INVF(ipinfo, IPT_INV_SRCIP,
(ip->saddr & ipinfo->smsk.s_addr) != ipinfo->src.s_addr) ||
NF_INVF(ipinfo, IPT_INV_DSTIP,
-@@ -80,6 +83,29 @@ ip_packet_match(const struct iphdr *ip,
+@@ -78,6 +81,29 @@ ip_packet_match(const struct iphdr *ip,
static bool
ip_checkentry(const struct ipt_ip *ip)
{
static bool
ip_checkentry(const struct ipt_ip *ip)
{
-@@ -525,6 +551,8 @@ find_check_entry(struct ipt_entry *e, st
+@@ -523,6 +549,8 @@ find_check_entry(struct ipt_entry *e, st
struct xt_mtchk_param mtpar;
struct xt_entry_match *ematch;
struct xt_mtchk_param mtpar;
struct xt_entry_match *ematch;
if (!xt_percpu_counter_alloc(alloc_state, &e->counters))
return -ENOMEM;
if (!xt_percpu_counter_alloc(alloc_state, &e->counters))
return -ENOMEM;
-@@ -819,6 +847,7 @@ copy_entries_to_user(unsigned int total_
+@@ -817,6 +845,7 @@ copy_entries_to_user(unsigned int total_
const struct xt_table_info *private = table->private;
int ret = 0;
const void *loc_cpu_entry;
const struct xt_table_info *private = table->private;
int ret = 0;
const void *loc_cpu_entry;
counters = alloc_counters(table);
if (IS_ERR(counters))
counters = alloc_counters(table);
if (IS_ERR(counters))
-@@ -846,6 +875,14 @@ copy_entries_to_user(unsigned int total_
+@@ -844,6 +873,14 @@ copy_entries_to_user(unsigned int total_
for (i = sizeof(struct ipt_entry);
i < e->target_offset;
i += m->u.match_size) {
for (i = sizeof(struct ipt_entry);
i < e->target_offset;
i += m->u.match_size) {
-@@ -1223,12 +1260,15 @@ compat_copy_entry_to_user(struct ipt_ent
+@@ -1221,12 +1258,15 @@ compat_copy_entry_to_user(struct ipt_ent
compat_uint_t origsize;
const struct xt_entry_match *ematch;
int ret = 0;
compat_uint_t origsize;
const struct xt_entry_match *ematch;
int ret = 0;
--- a/net/ipv4/netfilter/ip_tables.c
+++ b/net/ipv4/netfilter/ip_tables.c
--- a/net/ipv4/netfilter/ip_tables.c
+++ b/net/ipv4/netfilter/ip_tables.c
-@@ -246,6 +246,33 @@ struct ipt_entry *ipt_next_entry(const s
+@@ -244,6 +244,33 @@ struct ipt_entry *ipt_next_entry(const s
return (void *)entry + entry->next_offset;
}
return (void *)entry + entry->next_offset;
}
/* Returns one of the generic firewall policies, like NF_ACCEPT. */
unsigned int
ipt_do_table(void *priv,
/* Returns one of the generic firewall policies, like NF_ACCEPT. */
unsigned int
ipt_do_table(void *priv,
-@@ -267,27 +294,28 @@ ipt_do_table(void *priv,
+@@ -265,27 +292,28 @@ ipt_do_table(void *priv,
unsigned int addend;
/* Initialization */
unsigned int addend;
/* Initialization */
jumpstack = (struct ipt_entry **)private->jumpstack[cpu];
/* Switch to alternate jumpstack if we're being invoked via TEE.
jumpstack = (struct ipt_entry **)private->jumpstack[cpu];
/* Switch to alternate jumpstack if we're being invoked via TEE.
-@@ -300,7 +328,16 @@ ipt_do_table(void *priv,
+@@ -298,7 +326,16 @@ ipt_do_table(void *priv,
if (static_key_false(&xt_tee_enabled))
jumpstack += private->stacksize * __this_cpu_read(nf_skb_duplicated);
if (static_key_false(&xt_tee_enabled))
jumpstack += private->stacksize * __this_cpu_read(nf_skb_duplicated);
--- a/net/ipv4/netfilter/ip_tables.c
+++ b/net/ipv4/netfilter/ip_tables.c
--- a/net/ipv4/netfilter/ip_tables.c
+++ b/net/ipv4/netfilter/ip_tables.c
-@@ -53,9 +53,9 @@ ip_packet_match(const struct iphdr *ip,
+@@ -51,9 +51,9 @@ ip_packet_match(const struct iphdr *ip,
if (ipinfo->flags & IPT_F_NO_DEF_MATCH)
return true;
if (ipinfo->flags & IPT_F_NO_DEF_MATCH)
return true;
/* Packet socket options */
/* Packet socket options */
-@@ -59,6 +61,7 @@ struct sockaddr_ll {
+@@ -60,6 +62,7 @@ struct sockaddr_ll {
#define PACKET_FANOUT_DATA 22
#define PACKET_IGNORE_OUTGOING 23
#define PACKET_VNET_HDR_SZ 24
#define PACKET_FANOUT_DATA 22
#define PACKET_IGNORE_OUTGOING 23
#define PACKET_VNET_HDR_SZ 24
#define PACKET_FANOUT_LB 1
--- a/net/packet/af_packet.c
+++ b/net/packet/af_packet.c
#define PACKET_FANOUT_LB 1
--- a/net/packet/af_packet.c
+++ b/net/packet/af_packet.c
-@@ -1866,6 +1866,7 @@ static int packet_rcv_spkt(struct sk_buf
+@@ -1864,6 +1864,7 @@ static int packet_rcv_spkt(struct sk_buf
{
struct sock *sk;
struct sockaddr_pkt *spkt;
{
struct sock *sk;
struct sockaddr_pkt *spkt;
/*
* When we registered the protocol we saved the socket in the data
/*
* When we registered the protocol we saved the socket in the data
-@@ -1873,6 +1874,7 @@ static int packet_rcv_spkt(struct sk_buf
+@@ -1871,6 +1872,7 @@ static int packet_rcv_spkt(struct sk_buf
*/
sk = pt->af_packet_priv;
*/
sk = pt->af_packet_priv;
/*
* Yank back the headers [hope the device set this
/*
* Yank back the headers [hope the device set this
-@@ -1885,7 +1887,7 @@ static int packet_rcv_spkt(struct sk_buf
+@@ -1883,7 +1885,7 @@ static int packet_rcv_spkt(struct sk_buf
* so that this procedure is noop.
*/
* so that this procedure is noop.
*/
goto out;
if (!net_eq(dev_net(dev), sock_net(sk)))
goto out;
if (!net_eq(dev_net(dev), sock_net(sk)))
-@@ -2131,12 +2133,12 @@ static int packet_rcv(struct sk_buff *sk
+@@ -2129,12 +2131,12 @@ static int packet_rcv(struct sk_buff *sk
unsigned int snaplen, res;
bool is_drop_n_account = false;
unsigned int snaplen, res;
bool is_drop_n_account = false;
if (!net_eq(dev_net(dev), sock_net(sk)))
goto drop;
if (!net_eq(dev_net(dev), sock_net(sk)))
goto drop;
-@@ -2263,12 +2265,12 @@ static int tpacket_rcv(struct sk_buff *s
+@@ -2261,12 +2263,12 @@ static int tpacket_rcv(struct sk_buff *s
BUILD_BUG_ON(TPACKET_ALIGN(sizeof(*h.h2)) != 32);
BUILD_BUG_ON(TPACKET_ALIGN(sizeof(*h.h3)) != 48);
BUILD_BUG_ON(TPACKET_ALIGN(sizeof(*h.h2)) != 32);
BUILD_BUG_ON(TPACKET_ALIGN(sizeof(*h.h3)) != 48);
if (!net_eq(dev_net(dev), sock_net(sk)))
goto drop;
if (!net_eq(dev_net(dev), sock_net(sk)))
goto drop;
-@@ -3378,6 +3380,7 @@ static int packet_create(struct net *net
+@@ -3386,6 +3388,7 @@ static int packet_create(struct net *net
mutex_init(&po->pg_vec_lock);
po->rollover = NULL;
po->prot_hook.func = packet_rcv;
mutex_init(&po->pg_vec_lock);
po->rollover = NULL;
po->prot_hook.func = packet_rcv;
if (sock->type == SOCK_PACKET)
po->prot_hook.func = packet_rcv_spkt;
if (sock->type == SOCK_PACKET)
po->prot_hook.func = packet_rcv_spkt;
-@@ -4013,6 +4016,16 @@ packet_setsockopt(struct socket *sock, i
+@@ -4035,6 +4038,16 @@ packet_setsockopt(struct socket *sock, i
packet_sock_flag_set(po, PACKET_SOCK_QDISC_BYPASS, val);
return 0;
}
packet_sock_flag_set(po, PACKET_SOCK_QDISC_BYPASS, val);
return 0;
}
default:
return -ENOPROTOOPT;
}
default:
return -ENOPROTOOPT;
}
-@@ -4069,6 +4082,13 @@ static int packet_getsockopt(struct sock
+@@ -4094,6 +4107,13 @@ static int packet_getsockopt(struct sock
case PACKET_VNET_HDR_SZ:
val = READ_ONCE(po->vnet_hdr_sz);
break;
case PACKET_VNET_HDR_SZ:
val = READ_ONCE(po->vnet_hdr_sz);
break;
break;
--- a/net/packet/internal.h
+++ b/net/packet/internal.h
break;
--- a/net/packet/internal.h
+++ b/net/packet/internal.h
-@@ -136,6 +136,7 @@ struct packet_sock {
+@@ -131,6 +131,7 @@ struct packet_sock {
struct net_device __rcu *cached_dev;
struct packet_type prot_hook ____cacheline_aligned_in_smp;
atomic_t tp_drops ____cacheline_aligned_in_smp;
struct net_device __rcu *cached_dev;
struct packet_type prot_hook ____cacheline_aligned_in_smp;
atomic_t tp_drops ____cacheline_aligned_in_smp;
--- a/include/linux/skbuff.h
+++ b/include/linux/skbuff.h
--- a/include/linux/skbuff.h
+++ b/include/linux/skbuff.h
-@@ -3006,7 +3006,7 @@ static inline int pskb_network_may_pull(
+@@ -3041,7 +3041,7 @@ static inline int pskb_network_may_pull(
* NET_IP_ALIGN(2) + ethernet_header(14) + IP_header(20/40) + ports(8)
*/
#ifndef NET_SKB_PAD
* NET_IP_ALIGN(2) + ethernet_header(14) + IP_header(20/40) + ports(8)
*/
#ifndef NET_SKB_PAD
/**
* ip6_tnl_addr_conflict - compare packet addresses to tunnel's own
* @t: the outgoing tunnel device
/**
* ip6_tnl_addr_conflict - compare packet addresses to tunnel's own
* @t: the outgoing tunnel device
-@@ -1293,6 +1441,7 @@ ipxip6_tnl_xmit(struct sk_buff *skb, str
+@@ -1292,6 +1440,7 @@ ipxip6_tnl_xmit(struct sk_buff *skb, str
u8 protocol)
{
struct ip6_tnl *t = netdev_priv(dev);
u8 protocol)
{
struct ip6_tnl *t = netdev_priv(dev);
struct ipv6hdr *ipv6h;
const struct iphdr *iph;
int encap_limit = -1;
struct ipv6hdr *ipv6h;
const struct iphdr *iph;
int encap_limit = -1;
-@@ -1392,6 +1541,18 @@ ipxip6_tnl_xmit(struct sk_buff *skb, str
+@@ -1391,6 +1540,18 @@ ipxip6_tnl_xmit(struct sk_buff *skb, str
fl6.flowi6_uid = sock_net_uid(dev_net(dev), NULL);
dsfield = INET_ECN_encapsulate(dsfield, orig_dsfield);
fl6.flowi6_uid = sock_net_uid(dev_net(dev), NULL);
dsfield = INET_ECN_encapsulate(dsfield, orig_dsfield);
if (iptunnel_handle_offloads(skb, SKB_GSO_IPXIP6))
return -1;
if (iptunnel_handle_offloads(skb, SKB_GSO_IPXIP6))
return -1;
-@@ -1545,6 +1706,14 @@ ip6_tnl_change(struct ip6_tnl *t, const
+@@ -1543,6 +1704,14 @@ ip6_tnl_change(struct ip6_tnl *t, const
t->parms.link = p->link;
t->parms.proto = p->proto;
t->parms.fwmark = p->fwmark;
t->parms.link = p->link;
t->parms.proto = p->proto;
t->parms.fwmark = p->fwmark;
dst_cache_reset(&t->dst_cache);
ip6_tnl_link_config(t);
}
dst_cache_reset(&t->dst_cache);
ip6_tnl_link_config(t);
}
-@@ -1579,6 +1748,7 @@ ip6_tnl_parm_from_user(struct __ip6_tnl_
+@@ -1577,6 +1746,7 @@ ip6_tnl_parm_from_user(struct __ip6_tnl_
p->flowinfo = u->flowinfo;
p->link = u->link;
p->proto = u->proto;
p->flowinfo = u->flowinfo;
p->link = u->link;
p->proto = u->proto;
memcpy(p->name, u->name, sizeof(u->name));
}
memcpy(p->name, u->name, sizeof(u->name));
}
-@@ -1965,6 +2135,15 @@ static int ip6_tnl_validate(struct nlatt
+@@ -1963,6 +2133,15 @@ static int ip6_tnl_validate(struct nlatt
static void ip6_tnl_netlink_parms(struct nlattr *data[],
struct __ip6_tnl_parm *parms)
{
static void ip6_tnl_netlink_parms(struct nlattr *data[],
struct __ip6_tnl_parm *parms)
{
-@@ -2002,6 +2181,46 @@ static void ip6_tnl_netlink_parms(struct
+@@ -2000,6 +2179,46 @@ static void ip6_tnl_netlink_parms(struct
if (data[IFLA_IPTUN_FWMARK])
parms->fwmark = nla_get_u32(data[IFLA_IPTUN_FWMARK]);
if (data[IFLA_IPTUN_FWMARK])
parms->fwmark = nla_get_u32(data[IFLA_IPTUN_FWMARK]);
}
static int ip6_tnl_newlink(struct net *src_net, struct net_device *dev,
}
static int ip6_tnl_newlink(struct net *src_net, struct net_device *dev,
-@@ -2085,6 +2304,12 @@ static void ip6_tnl_dellink(struct net_d
+@@ -2083,6 +2302,12 @@ static void ip6_tnl_dellink(struct net_d
static size_t ip6_tnl_get_size(const struct net_device *dev)
{
static size_t ip6_tnl_get_size(const struct net_device *dev)
{
return
/* IFLA_IPTUN_LINK */
nla_total_size(4) +
return
/* IFLA_IPTUN_LINK */
nla_total_size(4) +
-@@ -2114,6 +2339,24 @@ static size_t ip6_tnl_get_size(const str
+@@ -2112,6 +2337,24 @@ static size_t ip6_tnl_get_size(const str
nla_total_size(0) +
/* IFLA_IPTUN_FWMARK */
nla_total_size(4) +
nla_total_size(0) +
/* IFLA_IPTUN_FWMARK */
nla_total_size(4) +
-@@ -2121,6 +2364,9 @@ static int ip6_tnl_fill_info(struct sk_b
+@@ -2119,6 +2362,9 @@ static int ip6_tnl_fill_info(struct sk_b
{
struct ip6_tnl *tunnel = netdev_priv(dev);
struct __ip6_tnl_parm *parm = &tunnel->parms;
{
struct ip6_tnl *tunnel = netdev_priv(dev);
struct __ip6_tnl_parm *parm = &tunnel->parms;
if (nla_put_u32(skb, IFLA_IPTUN_LINK, parm->link) ||
nla_put_in6_addr(skb, IFLA_IPTUN_LOCAL, &parm->laddr) ||
if (nla_put_u32(skb, IFLA_IPTUN_LINK, parm->link) ||
nla_put_in6_addr(skb, IFLA_IPTUN_LOCAL, &parm->laddr) ||
-@@ -2130,9 +2376,27 @@ static int ip6_tnl_fill_info(struct sk_b
+@@ -2128,9 +2374,27 @@ static int ip6_tnl_fill_info(struct sk_b
nla_put_be32(skb, IFLA_IPTUN_FLOWINFO, parm->flowinfo) ||
nla_put_u32(skb, IFLA_IPTUN_FLAGS, parm->flags) ||
nla_put_u8(skb, IFLA_IPTUN_PROTO, parm->proto) ||
nla_put_be32(skb, IFLA_IPTUN_FLOWINFO, parm->flowinfo) ||
nla_put_u32(skb, IFLA_IPTUN_FLAGS, parm->flags) ||
nla_put_u8(skb, IFLA_IPTUN_PROTO, parm->proto) ||
if (nla_put_u16(skb, IFLA_IPTUN_ENCAP_TYPE, tunnel->encap.type) ||
nla_put_be16(skb, IFLA_IPTUN_ENCAP_SPORT, tunnel->encap.sport) ||
nla_put_be16(skb, IFLA_IPTUN_ENCAP_DPORT, tunnel->encap.dport) ||
if (nla_put_u16(skb, IFLA_IPTUN_ENCAP_TYPE, tunnel->encap.type) ||
nla_put_be16(skb, IFLA_IPTUN_ENCAP_SPORT, tunnel->encap.sport) ||
nla_put_be16(skb, IFLA_IPTUN_ENCAP_DPORT, tunnel->encap.dport) ||
-@@ -2172,6 +2436,7 @@ static const struct nla_policy ip6_tnl_p
+@@ -2170,6 +2434,7 @@ static const struct nla_policy ip6_tnl_p
[IFLA_IPTUN_ENCAP_DPORT] = { .type = NLA_U16 },
[IFLA_IPTUN_COLLECT_METADATA] = { .type = NLA_FLAG },
[IFLA_IPTUN_FWMARK] = { .type = NLA_U32 },
[IFLA_IPTUN_ENCAP_DPORT] = { .type = NLA_U16 },
[IFLA_IPTUN_COLLECT_METADATA] = { .type = NLA_FLAG },
[IFLA_IPTUN_FWMARK] = { .type = NLA_U32 },
--- a/include/net/netns/ipv6.h
+++ b/include/net/netns/ipv6.h
--- a/include/net/netns/ipv6.h
+++ b/include/net/netns/ipv6.h
-@@ -85,6 +85,7 @@ struct netns_ipv6 {
+@@ -86,6 +86,7 @@ struct netns_ipv6 {
unsigned int fib6_routes_require_src;
#endif
struct rt6_info *ip6_prohibit_entry;
unsigned int fib6_routes_require_src;
#endif
struct rt6_info *ip6_prohibit_entry;
static const struct rt6_info ip6_blk_hole_entry_template = {
.dst = {
.__rcuref = RCUREF_INIT(1),
static const struct rt6_info ip6_blk_hole_entry_template = {
.dst = {
.__rcuref = RCUREF_INIT(1),
-@@ -1039,6 +1053,7 @@ static const int fib6_prop[RTN_MAX + 1]
+@@ -1037,6 +1051,7 @@ static const int fib6_prop[RTN_MAX + 1]
[RTN_BLACKHOLE] = -EINVAL,
[RTN_UNREACHABLE] = -EHOSTUNREACH,
[RTN_PROHIBIT] = -EACCES,
[RTN_BLACKHOLE] = -EINVAL,
[RTN_UNREACHABLE] = -EHOSTUNREACH,
[RTN_PROHIBIT] = -EACCES,
[RTN_THROW] = -EAGAIN,
[RTN_NAT] = -EINVAL,
[RTN_XRESOLVE] = -EINVAL,
[RTN_THROW] = -EAGAIN,
[RTN_NAT] = -EINVAL,
[RTN_XRESOLVE] = -EINVAL,
-@@ -1074,6 +1089,10 @@ static void ip6_rt_init_dst_reject(struc
+@@ -1072,6 +1087,10 @@ static void ip6_rt_init_dst_reject(struc
rt->dst.output = ip6_pkt_prohibit_out;
rt->dst.input = ip6_pkt_prohibit;
break;
rt->dst.output = ip6_pkt_prohibit_out;
rt->dst.input = ip6_pkt_prohibit;
break;
case RTN_THROW:
case RTN_UNREACHABLE:
default:
case RTN_THROW:
case RTN_UNREACHABLE:
default:
-@@ -4540,6 +4559,17 @@ static int ip6_pkt_prohibit_out(struct n
+@@ -4539,6 +4558,17 @@ static int ip6_pkt_prohibit_out(struct n
return ip6_pkt_drop(skb, ICMPV6_ADM_PROHIBITED, IPSTATS_MIB_OUTNOROUTES);
}
return ip6_pkt_drop(skb, ICMPV6_ADM_PROHIBITED, IPSTATS_MIB_OUTNOROUTES);
}
/*
* Allocate a dst for local (unicast / anycast) address.
*/
/*
* Allocate a dst for local (unicast / anycast) address.
*/
-@@ -5033,7 +5063,8 @@ static int rtm_to_fib6_config(struct sk_
+@@ -5030,7 +5060,8 @@ static int rtm_to_fib6_config(struct sk_
if (rtm->rtm_type == RTN_UNREACHABLE ||
rtm->rtm_type == RTN_BLACKHOLE ||
rtm->rtm_type == RTN_PROHIBIT ||
if (rtm->rtm_type == RTN_UNREACHABLE ||
rtm->rtm_type == RTN_BLACKHOLE ||
rtm->rtm_type == RTN_PROHIBIT ||
cfg->fc_flags |= RTF_REJECT;
if (rtm->rtm_type == RTN_LOCAL)
cfg->fc_flags |= RTF_REJECT;
if (rtm->rtm_type == RTN_LOCAL)
-@@ -6287,6 +6318,8 @@ static int ip6_route_dev_notify(struct n
+@@ -6284,6 +6315,8 @@ static int ip6_route_dev_notify(struct n
#ifdef CONFIG_IPV6_MULTIPLE_TABLES
net->ipv6.ip6_prohibit_entry->dst.dev = dev;
net->ipv6.ip6_prohibit_entry->rt6i_idev = in6_dev_get(dev);
#ifdef CONFIG_IPV6_MULTIPLE_TABLES
net->ipv6.ip6_prohibit_entry->dst.dev = dev;
net->ipv6.ip6_prohibit_entry->rt6i_idev = in6_dev_get(dev);
net->ipv6.ip6_blk_hole_entry->dst.dev = dev;
net->ipv6.ip6_blk_hole_entry->rt6i_idev = in6_dev_get(dev);
#endif
net->ipv6.ip6_blk_hole_entry->dst.dev = dev;
net->ipv6.ip6_blk_hole_entry->rt6i_idev = in6_dev_get(dev);
#endif
-@@ -6298,6 +6331,7 @@ static int ip6_route_dev_notify(struct n
+@@ -6295,6 +6328,7 @@ static int ip6_route_dev_notify(struct n
in6_dev_put_clear(&net->ipv6.ip6_null_entry->rt6i_idev);
#ifdef CONFIG_IPV6_MULTIPLE_TABLES
in6_dev_put_clear(&net->ipv6.ip6_prohibit_entry->rt6i_idev);
in6_dev_put_clear(&net->ipv6.ip6_null_entry->rt6i_idev);
#ifdef CONFIG_IPV6_MULTIPLE_TABLES
in6_dev_put_clear(&net->ipv6.ip6_prohibit_entry->rt6i_idev);
in6_dev_put_clear(&net->ipv6.ip6_blk_hole_entry->rt6i_idev);
#endif
}
in6_dev_put_clear(&net->ipv6.ip6_blk_hole_entry->rt6i_idev);
#endif
}
-@@ -6489,6 +6523,8 @@ static int __net_init ip6_route_net_init
+@@ -6495,6 +6529,8 @@ static int __net_init ip6_route_net_init
#ifdef CONFIG_IPV6_MULTIPLE_TABLES
net->ipv6.fib6_has_custom_rules = false;
#ifdef CONFIG_IPV6_MULTIPLE_TABLES
net->ipv6.fib6_has_custom_rules = false;
net->ipv6.ip6_prohibit_entry = kmemdup(&ip6_prohibit_entry_template,
sizeof(*net->ipv6.ip6_prohibit_entry),
GFP_KERNEL);
net->ipv6.ip6_prohibit_entry = kmemdup(&ip6_prohibit_entry_template,
sizeof(*net->ipv6.ip6_prohibit_entry),
GFP_KERNEL);
-@@ -6499,11 +6535,21 @@ static int __net_init ip6_route_net_init
+@@ -6505,11 +6541,21 @@ static int __net_init ip6_route_net_init
ip6_template_metrics, true);
INIT_LIST_HEAD(&net->ipv6.ip6_prohibit_entry->dst.rt_uncached);
ip6_template_metrics, true);
INIT_LIST_HEAD(&net->ipv6.ip6_prohibit_entry->dst.rt_uncached);
net->ipv6.ip6_blk_hole_entry->dst.ops = &net->ipv6.ip6_dst_ops;
dst_init_metrics(&net->ipv6.ip6_blk_hole_entry->dst,
ip6_template_metrics, true);
net->ipv6.ip6_blk_hole_entry->dst.ops = &net->ipv6.ip6_dst_ops;
dst_init_metrics(&net->ipv6.ip6_blk_hole_entry->dst,
ip6_template_metrics, true);
-@@ -6530,6 +6576,8 @@ out:
+@@ -6536,6 +6582,8 @@ out:
return ret;
#ifdef CONFIG_IPV6_MULTIPLE_TABLES
return ret;
#ifdef CONFIG_IPV6_MULTIPLE_TABLES
out_ip6_prohibit_entry:
kfree(net->ipv6.ip6_prohibit_entry);
out_ip6_null_entry:
out_ip6_prohibit_entry:
kfree(net->ipv6.ip6_prohibit_entry);
out_ip6_null_entry:
-@@ -6549,6 +6597,7 @@ static void __net_exit ip6_route_net_exi
+@@ -6555,6 +6603,7 @@ static void __net_exit ip6_route_net_exi
kfree(net->ipv6.ip6_null_entry);
#ifdef CONFIG_IPV6_MULTIPLE_TABLES
kfree(net->ipv6.ip6_prohibit_entry);
kfree(net->ipv6.ip6_null_entry);
#ifdef CONFIG_IPV6_MULTIPLE_TABLES
kfree(net->ipv6.ip6_prohibit_entry);
kfree(net->ipv6.ip6_blk_hole_entry);
#endif
dst_entries_destroy(&net->ipv6.ip6_dst_ops);
kfree(net->ipv6.ip6_blk_hole_entry);
#endif
dst_entries_destroy(&net->ipv6.ip6_dst_ops);
-@@ -6632,6 +6681,9 @@ void __init ip6_route_init_special_entri
+@@ -6638,6 +6687,9 @@ void __init ip6_route_init_special_entri
init_net.ipv6.ip6_prohibit_entry->rt6i_idev = in6_dev_get(init_net.loopback_dev);
init_net.ipv6.ip6_blk_hole_entry->dst.dev = init_net.loopback_dev;
init_net.ipv6.ip6_blk_hole_entry->rt6i_idev = in6_dev_get(init_net.loopback_dev);
init_net.ipv6.ip6_prohibit_entry->rt6i_idev = in6_dev_get(init_net.loopback_dev);
init_net.ipv6.ip6_blk_hole_entry->dst.dev = init_net.loopback_dev;
init_net.ipv6.ip6_blk_hole_entry->rt6i_idev = in6_dev_get(init_net.loopback_dev);
--- a/include/linux/netdevice.h
+++ b/include/linux/netdevice.h
--- a/include/linux/netdevice.h
+++ b/include/linux/netdevice.h
-@@ -2157,6 +2157,8 @@ struct net_device {
+@@ -2210,6 +2210,8 @@ struct net_device {
struct netdev_hw_addr_list mc;
struct netdev_hw_addr_list dev_addrs;
struct netdev_hw_addr_list mc;
struct netdev_hw_addr_list dev_addrs;
#endif
--- a/include/linux/skbuff.h
+++ b/include/linux/skbuff.h
#endif
--- a/include/linux/skbuff.h
+++ b/include/linux/skbuff.h
-@@ -972,6 +972,7 @@ struct sk_buff {
+@@ -964,6 +964,7 @@ struct sk_buff {
#ifdef CONFIG_IPV6_NDISC_NODETYPE
__u8 ndisc_nodetype:2;
#endif
#ifdef CONFIG_IPV6_NDISC_NODETYPE
__u8 ndisc_nodetype:2;
#endif
__u8 ipvs_property:1;
--- a/net/core/gro.c
+++ b/net/core/gro.c
__u8 ipvs_property:1;
--- a/net/core/gro.c
+++ b/net/core/gro.c
-@@ -491,6 +491,9 @@ static enum gro_result dev_gro_receive(s
+@@ -445,6 +445,9 @@ static enum gro_result dev_gro_receive(s
enum gro_result ret;
int same_flow;
enum gro_result ret;
int same_flow;
--- a/net/core/dev.c
+++ b/net/core/dev.c
--- a/net/core/dev.c
+++ b/net/core/dev.c
-@@ -7625,6 +7625,48 @@ static void __netdev_adjacent_dev_unlink
+@@ -7686,6 +7686,48 @@ static void __netdev_adjacent_dev_unlink
&upper_dev->adj_list.lower);
}
&upper_dev->adj_list.lower);
}
static int __netdev_upper_dev_link(struct net_device *dev,
struct net_device *upper_dev, bool master,
void *upper_priv, void *upper_info,
static int __netdev_upper_dev_link(struct net_device *dev,
struct net_device *upper_dev, bool master,
void *upper_priv, void *upper_info,
-@@ -7676,6 +7718,7 @@ static int __netdev_upper_dev_link(struc
+@@ -7737,6 +7779,7 @@ static int __netdev_upper_dev_link(struc
ret = call_netdevice_notifiers_info(NETDEV_CHANGEUPPER,
&changeupper_info.info);
ret = notifier_to_errno(ret);
ret = call_netdevice_notifiers_info(NETDEV_CHANGEUPPER,
&changeupper_info.info);
ret = notifier_to_errno(ret);
-@@ -7772,6 +7815,7 @@ static void __netdev_upper_dev_unlink(st
+@@ -7833,6 +7876,7 @@ static void __netdev_upper_dev_unlink(st
__netdev_adjacent_dev_unlink_neighbour(dev, upper_dev);
__netdev_adjacent_dev_unlink_neighbour(dev, upper_dev);
call_netdevice_notifiers_info(NETDEV_CHANGEUPPER,
&changeupper_info.info);
call_netdevice_notifiers_info(NETDEV_CHANGEUPPER,
&changeupper_info.info);
-@@ -8821,6 +8865,7 @@ int dev_set_mac_address(struct net_devic
+@@ -8889,6 +8933,7 @@ int dev_set_mac_address(struct net_devic
return err;
}
dev->addr_assign_type = NET_ADDR_SET;
return err;
}
dev->addr_assign_type = NET_ADDR_SET;
--- a/net/core/of_net.c
+++ b/net/core/of_net.c
--- a/net/core/of_net.c
+++ b/net/core/of_net.c
-@@ -95,6 +95,27 @@ static int of_get_mac_addr_nvmem(struct
+@@ -97,6 +97,27 @@ int of_get_mac_address_nvmem(struct devi
}
EXPORT_SYMBOL(of_get_mac_address_nvmem);
}
EXPORT_SYMBOL(of_get_mac_address_nvmem);
/**
* of_get_mac_address()
* @np: Caller's Device Node
/**
* of_get_mac_address()
* @np: Caller's Device Node
-@@ -130,17 +151,23 @@ int of_get_mac_address(struct device_nod
+@@ -132,17 +153,23 @@ int of_get_mac_address(struct device_nod
ret = of_get_mac_addr(np, "mac-address", addr);
if (!ret)
ret = of_get_mac_addr(np, "mac-address", addr);
if (!ret)
--- a/net/netfilter/nf_flow_table_core.c
+++ b/net/netfilter/nf_flow_table_core.c
--- a/net/netfilter/nf_flow_table_core.c
+++ b/net/netfilter/nf_flow_table_core.c
-@@ -659,6 +659,23 @@ static struct pernet_operations nf_flow_
+@@ -662,6 +662,23 @@ static struct pernet_operations nf_flow_
.exit_batch = nf_flow_table_pernet_exit,
};
.exit_batch = nf_flow_table_pernet_exit,
};
static int __init nf_flow_table_module_init(void)
{
int ret;
static int __init nf_flow_table_module_init(void)
{
int ret;
-@@ -671,8 +688,14 @@ static int __init nf_flow_table_module_i
+@@ -674,8 +691,14 @@ static int __init nf_flow_table_module_i
if (ret)
goto out_offload;
if (ret)
goto out_offload;
out_offload:
unregister_pernet_subsys(&nf_flow_table_net_ops);
return ret;
out_offload:
unregister_pernet_subsys(&nf_flow_table_net_ops);
return ret;
-@@ -680,6 +703,7 @@ out_offload:
+@@ -683,6 +706,7 @@ out_offload:
static void __exit nf_flow_table_module_exit(void)
{
static void __exit nf_flow_table_module_exit(void)
{
}
--- a/net/netfilter/nft_flow_offload.c
+++ b/net/netfilter/nft_flow_offload.c
}
--- a/net/netfilter/nft_flow_offload.c
+++ b/net/netfilter/nft_flow_offload.c
-@@ -479,47 +479,14 @@ static struct nft_expr_type nft_flow_off
+@@ -480,47 +480,14 @@ static struct nft_expr_type nft_flow_off
--- a/net/netfilter/nf_tables_api.c
+++ b/net/netfilter/nf_tables_api.c
--- a/net/netfilter/nf_tables_api.c
+++ b/net/netfilter/nf_tables_api.c
-@@ -7911,7 +7911,7 @@ static int nft_register_flowtable_net_ho
+@@ -8213,7 +8213,7 @@ static int nft_register_flowtable_net_ho
err = flowtable->data.type->setup(&flowtable->data,
hook->ops.dev,
FLOW_BLOCK_BIND);
err = flowtable->data.type->setup(&flowtable->data,
hook->ops.dev,
FLOW_BLOCK_BIND);
--- a/drivers/net/ethernet/mediatek/mtk_eth_soc.c
+++ b/drivers/net/ethernet/mediatek/mtk_eth_soc.c
--- a/drivers/net/ethernet/mediatek/mtk_eth_soc.c
+++ b/drivers/net/ethernet/mediatek/mtk_eth_soc.c
-@@ -4941,6 +4941,8 @@ static int mtk_probe(struct platform_dev
+@@ -4982,6 +4982,8 @@ static int mtk_probe(struct platform_dev
* for NAPI to work
*/
init_dummy_netdev(ð->dummy_dev);
* for NAPI to work
*/
init_dummy_netdev(ð->dummy_dev);
--- a/drivers/net/phy/phy_device.c
+++ b/drivers/net/phy/phy_device.c
--- a/drivers/net/phy/phy_device.c
+++ b/drivers/net/phy/phy_device.c
-@@ -1753,6 +1753,9 @@ void phy_detach(struct phy_device *phyde
+@@ -1900,6 +1900,9 @@ void phy_detach(struct phy_device *phyde
if (phydev->devlink)
device_link_del(phydev->devlink);
if (phydev->devlink)
device_link_del(phydev->devlink);
sysfs_remove_link(&dev->dev.kobj, "phydev");
--- a/include/linux/phy.h
+++ b/include/linux/phy.h
sysfs_remove_link(&dev->dev.kobj, "phydev");
--- a/include/linux/phy.h
+++ b/include/linux/phy.h
-@@ -900,6 +900,12 @@ struct phy_driver {
+@@ -976,6 +976,12 @@ struct phy_driver {
/** @handle_interrupt: Override default interrupt handling */
irqreturn_t (*handle_interrupt)(struct phy_device *phydev);
/** @handle_interrupt: Override default interrupt handling */
irqreturn_t (*handle_interrupt)(struct phy_device *phydev);
--- a/net/dsa/tag_mtk.c
+++ b/net/dsa/tag_mtk.c
--- a/net/dsa/tag_mtk.c
+++ b/net/dsa/tag_mtk.c
-@@ -27,6 +27,13 @@ static struct sk_buff *mtk_tag_xmit(stru
+@@ -29,6 +29,13 @@ static struct sk_buff *mtk_tag_xmit(stru
skb_set_queue_mapping(skb, dp->index);
skb_set_queue_mapping(skb, dp->index);
--- a/include/linux/if_bridge.h
+++ b/include/linux/if_bridge.h
--- a/include/linux/if_bridge.h
+++ b/include/linux/if_bridge.h
-@@ -59,6 +59,7 @@ struct br_ip_list {
+@@ -61,6 +61,7 @@ struct br_ip_list {
#define BR_PORT_LOCKED BIT(21)
#define BR_PORT_MAB BIT(22)
#define BR_NEIGH_VLAN_SUPPRESS BIT(23)
#define BR_PORT_LOCKED BIT(21)
#define BR_PORT_MAB BIT(22)
#define BR_NEIGH_VLAN_SUPPRESS BIT(23)
--- a/net/bridge/br_forward.c
+++ b/net/bridge/br_forward.c
--- a/net/bridge/br_forward.c
+++ b/net/bridge/br_forward.c
-@@ -199,6 +199,7 @@ out:
+@@ -201,6 +201,7 @@ void br_flood(struct net_bridge *br, str
enum br_pkt_type pkt_type, bool local_rcv, bool local_orig,
u16 vid)
{
enum br_pkt_type pkt_type, bool local_rcv, bool local_orig,
u16 vid)
{
struct net_bridge_port *prev = NULL;
struct net_bridge_port *p;
struct net_bridge_port *prev = NULL;
struct net_bridge_port *p;
-@@ -214,6 +215,10 @@ void br_flood(struct net_bridge *br, str
+@@ -218,6 +219,10 @@ void br_flood(struct net_bridge *br, str
case BR_PKT_MULTICAST:
if (!(p->flags & BR_MCAST_FLOOD) && skb->dev != br->dev)
continue;
case BR_PKT_MULTICAST:
if (!(p->flags & BR_MCAST_FLOOD) && skb->dev != br->dev)
continue;
if (!(p->flags & BR_BCAST_FLOOD) && skb->dev != br->dev)
--- a/net/bridge/br_input.c
+++ b/net/bridge/br_input.c
if (!(p->flags & BR_BCAST_FLOOD) && skb->dev != br->dev)
--- a/net/bridge/br_input.c
+++ b/net/bridge/br_input.c
-@@ -344,6 +344,8 @@ static rx_handler_result_t br_handle_fra
+@@ -362,6 +362,8 @@ static rx_handler_result_t br_handle_fra
fwd_mask |= p->group_fwd_mask;
switch (dest[5]) {
case 0x00: /* Bridge Group Address */
fwd_mask |= p->group_fwd_mask;
switch (dest[5]) {
case 0x00: /* Bridge Group Address */
--- a/include/uapi/linux/if_link.h
+++ b/include/uapi/linux/if_link.h
--- a/include/uapi/linux/if_link.h
+++ b/include/uapi/linux/if_link.h
-@@ -561,6 +561,7 @@ enum {
+@@ -571,6 +571,7 @@ enum {
IFLA_BRPORT_MCAST_MAX_GROUPS,
IFLA_BRPORT_NEIGH_VLAN_SUPPRESS,
IFLA_BRPORT_BACKUP_NHID,
IFLA_BRPORT_MCAST_MAX_GROUPS,
IFLA_BRPORT_NEIGH_VLAN_SUPPRESS,
IFLA_BRPORT_BACKUP_NHID,
#define IFLA_BRPORT_MAX (__IFLA_BRPORT_MAX - 1)
--- a/net/bridge/br_netlink.c
+++ b/net/bridge/br_netlink.c
#define IFLA_BRPORT_MAX (__IFLA_BRPORT_MAX - 1)
--- a/net/bridge/br_netlink.c
+++ b/net/bridge/br_netlink.c
-@@ -188,6 +188,7 @@ static inline size_t br_port_info_size(v
+@@ -190,6 +190,7 @@ static inline size_t br_port_info_size(v
+ nla_total_size(1) /* IFLA_BRPORT_LOCKED */
+ nla_total_size(1) /* IFLA_BRPORT_MAB */
+ nla_total_size(1) /* IFLA_BRPORT_NEIGH_VLAN_SUPPRESS */
+ nla_total_size(1) /* IFLA_BRPORT_LOCKED */
+ nla_total_size(1) /* IFLA_BRPORT_MAB */
+ nla_total_size(1) /* IFLA_BRPORT_NEIGH_VLAN_SUPPRESS */
+ nla_total_size(sizeof(struct ifla_bridge_id)) /* IFLA_BRPORT_ROOT_ID */
+ nla_total_size(sizeof(struct ifla_bridge_id)) /* IFLA_BRPORT_BRIDGE_ID */
+ nla_total_size(sizeof(u16)) /* IFLA_BRPORT_DESIGNATED_PORT */
+ nla_total_size(sizeof(struct ifla_bridge_id)) /* IFLA_BRPORT_ROOT_ID */
+ nla_total_size(sizeof(struct ifla_bridge_id)) /* IFLA_BRPORT_BRIDGE_ID */
+ nla_total_size(sizeof(u16)) /* IFLA_BRPORT_DESIGNATED_PORT */
-@@ -274,7 +275,8 @@ static int br_port_fill_attrs(struct sk_
+@@ -282,7 +283,8 @@ static int br_port_fill_attrs(struct sk_
nla_put_u8(skb, IFLA_BRPORT_LOCKED, !!(p->flags & BR_PORT_LOCKED)) ||
nla_put_u8(skb, IFLA_BRPORT_MAB, !!(p->flags & BR_PORT_MAB)) ||
nla_put_u8(skb, IFLA_BRPORT_NEIGH_VLAN_SUPPRESS,
nla_put_u8(skb, IFLA_BRPORT_LOCKED, !!(p->flags & BR_PORT_LOCKED)) ||
nla_put_u8(skb, IFLA_BRPORT_MAB, !!(p->flags & BR_PORT_MAB)) ||
nla_put_u8(skb, IFLA_BRPORT_NEIGH_VLAN_SUPPRESS,
return -EMSGSIZE;
timerval = br_timer_value(&p->message_age_timer);
return -EMSGSIZE;
timerval = br_timer_value(&p->message_age_timer);
-@@ -878,6 +880,7 @@ static const struct nla_policy br_port_p
+@@ -901,6 +903,7 @@ static const struct nla_policy br_port_p
[IFLA_BRPORT_MCAST_MAX_GROUPS] = { .type = NLA_U32 },
[IFLA_BRPORT_NEIGH_VLAN_SUPPRESS] = NLA_POLICY_MAX(NLA_U8, 1),
[IFLA_BRPORT_BACKUP_NHID] = { .type = NLA_U32 },
[IFLA_BRPORT_MCAST_MAX_GROUPS] = { .type = NLA_U32 },
[IFLA_BRPORT_NEIGH_VLAN_SUPPRESS] = NLA_POLICY_MAX(NLA_U8, 1),
[IFLA_BRPORT_BACKUP_NHID] = { .type = NLA_U32 },
};
/* Change the state of the port and notify spanning tree */
};
/* Change the state of the port and notify spanning tree */
-@@ -943,6 +946,7 @@ static int br_setport(struct net_bridge_
+@@ -969,6 +972,7 @@ static int br_setport(struct net_bridge_
br_set_port_flag(p, tb, IFLA_BRPORT_MAB, BR_PORT_MAB);
br_set_port_flag(p, tb, IFLA_BRPORT_NEIGH_VLAN_SUPPRESS,
BR_NEIGH_VLAN_SUPPRESS);
br_set_port_flag(p, tb, IFLA_BRPORT_MAB, BR_PORT_MAB);
br_set_port_flag(p, tb, IFLA_BRPORT_NEIGH_VLAN_SUPPRESS,
BR_NEIGH_VLAN_SUPPRESS);
(!(p->flags & BR_PORT_LOCKED) || !(p->flags & BR_LEARNING))) {
--- a/net/core/rtnetlink.c
+++ b/net/core/rtnetlink.c
(!(p->flags & BR_PORT_LOCKED) || !(p->flags & BR_LEARNING))) {
--- a/net/core/rtnetlink.c
+++ b/net/core/rtnetlink.c
#include "dev.h"
#define RTNL_MAX_TYPE 50
#include "dev.h"
#define RTNL_MAX_TYPE 50
struct rtnl_link {
rtnl_doit_func doit;
struct rtnl_link {
rtnl_doit_func doit;
-@@ -4840,7 +4840,9 @@ int ndo_dflt_bridge_getlink(struct sk_bu
+@@ -4949,7 +4949,9 @@ int ndo_dflt_bridge_getlink(struct sk_bu
brport_nla_put_flag(skb, flags, mask,
IFLA_BRPORT_MCAST_FLOOD, BR_MCAST_FLOOD) ||
brport_nla_put_flag(skb, flags, mask,
brport_nla_put_flag(skb, flags, mask,
IFLA_BRPORT_MCAST_FLOOD, BR_MCAST_FLOOD) ||
brport_nla_put_flag(skb, flags, mask,
--- a/drivers/net/dsa/qca/qca8k-8xxx.c
+++ b/drivers/net/dsa/qca/qca8k-8xxx.c
--- a/drivers/net/dsa/qca/qca8k-8xxx.c
+++ b/drivers/net/dsa/qca/qca8k-8xxx.c
-@@ -2015,6 +2015,8 @@ static const struct dsa_switch_ops qca8k
+@@ -2012,6 +2012,8 @@ static const struct dsa_switch_ops qca8k
.port_fdb_add = qca8k_port_fdb_add,
.port_fdb_del = qca8k_port_fdb_del,
.port_fdb_dump = qca8k_port_fdb_dump,
.port_fdb_add = qca8k_port_fdb_add,
.port_fdb_del = qca8k_port_fdb_del,
.port_fdb_dump = qca8k_port_fdb_dump,
--- a/drivers/net/dsa/qca/qca8k-8xxx.c
+++ b/drivers/net/dsa/qca/qca8k-8xxx.c
--- a/drivers/net/dsa/qca/qca8k-8xxx.c
+++ b/drivers/net/dsa/qca/qca8k-8xxx.c
-@@ -1904,15 +1904,12 @@ qca8k_setup(struct dsa_switch *ds)
+@@ -1901,15 +1901,12 @@ qca8k_setup(struct dsa_switch *ds)
--- a/drivers/net/dsa/qca/qca8k-8xxx.c
+++ b/drivers/net/dsa/qca/qca8k-8xxx.c
--- a/drivers/net/dsa/qca/qca8k-8xxx.c
+++ b/drivers/net/dsa/qca/qca8k-8xxx.c
-@@ -1741,6 +1741,117 @@ qca8k_get_tag_protocol(struct dsa_switch
+@@ -1738,6 +1738,117 @@ qca8k_get_tag_protocol(struct dsa_switch
return DSA_TAG_PROTO_QCA;
}
return DSA_TAG_PROTO_QCA;
}
static void
qca8k_master_change(struct dsa_switch *ds, const struct net_device *master,
bool operational)
static void
qca8k_master_change(struct dsa_switch *ds, const struct net_device *master,
bool operational)
-@@ -2027,8 +2138,9 @@ static const struct dsa_switch_ops qca8k
+@@ -2024,8 +2135,9 @@ static const struct dsa_switch_ops qca8k
.phylink_mac_link_down = qca8k_phylink_mac_link_down,
.phylink_mac_link_up = qca8k_phylink_mac_link_up,
.get_phy_flags = qca8k_get_phy_flags,
.phylink_mac_link_down = qca8k_phylink_mac_link_down,
.phylink_mac_link_up = qca8k_phylink_mac_link_up,
.get_phy_flags = qca8k_get_phy_flags,
--- a/drivers/net/dsa/qca/qca8k-8xxx.c
+++ b/drivers/net/dsa/qca/qca8k-8xxx.c
--- a/drivers/net/dsa/qca/qca8k-8xxx.c
+++ b/drivers/net/dsa/qca/qca8k-8xxx.c
-@@ -2013,6 +2013,12 @@ qca8k_setup(struct dsa_switch *ds)
+@@ -2010,6 +2010,12 @@ qca8k_setup(struct dsa_switch *ds)
dev_err(priv->dev, "failed enabling QCA header mode on port %d", dp->index);
return ret;
}
dev_err(priv->dev, "failed enabling QCA header mode on port %d", dp->index);
return ret;
}
}
/* Forward all unknown frames to CPU port for Linux processing */
}
/* Forward all unknown frames to CPU port for Linux processing */
-@@ -2042,11 +2048,6 @@ qca8k_setup(struct dsa_switch *ds)
+@@ -2039,11 +2045,6 @@ qca8k_setup(struct dsa_switch *ds)
/* For port based vlans to work we need to set the
* default egress vid
*/
/* For port based vlans to work we need to set the
* default egress vid
*/
-@@ -2098,6 +2099,9 @@ qca8k_setup(struct dsa_switch *ds)
+@@ -2095,6 +2096,9 @@ qca8k_setup(struct dsa_switch *ds)
/* Set max number of LAGs supported */
ds->num_lag_ids = QCA8K_NUM_LAGS;
/* Set max number of LAGs supported */
ds->num_lag_ids = QCA8K_NUM_LAGS;
--- a/arch/arm64/boot/dts/qcom/ipq8074.dtsi
+++ b/arch/arm64/boot/dts/qcom/ipq8074.dtsi
--- a/arch/arm64/boot/dts/qcom/ipq8074.dtsi
+++ b/arch/arm64/boot/dts/qcom/ipq8074.dtsi
clocks = <&gcc GCC_MDIO_AHB_CLK>;
clock-names = "gcc_mdio_ahb_clk";
clocks = <&gcc GCC_MDIO_AHB_CLK>;
clock-names = "gcc_mdio_ahb_clk";
--- a/drivers/net/phy/realtek.c
+++ b/drivers/net/phy/realtek.c
--- a/drivers/net/phy/realtek.c
+++ b/drivers/net/phy/realtek.c
RTL8201F_ISR_LINK)
#define RTL8201F_IER 0x13
RTL8201F_ISR_LINK)
#define RTL8201F_IER 0x13
#define RTL8366RB_POWER_SAVE 0x15
#define RTL8366RB_POWER_SAVE_ON BIT(12)
#define RTL8366RB_POWER_SAVE 0x15
#define RTL8366RB_POWER_SAVE_ON BIT(12)
-@@ -851,6 +860,48 @@ static irqreturn_t rtl9000a_handle_inter
+@@ -879,6 +888,48 @@ static irqreturn_t rtl9000a_handle_inter
static struct phy_driver realtek_drvs[] = {
{
PHY_ID_MATCH_EXACT(0x00008201),
static struct phy_driver realtek_drvs[] = {
{
PHY_ID_MATCH_EXACT(0x00008201),
-@@ -1003,6 +1054,7 @@ static struct phy_driver realtek_drvs[]
+@@ -1033,6 +1084,7 @@ static struct phy_driver realtek_drvs[]
PHY_ID_MATCH_EXACT(0x001cc849),
.name = "RTL8221B-VB-CG 2.5Gbps PHY",
.get_features = rtl822x_get_features,
PHY_ID_MATCH_EXACT(0x001cc849),
.name = "RTL8221B-VB-CG 2.5Gbps PHY",
.get_features = rtl822x_get_features,
.config_aneg = rtl822x_config_aneg,
.read_status = rtl822x_read_status,
.suspend = genphy_suspend,
.config_aneg = rtl822x_config_aneg,
.read_status = rtl822x_read_status,
.suspend = genphy_suspend,
-@@ -1014,6 +1066,7 @@ static struct phy_driver realtek_drvs[]
+@@ -1044,6 +1096,7 @@ static struct phy_driver realtek_drvs[]
.name = "RTL8221B-VM-CG 2.5Gbps PHY",
.get_features = rtl822x_get_features,
.config_aneg = rtl822x_config_aneg,
.name = "RTL8221B-VM-CG 2.5Gbps PHY",
.get_features = rtl822x_get_features,
.config_aneg = rtl822x_config_aneg,
--- a/drivers/net/phy/realtek.c
+++ b/drivers/net/phy/realtek.c
--- a/drivers/net/phy/realtek.c
+++ b/drivers/net/phy/realtek.c
-@@ -686,6 +686,25 @@ static int rtl822x_config_aneg(struct ph
+@@ -714,6 +714,25 @@ static int rtl822x_config_aneg(struct ph
return __genphy_config_aneg(phydev, ret);
}
return __genphy_config_aneg(phydev, ret);
}
static int rtl822x_read_status(struct phy_device *phydev)
{
int ret;
static int rtl822x_read_status(struct phy_device *phydev)
{
int ret;
-@@ -704,11 +723,14 @@ static int rtl822x_read_status(struct ph
+@@ -732,11 +751,14 @@ static int rtl822x_read_status(struct ph
phydev->lp_advertising, lpadv & RTL_LPADV_2500FULL);
}
phydev->lp_advertising, lpadv & RTL_LPADV_2500FULL);
}
--- a/drivers/net/dsa/mt7530.c
+++ b/drivers/net/dsa/mt7530.c
--- a/drivers/net/dsa/mt7530.c
+++ b/drivers/net/dsa/mt7530.c
-@@ -2252,6 +2252,10 @@ mt7530_setup(struct dsa_switch *ds)
+@@ -2268,6 +2268,10 @@ mt7530_setup(struct dsa_switch *ds)
--- a/drivers/net/phy/realtek.c
+++ b/drivers/net/phy/realtek.c
--- a/drivers/net/phy/realtek.c
+++ b/drivers/net/phy/realtek.c
-@@ -1040,6 +1040,7 @@ static struct phy_driver realtek_drvs[]
+@@ -1070,6 +1070,7 @@ static struct phy_driver realtek_drvs[]
.write_page = rtl821x_write_page,
.read_mmd = rtl822x_read_mmd,
.write_mmd = rtl822x_write_mmd,
.write_page = rtl821x_write_page,
.read_mmd = rtl822x_read_mmd,
.write_mmd = rtl822x_write_mmd,
}, {
PHY_ID_MATCH_EXACT(0x001cc840),
.name = "RTL8226B_RTL8221B 2.5Gbps PHY",
}, {
PHY_ID_MATCH_EXACT(0x001cc840),
.name = "RTL8226B_RTL8221B 2.5Gbps PHY",
-@@ -1052,6 +1053,7 @@ static struct phy_driver realtek_drvs[]
+@@ -1082,6 +1083,7 @@ static struct phy_driver realtek_drvs[]
.write_page = rtl821x_write_page,
.read_mmd = rtl822x_read_mmd,
.write_mmd = rtl822x_write_mmd,
.write_page = rtl821x_write_page,
.read_mmd = rtl822x_read_mmd,
.write_mmd = rtl822x_write_mmd,
}, {
PHY_ID_MATCH_EXACT(0x001cc838),
.name = "RTL8226-CG 2.5Gbps PHY",
}, {
PHY_ID_MATCH_EXACT(0x001cc838),
.name = "RTL8226-CG 2.5Gbps PHY",
-@@ -1062,6 +1064,7 @@ static struct phy_driver realtek_drvs[]
+@@ -1092,6 +1094,7 @@ static struct phy_driver realtek_drvs[]
.resume = rtlgen_resume,
.read_page = rtl821x_read_page,
.write_page = rtl821x_write_page,
.resume = rtlgen_resume,
.read_page = rtl821x_read_page,
.write_page = rtl821x_write_page,
}, {
PHY_ID_MATCH_EXACT(0x001cc848),
.name = "RTL8226B-CG_RTL8221B-CG 2.5Gbps PHY",
}, {
PHY_ID_MATCH_EXACT(0x001cc848),
.name = "RTL8226B-CG_RTL8221B-CG 2.5Gbps PHY",
-@@ -1072,6 +1075,7 @@ static struct phy_driver realtek_drvs[]
+@@ -1102,6 +1105,7 @@ static struct phy_driver realtek_drvs[]
.resume = rtlgen_resume,
.read_page = rtl821x_read_page,
.write_page = rtl821x_write_page,
.resume = rtlgen_resume,
.read_page = rtl821x_read_page,
.write_page = rtl821x_write_page,
}, {
PHY_ID_MATCH_EXACT(0x001cc849),
.name = "RTL8221B-VB-CG 2.5Gbps PHY",
}, {
PHY_ID_MATCH_EXACT(0x001cc849),
.name = "RTL8221B-VB-CG 2.5Gbps PHY",
-@@ -1083,6 +1087,7 @@ static struct phy_driver realtek_drvs[]
+@@ -1113,6 +1117,7 @@ static struct phy_driver realtek_drvs[]
.resume = rtlgen_resume,
.read_page = rtl821x_read_page,
.write_page = rtl821x_write_page,
.resume = rtlgen_resume,
.read_page = rtl821x_read_page,
.write_page = rtl821x_write_page,
}, {
PHY_ID_MATCH_EXACT(0x001cc84a),
.name = "RTL8221B-VM-CG 2.5Gbps PHY",
}, {
PHY_ID_MATCH_EXACT(0x001cc84a),
.name = "RTL8221B-VM-CG 2.5Gbps PHY",
-@@ -1094,6 +1099,7 @@ static struct phy_driver realtek_drvs[]
+@@ -1124,6 +1129,7 @@ static struct phy_driver realtek_drvs[]
.resume = rtlgen_resume,
.read_page = rtl821x_read_page,
.write_page = rtl821x_write_page,
.resume = rtlgen_resume,
.read_page = rtl821x_read_page,
.write_page = rtl821x_write_page,
--- a/drivers/net/phy/realtek.c
+++ b/drivers/net/phy/realtek.c
--- a/drivers/net/phy/realtek.c
+++ b/drivers/net/phy/realtek.c
-@@ -885,6 +885,7 @@ static irqreturn_t rtl9000a_handle_inter
+@@ -913,6 +913,7 @@ static irqreturn_t rtl9000a_handle_inter
static int rtl8221b_config_init(struct phy_device *phydev)
{
u16 option_mode;
static int rtl8221b_config_init(struct phy_device *phydev)
{
u16 option_mode;
switch (phydev->interface) {
case PHY_INTERFACE_MODE_2500BASEX:
switch (phydev->interface) {
case PHY_INTERFACE_MODE_2500BASEX:
-@@ -921,6 +922,13 @@ static int rtl8221b_config_init(struct p
+@@ -949,6 +950,13 @@ static int rtl8221b_config_init(struct p
--- a/drivers/net/phy/realtek.c
+++ b/drivers/net/phy/realtek.c
--- a/drivers/net/phy/realtek.c
+++ b/drivers/net/phy/realtek.c
-@@ -737,9 +737,11 @@ static bool rtlgen_supports_2_5gbps(stru
+@@ -765,9 +765,11 @@ static bool rtlgen_supports_2_5gbps(stru
--- a/drivers/net/phy/realtek.c
+++ b/drivers/net/phy/realtek.c
--- a/drivers/net/phy/realtek.c
+++ b/drivers/net/phy/realtek.c
#define RTL_SUPPORTS_5000FULL BIT(14)
#define RTL_SUPPORTS_2500FULL BIT(13)
#define RTL_SUPPORTS_10000FULL BIT(0)
#define RTL_SUPPORTS_5000FULL BIT(14)
#define RTL_SUPPORTS_2500FULL BIT(13)
#define RTL_SUPPORTS_10000FULL BIT(0)
#define RTL9000A_GINMR 0x14
#define RTL9000A_GINMR_LINK_STATUS BIT(4)
#define RTL9000A_GINMR 0x14
#define RTL9000A_GINMR_LINK_STATUS BIT(4)
-@@ -671,14 +667,11 @@ static int rtl822x_config_aneg(struct ph
+@@ -699,14 +695,11 @@ static int rtl822x_config_aneg(struct ph
int ret = 0;
if (phydev->autoneg == AUTONEG_ENABLE) {
int ret = 0;
if (phydev->autoneg == AUTONEG_ENABLE) {
if (ret < 0)
return ret;
}
if (ret < 0)
return ret;
}
-@@ -715,12 +708,7 @@ static int rtl822x_read_status(struct ph
+@@ -743,12 +736,7 @@ static int rtl822x_read_status(struct ph
if (lpadv < 0)
return lpadv;
if (lpadv < 0)
return lpadv;
--- a/drivers/net/phy/realtek.c
+++ b/drivers/net/phy/realtek.c
--- a/drivers/net/phy/realtek.c
+++ b/drivers/net/phy/realtek.c
-@@ -708,6 +708,10 @@ static int rtl822x_read_status(struct ph
+@@ -736,6 +736,10 @@ static int rtl822x_read_status(struct ph
if (lpadv < 0)
return lpadv;
if (lpadv < 0)
return lpadv;
--- a/drivers/net/phy/realtek.c
+++ b/drivers/net/phy/realtek.c
--- a/drivers/net/phy/realtek.c
+++ b/drivers/net/phy/realtek.c
#define RTL8221B_SERDES_OPTION_MODE_2500BASEX 2
#define RTL8221B_SERDES_OPTION_MODE_HISGMII 3
#define RTL8221B_SERDES_OPTION_MODE_2500BASEX 2
#define RTL8221B_SERDES_OPTION_MODE_HISGMII 3
#define RTL8366RB_POWER_SAVE 0x15
#define RTL8366RB_POWER_SAVE_ON BIT(12)
#define RTL8366RB_POWER_SAVE 0x15
#define RTL8366RB_POWER_SAVE_ON BIT(12)
-@@ -750,6 +754,25 @@ static int rtl8226_match_phy_device(stru
+@@ -778,6 +782,25 @@ static int rtl8226_match_phy_device(stru
rtlgen_supports_2_5gbps(phydev);
}
rtlgen_supports_2_5gbps(phydev);
}
static int rtlgen_resume(struct phy_device *phydev)
{
int ret = genphy_resume(phydev);
static int rtlgen_resume(struct phy_device *phydev)
{
int ret = genphy_resume(phydev);
-@@ -1061,6 +1084,7 @@ static struct phy_driver realtek_drvs[]
+@@ -1091,6 +1114,7 @@ static struct phy_driver realtek_drvs[]
.name = "RTL8226-CG 2.5Gbps PHY",
.get_features = rtl822x_get_features,
.config_aneg = rtl822x_config_aneg,
.name = "RTL8226-CG 2.5Gbps PHY",
.get_features = rtl822x_get_features,
.config_aneg = rtl822x_config_aneg,
.read_status = rtl822x_read_status,
.suspend = genphy_suspend,
.resume = rtlgen_resume,
.read_status = rtl822x_read_status,
.suspend = genphy_suspend,
.resume = rtlgen_resume,
-@@ -1072,6 +1096,7 @@ static struct phy_driver realtek_drvs[]
+@@ -1102,6 +1126,7 @@ static struct phy_driver realtek_drvs[]
.name = "RTL8226B-CG_RTL8221B-CG 2.5Gbps PHY",
.get_features = rtl822x_get_features,
.config_aneg = rtl822x_config_aneg,
.name = "RTL8226B-CG_RTL8221B-CG 2.5Gbps PHY",
.get_features = rtl822x_get_features,
.config_aneg = rtl822x_config_aneg,
.read_status = rtl822x_read_status,
.suspend = genphy_suspend,
.resume = rtlgen_resume,
.read_status = rtl822x_read_status,
.suspend = genphy_suspend,
.resume = rtlgen_resume,
-@@ -1084,6 +1109,7 @@ static struct phy_driver realtek_drvs[]
+@@ -1114,6 +1139,7 @@ static struct phy_driver realtek_drvs[]
.get_features = rtl822x_get_features,
.config_init = rtl8221b_config_init,
.config_aneg = rtl822x_config_aneg,
.get_features = rtl822x_get_features,
.config_init = rtl8221b_config_init,
.config_aneg = rtl822x_config_aneg,
.read_status = rtl822x_read_status,
.suspend = genphy_suspend,
.resume = rtlgen_resume,
.read_status = rtl822x_read_status,
.suspend = genphy_suspend,
.resume = rtlgen_resume,
-@@ -1096,6 +1122,7 @@ static struct phy_driver realtek_drvs[]
+@@ -1126,6 +1152,7 @@ static struct phy_driver realtek_drvs[]
.get_features = rtl822x_get_features,
.config_aneg = rtl822x_config_aneg,
.config_init = rtl8221b_config_init,
.get_features = rtl822x_get_features,
.config_aneg = rtl822x_config_aneg,
.config_init = rtl8221b_config_init,
--- a/drivers/net/phy/realtek.c
+++ b/drivers/net/phy/realtek.c
--- a/drivers/net/phy/realtek.c
+++ b/drivers/net/phy/realtek.c
-@@ -754,6 +754,38 @@ static int rtl8226_match_phy_device(stru
+@@ -782,6 +782,38 @@ static int rtl8226_match_phy_device(stru
rtlgen_supports_2_5gbps(phydev);
}
rtlgen_supports_2_5gbps(phydev);
}
static int rtl822x_probe(struct phy_device *phydev)
{
struct device *dev = &phydev->mdio.dev;
static int rtl822x_probe(struct phy_device *phydev)
{
struct device *dev = &phydev->mdio.dev;
-@@ -1104,7 +1136,7 @@ static struct phy_driver realtek_drvs[]
+@@ -1134,7 +1166,7 @@ static struct phy_driver realtek_drvs[]
.write_page = rtl821x_write_page,
.soft_reset = genphy_soft_reset,
}, {
.write_page = rtl821x_write_page,
.soft_reset = genphy_soft_reset,
}, {
--- a/include/linux/netdevice.h
+++ b/include/linux/netdevice.h
--- a/include/linux/netdevice.h
+++ b/include/linux/netdevice.h
-@@ -2192,7 +2192,7 @@ struct net_device {
+@@ -2245,7 +2245,7 @@ struct net_device {
#if IS_ENABLED(CONFIG_AX25)
void *ax25_ptr;
#endif
#if IS_ENABLED(CONFIG_AX25)
void *ax25_ptr;
#endif
#if IS_ENABLED(CONFIG_IEEE802154) || IS_ENABLED(CONFIG_6LOWPAN)
--- a/net/batman-adv/hard-interface.c
+++ b/net/batman-adv/hard-interface.c
#if IS_ENABLED(CONFIG_IEEE802154) || IS_ENABLED(CONFIG_6LOWPAN)
--- a/net/batman-adv/hard-interface.c
+++ b/net/batman-adv/hard-interface.c
-@@ -308,7 +308,7 @@ static bool batadv_is_cfg80211_netdev(st
+@@ -309,7 +309,7 @@ static bool batadv_is_cfg80211_netdev(st
if (!net_device)
return false;
if (!net_device)
return false;
#include <net/dst_metadata.h>
+#include <net/gso.h>
#include <net/page_pool/helpers.h>
#include <net/dst_metadata.h>
+#include <net/gso.h>
#include <net/page_pool/helpers.h>
-@@ -1562,12 +1562,28 @@ static void mtk_wake_queue(struct mtk_et
+@@ -1579,12 +1580,28 @@ static void mtk_wake_queue(struct mtk_et
bool gso = false;
int tx_num;
bool gso = false;
int tx_num;
-@@ -1589,6 +1605,18 @@ static netdev_tx_t mtk_start_xmit(struct
+@@ -1606,6 +1623,18 @@ static netdev_tx_t mtk_start_xmit(struct
/* TSO: fill MSS info in tcp checksum field */
if (skb_is_gso(skb)) {
if (skb_cow_head(skb, 0)) {
/* TSO: fill MSS info in tcp checksum field */
if (skb_is_gso(skb)) {
if (skb_cow_head(skb, 0)) {
-@@ -1604,8 +1632,14 @@ static netdev_tx_t mtk_start_xmit(struct
+@@ -1621,8 +1650,14 @@ static netdev_tx_t mtk_start_xmit(struct
return mtk_eth_mux_setup(eth, path);
--- a/drivers/net/ethernet/mediatek/mtk_eth_soc.c
+++ b/drivers/net/ethernet/mediatek/mtk_eth_soc.c
return mtk_eth_mux_setup(eth, path);
--- a/drivers/net/ethernet/mediatek/mtk_eth_soc.c
+++ b/drivers/net/ethernet/mediatek/mtk_eth_soc.c
#include <linux/pinctrl/devinfo.h>
#include <linux/phylink.h>
#include <linux/pcs/pcs-mtk-lynxi.h>
#include <linux/pinctrl/devinfo.h>
#include <linux/phylink.h>
#include <linux/pcs/pcs-mtk-lynxi.h>
#include <linux/jhash.h>
#include <linux/bitfield.h>
#include <net/dsa.h>
#include <linux/jhash.h>
#include <linux/bitfield.h>
#include <net/dsa.h>
-@@ -258,12 +260,8 @@ static const char * const mtk_clks_sourc
+@@ -261,12 +263,8 @@ static const char * const mtk_clks_sourc
"ethwarp_wocpu2",
"ethwarp_wocpu1",
"ethwarp_wocpu0",
"ethwarp_wocpu2",
"ethwarp_wocpu1",
"ethwarp_wocpu0",
"top_eth_gmii_sel",
"top_eth_refck_50m_sel",
"top_eth_sys_200m_sel",
"top_eth_gmii_sel",
"top_eth_refck_50m_sel",
"top_eth_sys_200m_sel",
-@@ -475,6 +473,30 @@ static void mtk_setup_bridge_switch(stru
+@@ -509,6 +507,30 @@ static void mtk_setup_bridge_switch(stru
static struct phylink_pcs *mtk_mac_select_pcs(struct phylink_config *config,
phy_interface_t interface)
{
static struct phylink_pcs *mtk_mac_select_pcs(struct phylink_config *config,
phy_interface_t interface)
{
-@@ -483,6 +505,21 @@ static struct phylink_pcs *mtk_mac_selec
+@@ -517,6 +539,21 @@ static struct phylink_pcs *mtk_mac_selec
struct mtk_eth *eth = mac->hw;
unsigned int sid;
struct mtk_eth *eth = mac->hw;
unsigned int sid;
if (interface == PHY_INTERFACE_MODE_SGMII ||
phy_interface_mode_is_8023z(interface)) {
sid = (MTK_HAS_CAPS(eth->soc->caps, MTK_SHARED_SGMII)) ?
if (interface == PHY_INTERFACE_MODE_SGMII ||
phy_interface_mode_is_8023z(interface)) {
sid = (MTK_HAS_CAPS(eth->soc->caps, MTK_SHARED_SGMII)) ?
-@@ -544,7 +581,22 @@ static void mtk_mac_config(struct phylin
+@@ -568,7 +605,22 @@ static void mtk_mac_config(struct phylin
break;
default:
goto err_phy;
break;
default:
goto err_phy;
-@@ -599,8 +651,6 @@ static void mtk_mac_config(struct phylin
+@@ -615,8 +667,6 @@ static void mtk_mac_config(struct phylin
val &= ~SYSCFG0_GE_MODE(SYSCFG0_GE_MASK, mac->id);
val |= SYSCFG0_GE_MODE(ge_mode, mac->id);
regmap_write(eth->ethsys, ETHSYS_SYSCFG0, val);
val &= ~SYSCFG0_GE_MODE(SYSCFG0_GE_MASK, mac->id);
val |= SYSCFG0_GE_MODE(ge_mode, mac->id);
regmap_write(eth->ethsys, ETHSYS_SYSCFG0, val);
-@@ -617,21 +667,40 @@ static void mtk_mac_config(struct phylin
+@@ -633,21 +683,40 @@ static void mtk_mac_config(struct phylin
/* Save the syscfg0 value for mac_finish */
mac->syscfg0 = val;
/* Save the syscfg0 value for mac_finish */
mac->syscfg0 = val;
-@@ -644,6 +713,18 @@ init_err:
+@@ -660,6 +729,18 @@ init_err:
mac->id, phy_modes(state->interface), err);
}
mac->id, phy_modes(state->interface), err);
}
static int mtk_mac_finish(struct phylink_config *config, unsigned int mode,
phy_interface_t interface)
{
static int mtk_mac_finish(struct phylink_config *config, unsigned int mode,
phy_interface_t interface)
{
-@@ -652,6 +733,10 @@ static int mtk_mac_finish(struct phylink
+@@ -668,6 +749,10 @@ static int mtk_mac_finish(struct phylink
struct mtk_eth *eth = mac->hw;
u32 mcr_cur, mcr_new;
struct mtk_eth *eth = mac->hw;
u32 mcr_cur, mcr_new;
/* Enable SGMII */
if (interface == PHY_INTERFACE_MODE_SGMII ||
phy_interface_mode_is_8023z(interface))
/* Enable SGMII */
if (interface == PHY_INTERFACE_MODE_SGMII ||
phy_interface_mode_is_8023z(interface))
-@@ -677,10 +762,13 @@ static void mtk_mac_link_down(struct phy
+@@ -693,10 +778,13 @@ static void mtk_mac_link_down(struct phy
{
struct mtk_mac *mac = container_of(config, struct mtk_mac,
phylink_config);
{
struct mtk_mac *mac = container_of(config, struct mtk_mac,
phylink_config);
}
static void mtk_set_queue_speed(struct mtk_eth *eth, unsigned int idx,
}
static void mtk_set_queue_speed(struct mtk_eth *eth, unsigned int idx,
-@@ -752,13 +840,11 @@ static void mtk_set_queue_speed(struct m
+@@ -768,13 +856,11 @@ static void mtk_set_queue_speed(struct m
mtk_w32(eth, val, soc->reg_map->qdma.qtx_sch + ofs);
}
mtk_w32(eth, val, soc->reg_map->qdma.qtx_sch + ofs);
}
u32 mcr;
mcr = mtk_r32(mac->hw, MTK_MAC_MCR(mac->id));
u32 mcr;
mcr = mtk_r32(mac->hw, MTK_MAC_MCR(mac->id));
-@@ -792,9 +878,63 @@ static void mtk_mac_link_up(struct phyli
+@@ -808,9 +894,63 @@ static void mtk_mac_link_up(struct phyli
mtk_w32(mac->hw, mcr, MTK_MAC_MCR(mac->id));
}
mtk_w32(mac->hw, mcr, MTK_MAC_MCR(mac->id));
}
.mac_finish = mtk_mac_finish,
.mac_link_down = mtk_mac_link_down,
.mac_link_up = mtk_mac_link_up,
.mac_finish = mtk_mac_finish,
.mac_link_down = mtk_mac_link_down,
.mac_link_up = mtk_mac_link_up,
-@@ -3373,6 +3513,9 @@ static int mtk_open(struct net_device *d
+@@ -3391,6 +3531,9 @@ static int mtk_open(struct net_device *d
struct mtk_eth *eth = mac->hw;
int i, err;
struct mtk_eth *eth = mac->hw;
int i, err;
err = phylink_of_phy_connect(mac->phylink, mac->of_node, 0);
if (err) {
netdev_err(dev, "%s: could not attach PHY: %d\n", __func__,
err = phylink_of_phy_connect(mac->phylink, mac->of_node, 0);
if (err) {
netdev_err(dev, "%s: could not attach PHY: %d\n", __func__,
-@@ -3501,6 +3644,9 @@ static int mtk_stop(struct net_device *d
+@@ -3520,6 +3663,9 @@ static int mtk_stop(struct net_device *d
for (i = 0; i < ARRAY_SIZE(eth->ppe); i++)
mtk_ppe_stop(eth->ppe[i]);
for (i = 0; i < ARRAY_SIZE(eth->ppe); i++)
mtk_ppe_stop(eth->ppe[i]);
-@@ -4498,6 +4644,7 @@ static const struct net_device_ops mtk_n
+@@ -4517,6 +4663,7 @@ static const struct net_device_ops mtk_n
static int mtk_add_mac(struct mtk_eth *eth, struct device_node *np)
{
const __be32 *_id = of_get_property(np, "reg", NULL);
static int mtk_add_mac(struct mtk_eth *eth, struct device_node *np)
{
const __be32 *_id = of_get_property(np, "reg", NULL);
phy_interface_t phy_mode;
struct phylink *phylink;
struct mtk_mac *mac;
phy_interface_t phy_mode;
struct phylink *phylink;
struct mtk_mac *mac;
-@@ -4533,16 +4680,41 @@ static int mtk_add_mac(struct mtk_eth *e
+@@ -4553,16 +4700,41 @@ static int mtk_add_mac(struct mtk_eth *e
mac->id = id;
mac->hw = eth;
mac->of_node = np;
mac->id = id;
mac->hw = eth;
mac->of_node = np;
}
memset(mac->hwlro_ip, 0, sizeof(mac->hwlro_ip));
}
memset(mac->hwlro_ip, 0, sizeof(mac->hwlro_ip));
-@@ -4616,8 +4788,21 @@ static int mtk_add_mac(struct mtk_eth *e
+@@ -4645,8 +4817,21 @@ static int mtk_add_mac(struct mtk_eth *e
phy_interface_zero(mac->phylink_config.supported_interfaces);
__set_bit(PHY_INTERFACE_MODE_INTERNAL,
mac->phylink_config.supported_interfaces);
phy_interface_zero(mac->phylink_config.supported_interfaces);
__set_bit(PHY_INTERFACE_MODE_INTERNAL,
mac->phylink_config.supported_interfaces);
phylink = phylink_create(&mac->phylink_config,
of_fwnode_handle(mac->of_node),
phy_mode, &mtk_phylink_ops);
phylink = phylink_create(&mac->phylink_config,
of_fwnode_handle(mac->of_node),
phy_mode, &mtk_phylink_ops);
-@@ -4662,6 +4847,26 @@ free_netdev:
+@@ -4697,6 +4882,26 @@ free_netdev:
void mtk_eth_set_dma_device(struct mtk_eth *eth, struct device *dma_dev)
{
struct net_device *dev, *tmp;
void mtk_eth_set_dma_device(struct mtk_eth *eth, struct device *dma_dev)
{
struct net_device *dev, *tmp;
-@@ -4805,7 +5010,8 @@ static int mtk_probe(struct platform_dev
+@@ -4843,7 +5048,8 @@ static int mtk_probe(struct platform_dev
regmap_write(cci, 0, 3);
}
regmap_write(cci, 0, 3);
}
err = mtk_sgmii_init(eth);
if (err)
err = mtk_sgmii_init(eth);
if (err)
-@@ -4916,6 +5122,24 @@ static int mtk_probe(struct platform_dev
+@@ -4954,6 +5160,24 @@ static int mtk_probe(struct platform_dev
if (MTK_HAS_CAPS(eth->soc->caps, MTK_SHARED_INT)) {
err = devm_request_irq(eth->dev, eth->irq[0],
mtk_handle_irq, 0,
if (MTK_HAS_CAPS(eth->soc->caps, MTK_SHARED_INT)) {
err = devm_request_irq(eth->dev, eth->irq[0],
mtk_handle_irq, 0,
-@@ -5018,6 +5242,11 @@ static int mtk_remove(struct platform_de
+@@ -5056,6 +5280,11 @@ static int mtk_remove(struct platform_de
mtk_stop(eth->netdev[i]);
mac = netdev_priv(eth->netdev[i]);
phylink_disconnect_phy(mac->phylink);
mtk_stop(eth->netdev[i]);
mac = netdev_priv(eth->netdev[i]);
phylink_disconnect_phy(mac->phylink);
static int mtk_pcs_lynxi_config(struct phylink_pcs *pcs, unsigned int neg_mode,
phy_interface_t interface,
const unsigned long *advertising,
static int mtk_pcs_lynxi_config(struct phylink_pcs *pcs, unsigned int neg_mode,
phy_interface_t interface,
const unsigned long *advertising,
-@@ -148,6 +181,7 @@ static int mtk_pcs_lynxi_config(struct p
+@@ -147,6 +180,7 @@ static int mtk_pcs_lynxi_config(struct p
SGMII_PHYA_PWD);
/* Reset SGMII PCS state */
SGMII_PHYA_PWD);
/* Reset SGMII PCS state */
regmap_set_bits(mpcs->regmap, SGMSYS_RESERVED_0,
SGMII_SW_RESET);
regmap_set_bits(mpcs->regmap, SGMSYS_RESERVED_0,
SGMII_SW_RESET);
-@@ -234,10 +268,29 @@ static void mtk_pcs_lynxi_link_up(struct
+@@ -233,10 +267,29 @@ static void mtk_pcs_lynxi_link_up(struct
mpcs->interface = PHY_INTERFACE_MODE_NA;
}
mpcs->interface = PHY_INTERFACE_MODE_NA;
}
-@@ -247,11 +300,12 @@ static const struct phylink_pcs_ops mtk_
+@@ -246,11 +299,12 @@ static const struct phylink_pcs_ops mtk_
.pcs_an_restart = mtk_pcs_lynxi_restart_an,
.pcs_link_up = mtk_pcs_lynxi_link_up,
.pcs_disable = mtk_pcs_lynxi_disable,
.pcs_an_restart = mtk_pcs_lynxi_restart_an,
.pcs_link_up = mtk_pcs_lynxi_link_up,
.pcs_disable = mtk_pcs_lynxi_disable,
{
struct mtk_pcs_lynxi *mpcs;
u32 id, ver;
{
struct mtk_pcs_lynxi *mpcs;
u32 id, ver;
-@@ -259,29 +313,33 @@ struct phylink_pcs *mtk_pcs_lynxi_create
+@@ -258,29 +312,33 @@ struct phylink_pcs *mtk_pcs_lynxi_create
ret = regmap_read(regmap, SGMSYS_PCS_DEVICE_ID, &id);
if (ret < 0)
ret = regmap_read(regmap, SGMSYS_PCS_DEVICE_ID, &id);
if (ret < 0)
mpcs->ana_rgc3 = ana_rgc3;
mpcs->regmap = regmap;
mpcs->ana_rgc3 = ana_rgc3;
mpcs->regmap = regmap;
-@@ -292,6 +350,13 @@ struct phylink_pcs *mtk_pcs_lynxi_create
+@@ -291,6 +349,13 @@ struct phylink_pcs *mtk_pcs_lynxi_create
mpcs->interface = PHY_INTERFACE_MODE_NA;
return &mpcs->pcs;
mpcs->interface = PHY_INTERFACE_MODE_NA;
return &mpcs->pcs;
}
EXPORT_SYMBOL(mtk_pcs_lynxi_create);
}
EXPORT_SYMBOL(mtk_pcs_lynxi_create);
-@@ -304,4 +369,144 @@ void mtk_pcs_lynxi_destroy(struct phylin
+@@ -303,4 +368,144 @@ void mtk_pcs_lynxi_destroy(struct phylin
}
EXPORT_SYMBOL(mtk_pcs_lynxi_destroy);
}
EXPORT_SYMBOL(mtk_pcs_lynxi_destroy);
--- a/MAINTAINERS
+++ b/MAINTAINERS
--- a/MAINTAINERS
+++ b/MAINTAINERS
-@@ -12934,7 +12934,9 @@ M: Daniel Golle <daniel@makrotopia.org>
+@@ -13348,7 +13348,9 @@ M: Daniel Golle <daniel@makrotopia.org>
L: netdev@vger.kernel.org
S: Maintained
F: drivers/net/pcs/pcs-mtk-lynxi.c
L: netdev@vger.kernel.org
S: Maintained
F: drivers/net/pcs/pcs-mtk-lynxi.c
M: Daniel Golle <daniel@makrotopia.org>
--- a/drivers/net/pcs/Kconfig
+++ b/drivers/net/pcs/Kconfig
M: Daniel Golle <daniel@makrotopia.org>
--- a/drivers/net/pcs/Kconfig
+++ b/drivers/net/pcs/Kconfig
-@@ -18,6 +18,17 @@ config PCS_LYNX
+@@ -25,6 +25,17 @@ config PCS_MTK_LYNXI
This module provides helpers to phylink for managing the LynxI PCS
which is part of MediaTek's SoC and Ethernet switch ICs.
This module provides helpers to phylink for managing the LynxI PCS
which is part of MediaTek's SoC and Ethernet switch ICs.
depends on OF && (ARCH_RZN1 || COMPILE_TEST)
--- a/drivers/net/pcs/Makefile
+++ b/drivers/net/pcs/Makefile
depends on OF && (ARCH_RZN1 || COMPILE_TEST)
--- a/drivers/net/pcs/Makefile
+++ b/drivers/net/pcs/Makefile
-@@ -8,3 +8,4 @@ obj-$(CONFIG_PCS_XPCS) += pcs_xpcs.o
+@@ -7,3 +7,4 @@ obj-$(CONFIG_PCS_XPCS) += pcs_xpcs.o
obj-$(CONFIG_PCS_LYNX) += pcs-lynx.o
obj-$(CONFIG_PCS_MTK_LYNXI) += pcs-mtk-lynxi.o
obj-$(CONFIG_PCS_RZN1_MIIC) += pcs-rzn1-miic.o
obj-$(CONFIG_PCS_LYNX) += pcs-lynx.o
obj-$(CONFIG_PCS_MTK_LYNXI) += pcs-mtk-lynxi.o
obj-$(CONFIG_PCS_RZN1_MIIC) += pcs-rzn1-miic.o
--- a/drivers/net/phy/realtek.c
+++ b/drivers/net/phy/realtek.c
--- a/drivers/net/phy/realtek.c
+++ b/drivers/net/phy/realtek.c
-@@ -981,6 +981,51 @@ static int rtl8221b_config_init(struct p
+@@ -1009,6 +1009,51 @@ static int rtl8221b_config_init(struct p
static struct phy_driver realtek_drvs[] = {
{
PHY_ID_MATCH_EXACT(0x00008201),
static struct phy_driver realtek_drvs[] = {
{
PHY_ID_MATCH_EXACT(0x00008201),
-@@ -1141,6 +1186,8 @@ static struct phy_driver realtek_drvs[]
+@@ -1171,6 +1216,8 @@ static struct phy_driver realtek_drvs[]
.get_features = rtl822x_get_features,
.config_init = rtl8221b_config_init,
.config_aneg = rtl822x_config_aneg,
.get_features = rtl822x_get_features,
.config_init = rtl8221b_config_init,
.config_aneg = rtl822x_config_aneg,
--- a/drivers/net/phy/Kconfig
+++ b/drivers/net/phy/Kconfig
--- a/drivers/net/phy/Kconfig
+++ b/drivers/net/phy/Kconfig
-@@ -69,6 +69,11 @@ config SFP
+@@ -68,6 +68,11 @@ config SFP
comment "MII PHY device drivers"
comment "MII PHY device drivers"
help
--- a/drivers/net/phy/Makefile
+++ b/drivers/net/phy/Makefile
help
--- a/drivers/net/phy/Makefile
+++ b/drivers/net/phy/Makefile
-@@ -32,6 +32,7 @@ obj-y += $(sfp-obj-y) $(sfp-obj-m)
+@@ -34,6 +34,7 @@ obj-y += $(sfp-obj-y) $(sfp-obj-m)
obj-$(CONFIG_ADIN_PHY) += adin.o
obj-$(CONFIG_ADIN1100_PHY) += adin1100.o
obj-$(CONFIG_ADIN_PHY) += adin.o
obj-$(CONFIG_ADIN1100_PHY) += adin1100.o
--- a/include/linux/netdevice.h
+++ b/include/linux/netdevice.h
--- a/include/linux/netdevice.h
+++ b/include/linux/netdevice.h
-@@ -543,6 +543,7 @@ static inline bool napi_complete(struct
+@@ -558,6 +558,7 @@ static inline bool napi_complete(struct
}
int dev_set_threaded(struct net_device *dev, bool threaded);
}
int dev_set_threaded(struct net_device *dev, bool threaded);
/**
* napi_disable - prevent NAPI from scheduling
/**
* napi_disable - prevent NAPI from scheduling
-@@ -3129,6 +3130,7 @@ struct softnet_data {
+@@ -3238,6 +3239,7 @@ struct softnet_data {
/* stats */
unsigned int processed;
unsigned int time_squeeze;
/* stats */
unsigned int processed;
unsigned int time_squeeze;
#endif
--- a/net/core/dev.c
+++ b/net/core/dev.c
#endif
--- a/net/core/dev.c
+++ b/net/core/dev.c
-@@ -4625,7 +4625,7 @@ static int napi_schedule_rps(struct soft
+@@ -4729,7 +4729,7 @@ static void napi_schedule_rps(struct sof
struct softnet_data *mysd = this_cpu_ptr(&softnet_data);
#ifdef CONFIG_RPS
struct softnet_data *mysd = this_cpu_ptr(&softnet_data);
#ifdef CONFIG_RPS
sd->rps_ipi_next = mysd->rps_ipi_list;
mysd->rps_ipi_list = sd;
sd->rps_ipi_next = mysd->rps_ipi_list;
mysd->rps_ipi_list = sd;
-@@ -5806,6 +5806,8 @@ static DEFINE_PER_CPU(struct work_struct
+@@ -5848,6 +5848,8 @@ static DEFINE_PER_CPU(struct work_struct
/* Network device is going away, flush any packets still pending */
static void flush_backlog(struct work_struct *work)
{
/* Network device is going away, flush any packets still pending */
static void flush_backlog(struct work_struct *work)
{
struct sk_buff *skb, *tmp;
struct softnet_data *sd;
struct sk_buff *skb, *tmp;
struct softnet_data *sd;
-@@ -5820,8 +5822,17 @@ static void flush_backlog(struct work_st
+@@ -5862,8 +5864,17 @@ static void flush_backlog(struct work_st
input_queue_head_incr(sd);
}
}
input_queue_head_incr(sd);
}
}
skb_queue_walk_safe(&sd->process_queue, skb, tmp) {
if (skb->dev->reg_state == NETREG_UNREGISTERING) {
__skb_unlink(skb, &sd->process_queue);
skb_queue_walk_safe(&sd->process_queue, skb, tmp) {
if (skb->dev->reg_state == NETREG_UNREGISTERING) {
__skb_unlink(skb, &sd->process_queue);
-@@ -5829,7 +5840,16 @@ static void flush_backlog(struct work_st
+@@ -5871,7 +5882,16 @@ static void flush_backlog(struct work_st
input_queue_head_incr(sd);
}
}
input_queue_head_incr(sd);
}
}
}
static bool flush_required(int cpu)
}
static bool flush_required(int cpu)
-@@ -5961,6 +5981,7 @@ static int process_backlog(struct napi_s
+@@ -6003,6 +6023,7 @@ static int process_backlog(struct napi_s
}
rps_lock_irq_disable(sd);
}
rps_lock_irq_disable(sd);
if (skb_queue_empty(&sd->input_pkt_queue)) {
/*
* Inline a custom version of __napi_complete().
if (skb_queue_empty(&sd->input_pkt_queue)) {
/*
* Inline a custom version of __napi_complete().
-@@ -5970,7 +5991,8 @@ static int process_backlog(struct napi_s
+@@ -6012,7 +6033,8 @@ static int process_backlog(struct napi_s
* We can use a plain write instead of clear_bit(),
* and we dont need an smp_mb() memory barrier.
*/
* We can use a plain write instead of clear_bit(),
* and we dont need an smp_mb() memory barrier.
*/
again = false;
} else {
skb_queue_splice_tail_init(&sd->input_pkt_queue,
again = false;
} else {
skb_queue_splice_tail_init(&sd->input_pkt_queue,
-@@ -6386,6 +6408,55 @@ int dev_set_threaded(struct net_device *
+@@ -6426,6 +6448,55 @@ int dev_set_threaded(struct net_device *
}
EXPORT_SYMBOL(dev_set_threaded);
}
EXPORT_SYMBOL(dev_set_threaded);
void netif_napi_add_weight(struct net_device *dev, struct napi_struct *napi,
int (*poll)(struct napi_struct *, int), int weight)
{
void netif_napi_add_weight(struct net_device *dev, struct napi_struct *napi,
int (*poll)(struct napi_struct *, int), int weight)
{
-@@ -11168,6 +11239,9 @@ static int dev_cpu_dead(unsigned int old
+@@ -11348,6 +11419,9 @@ static int dev_cpu_dead(unsigned int old
raise_softirq_irqoff(NET_TX_SOFTIRQ);
local_irq_enable();
raise_softirq_irqoff(NET_TX_SOFTIRQ);
local_irq_enable();
#ifdef CONFIG_RPS
remsd = oldsd->rps_ipi_list;
oldsd->rps_ipi_list = NULL;
#ifdef CONFIG_RPS
remsd = oldsd->rps_ipi_list;
oldsd->rps_ipi_list = NULL;
-@@ -11480,6 +11554,7 @@ static int __init net_dev_init(void)
+@@ -11663,6 +11737,7 @@ static int __init net_dev_init(void)
INIT_CSD(&sd->defer_csd, trigger_rx_softirq, sd);
spin_lock_init(&sd->defer_lock);
INIT_CSD(&sd->defer_csd, trigger_rx_softirq, sd);
spin_lock_init(&sd->defer_lock);
sd->backlog.weight = weight_p;
--- a/net/core/sysctl_net_core.c
+++ b/net/core/sysctl_net_core.c
sd->backlog.weight = weight_p;
--- a/net/core/sysctl_net_core.c
+++ b/net/core/sysctl_net_core.c
-@@ -29,6 +29,7 @@ static int int_3600 = 3600;
+@@ -30,6 +30,7 @@ static int int_3600 = 3600;
static int min_sndbuf = SOCK_MIN_SNDBUF;
static int min_rcvbuf = SOCK_MIN_RCVBUF;
static int max_skb_frags = MAX_SKB_FRAGS;
static int min_sndbuf = SOCK_MIN_SNDBUF;
static int min_rcvbuf = SOCK_MIN_RCVBUF;
static int max_skb_frags = MAX_SKB_FRAGS;
static int net_msg_warn; /* Unused, but still a sysctl */
static int net_msg_warn; /* Unused, but still a sysctl */
-@@ -112,6 +113,23 @@ static int rps_sock_flow_sysctl(struct c
+@@ -188,6 +189,23 @@ static int rps_sock_flow_sysctl(struct c
}
#endif /* CONFIG_RPS */
}
#endif /* CONFIG_RPS */
#ifdef CONFIG_NET_FLOW_LIMIT
static DEFINE_MUTEX(flow_limit_update_mutex);
#ifdef CONFIG_NET_FLOW_LIMIT
static DEFINE_MUTEX(flow_limit_update_mutex);
-@@ -473,6 +491,15 @@ static struct ctl_table net_core_table[]
+@@ -532,6 +550,15 @@ static struct ctl_table net_core_table[]
.proc_handler = rps_sock_flow_sysctl
},
#endif
.proc_handler = rps_sock_flow_sysctl
},
#endif
--- a/drivers/net/dsa/mv88e6xxx/chip.c
+++ b/drivers/net/dsa/mv88e6xxx/chip.c
--- a/drivers/net/dsa/mv88e6xxx/chip.c
+++ b/drivers/net/dsa/mv88e6xxx/chip.c
-@@ -7025,6 +7025,7 @@ static int mv88e6xxx_register_switch(str
+@@ -6883,6 +6883,7 @@ static int mv88e6xxx_register_switch(str
ds->ops = &mv88e6xxx_switch_ops;
ds->ageing_time_min = chip->info->age_time_coeff;
ds->ageing_time_max = chip->info->age_time_coeff * U8_MAX;
ds->ops = &mv88e6xxx_switch_ops;
ds->ageing_time_min = chip->info->age_time_coeff;
ds->ageing_time_max = chip->info->age_time_coeff * U8_MAX;
--- a/drivers/net/vxlan/vxlan_core.c
+++ b/drivers/net/vxlan/vxlan_core.c
--- a/drivers/net/vxlan/vxlan_core.c
+++ b/drivers/net/vxlan/vxlan_core.c
-@@ -1493,6 +1493,10 @@ static bool vxlan_snoop(struct net_devic
+@@ -1446,6 +1446,10 @@ static bool vxlan_snoop(struct net_devic
struct vxlan_fdb *f;
u32 ifindex = 0;
struct vxlan_fdb *f;
u32 ifindex = 0;
--- a/drivers/net/dsa/mt7530.c
+++ b/drivers/net/dsa/mt7530.c
--- a/drivers/net/dsa/mt7530.c
+++ b/drivers/net/dsa/mt7530.c
-@@ -2142,10 +2142,13 @@ mt7530_setup_mdio(struct mt7530_priv *pr
+@@ -2156,10 +2156,13 @@ mt7530_setup_mdio(struct mt7530_priv *pr
{
struct dsa_switch *ds = priv->ds;
struct device *dev = priv->dev;
{
struct dsa_switch *ds = priv->ds;
struct device *dev = priv->dev;
bus = devm_mdiobus_alloc(dev);
if (!bus)
return -ENOMEM;
bus = devm_mdiobus_alloc(dev);
if (!bus)
return -ENOMEM;
-@@ -2162,7 +2165,9 @@ mt7530_setup_mdio(struct mt7530_priv *pr
+@@ -2178,7 +2181,9 @@ mt7530_setup_mdio(struct mt7530_priv *pr
if (priv->irq)
mt7530_setup_mdio_irq(priv);
if (priv->irq)
mt7530_setup_mdio_irq(priv);
if (err)
--- a/drivers/bcma/main.c
+++ b/drivers/bcma/main.c
if (err)
--- a/drivers/bcma/main.c
+++ b/drivers/bcma/main.c
-@@ -236,13 +236,17 @@ EXPORT_SYMBOL(bcma_core_irq);
+@@ -237,13 +237,17 @@ EXPORT_SYMBOL(bcma_core_irq);
void bcma_prepare_core(struct bcma_bus *bus, struct bcma_device *core)
{
void bcma_prepare_core(struct bcma_bus *bus, struct bcma_device *core)
{
--- a/drivers/gpio/Kconfig
+++ b/drivers/gpio/Kconfig
--- a/drivers/gpio/Kconfig
+++ b/drivers/gpio/Kconfig
-@@ -1711,4 +1711,19 @@ config GPIO_SIM
+@@ -1819,4 +1819,19 @@ config GPIO_SIM
endif
--- a/drivers/gpio/Makefile
+++ b/drivers/gpio/Makefile
endif
--- a/drivers/gpio/Makefile
+++ b/drivers/gpio/Makefile
-@@ -43,6 +43,7 @@ obj-$(CONFIG_GPIO_BD9571MWV) += gpio-bd
+@@ -44,6 +44,7 @@ obj-$(CONFIG_GPIO_BD9571MWV) += gpio-bd
obj-$(CONFIG_GPIO_BRCMSTB) += gpio-brcmstb.o
obj-$(CONFIG_GPIO_BT8XX) += gpio-bt8xx.o
obj-$(CONFIG_GPIO_CADENCE) += gpio-cadence.o
obj-$(CONFIG_GPIO_BRCMSTB) += gpio-brcmstb.o
obj-$(CONFIG_GPIO_BT8XX) += gpio-bt8xx.o
obj-$(CONFIG_GPIO_CADENCE) += gpio-cadence.o
return 0;
--- a/drivers/opp/core.c
+++ b/drivers/opp/core.c
return 0;
--- a/drivers/opp/core.c
+++ b/drivers/opp/core.c
-@@ -816,7 +816,8 @@ static int _set_opp_voltage(struct devic
+@@ -902,7 +902,8 @@ static int _set_opp_voltage(struct devic
static int
_opp_config_clk_single(struct device *dev, struct opp_table *opp_table,
static int
_opp_config_clk_single(struct device *dev, struct opp_table *opp_table,
{
unsigned long *target = data;
unsigned long freq;
{
unsigned long *target = data;
unsigned long freq;
-@@ -848,8 +849,8 @@ _opp_config_clk_single(struct device *de
+@@ -934,8 +935,8 @@ _opp_config_clk_single(struct device *de
* the order in which they are present in the array while scaling up.
*/
int dev_pm_opp_config_clks_simple(struct device *dev,
* the order in which they are present in the array while scaling up.
*/
int dev_pm_opp_config_clks_simple(struct device *dev,
-@@ -1121,7 +1122,7 @@ static int _set_opp(struct device *dev,
+@@ -1217,7 +1218,7 @@ static int _set_opp(struct device *dev,
}
if (opp_table->config_clks) {
}
if (opp_table->config_clks) {
-@@ -1196,7 +1197,7 @@ int dev_pm_opp_set_rate(struct device *d
+@@ -1292,7 +1293,7 @@ int dev_pm_opp_set_rate(struct device *d
* equivalent to a clk_set_rate()
*/
if (!_get_opp_count(opp_table)) {
* equivalent to a clk_set_rate()
*/
if (!_get_opp_count(opp_table)) {
struct dev_pm_opp *opp, void *data, bool scaling_down);
/**
struct dev_pm_opp *opp, void *data, bool scaling_down);
/**
-@@ -160,8 +161,8 @@ int dev_pm_opp_set_config(struct device
+@@ -172,8 +173,8 @@ int dev_pm_opp_set_config(struct device
int devm_pm_opp_set_config(struct device *dev, struct dev_pm_opp_config *config);
void dev_pm_opp_clear_config(int token);
int dev_pm_opp_config_clks_simple(struct device *dev,
int devm_pm_opp_set_config(struct device *dev, struct dev_pm_opp_config *config);
void dev_pm_opp_clear_config(int token);
int dev_pm_opp_config_clks_simple(struct device *dev,
struct dev_pm_opp *dev_pm_opp_xlate_required_opp(struct opp_table *src_table, struct opp_table *dst_table, struct dev_pm_opp *src_opp);
int dev_pm_opp_xlate_performance_state(struct opp_table *src_table, struct opp_table *dst_table, unsigned int pstate);
struct dev_pm_opp *dev_pm_opp_xlate_required_opp(struct opp_table *src_table, struct opp_table *dst_table, struct dev_pm_opp *src_opp);
int dev_pm_opp_xlate_performance_state(struct opp_table *src_table, struct opp_table *dst_table, unsigned int pstate);
-@@ -346,8 +347,8 @@ static inline int devm_pm_opp_set_config
+@@ -377,8 +378,8 @@ static inline int devm_pm_opp_set_config
static inline void dev_pm_opp_clear_config(int token) {}
static inline int dev_pm_opp_config_clks_simple(struct device *dev,
static inline void dev_pm_opp_clear_config(int token) {}
static inline int dev_pm_opp_config_clks_simple(struct device *dev,
#include <linux/init.h>
#include <linux/kref.h>
#include <linux/module.h>
#include <linux/init.h>
#include <linux/kref.h>
#include <linux/module.h>
-@@ -780,6 +783,62 @@ static int nvmem_validate_keepouts(struc
+@@ -779,6 +782,62 @@ static int nvmem_validate_keepouts(struc
static int nvmem_add_cells_from_dt(struct nvmem_device *nvmem, struct device_node *np)
{
struct device *dev = &nvmem->dev;
static int nvmem_add_cells_from_dt(struct nvmem_device *nvmem, struct device_node *np)
{
struct device *dev = &nvmem->dev;
-@@ -814,6 +873,25 @@ static int nvmem_add_cells_from_dt(struc
+@@ -813,6 +872,25 @@ static int nvmem_add_cells_from_dt(struc
if (nvmem->fixup_dt_cell_info)
nvmem->fixup_dt_cell_info(nvmem, &info);
if (nvmem->fixup_dt_cell_info)
nvmem->fixup_dt_cell_info(nvmem, &info);
--- a/drivers/pci/Kconfig
+++ b/drivers/pci/Kconfig
--- a/drivers/pci/Kconfig
+++ b/drivers/pci/Kconfig
-@@ -118,6 +118,13 @@ config XEN_PCIDEV_FRONTEND
+@@ -113,6 +113,13 @@ config XEN_PCIDEV_FRONTEND
The PCI device frontend driver allows the kernel to import arbitrary
PCI devices from a PCI backend to support PCI driver domains.
The PCI device frontend driver allows the kernel to import arbitrary
PCI devices from a PCI backend to support PCI driver domains.
--- a/drivers/pci/quirks.c
+++ b/drivers/pci/quirks.c
--- a/drivers/pci/quirks.c
+++ b/drivers/pci/quirks.c
-@@ -207,6 +207,7 @@ static void quirk_mmio_always_on(struct
+@@ -300,6 +300,7 @@ static void quirk_mmio_always_on(struct
DECLARE_PCI_FIXUP_CLASS_EARLY(PCI_ANY_ID, PCI_ANY_ID,
PCI_CLASS_BRIDGE_HOST, 8, quirk_mmio_always_on);
DECLARE_PCI_FIXUP_CLASS_EARLY(PCI_ANY_ID, PCI_ANY_ID,
PCI_CLASS_BRIDGE_HOST, 8, quirk_mmio_always_on);
/*
* The Mellanox Tavor device gives false positive parity errors. Disable
* parity error reporting.
/*
* The Mellanox Tavor device gives false positive parity errors. Disable
* parity error reporting.
-@@ -3393,6 +3394,8 @@ DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_I
+@@ -3488,6 +3489,8 @@ DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_I
DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_INTEL, 0x65f9, quirk_intel_mc_errata);
DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_INTEL, 0x65fa, quirk_intel_mc_errata);
DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_INTEL, 0x65f9, quirk_intel_mc_errata);
DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_INTEL, 0x65fa, quirk_intel_mc_errata);
/*
* Ivytown NTB BAR sizes are misreported by the hardware due to an erratum.
* To work around this, query the size it should be configured to by the
/*
* Ivytown NTB BAR sizes are misreported by the hardware due to an erratum.
* To work around this, query the size it should be configured to by the
-@@ -3418,6 +3421,8 @@ static void quirk_intel_ntb(struct pci_d
+@@ -3513,6 +3516,8 @@ static void quirk_intel_ntb(struct pci_d
DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_INTEL, 0x0e08, quirk_intel_ntb);
DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_INTEL, 0x0e0d, quirk_intel_ntb);
DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_INTEL, 0x0e08, quirk_intel_ntb);
DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_INTEL, 0x0e0d, quirk_intel_ntb);
/*
* Some BIOS implementations leave the Intel GPU interrupts enabled, even
* though no one is handling them (e.g., if the i915 driver is never
/*
* Some BIOS implementations leave the Intel GPU interrupts enabled, even
* though no one is handling them (e.g., if the i915 driver is never
-@@ -3456,6 +3461,8 @@ DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_IN
+@@ -3551,6 +3556,8 @@ DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_IN
DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_INTEL, 0x010a, disable_igfx_irq);
DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_INTEL, 0x0152, disable_igfx_irq);
DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_INTEL, 0x010a, disable_igfx_irq);
DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_INTEL, 0x0152, disable_igfx_irq);
static struct amd_chipset_info {
struct pci_dev *nb_dev;
struct pci_dev *smbus_dev;
static struct amd_chipset_info {
struct pci_dev *nb_dev;
struct pci_dev *smbus_dev;
-@@ -633,6 +635,10 @@ bool usb_amd_pt_check_port(struct device
+@@ -631,6 +633,10 @@ bool usb_amd_pt_check_port(struct device
}
EXPORT_SYMBOL_GPL(usb_amd_pt_check_port);
}
EXPORT_SYMBOL_GPL(usb_amd_pt_check_port);
/*
* Make sure the controller is completely inactive, unable to
* generate interrupts or do DMA.
/*
* Make sure the controller is completely inactive, unable to
* generate interrupts or do DMA.
-@@ -712,8 +718,17 @@ reset_needed:
+@@ -710,8 +716,17 @@ reset_needed:
uhci_reset_hc(pdev, base);
return 1;
}
uhci_reset_hc(pdev, base);
return 1;
}
static inline int io_type_enabled(struct pci_dev *pdev, unsigned int mask)
{
u16 cmd;
static inline int io_type_enabled(struct pci_dev *pdev, unsigned int mask)
{
u16 cmd;
-@@ -1285,3 +1300,4 @@ static void quirk_usb_early_handoff(stru
+@@ -1283,3 +1298,4 @@ static void quirk_usb_early_handoff(stru
}
DECLARE_PCI_FIXUP_CLASS_FINAL(PCI_ANY_ID, PCI_ANY_ID,
PCI_CLASS_SERIAL_USB, 8, quirk_usb_early_handoff);
}
DECLARE_PCI_FIXUP_CLASS_FINAL(PCI_ANY_ID, PCI_ANY_ID,
PCI_CLASS_SERIAL_USB, 8, quirk_usb_early_handoff);
#endif /* __LINUX_USB_PCI_QUIRKS_H */
--- a/include/linux/usb/hcd.h
+++ b/include/linux/usb/hcd.h
#endif /* __LINUX_USB_PCI_QUIRKS_H */
--- a/include/linux/usb/hcd.h
+++ b/include/linux/usb/hcd.h
-@@ -483,7 +483,14 @@ extern int usb_hcd_pci_probe(struct pci_
+@@ -484,7 +484,14 @@ extern int usb_hcd_pci_probe(struct pci_
extern void usb_hcd_pci_remove(struct pci_dev *dev);
extern void usb_hcd_pci_shutdown(struct pci_dev *dev);
extern void usb_hcd_pci_remove(struct pci_dev *dev);
extern void usb_hcd_pci_shutdown(struct pci_dev *dev);
depends on ACPI
--- a/drivers/ata/libata-core.c
+++ b/drivers/ata/libata-core.c
depends on ACPI
--- a/drivers/ata/libata-core.c
+++ b/drivers/ata/libata-core.c
-@@ -663,6 +663,19 @@ u64 ata_tf_read_block(const struct ata_t
+@@ -685,6 +685,19 @@ static inline void ata_set_tf_cdl(struct
qc->flags |= ATA_QCFLAG_HAS_CDL | ATA_QCFLAG_RESULT_TF;
}
qc->flags |= ATA_QCFLAG_HAS_CDL | ATA_QCFLAG_RESULT_TF;
}
/**
* ata_build_rw_tf - Build ATA taskfile for given read/write request
* @qc: Metadata associated with the taskfile to build
/**
* ata_build_rw_tf - Build ATA taskfile for given read/write request
* @qc: Metadata associated with the taskfile to build
-@@ -4716,6 +4729,9 @@ void __ata_qc_complete(struct ata_queued
+@@ -4771,6 +4784,9 @@ void __ata_qc_complete(struct ata_queued
link->active_tag = ATA_TAG_POISON;
ap->nr_active_links--;
}
link->active_tag = ATA_TAG_POISON;
ap->nr_active_links--;
}
/* clear exclusive status */
if (unlikely(qc->flags & ATA_QCFLAG_CLEAR_EXCL &&
/* clear exclusive status */
if (unlikely(qc->flags & ATA_QCFLAG_CLEAR_EXCL &&
-@@ -5438,6 +5454,9 @@ struct ata_port *ata_port_alloc(struct a
+@@ -5494,6 +5510,9 @@ struct ata_port *ata_port_alloc(struct a
ap->stats.unhandled_irq = 1;
ap->stats.idle_irq = 1;
#endif
ap->stats.unhandled_irq = 1;
ap->stats.idle_irq = 1;
#endif
ata_sff_port_init(ap);
return ap;
ata_sff_port_init(ap);
return ap;
-@@ -5469,6 +5488,12 @@ static void ata_host_release(struct kref
+@@ -5530,6 +5549,12 @@ static void ata_host_release(struct kref
kfree(ap->pmp_link);
kfree(ap->slave_link);
kfree(ap->ncq_sense_buf);
kfree(ap->pmp_link);
kfree(ap->slave_link);
kfree(ap->ncq_sense_buf);
kfree(ap);
host->ports[i] = NULL;
}
kfree(ap);
host->ports[i] = NULL;
}
-@@ -5875,7 +5900,23 @@ int ata_host_register(struct ata_host *h
+@@ -5920,7 +5945,23 @@ int ata_host_register(struct ata_host *h
host->ports[i]->print_id = atomic_inc_return(&ata_print_id);
host->ports[i]->local_port_no = i + 1;
}
host->ports[i]->print_id = atomic_inc_return(&ata_print_id);
host->ports[i]->local_port_no = i + 1;
}
/*
* Define if arch has non-standard setup. This is a _PCI_ standard
/*
* Define if arch has non-standard setup. This is a _PCI_ standard
-@@ -864,6 +867,12 @@ struct ata_port {
+@@ -874,6 +877,12 @@ struct ata_port {
#ifdef CONFIG_ATA_ACPI
struct ata_acpi_gtm __acpi_init_gtm; /* use ata_acpi_init_gtm() */
#endif
#ifdef CONFIG_ATA_ACPI
struct ata_acpi_gtm __acpi_init_gtm; /* use ata_acpi_init_gtm() */
#endif
--- a/drivers/char/hw_random/bcm2835-rng.c
+++ b/drivers/char/hw_random/bcm2835-rng.c
--- a/drivers/char/hw_random/bcm2835-rng.c
+++ b/drivers/char/hw_random/bcm2835-rng.c
-@@ -170,6 +170,7 @@ static int bcm2835_rng_probe(struct plat
+@@ -169,6 +169,7 @@ static int bcm2835_rng_probe(struct plat
priv->rng.init = bcm2835_rng_init;
priv->rng.read = bcm2835_rng_read;
priv->rng.cleanup = bcm2835_rng_cleanup;
priv->rng.init = bcm2835_rng_init;
priv->rng.read = bcm2835_rng_read;
priv->rng.cleanup = bcm2835_rng_cleanup;
--- a/init/Kconfig
+++ b/init/Kconfig
--- a/init/Kconfig
+++ b/init/Kconfig
-@@ -1827,6 +1827,15 @@ config EMBEDDED
+@@ -1811,6 +1811,15 @@ config DEBUG_RSEQ
help
--- a/init/main.c
+++ b/init/main.c
help
--- a/init/main.c
+++ b/init/main.c
-@@ -611,6 +611,29 @@ static inline void setup_nr_cpu_ids(void
+@@ -608,6 +608,29 @@ static inline void setup_nr_cpu_ids(void
static inline void smp_prepare_cpus(unsigned int maxcpus) { }
#endif
static inline void smp_prepare_cpus(unsigned int maxcpus) { }
#endif
/*
* We need to store the untouched command line for future reference.
* We also need to store the touched command line since the parameter
/*
* We need to store the untouched command line for future reference.
* We also need to store the touched command line since the parameter
-@@ -958,6 +981,7 @@ asmlinkage __visible void __init __no_sa
+@@ -895,6 +918,7 @@ void start_kernel(void)
pr_notice("%s", linux_banner);
early_security_init();
setup_arch(&command_line);
pr_notice("%s", linux_banner);
early_security_init();
setup_arch(&command_line);