diff options
Diffstat (limited to 'include')
34 files changed, 193 insertions, 102 deletions
diff --git a/include/asm-generic/export.h b/include/asm-generic/export.h index 43199a049da5..63554e9f6e0c 100644 --- a/include/asm-generic/export.h +++ b/include/asm-generic/export.h | |||
@@ -70,7 +70,7 @@ KSYM(__kcrctab_\name): | |||
70 | #include <generated/autoksyms.h> | 70 | #include <generated/autoksyms.h> |
71 | 71 | ||
72 | #define __EXPORT_SYMBOL(sym, val, sec) \ | 72 | #define __EXPORT_SYMBOL(sym, val, sec) \ |
73 | __cond_export_sym(sym, val, sec, config_enabled(__KSYM_##sym)) | 73 | __cond_export_sym(sym, val, sec, __is_defined(__KSYM_##sym)) |
74 | #define __cond_export_sym(sym, val, sec, conf) \ | 74 | #define __cond_export_sym(sym, val, sec, conf) \ |
75 | ___cond_export_sym(sym, val, sec, conf) | 75 | ___cond_export_sym(sym, val, sec, conf) |
76 | #define ___cond_export_sym(sym, val, sec, enabled) \ | 76 | #define ___cond_export_sym(sym, val, sec, enabled) \ |
diff --git a/include/drm/drm_plane.h b/include/drm/drm_plane.h index 63d4e5051936..5b38eb94783b 100644 --- a/include/drm/drm_plane.h +++ b/include/drm/drm_plane.h | |||
@@ -43,8 +43,14 @@ struct drm_printer; | |||
43 | * @src_h: height of visible portion of plane (in 16.16) | 43 | * @src_h: height of visible portion of plane (in 16.16) |
44 | * @rotation: rotation of the plane | 44 | * @rotation: rotation of the plane |
45 | * @zpos: priority of the given plane on crtc (optional) | 45 | * @zpos: priority of the given plane on crtc (optional) |
46 | * Note that multiple active planes on the same crtc can have an identical | ||
47 | * zpos value. The rule to solving the conflict is to compare the plane | ||
48 | * object IDs; the plane with a higher ID must be stacked on top of a | ||
49 | * plane with a lower ID. | ||
46 | * @normalized_zpos: normalized value of zpos: unique, range from 0 to N-1 | 50 | * @normalized_zpos: normalized value of zpos: unique, range from 0 to N-1 |
47 | * where N is the number of active planes for given crtc | 51 | * where N is the number of active planes for given crtc. Note that |
52 | * the driver must call drm_atomic_normalize_zpos() to update this before | ||
53 | * it can be trusted. | ||
48 | * @src: clipped source coordinates of the plane (in 16.16) | 54 | * @src: clipped source coordinates of the plane (in 16.16) |
49 | * @dst: clipped destination coordinates of the plane | 55 | * @dst: clipped destination coordinates of the plane |
50 | * @state: backpointer to global drm_atomic_state | 56 | * @state: backpointer to global drm_atomic_state |
diff --git a/include/linux/acpi.h b/include/linux/acpi.h index ddbeda6dbdc8..689a8b9b9c8f 100644 --- a/include/linux/acpi.h +++ b/include/linux/acpi.h | |||
@@ -326,6 +326,7 @@ struct pci_dev; | |||
326 | int acpi_pci_irq_enable (struct pci_dev *dev); | 326 | int acpi_pci_irq_enable (struct pci_dev *dev); |
327 | void acpi_penalize_isa_irq(int irq, int active); | 327 | void acpi_penalize_isa_irq(int irq, int active); |
328 | bool acpi_isa_irq_available(int irq); | 328 | bool acpi_isa_irq_available(int irq); |
329 | void acpi_penalize_sci_irq(int irq, int trigger, int polarity); | ||
329 | void acpi_pci_irq_disable (struct pci_dev *dev); | 330 | void acpi_pci_irq_disable (struct pci_dev *dev); |
330 | 331 | ||
331 | extern int ec_read(u8 addr, u8 *val); | 332 | extern int ec_read(u8 addr, u8 *val); |
diff --git a/include/linux/clk-provider.h b/include/linux/clk-provider.h index af596381fa0f..a428aec36ace 100644 --- a/include/linux/clk-provider.h +++ b/include/linux/clk-provider.h | |||
@@ -785,7 +785,7 @@ extern struct of_device_id __clk_of_table; | |||
785 | * routines, one at of_clk_init(), and one at platform device probe | 785 | * routines, one at of_clk_init(), and one at platform device probe |
786 | */ | 786 | */ |
787 | #define CLK_OF_DECLARE_DRIVER(name, compat, fn) \ | 787 | #define CLK_OF_DECLARE_DRIVER(name, compat, fn) \ |
788 | static void name##_of_clk_init_driver(struct device_node *np) \ | 788 | static void __init name##_of_clk_init_driver(struct device_node *np) \ |
789 | { \ | 789 | { \ |
790 | of_node_clear_flag(np, OF_POPULATED); \ | 790 | of_node_clear_flag(np, OF_POPULATED); \ |
791 | fn(np); \ | 791 | fn(np); \ |
diff --git a/include/linux/hyperv.h b/include/linux/hyperv.h index 6824556d37ed..cd184bdca58f 100644 --- a/include/linux/hyperv.h +++ b/include/linux/hyperv.h | |||
@@ -1169,13 +1169,6 @@ int __must_check __vmbus_driver_register(struct hv_driver *hv_driver, | |||
1169 | const char *mod_name); | 1169 | const char *mod_name); |
1170 | void vmbus_driver_unregister(struct hv_driver *hv_driver); | 1170 | void vmbus_driver_unregister(struct hv_driver *hv_driver); |
1171 | 1171 | ||
1172 | static inline const char *vmbus_dev_name(const struct hv_device *device_obj) | ||
1173 | { | ||
1174 | const struct kobject *kobj = &device_obj->device.kobj; | ||
1175 | |||
1176 | return kobj->name; | ||
1177 | } | ||
1178 | |||
1179 | void vmbus_hvsock_device_unregister(struct vmbus_channel *channel); | 1172 | void vmbus_hvsock_device_unregister(struct vmbus_channel *channel); |
1180 | 1173 | ||
1181 | int vmbus_allocate_mmio(struct resource **new, struct hv_device *device_obj, | 1174 | int vmbus_allocate_mmio(struct resource **new, struct hv_device *device_obj, |
diff --git a/include/linux/io.h b/include/linux/io.h index e2c8419278c1..82ef36eac8a1 100644 --- a/include/linux/io.h +++ b/include/linux/io.h | |||
@@ -141,4 +141,26 @@ enum { | |||
141 | void *memremap(resource_size_t offset, size_t size, unsigned long flags); | 141 | void *memremap(resource_size_t offset, size_t size, unsigned long flags); |
142 | void memunmap(void *addr); | 142 | void memunmap(void *addr); |
143 | 143 | ||
144 | /* | ||
145 | * On x86 PAT systems we have memory tracking that keeps track of | ||
146 | * the allowed mappings on memory ranges. This tracking works for | ||
147 | * all the in-kernel mapping APIs (ioremap*), but where the user | ||
148 | * wishes to map a range from a physical device into user memory | ||
149 | * the tracking won't be updated. This API is to be used by | ||
150 | * drivers which remap physical device pages into userspace, | ||
151 | * and wants to make sure they are mapped WC and not UC. | ||
152 | */ | ||
153 | #ifndef arch_io_reserve_memtype_wc | ||
154 | static inline int arch_io_reserve_memtype_wc(resource_size_t base, | ||
155 | resource_size_t size) | ||
156 | { | ||
157 | return 0; | ||
158 | } | ||
159 | |||
160 | static inline void arch_io_free_memtype_wc(resource_size_t base, | ||
161 | resource_size_t size) | ||
162 | { | ||
163 | } | ||
164 | #endif | ||
165 | |||
144 | #endif /* _LINUX_IO_H */ | 166 | #endif /* _LINUX_IO_H */ |
diff --git a/include/linux/iomap.h b/include/linux/iomap.h index e63e288dee83..7892f55a1866 100644 --- a/include/linux/iomap.h +++ b/include/linux/iomap.h | |||
@@ -19,11 +19,15 @@ struct vm_fault; | |||
19 | #define IOMAP_UNWRITTEN 0x04 /* blocks allocated @blkno in unwritten state */ | 19 | #define IOMAP_UNWRITTEN 0x04 /* blocks allocated @blkno in unwritten state */ |
20 | 20 | ||
21 | /* | 21 | /* |
22 | * Flags for iomap mappings: | 22 | * Flags for all iomap mappings: |
23 | */ | 23 | */ |
24 | #define IOMAP_F_MERGED 0x01 /* contains multiple blocks/extents */ | 24 | #define IOMAP_F_NEW 0x01 /* blocks have been newly allocated */ |
25 | #define IOMAP_F_SHARED 0x02 /* block shared with another file */ | 25 | |
26 | #define IOMAP_F_NEW 0x04 /* blocks have been newly allocated */ | 26 | /* |
27 | * Flags that only need to be reported for IOMAP_REPORT requests: | ||
28 | */ | ||
29 | #define IOMAP_F_MERGED 0x10 /* contains multiple blocks/extents */ | ||
30 | #define IOMAP_F_SHARED 0x20 /* block shared with another file */ | ||
27 | 31 | ||
28 | /* | 32 | /* |
29 | * Magic value for blkno: | 33 | * Magic value for blkno: |
@@ -42,8 +46,9 @@ struct iomap { | |||
42 | /* | 46 | /* |
43 | * Flags for iomap_begin / iomap_end. No flag implies a read. | 47 | * Flags for iomap_begin / iomap_end. No flag implies a read. |
44 | */ | 48 | */ |
45 | #define IOMAP_WRITE (1 << 0) | 49 | #define IOMAP_WRITE (1 << 0) /* writing, must allocate blocks */ |
46 | #define IOMAP_ZERO (1 << 1) | 50 | #define IOMAP_ZERO (1 << 1) /* zeroing operation, may skip holes */ |
51 | #define IOMAP_REPORT (1 << 2) /* report extent status, e.g. FIEMAP */ | ||
47 | 52 | ||
48 | struct iomap_ops { | 53 | struct iomap_ops { |
49 | /* | 54 | /* |
diff --git a/include/linux/ipv6.h b/include/linux/ipv6.h index 7e9a789be5e0..ca1ad9ebbc92 100644 --- a/include/linux/ipv6.h +++ b/include/linux/ipv6.h | |||
@@ -123,12 +123,12 @@ struct inet6_skb_parm { | |||
123 | }; | 123 | }; |
124 | 124 | ||
125 | #if defined(CONFIG_NET_L3_MASTER_DEV) | 125 | #if defined(CONFIG_NET_L3_MASTER_DEV) |
126 | static inline bool skb_l3mdev_slave(__u16 flags) | 126 | static inline bool ipv6_l3mdev_skb(__u16 flags) |
127 | { | 127 | { |
128 | return flags & IP6SKB_L3SLAVE; | 128 | return flags & IP6SKB_L3SLAVE; |
129 | } | 129 | } |
130 | #else | 130 | #else |
131 | static inline bool skb_l3mdev_slave(__u16 flags) | 131 | static inline bool ipv6_l3mdev_skb(__u16 flags) |
132 | { | 132 | { |
133 | return false; | 133 | return false; |
134 | } | 134 | } |
@@ -139,11 +139,22 @@ static inline bool skb_l3mdev_slave(__u16 flags) | |||
139 | 139 | ||
140 | static inline int inet6_iif(const struct sk_buff *skb) | 140 | static inline int inet6_iif(const struct sk_buff *skb) |
141 | { | 141 | { |
142 | bool l3_slave = skb_l3mdev_slave(IP6CB(skb)->flags); | 142 | bool l3_slave = ipv6_l3mdev_skb(IP6CB(skb)->flags); |
143 | 143 | ||
144 | return l3_slave ? skb->skb_iif : IP6CB(skb)->iif; | 144 | return l3_slave ? skb->skb_iif : IP6CB(skb)->iif; |
145 | } | 145 | } |
146 | 146 | ||
147 | /* can not be used in TCP layer after tcp_v6_fill_cb */ | ||
148 | static inline bool inet6_exact_dif_match(struct net *net, struct sk_buff *skb) | ||
149 | { | ||
150 | #if defined(CONFIG_NET_L3_MASTER_DEV) | ||
151 | if (!net->ipv4.sysctl_tcp_l3mdev_accept && | ||
152 | ipv6_l3mdev_skb(IP6CB(skb)->flags)) | ||
153 | return true; | ||
154 | #endif | ||
155 | return false; | ||
156 | } | ||
157 | |||
147 | struct tcp6_request_sock { | 158 | struct tcp6_request_sock { |
148 | struct tcp_request_sock tcp6rsk_tcp; | 159 | struct tcp_request_sock tcp6rsk_tcp; |
149 | }; | 160 | }; |
diff --git a/include/linux/kconfig.h b/include/linux/kconfig.h index 15ec117ec537..8f2e059e4d45 100644 --- a/include/linux/kconfig.h +++ b/include/linux/kconfig.h | |||
@@ -31,7 +31,6 @@ | |||
31 | * When CONFIG_BOOGER is not defined, we generate a (... 1, 0) pair, and when | 31 | * When CONFIG_BOOGER is not defined, we generate a (... 1, 0) pair, and when |
32 | * the last step cherry picks the 2nd arg, we get a zero. | 32 | * the last step cherry picks the 2nd arg, we get a zero. |
33 | */ | 33 | */ |
34 | #define config_enabled(cfg) ___is_defined(cfg) | ||
35 | #define __is_defined(x) ___is_defined(x) | 34 | #define __is_defined(x) ___is_defined(x) |
36 | #define ___is_defined(val) ____is_defined(__ARG_PLACEHOLDER_##val) | 35 | #define ___is_defined(val) ____is_defined(__ARG_PLACEHOLDER_##val) |
37 | #define ____is_defined(arg1_or_junk) __take_second_arg(arg1_or_junk 1, 0) | 36 | #define ____is_defined(arg1_or_junk) __take_second_arg(arg1_or_junk 1, 0) |
@@ -41,13 +40,13 @@ | |||
41 | * otherwise. For boolean options, this is equivalent to | 40 | * otherwise. For boolean options, this is equivalent to |
42 | * IS_ENABLED(CONFIG_FOO). | 41 | * IS_ENABLED(CONFIG_FOO). |
43 | */ | 42 | */ |
44 | #define IS_BUILTIN(option) config_enabled(option) | 43 | #define IS_BUILTIN(option) __is_defined(option) |
45 | 44 | ||
46 | /* | 45 | /* |
47 | * IS_MODULE(CONFIG_FOO) evaluates to 1 if CONFIG_FOO is set to 'm', 0 | 46 | * IS_MODULE(CONFIG_FOO) evaluates to 1 if CONFIG_FOO is set to 'm', 0 |
48 | * otherwise. | 47 | * otherwise. |
49 | */ | 48 | */ |
50 | #define IS_MODULE(option) config_enabled(option##_MODULE) | 49 | #define IS_MODULE(option) __is_defined(option##_MODULE) |
51 | 50 | ||
52 | /* | 51 | /* |
53 | * IS_REACHABLE(CONFIG_FOO) evaluates to 1 if the currently compiled | 52 | * IS_REACHABLE(CONFIG_FOO) evaluates to 1 if the currently compiled |
diff --git a/include/linux/mlx4/device.h b/include/linux/mlx4/device.h index f6a164297358..3be7abd6e722 100644 --- a/include/linux/mlx4/device.h +++ b/include/linux/mlx4/device.h | |||
@@ -1399,7 +1399,8 @@ void mlx4_fmr_unmap(struct mlx4_dev *dev, struct mlx4_fmr *fmr, | |||
1399 | u32 *lkey, u32 *rkey); | 1399 | u32 *lkey, u32 *rkey); |
1400 | int mlx4_fmr_free(struct mlx4_dev *dev, struct mlx4_fmr *fmr); | 1400 | int mlx4_fmr_free(struct mlx4_dev *dev, struct mlx4_fmr *fmr); |
1401 | int mlx4_SYNC_TPT(struct mlx4_dev *dev); | 1401 | int mlx4_SYNC_TPT(struct mlx4_dev *dev); |
1402 | int mlx4_test_interrupts(struct mlx4_dev *dev); | 1402 | int mlx4_test_interrupt(struct mlx4_dev *dev, int vector); |
1403 | int mlx4_test_async(struct mlx4_dev *dev); | ||
1403 | int mlx4_query_diag_counters(struct mlx4_dev *dev, u8 op_modifier, | 1404 | int mlx4_query_diag_counters(struct mlx4_dev *dev, u8 op_modifier, |
1404 | const u32 offset[], u32 value[], | 1405 | const u32 offset[], u32 value[], |
1405 | size_t array_len, u8 port); | 1406 | size_t array_len, u8 port); |
diff --git a/include/linux/mlx5/driver.h b/include/linux/mlx5/driver.h index 85c4786427e4..ecc451d89ccd 100644 --- a/include/linux/mlx5/driver.h +++ b/include/linux/mlx5/driver.h | |||
@@ -418,8 +418,12 @@ struct mlx5_core_health { | |||
418 | u32 prev; | 418 | u32 prev; |
419 | int miss_counter; | 419 | int miss_counter; |
420 | bool sick; | 420 | bool sick; |
421 | /* wq spinlock to synchronize draining */ | ||
422 | spinlock_t wq_lock; | ||
421 | struct workqueue_struct *wq; | 423 | struct workqueue_struct *wq; |
424 | unsigned long flags; | ||
422 | struct work_struct work; | 425 | struct work_struct work; |
426 | struct delayed_work recover_work; | ||
423 | }; | 427 | }; |
424 | 428 | ||
425 | struct mlx5_cq_table { | 429 | struct mlx5_cq_table { |
@@ -626,10 +630,6 @@ struct mlx5_db { | |||
626 | }; | 630 | }; |
627 | 631 | ||
628 | enum { | 632 | enum { |
629 | MLX5_DB_PER_PAGE = PAGE_SIZE / L1_CACHE_BYTES, | ||
630 | }; | ||
631 | |||
632 | enum { | ||
633 | MLX5_COMP_EQ_SIZE = 1024, | 633 | MLX5_COMP_EQ_SIZE = 1024, |
634 | }; | 634 | }; |
635 | 635 | ||
@@ -638,13 +638,6 @@ enum { | |||
638 | MLX5_PTYS_EN = 1 << 2, | 638 | MLX5_PTYS_EN = 1 << 2, |
639 | }; | 639 | }; |
640 | 640 | ||
641 | struct mlx5_db_pgdir { | ||
642 | struct list_head list; | ||
643 | DECLARE_BITMAP(bitmap, MLX5_DB_PER_PAGE); | ||
644 | __be32 *db_page; | ||
645 | dma_addr_t db_dma; | ||
646 | }; | ||
647 | |||
648 | typedef void (*mlx5_cmd_cbk_t)(int status, void *context); | 641 | typedef void (*mlx5_cmd_cbk_t)(int status, void *context); |
649 | 642 | ||
650 | struct mlx5_cmd_work_ent { | 643 | struct mlx5_cmd_work_ent { |
@@ -789,6 +782,7 @@ void mlx5_health_cleanup(struct mlx5_core_dev *dev); | |||
789 | int mlx5_health_init(struct mlx5_core_dev *dev); | 782 | int mlx5_health_init(struct mlx5_core_dev *dev); |
790 | void mlx5_start_health_poll(struct mlx5_core_dev *dev); | 783 | void mlx5_start_health_poll(struct mlx5_core_dev *dev); |
791 | void mlx5_stop_health_poll(struct mlx5_core_dev *dev); | 784 | void mlx5_stop_health_poll(struct mlx5_core_dev *dev); |
785 | void mlx5_drain_health_wq(struct mlx5_core_dev *dev); | ||
792 | int mlx5_buf_alloc_node(struct mlx5_core_dev *dev, int size, | 786 | int mlx5_buf_alloc_node(struct mlx5_core_dev *dev, int size, |
793 | struct mlx5_buf *buf, int node); | 787 | struct mlx5_buf *buf, int node); |
794 | int mlx5_buf_alloc(struct mlx5_core_dev *dev, int size, struct mlx5_buf *buf); | 788 | int mlx5_buf_alloc(struct mlx5_core_dev *dev, int size, struct mlx5_buf *buf); |
diff --git a/include/linux/mm.h b/include/linux/mm.h index 3a191853faaa..a92c8d73aeaf 100644 --- a/include/linux/mm.h +++ b/include/linux/mm.h | |||
@@ -1271,10 +1271,6 @@ extern int access_process_vm(struct task_struct *tsk, unsigned long addr, void * | |||
1271 | extern int access_remote_vm(struct mm_struct *mm, unsigned long addr, | 1271 | extern int access_remote_vm(struct mm_struct *mm, unsigned long addr, |
1272 | void *buf, int len, unsigned int gup_flags); | 1272 | void *buf, int len, unsigned int gup_flags); |
1273 | 1273 | ||
1274 | long __get_user_pages(struct task_struct *tsk, struct mm_struct *mm, | ||
1275 | unsigned long start, unsigned long nr_pages, | ||
1276 | unsigned int foll_flags, struct page **pages, | ||
1277 | struct vm_area_struct **vmas, int *nonblocking); | ||
1278 | long get_user_pages_remote(struct task_struct *tsk, struct mm_struct *mm, | 1274 | long get_user_pages_remote(struct task_struct *tsk, struct mm_struct *mm, |
1279 | unsigned long start, unsigned long nr_pages, | 1275 | unsigned long start, unsigned long nr_pages, |
1280 | unsigned int gup_flags, struct page **pages, | 1276 | unsigned int gup_flags, struct page **pages, |
diff --git a/include/linux/mmzone.h b/include/linux/mmzone.h index 7f2ae99e5daf..0f088f3a2fed 100644 --- a/include/linux/mmzone.h +++ b/include/linux/mmzone.h | |||
@@ -440,33 +440,7 @@ struct zone { | |||
440 | seqlock_t span_seqlock; | 440 | seqlock_t span_seqlock; |
441 | #endif | 441 | #endif |
442 | 442 | ||
443 | /* | 443 | int initialized; |
444 | * wait_table -- the array holding the hash table | ||
445 | * wait_table_hash_nr_entries -- the size of the hash table array | ||
446 | * wait_table_bits -- wait_table_size == (1 << wait_table_bits) | ||
447 | * | ||
448 | * The purpose of all these is to keep track of the people | ||
449 | * waiting for a page to become available and make them | ||
450 | * runnable again when possible. The trouble is that this | ||
451 | * consumes a lot of space, especially when so few things | ||
452 | * wait on pages at a given time. So instead of using | ||
453 | * per-page waitqueues, we use a waitqueue hash table. | ||
454 | * | ||
455 | * The bucket discipline is to sleep on the same queue when | ||
456 | * colliding and wake all in that wait queue when removing. | ||
457 | * When something wakes, it must check to be sure its page is | ||
458 | * truly available, a la thundering herd. The cost of a | ||
459 | * collision is great, but given the expected load of the | ||
460 | * table, they should be so rare as to be outweighed by the | ||
461 | * benefits from the saved space. | ||
462 | * | ||
463 | * __wait_on_page_locked() and unlock_page() in mm/filemap.c, are the | ||
464 | * primary users of these fields, and in mm/page_alloc.c | ||
465 | * free_area_init_core() performs the initialization of them. | ||
466 | */ | ||
467 | wait_queue_head_t *wait_table; | ||
468 | unsigned long wait_table_hash_nr_entries; | ||
469 | unsigned long wait_table_bits; | ||
470 | 444 | ||
471 | /* Write-intensive fields used from the page allocator */ | 445 | /* Write-intensive fields used from the page allocator */ |
472 | ZONE_PADDING(_pad1_) | 446 | ZONE_PADDING(_pad1_) |
@@ -546,7 +520,7 @@ static inline bool zone_spans_pfn(const struct zone *zone, unsigned long pfn) | |||
546 | 520 | ||
547 | static inline bool zone_is_initialized(struct zone *zone) | 521 | static inline bool zone_is_initialized(struct zone *zone) |
548 | { | 522 | { |
549 | return !!zone->wait_table; | 523 | return zone->initialized; |
550 | } | 524 | } |
551 | 525 | ||
552 | static inline bool zone_is_empty(struct zone *zone) | 526 | static inline bool zone_is_empty(struct zone *zone) |
diff --git a/include/linux/mtd/nand.h b/include/linux/mtd/nand.h index c5d3d5024fc8..d8905a229f34 100644 --- a/include/linux/mtd/nand.h +++ b/include/linux/mtd/nand.h | |||
@@ -1184,7 +1184,7 @@ int nand_read_oob_syndrome(struct mtd_info *mtd, struct nand_chip *chip, | |||
1184 | int page); | 1184 | int page); |
1185 | 1185 | ||
1186 | /* Reset and initialize a NAND device */ | 1186 | /* Reset and initialize a NAND device */ |
1187 | int nand_reset(struct nand_chip *chip); | 1187 | int nand_reset(struct nand_chip *chip, int chipnr); |
1188 | 1188 | ||
1189 | /* Free resources held by the NAND device */ | 1189 | /* Free resources held by the NAND device */ |
1190 | void nand_cleanup(struct nand_chip *chip); | 1190 | void nand_cleanup(struct nand_chip *chip); |
diff --git a/include/linux/netdevice.h b/include/linux/netdevice.h index 136ae6bbe81e..91ee3643ccc8 100644 --- a/include/linux/netdevice.h +++ b/include/linux/netdevice.h | |||
@@ -2169,7 +2169,10 @@ struct napi_gro_cb { | |||
2169 | /* Used to determine if flush_id can be ignored */ | 2169 | /* Used to determine if flush_id can be ignored */ |
2170 | u8 is_atomic:1; | 2170 | u8 is_atomic:1; |
2171 | 2171 | ||
2172 | /* 5 bit hole */ | 2172 | /* Number of gro_receive callbacks this packet already went through */ |
2173 | u8 recursion_counter:4; | ||
2174 | |||
2175 | /* 1 bit hole */ | ||
2173 | 2176 | ||
2174 | /* used to support CHECKSUM_COMPLETE for tunneling protocols */ | 2177 | /* used to support CHECKSUM_COMPLETE for tunneling protocols */ |
2175 | __wsum csum; | 2178 | __wsum csum; |
@@ -2180,6 +2183,40 @@ struct napi_gro_cb { | |||
2180 | 2183 | ||
2181 | #define NAPI_GRO_CB(skb) ((struct napi_gro_cb *)(skb)->cb) | 2184 | #define NAPI_GRO_CB(skb) ((struct napi_gro_cb *)(skb)->cb) |
2182 | 2185 | ||
2186 | #define GRO_RECURSION_LIMIT 15 | ||
2187 | static inline int gro_recursion_inc_test(struct sk_buff *skb) | ||
2188 | { | ||
2189 | return ++NAPI_GRO_CB(skb)->recursion_counter == GRO_RECURSION_LIMIT; | ||
2190 | } | ||
2191 | |||
2192 | typedef struct sk_buff **(*gro_receive_t)(struct sk_buff **, struct sk_buff *); | ||
2193 | static inline struct sk_buff **call_gro_receive(gro_receive_t cb, | ||
2194 | struct sk_buff **head, | ||
2195 | struct sk_buff *skb) | ||
2196 | { | ||
2197 | if (unlikely(gro_recursion_inc_test(skb))) { | ||
2198 | NAPI_GRO_CB(skb)->flush |= 1; | ||
2199 | return NULL; | ||
2200 | } | ||
2201 | |||
2202 | return cb(head, skb); | ||
2203 | } | ||
2204 | |||
2205 | typedef struct sk_buff **(*gro_receive_sk_t)(struct sock *, struct sk_buff **, | ||
2206 | struct sk_buff *); | ||
2207 | static inline struct sk_buff **call_gro_receive_sk(gro_receive_sk_t cb, | ||
2208 | struct sock *sk, | ||
2209 | struct sk_buff **head, | ||
2210 | struct sk_buff *skb) | ||
2211 | { | ||
2212 | if (unlikely(gro_recursion_inc_test(skb))) { | ||
2213 | NAPI_GRO_CB(skb)->flush |= 1; | ||
2214 | return NULL; | ||
2215 | } | ||
2216 | |||
2217 | return cb(sk, head, skb); | ||
2218 | } | ||
2219 | |||
2183 | struct packet_type { | 2220 | struct packet_type { |
2184 | __be16 type; /* This is really htons(ether_type). */ | 2221 | __be16 type; /* This is really htons(ether_type). */ |
2185 | struct net_device *dev; /* NULL is wildcarded here */ | 2222 | struct net_device *dev; /* NULL is wildcarded here */ |
@@ -3877,7 +3914,7 @@ struct net_device *netdev_all_lower_get_next_rcu(struct net_device *dev, | |||
3877 | ldev = netdev_all_lower_get_next(dev, &(iter))) | 3914 | ldev = netdev_all_lower_get_next(dev, &(iter))) |
3878 | 3915 | ||
3879 | #define netdev_for_each_all_lower_dev_rcu(dev, ldev, iter) \ | 3916 | #define netdev_for_each_all_lower_dev_rcu(dev, ldev, iter) \ |
3880 | for (iter = (dev)->all_adj_list.lower.next, \ | 3917 | for (iter = &(dev)->all_adj_list.lower, \ |
3881 | ldev = netdev_all_lower_get_next_rcu(dev, &(iter)); \ | 3918 | ldev = netdev_all_lower_get_next_rcu(dev, &(iter)); \ |
3882 | ldev; \ | 3919 | ldev; \ |
3883 | ldev = netdev_all_lower_get_next_rcu(dev, &(iter))) | 3920 | ldev = netdev_all_lower_get_next_rcu(dev, &(iter))) |
diff --git a/include/linux/perf_event.h b/include/linux/perf_event.h index 060d0ede88df..4741ecdb9817 100644 --- a/include/linux/perf_event.h +++ b/include/linux/perf_event.h | |||
@@ -1257,6 +1257,7 @@ extern u64 perf_swevent_set_period(struct perf_event *event); | |||
1257 | extern void perf_event_enable(struct perf_event *event); | 1257 | extern void perf_event_enable(struct perf_event *event); |
1258 | extern void perf_event_disable(struct perf_event *event); | 1258 | extern void perf_event_disable(struct perf_event *event); |
1259 | extern void perf_event_disable_local(struct perf_event *event); | 1259 | extern void perf_event_disable_local(struct perf_event *event); |
1260 | extern void perf_event_disable_inatomic(struct perf_event *event); | ||
1260 | extern void perf_event_task_tick(void); | 1261 | extern void perf_event_task_tick(void); |
1261 | #else /* !CONFIG_PERF_EVENTS: */ | 1262 | #else /* !CONFIG_PERF_EVENTS: */ |
1262 | static inline void * | 1263 | static inline void * |
diff --git a/include/linux/qed/qed_if.h b/include/linux/qed/qed_if.h index f9ae903bbb84..8978a60371f4 100644 --- a/include/linux/qed/qed_if.h +++ b/include/linux/qed/qed_if.h | |||
@@ -146,6 +146,7 @@ enum qed_led_mode { | |||
146 | #define DIRECT_REG_RD(reg_addr) readl((void __iomem *)(reg_addr)) | 146 | #define DIRECT_REG_RD(reg_addr) readl((void __iomem *)(reg_addr)) |
147 | 147 | ||
148 | #define QED_COALESCE_MAX 0xFF | 148 | #define QED_COALESCE_MAX 0xFF |
149 | #define QED_DEFAULT_RX_USECS 12 | ||
149 | 150 | ||
150 | /* forward */ | 151 | /* forward */ |
151 | struct qed_dev; | 152 | struct qed_dev; |
diff --git a/include/linux/qed/qede_roce.h b/include/linux/qed/qede_roce.h index 99fbe6d55acb..f48d64b0e2fb 100644 --- a/include/linux/qed/qede_roce.h +++ b/include/linux/qed/qede_roce.h | |||
@@ -68,7 +68,7 @@ void qede_roce_unregister_driver(struct qedr_driver *drv); | |||
68 | 68 | ||
69 | bool qede_roce_supported(struct qede_dev *dev); | 69 | bool qede_roce_supported(struct qede_dev *dev); |
70 | 70 | ||
71 | #if IS_ENABLED(CONFIG_INFINIBAND_QEDR) | 71 | #if IS_ENABLED(CONFIG_QED_RDMA) |
72 | int qede_roce_dev_add(struct qede_dev *dev); | 72 | int qede_roce_dev_add(struct qede_dev *dev); |
73 | void qede_roce_dev_event_open(struct qede_dev *dev); | 73 | void qede_roce_dev_event_open(struct qede_dev *dev); |
74 | void qede_roce_dev_event_close(struct qede_dev *dev); | 74 | void qede_roce_dev_event_close(struct qede_dev *dev); |
diff --git a/include/linux/regmap.h b/include/linux/regmap.h index 9adc7b21903d..f6673132431d 100644 --- a/include/linux/regmap.h +++ b/include/linux/regmap.h | |||
@@ -15,6 +15,7 @@ | |||
15 | 15 | ||
16 | #include <linux/list.h> | 16 | #include <linux/list.h> |
17 | #include <linux/rbtree.h> | 17 | #include <linux/rbtree.h> |
18 | #include <linux/delay.h> | ||
18 | #include <linux/err.h> | 19 | #include <linux/err.h> |
19 | #include <linux/bug.h> | 20 | #include <linux/bug.h> |
20 | #include <linux/lockdep.h> | 21 | #include <linux/lockdep.h> |
@@ -116,22 +117,22 @@ struct reg_sequence { | |||
116 | #define regmap_read_poll_timeout(map, addr, val, cond, sleep_us, timeout_us) \ | 117 | #define regmap_read_poll_timeout(map, addr, val, cond, sleep_us, timeout_us) \ |
117 | ({ \ | 118 | ({ \ |
118 | ktime_t timeout = ktime_add_us(ktime_get(), timeout_us); \ | 119 | ktime_t timeout = ktime_add_us(ktime_get(), timeout_us); \ |
119 | int ret; \ | 120 | int pollret; \ |
120 | might_sleep_if(sleep_us); \ | 121 | might_sleep_if(sleep_us); \ |
121 | for (;;) { \ | 122 | for (;;) { \ |
122 | ret = regmap_read((map), (addr), &(val)); \ | 123 | pollret = regmap_read((map), (addr), &(val)); \ |
123 | if (ret) \ | 124 | if (pollret) \ |
124 | break; \ | 125 | break; \ |
125 | if (cond) \ | 126 | if (cond) \ |
126 | break; \ | 127 | break; \ |
127 | if (timeout_us && ktime_compare(ktime_get(), timeout) > 0) { \ | 128 | if (timeout_us && ktime_compare(ktime_get(), timeout) > 0) { \ |
128 | ret = regmap_read((map), (addr), &(val)); \ | 129 | pollret = regmap_read((map), (addr), &(val)); \ |
129 | break; \ | 130 | break; \ |
130 | } \ | 131 | } \ |
131 | if (sleep_us) \ | 132 | if (sleep_us) \ |
132 | usleep_range((sleep_us >> 2) + 1, sleep_us); \ | 133 | usleep_range((sleep_us >> 2) + 1, sleep_us); \ |
133 | } \ | 134 | } \ |
134 | ret ?: ((cond) ? 0 : -ETIMEDOUT); \ | 135 | pollret ?: ((cond) ? 0 : -ETIMEDOUT); \ |
135 | }) | 136 | }) |
136 | 137 | ||
137 | #ifdef CONFIG_REGMAP | 138 | #ifdef CONFIG_REGMAP |
diff --git a/include/linux/skbuff.h b/include/linux/skbuff.h index 601258f6e621..32810f279f8e 100644 --- a/include/linux/skbuff.h +++ b/include/linux/skbuff.h | |||
@@ -936,6 +936,7 @@ struct sk_buff_fclones { | |||
936 | 936 | ||
937 | /** | 937 | /** |
938 | * skb_fclone_busy - check if fclone is busy | 938 | * skb_fclone_busy - check if fclone is busy |
939 | * @sk: socket | ||
939 | * @skb: buffer | 940 | * @skb: buffer |
940 | * | 941 | * |
941 | * Returns true if skb is a fast clone, and its clone is not freed. | 942 | * Returns true if skb is a fast clone, and its clone is not freed. |
diff --git a/include/net/addrconf.h b/include/net/addrconf.h index f2d072787947..8f998afc1384 100644 --- a/include/net/addrconf.h +++ b/include/net/addrconf.h | |||
@@ -174,6 +174,7 @@ int ipv6_sock_mc_join(struct sock *sk, int ifindex, | |||
174 | const struct in6_addr *addr); | 174 | const struct in6_addr *addr); |
175 | int ipv6_sock_mc_drop(struct sock *sk, int ifindex, | 175 | int ipv6_sock_mc_drop(struct sock *sk, int ifindex, |
176 | const struct in6_addr *addr); | 176 | const struct in6_addr *addr); |
177 | void __ipv6_sock_mc_close(struct sock *sk); | ||
177 | void ipv6_sock_mc_close(struct sock *sk); | 178 | void ipv6_sock_mc_close(struct sock *sk); |
178 | bool inet6_mc_check(struct sock *sk, const struct in6_addr *mc_addr, | 179 | bool inet6_mc_check(struct sock *sk, const struct in6_addr *mc_addr, |
179 | const struct in6_addr *src_addr); | 180 | const struct in6_addr *src_addr); |
diff --git a/include/net/cfg80211.h b/include/net/cfg80211.h index bd19faad0d96..14b51d739c3b 100644 --- a/include/net/cfg80211.h +++ b/include/net/cfg80211.h | |||
@@ -4047,14 +4047,29 @@ unsigned int ieee80211_get_mesh_hdrlen(struct ieee80211s_hdr *meshhdr); | |||
4047 | */ | 4047 | */ |
4048 | 4048 | ||
4049 | /** | 4049 | /** |
4050 | * ieee80211_data_to_8023_exthdr - convert an 802.11 data frame to 802.3 | ||
4051 | * @skb: the 802.11 data frame | ||
4052 | * @ehdr: pointer to a &struct ethhdr that will get the header, instead | ||
4053 | * of it being pushed into the SKB | ||
4054 | * @addr: the device MAC address | ||
4055 | * @iftype: the virtual interface type | ||
4056 | * Return: 0 on success. Non-zero on error. | ||
4057 | */ | ||
4058 | int ieee80211_data_to_8023_exthdr(struct sk_buff *skb, struct ethhdr *ehdr, | ||
4059 | const u8 *addr, enum nl80211_iftype iftype); | ||
4060 | |||
4061 | /** | ||
4050 | * ieee80211_data_to_8023 - convert an 802.11 data frame to 802.3 | 4062 | * ieee80211_data_to_8023 - convert an 802.11 data frame to 802.3 |
4051 | * @skb: the 802.11 data frame | 4063 | * @skb: the 802.11 data frame |
4052 | * @addr: the device MAC address | 4064 | * @addr: the device MAC address |
4053 | * @iftype: the virtual interface type | 4065 | * @iftype: the virtual interface type |
4054 | * Return: 0 on success. Non-zero on error. | 4066 | * Return: 0 on success. Non-zero on error. |
4055 | */ | 4067 | */ |
4056 | int ieee80211_data_to_8023(struct sk_buff *skb, const u8 *addr, | 4068 | static inline int ieee80211_data_to_8023(struct sk_buff *skb, const u8 *addr, |
4057 | enum nl80211_iftype iftype); | 4069 | enum nl80211_iftype iftype) |
4070 | { | ||
4071 | return ieee80211_data_to_8023_exthdr(skb, NULL, addr, iftype); | ||
4072 | } | ||
4058 | 4073 | ||
4059 | /** | 4074 | /** |
4060 | * ieee80211_data_from_8023 - convert an 802.3 frame to 802.11 | 4075 | * ieee80211_data_from_8023 - convert an 802.3 frame to 802.11 |
@@ -4072,22 +4087,23 @@ int ieee80211_data_from_8023(struct sk_buff *skb, const u8 *addr, | |||
4072 | /** | 4087 | /** |
4073 | * ieee80211_amsdu_to_8023s - decode an IEEE 802.11n A-MSDU frame | 4088 | * ieee80211_amsdu_to_8023s - decode an IEEE 802.11n A-MSDU frame |
4074 | * | 4089 | * |
4075 | * Decode an IEEE 802.11n A-MSDU frame and convert it to a list of | 4090 | * Decode an IEEE 802.11 A-MSDU and convert it to a list of 802.3 frames. |
4076 | * 802.3 frames. The @list will be empty if the decode fails. The | 4091 | * The @list will be empty if the decode fails. The @skb must be fully |
4077 | * @skb is consumed after the function returns. | 4092 | * header-less before being passed in here; it is freed in this function. |
4078 | * | 4093 | * |
4079 | * @skb: The input IEEE 802.11n A-MSDU frame. | 4094 | * @skb: The input A-MSDU frame without any headers. |
4080 | * @list: The output list of 802.3 frames. It must be allocated and | 4095 | * @list: The output list of 802.3 frames. It must be allocated and |
4081 | * initialized by by the caller. | 4096 | * initialized by by the caller. |
4082 | * @addr: The device MAC address. | 4097 | * @addr: The device MAC address. |
4083 | * @iftype: The device interface type. | 4098 | * @iftype: The device interface type. |
4084 | * @extra_headroom: The hardware extra headroom for SKBs in the @list. | 4099 | * @extra_headroom: The hardware extra headroom for SKBs in the @list. |
4085 | * @has_80211_header: Set it true if SKB is with IEEE 802.11 header. | 4100 | * @check_da: DA to check in the inner ethernet header, or NULL |
4101 | * @check_sa: SA to check in the inner ethernet header, or NULL | ||
4086 | */ | 4102 | */ |
4087 | void ieee80211_amsdu_to_8023s(struct sk_buff *skb, struct sk_buff_head *list, | 4103 | void ieee80211_amsdu_to_8023s(struct sk_buff *skb, struct sk_buff_head *list, |
4088 | const u8 *addr, enum nl80211_iftype iftype, | 4104 | const u8 *addr, enum nl80211_iftype iftype, |
4089 | const unsigned int extra_headroom, | 4105 | const unsigned int extra_headroom, |
4090 | bool has_80211_header); | 4106 | const u8 *check_da, const u8 *check_sa); |
4091 | 4107 | ||
4092 | /** | 4108 | /** |
4093 | * cfg80211_classify8021d - determine the 802.1p/1d tag for a data frame | 4109 | * cfg80211_classify8021d - determine the 802.1p/1d tag for a data frame |
diff --git a/include/net/if_inet6.h b/include/net/if_inet6.h index 515352c6280a..b0576cb2ab25 100644 --- a/include/net/if_inet6.h +++ b/include/net/if_inet6.h | |||
@@ -190,8 +190,8 @@ struct inet6_dev { | |||
190 | __u32 if_flags; | 190 | __u32 if_flags; |
191 | int dead; | 191 | int dead; |
192 | 192 | ||
193 | u32 desync_factor; | ||
193 | u8 rndid[8]; | 194 | u8 rndid[8]; |
194 | struct timer_list regen_timer; | ||
195 | struct list_head tempaddr_list; | 195 | struct list_head tempaddr_list; |
196 | 196 | ||
197 | struct in6_addr token; | 197 | struct in6_addr token; |
diff --git a/include/net/ip.h b/include/net/ip.h index bc43c0fcae12..5413883ac47f 100644 --- a/include/net/ip.h +++ b/include/net/ip.h | |||
@@ -38,7 +38,7 @@ struct sock; | |||
38 | struct inet_skb_parm { | 38 | struct inet_skb_parm { |
39 | int iif; | 39 | int iif; |
40 | struct ip_options opt; /* Compiled IP options */ | 40 | struct ip_options opt; /* Compiled IP options */ |
41 | unsigned char flags; | 41 | u16 flags; |
42 | 42 | ||
43 | #define IPSKB_FORWARDED BIT(0) | 43 | #define IPSKB_FORWARDED BIT(0) |
44 | #define IPSKB_XFRM_TUNNEL_SIZE BIT(1) | 44 | #define IPSKB_XFRM_TUNNEL_SIZE BIT(1) |
@@ -48,10 +48,16 @@ struct inet_skb_parm { | |||
48 | #define IPSKB_DOREDIRECT BIT(5) | 48 | #define IPSKB_DOREDIRECT BIT(5) |
49 | #define IPSKB_FRAG_PMTU BIT(6) | 49 | #define IPSKB_FRAG_PMTU BIT(6) |
50 | #define IPSKB_FRAG_SEGS BIT(7) | 50 | #define IPSKB_FRAG_SEGS BIT(7) |
51 | #define IPSKB_L3SLAVE BIT(8) | ||
51 | 52 | ||
52 | u16 frag_max_size; | 53 | u16 frag_max_size; |
53 | }; | 54 | }; |
54 | 55 | ||
56 | static inline bool ipv4_l3mdev_skb(u16 flags) | ||
57 | { | ||
58 | return !!(flags & IPSKB_L3SLAVE); | ||
59 | } | ||
60 | |||
55 | static inline unsigned int ip_hdrlen(const struct sk_buff *skb) | 61 | static inline unsigned int ip_hdrlen(const struct sk_buff *skb) |
56 | { | 62 | { |
57 | return ip_hdr(skb)->ihl * 4; | 63 | return ip_hdr(skb)->ihl * 4; |
@@ -572,7 +578,7 @@ int ip_options_rcv_srr(struct sk_buff *skb); | |||
572 | */ | 578 | */ |
573 | 579 | ||
574 | void ipv4_pktinfo_prepare(const struct sock *sk, struct sk_buff *skb); | 580 | void ipv4_pktinfo_prepare(const struct sock *sk, struct sk_buff *skb); |
575 | void ip_cmsg_recv_offset(struct msghdr *msg, struct sk_buff *skb, int offset); | 581 | void ip_cmsg_recv_offset(struct msghdr *msg, struct sk_buff *skb, int tlen, int offset); |
576 | int ip_cmsg_send(struct sock *sk, struct msghdr *msg, | 582 | int ip_cmsg_send(struct sock *sk, struct msghdr *msg, |
577 | struct ipcm_cookie *ipc, bool allow_ipv6); | 583 | struct ipcm_cookie *ipc, bool allow_ipv6); |
578 | int ip_setsockopt(struct sock *sk, int level, int optname, char __user *optval, | 584 | int ip_setsockopt(struct sock *sk, int level, int optname, char __user *optval, |
@@ -594,7 +600,7 @@ void ip_local_error(struct sock *sk, int err, __be32 daddr, __be16 dport, | |||
594 | 600 | ||
595 | static inline void ip_cmsg_recv(struct msghdr *msg, struct sk_buff *skb) | 601 | static inline void ip_cmsg_recv(struct msghdr *msg, struct sk_buff *skb) |
596 | { | 602 | { |
597 | ip_cmsg_recv_offset(msg, skb, 0); | 603 | ip_cmsg_recv_offset(msg, skb, 0, 0); |
598 | } | 604 | } |
599 | 605 | ||
600 | bool icmp_global_allow(void); | 606 | bool icmp_global_allow(void); |
diff --git a/include/net/ip6_fib.h b/include/net/ip6_fib.h index fb961a576abe..a74e2aa40ef4 100644 --- a/include/net/ip6_fib.h +++ b/include/net/ip6_fib.h | |||
@@ -230,6 +230,8 @@ struct fib6_table { | |||
230 | rwlock_t tb6_lock; | 230 | rwlock_t tb6_lock; |
231 | struct fib6_node tb6_root; | 231 | struct fib6_node tb6_root; |
232 | struct inet_peer_base tb6_peers; | 232 | struct inet_peer_base tb6_peers; |
233 | unsigned int flags; | ||
234 | #define RT6_TABLE_HAS_DFLT_ROUTER BIT(0) | ||
233 | }; | 235 | }; |
234 | 236 | ||
235 | #define RT6_TABLE_UNSPEC RT_TABLE_UNSPEC | 237 | #define RT6_TABLE_UNSPEC RT_TABLE_UNSPEC |
diff --git a/include/net/ip6_route.h b/include/net/ip6_route.h index e0cd318d5103..f83e78d071a3 100644 --- a/include/net/ip6_route.h +++ b/include/net/ip6_route.h | |||
@@ -32,6 +32,7 @@ struct route_info { | |||
32 | #define RT6_LOOKUP_F_SRCPREF_TMP 0x00000008 | 32 | #define RT6_LOOKUP_F_SRCPREF_TMP 0x00000008 |
33 | #define RT6_LOOKUP_F_SRCPREF_PUBLIC 0x00000010 | 33 | #define RT6_LOOKUP_F_SRCPREF_PUBLIC 0x00000010 |
34 | #define RT6_LOOKUP_F_SRCPREF_COA 0x00000020 | 34 | #define RT6_LOOKUP_F_SRCPREF_COA 0x00000020 |
35 | #define RT6_LOOKUP_F_IGNORE_LINKSTATE 0x00000040 | ||
35 | 36 | ||
36 | /* We do not (yet ?) support IPv6 jumbograms (RFC 2675) | 37 | /* We do not (yet ?) support IPv6 jumbograms (RFC 2675) |
37 | * Unlike IPv4, hdr->seg_len doesn't include the IPv6 header | 38 | * Unlike IPv4, hdr->seg_len doesn't include the IPv6 header |
diff --git a/include/net/mac80211.h b/include/net/mac80211.h index a810dfcb83c2..e2dba93e374f 100644 --- a/include/net/mac80211.h +++ b/include/net/mac80211.h | |||
@@ -811,14 +811,18 @@ enum mac80211_rate_control_flags { | |||
811 | * in the control information, and it will be filled by the rate | 811 | * in the control information, and it will be filled by the rate |
812 | * control algorithm according to what should be sent. For example, | 812 | * control algorithm according to what should be sent. For example, |
813 | * if this array contains, in the format { <idx>, <count> } the | 813 | * if this array contains, in the format { <idx>, <count> } the |
814 | * information | 814 | * information:: |
815 | * | ||
815 | * { 3, 2 }, { 2, 2 }, { 1, 4 }, { -1, 0 }, { -1, 0 } | 816 | * { 3, 2 }, { 2, 2 }, { 1, 4 }, { -1, 0 }, { -1, 0 } |
817 | * | ||
816 | * then this means that the frame should be transmitted | 818 | * then this means that the frame should be transmitted |
817 | * up to twice at rate 3, up to twice at rate 2, and up to four | 819 | * up to twice at rate 3, up to twice at rate 2, and up to four |
818 | * times at rate 1 if it doesn't get acknowledged. Say it gets | 820 | * times at rate 1 if it doesn't get acknowledged. Say it gets |
819 | * acknowledged by the peer after the fifth attempt, the status | 821 | * acknowledged by the peer after the fifth attempt, the status |
820 | * information should then contain | 822 | * information should then contain:: |
823 | * | ||
821 | * { 3, 2 }, { 2, 2 }, { 1, 1 }, { -1, 0 } ... | 824 | * { 3, 2 }, { 2, 2 }, { 1, 1 }, { -1, 0 } ... |
825 | * | ||
822 | * since it was transmitted twice at rate 3, twice at rate 2 | 826 | * since it was transmitted twice at rate 3, twice at rate 2 |
823 | * and once at rate 1 after which we received an acknowledgement. | 827 | * and once at rate 1 after which we received an acknowledgement. |
824 | */ | 828 | */ |
@@ -1168,8 +1172,8 @@ enum mac80211_rx_vht_flags { | |||
1168 | * @rate_idx: index of data rate into band's supported rates or MCS index if | 1172 | * @rate_idx: index of data rate into band's supported rates or MCS index if |
1169 | * HT or VHT is used (%RX_FLAG_HT/%RX_FLAG_VHT) | 1173 | * HT or VHT is used (%RX_FLAG_HT/%RX_FLAG_VHT) |
1170 | * @vht_nss: number of streams (VHT only) | 1174 | * @vht_nss: number of streams (VHT only) |
1171 | * @flag: %RX_FLAG_* | 1175 | * @flag: %RX_FLAG_\* |
1172 | * @vht_flag: %RX_VHT_FLAG_* | 1176 | * @vht_flag: %RX_VHT_FLAG_\* |
1173 | * @rx_flags: internal RX flags for mac80211 | 1177 | * @rx_flags: internal RX flags for mac80211 |
1174 | * @ampdu_reference: A-MPDU reference number, must be a different value for | 1178 | * @ampdu_reference: A-MPDU reference number, must be a different value for |
1175 | * each A-MPDU but the same for each subframe within one A-MPDU | 1179 | * each A-MPDU but the same for each subframe within one A-MPDU |
@@ -1432,7 +1436,7 @@ enum ieee80211_vif_flags { | |||
1432 | * @probe_req_reg: probe requests should be reported to mac80211 for this | 1436 | * @probe_req_reg: probe requests should be reported to mac80211 for this |
1433 | * interface. | 1437 | * interface. |
1434 | * @drv_priv: data area for driver use, will always be aligned to | 1438 | * @drv_priv: data area for driver use, will always be aligned to |
1435 | * sizeof(void *). | 1439 | * sizeof(void \*). |
1436 | * @txq: the multicast data TX queue (if driver uses the TXQ abstraction) | 1440 | * @txq: the multicast data TX queue (if driver uses the TXQ abstraction) |
1437 | */ | 1441 | */ |
1438 | struct ieee80211_vif { | 1442 | struct ieee80211_vif { |
@@ -1743,7 +1747,7 @@ struct ieee80211_sta_rates { | |||
1743 | * @wme: indicates whether the STA supports QoS/WME (if local devices does, | 1747 | * @wme: indicates whether the STA supports QoS/WME (if local devices does, |
1744 | * otherwise always false) | 1748 | * otherwise always false) |
1745 | * @drv_priv: data area for driver use, will always be aligned to | 1749 | * @drv_priv: data area for driver use, will always be aligned to |
1746 | * sizeof(void *), size is determined in hw information. | 1750 | * sizeof(void \*), size is determined in hw information. |
1747 | * @uapsd_queues: bitmap of queues configured for uapsd. Only valid | 1751 | * @uapsd_queues: bitmap of queues configured for uapsd. Only valid |
1748 | * if wme is supported. | 1752 | * if wme is supported. |
1749 | * @max_sp: max Service Period. Only valid if wme is supported. | 1753 | * @max_sp: max Service Period. Only valid if wme is supported. |
@@ -2146,12 +2150,12 @@ enum ieee80211_hw_flags { | |||
2146 | * | 2150 | * |
2147 | * @radiotap_mcs_details: lists which MCS information can the HW | 2151 | * @radiotap_mcs_details: lists which MCS information can the HW |
2148 | * reports, by default it is set to _MCS, _GI and _BW but doesn't | 2152 | * reports, by default it is set to _MCS, _GI and _BW but doesn't |
2149 | * include _FMT. Use %IEEE80211_RADIOTAP_MCS_HAVE_* values, only | 2153 | * include _FMT. Use %IEEE80211_RADIOTAP_MCS_HAVE_\* values, only |
2150 | * adding _BW is supported today. | 2154 | * adding _BW is supported today. |
2151 | * | 2155 | * |
2152 | * @radiotap_vht_details: lists which VHT MCS information the HW reports, | 2156 | * @radiotap_vht_details: lists which VHT MCS information the HW reports, |
2153 | * the default is _GI | _BANDWIDTH. | 2157 | * the default is _GI | _BANDWIDTH. |
2154 | * Use the %IEEE80211_RADIOTAP_VHT_KNOWN_* values. | 2158 | * Use the %IEEE80211_RADIOTAP_VHT_KNOWN_\* values. |
2155 | * | 2159 | * |
2156 | * @radiotap_timestamp: Information for the radiotap timestamp field; if the | 2160 | * @radiotap_timestamp: Information for the radiotap timestamp field; if the |
2157 | * 'units_pos' member is set to a non-negative value it must be set to | 2161 | * 'units_pos' member is set to a non-negative value it must be set to |
@@ -2486,6 +2490,7 @@ void ieee80211_free_txskb(struct ieee80211_hw *hw, struct sk_buff *skb); | |||
2486 | * in the software stack cares about, we will, in the future, have mac80211 | 2490 | * in the software stack cares about, we will, in the future, have mac80211 |
2487 | * tell the driver which information elements are interesting in the sense | 2491 | * tell the driver which information elements are interesting in the sense |
2488 | * that we want to see changes in them. This will include | 2492 | * that we want to see changes in them. This will include |
2493 | * | ||
2489 | * - a list of information element IDs | 2494 | * - a list of information element IDs |
2490 | * - a list of OUIs for the vendor information element | 2495 | * - a list of OUIs for the vendor information element |
2491 | * | 2496 | * |
diff --git a/include/net/sock.h b/include/net/sock.h index ebf75db08e06..73c6b008f1b7 100644 --- a/include/net/sock.h +++ b/include/net/sock.h | |||
@@ -252,6 +252,7 @@ struct sock_common { | |||
252 | * @sk_pacing_rate: Pacing rate (if supported by transport/packet scheduler) | 252 | * @sk_pacing_rate: Pacing rate (if supported by transport/packet scheduler) |
253 | * @sk_max_pacing_rate: Maximum pacing rate (%SO_MAX_PACING_RATE) | 253 | * @sk_max_pacing_rate: Maximum pacing rate (%SO_MAX_PACING_RATE) |
254 | * @sk_sndbuf: size of send buffer in bytes | 254 | * @sk_sndbuf: size of send buffer in bytes |
255 | * @sk_padding: unused element for alignment | ||
255 | * @sk_no_check_tx: %SO_NO_CHECK setting, set checksum in TX packets | 256 | * @sk_no_check_tx: %SO_NO_CHECK setting, set checksum in TX packets |
256 | * @sk_no_check_rx: allow zero checksum in RX packets | 257 | * @sk_no_check_rx: allow zero checksum in RX packets |
257 | * @sk_route_caps: route capabilities (e.g. %NETIF_F_TSO) | 258 | * @sk_route_caps: route capabilities (e.g. %NETIF_F_TSO) |
@@ -302,7 +303,8 @@ struct sock_common { | |||
302 | * @sk_backlog_rcv: callback to process the backlog | 303 | * @sk_backlog_rcv: callback to process the backlog |
303 | * @sk_destruct: called at sock freeing time, i.e. when all refcnt == 0 | 304 | * @sk_destruct: called at sock freeing time, i.e. when all refcnt == 0 |
304 | * @sk_reuseport_cb: reuseport group container | 305 | * @sk_reuseport_cb: reuseport group container |
305 | */ | 306 | * @sk_rcu: used during RCU grace period |
307 | */ | ||
306 | struct sock { | 308 | struct sock { |
307 | /* | 309 | /* |
308 | * Now struct inet_timewait_sock also uses sock_common, so please just | 310 | * Now struct inet_timewait_sock also uses sock_common, so please just |
diff --git a/include/net/tcp.h b/include/net/tcp.h index f83b7f220a65..5b82d4d94834 100644 --- a/include/net/tcp.h +++ b/include/net/tcp.h | |||
@@ -794,12 +794,23 @@ struct tcp_skb_cb { | |||
794 | */ | 794 | */ |
795 | static inline int tcp_v6_iif(const struct sk_buff *skb) | 795 | static inline int tcp_v6_iif(const struct sk_buff *skb) |
796 | { | 796 | { |
797 | bool l3_slave = skb_l3mdev_slave(TCP_SKB_CB(skb)->header.h6.flags); | 797 | bool l3_slave = ipv6_l3mdev_skb(TCP_SKB_CB(skb)->header.h6.flags); |
798 | 798 | ||
799 | return l3_slave ? skb->skb_iif : TCP_SKB_CB(skb)->header.h6.iif; | 799 | return l3_slave ? skb->skb_iif : TCP_SKB_CB(skb)->header.h6.iif; |
800 | } | 800 | } |
801 | #endif | 801 | #endif |
802 | 802 | ||
803 | /* TCP_SKB_CB reference means this can not be used from early demux */ | ||
804 | static inline bool inet_exact_dif_match(struct net *net, struct sk_buff *skb) | ||
805 | { | ||
806 | #if IS_ENABLED(CONFIG_NET_L3_MASTER_DEV) | ||
807 | if (!net->ipv4.sysctl_tcp_l3mdev_accept && | ||
808 | ipv4_l3mdev_skb(TCP_SKB_CB(skb)->header.h4.flags)) | ||
809 | return true; | ||
810 | #endif | ||
811 | return false; | ||
812 | } | ||
813 | |||
803 | /* Due to TSO, an SKB can be composed of multiple actual | 814 | /* Due to TSO, an SKB can be composed of multiple actual |
804 | * packets. To keep these tracked properly, we use this. | 815 | * packets. To keep these tracked properly, we use this. |
805 | */ | 816 | */ |
diff --git a/include/net/udp.h b/include/net/udp.h index ea53a87d880f..4948790d393d 100644 --- a/include/net/udp.h +++ b/include/net/udp.h | |||
@@ -258,6 +258,7 @@ void udp_flush_pending_frames(struct sock *sk); | |||
258 | void udp4_hwcsum(struct sk_buff *skb, __be32 src, __be32 dst); | 258 | void udp4_hwcsum(struct sk_buff *skb, __be32 src, __be32 dst); |
259 | int udp_rcv(struct sk_buff *skb); | 259 | int udp_rcv(struct sk_buff *skb); |
260 | int udp_ioctl(struct sock *sk, int cmd, unsigned long arg); | 260 | int udp_ioctl(struct sock *sk, int cmd, unsigned long arg); |
261 | int __udp_disconnect(struct sock *sk, int flags); | ||
261 | int udp_disconnect(struct sock *sk, int flags); | 262 | int udp_disconnect(struct sock *sk, int flags); |
262 | unsigned int udp_poll(struct file *file, struct socket *sock, poll_table *wait); | 263 | unsigned int udp_poll(struct file *file, struct socket *sock, poll_table *wait); |
263 | struct sk_buff *skb_udp_tunnel_segment(struct sk_buff *skb, | 264 | struct sk_buff *skb_udp_tunnel_segment(struct sk_buff *skb, |
diff --git a/include/net/vxlan.h b/include/net/vxlan.h index 0255613a54a4..308adc4154f4 100644 --- a/include/net/vxlan.h +++ b/include/net/vxlan.h | |||
@@ -225,9 +225,9 @@ struct vxlan_config { | |||
225 | struct vxlan_dev { | 225 | struct vxlan_dev { |
226 | struct hlist_node hlist; /* vni hash table */ | 226 | struct hlist_node hlist; /* vni hash table */ |
227 | struct list_head next; /* vxlan's per namespace list */ | 227 | struct list_head next; /* vxlan's per namespace list */ |
228 | struct vxlan_sock *vn4_sock; /* listening socket for IPv4 */ | 228 | struct vxlan_sock __rcu *vn4_sock; /* listening socket for IPv4 */ |
229 | #if IS_ENABLED(CONFIG_IPV6) | 229 | #if IS_ENABLED(CONFIG_IPV6) |
230 | struct vxlan_sock *vn6_sock; /* listening socket for IPv6 */ | 230 | struct vxlan_sock __rcu *vn6_sock; /* listening socket for IPv6 */ |
231 | #endif | 231 | #endif |
232 | struct net_device *dev; | 232 | struct net_device *dev; |
233 | struct net *net; /* netns for packet i/o */ | 233 | struct net *net; /* netns for packet i/o */ |
diff --git a/include/uapi/linux/ethtool.h b/include/uapi/linux/ethtool.h index 099a4200732c..8e547231c1b7 100644 --- a/include/uapi/linux/ethtool.h +++ b/include/uapi/linux/ethtool.h | |||
@@ -119,8 +119,7 @@ struct ethtool_cmd { | |||
119 | static inline void ethtool_cmd_speed_set(struct ethtool_cmd *ep, | 119 | static inline void ethtool_cmd_speed_set(struct ethtool_cmd *ep, |
120 | __u32 speed) | 120 | __u32 speed) |
121 | { | 121 | { |
122 | 122 | ep->speed = (__u16)(speed & 0xFFFF); | |
123 | ep->speed = (__u16)speed; | ||
124 | ep->speed_hi = (__u16)(speed >> 16); | 123 | ep->speed_hi = (__u16)(speed >> 16); |
125 | } | 124 | } |
126 | 125 | ||
diff --git a/include/uapi/linux/rtnetlink.h b/include/uapi/linux/rtnetlink.h index 262f0379d83a..5a78be518101 100644 --- a/include/uapi/linux/rtnetlink.h +++ b/include/uapi/linux/rtnetlink.h | |||
@@ -350,7 +350,7 @@ struct rtnexthop { | |||
350 | #define RTNH_F_OFFLOAD 8 /* offloaded route */ | 350 | #define RTNH_F_OFFLOAD 8 /* offloaded route */ |
351 | #define RTNH_F_LINKDOWN 16 /* carrier-down on nexthop */ | 351 | #define RTNH_F_LINKDOWN 16 /* carrier-down on nexthop */ |
352 | 352 | ||
353 | #define RTNH_COMPARE_MASK (RTNH_F_DEAD | RTNH_F_LINKDOWN) | 353 | #define RTNH_COMPARE_MASK (RTNH_F_DEAD | RTNH_F_LINKDOWN | RTNH_F_OFFLOAD) |
354 | 354 | ||
355 | /* Macros to handle hexthops */ | 355 | /* Macros to handle hexthops */ |
356 | 356 | ||
diff --git a/include/video/display_timing.h b/include/video/display_timing.h index 28d9d0d566ca..3d289e990aca 100644 --- a/include/video/display_timing.h +++ b/include/video/display_timing.h | |||
@@ -28,6 +28,10 @@ enum display_flags { | |||
28 | DISPLAY_FLAGS_INTERLACED = BIT(8), | 28 | DISPLAY_FLAGS_INTERLACED = BIT(8), |
29 | DISPLAY_FLAGS_DOUBLESCAN = BIT(9), | 29 | DISPLAY_FLAGS_DOUBLESCAN = BIT(9), |
30 | DISPLAY_FLAGS_DOUBLECLK = BIT(10), | 30 | DISPLAY_FLAGS_DOUBLECLK = BIT(10), |
31 | /* drive sync on pos. edge */ | ||
32 | DISPLAY_FLAGS_SYNC_POSEDGE = BIT(11), | ||
33 | /* drive sync on neg. edge */ | ||
34 | DISPLAY_FLAGS_SYNC_NEGEDGE = BIT(12), | ||
31 | }; | 35 | }; |
32 | 36 | ||
33 | /* | 37 | /* |