generic: 5.15: refresh pending patch
Use 'make target/linux/refresh' to refresh pending patches. Signed-off-by: Ansuel Smith <ansuelsmth@gmail.com>
This commit is contained in:
		 Ansuel Smith
					Ansuel Smith
				
			
				
					committed by
					
						 Daniel Golle
						Daniel Golle
					
				
			
			
				
	
			
			
			 Daniel Golle
						Daniel Golle
					
				
			
						parent
						
							49cb5e501a
						
					
				
				
					commit
					009f8afe06
				
			| @@ -11,16 +11,16 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|  |  | ||||||
| --- a/include/linux/compiler.h | --- a/include/linux/compiler.h | ||||||
| +++ b/include/linux/compiler.h | +++ b/include/linux/compiler.h | ||||||
| @@ -211,6 +211,8 @@ void ftrace_likely_update(struct ftrace_ | @@ -220,6 +220,8 @@ void ftrace_likely_update(struct ftrace_ | ||||||
|  	__v;								\ |  #define function_nocfi(x) (x) | ||||||
|  }) |  #endif | ||||||
|   |   | ||||||
| +#include <asm/rwonce.h> | +#include <asm/rwonce.h> | ||||||
| + | + | ||||||
|  #endif /* __KERNEL__ */ |  #endif /* __KERNEL__ */ | ||||||
|   |   | ||||||
|  /* |  /* | ||||||
| @@ -243,6 +245,4 @@ static inline void *offset_to_ptr(const | @@ -252,6 +254,4 @@ static inline void *offset_to_ptr(const | ||||||
|   */ |   */ | ||||||
|  #define prevent_tail_call_optimization()	mb() |  #define prevent_tail_call_optimization()	mb() | ||||||
|   |   | ||||||
|   | |||||||
| @@ -46,7 +46,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|  |  | ||||||
| --- a/arch/mips/kernel/process.c | --- a/arch/mips/kernel/process.c | ||||||
| +++ b/arch/mips/kernel/process.c | +++ b/arch/mips/kernel/process.c | ||||||
| @@ -380,6 +380,8 @@ static inline int is_sp_move_ins(union m | @@ -393,6 +393,8 @@ static inline int is_sp_move_ins(union m | ||||||
|   |   | ||||||
|  	if (ip->i_format.opcode == addiu_op || |  	if (ip->i_format.opcode == addiu_op || | ||||||
|  	    ip->i_format.opcode == daddiu_op) { |  	    ip->i_format.opcode == daddiu_op) { | ||||||
|   | |||||||
| @@ -71,7 +71,7 @@ Signed-off-by: Tobias Wolf <dev-NTEO@vplace.de> | |||||||
|  |  | ||||||
| --- a/mm/page_alloc.c | --- a/mm/page_alloc.c | ||||||
| +++ b/mm/page_alloc.c | +++ b/mm/page_alloc.c | ||||||
| @@ -7055,7 +7055,7 @@ static void __ref alloc_node_mem_map(str | @@ -7552,7 +7552,7 @@ static void __init alloc_node_mem_map(st | ||||||
|  	if (pgdat == NODE_DATA(0)) { |  	if (pgdat == NODE_DATA(0)) { | ||||||
|  		mem_map = NODE_DATA(0)->node_mem_map; |  		mem_map = NODE_DATA(0)->node_mem_map; | ||||||
|  		if (page_to_pfn(mem_map) != pgdat->node_start_pfn) |  		if (page_to_pfn(mem_map) != pgdat->node_start_pfn) | ||||||
|   | |||||||
| @@ -8,7 +8,7 @@ Signed-off-by: Giuseppe Lippolis <giu.lippolis@gmail.com> | |||||||
|  |  | ||||||
| --- a/drivers/spi/spidev.c | --- a/drivers/spi/spidev.c | ||||||
| +++ b/drivers/spi/spidev.c | +++ b/drivers/spi/spidev.c | ||||||
| @@ -682,6 +682,7 @@ static const struct of_device_id spidev_ | @@ -696,6 +696,7 @@ static const struct of_device_id spidev_ | ||||||
|  	{ .compatible = "menlo,m53cpld" }, |  	{ .compatible = "menlo,m53cpld" }, | ||||||
|  	{ .compatible = "cisco,spi-petra" }, |  	{ .compatible = "cisco,spi-petra" }, | ||||||
|  	{ .compatible = "micron,spi-authenta" }, |  	{ .compatible = "micron,spi-authenta" }, | ||||||
|   | |||||||
| @@ -8,7 +8,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|  |  | ||||||
| --- a/fs/jffs2/dir.c | --- a/fs/jffs2/dir.c | ||||||
| +++ b/fs/jffs2/dir.c | +++ b/fs/jffs2/dir.c | ||||||
| @@ -609,8 +609,8 @@ static int jffs2_rmdir (struct inode *di | @@ -614,8 +614,8 @@ static int jffs2_rmdir (struct inode *di | ||||||
|  	return ret; |  	return ret; | ||||||
|  } |  } | ||||||
|   |   | ||||||
| @@ -19,7 +19,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|  { |  { | ||||||
|  	struct jffs2_inode_info *f, *dir_f; |  	struct jffs2_inode_info *f, *dir_f; | ||||||
|  	struct jffs2_sb_info *c; |  	struct jffs2_sb_info *c; | ||||||
| @@ -748,7 +749,11 @@ static int jffs2_mknod (struct inode *di | @@ -754,7 +754,11 @@ static int jffs2_mknod (struct user_name | ||||||
|  	mutex_unlock(&dir_f->sem); |  	mutex_unlock(&dir_f->sem); | ||||||
|  	jffs2_complete_reservation(c); |  	jffs2_complete_reservation(c); | ||||||
|   |   | ||||||
| @@ -32,7 +32,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|  	return 0; |  	return 0; | ||||||
|   |   | ||||||
|   fail: |   fail: | ||||||
| @@ -756,6 +761,19 @@ static int jffs2_mknod (struct inode *di | @@ -762,6 +766,19 @@ static int jffs2_mknod (struct user_name | ||||||
|  	return ret; |  	return ret; | ||||||
|  } |  } | ||||||
|   |   | ||||||
| @@ -52,7 +52,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|  static int jffs2_rename (struct user_namespace *mnt_userns, |  static int jffs2_rename (struct user_namespace *mnt_userns, | ||||||
|  			 struct inode *old_dir_i, struct dentry *old_dentry, |  			 struct inode *old_dir_i, struct dentry *old_dentry, | ||||||
|  			 struct inode *new_dir_i, struct dentry *new_dentry, |  			 struct inode *new_dir_i, struct dentry *new_dentry, | ||||||
| @@ -766,7 +782,7 @@ static int jffs2_rename (struct inode *o | @@ -773,7 +790,7 @@ static int jffs2_rename (struct user_nam | ||||||
|  	uint8_t type; |  	uint8_t type; | ||||||
|  	uint32_t now; |  	uint32_t now; | ||||||
|   |   | ||||||
| @@ -61,7 +61,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|  		return -EINVAL; |  		return -EINVAL; | ||||||
|   |   | ||||||
|  	/* The VFS will check for us and prevent trying to rename a |  	/* The VFS will check for us and prevent trying to rename a | ||||||
| @@ -832,9 +848,14 @@ static int jffs2_rename (struct inode *o | @@ -839,9 +856,14 @@ static int jffs2_rename (struct user_nam | ||||||
|  	if (d_is_dir(old_dentry) && !victim_f) |  	if (d_is_dir(old_dentry) && !victim_f) | ||||||
|  		inc_nlink(new_dir_i); |  		inc_nlink(new_dir_i); | ||||||
|   |   | ||||||
|   | |||||||
| @@ -6,7 +6,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|  |  | ||||||
| --- a/fs/jffs2/dir.c | --- a/fs/jffs2/dir.c | ||||||
| +++ b/fs/jffs2/dir.c | +++ b/fs/jffs2/dir.c | ||||||
| @@ -779,18 +779,31 @@ static int jffs2_rename (struct inode *o | @@ -787,18 +787,31 @@ static int jffs2_rename (struct user_nam | ||||||
|  	int ret; |  	int ret; | ||||||
|  	struct jffs2_sb_info *c = JFFS2_SB_INFO(old_dir_i->i_sb); |  	struct jffs2_sb_info *c = JFFS2_SB_INFO(old_dir_i->i_sb); | ||||||
|  	struct jffs2_inode_info *victim_f = NULL; |  	struct jffs2_inode_info *victim_f = NULL; | ||||||
| @@ -40,7 +40,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|  		victim_f = JFFS2_INODE_INFO(d_inode(new_dentry)); |  		victim_f = JFFS2_INODE_INFO(d_inode(new_dentry)); | ||||||
|  		if (d_is_dir(new_dentry)) { |  		if (d_is_dir(new_dentry)) { | ||||||
|  			struct jffs2_full_dirent *fd; |  			struct jffs2_full_dirent *fd; | ||||||
| @@ -825,7 +838,7 @@ static int jffs2_rename (struct inode *o | @@ -833,7 +846,7 @@ static int jffs2_rename (struct user_nam | ||||||
|  	if (ret) |  	if (ret) | ||||||
|  		return ret; |  		return ret; | ||||||
|   |   | ||||||
| @@ -49,7 +49,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|  		/* There was a victim. Kill it off nicely */ |  		/* There was a victim. Kill it off nicely */ | ||||||
|  		if (d_is_dir(new_dentry)) |  		if (d_is_dir(new_dentry)) | ||||||
|  			clear_nlink(d_inode(new_dentry)); |  			clear_nlink(d_inode(new_dentry)); | ||||||
| @@ -851,6 +864,12 @@ static int jffs2_rename (struct inode *o | @@ -859,6 +872,12 @@ static int jffs2_rename (struct user_nam | ||||||
|  	if (flags & RENAME_WHITEOUT) |  	if (flags & RENAME_WHITEOUT) | ||||||
|  		/* Replace with whiteout */ |  		/* Replace with whiteout */ | ||||||
|  		ret = jffs2_whiteout(mnt_userns, old_dir_i, old_dentry); |  		ret = jffs2_whiteout(mnt_userns, old_dir_i, old_dentry); | ||||||
| @@ -62,7 +62,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|  	else |  	else | ||||||
|  		/* Unlink the original */ |  		/* Unlink the original */ | ||||||
|  		ret = jffs2_do_unlink(c, JFFS2_INODE_INFO(old_dir_i), |  		ret = jffs2_do_unlink(c, JFFS2_INODE_INFO(old_dir_i), | ||||||
| @@ -882,7 +901,7 @@ static int jffs2_rename (struct inode *o | @@ -890,7 +909,7 @@ static int jffs2_rename (struct user_nam | ||||||
|  		return ret; |  		return ret; | ||||||
|  	} |  	} | ||||||
|   |   | ||||||
|   | |||||||
| @@ -15,7 +15,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|  |  | ||||||
| --- a/net/bridge/br_input.c | --- a/net/bridge/br_input.c | ||||||
| +++ b/net/bridge/br_input.c | +++ b/net/bridge/br_input.c | ||||||
| @@ -195,6 +195,9 @@ static void __br_handle_local_finish(str | @@ -197,6 +197,9 @@ static void __br_handle_local_finish(str | ||||||
|  /* note: already called with rcu_read_lock */ |  /* note: already called with rcu_read_lock */ | ||||||
|  static int br_handle_local_finish(struct net *net, struct sock *sk, struct sk_buff *skb) |  static int br_handle_local_finish(struct net *net, struct sock *sk, struct sk_buff *skb) | ||||||
|  { |  { | ||||||
| @@ -25,7 +25,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|  	__br_handle_local_finish(skb); |  	__br_handle_local_finish(skb); | ||||||
|   |   | ||||||
|  	/* return 1 to signal the okfn() was called so it's ok to use the skb */ |  	/* return 1 to signal the okfn() was called so it's ok to use the skb */ | ||||||
| @@ -348,6 +351,17 @@ static rx_handler_result_t br_handle_fra | @@ -362,6 +365,17 @@ static rx_handler_result_t br_handle_fra | ||||||
|   |   | ||||||
|  forward: |  forward: | ||||||
|  	switch (p->state) { |  	switch (p->state) { | ||||||
|   | |||||||
| @@ -14,7 +14,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|  |  | ||||||
| --- a/Makefile | --- a/Makefile | ||||||
| +++ b/Makefile | +++ b/Makefile | ||||||
| @@ -735,11 +735,11 @@ KBUILD_CFLAGS	+= $(call cc-disable-warni | @@ -752,11 +752,11 @@ KBUILD_CFLAGS	+= $(call cc-disable-warni | ||||||
|  KBUILD_CFLAGS	+= $(call cc-disable-warning, address-of-packed-member) |  KBUILD_CFLAGS	+= $(call cc-disable-warning, address-of-packed-member) | ||||||
|   |   | ||||||
|  ifdef CONFIG_CC_OPTIMIZE_FOR_PERFORMANCE |  ifdef CONFIG_CC_OPTIMIZE_FOR_PERFORMANCE | ||||||
|   | |||||||
| @@ -13,7 +13,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|  |  | ||||||
| --- a/init/Kconfig | --- a/init/Kconfig | ||||||
| +++ b/init/Kconfig | +++ b/init/Kconfig | ||||||
| @@ -1384,6 +1384,17 @@ config SYSCTL_ARCH_UNALIGN_ALLOW | @@ -1438,6 +1438,17 @@ config SYSCTL_ARCH_UNALIGN_ALLOW | ||||||
|  	  the unaligned access emulation. |  	  the unaligned access emulation. | ||||||
|  	  see arch/parisc/kernel/unaligned.c for reference |  	  see arch/parisc/kernel/unaligned.c for reference | ||||||
|   |   | ||||||
| @@ -33,7 +33,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|   |   | ||||||
| --- a/kernel/kallsyms.c | --- a/kernel/kallsyms.c | ||||||
| +++ b/kernel/kallsyms.c | +++ b/kernel/kallsyms.c | ||||||
| @@ -77,6 +77,11 @@ static unsigned int kallsyms_expand_symb | @@ -80,6 +80,11 @@ static unsigned int kallsyms_expand_symb | ||||||
|  	 * For every byte on the compressed symbol data, copy the table |  	 * For every byte on the compressed symbol data, copy the table | ||||||
|  	 * entry for that byte. |  	 * entry for that byte. | ||||||
|  	 */ |  	 */ | ||||||
| @@ -45,7 +45,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|  	while (len) { |  	while (len) { | ||||||
|  		tptr = &kallsyms_token_table[kallsyms_token_index[*data]]; |  		tptr = &kallsyms_token_table[kallsyms_token_index[*data]]; | ||||||
|  		data++; |  		data++; | ||||||
| @@ -109,6 +114,9 @@ tail: | @@ -112,6 +117,9 @@ tail: | ||||||
|   */ |   */ | ||||||
|  static char kallsyms_get_symbol_type(unsigned int off) |  static char kallsyms_get_symbol_type(unsigned int off) | ||||||
|  { |  { | ||||||
| @@ -106,7 +106,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|  		} |  		} | ||||||
| --- a/scripts/link-vmlinux.sh | --- a/scripts/link-vmlinux.sh | ||||||
| +++ b/scripts/link-vmlinux.sh | +++ b/scripts/link-vmlinux.sh | ||||||
| @@ -186,6 +186,10 @@ kallsyms() | @@ -260,6 +260,10 @@ kallsyms() | ||||||
|  		kallsymopt="${kallsymopt} --base-relative" |  		kallsymopt="${kallsymopt} --base-relative" | ||||||
|  	fi |  	fi | ||||||
|   |   | ||||||
|   | |||||||
| @@ -11,7 +11,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|  |  | ||||||
| --- a/lib/vsprintf.c | --- a/lib/vsprintf.c | ||||||
| +++ b/lib/vsprintf.c | +++ b/lib/vsprintf.c | ||||||
| @@ -983,8 +983,10 @@ char *symbol_string(char *buf, char *end | @@ -984,8 +984,10 @@ char *symbol_string(char *buf, char *end | ||||||
|  		    struct printf_spec spec, const char *fmt) |  		    struct printf_spec spec, const char *fmt) | ||||||
|  { |  { | ||||||
|  	unsigned long value; |  	unsigned long value; | ||||||
| @@ -23,7 +23,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|  #endif |  #endif | ||||||
|   |   | ||||||
|  	if (fmt[1] == 'R') |  	if (fmt[1] == 'R') | ||||||
| @@ -1001,8 +1003,14 @@ char *symbol_string(char *buf, char *end | @@ -1006,8 +1008,14 @@ char *symbol_string(char *buf, char *end | ||||||
|   |   | ||||||
|  	return string_nocheck(buf, end, sym, spec); |  	return string_nocheck(buf, end, sym, spec); | ||||||
|  #else |  #else | ||||||
|   | |||||||
| @@ -16,7 +16,7 @@ Signed-off-by: Thibaut VARÈNE <hacks@slashdirt.org> | |||||||
|  |  | ||||||
| --- a/drivers/platform/Kconfig | --- a/drivers/platform/Kconfig | ||||||
| +++ b/drivers/platform/Kconfig | +++ b/drivers/platform/Kconfig | ||||||
| @@ -13,3 +13,5 @@ source "drivers/platform/chrome/Kconfig" | @@ -15,3 +15,5 @@ source "drivers/platform/mellanox/Kconfi | ||||||
|  source "drivers/platform/olpc/Kconfig" |  source "drivers/platform/olpc/Kconfig" | ||||||
|   |   | ||||||
|  source "drivers/platform/surface/Kconfig" |  source "drivers/platform/surface/Kconfig" | ||||||
| @@ -24,7 +24,7 @@ Signed-off-by: Thibaut VARÈNE <hacks@slashdirt.org> | |||||||
| +source "drivers/platform/mikrotik/Kconfig" | +source "drivers/platform/mikrotik/Kconfig" | ||||||
| --- a/drivers/platform/Makefile | --- a/drivers/platform/Makefile | ||||||
| +++ b/drivers/platform/Makefile | +++ b/drivers/platform/Makefile | ||||||
| @@ -9,3 +9,4 @@ obj-$(CONFIG_MIPS)		+= mips/ | @@ -10,3 +10,4 @@ obj-$(CONFIG_OLPC_EC)		+= olpc/ | ||||||
|  obj-$(CONFIG_GOLDFISH)		+= goldfish/ |  obj-$(CONFIG_GOLDFISH)		+= goldfish/ | ||||||
|  obj-$(CONFIG_CHROME_PLATFORMS)	+= chrome/ |  obj-$(CONFIG_CHROME_PLATFORMS)	+= chrome/ | ||||||
|  obj-$(CONFIG_SURFACE_PLATFORMS)	+= surface/ |  obj-$(CONFIG_SURFACE_PLATFORMS)	+= surface/ | ||||||
|   | |||||||
| @@ -9,7 +9,7 @@ Acked-by: Rob Landley <rob@landley.net> | |||||||
| --- | --- | ||||||
| --- a/arch/mips/Kconfig | --- a/arch/mips/Kconfig | ||||||
| +++ b/arch/mips/Kconfig | +++ b/arch/mips/Kconfig | ||||||
| @@ -1085,9 +1085,6 @@ config FW_ARC | @@ -1100,9 +1100,6 @@ config FW_ARC | ||||||
|  config ARCH_MAY_HAVE_PC_FDC |  config ARCH_MAY_HAVE_PC_FDC | ||||||
|  	bool |  	bool | ||||||
|   |   | ||||||
|   | |||||||
| @@ -46,7 +46,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|  typedef uint8_t Elf64_Byte;		/* Type for a 8-bit quantity.  */ |  typedef uint8_t Elf64_Byte;		/* Type for a 8-bit quantity.  */ | ||||||
| --- a/arch/mips/kernel/module.c | --- a/arch/mips/kernel/module.c | ||||||
| +++ b/arch/mips/kernel/module.c | +++ b/arch/mips/kernel/module.c | ||||||
| @@ -31,14 +31,221 @@ struct mips_hi16 { | @@ -31,23 +31,261 @@ struct mips_hi16 { | ||||||
|  static LIST_HEAD(dbe_list); |  static LIST_HEAD(dbe_list); | ||||||
|  static DEFINE_SPINLOCK(dbe_lock); |  static DEFINE_SPINLOCK(dbe_lock); | ||||||
|   |   | ||||||
| @@ -267,9 +267,8 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
| +	return 0; | +	return 0; | ||||||
| +} | +} | ||||||
|   |   | ||||||
|  static int apply_r_mips_none(struct module *me, u32 *location, |  static void apply_r_mips_32(u32 *location, u32 base, Elf_Addr v) | ||||||
|  			     u32 base, Elf_Addr v, bool rela) |  { | ||||||
| @@ -54,9 +261,40 @@ static int apply_r_mips_32(struct module |  | ||||||
|  	*location = base + v; |  	*location = base + v; | ||||||
|  } |  } | ||||||
|   |   | ||||||
| @@ -310,7 +309,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|  	if (v % 4) { |  	if (v % 4) { | ||||||
|  		pr_err("module %s: dangerous R_MIPS_26 relocation\n", |  		pr_err("module %s: dangerous R_MIPS_26 relocation\n", | ||||||
|  		       me->name); |  		       me->name); | ||||||
| @@ -64,13 +302,17 @@ static int apply_r_mips_26(struct module | @@ -55,13 +293,17 @@ static int apply_r_mips_26(struct module | ||||||
|  	} |  	} | ||||||
|   |   | ||||||
|  	if ((v & 0xf0000000) != (((unsigned long)location + 4) & 0xf0000000)) { |  	if ((v & 0xf0000000) != (((unsigned long)location + 4) & 0xf0000000)) { | ||||||
| @@ -332,7 +331,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|   |   | ||||||
|  	return 0; |  	return 0; | ||||||
|  } |  } | ||||||
| @@ -446,9 +688,36 @@ int module_finalize(const Elf_Ehdr *hdr, | @@ -441,9 +683,36 @@ int module_finalize(const Elf_Ehdr *hdr, | ||||||
|  		list_add(&me->arch.dbe_list, &dbe_list); |  		list_add(&me->arch.dbe_list, &dbe_list); | ||||||
|  		spin_unlock_irq(&dbe_lock); |  		spin_unlock_irq(&dbe_lock); | ||||||
|  	} |  	} | ||||||
|   | |||||||
| @@ -8,7 +8,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|  |  | ||||||
| --- a/arch/mips/include/asm/mach-generic/spaces.h | --- a/arch/mips/include/asm/mach-generic/spaces.h | ||||||
| +++ b/arch/mips/include/asm/mach-generic/spaces.h | +++ b/arch/mips/include/asm/mach-generic/spaces.h | ||||||
| @@ -54,7 +54,7 @@ | @@ -46,7 +46,7 @@ | ||||||
|   * Memory above this physical address will be considered highmem. |   * Memory above this physical address will be considered highmem. | ||||||
|   */ |   */ | ||||||
|  #ifndef HIGHMEM_START |  #ifndef HIGHMEM_START | ||||||
|   | |||||||
| @@ -11,7 +11,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|  |  | ||||||
| --- a/arch/mips/Makefile | --- a/arch/mips/Makefile | ||||||
| +++ b/arch/mips/Makefile | +++ b/arch/mips/Makefile | ||||||
| @@ -174,7 +174,7 @@ cflags-$(CONFIG_CPU_VR41XX)	+= -march=r4 | @@ -175,7 +175,7 @@ cflags-$(CONFIG_CPU_VR41XX)	+= -march=r4 | ||||||
|  cflags-$(CONFIG_CPU_R4X00)	+= -march=r4600 -Wa,--trap |  cflags-$(CONFIG_CPU_R4X00)	+= -march=r4600 -Wa,--trap | ||||||
|  cflags-$(CONFIG_CPU_TX49XX)	+= -march=r4600 -Wa,--trap |  cflags-$(CONFIG_CPU_TX49XX)	+= -march=r4600 -Wa,--trap | ||||||
|  cflags-$(CONFIG_CPU_MIPS32_R1)	+= -march=mips32 -Wa,--trap |  cflags-$(CONFIG_CPU_MIPS32_R1)	+= -march=mips32 -Wa,--trap | ||||||
|   | |||||||
| @@ -251,7 +251,7 @@ Signed-off-by: Yousong Zhou <yszhou4tech@gmail.com> | |||||||
|  	PTR_L a0,	arg0 |  	PTR_L a0,	arg0 | ||||||
|  	PTR_L a1,	arg1 |  	PTR_L a1,	arg1 | ||||||
|  	PTR_L a2,	arg2 |  	PTR_L a2,	arg2 | ||||||
| @@ -96,7 +97,7 @@ done: | @@ -98,7 +99,7 @@ done: | ||||||
|  #endif |  #endif | ||||||
|  	/* jump to kexec_start_address */ |  	/* jump to kexec_start_address */ | ||||||
|  	j		s1 |  	j		s1 | ||||||
| @@ -260,7 +260,7 @@ Signed-off-by: Yousong Zhou <yszhou4tech@gmail.com> | |||||||
|   |   | ||||||
|  #ifdef CONFIG_SMP |  #ifdef CONFIG_SMP | ||||||
|  /* |  /* | ||||||
| @@ -182,9 +183,15 @@ kexec_indirection_page: | @@ -181,9 +182,15 @@ kexec_indirection_page: | ||||||
|  	PTR_WD		0 |  	PTR_WD		0 | ||||||
|  	.size		kexec_indirection_page, PTRSIZE |  	.size		kexec_indirection_page, PTRSIZE | ||||||
|   |   | ||||||
|   | |||||||
| @@ -14,7 +14,7 @@ Signed-off-by: Pawel Dembicki <paweldembicki@gmail.com> | |||||||
|  |  | ||||||
| --- a/arch/powerpc/Kconfig | --- a/arch/powerpc/Kconfig | ||||||
| +++ b/arch/powerpc/Kconfig | +++ b/arch/powerpc/Kconfig | ||||||
| @@ -214,7 +214,7 @@ config PPC | @@ -222,7 +222,7 @@ config PPC | ||||||
|  	select HAVE_KERNEL_GZIP |  	select HAVE_KERNEL_GZIP | ||||||
|  	select HAVE_KERNEL_LZMA			if DEFAULT_UIMAGE |  	select HAVE_KERNEL_LZMA			if DEFAULT_UIMAGE | ||||||
|  	select HAVE_KERNEL_LZO			if DEFAULT_UIMAGE |  	select HAVE_KERNEL_LZO			if DEFAULT_UIMAGE | ||||||
|   | |||||||
| @@ -41,7 +41,7 @@ | |||||||
|   |   | ||||||
|  /* |  /* | ||||||
|   * 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,146 @@ static int mtd_add_partition_attrs(struc | @@ -235,6 +237,146 @@ static int mtd_add_partition_attrs(struc | ||||||
|  	return ret; |  	return ret; | ||||||
|  } |  } | ||||||
|   |   | ||||||
| @@ -188,7 +188,7 @@ | |||||||
|  int mtd_add_partition(struct mtd_info *parent, const char *name, |  int mtd_add_partition(struct mtd_info *parent, const char *name, | ||||||
|  		      long long offset, long long length) |  		      long long offset, long long length) | ||||||
|  { |  { | ||||||
| @@ -274,6 +416,7 @@ int mtd_add_partition(struct mtd_info *p | @@ -273,6 +415,7 @@ int mtd_add_partition(struct mtd_info *p | ||||||
|  	if (ret) |  	if (ret) | ||||||
|  		goto err_remove_part; |  		goto err_remove_part; | ||||||
|   |   | ||||||
| @@ -196,7 +196,7 @@ | |||||||
|  	mtd_add_partition_attrs(child); |  	mtd_add_partition_attrs(child); | ||||||
|   |   | ||||||
|  	return 0; |  	return 0; | ||||||
| @@ -422,6 +565,7 @@ int add_mtd_partitions(struct mtd_info * | @@ -421,6 +564,7 @@ int add_mtd_partitions(struct mtd_info * | ||||||
|  			goto err_del_partitions; |  			goto err_del_partitions; | ||||||
|  		} |  		} | ||||||
|   |   | ||||||
| @@ -204,7 +204,7 @@ | |||||||
|  		mtd_add_partition_attrs(child); |  		mtd_add_partition_attrs(child); | ||||||
|   |   | ||||||
|  		/* Look for subpartitions */ |  		/* Look for subpartitions */ | ||||||
| @@ -438,31 +582,6 @@ err_del_partitions: | @@ -437,31 +581,6 @@ err_del_partitions: | ||||||
|  	return ret; |  	return ret; | ||||||
|  } |  } | ||||||
|   |   | ||||||
| @@ -272,7 +272,7 @@ | |||||||
|  obj-$(CONFIG_MTD_BLOCK)		+= mtdblock.o |  obj-$(CONFIG_MTD_BLOCK)		+= mtdblock.o | ||||||
| --- a/include/linux/mtd/mtd.h | --- a/include/linux/mtd/mtd.h | ||||||
| +++ b/include/linux/mtd/mtd.h | +++ b/include/linux/mtd/mtd.h | ||||||
| @@ -608,6 +608,24 @@ static inline void mtd_align_erase_req(s | @@ -615,6 +615,24 @@ static inline void mtd_align_erase_req(s | ||||||
|  		req->len += mtd->erasesize - mod; |  		req->len += mtd->erasesize - mod; | ||||||
|  } |  } | ||||||
|   |   | ||||||
| @@ -297,7 +297,7 @@ | |||||||
|  static inline uint32_t mtd_div_by_ws(uint64_t sz, struct mtd_info *mtd) |  static inline uint32_t mtd_div_by_ws(uint64_t sz, struct mtd_info *mtd) | ||||||
|  { |  { | ||||||
|  	if (mtd->writesize_shift) |  	if (mtd->writesize_shift) | ||||||
| @@ -680,6 +698,13 @@ extern void __put_mtd_device(struct mtd_ | @@ -687,6 +705,13 @@ extern void __put_mtd_device(struct mtd_ | ||||||
|  extern struct mtd_info *get_mtd_device_nm(const char *name); |  extern struct mtd_info *get_mtd_device_nm(const char *name); | ||||||
|  extern void put_mtd_device(struct mtd_info *mtd); |  extern void put_mtd_device(struct mtd_info *mtd); | ||||||
|   |   | ||||||
|   | |||||||
| @@ -338,7 +338,7 @@ Reported-by: Dan Carpenter <dan.carpenter@oracle.com> | |||||||
|  	default y |  	default y | ||||||
| --- a/drivers/mtd/spi-nor/core.c | --- a/drivers/mtd/spi-nor/core.c | ||||||
| +++ b/drivers/mtd/spi-nor/core.c | +++ b/drivers/mtd/spi-nor/core.c | ||||||
| @@ -1075,6 +1075,8 @@ static u8 spi_nor_convert_3to4_erase(u8 | @@ -1262,6 +1262,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) | ||||||
|  { |  { | ||||||
| @@ -347,7 +347,7 @@ Reported-by: Dan Carpenter <dan.carpenter@oracle.com> | |||||||
|  	return !!nor->params->erase_map.uniform_erase_type; |  	return !!nor->params->erase_map.uniform_erase_type; | ||||||
|  } |  } | ||||||
|   |   | ||||||
| @@ -2560,6 +2562,7 @@ static int spi_nor_select_erase(struct s | @@ -2379,6 +2381,7 @@ static int spi_nor_select_erase(struct s | ||||||
|  { |  { | ||||||
|  	struct spi_nor_erase_map *map = &nor->params->erase_map; |  	struct spi_nor_erase_map *map = &nor->params->erase_map; | ||||||
|  	const struct spi_nor_erase_type *erase = NULL; |  	const struct spi_nor_erase_type *erase = NULL; | ||||||
| @@ -355,7 +355,7 @@ Reported-by: Dan Carpenter <dan.carpenter@oracle.com> | |||||||
|  	struct mtd_info *mtd = &nor->mtd; |  	struct mtd_info *mtd = &nor->mtd; | ||||||
|  	u32 wanted_size = nor->info->sector_size; |  	u32 wanted_size = nor->info->sector_size; | ||||||
|  	int i; |  	int i; | ||||||
| @@ -2592,8 +2595,9 @@ static int spi_nor_select_erase(struct s | @@ -2411,8 +2414,9 @@ static int spi_nor_select_erase(struct s | ||||||
|  	 */ |  	 */ | ||||||
|  	for (i = SNOR_ERASE_TYPE_MAX - 1; i >= 0; i--) { |  	for (i = SNOR_ERASE_TYPE_MAX - 1; i >= 0; i--) { | ||||||
|  		if (map->erase_type[i].size) { |  		if (map->erase_type[i].size) { | ||||||
| @@ -367,7 +367,7 @@ Reported-by: Dan Carpenter <dan.carpenter@oracle.com> | |||||||
|  		} |  		} | ||||||
|  	} |  	} | ||||||
|   |   | ||||||
| @@ -2601,6 +2605,8 @@ static int spi_nor_select_erase(struct s | @@ -2420,6 +2424,8 @@ static int spi_nor_select_erase(struct s | ||||||
|  		return -EINVAL; |  		return -EINVAL; | ||||||
|   |   | ||||||
|  	mtd->erasesize = erase->size; |  	mtd->erasesize = erase->size; | ||||||
| @@ -378,7 +378,7 @@ Reported-by: Dan Carpenter <dan.carpenter@oracle.com> | |||||||
|   |   | ||||||
| --- a/include/linux/mtd/mtd.h | --- a/include/linux/mtd/mtd.h | ||||||
| +++ b/include/linux/mtd/mtd.h | +++ b/include/linux/mtd/mtd.h | ||||||
| @@ -242,6 +242,8 @@ struct mtd_info { | @@ -243,6 +243,8 @@ struct mtd_info { | ||||||
|  	 * information below if they desire |  	 * information below if they desire | ||||||
|  	 */ |  	 */ | ||||||
|  	uint32_t erasesize; |  	uint32_t erasesize; | ||||||
|   | |||||||
| @@ -12,7 +12,7 @@ Signed-off-by: Rafał Miłecki <rafal@milecki.pl> | |||||||
|  |  | ||||||
| --- a/drivers/mtd/parsers/redboot.c | --- a/drivers/mtd/parsers/redboot.c | ||||||
| +++ b/drivers/mtd/parsers/redboot.c | +++ b/drivers/mtd/parsers/redboot.c | ||||||
| @@ -305,6 +305,7 @@ static int parse_redboot_partitions(stru | @@ -304,6 +304,7 @@ nogood: | ||||||
|   |   | ||||||
|  static const struct of_device_id mtd_parser_redboot_of_match_table[] = { |  static const struct of_device_id mtd_parser_redboot_of_match_table[] = { | ||||||
|  	{ .compatible = "redboot-fis" }, |  	{ .compatible = "redboot-fis" }, | ||||||
|   | |||||||
| @@ -11,9 +11,9 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|  |  | ||||||
| --- a/drivers/mtd/parsers/redboot.c | --- a/drivers/mtd/parsers/redboot.c | ||||||
| +++ b/drivers/mtd/parsers/redboot.c | +++ b/drivers/mtd/parsers/redboot.c | ||||||
| @@ -279,14 +279,21 @@ static int parse_redboot_partitions(stru | @@ -277,14 +277,21 @@ nogood: | ||||||
|  #endif |  #endif | ||||||
|  		names += strlen(names)+1; |  		names += strlen(names) + 1; | ||||||
|   |   | ||||||
| -#ifdef CONFIG_MTD_REDBOOT_PARTS_UNALLOCATED | -#ifdef CONFIG_MTD_REDBOOT_PARTS_UNALLOCATED | ||||||
|  		if (fl->next && fl->img->flash_base + fl->img->size + master->erasesize <= fl->next->img->flash_base) { |  		if (fl->next && fl->img->flash_base + fl->img->size + master->erasesize <= fl->next->img->flash_base) { | ||||||
|   | |||||||
| @@ -16,7 +16,7 @@ Signed-off-by: Thibaut VARÈNE <hacks@slashdirt.org> | |||||||
|  |  | ||||||
| --- a/drivers/mtd/parsers/Kconfig | --- a/drivers/mtd/parsers/Kconfig | ||||||
| +++ b/drivers/mtd/parsers/Kconfig | +++ b/drivers/mtd/parsers/Kconfig | ||||||
| @@ -195,3 +195,12 @@ config MTD_REDBOOT_PARTS_READONLY | @@ -202,3 +202,12 @@ config MTD_QCOMSMEM_PARTS | ||||||
|  	help |  	help | ||||||
|  	  This provides support for parsing partitions from Shared Memory (SMEM) |  	  This provides support for parsing partitions from Shared Memory (SMEM) | ||||||
|  	  for NAND and SPI flash on Qualcomm platforms. |  	  for NAND and SPI flash on Qualcomm platforms. | ||||||
| @@ -31,7 +31,7 @@ Signed-off-by: Thibaut VARÈNE <hacks@slashdirt.org> | |||||||
| +	 formatted DTS. | +	 formatted DTS. | ||||||
| --- a/drivers/mtd/parsers/Makefile | --- a/drivers/mtd/parsers/Makefile | ||||||
| +++ b/drivers/mtd/parsers/Makefile | +++ b/drivers/mtd/parsers/Makefile | ||||||
| @@ -13,3 +13,4 @@ obj-$(CONFIG_MTD_AFS_PARTS)		+= afs.o | @@ -14,3 +14,4 @@ obj-$(CONFIG_MTD_PARSER_TRX)		+= parser_ | ||||||
|  obj-$(CONFIG_MTD_SHARPSL_PARTS)		+= sharpslpart.o |  obj-$(CONFIG_MTD_SHARPSL_PARTS)		+= sharpslpart.o | ||||||
|  obj-$(CONFIG_MTD_REDBOOT_PARTS)		+= redboot.o |  obj-$(CONFIG_MTD_REDBOOT_PARTS)		+= redboot.o | ||||||
|  obj-$(CONFIG_MTD_QCOMSMEM_PARTS)	+= qcomsmempart.o |  obj-$(CONFIG_MTD_QCOMSMEM_PARTS)	+= qcomsmempart.o | ||||||
|   | |||||||
| @@ -14,7 +14,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|  |  | ||||||
| --- a/drivers/mtd/chips/cfi_cmdset_0002.c | --- a/drivers/mtd/chips/cfi_cmdset_0002.c | ||||||
| +++ b/drivers/mtd/chips/cfi_cmdset_0002.c | +++ b/drivers/mtd/chips/cfi_cmdset_0002.c | ||||||
| @@ -913,7 +913,7 @@ static int get_chip(struct map_info *map | @@ -914,7 +914,7 @@ static int get_chip(struct map_info *map | ||||||
|  		return 0; |  		return 0; | ||||||
|   |   | ||||||
|  	case FL_ERASING: |  	case FL_ERASING: | ||||||
|   | |||||||
| @@ -7,7 +7,7 @@ Signed-off-by: George Kashperko <george@znau.edu.ua> | |||||||
|  1 file changed, 1 insertion(+) |  1 file changed, 1 insertion(+) | ||||||
| --- a/drivers/mtd/chips/cfi_cmdset_0002.c | --- a/drivers/mtd/chips/cfi_cmdset_0002.c | ||||||
| +++ b/drivers/mtd/chips/cfi_cmdset_0002.c | +++ b/drivers/mtd/chips/cfi_cmdset_0002.c | ||||||
| @@ -2057,6 +2057,7 @@ static int __xipram do_write_buffer(stru | @@ -2058,6 +2058,7 @@ static int __xipram do_write_buffer(stru | ||||||
|   |   | ||||||
|  	/* Write Buffer Load */ |  	/* Write Buffer Load */ | ||||||
|  	map_write(map, CMD(0x25), cmd_adr); |  	map_write(map, CMD(0x25), cmd_adr); | ||||||
|   | |||||||
| @@ -19,9 +19,9 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|  |  | ||||||
| --- a/drivers/mtd/spi-nor/Kconfig | --- a/drivers/mtd/spi-nor/Kconfig | ||||||
| +++ b/drivers/mtd/spi-nor/Kconfig | +++ b/drivers/mtd/spi-nor/Kconfig | ||||||
| @@ -34,6 +34,17 @@ config MTD_SPI_NOR_USE_4K_SECTORS | @@ -78,6 +78,17 @@ config MTD_SPI_NOR_SWP_KEEP | ||||||
|  	  Please note that some tools/drivers/filesystems may not work with |   | ||||||
|  	  4096 B erase size (e.g. UBIFS requires 15 KiB as a minimum). |  endchoice | ||||||
|   |   | ||||||
| +config MTD_SPI_NOR_USE_4K_SECTORS_LIMIT | +config MTD_SPI_NOR_USE_4K_SECTORS_LIMIT | ||||||
| +	int "Maximum flash chip size to use 4K sectors on (in KiB)" | +	int "Maximum flash chip size to use 4K sectors on (in KiB)" | ||||||
| @@ -39,7 +39,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|  endif # MTD_SPI_NOR |  endif # MTD_SPI_NOR | ||||||
| --- a/drivers/mtd/spi-nor/core.c | --- a/drivers/mtd/spi-nor/core.c | ||||||
| +++ b/drivers/mtd/spi-nor/core.c | +++ b/drivers/mtd/spi-nor/core.c | ||||||
| @@ -2792,6 +2792,21 @@ static void spi_nor_info_init_params(str | @@ -2631,6 +2631,21 @@ static void spi_nor_info_init_params(str | ||||||
|  	 */ |  	 */ | ||||||
|  	erase_mask = 0; |  	erase_mask = 0; | ||||||
|  	i = 0; |  	i = 0; | ||||||
| @@ -61,7 +61,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|  	if (info->flags & SECT_4K_PMC) { |  	if (info->flags & SECT_4K_PMC) { | ||||||
|  		erase_mask |= BIT(i); |  		erase_mask |= BIT(i); | ||||||
|  		spi_nor_set_erase_type(&map->erase_type[i], 4096u, |  		spi_nor_set_erase_type(&map->erase_type[i], 4096u, | ||||||
| @@ -2803,6 +2818,7 @@ static void spi_nor_info_init_params(str | @@ -2642,6 +2657,7 @@ static void spi_nor_info_init_params(str | ||||||
|  				       SPINOR_OP_BE_4K); |  				       SPINOR_OP_BE_4K); | ||||||
|  		i++; |  		i++; | ||||||
|  	} |  	} | ||||||
|   | |||||||
| @@ -59,7 +59,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
| +}; | +}; | ||||||
| --- a/drivers/mtd/spi-nor/core.c | --- a/drivers/mtd/spi-nor/core.c | ||||||
| +++ b/drivers/mtd/spi-nor/core.c | +++ b/drivers/mtd/spi-nor/core.c | ||||||
| @@ -2028,6 +2028,7 @@ static const struct spi_nor_manufacturer | @@ -1848,6 +1848,7 @@ static const struct spi_nor_manufacturer | ||||||
|  	&spi_nor_winbond, |  	&spi_nor_winbond, | ||||||
|  	&spi_nor_xilinx, |  	&spi_nor_xilinx, | ||||||
|  	&spi_nor_xmc, |  	&spi_nor_xmc, | ||||||
| @@ -69,11 +69,11 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|  static const struct flash_info * |  static const struct flash_info * | ||||||
| --- a/drivers/mtd/spi-nor/core.h | --- a/drivers/mtd/spi-nor/core.h | ||||||
| +++ b/drivers/mtd/spi-nor/core.h | +++ b/drivers/mtd/spi-nor/core.h | ||||||
| @@ -398,6 +398,7 @@ extern const struct spi_nor_manufacturer | @@ -489,6 +489,7 @@ extern const struct spi_nor_manufacturer | ||||||
|  extern const struct spi_nor_manufacturer spi_nor_winbond; |  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_xilinx; | ||||||
|  extern const struct spi_nor_manufacturer spi_nor_xmc; |  extern const struct spi_nor_manufacturer spi_nor_xmc; | ||||||
| +extern const struct spi_nor_manufacturer spi_nor_xtx; | +extern const struct spi_nor_manufacturer spi_nor_xtx; | ||||||
|   |   | ||||||
|  int spi_nor_write_enable(struct spi_nor *nor); |  extern const struct attribute_group *spi_nor_sysfs_groups[]; | ||||||
|  int spi_nor_write_disable(struct spi_nor *nor); |   | ||||||
|   | |||||||
| @@ -33,7 +33,7 @@ Signed-off-by: Felix Matouschek <felix@matouschek.org> | |||||||
|  obj-$(CONFIG_MTD_SPI_NAND) += spinand.o |  obj-$(CONFIG_MTD_SPI_NAND) += spinand.o | ||||||
| --- a/drivers/mtd/nand/spi/core.c | --- a/drivers/mtd/nand/spi/core.c | ||||||
| +++ b/drivers/mtd/nand/spi/core.c | +++ b/drivers/mtd/nand/spi/core.c | ||||||
| @@ -760,6 +760,7 @@ static const struct spinand_manufacturer | @@ -902,6 +902,7 @@ static const struct spinand_manufacturer | ||||||
|  	¶gon_spinand_manufacturer, |  	¶gon_spinand_manufacturer, | ||||||
|  	&toshiba_spinand_manufacturer, |  	&toshiba_spinand_manufacturer, | ||||||
|  	&winbond_spinand_manufacturer, |  	&winbond_spinand_manufacturer, | ||||||
| @@ -168,7 +168,7 @@ Signed-off-by: Felix Matouschek <felix@matouschek.org> | |||||||
| +}; | +}; | ||||||
| --- a/include/linux/mtd/spinand.h | --- a/include/linux/mtd/spinand.h | ||||||
| +++ b/include/linux/mtd/spinand.h | +++ b/include/linux/mtd/spinand.h | ||||||
| @@ -244,6 +244,7 @@ extern const struct spinand_manufacturer | @@ -266,6 +266,7 @@ extern const struct spinand_manufacturer | ||||||
|  extern const struct spinand_manufacturer paragon_spinand_manufacturer; |  extern const struct spinand_manufacturer paragon_spinand_manufacturer; | ||||||
|  extern const struct spinand_manufacturer toshiba_spinand_manufacturer; |  extern const struct spinand_manufacturer toshiba_spinand_manufacturer; | ||||||
|  extern const struct spinand_manufacturer winbond_spinand_manufacturer; |  extern const struct spinand_manufacturer winbond_spinand_manufacturer; | ||||||
|   | |||||||
| @@ -7,5 +7,5 @@ | |||||||
| +	{ "f25l16pa-2s", INFO(0x8c2115, 0, 64 * 1024, 32, | +	{ "f25l16pa-2s", INFO(0x8c2115, 0, 64 * 1024, 32, | ||||||
| +			   SECT_4K | SPI_NOR_HAS_LOCK) }, | +			   SECT_4K | SPI_NOR_HAS_LOCK) }, | ||||||
|  	{ "f25l32pa", INFO(0x8c2016, 0, 64 * 1024, 64, |  	{ "f25l32pa", INFO(0x8c2016, 0, 64 * 1024, 64, | ||||||
|  			   SECT_4K | SPI_NOR_HAS_LOCK) }, |  			   SECT_4K | SPI_NOR_HAS_LOCK | SPI_NOR_SWP_IS_VOLATILE) }, | ||||||
|  	{ "f25l32qa", INFO(0x8c4116, 0, 64 * 1024, 64, |  	{ "f25l32qa", INFO(0x8c4116, 0, 64 * 1024, 64, | ||||||
|   | |||||||
| @@ -8,7 +8,7 @@ Signed-off-by: Daniel Golle <daniel@makrotopia.org> | |||||||
|  |  | ||||||
| --- a/drivers/mtd/ubi/build.c | --- a/drivers/mtd/ubi/build.c | ||||||
| +++ b/drivers/mtd/ubi/build.c | +++ b/drivers/mtd/ubi/build.c | ||||||
| @@ -1192,6 +1192,73 @@ static struct mtd_info * __init open_mtd | @@ -1191,6 +1191,73 @@ static struct mtd_info * __init open_mtd | ||||||
|  	return mtd; |  	return mtd; | ||||||
|  } |  } | ||||||
|   |   | ||||||
| @@ -82,7 +82,7 @@ Signed-off-by: Daniel Golle <daniel@makrotopia.org> | |||||||
|  static int __init ubi_init(void) |  static int __init ubi_init(void) | ||||||
|  { |  { | ||||||
|  	int err, i, k; |  	int err, i, k; | ||||||
| @@ -1275,6 +1342,12 @@ static int __init ubi_init(void) | @@ -1274,6 +1341,12 @@ static int __init ubi_init(void) | ||||||
|  		} |  		} | ||||||
|  	} |  	} | ||||||
|   |   | ||||||
|   | |||||||
| @@ -8,7 +8,7 @@ Signed-off-by: Daniel Golle <daniel@makrotopia.org> | |||||||
|  |  | ||||||
| --- a/drivers/mtd/ubi/block.c | --- a/drivers/mtd/ubi/block.c | ||||||
| +++ b/drivers/mtd/ubi/block.c | +++ b/drivers/mtd/ubi/block.c | ||||||
| @@ -652,6 +652,47 @@ static void __init ubiblock_create_from_ | @@ -642,6 +642,47 @@ static void __init ubiblock_create_from_ | ||||||
|  	} |  	} | ||||||
|  } |  } | ||||||
|   |   | ||||||
| @@ -56,7 +56,7 @@ Signed-off-by: Daniel Golle <daniel@makrotopia.org> | |||||||
|  static void ubiblock_remove_all(void) |  static void ubiblock_remove_all(void) | ||||||
|  { |  { | ||||||
|  	struct ubiblock *next; |  	struct ubiblock *next; | ||||||
| @@ -684,6 +725,10 @@ int __init ubiblock_init(void) | @@ -674,6 +715,10 @@ int __init ubiblock_init(void) | ||||||
|  	 */ |  	 */ | ||||||
|  	ubiblock_create_from_param(); |  	ubiblock_create_from_param(); | ||||||
|   |   | ||||||
|   | |||||||
| @@ -8,7 +8,7 @@ Signed-off-by: Daniel Golle <daniel@makrotopia.org> | |||||||
|  |  | ||||||
| --- a/init/do_mounts.c | --- a/init/do_mounts.c | ||||||
| +++ b/init/do_mounts.c | +++ b/init/do_mounts.c | ||||||
| @@ -474,7 +474,30 @@ retry: | @@ -447,7 +447,30 @@ retry: | ||||||
|  out: |  out: | ||||||
|  	put_page(page); |  	put_page(page); | ||||||
|  } |  } | ||||||
| @@ -40,7 +40,7 @@ Signed-off-by: Daniel Golle <daniel@makrotopia.org> | |||||||
|  #ifdef CONFIG_ROOT_NFS |  #ifdef CONFIG_ROOT_NFS | ||||||
|   |   | ||||||
|  #define NFSROOT_TIMEOUT_MIN	5 |  #define NFSROOT_TIMEOUT_MIN	5 | ||||||
| @@ -567,6 +590,10 @@ void __init mount_root(void) | @@ -580,6 +603,10 @@ void __init mount_root(void) | ||||||
|  		return; |  		return; | ||||||
|  	} |  	} | ||||||
|  #endif |  #endif | ||||||
|   | |||||||
| @@ -16,7 +16,7 @@ Signed-off-by: Daniel Golle <daniel@makrotopia.org> | |||||||
|   |   | ||||||
|  #include "ubi-media.h" |  #include "ubi-media.h" | ||||||
|  #include "ubi.h" |  #include "ubi.h" | ||||||
| @@ -458,6 +459,15 @@ int ubiblock_create(struct ubi_volume_in | @@ -451,6 +452,15 @@ int ubiblock_create(struct ubi_volume_in | ||||||
|  	dev_info(disk_to_dev(dev->gd), "created from ubi%d:%d(%s)", |  	dev_info(disk_to_dev(dev->gd), "created from ubi%d:%d(%s)", | ||||||
|  		 dev->ubi_num, dev->vol_id, vi->name); |  		 dev->ubi_num, dev->vol_id, vi->name); | ||||||
|  	mutex_unlock(&devices_mutex); |  	mutex_unlock(&devices_mutex); | ||||||
| @@ -31,4 +31,4 @@ Signed-off-by: Daniel Golle <daniel@makrotopia.org> | |||||||
| + | + | ||||||
|  	return 0; |  	return 0; | ||||||
|   |   | ||||||
|  out_free_queue: |  out_remove_minor: | ||||||
|   | |||||||
| @@ -50,7 +50,7 @@ Signed-off-by: Gabor Juhos <juhosg@openwrt.org> | |||||||
|  		break; |  		break; | ||||||
| --- a/drivers/mtd/ubi/ubi.h | --- a/drivers/mtd/ubi/ubi.h | ||||||
| +++ b/drivers/mtd/ubi/ubi.h | +++ b/drivers/mtd/ubi/ubi.h | ||||||
| @@ -782,6 +782,7 @@ struct ubi_attach_info { | @@ -780,6 +780,7 @@ struct ubi_attach_info { | ||||||
|  	int mean_ec; |  	int mean_ec; | ||||||
|  	uint64_t ec_sum; |  	uint64_t ec_sum; | ||||||
|  	int ec_count; |  	int ec_count; | ||||||
|   | |||||||
| @@ -17,7 +17,7 @@ Reviewed-by: Miquel Raynal <miquel.raynal@bootlin.com> | |||||||
|  |  | ||||||
| --- a/drivers/mtd/mtdcore.c | --- a/drivers/mtd/mtdcore.c | ||||||
| +++ b/drivers/mtd/mtdcore.c | +++ b/drivers/mtd/mtdcore.c | ||||||
| @@ -1046,6 +1046,44 @@ out_unlock: | @@ -1203,6 +1203,44 @@ out_unlock: | ||||||
|  } |  } | ||||||
|  EXPORT_SYMBOL_GPL(get_mtd_device_nm); |  EXPORT_SYMBOL_GPL(get_mtd_device_nm); | ||||||
|   |   | ||||||
| @@ -64,7 +64,7 @@ Reviewed-by: Miquel Raynal <miquel.raynal@bootlin.com> | |||||||
|  	mutex_lock(&mtd_table_mutex); |  	mutex_lock(&mtd_table_mutex); | ||||||
| --- a/include/linux/mtd/mtd.h | --- a/include/linux/mtd/mtd.h | ||||||
| +++ b/include/linux/mtd/mtd.h | +++ b/include/linux/mtd/mtd.h | ||||||
| @@ -698,6 +698,8 @@ extern struct mtd_info *get_mtd_device(s | @@ -705,6 +705,8 @@ extern struct mtd_info *get_mtd_device(s | ||||||
|  extern int __get_mtd_device(struct mtd_info *mtd); |  extern int __get_mtd_device(struct mtd_info *mtd); | ||||||
|  extern void __put_mtd_device(struct mtd_info *mtd); |  extern void __put_mtd_device(struct mtd_info *mtd); | ||||||
|  extern struct mtd_info *get_mtd_device_nm(const char *name); |  extern struct mtd_info *get_mtd_device_nm(const char *name); | ||||||
|   | |||||||
| @@ -43,7 +43,7 @@ Signed-off-by: Bernhard Frauendienst <kernel@nospam.obeliks.de> | |||||||
|  |  | ||||||
| --- a/drivers/mtd/Kconfig | --- a/drivers/mtd/Kconfig | ||||||
| +++ b/drivers/mtd/Kconfig | +++ b/drivers/mtd/Kconfig | ||||||
| @@ -238,4 +238,6 @@ source "drivers/mtd/ubi/Kconfig" | @@ -241,4 +241,6 @@ source "drivers/mtd/ubi/Kconfig" | ||||||
|   |   | ||||||
|  source "drivers/mtd/hyperbus/Kconfig" |  source "drivers/mtd/hyperbus/Kconfig" | ||||||
|   |   | ||||||
|   | |||||||
| @@ -22,7 +22,7 @@ Signed-off-by: Nick Hainke <vincent@systemli.org> | |||||||
|  |  | ||||||
| --- a/drivers/mtd/spi-nor/macronix.c | --- a/drivers/mtd/spi-nor/macronix.c | ||||||
| +++ b/drivers/mtd/spi-nor/macronix.c | +++ b/drivers/mtd/spi-nor/macronix.c | ||||||
| @@ -42,7 +42,8 @@ static const struct flash_info macronix_ | @@ -41,7 +41,8 @@ static const struct flash_info macronix_ | ||||||
|  	{ "mx25l1606e",  INFO(0xc22015, 0, 64 * 1024,  32, SECT_4K) }, |  	{ "mx25l1606e",  INFO(0xc22015, 0, 64 * 1024,  32, SECT_4K) }, | ||||||
|  	{ "mx25l3205d",  INFO(0xc22016, 0, 64 * 1024,  64, SECT_4K) }, |  	{ "mx25l3205d",  INFO(0xc22016, 0, 64 * 1024,  64, SECT_4K) }, | ||||||
|  	{ "mx25l3255e",  INFO(0xc29e16, 0, 64 * 1024,  64, SECT_4K) }, |  	{ "mx25l3255e",  INFO(0xc29e16, 0, 64 * 1024,  64, SECT_4K) }, | ||||||
|   | |||||||
| @@ -1087,7 +1087,7 @@ Signed-off-by: Alexandros C. Couloumbis <alex@ozo.com> | |||||||
|  #define JFFS2_NODE_ACCURATE 0x2000 |  #define JFFS2_NODE_ACCURATE 0x2000 | ||||||
| --- a/lib/Kconfig | --- a/lib/Kconfig | ||||||
| +++ b/lib/Kconfig | +++ b/lib/Kconfig | ||||||
| @@ -315,6 +315,12 @@ config ZSTD_DECOMPRESS | @@ -335,6 +335,12 @@ config ZSTD_DECOMPRESS | ||||||
|   |   | ||||||
|  source "lib/xz/Kconfig" |  source "lib/xz/Kconfig" | ||||||
|   |   | ||||||
| @@ -1102,7 +1102,7 @@ Signed-off-by: Alexandros C. Couloumbis <alex@ozo.com> | |||||||
|  # ZLIB_INFLATE; DECOMPRESS_GZIP is just a wrapper.) |  # ZLIB_INFLATE; DECOMPRESS_GZIP is just a wrapper.) | ||||||
| --- a/lib/Makefile | --- a/lib/Makefile | ||||||
| +++ b/lib/Makefile | +++ b/lib/Makefile | ||||||
| @@ -136,6 +136,16 @@ CFLAGS_kobject.o += -DDEBUG | @@ -135,6 +135,16 @@ CFLAGS_kobject.o += -DDEBUG | ||||||
|  CFLAGS_kobject_uevent.o += -DDEBUG |  CFLAGS_kobject_uevent.o += -DDEBUG | ||||||
|  endif |  endif | ||||||
|   |   | ||||||
| @@ -1119,7 +1119,7 @@ Signed-off-by: Alexandros C. Couloumbis <alex@ozo.com> | |||||||
|  obj-$(CONFIG_DEBUG_INFO_REDUCED) += debug_info.o |  obj-$(CONFIG_DEBUG_INFO_REDUCED) += debug_info.o | ||||||
|  CFLAGS_debug_info.o += $(call cc-option, -femit-struct-debug-detailed=any) |  CFLAGS_debug_info.o += $(call cc-option, -femit-struct-debug-detailed=any) | ||||||
|   |   | ||||||
| @@ -191,6 +201,8 @@ obj-$(CONFIG_ZSTD_COMPRESS) += zstd/ | @@ -192,6 +202,8 @@ obj-$(CONFIG_ZSTD_COMPRESS) += zstd/ | ||||||
|  obj-$(CONFIG_ZSTD_DECOMPRESS) += zstd/ |  obj-$(CONFIG_ZSTD_DECOMPRESS) += zstd/ | ||||||
|  obj-$(CONFIG_XZ_DEC) += xz/ |  obj-$(CONFIG_XZ_DEC) += xz/ | ||||||
|  obj-$(CONFIG_RAID6_PQ) += raid6/ |  obj-$(CONFIG_RAID6_PQ) += raid6/ | ||||||
|   | |||||||
| @@ -17,7 +17,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|  #include <net/net_namespace.h> |  #include <net/net_namespace.h> | ||||||
|  #ifdef CONFIG_SYSCTL |  #ifdef CONFIG_SYSCTL | ||||||
|  #include <linux/sysctl.h> |  #include <linux/sysctl.h> | ||||||
| @@ -457,6 +458,56 @@ static int ct_cpu_seq_show(struct seq_fi | @@ -462,6 +463,56 @@ static int ct_cpu_seq_show(struct seq_fi | ||||||
|  	return 0; |  	return 0; | ||||||
|  } |  } | ||||||
|   |   | ||||||
| @@ -74,7 +74,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|  static const struct seq_operations ct_cpu_seq_ops = { |  static const struct seq_operations ct_cpu_seq_ops = { | ||||||
|  	.start	= ct_cpu_seq_start, |  	.start	= ct_cpu_seq_start, | ||||||
|  	.next	= ct_cpu_seq_next, |  	.next	= ct_cpu_seq_next, | ||||||
| @@ -470,8 +521,9 @@ static int nf_conntrack_standalone_init_ | @@ -475,8 +526,9 @@ static int nf_conntrack_standalone_init_ | ||||||
|  	kuid_t root_uid; |  	kuid_t root_uid; | ||||||
|  	kgid_t root_gid; |  	kgid_t root_gid; | ||||||
|   |   | ||||||
|   | |||||||
| @@ -8,7 +8,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|  |  | ||||||
| --- a/net/netfilter/nf_conntrack_proto_tcp.c | --- a/net/netfilter/nf_conntrack_proto_tcp.c | ||||||
| +++ b/net/netfilter/nf_conntrack_proto_tcp.c | +++ b/net/netfilter/nf_conntrack_proto_tcp.c | ||||||
| @@ -476,6 +479,9 @@ static bool tcp_in_window(const struct n | @@ -465,6 +465,9 @@ static bool tcp_in_window(struct nf_conn | ||||||
|  	s32 receiver_offset; |  	s32 receiver_offset; | ||||||
|  	bool res, in_recv_win; |  	bool res, in_recv_win; | ||||||
|   |   | ||||||
| @@ -18,7 +18,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|  	/* |  	/* | ||||||
|  	 * Get the required data from the packet. |  	 * Get the required data from the packet. | ||||||
|  	 */ |  	 */ | ||||||
| @@ -1130,7 +1136,7 @@ int nf_conntrack_tcp_packet(struct nf_co | @@ -1151,7 +1154,7 @@ int nf_conntrack_tcp_packet(struct nf_co | ||||||
|  		 IP_CT_TCP_FLAG_DATA_UNACKNOWLEDGED && |  		 IP_CT_TCP_FLAG_DATA_UNACKNOWLEDGED && | ||||||
|  		 timeouts[new_state] > timeouts[TCP_CONNTRACK_UNACK]) |  		 timeouts[new_state] > timeouts[TCP_CONNTRACK_UNACK]) | ||||||
|  		timeout = timeouts[TCP_CONNTRACK_UNACK]; |  		timeout = timeouts[TCP_CONNTRACK_UNACK]; | ||||||
| @@ -29,16 +29,16 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|  	else |  	else | ||||||
| --- a/net/netfilter/nf_conntrack_standalone.c | --- a/net/netfilter/nf_conntrack_standalone.c | ||||||
| +++ b/net/netfilter/nf_conntrack_standalone.c | +++ b/net/netfilter/nf_conntrack_standalone.c | ||||||
| @@ -660,6 +663,7 @@ enum nf_ct_sysctl_index { | @@ -671,6 +671,7 @@ enum nf_ct_sysctl_index { | ||||||
|  	NF_SYSCTL_CT_PROTO_TIMEOUT_GRE_STREAM, |  	NF_SYSCTL_CT_LWTUNNEL, | ||||||
|  #endif |  #endif | ||||||
|   |   | ||||||
| +	NF_SYSCTL_CT_PROTO_TCP_NO_WINDOW_CHECK, | +	NF_SYSCTL_CT_PROTO_TCP_NO_WINDOW_CHECK, | ||||||
|  	__NF_SYSCTL_CT_LAST_SYSCTL, |  	__NF_SYSCTL_CT_LAST_SYSCTL, | ||||||
|  }; |  }; | ||||||
|   |   | ||||||
| @@ -1014,6 +1018,13 @@ static struct ctl_table nf_ct_sysctl_tab | @@ -1026,6 +1027,13 @@ static struct ctl_table nf_ct_sysctl_tab | ||||||
|  		.proc_handler   = proc_dointvec_jiffies, |  		.proc_handler	= nf_hooks_lwtunnel_sysctl_handler, | ||||||
|  	}, |  	}, | ||||||
|  #endif |  #endif | ||||||
| +	[NF_SYSCTL_CT_PROTO_TCP_NO_WINDOW_CHECK] = { | +	[NF_SYSCTL_CT_PROTO_TCP_NO_WINDOW_CHECK] = { | ||||||
| @@ -51,7 +51,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|  	{} |  	{} | ||||||
|  }; |  }; | ||||||
|   |   | ||||||
| @@ -1164,6 +1164,7 @@ static int nf_conntrack_standalone_init_sysctl(struct net *net) | @@ -1153,6 +1161,7 @@ static int nf_conntrack_standalone_init_ | ||||||
|  #ifdef CONFIG_NF_CONNTRACK_EVENTS |  #ifdef CONFIG_NF_CONNTRACK_EVENTS | ||||||
|  	table[NF_SYSCTL_CT_EVENTS].data = &net->ct.sysctl_events; |  	table[NF_SYSCTL_CT_EVENTS].data = &net->ct.sysctl_events; | ||||||
|  #endif |  #endif | ||||||
| @@ -59,7 +59,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|  #ifdef CONFIG_NF_CONNTRACK_TIMESTAMP |  #ifdef CONFIG_NF_CONNTRACK_TIMESTAMP | ||||||
|  	table[NF_SYSCTL_CT_TIMESTAMP].data = &net->ct.sysctl_tstamp; |  	table[NF_SYSCTL_CT_TIMESTAMP].data = &net->ct.sysctl_tstamp; | ||||||
|  #endif |  #endif | ||||||
| @@ -1220,6 +1220,7 @@ | @@ -1222,6 +1231,7 @@ static int nf_conntrack_pernet_init(stru | ||||||
|  	int ret; |  	int ret; | ||||||
|   |   | ||||||
|  	net->ct.sysctl_checksum = 1; |  	net->ct.sysctl_checksum = 1; | ||||||
|   | |||||||
| @@ -30,7 +30,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|  #define PACKET_FANOUT_LB		1 |  #define PACKET_FANOUT_LB		1 | ||||||
| --- a/net/packet/af_packet.c | --- a/net/packet/af_packet.c | ||||||
| +++ b/net/packet/af_packet.c | +++ b/net/packet/af_packet.c | ||||||
| @@ -1822,6 +1822,7 @@ static int packet_rcv_spkt(struct sk_buf | @@ -1825,6 +1825,7 @@ static int packet_rcv_spkt(struct sk_buf | ||||||
|  { |  { | ||||||
|  	struct sock *sk; |  	struct sock *sk; | ||||||
|  	struct sockaddr_pkt *spkt; |  	struct sockaddr_pkt *spkt; | ||||||
| @@ -38,7 +38,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|   |   | ||||||
|  	/* |  	/* | ||||||
|  	 *	When we registered the protocol we saved the socket in the data |  	 *	When we registered the protocol we saved the socket in the data | ||||||
| @@ -1829,6 +1830,7 @@ static int packet_rcv_spkt(struct sk_buf | @@ -1832,6 +1833,7 @@ static int packet_rcv_spkt(struct sk_buf | ||||||
|  	 */ |  	 */ | ||||||
|   |   | ||||||
|  	sk = pt->af_packet_priv; |  	sk = pt->af_packet_priv; | ||||||
| @@ -46,7 +46,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|   |   | ||||||
|  	/* |  	/* | ||||||
|  	 *	Yank back the headers [hope the device set this |  	 *	Yank back the headers [hope the device set this | ||||||
| @@ -1841,7 +1843,7 @@ static int packet_rcv_spkt(struct sk_buf | @@ -1844,7 +1846,7 @@ static int packet_rcv_spkt(struct sk_buf | ||||||
|  	 *	so that this procedure is noop. |  	 *	so that this procedure is noop. | ||||||
|  	 */ |  	 */ | ||||||
|   |   | ||||||
| @@ -55,7 +55,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|  		goto out; |  		goto out; | ||||||
|   |   | ||||||
|  	if (!net_eq(dev_net(dev), sock_net(sk))) |  	if (!net_eq(dev_net(dev), sock_net(sk))) | ||||||
| @@ -2079,12 +2081,12 @@ static int packet_rcv(struct sk_buff *sk | @@ -2082,12 +2084,12 @@ static int packet_rcv(struct sk_buff *sk | ||||||
|  	unsigned int snaplen, res; |  	unsigned int snaplen, res; | ||||||
|  	bool is_drop_n_account = false; |  	bool is_drop_n_account = false; | ||||||
|   |   | ||||||
| @@ -71,7 +71,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|  	if (!net_eq(dev_net(dev), sock_net(sk))) |  	if (!net_eq(dev_net(dev), sock_net(sk))) | ||||||
|  		goto drop; |  		goto drop; | ||||||
|   |   | ||||||
| @@ -2210,12 +2212,12 @@ static int tpacket_rcv(struct sk_buff *s | @@ -2213,12 +2215,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.h2)) != 32); | ||||||
|  	BUILD_BUG_ON(TPACKET_ALIGN(sizeof(*h.h3)) != 48); |  	BUILD_BUG_ON(TPACKET_ALIGN(sizeof(*h.h3)) != 48); | ||||||
|   |   | ||||||
| @@ -95,7 +95,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|   |   | ||||||
|  	if (sock->type == SOCK_PACKET) |  	if (sock->type == SOCK_PACKET) | ||||||
|  		po->prot_hook.func = packet_rcv_spkt; |  		po->prot_hook.func = packet_rcv_spkt; | ||||||
| @@ -3969,6 +3972,16 @@ packet_setsockopt(struct socket *sock, i | @@ -3966,6 +3969,16 @@ packet_setsockopt(struct socket *sock, i | ||||||
|  		po->xmit = val ? packet_direct_xmit : dev_queue_xmit; |  		po->xmit = val ? packet_direct_xmit : dev_queue_xmit; | ||||||
|  		return 0; |  		return 0; | ||||||
|  	} |  	} | ||||||
| @@ -112,7 +112,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|  	default: |  	default: | ||||||
|  		return -ENOPROTOOPT; |  		return -ENOPROTOOPT; | ||||||
|  	} |  	} | ||||||
| @@ -4025,6 +4038,13 @@ static int packet_getsockopt(struct sock | @@ -4022,6 +4035,13 @@ static int packet_getsockopt(struct sock | ||||||
|  	case PACKET_VNET_HDR: |  	case PACKET_VNET_HDR: | ||||||
|  		val = po->has_vnet_hdr; |  		val = po->has_vnet_hdr; | ||||||
|  		break; |  		break; | ||||||
| @@ -135,4 +135,4 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
| +	unsigned int		pkt_type; | +	unsigned int		pkt_type; | ||||||
|  }; |  }; | ||||||
|   |   | ||||||
|  static struct packet_sock *pkt_sk(struct sock *sk) |  static inline struct packet_sock *pkt_sk(struct sock *sk) | ||||||
|   | |||||||
| @@ -9,7 +9,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|  |  | ||||||
| --- a/include/linux/skbuff.h | --- a/include/linux/skbuff.h | ||||||
| +++ b/include/linux/skbuff.h | +++ b/include/linux/skbuff.h | ||||||
| @@ -2676,7 +2676,7 @@ static inline int pskb_network_may_pull( | @@ -2727,7 +2727,7 @@ static inline int pskb_network_may_pull( | ||||||
|   * NET_IP_ALIGN(2) + ethernet_header(14) + IP_header(20/40) + ports(8) |   * NET_IP_ALIGN(2) + ethernet_header(14) + IP_header(20/40) + ports(8) | ||||||
|   */ |   */ | ||||||
|  #ifndef NET_SKB_PAD |  #ifndef NET_SKB_PAD | ||||||
|   | |||||||
| @@ -91,7 +91,7 @@ Signed-off-by: Steven Barth <cyrus@openwrt.org> | |||||||
|   |   | ||||||
|  	return hash_32(hash, IP6_TUNNEL_HASH_SIZE_SHIFT); |  	return hash_32(hash, IP6_TUNNEL_HASH_SIZE_SHIFT); | ||||||
|  } |  } | ||||||
| @@ -144,17 +147,33 @@ static struct ip6_tnl * | @@ -114,17 +117,33 @@ static struct ip6_tnl * | ||||||
|  ip6_tnl_lookup(struct net *net, int link, |  ip6_tnl_lookup(struct net *net, int link, | ||||||
|  	       const struct in6_addr *remote, const struct in6_addr *local) |  	       const struct in6_addr *remote, const struct in6_addr *local) | ||||||
|  { |  { | ||||||
| @@ -127,7 +127,7 @@ Signed-off-by: Steven Barth <cyrus@openwrt.org> | |||||||
|  		if (link == t->parms.link) |  		if (link == t->parms.link) | ||||||
|  			return t; |  			return t; | ||||||
|  		else |  		else | ||||||
| @@ -162,7 +181,7 @@ ip6_tnl_lookup(struct net *net, int link | @@ -132,7 +151,7 @@ ip6_tnl_lookup(struct net *net, int link | ||||||
|  	} |  	} | ||||||
|   |   | ||||||
|  	memset(&any, 0, sizeof(any)); |  	memset(&any, 0, sizeof(any)); | ||||||
| @@ -136,7 +136,7 @@ Signed-off-by: Steven Barth <cyrus@openwrt.org> | |||||||
|  	for_each_ip6_tunnel_rcu(ip6n->tnls_r_l[hash]) { |  	for_each_ip6_tunnel_rcu(ip6n->tnls_r_l[hash]) { | ||||||
|  		if (!ipv6_addr_equal(local, &t->parms.laddr) || |  		if (!ipv6_addr_equal(local, &t->parms.laddr) || | ||||||
|  		    !ipv6_addr_any(&t->parms.raddr) || |  		    !ipv6_addr_any(&t->parms.raddr) || | ||||||
| @@ -175,7 +194,7 @@ ip6_tnl_lookup(struct net *net, int link | @@ -145,7 +164,7 @@ ip6_tnl_lookup(struct net *net, int link | ||||||
|  			cand = t; |  			cand = t; | ||||||
|  	} |  	} | ||||||
|   |   | ||||||
| @@ -145,7 +145,7 @@ Signed-off-by: Steven Barth <cyrus@openwrt.org> | |||||||
|  	for_each_ip6_tunnel_rcu(ip6n->tnls_r_l[hash]) { |  	for_each_ip6_tunnel_rcu(ip6n->tnls_r_l[hash]) { | ||||||
|  		if (!ipv6_addr_equal(remote, &t->parms.raddr) || |  		if (!ipv6_addr_equal(remote, &t->parms.raddr) || | ||||||
|  		    !ipv6_addr_any(&t->parms.laddr) || |  		    !ipv6_addr_any(&t->parms.laddr) || | ||||||
| @@ -223,7 +242,7 @@ ip6_tnl_bucket(struct ip6_tnl_net *ip6n, | @@ -194,7 +213,7 @@ ip6_tnl_bucket(struct ip6_tnl_net *ip6n, | ||||||
|   |   | ||||||
|  	if (!ipv6_addr_any(remote) || !ipv6_addr_any(local)) { |  	if (!ipv6_addr_any(remote) || !ipv6_addr_any(local)) { | ||||||
|  		prio = 1; |  		prio = 1; | ||||||
| @@ -154,7 +154,7 @@ Signed-off-by: Steven Barth <cyrus@openwrt.org> | |||||||
|  	} |  	} | ||||||
|  	return &ip6n->tnls[prio][h]; |  	return &ip6n->tnls[prio][h]; | ||||||
|  } |  } | ||||||
| @@ -405,6 +424,12 @@ ip6_tnl_dev_uninit(struct net_device *de | @@ -378,6 +397,12 @@ ip6_tnl_dev_uninit(struct net_device *de | ||||||
|  	struct net *net = t->net; |  	struct net *net = t->net; | ||||||
|  	struct ip6_tnl_net *ip6n = net_generic(net, ip6_tnl_net_id); |  	struct ip6_tnl_net *ip6n = net_generic(net, ip6_tnl_net_id); | ||||||
|   |   | ||||||
| @@ -167,7 +167,7 @@ Signed-off-by: Steven Barth <cyrus@openwrt.org> | |||||||
|  	if (dev == ip6n->fb_tnl_dev) |  	if (dev == ip6n->fb_tnl_dev) | ||||||
|  		RCU_INIT_POINTER(ip6n->tnls_wc[0], NULL); |  		RCU_INIT_POINTER(ip6n->tnls_wc[0], NULL); | ||||||
|  	else |  	else | ||||||
| @@ -821,6 +846,107 @@ int ip6_tnl_rcv_ctl(struct ip6_tnl *t, | @@ -790,6 +815,107 @@ int ip6_tnl_rcv_ctl(struct ip6_tnl *t, | ||||||
|  } |  } | ||||||
|  EXPORT_SYMBOL_GPL(ip6_tnl_rcv_ctl); |  EXPORT_SYMBOL_GPL(ip6_tnl_rcv_ctl); | ||||||
|   |   | ||||||
| @@ -275,7 +275,7 @@ Signed-off-by: Steven Barth <cyrus@openwrt.org> | |||||||
|  static int __ip6_tnl_rcv(struct ip6_tnl *tunnel, struct sk_buff *skb, |  static int __ip6_tnl_rcv(struct ip6_tnl *tunnel, struct sk_buff *skb, | ||||||
|  			 const struct tnl_ptk_info *tpi, |  			 const struct tnl_ptk_info *tpi, | ||||||
|  			 struct metadata_dst *tun_dst, |  			 struct metadata_dst *tun_dst, | ||||||
| @@ -873,6 +999,27 @@ static int __ip6_tnl_rcv(struct ip6_tnl | @@ -843,6 +969,27 @@ static int __ip6_tnl_rcv(struct ip6_tnl | ||||||
|  	skb_reset_network_header(skb); |  	skb_reset_network_header(skb); | ||||||
|  	memset(skb->cb, 0, sizeof(struct inet6_skb_parm)); |  	memset(skb->cb, 0, sizeof(struct inet6_skb_parm)); | ||||||
|   |   | ||||||
| @@ -303,7 +303,7 @@ Signed-off-by: Steven Barth <cyrus@openwrt.org> | |||||||
|  	__skb_tunnel_rx(skb, tunnel->dev, tunnel->net); |  	__skb_tunnel_rx(skb, tunnel->dev, tunnel->net); | ||||||
|   |   | ||||||
|  	err = dscp_ecn_decapsulate(tunnel, ipv6h, skb); |  	err = dscp_ecn_decapsulate(tunnel, ipv6h, skb); | ||||||
| @@ -1024,6 +1171,7 @@ static void init_tel_txopt(struct ipv6_t | @@ -994,6 +1141,7 @@ static void init_tel_txopt(struct ipv6_t | ||||||
|  	opt->ops.opt_nflen = 8; |  	opt->ops.opt_nflen = 8; | ||||||
|  } |  } | ||||||
|   |   | ||||||
| @@ -311,7 +311,7 @@ Signed-off-by: Steven Barth <cyrus@openwrt.org> | |||||||
|  /** |  /** | ||||||
|   * ip6_tnl_addr_conflict - compare packet addresses to tunnel's own |   * ip6_tnl_addr_conflict - compare packet addresses to tunnel's own | ||||||
|   *   @t: the outgoing tunnel device |   *   @t: the outgoing tunnel device | ||||||
| @@ -1304,6 +1452,7 @@ ipxip6_tnl_xmit(struct sk_buff *skb, str | @@ -1274,6 +1422,7 @@ ipxip6_tnl_xmit(struct sk_buff *skb, str | ||||||
|  		u8 protocol) |  		u8 protocol) | ||||||
|  { |  { | ||||||
|  	struct ip6_tnl *t = netdev_priv(dev); |  	struct ip6_tnl *t = netdev_priv(dev); | ||||||
| @@ -319,7 +319,7 @@ Signed-off-by: Steven Barth <cyrus@openwrt.org> | |||||||
|  	struct ipv6hdr *ipv6h; |  	struct ipv6hdr *ipv6h; | ||||||
|  	const struct iphdr  *iph; |  	const struct iphdr  *iph; | ||||||
|  	int encap_limit = -1; |  	int encap_limit = -1; | ||||||
| @@ -1403,6 +1552,18 @@ ipxip6_tnl_xmit(struct sk_buff *skb, str | @@ -1373,6 +1522,18 @@ ipxip6_tnl_xmit(struct sk_buff *skb, str | ||||||
|  	fl6.flowi6_uid = sock_net_uid(dev_net(dev), NULL); |  	fl6.flowi6_uid = sock_net_uid(dev_net(dev), NULL); | ||||||
|  	dsfield = INET_ECN_encapsulate(dsfield, orig_dsfield); |  	dsfield = INET_ECN_encapsulate(dsfield, orig_dsfield); | ||||||
|   |   | ||||||
| @@ -338,7 +338,7 @@ Signed-off-by: Steven Barth <cyrus@openwrt.org> | |||||||
|  	if (iptunnel_handle_offloads(skb, SKB_GSO_IPXIP6)) |  	if (iptunnel_handle_offloads(skb, SKB_GSO_IPXIP6)) | ||||||
|  		return -1; |  		return -1; | ||||||
|   |   | ||||||
| @@ -1555,6 +1716,14 @@ ip6_tnl_change(struct ip6_tnl *t, const | @@ -1525,6 +1686,14 @@ ip6_tnl_change(struct ip6_tnl *t, const | ||||||
|  	t->parms.link = p->link; |  	t->parms.link = p->link; | ||||||
|  	t->parms.proto = p->proto; |  	t->parms.proto = p->proto; | ||||||
|  	t->parms.fwmark = p->fwmark; |  	t->parms.fwmark = p->fwmark; | ||||||
| @@ -353,7 +353,7 @@ Signed-off-by: Steven Barth <cyrus@openwrt.org> | |||||||
|  	dst_cache_reset(&t->dst_cache); |  	dst_cache_reset(&t->dst_cache); | ||||||
|  	ip6_tnl_link_config(t); |  	ip6_tnl_link_config(t); | ||||||
|  	return 0; |  	return 0; | ||||||
| @@ -1593,6 +1762,7 @@ ip6_tnl_parm_from_user(struct __ip6_tnl_ | @@ -1563,6 +1732,7 @@ ip6_tnl_parm_from_user(struct __ip6_tnl_ | ||||||
|  	p->flowinfo = u->flowinfo; |  	p->flowinfo = u->flowinfo; | ||||||
|  	p->link = u->link; |  	p->link = u->link; | ||||||
|  	p->proto = u->proto; |  	p->proto = u->proto; | ||||||
| @@ -361,7 +361,7 @@ Signed-off-by: Steven Barth <cyrus@openwrt.org> | |||||||
|  	memcpy(p->name, u->name, sizeof(u->name)); |  	memcpy(p->name, u->name, sizeof(u->name)); | ||||||
|  } |  } | ||||||
|   |   | ||||||
| @@ -1978,6 +2148,15 @@ static int ip6_tnl_validate(struct nlatt | @@ -1949,6 +2119,15 @@ static int ip6_tnl_validate(struct nlatt | ||||||
|  	return 0; |  	return 0; | ||||||
|  } |  } | ||||||
|   |   | ||||||
| @@ -377,7 +377,7 @@ Signed-off-by: Steven Barth <cyrus@openwrt.org> | |||||||
|  static void ip6_tnl_netlink_parms(struct nlattr *data[], |  static void ip6_tnl_netlink_parms(struct nlattr *data[], | ||||||
|  				  struct __ip6_tnl_parm *parms) |  				  struct __ip6_tnl_parm *parms) | ||||||
|  { |  { | ||||||
| @@ -2015,6 +2194,46 @@ static void ip6_tnl_netlink_parms(struct | @@ -1986,6 +2165,46 @@ static void ip6_tnl_netlink_parms(struct | ||||||
|   |   | ||||||
|  	if (data[IFLA_IPTUN_FWMARK]) |  	if (data[IFLA_IPTUN_FWMARK]) | ||||||
|  		parms->fwmark = nla_get_u32(data[IFLA_IPTUN_FWMARK]); |  		parms->fwmark = nla_get_u32(data[IFLA_IPTUN_FWMARK]); | ||||||
| @@ -424,7 +424,7 @@ Signed-off-by: Steven Barth <cyrus@openwrt.org> | |||||||
|  } |  } | ||||||
|   |   | ||||||
|  static bool ip6_tnl_netlink_encap_parms(struct nlattr *data[], |  static bool ip6_tnl_netlink_encap_parms(struct nlattr *data[], | ||||||
| @@ -2130,6 +2349,12 @@ static void ip6_tnl_dellink(struct net_d | @@ -2101,6 +2320,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) | ||||||
|  { |  { | ||||||
| @@ -437,7 +437,7 @@ Signed-off-by: Steven Barth <cyrus@openwrt.org> | |||||||
|  	return |  	return | ||||||
|  		/* IFLA_IPTUN_LINK */ |  		/* IFLA_IPTUN_LINK */ | ||||||
|  		nla_total_size(4) + |  		nla_total_size(4) + | ||||||
| @@ -2159,6 +2384,24 @@ static size_t ip6_tnl_get_size(const str | @@ -2130,6 +2355,24 @@ static size_t ip6_tnl_get_size(const str | ||||||
|  		nla_total_size(0) + |  		nla_total_size(0) + | ||||||
|  		/* IFLA_IPTUN_FWMARK */ |  		/* IFLA_IPTUN_FWMARK */ | ||||||
|  		nla_total_size(4) + |  		nla_total_size(4) + | ||||||
| @@ -462,7 +462,7 @@ Signed-off-by: Steven Barth <cyrus@openwrt.org> | |||||||
|  		0; |  		0; | ||||||
|  } |  } | ||||||
|   |   | ||||||
| @@ -2166,6 +2409,9 @@ static int ip6_tnl_fill_info(struct sk_b | @@ -2137,6 +2380,9 @@ static int ip6_tnl_fill_info(struct sk_b | ||||||
|  { |  { | ||||||
|  	struct ip6_tnl *tunnel = netdev_priv(dev); |  	struct ip6_tnl *tunnel = netdev_priv(dev); | ||||||
|  	struct __ip6_tnl_parm *parm = &tunnel->parms; |  	struct __ip6_tnl_parm *parm = &tunnel->parms; | ||||||
| @@ -472,7 +472,7 @@ Signed-off-by: Steven Barth <cyrus@openwrt.org> | |||||||
|   |   | ||||||
|  	if (nla_put_u32(skb, IFLA_IPTUN_LINK, parm->link) || |  	if (nla_put_u32(skb, IFLA_IPTUN_LINK, parm->link) || | ||||||
|  	    nla_put_in6_addr(skb, IFLA_IPTUN_LOCAL, &parm->laddr) || |  	    nla_put_in6_addr(skb, IFLA_IPTUN_LOCAL, &parm->laddr) || | ||||||
| @@ -2175,9 +2421,27 @@ static int ip6_tnl_fill_info(struct sk_b | @@ -2146,9 +2392,27 @@ static int ip6_tnl_fill_info(struct sk_b | ||||||
|  	    nla_put_be32(skb, IFLA_IPTUN_FLOWINFO, parm->flowinfo) || |  	    nla_put_be32(skb, IFLA_IPTUN_FLOWINFO, parm->flowinfo) || | ||||||
|  	    nla_put_u32(skb, IFLA_IPTUN_FLAGS, parm->flags) || |  	    nla_put_u32(skb, IFLA_IPTUN_FLAGS, parm->flags) || | ||||||
|  	    nla_put_u8(skb, IFLA_IPTUN_PROTO, parm->proto) || |  	    nla_put_u8(skb, IFLA_IPTUN_PROTO, parm->proto) || | ||||||
| @@ -501,7 +501,7 @@ Signed-off-by: Steven Barth <cyrus@openwrt.org> | |||||||
|  	if (nla_put_u16(skb, IFLA_IPTUN_ENCAP_TYPE, tunnel->encap.type) || |  	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_SPORT, tunnel->encap.sport) || | ||||||
|  	    nla_put_be16(skb, IFLA_IPTUN_ENCAP_DPORT, tunnel->encap.dport) || |  	    nla_put_be16(skb, IFLA_IPTUN_ENCAP_DPORT, tunnel->encap.dport) || | ||||||
| @@ -2217,6 +2481,7 @@ static const struct nla_policy ip6_tnl_p | @@ -2188,6 +2452,7 @@ static const struct nla_policy ip6_tnl_p | ||||||
|  	[IFLA_IPTUN_ENCAP_DPORT]	= { .type = NLA_U16 }, |  	[IFLA_IPTUN_ENCAP_DPORT]	= { .type = NLA_U16 }, | ||||||
|  	[IFLA_IPTUN_COLLECT_METADATA]	= { .type = NLA_FLAG }, |  	[IFLA_IPTUN_COLLECT_METADATA]	= { .type = NLA_FLAG }, | ||||||
|  	[IFLA_IPTUN_FWMARK]		= { .type = NLA_U32 }, |  	[IFLA_IPTUN_FWMARK]		= { .type = NLA_U32 }, | ||||||
|   | |||||||
| @@ -20,7 +20,7 @@ Signed-off-by: Jonas Gorski <jogo@openwrt.org> | |||||||
|  |  | ||||||
| --- a/include/net/netns/ipv6.h | --- a/include/net/netns/ipv6.h | ||||||
| +++ b/include/net/netns/ipv6.h | +++ b/include/net/netns/ipv6.h | ||||||
| @@ -88,6 +88,7 @@ struct netns_ipv6 { | @@ -85,6 +85,7 @@ struct netns_ipv6 { | ||||||
|  	unsigned int		fib6_routes_require_src; |  	unsigned int		fib6_routes_require_src; | ||||||
|  #endif |  #endif | ||||||
|  	struct rt6_info         *ip6_prohibit_entry; |  	struct rt6_info         *ip6_prohibit_entry; | ||||||
| @@ -43,7 +43,7 @@ Signed-off-by: Jonas Gorski <jogo@openwrt.org> | |||||||
|   |   | ||||||
| --- a/include/uapi/linux/rtnetlink.h | --- a/include/uapi/linux/rtnetlink.h | ||||||
| +++ b/include/uapi/linux/rtnetlink.h | +++ b/include/uapi/linux/rtnetlink.h | ||||||
| @@ -249,6 +249,7 @@ enum { | @@ -256,6 +256,7 @@ enum { | ||||||
|  	RTN_THROW,		/* Not in this table		*/ |  	RTN_THROW,		/* Not in this table		*/ | ||||||
|  	RTN_NAT,		/* Translate this address	*/ |  	RTN_NAT,		/* Translate this address	*/ | ||||||
|  	RTN_XRESOLVE,		/* Use external resolver	*/ |  	RTN_XRESOLVE,		/* Use external resolver	*/ | ||||||
| @@ -66,7 +66,7 @@ Signed-off-by: Jonas Gorski <jogo@openwrt.org> | |||||||
|  static void rt_fibinfo_free(struct rtable __rcu **rtp) |  static void rt_fibinfo_free(struct rtable __rcu **rtp) | ||||||
| --- a/net/ipv4/fib_trie.c | --- a/net/ipv4/fib_trie.c | ||||||
| +++ b/net/ipv4/fib_trie.c | +++ b/net/ipv4/fib_trie.c | ||||||
| @@ -2734,6 +2734,7 @@ static const char *const rtn_type_names[ | @@ -2767,6 +2767,7 @@ static const char *const rtn_type_names[ | ||||||
|  	[RTN_THROW] = "THROW", |  	[RTN_THROW] = "THROW", | ||||||
|  	[RTN_NAT] = "NAT", |  	[RTN_NAT] = "NAT", | ||||||
|  	[RTN_XRESOLVE] = "XRESOLVE", |  	[RTN_XRESOLVE] = "XRESOLVE", | ||||||
| @@ -110,7 +110,7 @@ Signed-off-by: Jonas Gorski <jogo@openwrt.org> | |||||||
|  		return -EINVAL; |  		return -EINVAL; | ||||||
| --- a/net/ipv6/route.c | --- a/net/ipv6/route.c | ||||||
| +++ b/net/ipv6/route.c | +++ b/net/ipv6/route.c | ||||||
| @@ -94,6 +94,8 @@ static int		ip6_pkt_discard(struct sk_bu | @@ -97,6 +97,8 @@ static int		ip6_pkt_discard(struct sk_bu | ||||||
|  static int		ip6_pkt_discard_out(struct net *net, struct sock *sk, struct sk_buff *skb); |  static int		ip6_pkt_discard_out(struct net *net, struct sock *sk, struct sk_buff *skb); | ||||||
|  static int		ip6_pkt_prohibit(struct sk_buff *skb); |  static int		ip6_pkt_prohibit(struct sk_buff *skb); | ||||||
|  static int		ip6_pkt_prohibit_out(struct net *net, struct sock *sk, struct sk_buff *skb); |  static int		ip6_pkt_prohibit_out(struct net *net, struct sock *sk, struct sk_buff *skb); | ||||||
| @@ -119,7 +119,7 @@ Signed-off-by: Jonas Gorski <jogo@openwrt.org> | |||||||
|  static void		ip6_link_failure(struct sk_buff *skb); |  static void		ip6_link_failure(struct sk_buff *skb); | ||||||
|  static void		ip6_rt_update_pmtu(struct dst_entry *dst, struct sock *sk, |  static void		ip6_rt_update_pmtu(struct dst_entry *dst, struct sock *sk, | ||||||
|  					   struct sk_buff *skb, u32 mtu, |  					   struct sk_buff *skb, u32 mtu, | ||||||
| @@ -309,6 +311,18 @@ static const struct rt6_info ip6_prohibi | @@ -312,6 +314,18 @@ static const struct rt6_info ip6_prohibi | ||||||
|  	.rt6i_flags	= (RTF_REJECT | RTF_NONEXTHOP), |  	.rt6i_flags	= (RTF_REJECT | RTF_NONEXTHOP), | ||||||
|  }; |  }; | ||||||
|   |   | ||||||
| @@ -138,7 +138,7 @@ Signed-off-by: Jonas Gorski <jogo@openwrt.org> | |||||||
|  static const struct rt6_info ip6_blk_hole_entry_template = { |  static const struct rt6_info ip6_blk_hole_entry_template = { | ||||||
|  	.dst = { |  	.dst = { | ||||||
|  		.__refcnt	= ATOMIC_INIT(1), |  		.__refcnt	= ATOMIC_INIT(1), | ||||||
| @@ -1030,6 +1044,7 @@ static const int fib6_prop[RTN_MAX + 1] | @@ -1033,6 +1047,7 @@ static const int fib6_prop[RTN_MAX + 1] | ||||||
|  	[RTN_BLACKHOLE]	= -EINVAL, |  	[RTN_BLACKHOLE]	= -EINVAL, | ||||||
|  	[RTN_UNREACHABLE] = -EHOSTUNREACH, |  	[RTN_UNREACHABLE] = -EHOSTUNREACH, | ||||||
|  	[RTN_PROHIBIT]	= -EACCES, |  	[RTN_PROHIBIT]	= -EACCES, | ||||||
| @@ -146,7 +146,7 @@ Signed-off-by: Jonas Gorski <jogo@openwrt.org> | |||||||
|  	[RTN_THROW]	= -EAGAIN, |  	[RTN_THROW]	= -EAGAIN, | ||||||
|  	[RTN_NAT]	= -EINVAL, |  	[RTN_NAT]	= -EINVAL, | ||||||
|  	[RTN_XRESOLVE]	= -EINVAL, |  	[RTN_XRESOLVE]	= -EINVAL, | ||||||
| @@ -1065,6 +1080,10 @@ static void ip6_rt_init_dst_reject(struc | @@ -1068,6 +1083,10 @@ static void ip6_rt_init_dst_reject(struc | ||||||
|  		rt->dst.output = ip6_pkt_prohibit_out; |  		rt->dst.output = ip6_pkt_prohibit_out; | ||||||
|  		rt->dst.input = ip6_pkt_prohibit; |  		rt->dst.input = ip6_pkt_prohibit; | ||||||
|  		break; |  		break; | ||||||
| @@ -157,7 +157,7 @@ Signed-off-by: Jonas Gorski <jogo@openwrt.org> | |||||||
|  	case RTN_THROW: |  	case RTN_THROW: | ||||||
|  	case RTN_UNREACHABLE: |  	case RTN_UNREACHABLE: | ||||||
|  	default: |  	default: | ||||||
| @@ -4448,6 +4467,17 @@ static int ip6_pkt_prohibit_out(struct n | @@ -4559,6 +4578,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); | ||||||
|  } |  } | ||||||
|   |   | ||||||
| @@ -175,7 +175,7 @@ Signed-off-by: Jonas Gorski <jogo@openwrt.org> | |||||||
|  /* |  /* | ||||||
|   *	Allocate a dst for local (unicast / anycast) address. |   *	Allocate a dst for local (unicast / anycast) address. | ||||||
|   */ |   */ | ||||||
| @@ -4928,7 +4958,8 @@ static int rtm_to_fib6_config(struct sk_ | @@ -5039,7 +5069,8 @@ static int rtm_to_fib6_config(struct sk_ | ||||||
|  	if (rtm->rtm_type == RTN_UNREACHABLE || |  	if (rtm->rtm_type == RTN_UNREACHABLE || | ||||||
|  	    rtm->rtm_type == RTN_BLACKHOLE || |  	    rtm->rtm_type == RTN_BLACKHOLE || | ||||||
|  	    rtm->rtm_type == RTN_PROHIBIT || |  	    rtm->rtm_type == RTN_PROHIBIT || | ||||||
| @@ -185,7 +185,7 @@ Signed-off-by: Jonas Gorski <jogo@openwrt.org> | |||||||
|  		cfg->fc_flags |= RTF_REJECT; |  		cfg->fc_flags |= RTF_REJECT; | ||||||
|   |   | ||||||
|  	if (rtm->rtm_type == RTN_LOCAL) |  	if (rtm->rtm_type == RTN_LOCAL) | ||||||
| @@ -6127,6 +6158,8 @@ static int ip6_route_dev_notify(struct n | @@ -6292,6 +6323,8 @@ static int ip6_route_dev_notify(struct n | ||||||
|  #ifdef CONFIG_IPV6_MULTIPLE_TABLES |  #ifdef CONFIG_IPV6_MULTIPLE_TABLES | ||||||
|  		net->ipv6.ip6_prohibit_entry->dst.dev = dev; |  		net->ipv6.ip6_prohibit_entry->dst.dev = dev; | ||||||
|  		net->ipv6.ip6_prohibit_entry->rt6i_idev = in6_dev_get(dev); |  		net->ipv6.ip6_prohibit_entry->rt6i_idev = in6_dev_get(dev); | ||||||
| @@ -194,7 +194,7 @@ Signed-off-by: Jonas Gorski <jogo@openwrt.org> | |||||||
|  		net->ipv6.ip6_blk_hole_entry->dst.dev = dev; |  		net->ipv6.ip6_blk_hole_entry->dst.dev = dev; | ||||||
|  		net->ipv6.ip6_blk_hole_entry->rt6i_idev = in6_dev_get(dev); |  		net->ipv6.ip6_blk_hole_entry->rt6i_idev = in6_dev_get(dev); | ||||||
|  #endif |  #endif | ||||||
| @@ -6138,6 +6171,7 @@ static int ip6_route_dev_notify(struct n | @@ -6303,6 +6336,7 @@ static int ip6_route_dev_notify(struct n | ||||||
|  		in6_dev_put_clear(&net->ipv6.ip6_null_entry->rt6i_idev); |  		in6_dev_put_clear(&net->ipv6.ip6_null_entry->rt6i_idev); | ||||||
|  #ifdef CONFIG_IPV6_MULTIPLE_TABLES |  #ifdef CONFIG_IPV6_MULTIPLE_TABLES | ||||||
|  		in6_dev_put_clear(&net->ipv6.ip6_prohibit_entry->rt6i_idev); |  		in6_dev_put_clear(&net->ipv6.ip6_prohibit_entry->rt6i_idev); | ||||||
| @@ -202,7 +202,7 @@ Signed-off-by: Jonas Gorski <jogo@openwrt.org> | |||||||
|  		in6_dev_put_clear(&net->ipv6.ip6_blk_hole_entry->rt6i_idev); |  		in6_dev_put_clear(&net->ipv6.ip6_blk_hole_entry->rt6i_idev); | ||||||
|  #endif |  #endif | ||||||
|  	} |  	} | ||||||
| @@ -6329,6 +6363,8 @@ static int __net_init ip6_route_net_init | @@ -6494,6 +6528,8 @@ static int __net_init ip6_route_net_init | ||||||
|   |   | ||||||
|  #ifdef CONFIG_IPV6_MULTIPLE_TABLES |  #ifdef CONFIG_IPV6_MULTIPLE_TABLES | ||||||
|  	net->ipv6.fib6_has_custom_rules = false; |  	net->ipv6.fib6_has_custom_rules = false; | ||||||
| @@ -211,7 +211,7 @@ Signed-off-by: Jonas Gorski <jogo@openwrt.org> | |||||||
|  	net->ipv6.ip6_prohibit_entry = kmemdup(&ip6_prohibit_entry_template, |  	net->ipv6.ip6_prohibit_entry = kmemdup(&ip6_prohibit_entry_template, | ||||||
|  					       sizeof(*net->ipv6.ip6_prohibit_entry), |  					       sizeof(*net->ipv6.ip6_prohibit_entry), | ||||||
|  					       GFP_KERNEL); |  					       GFP_KERNEL); | ||||||
| @@ -6339,11 +6375,21 @@ static int __net_init ip6_route_net_init | @@ -6504,11 +6540,21 @@ static int __net_init ip6_route_net_init | ||||||
|  			 ip6_template_metrics, true); |  			 ip6_template_metrics, true); | ||||||
|  	INIT_LIST_HEAD(&net->ipv6.ip6_prohibit_entry->rt6i_uncached); |  	INIT_LIST_HEAD(&net->ipv6.ip6_prohibit_entry->rt6i_uncached); | ||||||
|   |   | ||||||
| @@ -234,7 +234,7 @@ Signed-off-by: Jonas Gorski <jogo@openwrt.org> | |||||||
|  	net->ipv6.ip6_blk_hole_entry->dst.ops = &net->ipv6.ip6_dst_ops; |  	net->ipv6.ip6_blk_hole_entry->dst.ops = &net->ipv6.ip6_dst_ops; | ||||||
|  	dst_init_metrics(&net->ipv6.ip6_blk_hole_entry->dst, |  	dst_init_metrics(&net->ipv6.ip6_blk_hole_entry->dst, | ||||||
|  			 ip6_template_metrics, true); |  			 ip6_template_metrics, true); | ||||||
| @@ -6370,6 +6416,8 @@ out: | @@ -6535,6 +6581,8 @@ out: | ||||||
|  	return ret; |  	return ret; | ||||||
|   |   | ||||||
|  #ifdef CONFIG_IPV6_MULTIPLE_TABLES |  #ifdef CONFIG_IPV6_MULTIPLE_TABLES | ||||||
| @@ -243,7 +243,7 @@ Signed-off-by: Jonas Gorski <jogo@openwrt.org> | |||||||
|  out_ip6_prohibit_entry: |  out_ip6_prohibit_entry: | ||||||
|  	kfree(net->ipv6.ip6_prohibit_entry); |  	kfree(net->ipv6.ip6_prohibit_entry); | ||||||
|  out_ip6_null_entry: |  out_ip6_null_entry: | ||||||
| @@ -6389,6 +6437,7 @@ static void __net_exit ip6_route_net_exi | @@ -6554,6 +6602,7 @@ static void __net_exit ip6_route_net_exi | ||||||
|  	kfree(net->ipv6.ip6_null_entry); |  	kfree(net->ipv6.ip6_null_entry); | ||||||
|  #ifdef CONFIG_IPV6_MULTIPLE_TABLES |  #ifdef CONFIG_IPV6_MULTIPLE_TABLES | ||||||
|  	kfree(net->ipv6.ip6_prohibit_entry); |  	kfree(net->ipv6.ip6_prohibit_entry); | ||||||
| @@ -251,7 +251,7 @@ Signed-off-by: Jonas Gorski <jogo@openwrt.org> | |||||||
|  	kfree(net->ipv6.ip6_blk_hole_entry); |  	kfree(net->ipv6.ip6_blk_hole_entry); | ||||||
|  #endif |  #endif | ||||||
|  	dst_entries_destroy(&net->ipv6.ip6_dst_ops); |  	dst_entries_destroy(&net->ipv6.ip6_dst_ops); | ||||||
| @@ -6466,6 +6515,9 @@ void __init ip6_route_init_special_entri | @@ -6631,6 +6680,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_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->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_blk_hole_entry->rt6i_idev = in6_dev_get(init_net.loopback_dev); | ||||||
|   | |||||||
| @@ -39,7 +39,7 @@ Signed-off-by: Jonas Gorski <jogo@openwrt.org> | |||||||
|   */ |   */ | ||||||
| --- a/include/uapi/linux/rtnetlink.h | --- a/include/uapi/linux/rtnetlink.h | ||||||
| +++ b/include/uapi/linux/rtnetlink.h | +++ b/include/uapi/linux/rtnetlink.h | ||||||
| @@ -253,6 +253,8 @@ enum { | @@ -260,6 +260,8 @@ enum { | ||||||
|  	__RTN_MAX |  	__RTN_MAX | ||||||
|  }; |  }; | ||||||
|   |   | ||||||
|   | |||||||
| @@ -11,7 +11,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|  |  | ||||||
| --- a/include/linux/netdevice.h | --- a/include/linux/netdevice.h | ||||||
| +++ b/include/linux/netdevice.h | +++ b/include/linux/netdevice.h | ||||||
| @@ -2036,6 +2036,8 @@ struct net_device { | @@ -2068,6 +2068,8 @@ struct net_device { | ||||||
|  	struct netdev_hw_addr_list	mc; |  	struct netdev_hw_addr_list	mc; | ||||||
|  	struct netdev_hw_addr_list	dev_addrs; |  	struct netdev_hw_addr_list	dev_addrs; | ||||||
|   |   | ||||||
| @@ -22,17 +22,17 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|  #endif |  #endif | ||||||
| --- a/include/linux/skbuff.h | --- a/include/linux/skbuff.h | ||||||
| +++ b/include/linux/skbuff.h | +++ b/include/linux/skbuff.h | ||||||
| @@ -858,6 +858,7 @@ struct sk_buff { | @@ -855,6 +855,7 @@ struct sk_buff { | ||||||
|  #ifdef CONFIG_TLS_DEVICE |  #ifdef CONFIG_IPV6_NDISC_NODETYPE | ||||||
|  	__u8			decrypted:1; |  	__u8			ndisc_nodetype:2; | ||||||
|  #endif |  #endif | ||||||
| +	__u8			gro_skip:1; | +	__u8			gro_skip:1; | ||||||
|   |   | ||||||
|  #ifdef CONFIG_NET_SCHED |  	__u8			ipvs_property:1; | ||||||
|  	__u16			tc_index;	/* traffic control index */ |  	__u8			inner_protocol_type:1; | ||||||
| --- a/net/core/dev.c | --- a/net/core/dev.c | ||||||
| +++ b/net/core/dev.c | +++ b/net/core/dev.c | ||||||
| @@ -6062,6 +6062,9 @@ static enum gro_result dev_gro_receive(s | @@ -6051,6 +6051,9 @@ static enum gro_result dev_gro_receive(s | ||||||
|  	int same_flow; |  	int same_flow; | ||||||
|  	int grow; |  	int grow; | ||||||
|   |   | ||||||
| @@ -42,7 +42,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|  	if (netif_elide_gro(skb->dev)) |  	if (netif_elide_gro(skb->dev)) | ||||||
|  		goto normal; |  		goto normal; | ||||||
|   |   | ||||||
| @@ -8039,6 +8042,48 @@ static void __netdev_adjacent_dev_unlink | @@ -8065,6 +8068,48 @@ static void __netdev_adjacent_dev_unlink | ||||||
|  					   &upper_dev->adj_list.lower); |  					   &upper_dev->adj_list.lower); | ||||||
|  } |  } | ||||||
|   |   | ||||||
| @@ -91,7 +91,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|  static int __netdev_upper_dev_link(struct net_device *dev, |  static int __netdev_upper_dev_link(struct net_device *dev, | ||||||
|  				   struct net_device *upper_dev, bool master, |  				   struct net_device *upper_dev, bool master, | ||||||
|  				   void *upper_priv, void *upper_info, |  				   void *upper_priv, void *upper_info, | ||||||
| @@ -8090,6 +8135,7 @@ static int __netdev_upper_dev_link(struc | @@ -8116,6 +8161,7 @@ static int __netdev_upper_dev_link(struc | ||||||
|  	if (ret) |  	if (ret) | ||||||
|  		return ret; |  		return ret; | ||||||
|   |   | ||||||
| @@ -99,7 +99,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|  	ret = call_netdevice_notifiers_info(NETDEV_CHANGEUPPER, |  	ret = call_netdevice_notifiers_info(NETDEV_CHANGEUPPER, | ||||||
|  					    &changeupper_info.info); |  					    &changeupper_info.info); | ||||||
|  	ret = notifier_to_errno(ret); |  	ret = notifier_to_errno(ret); | ||||||
| @@ -8186,6 +8232,7 @@ static void __netdev_upper_dev_unlink(st | @@ -8212,6 +8258,7 @@ static void __netdev_upper_dev_unlink(st | ||||||
|   |   | ||||||
|  	__netdev_adjacent_dev_unlink_neighbour(dev, upper_dev); |  	__netdev_adjacent_dev_unlink_neighbour(dev, upper_dev); | ||||||
|   |   | ||||||
| @@ -107,7 +107,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|  	call_netdevice_notifiers_info(NETDEV_CHANGEUPPER, |  	call_netdevice_notifiers_info(NETDEV_CHANGEUPPER, | ||||||
|  				      &changeupper_info.info); |  				      &changeupper_info.info); | ||||||
|   |   | ||||||
| @@ -8972,6 +9019,7 @@ int dev_set_mac_address(struct net_devic | @@ -9031,6 +9078,7 @@ int dev_set_mac_address(struct net_devic | ||||||
|  	if (err) |  	if (err) | ||||||
|  		return err; |  		return err; | ||||||
|  	dev->addr_assign_type = NET_ADDR_SET; |  	dev->addr_assign_type = NET_ADDR_SET; | ||||||
| @@ -117,7 +117,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|  	return 0; |  	return 0; | ||||||
| --- a/net/ethernet/eth.c | --- a/net/ethernet/eth.c | ||||||
| +++ b/net/ethernet/eth.c | +++ b/net/ethernet/eth.c | ||||||
| @@ -143,6 +143,18 @@ u32 eth_get_headlen(const struct net_dev | @@ -142,6 +142,18 @@ u32 eth_get_headlen(const struct net_dev | ||||||
|  } |  } | ||||||
|  EXPORT_SYMBOL(eth_get_headlen); |  EXPORT_SYMBOL(eth_get_headlen); | ||||||
|   |   | ||||||
| @@ -136,7 +136,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|  /** |  /** | ||||||
|   * eth_type_trans - determine the packet's protocol ID. |   * eth_type_trans - determine the packet's protocol ID. | ||||||
|   * @skb: received socket data |   * @skb: received socket data | ||||||
| @@ -174,6 +186,10 @@ __be16 eth_type_trans(struct sk_buff *sk | @@ -173,6 +185,10 @@ __be16 eth_type_trans(struct sk_buff *sk | ||||||
|  		} else { |  		} else { | ||||||
|  			skb->pkt_type = PACKET_OTHERHOST; |  			skb->pkt_type = PACKET_OTHERHOST; | ||||||
|  		} |  		} | ||||||
|   | |||||||
| @@ -20,7 +20,7 @@ Signed-off-by: Ansuel Smith <ansuelsmth@gmail.com> | |||||||
|  |  | ||||||
| --- a/net/core/of_net.c | --- a/net/core/of_net.c | ||||||
| +++ b/net/core/of_net.c | +++ b/net/core/of_net.c | ||||||
| @@ -115,27 +115,62 @@ static int of_get_mac_addr_nvmem(struct | @@ -119,27 +119,62 @@ static int of_get_mac_addr_nvmem(struct | ||||||
|   * this case, the real MAC is in 'local-mac-address', and 'mac-address' exists |   * this case, the real MAC is in 'local-mac-address', and 'mac-address' exists | ||||||
|   * but is all zeros. |   * but is all zeros. | ||||||
|   * |   * | ||||||
|   | |||||||
| @@ -26,9 +26,9 @@ | |||||||
| +} | +} | ||||||
| + | + | ||||||
|  /** |  /** | ||||||
|   * Search the device tree for the best MAC address to use.  'mac-address' is |   * of_get_mac_address() | ||||||
|   * checked first, because that is supposed to contain to "most recent" MAC |   * @np:		Caller's Device Node | ||||||
| @@ -171,6 +192,7 @@ found: | @@ -175,6 +196,7 @@ found: | ||||||
|  		addr[5] = (mac_val >> 0) & 0xff; |  		addr[5] = (mac_val >> 0) & 0xff; | ||||||
|  	} |  	} | ||||||
|   |   | ||||||
|   | |||||||
| @@ -14,9 +14,9 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|  |  | ||||||
| --- a/drivers/net/ethernet/mediatek/mtk_ppe_offload.c | --- a/drivers/net/ethernet/mediatek/mtk_ppe_offload.c | ||||||
| +++ b/drivers/net/ethernet/mediatek/mtk_ppe_offload.c | +++ b/drivers/net/ethernet/mediatek/mtk_ppe_offload.c | ||||||
| @@ -187,6 +187,9 @@ mtk_flow_offload_replace(struct mtk_eth | @@ -189,6 +189,9 @@ mtk_flow_offload_replace(struct mtk_eth | ||||||
|  	int hash; |  	if (rhashtable_lookup(ð->flow_table, &f->cookie, mtk_flow_ht_params)) | ||||||
|  	int i; |  		return -EEXIST; | ||||||
|   |   | ||||||
| +	if (rhashtable_lookup(ð->flow_table, &f->cookie, mtk_flow_ht_params)) | +	if (rhashtable_lookup(ð->flow_table, &f->cookie, mtk_flow_ht_params)) | ||||||
| +		return -EEXIST; | +		return -EEXIST; | ||||||
|   | |||||||
| @@ -1,14 +1,14 @@ | |||||||
| --- a/drivers/net/ethernet/mediatek/mtk_ppe_offload.c | --- a/drivers/net/ethernet/mediatek/mtk_ppe_offload.c | ||||||
| +++ b/drivers/net/ethernet/mediatek/mtk_ppe_offload.c | +++ b/drivers/net/ethernet/mediatek/mtk_ppe_offload.c | ||||||
| @@ -7,6 +7,7 @@ | @@ -6,6 +6,7 @@ | ||||||
|  #include <linux/rhashtable.h> |  | ||||||
|  #include <linux/if_ether.h> |  #include <linux/if_ether.h> | ||||||
|  |  #include <linux/rhashtable.h> | ||||||
|  #include <linux/ip.h> |  #include <linux/ip.h> | ||||||
| +#include <linux/ipv6.h> | +#include <linux/ipv6.h> | ||||||
|  #include <net/flow_offload.h> |  #include <net/flow_offload.h> | ||||||
|  #include <net/pkt_cls.h> |  #include <net/pkt_cls.h> | ||||||
|  #include <net/dsa.h> |  #include <net/dsa.h> | ||||||
| @@ -20,6 +21,11 @@ struct mtk_flow_data { | @@ -19,6 +20,11 @@ struct mtk_flow_data { | ||||||
|  			__be32 src_addr; |  			__be32 src_addr; | ||||||
|  			__be32 dst_addr; |  			__be32 dst_addr; | ||||||
|  		} v4; |  		} v4; | ||||||
| @@ -20,7 +20,7 @@ | |||||||
|  	}; |  	}; | ||||||
|   |   | ||||||
|  	__be16 src_port; |  	__be16 src_port; | ||||||
| @@ -64,6 +70,14 @@ mtk_flow_set_ipv4_addr(struct mtk_foe_en | @@ -63,6 +69,14 @@ mtk_flow_set_ipv4_addr(struct mtk_foe_en | ||||||
|  					    data->v4.dst_addr, data->dst_port); |  					    data->v4.dst_addr, data->dst_port); | ||||||
|  } |  } | ||||||
|   |   | ||||||
| @@ -35,7 +35,7 @@ | |||||||
|  static void |  static void | ||||||
|  mtk_flow_offload_mangle_eth(const struct flow_action_entry *act, void *eth) |  mtk_flow_offload_mangle_eth(const struct flow_action_entry *act, void *eth) | ||||||
|  { |  { | ||||||
| @@ -254,6 +268,9 @@ mtk_flow_offload_replace(struct mtk_eth | @@ -256,6 +270,9 @@ mtk_flow_offload_replace(struct mtk_eth | ||||||
|  	case FLOW_DISSECTOR_KEY_IPV4_ADDRS: |  	case FLOW_DISSECTOR_KEY_IPV4_ADDRS: | ||||||
|  		offload_type = MTK_PPE_PKT_TYPE_IPV4_HNAPT; |  		offload_type = MTK_PPE_PKT_TYPE_IPV4_HNAPT; | ||||||
|  		break; |  		break; | ||||||
| @@ -45,7 +45,7 @@ | |||||||
|  	default: |  	default: | ||||||
|  		return -EOPNOTSUPP; |  		return -EOPNOTSUPP; | ||||||
|  	} |  	} | ||||||
| @@ -289,6 +306,17 @@ mtk_flow_offload_replace(struct mtk_eth | @@ -291,6 +308,17 @@ mtk_flow_offload_replace(struct mtk_eth | ||||||
|  		mtk_flow_set_ipv4_addr(&foe, &data, false); |  		mtk_flow_set_ipv4_addr(&foe, &data, false); | ||||||
|  	} |  	} | ||||||
|   |   | ||||||
|   | |||||||
| @@ -10,7 +10,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|  |  | ||||||
| --- a/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 | +++ b/drivers/net/ethernet/mediatek/mtk_eth_soc.c | ||||||
| @@ -2171,8 +2171,8 @@ static irqreturn_t mtk_handle_irq_rx(int | @@ -2178,8 +2178,8 @@ static irqreturn_t mtk_handle_irq_rx(int | ||||||
|   |   | ||||||
|  	eth->rx_events++; |  	eth->rx_events++; | ||||||
|  	if (likely(napi_schedule_prep(ð->rx_napi))) { |  	if (likely(napi_schedule_prep(ð->rx_napi))) { | ||||||
| @@ -20,7 +20,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|  	} |  	} | ||||||
|   |   | ||||||
|  	return IRQ_HANDLED; |  	return IRQ_HANDLED; | ||||||
| @@ -2184,8 +2184,8 @@ static irqreturn_t mtk_handle_irq_tx(int | @@ -2191,8 +2191,8 @@ static irqreturn_t mtk_handle_irq_tx(int | ||||||
|   |   | ||||||
|  	eth->tx_events++; |  	eth->tx_events++; | ||||||
|  	if (likely(napi_schedule_prep(ð->tx_napi))) { |  	if (likely(napi_schedule_prep(ð->tx_napi))) { | ||||||
| @@ -30,7 +30,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|  	} |  	} | ||||||
|   |   | ||||||
|  	return IRQ_HANDLED; |  	return IRQ_HANDLED; | ||||||
| @@ -3229,6 +3229,8 @@ static int mtk_probe(struct platform_dev | @@ -3242,6 +3242,8 @@ static int mtk_probe(struct platform_dev | ||||||
|  	 * for NAPI to work |  	 * for NAPI to work | ||||||
|  	 */ |  	 */ | ||||||
|  	init_dummy_netdev(ð->dummy_dev); |  	init_dummy_netdev(ð->dummy_dev); | ||||||
|   | |||||||
| @@ -11,7 +11,7 @@ Signed-off-by: Gabor Juhos <juhosg@openwrt.org> | |||||||
|  |  | ||||||
| --- a/drivers/net/phy/phy_device.c | --- a/drivers/net/phy/phy_device.c | ||||||
| +++ b/drivers/net/phy/phy_device.c | +++ b/drivers/net/phy/phy_device.c | ||||||
| @@ -1651,6 +1651,9 @@ void phy_detach(struct phy_device *phyde | @@ -1715,6 +1715,9 @@ void phy_detach(struct phy_device *phyde | ||||||
|  	struct module *ndev_owner = NULL; |  	struct module *ndev_owner = NULL; | ||||||
|  	struct mii_bus *bus; |  	struct mii_bus *bus; | ||||||
|   |   | ||||||
| @@ -23,7 +23,7 @@ Signed-off-by: Gabor Juhos <juhosg@openwrt.org> | |||||||
|  			sysfs_remove_link(&dev->dev.kobj, "phydev"); |  			sysfs_remove_link(&dev->dev.kobj, "phydev"); | ||||||
| --- a/include/linux/phy.h | --- a/include/linux/phy.h | ||||||
| +++ b/include/linux/phy.h | +++ b/include/linux/phy.h | ||||||
| @@ -761,6 +761,12 @@ struct phy_driver { | @@ -783,6 +783,12 @@ struct phy_driver { | ||||||
|  	/** @handle_interrupt: Override default interrupt handling */ |  	/** @handle_interrupt: Override default interrupt handling */ | ||||||
|  	irqreturn_t (*handle_interrupt)(struct phy_device *phydev); |  	irqreturn_t (*handle_interrupt)(struct phy_device *phydev); | ||||||
|   |   | ||||||
|   | |||||||
| @@ -14,7 +14,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|  |  | ||||||
| --- a/include/linux/if_bridge.h | --- a/include/linux/if_bridge.h | ||||||
| +++ b/include/linux/if_bridge.h | +++ b/include/linux/if_bridge.h | ||||||
| @@ -56,6 +56,7 @@ struct br_ip_list { | @@ -58,6 +58,7 @@ struct br_ip_list { | ||||||
|  #define BR_MRP_LOST_CONT	BIT(18) |  #define BR_MRP_LOST_CONT	BIT(18) | ||||||
|  #define BR_MRP_LOST_IN_CONT	BIT(19) |  #define BR_MRP_LOST_IN_CONT	BIT(19) | ||||||
|  #define BR_TX_FWD_OFFLOAD	BIT(20) |  #define BR_TX_FWD_OFFLOAD	BIT(20) | ||||||
| @@ -24,7 +24,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|   |   | ||||||
| --- a/net/bridge/br_forward.c | --- a/net/bridge/br_forward.c | ||||||
| +++ b/net/bridge/br_forward.c | +++ b/net/bridge/br_forward.c | ||||||
| @@ -191,6 +191,7 @@ out: | @@ -199,6 +199,7 @@ out: | ||||||
|  void br_flood(struct net_bridge *br, struct sk_buff *skb, |  void br_flood(struct net_bridge *br, struct sk_buff *skb, | ||||||
|  	      enum br_pkt_type pkt_type, bool local_rcv, bool local_orig) |  	      enum br_pkt_type pkt_type, bool local_rcv, bool local_orig) | ||||||
|  { |  { | ||||||
| @@ -32,7 +32,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|  	struct net_bridge_port *prev = NULL; |  	struct net_bridge_port *prev = NULL; | ||||||
|  	struct net_bridge_port *p; |  	struct net_bridge_port *p; | ||||||
|   |   | ||||||
| @@ -206,6 +207,10 @@ void br_flood(struct net_bridge *br, str | @@ -214,6 +215,10 @@ void br_flood(struct net_bridge *br, str | ||||||
|  		case BR_PKT_MULTICAST: |  		case BR_PKT_MULTICAST: | ||||||
|  			if (!(p->flags & BR_MCAST_FLOOD) && skb->dev != br->dev) |  			if (!(p->flags & BR_MCAST_FLOOD) && skb->dev != br->dev) | ||||||
|  				continue; |  				continue; | ||||||
| @@ -45,7 +45,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|  			if (!(p->flags & BR_BCAST_FLOOD) && skb->dev != br->dev) |  			if (!(p->flags & BR_BCAST_FLOOD) && skb->dev != br->dev) | ||||||
| --- a/net/bridge/br_input.c | --- a/net/bridge/br_input.c | ||||||
| +++ b/net/bridge/br_input.c | +++ b/net/bridge/br_input.c | ||||||
| @@ -305,6 +305,8 @@ static rx_handler_result_t br_handle_fra | @@ -319,6 +319,8 @@ static rx_handler_result_t br_handle_fra | ||||||
|  		fwd_mask |= p->group_fwd_mask; |  		fwd_mask |= p->group_fwd_mask; | ||||||
|  		switch (dest[5]) { |  		switch (dest[5]) { | ||||||
|  		case 0x00:	/* Bridge Group Address */ |  		case 0x00:	/* Bridge Group Address */ | ||||||
| @@ -56,7 +56,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|  			if (p->br->stp_enabled == BR_NO_STP || |  			if (p->br->stp_enabled == BR_NO_STP || | ||||||
| --- a/net/bridge/br_sysfs_if.c | --- a/net/bridge/br_sysfs_if.c | ||||||
| +++ b/net/bridge/br_sysfs_if.c | +++ b/net/bridge/br_sysfs_if.c | ||||||
| @@ -233,6 +233,7 @@ BRPORT_ATTR_FLAG(multicast_flood, BR_MCA | @@ -240,6 +240,7 @@ BRPORT_ATTR_FLAG(multicast_flood, BR_MCA | ||||||
|  BRPORT_ATTR_FLAG(broadcast_flood, BR_BCAST_FLOOD); |  BRPORT_ATTR_FLAG(broadcast_flood, BR_BCAST_FLOOD); | ||||||
|  BRPORT_ATTR_FLAG(neigh_suppress, BR_NEIGH_SUPPRESS); |  BRPORT_ATTR_FLAG(neigh_suppress, BR_NEIGH_SUPPRESS); | ||||||
|  BRPORT_ATTR_FLAG(isolated, BR_ISOLATED); |  BRPORT_ATTR_FLAG(isolated, BR_ISOLATED); | ||||||
| @@ -64,7 +64,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|   |   | ||||||
|  #ifdef CONFIG_BRIDGE_IGMP_SNOOPING |  #ifdef CONFIG_BRIDGE_IGMP_SNOOPING | ||||||
|  static ssize_t show_multicast_router(struct net_bridge_port *p, char *buf) |  static ssize_t show_multicast_router(struct net_bridge_port *p, char *buf) | ||||||
| @@ -285,6 +286,7 @@ static const struct brport_attribute *br | @@ -292,6 +293,7 @@ static const struct brport_attribute *br | ||||||
|  	&brport_attr_group_fwd_mask, |  	&brport_attr_group_fwd_mask, | ||||||
|  	&brport_attr_neigh_suppress, |  	&brport_attr_neigh_suppress, | ||||||
|  	&brport_attr_isolated, |  	&brport_attr_isolated, | ||||||
| @@ -106,7 +106,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|   |   | ||||||
| --- a/include/uapi/linux/if_link.h | --- a/include/uapi/linux/if_link.h | ||||||
| +++ b/include/uapi/linux/if_link.h | +++ b/include/uapi/linux/if_link.h | ||||||
| @@ -524,6 +524,7 @@ enum { | @@ -536,6 +536,7 @@ enum { | ||||||
|  	IFLA_BRPORT_MRP_IN_OPEN, |  	IFLA_BRPORT_MRP_IN_OPEN, | ||||||
|  	IFLA_BRPORT_MCAST_EHT_HOSTS_LIMIT, |  	IFLA_BRPORT_MCAST_EHT_HOSTS_LIMIT, | ||||||
|  	IFLA_BRPORT_MCAST_EHT_HOSTS_CNT, |  	IFLA_BRPORT_MCAST_EHT_HOSTS_CNT, | ||||||
| @@ -116,7 +116,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|  #define IFLA_BRPORT_MAX (__IFLA_BRPORT_MAX - 1) |  #define IFLA_BRPORT_MAX (__IFLA_BRPORT_MAX - 1) | ||||||
| --- a/net/bridge/br_netlink.c | --- a/net/bridge/br_netlink.c | ||||||
| +++ b/net/bridge/br_netlink.c | +++ b/net/bridge/br_netlink.c | ||||||
| @@ -137,6 +137,7 @@ static inline size_t br_port_info_size(v | @@ -184,6 +184,7 @@ static inline size_t br_port_info_size(v | ||||||
|  		+ nla_total_size(1)	/* IFLA_BRPORT_VLAN_TUNNEL */ |  		+ nla_total_size(1)	/* IFLA_BRPORT_VLAN_TUNNEL */ | ||||||
|  		+ nla_total_size(1)	/* IFLA_BRPORT_NEIGH_SUPPRESS */ |  		+ nla_total_size(1)	/* IFLA_BRPORT_NEIGH_SUPPRESS */ | ||||||
|  		+ nla_total_size(1)	/* IFLA_BRPORT_ISOLATED */ |  		+ nla_total_size(1)	/* IFLA_BRPORT_ISOLATED */ | ||||||
| @@ -124,7 +124,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|  		+ nla_total_size(sizeof(struct ifla_bridge_id))	/* IFLA_BRPORT_ROOT_ID */ |  		+ 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(struct ifla_bridge_id))	/* IFLA_BRPORT_BRIDGE_ID */ | ||||||
|  		+ nla_total_size(sizeof(u16))	/* IFLA_BRPORT_DESIGNATED_PORT */ |  		+ nla_total_size(sizeof(u16))	/* IFLA_BRPORT_DESIGNATED_PORT */ | ||||||
| @@ -220,7 +221,8 @@ static int br_port_fill_attrs(struct sk_ | @@ -269,7 +270,8 @@ static int br_port_fill_attrs(struct sk_ | ||||||
|  							  BR_MRP_LOST_CONT)) || |  							  BR_MRP_LOST_CONT)) || | ||||||
|  	    nla_put_u8(skb, IFLA_BRPORT_MRP_IN_OPEN, |  	    nla_put_u8(skb, IFLA_BRPORT_MRP_IN_OPEN, | ||||||
|  		       !!(p->flags & BR_MRP_LOST_IN_CONT)) || |  		       !!(p->flags & BR_MRP_LOST_IN_CONT)) || | ||||||
| @@ -134,7 +134,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|  		return -EMSGSIZE; |  		return -EMSGSIZE; | ||||||
|   |   | ||||||
|  	timerval = br_timer_value(&p->message_age_timer); |  	timerval = br_timer_value(&p->message_age_timer); | ||||||
| @@ -728,6 +730,7 @@ static const struct nla_policy br_port_p | @@ -829,6 +831,7 @@ static const struct nla_policy br_port_p | ||||||
|  	[IFLA_BRPORT_ISOLATED]	= { .type = NLA_U8 }, |  	[IFLA_BRPORT_ISOLATED]	= { .type = NLA_U8 }, | ||||||
|  	[IFLA_BRPORT_BACKUP_PORT] = { .type = NLA_U32 }, |  	[IFLA_BRPORT_BACKUP_PORT] = { .type = NLA_U32 }, | ||||||
|  	[IFLA_BRPORT_MCAST_EHT_HOSTS_LIMIT] = { .type = NLA_U32 }, |  	[IFLA_BRPORT_MCAST_EHT_HOSTS_LIMIT] = { .type = NLA_U32 }, | ||||||
| @@ -142,7 +142,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|  }; |  }; | ||||||
|   |   | ||||||
|  /* Change the state of the port and notify spanning tree */ |  /* Change the state of the port and notify spanning tree */ | ||||||
| @@ -826,6 +829,7 @@ static int br_setport(struct net_bridge_ | @@ -893,6 +896,7 @@ static int br_setport(struct net_bridge_ | ||||||
|  	br_set_port_flag(p, tb, IFLA_BRPORT_VLAN_TUNNEL, BR_VLAN_TUNNEL); |  	br_set_port_flag(p, tb, IFLA_BRPORT_VLAN_TUNNEL, BR_VLAN_TUNNEL); | ||||||
|  	br_set_port_flag(p, tb, IFLA_BRPORT_NEIGH_SUPPRESS, BR_NEIGH_SUPPRESS); |  	br_set_port_flag(p, tb, IFLA_BRPORT_NEIGH_SUPPRESS, BR_NEIGH_SUPPRESS); | ||||||
|  	br_set_port_flag(p, tb, IFLA_BRPORT_ISOLATED, BR_ISOLATED); |  	br_set_port_flag(p, tb, IFLA_BRPORT_ISOLATED, BR_ISOLATED); | ||||||
| @@ -161,7 +161,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|   |   | ||||||
|  struct rtnl_link { |  struct rtnl_link { | ||||||
|  	rtnl_doit_func		doit; |  	rtnl_doit_func		doit; | ||||||
| @@ -4684,7 +4684,9 @@ int ndo_dflt_bridge_getlink(struct sk_bu | @@ -4689,7 +4689,9 @@ int ndo_dflt_bridge_getlink(struct sk_bu | ||||||
|  	    brport_nla_put_flag(skb, flags, mask, |  	    brport_nla_put_flag(skb, flags, mask, | ||||||
|  				IFLA_BRPORT_MCAST_FLOOD, BR_MCAST_FLOOD) || |  				IFLA_BRPORT_MCAST_FLOOD, BR_MCAST_FLOOD) || | ||||||
|  	    brport_nla_put_flag(skb, flags, mask, |  	    brport_nla_put_flag(skb, flags, mask, | ||||||
|   | |||||||
| @@ -17,11 +17,11 @@ Signed-off-by: DENG Qingfang <dqfext@gmail.com> | |||||||
|  |  | ||||||
| --- a/drivers/net/dsa/mv88e6xxx/chip.c | --- a/drivers/net/dsa/mv88e6xxx/chip.c | ||||||
| +++ b/drivers/net/dsa/mv88e6xxx/chip.c | +++ b/drivers/net/dsa/mv88e6xxx/chip.c | ||||||
| @@ -2869,6 +2869,7 @@ static int mv88e6xxx_setup(struct dsa_sw | @@ -3193,6 +3193,7 @@ static int mv88e6xxx_setup(struct dsa_sw | ||||||
|   |   | ||||||
|  	chip->ds = ds; |  	chip->ds = ds; | ||||||
|  	ds->slave_mii_bus = mv88e6xxx_default_mdio_bus(chip); |  	ds->slave_mii_bus = mv88e6xxx_default_mdio_bus(chip); | ||||||
| +	ds->configure_vlan_while_not_filtering = true; | +	ds->configure_vlan_while_not_filtering = true; | ||||||
|   |   | ||||||
|  	mv88e6xxx_reg_lock(chip); |  	/* Since virtual bridges are mapped in the PVT, the number we support | ||||||
|   |  	 * depends on the physical switch topology. We need to let DSA figure | ||||||
|   | |||||||
| @@ -17,11 +17,11 @@ Signed-off-by: Tobias Waldekranz <tobias@waldekranz.com> | |||||||
|  |  | ||||||
| --- a/drivers/net/dsa/mv88e6xxx/chip.c | --- a/drivers/net/dsa/mv88e6xxx/chip.c | ||||||
| +++ b/drivers/net/dsa/mv88e6xxx/chip.c | +++ b/drivers/net/dsa/mv88e6xxx/chip.c | ||||||
| @@ -5436,6 +5436,7 @@ static int mv88e6xxx_register_switch(str | @@ -6319,6 +6319,7 @@ static int mv88e6xxx_register_switch(str | ||||||
|  	ds->ops = &mv88e6xxx_switch_ops; |  	ds->ops = &mv88e6xxx_switch_ops; | ||||||
|  	ds->ageing_time_min = chip->info->age_time_coeff; |  	ds->ageing_time_min = chip->info->age_time_coeff; | ||||||
|  	ds->ageing_time_max = chip->info->age_time_coeff * U8_MAX; |  	ds->ageing_time_max = chip->info->age_time_coeff * U8_MAX; | ||||||
| +	ds->assisted_learning_on_cpu_port = true; | +	ds->assisted_learning_on_cpu_port = true; | ||||||
|   |   | ||||||
|  	dev_set_drvdata(dev, ds); |  	/* Some chips support up to 32, but that requires enabling the | ||||||
|   |  	 * 5-bit port mode, which we do not support. 640k^W16 ought to | ||||||
|   | |||||||
| @@ -70,9 +70,9 @@ v1 -> v2: | |||||||
|  |  | ||||||
| --- a/drivers/gpio/Kconfig | --- a/drivers/gpio/Kconfig | ||||||
| +++ b/drivers/gpio/Kconfig | +++ b/drivers/gpio/Kconfig | ||||||
| @@ -1617,4 +1617,19 @@ config GPIO_MOCKUP | @@ -1683,4 +1683,19 @@ config GPIO_VIRTIO | ||||||
|  	  tools/testing/selftests/gpio/gpio-mockup.sh. Reference the usage in |   | ||||||
|  	  it. |  endmenu | ||||||
|   |   | ||||||
| +comment "Other GPIO expanders" | +comment "Other GPIO expanders" | ||||||
| + | + | ||||||
| @@ -92,7 +92,7 @@ v1 -> v2: | |||||||
|  endif |  endif | ||||||
| --- a/drivers/gpio/Makefile | --- a/drivers/gpio/Makefile | ||||||
| +++ b/drivers/gpio/Makefile | +++ b/drivers/gpio/Makefile | ||||||
| @@ -44,6 +44,7 @@ obj-$(CONFIG_GPIO_BD9571MWV)		+= gpio-bd | @@ -45,6 +45,7 @@ obj-$(CONFIG_GPIO_BD9571MWV)		+= gpio-bd | ||||||
|  obj-$(CONFIG_GPIO_BRCMSTB)		+= gpio-brcmstb.o |  obj-$(CONFIG_GPIO_BRCMSTB)		+= gpio-brcmstb.o | ||||||
|  obj-$(CONFIG_GPIO_BT8XX)		+= gpio-bt8xx.o |  obj-$(CONFIG_GPIO_BT8XX)		+= gpio-bt8xx.o | ||||||
|  obj-$(CONFIG_GPIO_CADENCE)		+= gpio-cadence.o |  obj-$(CONFIG_GPIO_CADENCE)		+= gpio-cadence.o | ||||||
|   | |||||||
| @@ -31,9 +31,9 @@ Signed-off-by: Gabor Juhos <juhosg@openwrt.org> | |||||||
|   |   | ||||||
| +#ifndef CONFIG_PCI_DISABLE_COMMON_QUIRKS | +#ifndef CONFIG_PCI_DISABLE_COMMON_QUIRKS | ||||||
|  /* |  /* | ||||||
|   * The Mellanox Tavor device gives false positive parity errors.  Mark this |   * The Mellanox Tavor device gives false positive parity errors.  Disable | ||||||
|   * device with a broken_parity_status to allow PCI scanning code to "skip" |   * parity error reporting. | ||||||
| @@ -3322,6 +3323,8 @@ DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_I | @@ -3351,6 +3352,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, 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, 0x65fa, quirk_intel_mc_errata); | ||||||
|   |   | ||||||
| @@ -42,7 +42,7 @@ Signed-off-by: Gabor Juhos <juhosg@openwrt.org> | |||||||
|  /* |  /* | ||||||
|   * Ivytown NTB BAR sizes are misreported by the hardware due to an erratum. |   * 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 |   * To work around this, query the size it should be configured to by the | ||||||
| @@ -3347,6 +3350,8 @@ static void quirk_intel_ntb(struct pci_d | @@ -3376,6 +3379,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, 0x0e08, quirk_intel_ntb); | ||||||
|  DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_INTEL, 0x0e0d, quirk_intel_ntb); |  DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_INTEL, 0x0e0d, quirk_intel_ntb); | ||||||
|   |   | ||||||
| @@ -51,7 +51,7 @@ Signed-off-by: Gabor Juhos <juhosg@openwrt.org> | |||||||
|  /* |  /* | ||||||
|   * Some BIOS implementations leave the Intel GPU interrupts enabled, even |   * Some BIOS implementations leave the Intel GPU interrupts enabled, even | ||||||
|   * though no one is handling them (e.g., if the i915 driver is never |   * though no one is handling them (e.g., if the i915 driver is never | ||||||
| @@ -3385,6 +3390,8 @@ DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_IN | @@ -3414,6 +3419,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, 0x010a, disable_igfx_irq); | ||||||
|  DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_INTEL, 0x0152, disable_igfx_irq); |  DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_INTEL, 0x0152, disable_igfx_irq); | ||||||
|   |   | ||||||
|   | |||||||
| @@ -98,7 +98,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> | |||||||
|  #endif  /*  __LINUX_USB_PCI_QUIRKS_H  */ |  #endif  /*  __LINUX_USB_PCI_QUIRKS_H  */ | ||||||
| --- a/include/linux/usb/hcd.h | --- a/include/linux/usb/hcd.h | ||||||
| +++ b/include/linux/usb/hcd.h | +++ b/include/linux/usb/hcd.h | ||||||
| @@ -484,7 +484,14 @@ extern int usb_hcd_pci_probe(struct pci_ | @@ -495,7 +495,14 @@ extern int usb_hcd_pci_probe(struct pci_ | ||||||
|  extern void usb_hcd_pci_remove(struct pci_dev *dev); |  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_shutdown(struct pci_dev *dev); | ||||||
|   |   | ||||||
|   | |||||||
| @@ -45,7 +45,7 @@ Signed-off-by: Daniel Golle <daniel@makrotopia.org> | |||||||
|  	depends on ACPI |  	depends on ACPI | ||||||
| --- a/drivers/ata/libata-core.c | --- a/drivers/ata/libata-core.c | ||||||
| +++ b/drivers/ata/libata-core.c | +++ b/drivers/ata/libata-core.c | ||||||
| @@ -650,6 +650,19 @@ u64 ata_tf_read_block(const struct ata_t | @@ -656,6 +656,19 @@ u64 ata_tf_read_block(const struct ata_t | ||||||
|  	return block; |  	return block; | ||||||
|  } |  } | ||||||
|   |   | ||||||
| @@ -65,7 +65,7 @@ Signed-off-by: Daniel Golle <daniel@makrotopia.org> | |||||||
|  /** |  /** | ||||||
|   *	ata_build_rw_tf - Build ATA taskfile for given read/write request |   *	ata_build_rw_tf - Build ATA taskfile for given read/write request | ||||||
|   *	@tf: Target ATA taskfile |   *	@tf: Target ATA taskfile | ||||||
| @@ -4548,6 +4561,9 @@ struct ata_queued_cmd *ata_qc_new_init(s | @@ -4573,6 +4586,9 @@ struct ata_queued_cmd *ata_qc_new_init(s | ||||||
|  		if (tag < 0) |  		if (tag < 0) | ||||||
|  			return NULL; |  			return NULL; | ||||||
|  	} |  	} | ||||||
| @@ -75,7 +75,7 @@ Signed-off-by: Daniel Golle <daniel@makrotopia.org> | |||||||
|   |   | ||||||
|  	qc = __ata_qc_from_tag(ap, tag); |  	qc = __ata_qc_from_tag(ap, tag); | ||||||
|  	qc->tag = qc->hw_tag = tag; |  	qc->tag = qc->hw_tag = tag; | ||||||
| @@ -5326,6 +5342,9 @@ struct ata_port *ata_port_alloc(struct a | @@ -5351,6 +5367,9 @@ struct ata_port *ata_port_alloc(struct a | ||||||
|  	ap->stats.unhandled_irq = 1; |  	ap->stats.unhandled_irq = 1; | ||||||
|  	ap->stats.idle_irq = 1; |  	ap->stats.idle_irq = 1; | ||||||
|  #endif |  #endif | ||||||
| @@ -85,7 +85,7 @@ Signed-off-by: Daniel Golle <daniel@makrotopia.org> | |||||||
|  	ata_sff_port_init(ap); |  	ata_sff_port_init(ap); | ||||||
|   |   | ||||||
|  	return ap; |  	return ap; | ||||||
| @@ -5361,6 +5380,12 @@ static void ata_host_release(struct kref | @@ -5386,6 +5405,12 @@ static void ata_host_release(struct kref | ||||||
|   |   | ||||||
|  		kfree(ap->pmp_link); |  		kfree(ap->pmp_link); | ||||||
|  		kfree(ap->slave_link); |  		kfree(ap->slave_link); | ||||||
| @@ -98,7 +98,7 @@ Signed-off-by: Daniel Golle <daniel@makrotopia.org> | |||||||
|  		kfree(ap); |  		kfree(ap); | ||||||
|  		host->ports[i] = NULL; |  		host->ports[i] = NULL; | ||||||
|  	} |  	} | ||||||
| @@ -5767,7 +5792,23 @@ int ata_host_register(struct ata_host *h | @@ -5792,7 +5817,23 @@ int ata_host_register(struct ata_host *h | ||||||
|  		host->ports[i]->print_id = atomic_inc_return(&ata_print_id); |  		host->ports[i]->print_id = atomic_inc_return(&ata_print_id); | ||||||
|  		host->ports[i]->local_port_no = i + 1; |  		host->ports[i]->local_port_no = i + 1; | ||||||
|  	} |  	} | ||||||
| @@ -134,7 +134,7 @@ Signed-off-by: Daniel Golle <daniel@makrotopia.org> | |||||||
|   |   | ||||||
|  /* |  /* | ||||||
|   * Define if arch has non-standard setup.  This is a _PCI_ standard |   * Define if arch has non-standard setup.  This is a _PCI_ standard | ||||||
| @@ -882,6 +885,12 @@ struct ata_port { | @@ -888,6 +891,12 @@ struct ata_port { | ||||||
|  #ifdef CONFIG_ATA_ACPI |  #ifdef CONFIG_ATA_ACPI | ||||||
|  	struct ata_acpi_gtm	__acpi_init_gtm; /* use ata_acpi_init_gtm() */ |  	struct ata_acpi_gtm	__acpi_init_gtm; /* use ata_acpi_init_gtm() */ | ||||||
|  #endif |  #endif | ||||||
|   | |||||||
| @@ -16,7 +16,7 @@ Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com> | |||||||
|  |  | ||||||
| --- a/drivers/char/hw_random/bcm2835-rng.c | --- a/drivers/char/hw_random/bcm2835-rng.c | ||||||
| +++ b/drivers/char/hw_random/bcm2835-rng.c | +++ b/drivers/char/hw_random/bcm2835-rng.c | ||||||
| @@ -163,6 +163,7 @@ static int bcm2835_rng_probe(struct plat | @@ -170,6 +170,7 @@ static int bcm2835_rng_probe(struct plat | ||||||
|  	priv->rng.init = bcm2835_rng_init; |  	priv->rng.init = bcm2835_rng_init; | ||||||
|  	priv->rng.read = bcm2835_rng_read; |  	priv->rng.read = bcm2835_rng_read; | ||||||
|  	priv->rng.cleanup = bcm2835_rng_cleanup; |  	priv->rng.cleanup = bcm2835_rng_cleanup; | ||||||
|   | |||||||
| @@ -49,7 +49,7 @@ Signed-off-by: David S. Miller <davem@davemloft.net> | |||||||
|  |  | ||||||
| --- a/drivers/net/usb/qmi_wwan.c | --- a/drivers/net/usb/qmi_wwan.c | ||||||
| +++ b/drivers/net/usb/qmi_wwan.c | +++ b/drivers/net/usb/qmi_wwan.c | ||||||
| @@ -1252,6 +1252,7 @@ static const struct usb_device_id produc | @@ -1313,6 +1313,7 @@ static const struct usb_device_id produc | ||||||
|  	{QMI_FIXED_INTF(0x19d2, 0x1426, 2)},	/* ZTE MF91 */ |  	{QMI_FIXED_INTF(0x19d2, 0x1426, 2)},	/* ZTE MF91 */ | ||||||
|  	{QMI_FIXED_INTF(0x19d2, 0x1428, 2)},	/* Telewell TW-LTE 4G v2 */ |  	{QMI_FIXED_INTF(0x19d2, 0x1428, 2)},	/* Telewell TW-LTE 4G v2 */ | ||||||
|  	{QMI_FIXED_INTF(0x19d2, 0x1432, 3)},	/* ZTE ME3620 */ |  	{QMI_FIXED_INTF(0x19d2, 0x1432, 3)},	/* ZTE ME3620 */ | ||||||
|   | |||||||
| @@ -18,7 +18,7 @@ Signed-off-by: Marek Behún <kabel@kernel.org> | |||||||
|  |  | ||||||
| --- a/drivers/pci/controller/pci-aardvark.c | --- a/drivers/pci/controller/pci-aardvark.c | ||||||
| +++ b/drivers/pci/controller/pci-aardvark.c | +++ b/drivers/pci/controller/pci-aardvark.c | ||||||
| @@ -37,10 +37,6 @@ | @@ -38,10 +38,6 @@ | ||||||
|  #define     PCIE_CORE_ERR_CAPCTL_ECRC_CHK_TX_EN			BIT(6) |  #define     PCIE_CORE_ERR_CAPCTL_ECRC_CHK_TX_EN			BIT(6) | ||||||
|  #define     PCIE_CORE_ERR_CAPCTL_ECRC_CHCK			BIT(7) |  #define     PCIE_CORE_ERR_CAPCTL_ECRC_CHCK			BIT(7) | ||||||
|  #define     PCIE_CORE_ERR_CAPCTL_ECRC_CHCK_RCV			BIT(8) |  #define     PCIE_CORE_ERR_CAPCTL_ECRC_CHCK_RCV			BIT(8) | ||||||
| @@ -29,7 +29,7 @@ Signed-off-by: Marek Behún <kabel@kernel.org> | |||||||
|  /* PIO registers base address and register offsets */ |  /* PIO registers base address and register offsets */ | ||||||
|  #define PIO_BASE_ADDR				0x4000 |  #define PIO_BASE_ADDR				0x4000 | ||||||
|  #define PIO_CTRL				(PIO_BASE_ADDR + 0x0) |  #define PIO_CTRL				(PIO_BASE_ADDR + 0x0) | ||||||
| @@ -966,7 +962,7 @@ static int advk_sw_pci_bridge_init(struc | @@ -959,7 +955,7 @@ static int advk_sw_pci_bridge_init(struc | ||||||
|  	bridge->conf.pref_mem_limit = cpu_to_le16(PCI_PREF_RANGE_TYPE_64); |  	bridge->conf.pref_mem_limit = cpu_to_le16(PCI_PREF_RANGE_TYPE_64); | ||||||
|   |   | ||||||
|  	/* Support interrupt A for MSI feature */ |  	/* Support interrupt A for MSI feature */ | ||||||
|   | |||||||
| @@ -27,7 +27,7 @@ Signed-off-by: Marek Behún <kabel@kernel.org> | |||||||
|  |  | ||||||
| --- a/drivers/pci/controller/pci-aardvark.c | --- a/drivers/pci/controller/pci-aardvark.c | ||||||
| +++ b/drivers/pci/controller/pci-aardvark.c | +++ b/drivers/pci/controller/pci-aardvark.c | ||||||
| @@ -1393,7 +1393,7 @@ static void advk_pcie_remove_irq_domain( | @@ -1386,7 +1386,7 @@ static void advk_pcie_remove_irq_domain( | ||||||
|  static void advk_pcie_handle_msi(struct advk_pcie *pcie) |  static void advk_pcie_handle_msi(struct advk_pcie *pcie) | ||||||
|  { |  { | ||||||
|  	u32 msi_val, msi_mask, msi_status, msi_idx; |  	u32 msi_val, msi_mask, msi_status, msi_idx; | ||||||
| @@ -36,7 +36,7 @@ Signed-off-by: Marek Behún <kabel@kernel.org> | |||||||
|   |   | ||||||
|  	msi_mask = advk_readl(pcie, PCIE_MSI_MASK_REG); |  	msi_mask = advk_readl(pcie, PCIE_MSI_MASK_REG); | ||||||
|  	msi_val = advk_readl(pcie, PCIE_MSI_STATUS_REG); |  	msi_val = advk_readl(pcie, PCIE_MSI_STATUS_REG); | ||||||
| @@ -1403,13 +1403,12 @@ static void advk_pcie_handle_msi(struct | @@ -1396,13 +1396,12 @@ static void advk_pcie_handle_msi(struct | ||||||
|  		if (!(BIT(msi_idx) & msi_status)) |  		if (!(BIT(msi_idx) & msi_status)) | ||||||
|  			continue; |  			continue; | ||||||
|   |   | ||||||
|   | |||||||
| @@ -32,7 +32,7 @@ Signed-off-by: Marek Behún <kabel@kernel.org> | |||||||
|  |  | ||||||
| --- a/drivers/pci/controller/pci-aardvark.c | --- a/drivers/pci/controller/pci-aardvark.c | ||||||
| +++ b/drivers/pci/controller/pci-aardvark.c | +++ b/drivers/pci/controller/pci-aardvark.c | ||||||
| @@ -1189,7 +1189,7 @@ static void advk_msi_irq_compose_msi_msg | @@ -1182,7 +1182,7 @@ static void advk_msi_irq_compose_msi_msg | ||||||
|   |   | ||||||
|  	msg->address_lo = lower_32_bits(msi_msg); |  	msg->address_lo = lower_32_bits(msi_msg); | ||||||
|  	msg->address_hi = upper_32_bits(msi_msg); |  	msg->address_hi = upper_32_bits(msi_msg); | ||||||
| @@ -41,7 +41,7 @@ Signed-off-by: Marek Behún <kabel@kernel.org> | |||||||
|  } |  } | ||||||
|   |   | ||||||
|  static int advk_msi_set_affinity(struct irq_data *irq_data, |  static int advk_msi_set_affinity(struct irq_data *irq_data, | ||||||
| @@ -1206,15 +1206,11 @@ static int advk_msi_irq_domain_alloc(str | @@ -1199,15 +1199,11 @@ static int advk_msi_irq_domain_alloc(str | ||||||
|  	int hwirq, i; |  	int hwirq, i; | ||||||
|   |   | ||||||
|  	mutex_lock(&pcie->msi_used_lock); |  	mutex_lock(&pcie->msi_used_lock); | ||||||
| @@ -61,7 +61,7 @@ Signed-off-by: Marek Behún <kabel@kernel.org> | |||||||
|   |   | ||||||
|  	for (i = 0; i < nr_irqs; i++) |  	for (i = 0; i < nr_irqs; i++) | ||||||
|  		irq_domain_set_info(domain, virq + i, hwirq + i, |  		irq_domain_set_info(domain, virq + i, hwirq + i, | ||||||
| @@ -1232,7 +1228,7 @@ static void advk_msi_irq_domain_free(str | @@ -1225,7 +1221,7 @@ static void advk_msi_irq_domain_free(str | ||||||
|  	struct advk_pcie *pcie = domain->host_data; |  	struct advk_pcie *pcie = domain->host_data; | ||||||
|   |   | ||||||
|  	mutex_lock(&pcie->msi_used_lock); |  	mutex_lock(&pcie->msi_used_lock); | ||||||
|   | |||||||
| @@ -23,7 +23,7 @@ Signed-off-by: Marek Behún <kabel@kernel.org> | |||||||
|  |  | ||||||
| --- a/drivers/pci/controller/pci-aardvark.c | --- a/drivers/pci/controller/pci-aardvark.c | ||||||
| +++ b/drivers/pci/controller/pci-aardvark.c | +++ b/drivers/pci/controller/pci-aardvark.c | ||||||
| @@ -275,6 +275,7 @@ struct advk_pcie { | @@ -268,6 +268,7 @@ struct advk_pcie { | ||||||
|  		u32 actions; |  		u32 actions; | ||||||
|  	} wins[OB_WIN_COUNT]; |  	} wins[OB_WIN_COUNT]; | ||||||
|  	u8 wins_count; |  	u8 wins_count; | ||||||
| @@ -31,7 +31,7 @@ Signed-off-by: Marek Behún <kabel@kernel.org> | |||||||
|  	struct irq_domain *irq_domain; |  	struct irq_domain *irq_domain; | ||||||
|  	struct irq_chip irq_chip; |  	struct irq_chip irq_chip; | ||||||
|  	raw_spinlock_t irq_lock; |  	raw_spinlock_t irq_lock; | ||||||
| @@ -1442,21 +1443,26 @@ static void advk_pcie_handle_int(struct | @@ -1434,21 +1435,26 @@ static void advk_pcie_handle_int(struct | ||||||
|  	} |  	} | ||||||
|  } |  } | ||||||
|   |   | ||||||
| @@ -68,7 +68,7 @@ Signed-off-by: Marek Behún <kabel@kernel.org> | |||||||
|  } |  } | ||||||
|   |   | ||||||
|  static void __maybe_unused advk_pcie_disable_phy(struct advk_pcie *pcie) |  static void __maybe_unused advk_pcie_disable_phy(struct advk_pcie *pcie) | ||||||
| @@ -1523,7 +1529,7 @@ static int advk_pcie_probe(struct platfo | @@ -1515,7 +1521,7 @@ static int advk_pcie_probe(struct platfo | ||||||
|  	struct advk_pcie *pcie; |  	struct advk_pcie *pcie; | ||||||
|  	struct pci_host_bridge *bridge; |  	struct pci_host_bridge *bridge; | ||||||
|  	struct resource_entry *entry; |  	struct resource_entry *entry; | ||||||
| @@ -77,7 +77,7 @@ Signed-off-by: Marek Behún <kabel@kernel.org> | |||||||
|   |   | ||||||
|  	bridge = devm_pci_alloc_host_bridge(dev, sizeof(struct advk_pcie)); |  	bridge = devm_pci_alloc_host_bridge(dev, sizeof(struct advk_pcie)); | ||||||
|  	if (!bridge) |  	if (!bridge) | ||||||
| @@ -1611,17 +1617,9 @@ static int advk_pcie_probe(struct platfo | @@ -1601,17 +1607,9 @@ static int advk_pcie_probe(struct platfo | ||||||
|  	if (IS_ERR(pcie->base)) |  	if (IS_ERR(pcie->base)) | ||||||
|  		return PTR_ERR(pcie->base); |  		return PTR_ERR(pcie->base); | ||||||
|   |   | ||||||
| @@ -98,7 +98,7 @@ Signed-off-by: Marek Behún <kabel@kernel.org> | |||||||
|   |   | ||||||
|  	pcie->reset_gpio = devm_gpiod_get_from_of_node(dev, dev->of_node, |  	pcie->reset_gpio = devm_gpiod_get_from_of_node(dev, dev->of_node, | ||||||
|  						       "reset-gpios", 0, |  						       "reset-gpios", 0, | ||||||
| @@ -1670,11 +1668,14 @@ static int advk_pcie_probe(struct platfo | @@ -1660,11 +1658,14 @@ static int advk_pcie_probe(struct platfo | ||||||
|  		return ret; |  		return ret; | ||||||
|  	} |  	} | ||||||
|   |   | ||||||
| @@ -113,7 +113,7 @@ Signed-off-by: Marek Behún <kabel@kernel.org> | |||||||
|  		advk_pcie_remove_msi_irq_domain(pcie); |  		advk_pcie_remove_msi_irq_domain(pcie); | ||||||
|  		advk_pcie_remove_irq_domain(pcie); |  		advk_pcie_remove_irq_domain(pcie); | ||||||
|  		return ret; |  		return ret; | ||||||
| @@ -1722,6 +1723,9 @@ static int advk_pcie_remove(struct platf | @@ -1712,6 +1713,9 @@ static int advk_pcie_remove(struct platf | ||||||
|  	advk_writel(pcie, PCIE_ISR1_ALL_MASK, PCIE_ISR1_REG); |  	advk_writel(pcie, PCIE_ISR1_ALL_MASK, PCIE_ISR1_REG); | ||||||
|  	advk_writel(pcie, PCIE_IRQ_ALL_MASK, HOST_CTRL_INT_STATUS_REG); |  	advk_writel(pcie, PCIE_IRQ_ALL_MASK, HOST_CTRL_INT_STATUS_REG); | ||||||
|   |   | ||||||
|   | |||||||
| @@ -18,7 +18,7 @@ Signed-off-by: Marek Behún <kabel@kernel.org> | |||||||
|  |  | ||||||
| --- a/drivers/pci/controller/pci-aardvark.c | --- a/drivers/pci/controller/pci-aardvark.c | ||||||
| +++ b/drivers/pci/controller/pci-aardvark.c | +++ b/drivers/pci/controller/pci-aardvark.c | ||||||
| @@ -1439,7 +1439,9 @@ static void advk_pcie_handle_int(struct | @@ -1431,7 +1431,9 @@ static void advk_pcie_handle_int(struct | ||||||
|  		advk_writel(pcie, PCIE_ISR1_INTX_ASSERT(i), |  		advk_writel(pcie, PCIE_ISR1_INTX_ASSERT(i), | ||||||
|  			    PCIE_ISR1_REG); |  			    PCIE_ISR1_REG); | ||||||
|   |   | ||||||
|   | |||||||
| @@ -25,7 +25,7 @@ Signed-off-by: Marek Behún <kabel@kernel.org> | |||||||
|  |  | ||||||
| --- a/drivers/pci/controller/pci-aardvark.c | --- a/drivers/pci/controller/pci-aardvark.c | ||||||
| +++ b/drivers/pci/controller/pci-aardvark.c | +++ b/drivers/pci/controller/pci-aardvark.c | ||||||
| @@ -281,8 +281,6 @@ struct advk_pcie { | @@ -274,8 +274,6 @@ struct advk_pcie { | ||||||
|  	raw_spinlock_t irq_lock; |  	raw_spinlock_t irq_lock; | ||||||
|  	struct irq_domain *msi_domain; |  	struct irq_domain *msi_domain; | ||||||
|  	struct irq_domain *msi_inner_domain; |  	struct irq_domain *msi_inner_domain; | ||||||
| @@ -34,7 +34,7 @@ Signed-off-by: Marek Behún <kabel@kernel.org> | |||||||
|  	struct msi_domain_info msi_domain_info; |  	struct msi_domain_info msi_domain_info; | ||||||
|  	DECLARE_BITMAP(msi_used, MSI_IRQ_NUM); |  	DECLARE_BITMAP(msi_used, MSI_IRQ_NUM); | ||||||
|  	struct mutex msi_used_lock; |  	struct mutex msi_used_lock; | ||||||
| @@ -1199,6 +1197,12 @@ static int advk_msi_set_affinity(struct | @@ -1192,6 +1190,12 @@ static int advk_msi_set_affinity(struct | ||||||
|  	return -EINVAL; |  	return -EINVAL; | ||||||
|  } |  } | ||||||
|   |   | ||||||
| @@ -47,7 +47,7 @@ Signed-off-by: Marek Behún <kabel@kernel.org> | |||||||
|  static int advk_msi_irq_domain_alloc(struct irq_domain *domain, |  static int advk_msi_irq_domain_alloc(struct irq_domain *domain, | ||||||
|  				     unsigned int virq, |  				     unsigned int virq, | ||||||
|  				     unsigned int nr_irqs, void *args) |  				     unsigned int nr_irqs, void *args) | ||||||
| @@ -1215,7 +1219,7 @@ static int advk_msi_irq_domain_alloc(str | @@ -1208,7 +1212,7 @@ static int advk_msi_irq_domain_alloc(str | ||||||
|   |   | ||||||
|  	for (i = 0; i < nr_irqs; i++) |  	for (i = 0; i < nr_irqs; i++) | ||||||
|  		irq_domain_set_info(domain, virq + i, hwirq + i, |  		irq_domain_set_info(domain, virq + i, hwirq + i, | ||||||
| @@ -56,7 +56,7 @@ Signed-off-by: Marek Behún <kabel@kernel.org> | |||||||
|  				    domain->host_data, handle_simple_irq, |  				    domain->host_data, handle_simple_irq, | ||||||
|  				    NULL, NULL); |  				    NULL, NULL); | ||||||
|   |   | ||||||
| @@ -1285,29 +1289,23 @@ static const struct irq_domain_ops advk_ | @@ -1278,29 +1282,23 @@ static const struct irq_domain_ops advk_ | ||||||
|  	.xlate = irq_domain_xlate_onecell, |  	.xlate = irq_domain_xlate_onecell, | ||||||
|  }; |  }; | ||||||
|   |   | ||||||
|   | |||||||
| @@ -17,7 +17,7 @@ Signed-off-by: Marek Behún <kabel@kernel.org> | |||||||
|  |  | ||||||
| --- a/drivers/pci/controller/pci-aardvark.c | --- a/drivers/pci/controller/pci-aardvark.c | ||||||
| +++ b/drivers/pci/controller/pci-aardvark.c | +++ b/drivers/pci/controller/pci-aardvark.c | ||||||
| @@ -281,7 +281,6 @@ struct advk_pcie { | @@ -274,7 +274,6 @@ struct advk_pcie { | ||||||
|  	raw_spinlock_t irq_lock; |  	raw_spinlock_t irq_lock; | ||||||
|  	struct irq_domain *msi_domain; |  	struct irq_domain *msi_domain; | ||||||
|  	struct irq_domain *msi_inner_domain; |  	struct irq_domain *msi_inner_domain; | ||||||
| @@ -25,7 +25,7 @@ Signed-off-by: Marek Behún <kabel@kernel.org> | |||||||
|  	DECLARE_BITMAP(msi_used, MSI_IRQ_NUM); |  	DECLARE_BITMAP(msi_used, MSI_IRQ_NUM); | ||||||
|  	struct mutex msi_used_lock; |  	struct mutex msi_used_lock; | ||||||
|  	u16 msi_msg; |  	u16 msi_msg; | ||||||
| @@ -1293,20 +1292,20 @@ static struct irq_chip advk_msi_irq_chip | @@ -1286,20 +1285,20 @@ static struct irq_chip advk_msi_irq_chip | ||||||
|  	.name = "advk-MSI", |  	.name = "advk-MSI", | ||||||
|  }; |  }; | ||||||
|   |   | ||||||
| @@ -52,7 +52,7 @@ Signed-off-by: Marek Behún <kabel@kernel.org> | |||||||
|  	msi_msg_phys = virt_to_phys(&pcie->msi_msg); |  	msi_msg_phys = virt_to_phys(&pcie->msi_msg); | ||||||
|   |   | ||||||
|  	advk_writel(pcie, lower_32_bits(msi_msg_phys), |  	advk_writel(pcie, lower_32_bits(msi_msg_phys), | ||||||
| @@ -1322,7 +1321,8 @@ static int advk_pcie_init_msi_irq_domain | @@ -1315,7 +1314,8 @@ static int advk_pcie_init_msi_irq_domain | ||||||
|   |   | ||||||
|  	pcie->msi_domain = |  	pcie->msi_domain = | ||||||
|  		pci_msi_create_irq_domain(of_node_to_fwnode(node), |  		pci_msi_create_irq_domain(of_node_to_fwnode(node), | ||||||
|   | |||||||
| @@ -21,7 +21,7 @@ Signed-off-by: Marek Behún <kabel@kernel.org> | |||||||
|  |  | ||||||
| --- a/drivers/pci/controller/pci-aardvark.c | --- a/drivers/pci/controller/pci-aardvark.c | ||||||
| +++ b/drivers/pci/controller/pci-aardvark.c | +++ b/drivers/pci/controller/pci-aardvark.c | ||||||
| @@ -1301,7 +1301,6 @@ static struct msi_domain_info advk_msi_d | @@ -1294,7 +1294,6 @@ static struct msi_domain_info advk_msi_d | ||||||
|  static int advk_pcie_init_msi_irq_domain(struct advk_pcie *pcie) |  static int advk_pcie_init_msi_irq_domain(struct advk_pcie *pcie) | ||||||
|  { |  { | ||||||
|  	struct device *dev = &pcie->pdev->dev; |  	struct device *dev = &pcie->pdev->dev; | ||||||
| @@ -29,7 +29,7 @@ Signed-off-by: Marek Behún <kabel@kernel.org> | |||||||
|  	phys_addr_t msi_msg_phys; |  	phys_addr_t msi_msg_phys; | ||||||
|   |   | ||||||
|  	mutex_init(&pcie->msi_used_lock); |  	mutex_init(&pcie->msi_used_lock); | ||||||
| @@ -1320,7 +1319,7 @@ static int advk_pcie_init_msi_irq_domain | @@ -1313,7 +1312,7 @@ static int advk_pcie_init_msi_irq_domain | ||||||
|  		return -ENOMEM; |  		return -ENOMEM; | ||||||
|   |   | ||||||
|  	pcie->msi_domain = |  	pcie->msi_domain = | ||||||
|   | |||||||
| @@ -20,7 +20,7 @@ Signed-off-by: Marek Behún <kabel@kernel.org> | |||||||
|  |  | ||||||
| --- a/drivers/pci/controller/pci-aardvark.c | --- a/drivers/pci/controller/pci-aardvark.c | ||||||
| +++ b/drivers/pci/controller/pci-aardvark.c | +++ b/drivers/pci/controller/pci-aardvark.c | ||||||
| @@ -578,15 +578,17 @@ static void advk_pcie_setup_hw(struct ad | @@ -571,15 +571,17 @@ static void advk_pcie_setup_hw(struct ad | ||||||
|  	advk_writel(pcie, PCIE_IRQ_ALL_MASK, HOST_CTRL_INT_STATUS_REG); |  	advk_writel(pcie, PCIE_IRQ_ALL_MASK, HOST_CTRL_INT_STATUS_REG); | ||||||
|   |   | ||||||
|  	/* Disable All ISR0/1 Sources */ |  	/* Disable All ISR0/1 Sources */ | ||||||
|   | |||||||
| @@ -20,7 +20,7 @@ Signed-off-by: Marek Behún <kabel@kernel.org> | |||||||
|  |  | ||||||
| --- a/drivers/pci/controller/pci-aardvark.c | --- a/drivers/pci/controller/pci-aardvark.c | ||||||
| +++ b/drivers/pci/controller/pci-aardvark.c | +++ b/drivers/pci/controller/pci-aardvark.c | ||||||
| @@ -281,6 +281,7 @@ struct advk_pcie { | @@ -274,6 +274,7 @@ struct advk_pcie { | ||||||
|  	raw_spinlock_t irq_lock; |  	raw_spinlock_t irq_lock; | ||||||
|  	struct irq_domain *msi_domain; |  	struct irq_domain *msi_domain; | ||||||
|  	struct irq_domain *msi_inner_domain; |  	struct irq_domain *msi_inner_domain; | ||||||
| @@ -28,7 +28,7 @@ Signed-off-by: Marek Behún <kabel@kernel.org> | |||||||
|  	DECLARE_BITMAP(msi_used, MSI_IRQ_NUM); |  	DECLARE_BITMAP(msi_used, MSI_IRQ_NUM); | ||||||
|  	struct mutex msi_used_lock; |  	struct mutex msi_used_lock; | ||||||
|  	u16 msi_msg; |  	u16 msi_msg; | ||||||
| @@ -577,12 +578,10 @@ static void advk_pcie_setup_hw(struct ad | @@ -570,12 +571,10 @@ static void advk_pcie_setup_hw(struct ad | ||||||
|  	advk_writel(pcie, PCIE_ISR1_ALL_MASK, PCIE_ISR1_REG); |  	advk_writel(pcie, PCIE_ISR1_ALL_MASK, PCIE_ISR1_REG); | ||||||
|  	advk_writel(pcie, PCIE_IRQ_ALL_MASK, HOST_CTRL_INT_STATUS_REG); |  	advk_writel(pcie, PCIE_IRQ_ALL_MASK, HOST_CTRL_INT_STATUS_REG); | ||||||
|   |   | ||||||
| @@ -43,7 +43,7 @@ Signed-off-by: Marek Behún <kabel@kernel.org> | |||||||
|   |   | ||||||
|  	/* Unmask summary MSI interrupt */ |  	/* Unmask summary MSI interrupt */ | ||||||
|  	reg = advk_readl(pcie, PCIE_ISR0_MASK_REG); |  	reg = advk_readl(pcie, PCIE_ISR0_MASK_REG); | ||||||
| @@ -1198,10 +1197,52 @@ static int advk_msi_set_affinity(struct | @@ -1191,10 +1190,52 @@ static int advk_msi_set_affinity(struct | ||||||
|  	return -EINVAL; |  	return -EINVAL; | ||||||
|  } |  } | ||||||
|   |   | ||||||
| @@ -96,7 +96,7 @@ Signed-off-by: Marek Behún <kabel@kernel.org> | |||||||
|  }; |  }; | ||||||
|   |   | ||||||
|  static int advk_msi_irq_domain_alloc(struct irq_domain *domain, |  static int advk_msi_irq_domain_alloc(struct irq_domain *domain, | ||||||
| @@ -1291,7 +1332,9 @@ static const struct irq_domain_ops advk_ | @@ -1284,7 +1325,9 @@ static const struct irq_domain_ops advk_ | ||||||
|  }; |  }; | ||||||
|   |   | ||||||
|  static struct irq_chip advk_msi_irq_chip = { |  static struct irq_chip advk_msi_irq_chip = { | ||||||
| @@ -107,7 +107,7 @@ Signed-off-by: Marek Behún <kabel@kernel.org> | |||||||
|  }; |  }; | ||||||
|   |   | ||||||
|  static struct msi_domain_info advk_msi_domain_info = { |  static struct msi_domain_info advk_msi_domain_info = { | ||||||
| @@ -1305,6 +1348,7 @@ static int advk_pcie_init_msi_irq_domain | @@ -1298,6 +1341,7 @@ static int advk_pcie_init_msi_irq_domain | ||||||
|  	struct device *dev = &pcie->pdev->dev; |  	struct device *dev = &pcie->pdev->dev; | ||||||
|  	phys_addr_t msi_msg_phys; |  	phys_addr_t msi_msg_phys; | ||||||
|   |   | ||||||
|   | |||||||
| @@ -28,7 +28,7 @@ Cc: stable@vger.kernel.org # f21a8b1b6837 ("PCI: aardvark: Move to MSI handling | |||||||
|  |  | ||||||
| --- a/drivers/pci/controller/pci-aardvark.c | --- a/drivers/pci/controller/pci-aardvark.c | ||||||
| +++ b/drivers/pci/controller/pci-aardvark.c | +++ b/drivers/pci/controller/pci-aardvark.c | ||||||
| @@ -284,7 +284,6 @@ struct advk_pcie { | @@ -277,7 +277,6 @@ struct advk_pcie { | ||||||
|  	raw_spinlock_t msi_irq_lock; |  	raw_spinlock_t msi_irq_lock; | ||||||
|  	DECLARE_BITMAP(msi_used, MSI_IRQ_NUM); |  	DECLARE_BITMAP(msi_used, MSI_IRQ_NUM); | ||||||
|  	struct mutex msi_used_lock; |  	struct mutex msi_used_lock; | ||||||
| @@ -36,7 +36,7 @@ Cc: stable@vger.kernel.org # f21a8b1b6837 ("PCI: aardvark: Move to MSI handling | |||||||
|  	int link_gen; |  	int link_gen; | ||||||
|  	struct pci_bridge_emul bridge; |  	struct pci_bridge_emul bridge; | ||||||
|  	struct gpio_desc *reset_gpio; |  	struct gpio_desc *reset_gpio; | ||||||
| @@ -479,6 +478,7 @@ static void advk_pcie_disable_ob_win(str | @@ -472,6 +471,7 @@ static void advk_pcie_disable_ob_win(str | ||||||
|   |   | ||||||
|  static void advk_pcie_setup_hw(struct advk_pcie *pcie) |  static void advk_pcie_setup_hw(struct advk_pcie *pcie) | ||||||
|  { |  { | ||||||
| @@ -44,7 +44,7 @@ Cc: stable@vger.kernel.org # f21a8b1b6837 ("PCI: aardvark: Move to MSI handling | |||||||
|  	u32 reg; |  	u32 reg; | ||||||
|  	int i; |  	int i; | ||||||
|   |   | ||||||
| @@ -567,6 +567,11 @@ static void advk_pcie_setup_hw(struct ad | @@ -560,6 +560,11 @@ static void advk_pcie_setup_hw(struct ad | ||||||
|  	reg |= LANE_COUNT_1; |  	reg |= LANE_COUNT_1; | ||||||
|  	advk_writel(pcie, reg, PCIE_CORE_CTRL0_REG); |  	advk_writel(pcie, reg, PCIE_CORE_CTRL0_REG); | ||||||
|   |   | ||||||
| @@ -56,7 +56,7 @@ Cc: stable@vger.kernel.org # f21a8b1b6837 ("PCI: aardvark: Move to MSI handling | |||||||
|  	/* Enable MSI */ |  	/* Enable MSI */ | ||||||
|  	reg = advk_readl(pcie, PCIE_CORE_CTRL2_REG); |  	reg = advk_readl(pcie, PCIE_CORE_CTRL2_REG); | ||||||
|  	reg |= PCIE_CORE_CTRL2_MSI_ENABLE; |  	reg |= PCIE_CORE_CTRL2_MSI_ENABLE; | ||||||
| @@ -1184,10 +1189,10 @@ static void advk_msi_irq_compose_msi_msg | @@ -1177,10 +1182,10 @@ static void advk_msi_irq_compose_msi_msg | ||||||
|  					 struct msi_msg *msg) |  					 struct msi_msg *msg) | ||||||
|  { |  { | ||||||
|  	struct advk_pcie *pcie = irq_data_get_irq_chip_data(data); |  	struct advk_pcie *pcie = irq_data_get_irq_chip_data(data); | ||||||
| @@ -70,7 +70,7 @@ Cc: stable@vger.kernel.org # f21a8b1b6837 ("PCI: aardvark: Move to MSI handling | |||||||
|  	msg->data = data->hwirq; |  	msg->data = data->hwirq; | ||||||
|  } |  } | ||||||
|   |   | ||||||
| @@ -1346,18 +1351,10 @@ static struct msi_domain_info advk_msi_d | @@ -1339,18 +1344,10 @@ static struct msi_domain_info advk_msi_d | ||||||
|  static int advk_pcie_init_msi_irq_domain(struct advk_pcie *pcie) |  static int advk_pcie_init_msi_irq_domain(struct advk_pcie *pcie) | ||||||
|  { |  { | ||||||
|  	struct device *dev = &pcie->pdev->dev; |  	struct device *dev = &pcie->pdev->dev; | ||||||
|   | |||||||
| @@ -27,7 +27,7 @@ Signed-off-by: Marek Behún <kabel@kernel.org> | |||||||
|  |  | ||||||
| --- a/drivers/pci/controller/pci-aardvark.c | --- a/drivers/pci/controller/pci-aardvark.c | ||||||
| +++ b/drivers/pci/controller/pci-aardvark.c | +++ b/drivers/pci/controller/pci-aardvark.c | ||||||
| @@ -1344,7 +1344,7 @@ static struct irq_chip advk_msi_irq_chip | @@ -1337,7 +1337,7 @@ static struct irq_chip advk_msi_irq_chip | ||||||
|   |   | ||||||
|  static struct msi_domain_info advk_msi_domain_info = { |  static struct msi_domain_info advk_msi_domain_info = { | ||||||
|  	.flags	= MSI_FLAG_USE_DEF_DOM_OPS | MSI_FLAG_USE_DEF_CHIP_OPS | |  	.flags	= MSI_FLAG_USE_DEF_DOM_OPS | MSI_FLAG_USE_DEF_CHIP_OPS | | ||||||
|   | |||||||
| @@ -30,7 +30,7 @@ Signed-off-by: Marek Behún <kabel@kernel.org> | |||||||
|  |  | ||||||
| --- a/drivers/pci/controller/pci-aardvark.c | --- a/drivers/pci/controller/pci-aardvark.c | ||||||
| +++ b/drivers/pci/controller/pci-aardvark.c | +++ b/drivers/pci/controller/pci-aardvark.c | ||||||
| @@ -97,6 +97,10 @@ | @@ -98,6 +98,10 @@ | ||||||
|  #define PCIE_MSG_PM_PME_MASK			BIT(7) |  #define PCIE_MSG_PM_PME_MASK			BIT(7) | ||||||
|  #define PCIE_ISR0_MASK_REG			(CONTROL_BASE_ADDR + 0x44) |  #define PCIE_ISR0_MASK_REG			(CONTROL_BASE_ADDR + 0x44) | ||||||
|  #define     PCIE_ISR0_MSI_INT_PENDING		BIT(24) |  #define     PCIE_ISR0_MSI_INT_PENDING		BIT(24) | ||||||
| @@ -41,7 +41,7 @@ Signed-off-by: Marek Behún <kabel@kernel.org> | |||||||
|  #define     PCIE_ISR0_INTX_ASSERT(val)		BIT(16 + (val)) |  #define     PCIE_ISR0_INTX_ASSERT(val)		BIT(16 + (val)) | ||||||
|  #define     PCIE_ISR0_INTX_DEASSERT(val)	BIT(20 + (val)) |  #define     PCIE_ISR0_INTX_DEASSERT(val)	BIT(20 + (val)) | ||||||
|  #define     PCIE_ISR0_ALL_MASK			GENMASK(31, 0) |  #define     PCIE_ISR0_ALL_MASK			GENMASK(31, 0) | ||||||
| @@ -785,11 +789,15 @@ advk_pci_bridge_emul_base_conf_read(stru | @@ -778,11 +782,15 @@ advk_pci_bridge_emul_base_conf_read(stru | ||||||
|  	case PCI_INTERRUPT_LINE: { |  	case PCI_INTERRUPT_LINE: { | ||||||
|  		/* |  		/* | ||||||
|  		 * From the whole 32bit register we support reading from HW only |  		 * From the whole 32bit register we support reading from HW only | ||||||
| @@ -58,7 +58,7 @@ Signed-off-by: Marek Behún <kabel@kernel.org> | |||||||
|  		if (advk_readl(pcie, PCIE_CORE_CTRL1_REG) & HOT_RESET_GEN) |  		if (advk_readl(pcie, PCIE_CORE_CTRL1_REG) & HOT_RESET_GEN) | ||||||
|  			val |= PCI_BRIDGE_CTL_BUS_RESET << 16; |  			val |= PCI_BRIDGE_CTL_BUS_RESET << 16; | ||||||
|  		else |  		else | ||||||
| @@ -815,6 +823,19 @@ advk_pci_bridge_emul_base_conf_write(str | @@ -808,6 +816,19 @@ advk_pci_bridge_emul_base_conf_write(str | ||||||
|  		break; |  		break; | ||||||
|   |   | ||||||
|  	case PCI_INTERRUPT_LINE: |  	case PCI_INTERRUPT_LINE: | ||||||
| @@ -78,7 +78,7 @@ Signed-off-by: Marek Behún <kabel@kernel.org> | |||||||
|  		if (mask & (PCI_BRIDGE_CTL_BUS_RESET << 16)) { |  		if (mask & (PCI_BRIDGE_CTL_BUS_RESET << 16)) { | ||||||
|  			u32 val = advk_readl(pcie, PCIE_CORE_CTRL1_REG); |  			u32 val = advk_readl(pcie, PCIE_CORE_CTRL1_REG); | ||||||
|  			if (new & (PCI_BRIDGE_CTL_BUS_RESET << 16)) |  			if (new & (PCI_BRIDGE_CTL_BUS_RESET << 16)) | ||||||
| @@ -1466,6 +1487,19 @@ static void advk_pcie_handle_int(struct | @@ -1459,6 +1480,19 @@ static void advk_pcie_handle_int(struct | ||||||
|  	isr1_mask = advk_readl(pcie, PCIE_ISR1_MASK_REG); |  	isr1_mask = advk_readl(pcie, PCIE_ISR1_MASK_REG); | ||||||
|  	isr1_status = isr1_val & ((~isr1_mask) & PCIE_ISR1_ALL_MASK); |  	isr1_status = isr1_val & ((~isr1_mask) & PCIE_ISR1_ALL_MASK); | ||||||
|   |   | ||||||
|   | |||||||
| @@ -31,7 +31,7 @@ Signed-off-by: Marek Behún <kabel@kernel.org> | |||||||
|  |  | ||||||
| --- a/drivers/pci/controller/pci-aardvark.c | --- a/drivers/pci/controller/pci-aardvark.c | ||||||
| +++ b/drivers/pci/controller/pci-aardvark.c | +++ b/drivers/pci/controller/pci-aardvark.c | ||||||
| @@ -874,7 +874,9 @@ advk_pci_bridge_emul_pcie_conf_read(stru | @@ -867,7 +867,9 @@ advk_pci_bridge_emul_pcie_conf_read(stru | ||||||
|  	case PCI_EXP_RTSTA: { |  	case PCI_EXP_RTSTA: { | ||||||
|  		u32 isr0 = advk_readl(pcie, PCIE_ISR0_REG); |  		u32 isr0 = advk_readl(pcie, PCIE_ISR0_REG); | ||||||
|  		u32 msglog = advk_readl(pcie, PCIE_MSG_LOG_REG); |  		u32 msglog = advk_readl(pcie, PCIE_MSG_LOG_REG); | ||||||
|   | |||||||
| @@ -19,7 +19,7 @@ Signed-off-by: Marek Behún <kabel@kernel.org> | |||||||
|  |  | ||||||
| --- a/drivers/pci/controller/pci-aardvark.c | --- a/drivers/pci/controller/pci-aardvark.c | ||||||
| +++ b/drivers/pci/controller/pci-aardvark.c | +++ b/drivers/pci/controller/pci-aardvark.c | ||||||
| @@ -932,19 +932,21 @@ advk_pci_bridge_emul_pcie_conf_write(str | @@ -925,19 +925,21 @@ advk_pci_bridge_emul_pcie_conf_write(str | ||||||
|  			advk_pcie_wait_for_retrain(pcie); |  			advk_pcie_wait_for_retrain(pcie); | ||||||
|  		break; |  		break; | ||||||
|   |   | ||||||
|   | |||||||
| @@ -25,7 +25,7 @@ Signed-off-by: Marek Behún <kabel@kernel.org> | |||||||
|  |  | ||||||
| --- a/drivers/pci/controller/pci-aardvark.c | --- a/drivers/pci/controller/pci-aardvark.c | ||||||
| +++ b/drivers/pci/controller/pci-aardvark.c | +++ b/drivers/pci/controller/pci-aardvark.c | ||||||
| @@ -1491,6 +1491,19 @@ static void advk_pcie_handle_int(struct | @@ -1484,6 +1484,19 @@ static void advk_pcie_handle_int(struct | ||||||
|  	isr1_mask = advk_readl(pcie, PCIE_ISR1_MASK_REG); |  	isr1_mask = advk_readl(pcie, PCIE_ISR1_MASK_REG); | ||||||
|  	isr1_status = isr1_val & ((~isr1_mask) & PCIE_ISR1_ALL_MASK); |  	isr1_status = isr1_val & ((~isr1_mask) & PCIE_ISR1_ALL_MASK); | ||||||
|   |   | ||||||
|   | |||||||
| @@ -40,7 +40,7 @@ Signed-off-by: Marek Behún <kabel@kernel.org> | |||||||
|  |  | ||||||
| --- a/drivers/pci/controller/pci-aardvark.c | --- a/drivers/pci/controller/pci-aardvark.c | ||||||
| +++ b/drivers/pci/controller/pci-aardvark.c | +++ b/drivers/pci/controller/pci-aardvark.c | ||||||
| @@ -597,6 +597,11 @@ static void advk_pcie_setup_hw(struct ad | @@ -590,6 +590,11 @@ static void advk_pcie_setup_hw(struct ad | ||||||
|  	reg &= ~PCIE_ISR0_MSI_INT_PENDING; |  	reg &= ~PCIE_ISR0_MSI_INT_PENDING; | ||||||
|  	advk_writel(pcie, reg, PCIE_ISR0_MASK_REG); |  	advk_writel(pcie, reg, PCIE_ISR0_MASK_REG); | ||||||
|   |   | ||||||
| @@ -52,7 +52,7 @@ Signed-off-by: Marek Behún <kabel@kernel.org> | |||||||
|  	/* Enable summary interrupt for GIC SPI source */ |  	/* Enable summary interrupt for GIC SPI source */ | ||||||
|  	reg = PCIE_IRQ_ALL_MASK & (~PCIE_IRQ_ENABLE_INTS_MASK); |  	reg = PCIE_IRQ_ALL_MASK & (~PCIE_IRQ_ENABLE_INTS_MASK); | ||||||
|  	advk_writel(pcie, reg, HOST_CTRL_INT_MASK_REG); |  	advk_writel(pcie, reg, HOST_CTRL_INT_MASK_REG); | ||||||
| @@ -863,22 +868,11 @@ advk_pci_bridge_emul_pcie_conf_read(stru | @@ -856,22 +861,11 @@ advk_pci_bridge_emul_pcie_conf_read(stru | ||||||
|  		*value = PCI_EXP_SLTSTA_PDS << 16; |  		*value = PCI_EXP_SLTSTA_PDS << 16; | ||||||
|  		return PCI_BRIDGE_EMUL_HANDLED; |  		return PCI_BRIDGE_EMUL_HANDLED; | ||||||
|   |   | ||||||
| @@ -80,7 +80,7 @@ Signed-off-by: Marek Behún <kabel@kernel.org> | |||||||
|   |   | ||||||
|  	case PCI_EXP_LNKCAP: { |  	case PCI_EXP_LNKCAP: { | ||||||
|  		u32 val = advk_readl(pcie, PCIE_CORE_PCIEXP_CAP + reg); |  		u32 val = advk_readl(pcie, PCIE_CORE_PCIEXP_CAP + reg); | ||||||
| @@ -932,22 +926,19 @@ advk_pci_bridge_emul_pcie_conf_write(str | @@ -925,22 +919,19 @@ advk_pci_bridge_emul_pcie_conf_write(str | ||||||
|  			advk_pcie_wait_for_retrain(pcie); |  			advk_pcie_wait_for_retrain(pcie); | ||||||
|  		break; |  		break; | ||||||
|   |   | ||||||
| @@ -114,7 +114,7 @@ Signed-off-by: Marek Behún <kabel@kernel.org> | |||||||
|   |   | ||||||
|  	case PCI_EXP_DEVCTL: |  	case PCI_EXP_DEVCTL: | ||||||
|  	case PCI_EXP_DEVCTL2: |  	case PCI_EXP_DEVCTL2: | ||||||
| @@ -1452,6 +1443,34 @@ static void advk_pcie_remove_irq_domain( | @@ -1445,6 +1436,34 @@ static void advk_pcie_remove_irq_domain( | ||||||
|  	irq_domain_remove(pcie->irq_domain); |  	irq_domain_remove(pcie->irq_domain); | ||||||
|  } |  } | ||||||
|   |   | ||||||
| @@ -149,7 +149,7 @@ Signed-off-by: Marek Behún <kabel@kernel.org> | |||||||
|  static void advk_pcie_handle_msi(struct advk_pcie *pcie) |  static void advk_pcie_handle_msi(struct advk_pcie *pcie) | ||||||
|  { |  { | ||||||
|  	u32 msi_val, msi_mask, msi_status, msi_idx; |  	u32 msi_val, msi_mask, msi_status, msi_idx; | ||||||
| @@ -1491,18 +1510,9 @@ static void advk_pcie_handle_int(struct | @@ -1484,18 +1503,9 @@ static void advk_pcie_handle_int(struct | ||||||
|  	isr1_mask = advk_readl(pcie, PCIE_ISR1_MASK_REG); |  	isr1_mask = advk_readl(pcie, PCIE_ISR1_MASK_REG); | ||||||
|  	isr1_status = isr1_val & ((~isr1_mask) & PCIE_ISR1_ALL_MASK); |  	isr1_status = isr1_val & ((~isr1_mask) & PCIE_ISR1_ALL_MASK); | ||||||
|   |   | ||||||
|   | |||||||
| @@ -33,7 +33,7 @@ Signed-off-by: Marek Behún <kabel@kernel.org> | |||||||
|  |  | ||||||
| --- a/drivers/pci/controller/pci-aardvark.c | --- a/drivers/pci/controller/pci-aardvark.c | ||||||
| +++ b/drivers/pci/controller/pci-aardvark.c | +++ b/drivers/pci/controller/pci-aardvark.c | ||||||
| @@ -280,6 +280,7 @@ struct advk_pcie { | @@ -273,6 +273,7 @@ struct advk_pcie { | ||||||
|  	} wins[OB_WIN_COUNT]; |  	} wins[OB_WIN_COUNT]; | ||||||
|  	u8 wins_count; |  	u8 wins_count; | ||||||
|  	int irq; |  	int irq; | ||||||
| @@ -41,7 +41,7 @@ Signed-off-by: Marek Behún <kabel@kernel.org> | |||||||
|  	struct irq_domain *irq_domain; |  	struct irq_domain *irq_domain; | ||||||
|  	struct irq_chip irq_chip; |  	struct irq_chip irq_chip; | ||||||
|  	raw_spinlock_t irq_lock; |  	raw_spinlock_t irq_lock; | ||||||
| @@ -1443,6 +1444,44 @@ static void advk_pcie_remove_irq_domain( | @@ -1436,6 +1437,44 @@ static void advk_pcie_remove_irq_domain( | ||||||
|  	irq_domain_remove(pcie->irq_domain); |  	irq_domain_remove(pcie->irq_domain); | ||||||
|  } |  } | ||||||
|   |   | ||||||
| @@ -86,7 +86,7 @@ Signed-off-by: Marek Behún <kabel@kernel.org> | |||||||
|  static void advk_pcie_handle_pme(struct advk_pcie *pcie) |  static void advk_pcie_handle_pme(struct advk_pcie *pcie) | ||||||
|  { |  { | ||||||
|  	u32 requester = advk_readl(pcie, PCIE_MSG_LOG_REG) >> 16; |  	u32 requester = advk_readl(pcie, PCIE_MSG_LOG_REG) >> 16; | ||||||
| @@ -1465,7 +1504,7 @@ static void advk_pcie_handle_pme(struct | @@ -1458,7 +1497,7 @@ static void advk_pcie_handle_pme(struct | ||||||
|  		if (!(le16_to_cpu(pcie->bridge.pcie_conf.rootctl) & PCI_EXP_RTCTL_PMEIE)) |  		if (!(le16_to_cpu(pcie->bridge.pcie_conf.rootctl) & PCI_EXP_RTCTL_PMEIE)) | ||||||
|  			return; |  			return; | ||||||
|   |   | ||||||
| @@ -95,7 +95,7 @@ Signed-off-by: Marek Behún <kabel@kernel.org> | |||||||
|  		if (generic_handle_irq(virq) == -EINVAL) |  		if (generic_handle_irq(virq) == -EINVAL) | ||||||
|  			dev_err_ratelimited(&pcie->pdev->dev, "unhandled PME IRQ\n"); |  			dev_err_ratelimited(&pcie->pdev->dev, "unhandled PME IRQ\n"); | ||||||
|  	} |  	} | ||||||
| @@ -1522,7 +1561,7 @@ static void advk_pcie_handle_int(struct | @@ -1515,7 +1554,7 @@ static void advk_pcie_handle_int(struct | ||||||
|  		 * Aardvark HW returns zero for PCI_ERR_ROOT_AER_IRQ, so use |  		 * Aardvark HW returns zero for PCI_ERR_ROOT_AER_IRQ, so use | ||||||
|  		 * PCIe interrupt 0 |  		 * PCIe interrupt 0 | ||||||
|  		 */ |  		 */ | ||||||
| @@ -104,7 +104,7 @@ Signed-off-by: Marek Behún <kabel@kernel.org> | |||||||
|  		if (generic_handle_irq(virq) == -EINVAL) |  		if (generic_handle_irq(virq) == -EINVAL) | ||||||
|  			dev_err_ratelimited(&pcie->pdev->dev, "unhandled ERR IRQ\n"); |  			dev_err_ratelimited(&pcie->pdev->dev, "unhandled ERR IRQ\n"); | ||||||
|  	} |  	} | ||||||
| @@ -1568,6 +1607,21 @@ static void advk_pcie_irq_handler(struct | @@ -1560,6 +1599,21 @@ static void advk_pcie_irq_handler(struct | ||||||
|  	chained_irq_exit(chip, desc); |  	chained_irq_exit(chip, desc); | ||||||
|  } |  } | ||||||
|   |   | ||||||
| @@ -126,7 +126,7 @@ Signed-off-by: Marek Behún <kabel@kernel.org> | |||||||
|  static void __maybe_unused advk_pcie_disable_phy(struct advk_pcie *pcie) |  static void __maybe_unused advk_pcie_disable_phy(struct advk_pcie *pcie) | ||||||
|  { |  { | ||||||
|  	phy_power_off(pcie->phy); |  	phy_power_off(pcie->phy); | ||||||
| @@ -1771,14 +1825,24 @@ static int advk_pcie_probe(struct platfo | @@ -1761,14 +1815,24 @@ static int advk_pcie_probe(struct platfo | ||||||
|  		return ret; |  		return ret; | ||||||
|  	} |  	} | ||||||
|   |   | ||||||
| @@ -151,7 +151,7 @@ Signed-off-by: Marek Behún <kabel@kernel.org> | |||||||
|  		advk_pcie_remove_msi_irq_domain(pcie); |  		advk_pcie_remove_msi_irq_domain(pcie); | ||||||
|  		advk_pcie_remove_irq_domain(pcie); |  		advk_pcie_remove_irq_domain(pcie); | ||||||
|  		return ret; |  		return ret; | ||||||
| @@ -1830,6 +1894,7 @@ static int advk_pcie_remove(struct platf | @@ -1820,6 +1884,7 @@ static int advk_pcie_remove(struct platf | ||||||
|  	irq_set_chained_handler_and_data(pcie->irq, NULL, NULL); |  	irq_set_chained_handler_and_data(pcie->irq, NULL, NULL); | ||||||
|   |   | ||||||
|  	/* Remove IRQ domains */ |  	/* Remove IRQ domains */ | ||||||
|   | |||||||
| @@ -19,7 +19,7 @@ Signed-off-by: Marek Behún <kabel@kernel.org> | |||||||
|  |  | ||||||
| --- a/drivers/pci/controller/pci-aardvark.c | --- a/drivers/pci/controller/pci-aardvark.c | ||||||
| +++ b/drivers/pci/controller/pci-aardvark.c | +++ b/drivers/pci/controller/pci-aardvark.c | ||||||
| @@ -1422,7 +1422,6 @@ static int advk_pcie_init_irq_domain(str | @@ -1415,7 +1415,6 @@ static int advk_pcie_init_irq_domain(str | ||||||
|  	} |  	} | ||||||
|   |   | ||||||
|  	irq_chip->irq_mask = advk_pcie_irq_mask; |  	irq_chip->irq_mask = advk_pcie_irq_mask; | ||||||
|   | |||||||
| @@ -17,7 +17,7 @@ Signed-off-by: Marek Behún <kabel@kernel.org> | |||||||
|  |  | ||||||
| --- a/drivers/pci/controller/pci-aardvark.c | --- a/drivers/pci/controller/pci-aardvark.c | ||||||
| +++ b/drivers/pci/controller/pci-aardvark.c | +++ b/drivers/pci/controller/pci-aardvark.c | ||||||
| @@ -1339,7 +1339,6 @@ static int advk_pcie_irq_map(struct irq_ | @@ -1332,7 +1332,6 @@ static int advk_pcie_irq_map(struct irq_ | ||||||
|  { |  { | ||||||
|  	struct advk_pcie *pcie = h->host_data; |  	struct advk_pcie *pcie = h->host_data; | ||||||
|   |   | ||||||
|   | |||||||
| @@ -17,7 +17,7 @@ Signed-off-by: Marek Behún <kabel@kernel.org> | |||||||
|  |  | ||||||
| --- a/drivers/pci/controller/pci-aardvark.c | --- a/drivers/pci/controller/pci-aardvark.c | ||||||
| +++ b/drivers/pci/controller/pci-aardvark.c | +++ b/drivers/pci/controller/pci-aardvark.c | ||||||
| @@ -1620,7 +1620,7 @@ static int advk_pcie_map_irq(const struc | @@ -1612,7 +1612,7 @@ static int advk_pcie_map_irq(const struc | ||||||
|  		return of_irq_parse_and_map_pci(dev, slot, pin); |  		return of_irq_parse_and_map_pci(dev, slot, pin); | ||||||
|  } |  } | ||||||
|   |   | ||||||
|   | |||||||
| @@ -18,7 +18,7 @@ Signed-off-by: Marek Behún <kabel@kernel.org> | |||||||
|  |  | ||||||
| --- a/drivers/pci/controller/pci-aardvark.c | --- a/drivers/pci/controller/pci-aardvark.c | ||||||
| +++ b/drivers/pci/controller/pci-aardvark.c | +++ b/drivers/pci/controller/pci-aardvark.c | ||||||
| @@ -1005,8 +1005,12 @@ static bool advk_pcie_valid_device(struc | @@ -998,8 +998,12 @@ static bool advk_pcie_valid_device(struc | ||||||
|  		return false; |  		return false; | ||||||
|   |   | ||||||
|  	/* |  	/* | ||||||
|   | |||||||
| @@ -33,7 +33,7 @@ Signed-off-by: Marek Behún <kabel@kernel.org> | |||||||
|  |  | ||||||
| --- a/drivers/pci/controller/pci-aardvark.c | --- a/drivers/pci/controller/pci-aardvark.c | ||||||
| +++ b/drivers/pci/controller/pci-aardvark.c | +++ b/drivers/pci/controller/pci-aardvark.c | ||||||
| @@ -282,7 +282,6 @@ struct advk_pcie { | @@ -275,7 +275,6 @@ struct advk_pcie { | ||||||
|  	int irq; |  	int irq; | ||||||
|  	struct irq_domain *rp_irq_domain; |  	struct irq_domain *rp_irq_domain; | ||||||
|  	struct irq_domain *irq_domain; |  	struct irq_domain *irq_domain; | ||||||
| @@ -41,7 +41,7 @@ Signed-off-by: Marek Behún <kabel@kernel.org> | |||||||
|  	raw_spinlock_t irq_lock; |  	raw_spinlock_t irq_lock; | ||||||
|  	struct irq_domain *msi_domain; |  	struct irq_domain *msi_domain; | ||||||
|  	struct irq_domain *msi_inner_domain; |  	struct irq_domain *msi_inner_domain; | ||||||
| @@ -1338,14 +1337,19 @@ static void advk_pcie_irq_unmask(struct | @@ -1331,14 +1330,19 @@ static void advk_pcie_irq_unmask(struct | ||||||
|  	raw_spin_unlock_irqrestore(&pcie->irq_lock, flags); |  	raw_spin_unlock_irqrestore(&pcie->irq_lock, flags); | ||||||
|  } |  } | ||||||
|   |   | ||||||
| @@ -63,7 +63,7 @@ Signed-off-by: Marek Behún <kabel@kernel.org> | |||||||
|  	irq_set_chip_data(virq, pcie); |  	irq_set_chip_data(virq, pcie); | ||||||
|   |   | ||||||
|  	return 0; |  	return 0; | ||||||
| @@ -1404,7 +1408,6 @@ static int advk_pcie_init_irq_domain(str | @@ -1397,7 +1401,6 @@ static int advk_pcie_init_irq_domain(str | ||||||
|  	struct device *dev = &pcie->pdev->dev; |  	struct device *dev = &pcie->pdev->dev; | ||||||
|  	struct device_node *node = dev->of_node; |  	struct device_node *node = dev->of_node; | ||||||
|  	struct device_node *pcie_intc_node; |  	struct device_node *pcie_intc_node; | ||||||
| @@ -71,7 +71,7 @@ Signed-off-by: Marek Behún <kabel@kernel.org> | |||||||
|  	int ret = 0; |  	int ret = 0; | ||||||
|   |   | ||||||
|  	raw_spin_lock_init(&pcie->irq_lock); |  	raw_spin_lock_init(&pcie->irq_lock); | ||||||
| @@ -1415,28 +1418,14 @@ static int advk_pcie_init_irq_domain(str | @@ -1408,28 +1411,14 @@ static int advk_pcie_init_irq_domain(str | ||||||
|  		return -ENODEV; |  		return -ENODEV; | ||||||
|  	} |  	} | ||||||
|   |   | ||||||
|   | |||||||
| @@ -23,7 +23,7 @@ Acked-by: Miquel Raynal <miquel.raynal@bootlin.com> | |||||||
|  |  | ||||||
| --- a/drivers/pci/controller/pci-aardvark.c | --- a/drivers/pci/controller/pci-aardvark.c | ||||||
| +++ b/drivers/pci/controller/pci-aardvark.c | +++ b/drivers/pci/controller/pci-aardvark.c | ||||||
| @@ -1637,9 +1637,7 @@ static int advk_pcie_enable_phy(struct a | @@ -1629,9 +1629,7 @@ static int advk_pcie_enable_phy(struct a | ||||||
|  	} |  	} | ||||||
|   |   | ||||||
|  	ret = phy_power_on(pcie->phy); |  	ret = phy_power_on(pcie->phy); | ||||||
|   | |||||||
| @@ -13,7 +13,7 @@ Signed-off-by: Imre Kaloz <kaloz@openwrt.org> | |||||||
|  |  | ||||||
| --- a/init/Kconfig | --- a/init/Kconfig | ||||||
| +++ b/init/Kconfig | +++ b/init/Kconfig | ||||||
| @@ -1800,6 +1800,15 @@ config EMBEDDED | @@ -1805,6 +1805,15 @@ config EMBEDDED | ||||||
|  	  an embedded system so certain expert options are available |  	  an embedded system so certain expert options are available | ||||||
|  	  for configuration. |  	  for configuration. | ||||||
|   |   | ||||||
| @@ -31,7 +31,7 @@ Signed-off-by: Imre Kaloz <kaloz@openwrt.org> | |||||||
|  	help |  	help | ||||||
| --- a/init/main.c | --- a/init/main.c | ||||||
| +++ b/init/main.c | +++ b/init/main.c | ||||||
| @@ -608,6 +608,29 @@ static inline void setup_nr_cpu_ids(void | @@ -614,6 +614,29 @@ static inline void setup_nr_cpu_ids(void | ||||||
|  static inline void smp_prepare_cpus(unsigned int maxcpus) { } |  static inline void smp_prepare_cpus(unsigned int maxcpus) { } | ||||||
|  #endif |  #endif | ||||||
|   |   | ||||||
| @@ -61,7 +61,7 @@ Signed-off-by: Imre Kaloz <kaloz@openwrt.org> | |||||||
|  /* |  /* | ||||||
|   * We need to store the untouched command line for future reference. |   * We need to store the untouched command line for future reference. | ||||||
|   * We also need to store the touched command line since the parameter |   * We also need to store the touched command line since the parameter | ||||||
| @@ -869,6 +892,7 @@ asmlinkage __visible void __init __no_sa | @@ -954,6 +977,7 @@ asmlinkage __visible void __init __no_sa | ||||||
|  	pr_notice("%s", linux_banner); |  	pr_notice("%s", linux_banner); | ||||||
|  	early_security_init(); |  	early_security_init(); | ||||||
|  	setup_arch(&command_line); |  	setup_arch(&command_line); | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user