aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
Diffstat (limited to 'include')
-rw-r--r--include/asm-generic/qspinlock.h53
-rw-r--r--include/linux/binfmts.h1
-rw-r--r--include/linux/clk-provider.h2
-rw-r--r--include/linux/cpuidle.h3
-rw-r--r--include/linux/dcache.h12
-rw-r--r--include/linux/efi.h2
-rw-r--r--include/linux/iio/common/st_sensors.h9
-rw-r--r--include/linux/isa.h5
-rw-r--r--include/linux/leds.h23
-rw-r--r--include/linux/mlx5/device.h8
-rw-r--r--include/linux/mlx5/mlx5_ifc.h12
-rw-r--r--include/linux/mlx5/qp.h6
-rw-r--r--include/linux/mlx5/vport.h2
-rw-r--r--include/linux/of.h2
-rw-r--r--include/linux/of_pci.h2
-rw-r--r--include/linux/of_reserved_mem.h7
-rw-r--r--include/linux/pwm.h3
-rw-r--r--include/linux/seqlock.h7
-rw-r--r--include/linux/sunrpc/clnt.h2
-rw-r--r--include/linux/sunrpc/svc_xprt.h1
-rw-r--r--include/linux/sunrpc/xprt.h1
-rw-r--r--include/linux/thermal.h2
-rw-r--r--include/linux/usb/gadget.h3
-rw-r--r--include/linux/usb/musb.h5
-rw-r--r--include/media/v4l2-mc.h2
-rw-r--r--include/net/compat.h1
-rw-r--r--include/net/ip_vs.h2
-rw-r--r--include/net/netfilter/nf_queue.h4
-rw-r--r--include/net/netns/netfilter.h2
-rw-r--r--include/net/pkt_cls.h10
-rw-r--r--include/net/sch_generic.h6
-rw-r--r--include/rdma/ib_verbs.h6
-rw-r--r--include/uapi/linux/btrfs.h2
-rw-r--r--include/uapi/linux/gtp.h2
-rw-r--r--include/uapi/sound/Kbuild3
35 files changed, 132 insertions, 81 deletions
diff --git a/include/asm-generic/qspinlock.h b/include/asm-generic/qspinlock.h
index 6bd05700d8c9..05f05f17a7c2 100644
--- a/include/asm-generic/qspinlock.h
+++ b/include/asm-generic/qspinlock.h
@@ -22,37 +22,33 @@
22#include <asm-generic/qspinlock_types.h> 22#include <asm-generic/qspinlock_types.h>
23 23
24/** 24/**
25 * queued_spin_unlock_wait - wait until the _current_ lock holder releases the lock
26 * @lock : Pointer to queued spinlock structure
27 *
28 * There is a very slight possibility of live-lock if the lockers keep coming
29 * and the waiter is just unfortunate enough to not see any unlock state.
30 */
31#ifndef queued_spin_unlock_wait
32extern void queued_spin_unlock_wait(struct qspinlock *lock);
33#endif
34
35/**
25 * queued_spin_is_locked - is the spinlock locked? 36 * queued_spin_is_locked - is the spinlock locked?
26 * @lock: Pointer to queued spinlock structure 37 * @lock: Pointer to queued spinlock structure
27 * Return: 1 if it is locked, 0 otherwise 38 * Return: 1 if it is locked, 0 otherwise
28 */ 39 */
40#ifndef queued_spin_is_locked
29static __always_inline int queued_spin_is_locked(struct qspinlock *lock) 41static __always_inline int queued_spin_is_locked(struct qspinlock *lock)
30{ 42{
31 /* 43 /*
32 * queued_spin_lock_slowpath() can ACQUIRE the lock before 44 * See queued_spin_unlock_wait().
33 * issuing the unordered store that sets _Q_LOCKED_VAL.
34 *
35 * See both smp_cond_acquire() sites for more detail.
36 *
37 * This however means that in code like:
38 *
39 * spin_lock(A) spin_lock(B)
40 * spin_unlock_wait(B) spin_is_locked(A)
41 * do_something() do_something()
42 *
43 * Both CPUs can end up running do_something() because the store
44 * setting _Q_LOCKED_VAL will pass through the loads in
45 * spin_unlock_wait() and/or spin_is_locked().
46 * 45 *
47 * Avoid this by issuing a full memory barrier between the spin_lock() 46 * Any !0 state indicates it is locked, even if _Q_LOCKED_VAL
48 * and the loads in spin_unlock_wait() and spin_is_locked(). 47 * isn't immediately observable.
49 *
50 * Note that regular mutual exclusion doesn't care about this
51 * delayed store.
52 */ 48 */
53 smp_mb(); 49 return atomic_read(&lock->val);
54 return atomic_read(&lock->val) & _Q_LOCKED_MASK;
55} 50}
51#endif
56 52
57/** 53/**
58 * queued_spin_value_unlocked - is the spinlock structure unlocked? 54 * queued_spin_value_unlocked - is the spinlock structure unlocked?
@@ -122,21 +118,6 @@ static __always_inline void queued_spin_unlock(struct qspinlock *lock)
122} 118}
123#endif 119#endif
124 120
125/**
126 * queued_spin_unlock_wait - wait until current lock holder releases the lock
127 * @lock : Pointer to queued spinlock structure
128 *
129 * There is a very slight possibility of live-lock if the lockers keep coming
130 * and the waiter is just unfortunate enough to not see any unlock state.
131 */
132static inline void queued_spin_unlock_wait(struct qspinlock *lock)
133{
134 /* See queued_spin_is_locked() */
135 smp_mb();
136 while (atomic_read(&lock->val) & _Q_LOCKED_MASK)
137 cpu_relax();
138}
139
140#ifndef virt_spin_lock 121#ifndef virt_spin_lock
141static __always_inline bool virt_spin_lock(struct qspinlock *lock) 122static __always_inline bool virt_spin_lock(struct qspinlock *lock)
142{ 123{
diff --git a/include/linux/binfmts.h b/include/linux/binfmts.h
index 576e4639ca60..314b3caa701c 100644
--- a/include/linux/binfmts.h
+++ b/include/linux/binfmts.h
@@ -65,6 +65,7 @@ struct coredump_params {
65 unsigned long limit; 65 unsigned long limit;
66 unsigned long mm_flags; 66 unsigned long mm_flags;
67 loff_t written; 67 loff_t written;
68 loff_t pos;
68}; 69};
69 70
70/* 71/*
diff --git a/include/linux/clk-provider.h b/include/linux/clk-provider.h
index 0c72204c75fc..fb39d5add173 100644
--- a/include/linux/clk-provider.h
+++ b/include/linux/clk-provider.h
@@ -25,7 +25,7 @@
25#define CLK_SET_PARENT_GATE BIT(1) /* must be gated across re-parent */ 25#define CLK_SET_PARENT_GATE BIT(1) /* must be gated across re-parent */
26#define CLK_SET_RATE_PARENT BIT(2) /* propagate rate change up one level */ 26#define CLK_SET_RATE_PARENT BIT(2) /* propagate rate change up one level */
27#define CLK_IGNORE_UNUSED BIT(3) /* do not gate even if unused */ 27#define CLK_IGNORE_UNUSED BIT(3) /* do not gate even if unused */
28#define CLK_IS_ROOT BIT(4) /* Deprecated: Don't use */ 28 /* unused */
29#define CLK_IS_BASIC BIT(5) /* Basic clk, can't do a to_clk_foo() */ 29#define CLK_IS_BASIC BIT(5) /* Basic clk, can't do a to_clk_foo() */
30#define CLK_GET_RATE_NOCACHE BIT(6) /* do not use the cached clk rate */ 30#define CLK_GET_RATE_NOCACHE BIT(6) /* do not use the cached clk rate */
31#define CLK_SET_RATE_NO_REPARENT BIT(7) /* don't re-parent on rate change */ 31#define CLK_SET_RATE_NO_REPARENT BIT(7) /* don't re-parent on rate change */
diff --git a/include/linux/cpuidle.h b/include/linux/cpuidle.h
index 786ad32631a6..07b83d32f66c 100644
--- a/include/linux/cpuidle.h
+++ b/include/linux/cpuidle.h
@@ -152,6 +152,8 @@ extern void cpuidle_disable_device(struct cpuidle_device *dev);
152extern int cpuidle_play_dead(void); 152extern int cpuidle_play_dead(void);
153 153
154extern struct cpuidle_driver *cpuidle_get_cpu_driver(struct cpuidle_device *dev); 154extern struct cpuidle_driver *cpuidle_get_cpu_driver(struct cpuidle_device *dev);
155static inline struct cpuidle_device *cpuidle_get_device(void)
156{return __this_cpu_read(cpuidle_devices); }
155#else 157#else
156static inline void disable_cpuidle(void) { } 158static inline void disable_cpuidle(void) { }
157static inline bool cpuidle_not_available(struct cpuidle_driver *drv, 159static inline bool cpuidle_not_available(struct cpuidle_driver *drv,
@@ -187,6 +189,7 @@ static inline void cpuidle_disable_device(struct cpuidle_device *dev) { }
187static inline int cpuidle_play_dead(void) {return -ENODEV; } 189static inline int cpuidle_play_dead(void) {return -ENODEV; }
188static inline struct cpuidle_driver *cpuidle_get_cpu_driver( 190static inline struct cpuidle_driver *cpuidle_get_cpu_driver(
189 struct cpuidle_device *dev) {return NULL; } 191 struct cpuidle_device *dev) {return NULL; }
192static inline struct cpuidle_device *cpuidle_get_device(void) {return NULL; }
190#endif 193#endif
191 194
192#if defined(CONFIG_CPU_IDLE) && defined(CONFIG_SUSPEND) 195#if defined(CONFIG_CPU_IDLE) && defined(CONFIG_SUSPEND)
diff --git a/include/linux/dcache.h b/include/linux/dcache.h
index 484c8792da82..f28100f6b556 100644
--- a/include/linux/dcache.h
+++ b/include/linux/dcache.h
@@ -575,5 +575,17 @@ static inline struct inode *vfs_select_inode(struct dentry *dentry,
575 return inode; 575 return inode;
576} 576}
577 577
578/**
579 * d_real_inode - Return the real inode
580 * @dentry: The dentry to query
581 *
582 * If dentry is on an union/overlay, then return the underlying, real inode.
583 * Otherwise return d_inode().
584 */
585static inline struct inode *d_real_inode(struct dentry *dentry)
586{
587 return d_backing_inode(d_real(dentry));
588}
589
578 590
579#endif /* __LINUX_DCACHE_H */ 591#endif /* __LINUX_DCACHE_H */
diff --git a/include/linux/efi.h b/include/linux/efi.h
index c2db3ca22217..f196dd0b0f2f 100644
--- a/include/linux/efi.h
+++ b/include/linux/efi.h
@@ -1005,7 +1005,7 @@ extern int efi_memattr_apply_permissions(struct mm_struct *mm,
1005/* Iterate through an efi_memory_map */ 1005/* Iterate through an efi_memory_map */
1006#define for_each_efi_memory_desc_in_map(m, md) \ 1006#define for_each_efi_memory_desc_in_map(m, md) \
1007 for ((md) = (m)->map; \ 1007 for ((md) = (m)->map; \
1008 (md) <= (efi_memory_desc_t *)((m)->map_end - (m)->desc_size); \ 1008 ((void *)(md) + (m)->desc_size) <= (m)->map_end; \
1009 (md) = (void *)(md) + (m)->desc_size) 1009 (md) = (void *)(md) + (m)->desc_size)
1010 1010
1011/** 1011/**
diff --git a/include/linux/iio/common/st_sensors.h b/include/linux/iio/common/st_sensors.h
index 91d5f684a53a..28052cddaa03 100644
--- a/include/linux/iio/common/st_sensors.h
+++ b/include/linux/iio/common/st_sensors.h
@@ -223,6 +223,8 @@ struct st_sensor_settings {
223 * @get_irq_data_ready: Function to get the IRQ used for data ready signal. 223 * @get_irq_data_ready: Function to get the IRQ used for data ready signal.
224 * @tf: Transfer function structure used by I/O operations. 224 * @tf: Transfer function structure used by I/O operations.
225 * @tb: Transfer buffers and mutex used by I/O operations. 225 * @tb: Transfer buffers and mutex used by I/O operations.
226 * @hw_irq_trigger: if we're using the hardware interrupt on the sensor.
227 * @hw_timestamp: Latest timestamp from the interrupt handler, when in use.
226 */ 228 */
227struct st_sensor_data { 229struct st_sensor_data {
228 struct device *dev; 230 struct device *dev;
@@ -247,6 +249,9 @@ struct st_sensor_data {
247 249
248 const struct st_sensor_transfer_function *tf; 250 const struct st_sensor_transfer_function *tf;
249 struct st_sensor_transfer_buffer tb; 251 struct st_sensor_transfer_buffer tb;
252
253 bool hw_irq_trigger;
254 s64 hw_timestamp;
250}; 255};
251 256
252#ifdef CONFIG_IIO_BUFFER 257#ifdef CONFIG_IIO_BUFFER
@@ -258,7 +263,8 @@ int st_sensors_allocate_trigger(struct iio_dev *indio_dev,
258 const struct iio_trigger_ops *trigger_ops); 263 const struct iio_trigger_ops *trigger_ops);
259 264
260void st_sensors_deallocate_trigger(struct iio_dev *indio_dev); 265void st_sensors_deallocate_trigger(struct iio_dev *indio_dev);
261 266int st_sensors_validate_device(struct iio_trigger *trig,
267 struct iio_dev *indio_dev);
262#else 268#else
263static inline int st_sensors_allocate_trigger(struct iio_dev *indio_dev, 269static inline int st_sensors_allocate_trigger(struct iio_dev *indio_dev,
264 const struct iio_trigger_ops *trigger_ops) 270 const struct iio_trigger_ops *trigger_ops)
@@ -269,6 +275,7 @@ static inline void st_sensors_deallocate_trigger(struct iio_dev *indio_dev)
269{ 275{
270 return; 276 return;
271} 277}
278#define st_sensors_validate_device NULL
272#endif 279#endif
273 280
274int st_sensors_init_sensor(struct iio_dev *indio_dev, 281int st_sensors_init_sensor(struct iio_dev *indio_dev,
diff --git a/include/linux/isa.h b/include/linux/isa.h
index 5ab85281230b..f2d0258414cf 100644
--- a/include/linux/isa.h
+++ b/include/linux/isa.h
@@ -6,6 +6,7 @@
6#define __LINUX_ISA_H 6#define __LINUX_ISA_H
7 7
8#include <linux/device.h> 8#include <linux/device.h>
9#include <linux/errno.h>
9#include <linux/kernel.h> 10#include <linux/kernel.h>
10 11
11struct isa_driver { 12struct isa_driver {
@@ -22,13 +23,13 @@ struct isa_driver {
22 23
23#define to_isa_driver(x) container_of((x), struct isa_driver, driver) 24#define to_isa_driver(x) container_of((x), struct isa_driver, driver)
24 25
25#ifdef CONFIG_ISA 26#ifdef CONFIG_ISA_BUS_API
26int isa_register_driver(struct isa_driver *, unsigned int); 27int isa_register_driver(struct isa_driver *, unsigned int);
27void isa_unregister_driver(struct isa_driver *); 28void isa_unregister_driver(struct isa_driver *);
28#else 29#else
29static inline int isa_register_driver(struct isa_driver *d, unsigned int i) 30static inline int isa_register_driver(struct isa_driver *d, unsigned int i)
30{ 31{
31 return 0; 32 return -ENODEV;
32} 33}
33 34
34static inline void isa_unregister_driver(struct isa_driver *d) 35static inline void isa_unregister_driver(struct isa_driver *d)
diff --git a/include/linux/leds.h b/include/linux/leds.h
index d2b13066e781..e5e7f2e80a54 100644
--- a/include/linux/leds.h
+++ b/include/linux/leds.h
@@ -42,15 +42,16 @@ struct led_classdev {
42#define LED_UNREGISTERING (1 << 1) 42#define LED_UNREGISTERING (1 << 1)
43 /* Upper 16 bits reflect control information */ 43 /* Upper 16 bits reflect control information */
44#define LED_CORE_SUSPENDRESUME (1 << 16) 44#define LED_CORE_SUSPENDRESUME (1 << 16)
45#define LED_BLINK_ONESHOT (1 << 17) 45#define LED_BLINK_SW (1 << 17)
46#define LED_BLINK_ONESHOT_STOP (1 << 18) 46#define LED_BLINK_ONESHOT (1 << 18)
47#define LED_BLINK_INVERT (1 << 19) 47#define LED_BLINK_ONESHOT_STOP (1 << 19)
48#define LED_BLINK_BRIGHTNESS_CHANGE (1 << 20) 48#define LED_BLINK_INVERT (1 << 20)
49#define LED_BLINK_DISABLE (1 << 21) 49#define LED_BLINK_BRIGHTNESS_CHANGE (1 << 21)
50#define LED_SYSFS_DISABLE (1 << 22) 50#define LED_BLINK_DISABLE (1 << 22)
51#define LED_DEV_CAP_FLASH (1 << 23) 51#define LED_SYSFS_DISABLE (1 << 23)
52#define LED_HW_PLUGGABLE (1 << 24) 52#define LED_DEV_CAP_FLASH (1 << 24)
53#define LED_PANIC_INDICATOR (1 << 25) 53#define LED_HW_PLUGGABLE (1 << 25)
54#define LED_PANIC_INDICATOR (1 << 26)
54 55
55 /* Set LED brightness level 56 /* Set LED brightness level
56 * Must not sleep. Use brightness_set_blocking for drivers 57 * Must not sleep. Use brightness_set_blocking for drivers
@@ -72,8 +73,8 @@ struct led_classdev {
72 * and if both are zero then a sensible default should be chosen. 73 * and if both are zero then a sensible default should be chosen.
73 * The call should adjust the timings in that case and if it can't 74 * The call should adjust the timings in that case and if it can't
74 * match the values specified exactly. 75 * match the values specified exactly.
75 * Deactivate blinking again when the brightness is set to a fixed 76 * Deactivate blinking again when the brightness is set to LED_OFF
76 * value via the brightness_set() callback. 77 * via the brightness_set() callback.
77 */ 78 */
78 int (*blink_set)(struct led_classdev *led_cdev, 79 int (*blink_set)(struct led_classdev *led_cdev,
79 unsigned long *delay_on, 80 unsigned long *delay_on,
diff --git a/include/linux/mlx5/device.h b/include/linux/mlx5/device.h
index 035abdf62cfe..73a48479892d 100644
--- a/include/linux/mlx5/device.h
+++ b/include/linux/mlx5/device.h
@@ -1240,8 +1240,6 @@ struct mlx5_destroy_psv_out {
1240 u8 rsvd[8]; 1240 u8 rsvd[8];
1241}; 1241};
1242 1242
1243#define MLX5_CMD_OP_MAX 0x920
1244
1245enum { 1243enum {
1246 VPORT_STATE_DOWN = 0x0, 1244 VPORT_STATE_DOWN = 0x0,
1247 VPORT_STATE_UP = 0x1, 1245 VPORT_STATE_UP = 0x1,
@@ -1369,6 +1367,12 @@ enum mlx5_cap_type {
1369#define MLX5_CAP_FLOWTABLE_MAX(mdev, cap) \ 1367#define MLX5_CAP_FLOWTABLE_MAX(mdev, cap) \
1370 MLX5_GET(flow_table_nic_cap, mdev->hca_caps_max[MLX5_CAP_FLOW_TABLE], cap) 1368 MLX5_GET(flow_table_nic_cap, mdev->hca_caps_max[MLX5_CAP_FLOW_TABLE], cap)
1371 1369
1370#define MLX5_CAP_FLOWTABLE_NIC_RX(mdev, cap) \
1371 MLX5_CAP_FLOWTABLE(mdev, flow_table_properties_nic_receive.cap)
1372
1373#define MLX5_CAP_FLOWTABLE_NIC_RX_MAX(mdev, cap) \
1374 MLX5_CAP_FLOWTABLE_MAX(mdev, flow_table_properties_nic_receive.cap)
1375
1372#define MLX5_CAP_ESW_FLOWTABLE(mdev, cap) \ 1376#define MLX5_CAP_ESW_FLOWTABLE(mdev, cap) \
1373 MLX5_GET(flow_table_eswitch_cap, \ 1377 MLX5_GET(flow_table_eswitch_cap, \
1374 mdev->hca_caps_cur[MLX5_CAP_ESWITCH_FLOW_TABLE], cap) 1378 mdev->hca_caps_cur[MLX5_CAP_ESWITCH_FLOW_TABLE], cap)
diff --git a/include/linux/mlx5/mlx5_ifc.h b/include/linux/mlx5/mlx5_ifc.h
index 9a05cd7e5890..e955a2859009 100644
--- a/include/linux/mlx5/mlx5_ifc.h
+++ b/include/linux/mlx5/mlx5_ifc.h
@@ -205,7 +205,8 @@ enum {
205 MLX5_CMD_OP_ALLOC_FLOW_COUNTER = 0x939, 205 MLX5_CMD_OP_ALLOC_FLOW_COUNTER = 0x939,
206 MLX5_CMD_OP_DEALLOC_FLOW_COUNTER = 0x93a, 206 MLX5_CMD_OP_DEALLOC_FLOW_COUNTER = 0x93a,
207 MLX5_CMD_OP_QUERY_FLOW_COUNTER = 0x93b, 207 MLX5_CMD_OP_QUERY_FLOW_COUNTER = 0x93b,
208 MLX5_CMD_OP_MODIFY_FLOW_TABLE = 0x93c 208 MLX5_CMD_OP_MODIFY_FLOW_TABLE = 0x93c,
209 MLX5_CMD_OP_MAX
209}; 210};
210 211
211struct mlx5_ifc_flow_table_fields_supported_bits { 212struct mlx5_ifc_flow_table_fields_supported_bits {
@@ -500,7 +501,9 @@ struct mlx5_ifc_e_switch_cap_bits {
500 u8 vport_svlan_insert[0x1]; 501 u8 vport_svlan_insert[0x1];
501 u8 vport_cvlan_insert_if_not_exist[0x1]; 502 u8 vport_cvlan_insert_if_not_exist[0x1];
502 u8 vport_cvlan_insert_overwrite[0x1]; 503 u8 vport_cvlan_insert_overwrite[0x1];
503 u8 reserved_at_5[0x1b]; 504 u8 reserved_at_5[0x19];
505 u8 nic_vport_node_guid_modify[0x1];
506 u8 nic_vport_port_guid_modify[0x1];
504 507
505 u8 reserved_at_20[0x7e0]; 508 u8 reserved_at_20[0x7e0];
506}; 509};
@@ -4583,7 +4586,10 @@ struct mlx5_ifc_modify_nic_vport_context_out_bits {
4583}; 4586};
4584 4587
4585struct mlx5_ifc_modify_nic_vport_field_select_bits { 4588struct mlx5_ifc_modify_nic_vport_field_select_bits {
4586 u8 reserved_at_0[0x19]; 4589 u8 reserved_at_0[0x16];
4590 u8 node_guid[0x1];
4591 u8 port_guid[0x1];
4592 u8 reserved_at_18[0x1];
4587 u8 mtu[0x1]; 4593 u8 mtu[0x1];
4588 u8 change_event[0x1]; 4594 u8 change_event[0x1];
4589 u8 promisc[0x1]; 4595 u8 promisc[0x1];
diff --git a/include/linux/mlx5/qp.h b/include/linux/mlx5/qp.h
index 64221027bf1f..266320feb160 100644
--- a/include/linux/mlx5/qp.h
+++ b/include/linux/mlx5/qp.h
@@ -460,10 +460,9 @@ struct mlx5_core_qp {
460}; 460};
461 461
462struct mlx5_qp_path { 462struct mlx5_qp_path {
463 u8 fl; 463 u8 fl_free_ar;
464 u8 rsvd3; 464 u8 rsvd3;
465 u8 free_ar; 465 __be16 pkey_index;
466 u8 pkey_index;
467 u8 rsvd0; 466 u8 rsvd0;
468 u8 grh_mlid; 467 u8 grh_mlid;
469 __be16 rlid; 468 __be16 rlid;
@@ -560,6 +559,7 @@ struct mlx5_modify_qp_mbox_in {
560 __be32 optparam; 559 __be32 optparam;
561 u8 rsvd0[4]; 560 u8 rsvd0[4];
562 struct mlx5_qp_context ctx; 561 struct mlx5_qp_context ctx;
562 u8 rsvd2[16];
563}; 563};
564 564
565struct mlx5_modify_qp_mbox_out { 565struct mlx5_modify_qp_mbox_out {
diff --git a/include/linux/mlx5/vport.h b/include/linux/mlx5/vport.h
index 301da4a5e6bf..6c16c198f680 100644
--- a/include/linux/mlx5/vport.h
+++ b/include/linux/mlx5/vport.h
@@ -50,6 +50,8 @@ int mlx5_modify_nic_vport_mtu(struct mlx5_core_dev *mdev, u16 mtu);
50int mlx5_query_nic_vport_system_image_guid(struct mlx5_core_dev *mdev, 50int mlx5_query_nic_vport_system_image_guid(struct mlx5_core_dev *mdev,
51 u64 *system_image_guid); 51 u64 *system_image_guid);
52int mlx5_query_nic_vport_node_guid(struct mlx5_core_dev *mdev, u64 *node_guid); 52int mlx5_query_nic_vport_node_guid(struct mlx5_core_dev *mdev, u64 *node_guid);
53int mlx5_modify_nic_vport_node_guid(struct mlx5_core_dev *mdev,
54 u32 vport, u64 node_guid);
53int mlx5_query_nic_vport_qkey_viol_cntr(struct mlx5_core_dev *mdev, 55int mlx5_query_nic_vport_qkey_viol_cntr(struct mlx5_core_dev *mdev,
54 u16 *qkey_viol_cntr); 56 u16 *qkey_viol_cntr);
55int mlx5_query_hca_vport_gid(struct mlx5_core_dev *dev, u8 other_vport, 57int mlx5_query_hca_vport_gid(struct mlx5_core_dev *dev, u8 other_vport,
diff --git a/include/linux/of.h b/include/linux/of.h
index c7292e8ea080..74eb28cadbef 100644
--- a/include/linux/of.h
+++ b/include/linux/of.h
@@ -614,7 +614,7 @@ static inline struct device_node *of_parse_phandle(const struct device_node *np,
614 return NULL; 614 return NULL;
615} 615}
616 616
617static inline int of_parse_phandle_with_args(struct device_node *np, 617static inline int of_parse_phandle_with_args(const struct device_node *np,
618 const char *list_name, 618 const char *list_name,
619 const char *cells_name, 619 const char *cells_name,
620 int index, 620 int index,
diff --git a/include/linux/of_pci.h b/include/linux/of_pci.h
index f6e9e85164e8..b969e9443962 100644
--- a/include/linux/of_pci.h
+++ b/include/linux/of_pci.h
@@ -8,7 +8,7 @@ struct pci_dev;
8struct of_phandle_args; 8struct of_phandle_args;
9struct device_node; 9struct device_node;
10 10
11#ifdef CONFIG_OF 11#ifdef CONFIG_OF_PCI
12int of_irq_parse_pci(const struct pci_dev *pdev, struct of_phandle_args *out_irq); 12int of_irq_parse_pci(const struct pci_dev *pdev, struct of_phandle_args *out_irq);
13struct device_node *of_pci_find_child_device(struct device_node *parent, 13struct device_node *of_pci_find_child_device(struct device_node *parent,
14 unsigned int devfn); 14 unsigned int devfn);
diff --git a/include/linux/of_reserved_mem.h b/include/linux/of_reserved_mem.h
index ad2f67054372..c201060e0c6d 100644
--- a/include/linux/of_reserved_mem.h
+++ b/include/linux/of_reserved_mem.h
@@ -31,6 +31,13 @@ typedef int (*reservedmem_of_init_fn)(struct reserved_mem *rmem);
31int of_reserved_mem_device_init(struct device *dev); 31int of_reserved_mem_device_init(struct device *dev);
32void of_reserved_mem_device_release(struct device *dev); 32void of_reserved_mem_device_release(struct device *dev);
33 33
34int early_init_dt_alloc_reserved_memory_arch(phys_addr_t size,
35 phys_addr_t align,
36 phys_addr_t start,
37 phys_addr_t end,
38 bool nomap,
39 phys_addr_t *res_base);
40
34void fdt_init_reserved_mem(void); 41void fdt_init_reserved_mem(void);
35void fdt_reserved_mem_save_node(unsigned long node, const char *uname, 42void fdt_reserved_mem_save_node(unsigned long node, const char *uname,
36 phys_addr_t base, phys_addr_t size); 43 phys_addr_t base, phys_addr_t size);
diff --git a/include/linux/pwm.h b/include/linux/pwm.h
index 17018f3c066e..908b67c847cd 100644
--- a/include/linux/pwm.h
+++ b/include/linux/pwm.h
@@ -235,6 +235,9 @@ static inline int pwm_config(struct pwm_device *pwm, int duty_ns,
235 if (!pwm) 235 if (!pwm)
236 return -EINVAL; 236 return -EINVAL;
237 237
238 if (duty_ns < 0 || period_ns < 0)
239 return -EINVAL;
240
238 pwm_get_state(pwm, &state); 241 pwm_get_state(pwm, &state);
239 if (state.duty_cycle == duty_ns && state.period == period_ns) 242 if (state.duty_cycle == duty_ns && state.period == period_ns)
240 return 0; 243 return 0;
diff --git a/include/linux/seqlock.h b/include/linux/seqlock.h
index 7973a821ac58..ead97654c4e9 100644
--- a/include/linux/seqlock.h
+++ b/include/linux/seqlock.h
@@ -277,7 +277,10 @@ static inline void raw_write_seqcount_barrier(seqcount_t *s)
277 277
278static inline int raw_read_seqcount_latch(seqcount_t *s) 278static inline int raw_read_seqcount_latch(seqcount_t *s)
279{ 279{
280 return lockless_dereference(s)->sequence; 280 int seq = READ_ONCE(s->sequence);
281 /* Pairs with the first smp_wmb() in raw_write_seqcount_latch() */
282 smp_read_barrier_depends();
283 return seq;
281} 284}
282 285
283/** 286/**
@@ -331,7 +334,7 @@ static inline int raw_read_seqcount_latch(seqcount_t *s)
331 * unsigned seq, idx; 334 * unsigned seq, idx;
332 * 335 *
333 * do { 336 * do {
334 * seq = lockless_dereference(latch)->seq; 337 * seq = raw_read_seqcount_latch(&latch->seq);
335 * 338 *
336 * idx = seq & 0x01; 339 * idx = seq & 0x01;
337 * entry = data_query(latch->data[idx], ...); 340 * entry = data_query(latch->data[idx], ...);
diff --git a/include/linux/sunrpc/clnt.h b/include/linux/sunrpc/clnt.h
index 19c659d1c0f8..b6810c92b8bb 100644
--- a/include/linux/sunrpc/clnt.h
+++ b/include/linux/sunrpc/clnt.h
@@ -137,8 +137,6 @@ struct rpc_create_args {
137#define RPC_CLNT_CREATE_NO_RETRANS_TIMEOUT (1UL << 9) 137#define RPC_CLNT_CREATE_NO_RETRANS_TIMEOUT (1UL << 9)
138 138
139struct rpc_clnt *rpc_create(struct rpc_create_args *args); 139struct rpc_clnt *rpc_create(struct rpc_create_args *args);
140struct rpc_clnt *rpc_create_xprt(struct rpc_create_args *args,
141 struct rpc_xprt *xprt);
142struct rpc_clnt *rpc_bind_new_program(struct rpc_clnt *, 140struct rpc_clnt *rpc_bind_new_program(struct rpc_clnt *,
143 const struct rpc_program *, u32); 141 const struct rpc_program *, u32);
144struct rpc_clnt *rpc_clone_client(struct rpc_clnt *); 142struct rpc_clnt *rpc_clone_client(struct rpc_clnt *);
diff --git a/include/linux/sunrpc/svc_xprt.h b/include/linux/sunrpc/svc_xprt.h
index b7dabc4baafd..79ba50856707 100644
--- a/include/linux/sunrpc/svc_xprt.h
+++ b/include/linux/sunrpc/svc_xprt.h
@@ -84,6 +84,7 @@ struct svc_xprt {
84 84
85 struct net *xpt_net; 85 struct net *xpt_net;
86 struct rpc_xprt *xpt_bc_xprt; /* NFSv4.1 backchannel */ 86 struct rpc_xprt *xpt_bc_xprt; /* NFSv4.1 backchannel */
87 struct rpc_xprt_switch *xpt_bc_xps; /* NFSv4.1 backchannel */
87}; 88};
88 89
89static inline void unregister_xpt_user(struct svc_xprt *xpt, struct svc_xpt_user *u) 90static inline void unregister_xpt_user(struct svc_xprt *xpt, struct svc_xpt_user *u)
diff --git a/include/linux/sunrpc/xprt.h b/include/linux/sunrpc/xprt.h
index 5aa3834619a8..5e3e1b63dbb3 100644
--- a/include/linux/sunrpc/xprt.h
+++ b/include/linux/sunrpc/xprt.h
@@ -297,6 +297,7 @@ struct xprt_create {
297 size_t addrlen; 297 size_t addrlen;
298 const char *servername; 298 const char *servername;
299 struct svc_xprt *bc_xprt; /* NFSv4.1 backchannel */ 299 struct svc_xprt *bc_xprt; /* NFSv4.1 backchannel */
300 struct rpc_xprt_switch *bc_xps;
300 unsigned int flags; 301 unsigned int flags;
301}; 302};
302 303
diff --git a/include/linux/thermal.h b/include/linux/thermal.h
index e45abe7db9a6..ee517bef0db0 100644
--- a/include/linux/thermal.h
+++ b/include/linux/thermal.h
@@ -335,6 +335,8 @@ struct thermal_genl_event {
335 * @get_trend: a pointer to a function that reads the sensor temperature trend. 335 * @get_trend: a pointer to a function that reads the sensor temperature trend.
336 * @set_emul_temp: a pointer to a function that sets sensor emulated 336 * @set_emul_temp: a pointer to a function that sets sensor emulated
337 * temperature. 337 * temperature.
338 * @set_trip_temp: a pointer to a function that sets the trip temperature on
339 * hardware.
338 */ 340 */
339struct thermal_zone_of_device_ops { 341struct thermal_zone_of_device_ops {
340 int (*get_temp)(void *, int *); 342 int (*get_temp)(void *, int *);
diff --git a/include/linux/usb/gadget.h b/include/linux/usb/gadget.h
index 457651bf45b0..fefe8b06a63d 100644
--- a/include/linux/usb/gadget.h
+++ b/include/linux/usb/gadget.h
@@ -1034,6 +1034,8 @@ static inline int usb_gadget_activate(struct usb_gadget *gadget)
1034 * @udc_name: A name of UDC this driver should be bound to. If udc_name is NULL, 1034 * @udc_name: A name of UDC this driver should be bound to. If udc_name is NULL,
1035 * this driver will be bound to any available UDC. 1035 * this driver will be bound to any available UDC.
1036 * @pending: UDC core private data used for deferred probe of this driver. 1036 * @pending: UDC core private data used for deferred probe of this driver.
1037 * @match_existing_only: If udc is not found, return an error and don't add this
1038 * gadget driver to list of pending driver
1037 * 1039 *
1038 * Devices are disabled till a gadget driver successfully bind()s, which 1040 * Devices are disabled till a gadget driver successfully bind()s, which
1039 * means the driver will handle setup() requests needed to enumerate (and 1041 * means the driver will handle setup() requests needed to enumerate (and
@@ -1097,6 +1099,7 @@ struct usb_gadget_driver {
1097 1099
1098 char *udc_name; 1100 char *udc_name;
1099 struct list_head pending; 1101 struct list_head pending;
1102 unsigned match_existing_only:1;
1100}; 1103};
1101 1104
1102 1105
diff --git a/include/linux/usb/musb.h b/include/linux/usb/musb.h
index 0b3da40a525e..d315c8907869 100644
--- a/include/linux/usb/musb.h
+++ b/include/linux/usb/musb.h
@@ -142,10 +142,11 @@ enum musb_vbus_id_status {
142}; 142};
143 143
144#if IS_ENABLED(CONFIG_USB_MUSB_HDRC) 144#if IS_ENABLED(CONFIG_USB_MUSB_HDRC)
145void musb_mailbox(enum musb_vbus_id_status status); 145int musb_mailbox(enum musb_vbus_id_status status);
146#else 146#else
147static inline void musb_mailbox(enum musb_vbus_id_status status) 147static inline int musb_mailbox(enum musb_vbus_id_status status)
148{ 148{
149 return 0;
149} 150}
150#endif 151#endif
151 152
diff --git a/include/media/v4l2-mc.h b/include/media/v4l2-mc.h
index 98a938aabdfb..7a8d6037a4bb 100644
--- a/include/media/v4l2-mc.h
+++ b/include/media/v4l2-mc.h
@@ -1,7 +1,7 @@
1/* 1/*
2 * v4l2-mc.h - Media Controller V4L2 types and prototypes 2 * v4l2-mc.h - Media Controller V4L2 types and prototypes
3 * 3 *
4 * Copyright (C) 2016 Mauro Carvalho Chehab <mchehab@osg.samsung.com> 4 * Copyright (C) 2016 Mauro Carvalho Chehab <mchehab@kernel.org>
5 * Copyright (C) 2006-2010 Nokia Corporation 5 * Copyright (C) 2006-2010 Nokia Corporation
6 * Copyright (c) 2016 Intel Corporation. 6 * Copyright (c) 2016 Intel Corporation.
7 * 7 *
diff --git a/include/net/compat.h b/include/net/compat.h
index 48103cf94e97..13de0ccaa059 100644
--- a/include/net/compat.h
+++ b/include/net/compat.h
@@ -42,6 +42,7 @@ int compat_sock_get_timestampns(struct sock *, struct timespec __user *);
42 42
43int get_compat_msghdr(struct msghdr *, struct compat_msghdr __user *, 43int get_compat_msghdr(struct msghdr *, struct compat_msghdr __user *,
44 struct sockaddr __user **, struct iovec **); 44 struct sockaddr __user **, struct iovec **);
45struct sock_fprog __user *get_compat_bpf_fprog(char __user *optval);
45asmlinkage long compat_sys_sendmsg(int, struct compat_msghdr __user *, 46asmlinkage long compat_sys_sendmsg(int, struct compat_msghdr __user *,
46 unsigned int); 47 unsigned int);
47asmlinkage long compat_sys_sendmmsg(int, struct compat_mmsghdr __user *, 48asmlinkage long compat_sys_sendmmsg(int, struct compat_mmsghdr __user *,
diff --git a/include/net/ip_vs.h b/include/net/ip_vs.h
index af4c10ebb241..cd6018a9ee24 100644
--- a/include/net/ip_vs.h
+++ b/include/net/ip_vs.h
@@ -1232,7 +1232,7 @@ void ip_vs_conn_expire_now(struct ip_vs_conn *cp);
1232const char *ip_vs_state_name(__u16 proto, int state); 1232const char *ip_vs_state_name(__u16 proto, int state);
1233 1233
1234void ip_vs_tcp_conn_listen(struct ip_vs_conn *cp); 1234void ip_vs_tcp_conn_listen(struct ip_vs_conn *cp);
1235int ip_vs_check_template(struct ip_vs_conn *ct); 1235int ip_vs_check_template(struct ip_vs_conn *ct, struct ip_vs_dest *cdest);
1236void ip_vs_random_dropentry(struct netns_ipvs *ipvs); 1236void ip_vs_random_dropentry(struct netns_ipvs *ipvs);
1237int ip_vs_conn_init(void); 1237int ip_vs_conn_init(void);
1238void ip_vs_conn_cleanup(void); 1238void ip_vs_conn_cleanup(void);
diff --git a/include/net/netfilter/nf_queue.h b/include/net/netfilter/nf_queue.h
index 9c5638ad872e..0dbce55437f2 100644
--- a/include/net/netfilter/nf_queue.h
+++ b/include/net/netfilter/nf_queue.h
@@ -28,8 +28,8 @@ struct nf_queue_handler {
28 struct nf_hook_ops *ops); 28 struct nf_hook_ops *ops);
29}; 29};
30 30
31void nf_register_queue_handler(const struct nf_queue_handler *qh); 31void nf_register_queue_handler(struct net *net, const struct nf_queue_handler *qh);
32void nf_unregister_queue_handler(void); 32void nf_unregister_queue_handler(struct net *net);
33void nf_reinject(struct nf_queue_entry *entry, unsigned int verdict); 33void nf_reinject(struct nf_queue_entry *entry, unsigned int verdict);
34 34
35void nf_queue_entry_get_refs(struct nf_queue_entry *entry); 35void nf_queue_entry_get_refs(struct nf_queue_entry *entry);
diff --git a/include/net/netns/netfilter.h b/include/net/netns/netfilter.h
index 38aa4983e2a9..36d723579af2 100644
--- a/include/net/netns/netfilter.h
+++ b/include/net/netns/netfilter.h
@@ -5,11 +5,13 @@
5 5
6struct proc_dir_entry; 6struct proc_dir_entry;
7struct nf_logger; 7struct nf_logger;
8struct nf_queue_handler;
8 9
9struct netns_nf { 10struct netns_nf {
10#if defined CONFIG_PROC_FS 11#if defined CONFIG_PROC_FS
11 struct proc_dir_entry *proc_netfilter; 12 struct proc_dir_entry *proc_netfilter;
12#endif 13#endif
14 const struct nf_queue_handler __rcu *queue_handler;
13 const struct nf_logger __rcu *nf_loggers[NFPROTO_NUMPROTO]; 15 const struct nf_logger __rcu *nf_loggers[NFPROTO_NUMPROTO];
14#ifdef CONFIG_SYSCTL 16#ifdef CONFIG_SYSCTL
15 struct ctl_table_header *nf_log_dir_header; 17 struct ctl_table_header *nf_log_dir_header;
diff --git a/include/net/pkt_cls.h b/include/net/pkt_cls.h
index 0f7efa88f210..3722dda0199d 100644
--- a/include/net/pkt_cls.h
+++ b/include/net/pkt_cls.h
@@ -392,16 +392,20 @@ struct tc_cls_u32_offload {
392 }; 392 };
393}; 393};
394 394
395static inline bool tc_should_offload(struct net_device *dev, u32 flags) 395static inline bool tc_should_offload(const struct net_device *dev,
396 const struct tcf_proto *tp, u32 flags)
396{ 397{
398 const struct Qdisc *sch = tp->q;
399 const struct Qdisc_class_ops *cops = sch->ops->cl_ops;
400
397 if (!(dev->features & NETIF_F_HW_TC)) 401 if (!(dev->features & NETIF_F_HW_TC))
398 return false; 402 return false;
399
400 if (flags & TCA_CLS_FLAGS_SKIP_HW) 403 if (flags & TCA_CLS_FLAGS_SKIP_HW)
401 return false; 404 return false;
402
403 if (!dev->netdev_ops->ndo_setup_tc) 405 if (!dev->netdev_ops->ndo_setup_tc)
404 return false; 406 return false;
407 if (cops && cops->tcf_cl_offload)
408 return cops->tcf_cl_offload(tp->classid);
405 409
406 return true; 410 return true;
407} 411}
diff --git a/include/net/sch_generic.h b/include/net/sch_generic.h
index a1fd76c22a59..62d553184e91 100644
--- a/include/net/sch_generic.h
+++ b/include/net/sch_generic.h
@@ -168,6 +168,7 @@ struct Qdisc_class_ops {
168 168
169 /* Filter manipulation */ 169 /* Filter manipulation */
170 struct tcf_proto __rcu ** (*tcf_chain)(struct Qdisc *, unsigned long); 170 struct tcf_proto __rcu ** (*tcf_chain)(struct Qdisc *, unsigned long);
171 bool (*tcf_cl_offload)(u32 classid);
171 unsigned long (*bind_tcf)(struct Qdisc *, unsigned long, 172 unsigned long (*bind_tcf)(struct Qdisc *, unsigned long,
172 u32 classid); 173 u32 classid);
173 void (*unbind_tcf)(struct Qdisc *, unsigned long); 174 void (*unbind_tcf)(struct Qdisc *, unsigned long);
@@ -691,9 +692,11 @@ static inline struct sk_buff *qdisc_peek_dequeued(struct Qdisc *sch)
691 /* we can reuse ->gso_skb because peek isn't called for root qdiscs */ 692 /* we can reuse ->gso_skb because peek isn't called for root qdiscs */
692 if (!sch->gso_skb) { 693 if (!sch->gso_skb) {
693 sch->gso_skb = sch->dequeue(sch); 694 sch->gso_skb = sch->dequeue(sch);
694 if (sch->gso_skb) 695 if (sch->gso_skb) {
695 /* it's still part of the queue */ 696 /* it's still part of the queue */
697 qdisc_qstats_backlog_inc(sch, sch->gso_skb);
696 sch->q.qlen++; 698 sch->q.qlen++;
699 }
697 } 700 }
698 701
699 return sch->gso_skb; 702 return sch->gso_skb;
@@ -706,6 +709,7 @@ static inline struct sk_buff *qdisc_dequeue_peeked(struct Qdisc *sch)
706 709
707 if (skb) { 710 if (skb) {
708 sch->gso_skb = NULL; 711 sch->gso_skb = NULL;
712 qdisc_qstats_backlog_dec(sch, skb);
709 sch->q.qlen--; 713 sch->q.qlen--;
710 } else { 714 } else {
711 skb = sch->dequeue(sch); 715 skb = sch->dequeue(sch);
diff --git a/include/rdma/ib_verbs.h b/include/rdma/ib_verbs.h
index 432bed510369..7e440d41487a 100644
--- a/include/rdma/ib_verbs.h
+++ b/include/rdma/ib_verbs.h
@@ -217,10 +217,10 @@ enum ib_device_cap_flags {
217 IB_DEVICE_CROSS_CHANNEL = (1 << 27), 217 IB_DEVICE_CROSS_CHANNEL = (1 << 27),
218 IB_DEVICE_MANAGED_FLOW_STEERING = (1 << 29), 218 IB_DEVICE_MANAGED_FLOW_STEERING = (1 << 29),
219 IB_DEVICE_SIGNATURE_HANDOVER = (1 << 30), 219 IB_DEVICE_SIGNATURE_HANDOVER = (1 << 30),
220 IB_DEVICE_ON_DEMAND_PAGING = (1 << 31), 220 IB_DEVICE_ON_DEMAND_PAGING = (1ULL << 31),
221 IB_DEVICE_SG_GAPS_REG = (1ULL << 32), 221 IB_DEVICE_SG_GAPS_REG = (1ULL << 32),
222 IB_DEVICE_VIRTUAL_FUNCTION = ((u64)1 << 33), 222 IB_DEVICE_VIRTUAL_FUNCTION = (1ULL << 33),
223 IB_DEVICE_RAW_SCATTER_FCS = ((u64)1 << 34), 223 IB_DEVICE_RAW_SCATTER_FCS = (1ULL << 34),
224}; 224};
225 225
226enum ib_signature_prot_cap { 226enum ib_signature_prot_cap {
diff --git a/include/uapi/linux/btrfs.h b/include/uapi/linux/btrfs.h
index 23c6960e94a4..2bdd1e3e7007 100644
--- a/include/uapi/linux/btrfs.h
+++ b/include/uapi/linux/btrfs.h
@@ -118,7 +118,7 @@ struct btrfs_ioctl_vol_args_v2 {
118 }; 118 };
119 union { 119 union {
120 char name[BTRFS_SUBVOL_NAME_MAX + 1]; 120 char name[BTRFS_SUBVOL_NAME_MAX + 1];
121 u64 devid; 121 __u64 devid;
122 }; 122 };
123}; 123};
124 124
diff --git a/include/uapi/linux/gtp.h b/include/uapi/linux/gtp.h
index ca1054dd8249..72a04a0e8cce 100644
--- a/include/uapi/linux/gtp.h
+++ b/include/uapi/linux/gtp.h
@@ -1,5 +1,5 @@
1#ifndef _UAPI_LINUX_GTP_H_ 1#ifndef _UAPI_LINUX_GTP_H_
2#define _UAPI_LINUX_GTP_H__ 2#define _UAPI_LINUX_GTP_H_
3 3
4enum gtp_genl_cmds { 4enum gtp_genl_cmds {
5 GTP_CMD_NEWPDP, 5 GTP_CMD_NEWPDP,
diff --git a/include/uapi/sound/Kbuild b/include/uapi/sound/Kbuild
index a7f27704f980..691984cb0b91 100644
--- a/include/uapi/sound/Kbuild
+++ b/include/uapi/sound/Kbuild
@@ -1,5 +1,6 @@
1# UAPI Header export list 1# UAPI Header export list
2header-y += asequencer.h 2header-y += asequencer.h
3header-y += asoc.h
3header-y += asound.h 4header-y += asound.h
4header-y += asound_fm.h 5header-y += asound_fm.h
5header-y += compress_offload.h 6header-y += compress_offload.h
@@ -10,3 +11,5 @@ header-y += hdsp.h
10header-y += hdspm.h 11header-y += hdspm.h
11header-y += sb16_csp.h 12header-y += sb16_csp.h
12header-y += sfnt_info.h 13header-y += sfnt_info.h
14header-y += tlv.h
15header-y += usb_stream.h