diff options
author | Mark Brown <broonie@opensource.wolfsonmicro.com> | 2012-07-22 14:32:00 -0400 |
---|---|---|
committer | Mark Brown <broonie@opensource.wolfsonmicro.com> | 2012-07-22 14:32:00 -0400 |
commit | 3384fb98845dc014770caa224d61a2effd258ca5 (patch) | |
tree | 8189134a4938632e2d06e93af04c9fc1f3c2d4c9 /include | |
parent | 8cfc545e0e3e6cc82acfdc79321b41eeeab0ca45 (diff) | |
parent | ade7515fefad9af13f6dd469f35bb413b6a5b473 (diff) |
Merge branch 'regulator-drivers' into regulator-next
Diffstat (limited to 'include')
-rw-r--r-- | include/linux/aio.h | 1 | ||||
-rw-r--r-- | include/linux/blkdev.h | 1 | ||||
-rw-r--r-- | include/linux/bootmem.h | 5 | ||||
-rw-r--r-- | include/linux/gpio.h | 4 | ||||
-rw-r--r-- | include/linux/hrtimer.h | 10 | ||||
-rw-r--r-- | include/linux/input.h | 1 | ||||
-rw-r--r-- | include/linux/kvm_host.h | 4 | ||||
-rw-r--r-- | include/linux/memblock.h | 4 | ||||
-rw-r--r-- | include/linux/mfd/s5m87xx/s5m-core.h | 5 | ||||
-rw-r--r-- | include/linux/mfd/tps65217.h | 13 | ||||
-rw-r--r-- | include/linux/mfd/tps65910.h | 6 | ||||
-rw-r--r-- | include/linux/mmzone.h | 2 | ||||
-rw-r--r-- | include/linux/pci.h | 2 | ||||
-rw-r--r-- | include/linux/prctl.h | 2 | ||||
-rw-r--r-- | include/linux/rcupdate.h | 1 | ||||
-rw-r--r-- | include/linux/rcutiny.h | 6 | ||||
-rw-r--r-- | include/linux/regulator/driver.h | 23 | ||||
-rw-r--r-- | include/linux/regulator/fixed.h | 2 | ||||
-rw-r--r-- | include/linux/regulator/lp872x.h | 90 | ||||
-rw-r--r-- | include/linux/regulator/machine.h | 3 | ||||
-rw-r--r-- | include/linux/rpmsg.h | 6 | ||||
-rw-r--r-- | include/linux/sched.h | 18 | ||||
-rw-r--r-- | include/linux/splice.h | 8 | ||||
-rw-r--r-- | include/net/sctp/structs.h | 4 | ||||
-rw-r--r-- | include/net/sctp/tsnmap.h | 3 | ||||
-rw-r--r-- | include/scsi/libsas.h | 6 | ||||
-rw-r--r-- | include/scsi/scsi_cmnd.h | 8 |
27 files changed, 196 insertions, 42 deletions
diff --git a/include/linux/aio.h b/include/linux/aio.h index 2314ad8b3c9c..b1a520ec8b59 100644 --- a/include/linux/aio.h +++ b/include/linux/aio.h | |||
@@ -140,6 +140,7 @@ struct kiocb { | |||
140 | (x)->ki_dtor = NULL; \ | 140 | (x)->ki_dtor = NULL; \ |
141 | (x)->ki_obj.tsk = tsk; \ | 141 | (x)->ki_obj.tsk = tsk; \ |
142 | (x)->ki_user_data = 0; \ | 142 | (x)->ki_user_data = 0; \ |
143 | (x)->private = NULL; \ | ||
143 | } while (0) | 144 | } while (0) |
144 | 145 | ||
145 | #define AIO_RING_MAGIC 0xa10a10a1 | 146 | #define AIO_RING_MAGIC 0xa10a10a1 |
diff --git a/include/linux/blkdev.h b/include/linux/blkdev.h index ba43f408baa3..07954b05b86c 100644 --- a/include/linux/blkdev.h +++ b/include/linux/blkdev.h | |||
@@ -827,7 +827,6 @@ extern bool __blk_end_request_err(struct request *rq, int error); | |||
827 | extern void blk_complete_request(struct request *); | 827 | extern void blk_complete_request(struct request *); |
828 | extern void __blk_complete_request(struct request *); | 828 | extern void __blk_complete_request(struct request *); |
829 | extern void blk_abort_request(struct request *); | 829 | extern void blk_abort_request(struct request *); |
830 | extern void blk_abort_queue(struct request_queue *); | ||
831 | extern void blk_unprep_request(struct request *); | 830 | extern void blk_unprep_request(struct request *); |
832 | 831 | ||
833 | /* | 832 | /* |
diff --git a/include/linux/bootmem.h b/include/linux/bootmem.h index 324fe08ea3b1..6d6795d46a75 100644 --- a/include/linux/bootmem.h +++ b/include/linux/bootmem.h | |||
@@ -91,6 +91,11 @@ extern void *__alloc_bootmem_node_nopanic(pg_data_t *pgdat, | |||
91 | unsigned long size, | 91 | unsigned long size, |
92 | unsigned long align, | 92 | unsigned long align, |
93 | unsigned long goal); | 93 | unsigned long goal); |
94 | void *___alloc_bootmem_node_nopanic(pg_data_t *pgdat, | ||
95 | unsigned long size, | ||
96 | unsigned long align, | ||
97 | unsigned long goal, | ||
98 | unsigned long limit); | ||
94 | extern void *__alloc_bootmem_low(unsigned long size, | 99 | extern void *__alloc_bootmem_low(unsigned long size, |
95 | unsigned long align, | 100 | unsigned long align, |
96 | unsigned long goal); | 101 | unsigned long goal); |
diff --git a/include/linux/gpio.h b/include/linux/gpio.h index f07fc2d08159..2e31e8b3a190 100644 --- a/include/linux/gpio.h +++ b/include/linux/gpio.h | |||
@@ -22,8 +22,8 @@ | |||
22 | /* Gpio pin is open source */ | 22 | /* Gpio pin is open source */ |
23 | #define GPIOF_OPEN_SOURCE (1 << 3) | 23 | #define GPIOF_OPEN_SOURCE (1 << 3) |
24 | 24 | ||
25 | #define GPIOF_EXPORT (1 << 2) | 25 | #define GPIOF_EXPORT (1 << 4) |
26 | #define GPIOF_EXPORT_CHANGEABLE (1 << 3) | 26 | #define GPIOF_EXPORT_CHANGEABLE (1 << 5) |
27 | #define GPIOF_EXPORT_DIR_FIXED (GPIOF_EXPORT) | 27 | #define GPIOF_EXPORT_DIR_FIXED (GPIOF_EXPORT) |
28 | #define GPIOF_EXPORT_DIR_CHANGEABLE (GPIOF_EXPORT | GPIOF_EXPORT_CHANGEABLE) | 28 | #define GPIOF_EXPORT_DIR_CHANGEABLE (GPIOF_EXPORT | GPIOF_EXPORT_CHANGEABLE) |
29 | 29 | ||
diff --git a/include/linux/hrtimer.h b/include/linux/hrtimer.h index fd0dc30c9f15..cc07d2777bbe 100644 --- a/include/linux/hrtimer.h +++ b/include/linux/hrtimer.h | |||
@@ -165,6 +165,7 @@ enum hrtimer_base_type { | |||
165 | * @lock: lock protecting the base and associated clock bases | 165 | * @lock: lock protecting the base and associated clock bases |
166 | * and timers | 166 | * and timers |
167 | * @active_bases: Bitfield to mark bases with active timers | 167 | * @active_bases: Bitfield to mark bases with active timers |
168 | * @clock_was_set: Indicates that clock was set from irq context. | ||
168 | * @expires_next: absolute time of the next event which was scheduled | 169 | * @expires_next: absolute time of the next event which was scheduled |
169 | * via clock_set_next_event() | 170 | * via clock_set_next_event() |
170 | * @hres_active: State of high resolution mode | 171 | * @hres_active: State of high resolution mode |
@@ -177,7 +178,8 @@ enum hrtimer_base_type { | |||
177 | */ | 178 | */ |
178 | struct hrtimer_cpu_base { | 179 | struct hrtimer_cpu_base { |
179 | raw_spinlock_t lock; | 180 | raw_spinlock_t lock; |
180 | unsigned long active_bases; | 181 | unsigned int active_bases; |
182 | unsigned int clock_was_set; | ||
181 | #ifdef CONFIG_HIGH_RES_TIMERS | 183 | #ifdef CONFIG_HIGH_RES_TIMERS |
182 | ktime_t expires_next; | 184 | ktime_t expires_next; |
183 | int hres_active; | 185 | int hres_active; |
@@ -286,6 +288,8 @@ extern void hrtimer_peek_ahead_timers(void); | |||
286 | # define MONOTONIC_RES_NSEC HIGH_RES_NSEC | 288 | # define MONOTONIC_RES_NSEC HIGH_RES_NSEC |
287 | # define KTIME_MONOTONIC_RES KTIME_HIGH_RES | 289 | # define KTIME_MONOTONIC_RES KTIME_HIGH_RES |
288 | 290 | ||
291 | extern void clock_was_set_delayed(void); | ||
292 | |||
289 | #else | 293 | #else |
290 | 294 | ||
291 | # define MONOTONIC_RES_NSEC LOW_RES_NSEC | 295 | # define MONOTONIC_RES_NSEC LOW_RES_NSEC |
@@ -306,6 +310,9 @@ static inline int hrtimer_is_hres_active(struct hrtimer *timer) | |||
306 | { | 310 | { |
307 | return 0; | 311 | return 0; |
308 | } | 312 | } |
313 | |||
314 | static inline void clock_was_set_delayed(void) { } | ||
315 | |||
309 | #endif | 316 | #endif |
310 | 317 | ||
311 | extern void clock_was_set(void); | 318 | extern void clock_was_set(void); |
@@ -320,6 +327,7 @@ extern ktime_t ktime_get(void); | |||
320 | extern ktime_t ktime_get_real(void); | 327 | extern ktime_t ktime_get_real(void); |
321 | extern ktime_t ktime_get_boottime(void); | 328 | extern ktime_t ktime_get_boottime(void); |
322 | extern ktime_t ktime_get_monotonic_offset(void); | 329 | extern ktime_t ktime_get_monotonic_offset(void); |
330 | extern ktime_t ktime_get_update_offsets(ktime_t *offs_real, ktime_t *offs_boot); | ||
323 | 331 | ||
324 | DECLARE_PER_CPU(struct tick_device, tick_cpu_device); | 332 | DECLARE_PER_CPU(struct tick_device, tick_cpu_device); |
325 | 333 | ||
diff --git a/include/linux/input.h b/include/linux/input.h index a81671453575..2740d080ec6b 100644 --- a/include/linux/input.h +++ b/include/linux/input.h | |||
@@ -116,6 +116,7 @@ struct input_keymap_entry { | |||
116 | 116 | ||
117 | /** | 117 | /** |
118 | * EVIOCGMTSLOTS(len) - get MT slot values | 118 | * EVIOCGMTSLOTS(len) - get MT slot values |
119 | * @len: size of the data buffer in bytes | ||
119 | * | 120 | * |
120 | * The ioctl buffer argument should be binary equivalent to | 121 | * The ioctl buffer argument should be binary equivalent to |
121 | * | 122 | * |
diff --git a/include/linux/kvm_host.h b/include/linux/kvm_host.h index c4464356b35b..96c158a37d3e 100644 --- a/include/linux/kvm_host.h +++ b/include/linux/kvm_host.h | |||
@@ -815,7 +815,7 @@ static inline void kvm_free_irq_routing(struct kvm *kvm) {} | |||
815 | #ifdef CONFIG_HAVE_KVM_EVENTFD | 815 | #ifdef CONFIG_HAVE_KVM_EVENTFD |
816 | 816 | ||
817 | void kvm_eventfd_init(struct kvm *kvm); | 817 | void kvm_eventfd_init(struct kvm *kvm); |
818 | int kvm_irqfd(struct kvm *kvm, int fd, int gsi, int flags); | 818 | int kvm_irqfd(struct kvm *kvm, struct kvm_irqfd *args); |
819 | void kvm_irqfd_release(struct kvm *kvm); | 819 | void kvm_irqfd_release(struct kvm *kvm); |
820 | void kvm_irq_routing_update(struct kvm *, struct kvm_irq_routing_table *); | 820 | void kvm_irq_routing_update(struct kvm *, struct kvm_irq_routing_table *); |
821 | int kvm_ioeventfd(struct kvm *kvm, struct kvm_ioeventfd *args); | 821 | int kvm_ioeventfd(struct kvm *kvm, struct kvm_ioeventfd *args); |
@@ -824,7 +824,7 @@ int kvm_ioeventfd(struct kvm *kvm, struct kvm_ioeventfd *args); | |||
824 | 824 | ||
825 | static inline void kvm_eventfd_init(struct kvm *kvm) {} | 825 | static inline void kvm_eventfd_init(struct kvm *kvm) {} |
826 | 826 | ||
827 | static inline int kvm_irqfd(struct kvm *kvm, int fd, int gsi, int flags) | 827 | static inline int kvm_irqfd(struct kvm *kvm, struct kvm_irqfd *args) |
828 | { | 828 | { |
829 | return -EINVAL; | 829 | return -EINVAL; |
830 | } | 830 | } |
diff --git a/include/linux/memblock.h b/include/linux/memblock.h index a6bb10235148..19dc455b4f3d 100644 --- a/include/linux/memblock.h +++ b/include/linux/memblock.h | |||
@@ -50,9 +50,7 @@ phys_addr_t memblock_find_in_range_node(phys_addr_t start, phys_addr_t end, | |||
50 | phys_addr_t size, phys_addr_t align, int nid); | 50 | phys_addr_t size, phys_addr_t align, int nid); |
51 | phys_addr_t memblock_find_in_range(phys_addr_t start, phys_addr_t end, | 51 | phys_addr_t memblock_find_in_range(phys_addr_t start, phys_addr_t end, |
52 | phys_addr_t size, phys_addr_t align); | 52 | phys_addr_t size, phys_addr_t align); |
53 | int memblock_free_reserved_regions(void); | 53 | phys_addr_t get_allocated_memblock_reserved_regions_info(phys_addr_t *addr); |
54 | int memblock_reserve_reserved_regions(void); | ||
55 | |||
56 | void memblock_allow_resize(void); | 54 | void memblock_allow_resize(void); |
57 | int memblock_add_node(phys_addr_t base, phys_addr_t size, int nid); | 55 | int memblock_add_node(phys_addr_t base, phys_addr_t size, int nid); |
58 | int memblock_add(phys_addr_t base, phys_addr_t size); | 56 | int memblock_add(phys_addr_t base, phys_addr_t size); |
diff --git a/include/linux/mfd/s5m87xx/s5m-core.h b/include/linux/mfd/s5m87xx/s5m-core.h index 21603b42f22f..0b2e0ed309f5 100644 --- a/include/linux/mfd/s5m87xx/s5m-core.h +++ b/include/linux/mfd/s5m87xx/s5m-core.h | |||
@@ -347,6 +347,7 @@ struct s5m_platform_data { | |||
347 | bool buck_voltage_lock; | 347 | bool buck_voltage_lock; |
348 | 348 | ||
349 | int buck_gpios[3]; | 349 | int buck_gpios[3]; |
350 | int buck_ds[3]; | ||
350 | int buck2_voltage[8]; | 351 | int buck2_voltage[8]; |
351 | bool buck2_gpiodvs; | 352 | bool buck2_gpiodvs; |
352 | int buck3_voltage[8]; | 353 | int buck3_voltage[8]; |
@@ -369,6 +370,10 @@ struct s5m_platform_data { | |||
369 | bool buck2_ramp_enable; | 370 | bool buck2_ramp_enable; |
370 | bool buck3_ramp_enable; | 371 | bool buck3_ramp_enable; |
371 | bool buck4_ramp_enable; | 372 | bool buck4_ramp_enable; |
373 | |||
374 | int buck2_init; | ||
375 | int buck3_init; | ||
376 | int buck4_init; | ||
372 | }; | 377 | }; |
373 | 378 | ||
374 | #endif /* __LINUX_MFD_S5M_CORE_H */ | 379 | #endif /* __LINUX_MFD_S5M_CORE_H */ |
diff --git a/include/linux/mfd/tps65217.h b/include/linux/mfd/tps65217.h index e030ef9a64ee..12c06870829a 100644 --- a/include/linux/mfd/tps65217.h +++ b/include/linux/mfd/tps65217.h | |||
@@ -217,7 +217,8 @@ enum tps65217_regulator_id { | |||
217 | * Board data may be used to initialize regulator. | 217 | * Board data may be used to initialize regulator. |
218 | */ | 218 | */ |
219 | struct tps65217_board { | 219 | struct tps65217_board { |
220 | struct regulator_init_data *tps65217_init_data; | 220 | struct regulator_init_data *tps65217_init_data[TPS65217_NUM_REGULATOR]; |
221 | struct device_node *of_node[TPS65217_NUM_REGULATOR]; | ||
221 | }; | 222 | }; |
222 | 223 | ||
223 | /** | 224 | /** |
@@ -227,11 +228,6 @@ struct tps65217_board { | |||
227 | * @max_uV: minimum micro volts | 228 | * @max_uV: minimum micro volts |
228 | * @vsel_to_uv: Function pointer to get voltage from selector | 229 | * @vsel_to_uv: Function pointer to get voltage from selector |
229 | * @uv_to_vsel: Function pointer to get selector from voltage | 230 | * @uv_to_vsel: Function pointer to get selector from voltage |
230 | * @table: Table for non-uniform voltage step-size | ||
231 | * @table_len: Length of the voltage table | ||
232 | * @enable_mask: Regulator enable mask bits | ||
233 | * @set_vout_reg: Regulator output voltage set register | ||
234 | * @set_vout_mask: Regulator output voltage set mask | ||
235 | * | 231 | * |
236 | * This data is used to check the regualtor voltage limits while setting. | 232 | * This data is used to check the regualtor voltage limits while setting. |
237 | */ | 233 | */ |
@@ -241,11 +237,6 @@ struct tps_info { | |||
241 | int max_uV; | 237 | int max_uV; |
242 | int (*vsel_to_uv)(unsigned int vsel); | 238 | int (*vsel_to_uv)(unsigned int vsel); |
243 | int (*uv_to_vsel)(int uV, unsigned int *vsel); | 239 | int (*uv_to_vsel)(int uV, unsigned int *vsel); |
244 | const int *table; | ||
245 | unsigned int table_len; | ||
246 | unsigned int enable_mask; | ||
247 | unsigned int set_vout_reg; | ||
248 | unsigned int set_vout_mask; | ||
249 | }; | 240 | }; |
250 | 241 | ||
251 | /** | 242 | /** |
diff --git a/include/linux/mfd/tps65910.h b/include/linux/mfd/tps65910.h index dd8dc0a6c462..6c4c478e21a4 100644 --- a/include/linux/mfd/tps65910.h +++ b/include/linux/mfd/tps65910.h | |||
@@ -880,4 +880,10 @@ static inline int tps65910_reg_clear_bits(struct tps65910 *tps65910, u8 reg, | |||
880 | return regmap_update_bits(tps65910->regmap, reg, mask, 0); | 880 | return regmap_update_bits(tps65910->regmap, reg, mask, 0); |
881 | } | 881 | } |
882 | 882 | ||
883 | static inline int tps65910_reg_update_bits(struct tps65910 *tps65910, u8 reg, | ||
884 | u8 mask, u8 val) | ||
885 | { | ||
886 | return regmap_update_bits(tps65910->regmap, reg, mask, val); | ||
887 | } | ||
888 | |||
883 | #endif /* __LINUX_MFD_TPS65910_H */ | 889 | #endif /* __LINUX_MFD_TPS65910_H */ |
diff --git a/include/linux/mmzone.h b/include/linux/mmzone.h index 2427706f78b4..68c569fcbb66 100644 --- a/include/linux/mmzone.h +++ b/include/linux/mmzone.h | |||
@@ -694,7 +694,7 @@ typedef struct pglist_data { | |||
694 | range, including holes */ | 694 | range, including holes */ |
695 | int node_id; | 695 | int node_id; |
696 | wait_queue_head_t kswapd_wait; | 696 | wait_queue_head_t kswapd_wait; |
697 | struct task_struct *kswapd; | 697 | struct task_struct *kswapd; /* Protected by lock_memory_hotplug() */ |
698 | int kswapd_max_order; | 698 | int kswapd_max_order; |
699 | enum zone_type classzone_idx; | 699 | enum zone_type classzone_idx; |
700 | } pg_data_t; | 700 | } pg_data_t; |
diff --git a/include/linux/pci.h b/include/linux/pci.h index fefb4e19bf6a..d8c379dba6ad 100644 --- a/include/linux/pci.h +++ b/include/linux/pci.h | |||
@@ -176,8 +176,6 @@ enum pci_dev_flags { | |||
176 | PCI_DEV_FLAGS_NO_D3 = (__force pci_dev_flags_t) 2, | 176 | PCI_DEV_FLAGS_NO_D3 = (__force pci_dev_flags_t) 2, |
177 | /* Provide indication device is assigned by a Virtual Machine Manager */ | 177 | /* Provide indication device is assigned by a Virtual Machine Manager */ |
178 | PCI_DEV_FLAGS_ASSIGNED = (__force pci_dev_flags_t) 4, | 178 | PCI_DEV_FLAGS_ASSIGNED = (__force pci_dev_flags_t) 4, |
179 | /* Device causes system crash if in D3 during S3 sleep */ | ||
180 | PCI_DEV_FLAGS_NO_D3_DURING_SLEEP = (__force pci_dev_flags_t) 8, | ||
181 | }; | 179 | }; |
182 | 180 | ||
183 | enum pci_irq_reroute_variant { | 181 | enum pci_irq_reroute_variant { |
diff --git a/include/linux/prctl.h b/include/linux/prctl.h index 3988012255dc..289760f424aa 100644 --- a/include/linux/prctl.h +++ b/include/linux/prctl.h | |||
@@ -141,6 +141,8 @@ | |||
141 | * Changing LSM security domain is considered a new privilege. So, for example, | 141 | * Changing LSM security domain is considered a new privilege. So, for example, |
142 | * asking selinux for a specific new context (e.g. with runcon) will result | 142 | * asking selinux for a specific new context (e.g. with runcon) will result |
143 | * in execve returning -EPERM. | 143 | * in execve returning -EPERM. |
144 | * | ||
145 | * See Documentation/prctl/no_new_privs.txt for more details. | ||
144 | */ | 146 | */ |
145 | #define PR_SET_NO_NEW_PRIVS 38 | 147 | #define PR_SET_NO_NEW_PRIVS 38 |
146 | #define PR_GET_NO_NEW_PRIVS 39 | 148 | #define PR_GET_NO_NEW_PRIVS 39 |
diff --git a/include/linux/rcupdate.h b/include/linux/rcupdate.h index 26d1a47591f1..9cac722b169c 100644 --- a/include/linux/rcupdate.h +++ b/include/linux/rcupdate.h | |||
@@ -184,7 +184,6 @@ static inline int rcu_preempt_depth(void) | |||
184 | /* Internal to kernel */ | 184 | /* Internal to kernel */ |
185 | extern void rcu_sched_qs(int cpu); | 185 | extern void rcu_sched_qs(int cpu); |
186 | extern void rcu_bh_qs(int cpu); | 186 | extern void rcu_bh_qs(int cpu); |
187 | extern void rcu_preempt_note_context_switch(void); | ||
188 | extern void rcu_check_callbacks(int cpu, int user); | 187 | extern void rcu_check_callbacks(int cpu, int user); |
189 | struct notifier_block; | 188 | struct notifier_block; |
190 | extern void rcu_idle_enter(void); | 189 | extern void rcu_idle_enter(void); |
diff --git a/include/linux/rcutiny.h b/include/linux/rcutiny.h index 854dc4c5c271..4e56a9c69a35 100644 --- a/include/linux/rcutiny.h +++ b/include/linux/rcutiny.h | |||
@@ -87,6 +87,10 @@ static inline void kfree_call_rcu(struct rcu_head *head, | |||
87 | 87 | ||
88 | #ifdef CONFIG_TINY_RCU | 88 | #ifdef CONFIG_TINY_RCU |
89 | 89 | ||
90 | static inline void rcu_preempt_note_context_switch(void) | ||
91 | { | ||
92 | } | ||
93 | |||
90 | static inline int rcu_needs_cpu(int cpu, unsigned long *delta_jiffies) | 94 | static inline int rcu_needs_cpu(int cpu, unsigned long *delta_jiffies) |
91 | { | 95 | { |
92 | *delta_jiffies = ULONG_MAX; | 96 | *delta_jiffies = ULONG_MAX; |
@@ -95,6 +99,7 @@ static inline int rcu_needs_cpu(int cpu, unsigned long *delta_jiffies) | |||
95 | 99 | ||
96 | #else /* #ifdef CONFIG_TINY_RCU */ | 100 | #else /* #ifdef CONFIG_TINY_RCU */ |
97 | 101 | ||
102 | void rcu_preempt_note_context_switch(void); | ||
98 | int rcu_preempt_needs_cpu(void); | 103 | int rcu_preempt_needs_cpu(void); |
99 | 104 | ||
100 | static inline int rcu_needs_cpu(int cpu, unsigned long *delta_jiffies) | 105 | static inline int rcu_needs_cpu(int cpu, unsigned long *delta_jiffies) |
@@ -108,6 +113,7 @@ static inline int rcu_needs_cpu(int cpu, unsigned long *delta_jiffies) | |||
108 | static inline void rcu_note_context_switch(int cpu) | 113 | static inline void rcu_note_context_switch(int cpu) |
109 | { | 114 | { |
110 | rcu_sched_qs(cpu); | 115 | rcu_sched_qs(cpu); |
116 | rcu_preempt_note_context_switch(); | ||
111 | } | 117 | } |
112 | 118 | ||
113 | /* | 119 | /* |
diff --git a/include/linux/regulator/driver.h b/include/linux/regulator/driver.h index 2513a54ca2e8..bac4c871f3bd 100644 --- a/include/linux/regulator/driver.h +++ b/include/linux/regulator/driver.h | |||
@@ -69,6 +69,8 @@ enum regulator_status { | |||
69 | * | 69 | * |
70 | * @enable_time: Time taken for the regulator voltage output voltage to | 70 | * @enable_time: Time taken for the regulator voltage output voltage to |
71 | * stabilise after being enabled, in microseconds. | 71 | * stabilise after being enabled, in microseconds. |
72 | * @set_ramp_delay: Set the ramp delay for the regulator. The driver should | ||
73 | * select ramp delay equal to or less than(closest) ramp_delay. | ||
72 | * @set_voltage_time_sel: Time taken for the regulator voltage output voltage | 74 | * @set_voltage_time_sel: Time taken for the regulator voltage output voltage |
73 | * to stabilise after being set to a new value, in microseconds. | 75 | * to stabilise after being set to a new value, in microseconds. |
74 | * The function provides the from and to voltage selector, the | 76 | * The function provides the from and to voltage selector, the |
@@ -115,6 +117,7 @@ struct regulator_ops { | |||
115 | 117 | ||
116 | /* Time taken to enable or set voltage on the regulator */ | 118 | /* Time taken to enable or set voltage on the regulator */ |
117 | int (*enable_time) (struct regulator_dev *); | 119 | int (*enable_time) (struct regulator_dev *); |
120 | int (*set_ramp_delay) (struct regulator_dev *, int ramp_delay); | ||
118 | int (*set_voltage_time_sel) (struct regulator_dev *, | 121 | int (*set_voltage_time_sel) (struct regulator_dev *, |
119 | unsigned int old_selector, | 122 | unsigned int old_selector, |
120 | unsigned int new_selector); | 123 | unsigned int new_selector); |
@@ -172,12 +175,15 @@ enum regulator_type { | |||
172 | * | 175 | * |
173 | * @min_uV: Voltage given by the lowest selector (if linear mapping) | 176 | * @min_uV: Voltage given by the lowest selector (if linear mapping) |
174 | * @uV_step: Voltage increase with each selector (if linear mapping) | 177 | * @uV_step: Voltage increase with each selector (if linear mapping) |
178 | * @ramp_delay: Time to settle down after voltage change (unit: uV/us) | ||
175 | * @volt_table: Voltage mapping table (if table based mapping) | 179 | * @volt_table: Voltage mapping table (if table based mapping) |
176 | * | 180 | * |
177 | * @vsel_reg: Register for selector when using regulator_regmap_X_voltage_ | 181 | * @vsel_reg: Register for selector when using regulator_regmap_X_voltage_ |
178 | * @vsel_mask: Mask for register bitfield used for selector | 182 | * @vsel_mask: Mask for register bitfield used for selector |
179 | * @enable_reg: Register for control when using regmap enable/disable ops | 183 | * @enable_reg: Register for control when using regmap enable/disable ops |
180 | * @enable_mask: Mask for control when using regmap enable/disable ops | 184 | * @enable_mask: Mask for control when using regmap enable/disable ops |
185 | * | ||
186 | * @enable_time: Time taken for initial enable of regulator (in uS). | ||
181 | */ | 187 | */ |
182 | struct regulator_desc { | 188 | struct regulator_desc { |
183 | const char *name; | 189 | const char *name; |
@@ -191,6 +197,7 @@ struct regulator_desc { | |||
191 | 197 | ||
192 | unsigned int min_uV; | 198 | unsigned int min_uV; |
193 | unsigned int uV_step; | 199 | unsigned int uV_step; |
200 | unsigned int ramp_delay; | ||
194 | 201 | ||
195 | const unsigned int *volt_table; | 202 | const unsigned int *volt_table; |
196 | 203 | ||
@@ -198,6 +205,8 @@ struct regulator_desc { | |||
198 | unsigned int vsel_mask; | 205 | unsigned int vsel_mask; |
199 | unsigned int enable_reg; | 206 | unsigned int enable_reg; |
200 | unsigned int enable_mask; | 207 | unsigned int enable_mask; |
208 | |||
209 | unsigned int enable_time; | ||
201 | }; | 210 | }; |
202 | 211 | ||
203 | /** | 212 | /** |
@@ -213,6 +222,9 @@ struct regulator_desc { | |||
213 | * @of_node: OpenFirmware node to parse for device tree bindings (may be | 222 | * @of_node: OpenFirmware node to parse for device tree bindings (may be |
214 | * NULL). | 223 | * NULL). |
215 | * @regmap: regmap to use for core regmap helpers | 224 | * @regmap: regmap to use for core regmap helpers |
225 | * @ena_gpio: GPIO controlling regulator enable. | ||
226 | * @ena_gpio_invert: Sense for GPIO enable control. | ||
227 | * @ena_gpio_flags: Flags to use when calling gpio_request_one() | ||
216 | */ | 228 | */ |
217 | struct regulator_config { | 229 | struct regulator_config { |
218 | struct device *dev; | 230 | struct device *dev; |
@@ -220,6 +232,10 @@ struct regulator_config { | |||
220 | void *driver_data; | 232 | void *driver_data; |
221 | struct device_node *of_node; | 233 | struct device_node *of_node; |
222 | struct regmap *regmap; | 234 | struct regmap *regmap; |
235 | |||
236 | int ena_gpio; | ||
237 | unsigned int ena_gpio_invert:1; | ||
238 | unsigned int ena_gpio_flags; | ||
223 | }; | 239 | }; |
224 | 240 | ||
225 | /* | 241 | /* |
@@ -258,6 +274,10 @@ struct regulator_dev { | |||
258 | void *reg_data; /* regulator_dev data */ | 274 | void *reg_data; /* regulator_dev data */ |
259 | 275 | ||
260 | struct dentry *debugfs; | 276 | struct dentry *debugfs; |
277 | |||
278 | int ena_gpio; | ||
279 | unsigned int ena_gpio_invert:1; | ||
280 | unsigned int ena_gpio_state:1; | ||
261 | }; | 281 | }; |
262 | 282 | ||
263 | struct regulator_dev * | 283 | struct regulator_dev * |
@@ -287,6 +307,9 @@ int regulator_set_voltage_sel_regmap(struct regulator_dev *rdev, unsigned sel); | |||
287 | int regulator_is_enabled_regmap(struct regulator_dev *rdev); | 307 | int regulator_is_enabled_regmap(struct regulator_dev *rdev); |
288 | int regulator_enable_regmap(struct regulator_dev *rdev); | 308 | int regulator_enable_regmap(struct regulator_dev *rdev); |
289 | int regulator_disable_regmap(struct regulator_dev *rdev); | 309 | int regulator_disable_regmap(struct regulator_dev *rdev); |
310 | int regulator_set_voltage_time_sel(struct regulator_dev *rdev, | ||
311 | unsigned int old_selector, | ||
312 | unsigned int new_selector); | ||
290 | 313 | ||
291 | void *regulator_get_init_drvdata(struct regulator_init_data *reg_init_data); | 314 | void *regulator_get_init_drvdata(struct regulator_init_data *reg_init_data); |
292 | 315 | ||
diff --git a/include/linux/regulator/fixed.h b/include/linux/regulator/fixed.h index 680f24e08af2..48918be649d4 100644 --- a/include/linux/regulator/fixed.h +++ b/include/linux/regulator/fixed.h | |||
@@ -22,6 +22,7 @@ struct regulator_init_data; | |||
22 | /** | 22 | /** |
23 | * struct fixed_voltage_config - fixed_voltage_config structure | 23 | * struct fixed_voltage_config - fixed_voltage_config structure |
24 | * @supply_name: Name of the regulator supply | 24 | * @supply_name: Name of the regulator supply |
25 | * @input_supply: Name of the input regulator supply | ||
25 | * @microvolts: Output voltage of regulator | 26 | * @microvolts: Output voltage of regulator |
26 | * @gpio: GPIO to use for enable control | 27 | * @gpio: GPIO to use for enable control |
27 | * set to -EINVAL if not used | 28 | * set to -EINVAL if not used |
@@ -46,6 +47,7 @@ struct regulator_init_data; | |||
46 | */ | 47 | */ |
47 | struct fixed_voltage_config { | 48 | struct fixed_voltage_config { |
48 | const char *supply_name; | 49 | const char *supply_name; |
50 | const char *input_supply; | ||
49 | int microvolts; | 51 | int microvolts; |
50 | int gpio; | 52 | int gpio; |
51 | unsigned startup_delay; | 53 | unsigned startup_delay; |
diff --git a/include/linux/regulator/lp872x.h b/include/linux/regulator/lp872x.h new file mode 100644 index 000000000000..132e05c46661 --- /dev/null +++ b/include/linux/regulator/lp872x.h | |||
@@ -0,0 +1,90 @@ | |||
1 | /* | ||
2 | * Copyright 2012 Texas Instruments | ||
3 | * | ||
4 | * Author: Milo(Woogyom) Kim <milo.kim@ti.com> | ||
5 | * | ||
6 | * This program is free software; you can redistribute it and/or modify | ||
7 | * it under the terms of the GNU General Public License version 2 as | ||
8 | * published by the Free Software Foundation. | ||
9 | * | ||
10 | */ | ||
11 | |||
12 | #ifndef __LP872X_REGULATOR_H__ | ||
13 | #define __LP872X_REGULATOR_H__ | ||
14 | |||
15 | #include <linux/regulator/machine.h> | ||
16 | #include <linux/platform_device.h> | ||
17 | #include <linux/gpio.h> | ||
18 | |||
19 | #define LP872X_MAX_REGULATORS 9 | ||
20 | |||
21 | enum lp872x_regulator_id { | ||
22 | LP8720_ID_BASE, | ||
23 | LP8720_ID_LDO1 = LP8720_ID_BASE, | ||
24 | LP8720_ID_LDO2, | ||
25 | LP8720_ID_LDO3, | ||
26 | LP8720_ID_LDO4, | ||
27 | LP8720_ID_LDO5, | ||
28 | LP8720_ID_BUCK, | ||
29 | |||
30 | LP8725_ID_BASE, | ||
31 | LP8725_ID_LDO1 = LP8725_ID_BASE, | ||
32 | LP8725_ID_LDO2, | ||
33 | LP8725_ID_LDO3, | ||
34 | LP8725_ID_LDO4, | ||
35 | LP8725_ID_LDO5, | ||
36 | LP8725_ID_LILO1, | ||
37 | LP8725_ID_LILO2, | ||
38 | LP8725_ID_BUCK1, | ||
39 | LP8725_ID_BUCK2, | ||
40 | |||
41 | LP872X_ID_MAX, | ||
42 | }; | ||
43 | |||
44 | enum lp872x_dvs_state { | ||
45 | DVS_LOW = GPIOF_OUT_INIT_LOW, | ||
46 | DVS_HIGH = GPIOF_OUT_INIT_HIGH, | ||
47 | }; | ||
48 | |||
49 | enum lp872x_dvs_sel { | ||
50 | SEL_V1, | ||
51 | SEL_V2, | ||
52 | }; | ||
53 | |||
54 | /** | ||
55 | * lp872x_dvs | ||
56 | * @gpio : gpio pin number for dvs control | ||
57 | * @vsel : dvs selector for buck v1 or buck v2 register | ||
58 | * @init_state : initial dvs pin state | ||
59 | */ | ||
60 | struct lp872x_dvs { | ||
61 | int gpio; | ||
62 | enum lp872x_dvs_sel vsel; | ||
63 | enum lp872x_dvs_state init_state; | ||
64 | }; | ||
65 | |||
66 | /** | ||
67 | * lp872x_regdata | ||
68 | * @id : regulator id | ||
69 | * @init_data : init data for each regulator | ||
70 | */ | ||
71 | struct lp872x_regulator_data { | ||
72 | enum lp872x_regulator_id id; | ||
73 | struct regulator_init_data *init_data; | ||
74 | }; | ||
75 | |||
76 | /** | ||
77 | * lp872x_platform_data | ||
78 | * @general_config : the value of LP872X_GENERAL_CFG register | ||
79 | * @update_config : if LP872X_GENERAL_CFG register is updated, set true | ||
80 | * @regulator_data : platform regulator id and init data | ||
81 | * @dvs : dvs data for buck voltage control | ||
82 | */ | ||
83 | struct lp872x_platform_data { | ||
84 | u8 general_config; | ||
85 | bool update_config; | ||
86 | struct lp872x_regulator_data regulator_data[LP872X_MAX_REGULATORS]; | ||
87 | struct lp872x_dvs *dvs; | ||
88 | }; | ||
89 | |||
90 | #endif | ||
diff --git a/include/linux/regulator/machine.h b/include/linux/regulator/machine.h index b02108446be7..40dd0a394cfa 100644 --- a/include/linux/regulator/machine.h +++ b/include/linux/regulator/machine.h | |||
@@ -92,6 +92,7 @@ struct regulator_state { | |||
92 | * mode. | 92 | * mode. |
93 | * @initial_state: Suspend state to set by default. | 93 | * @initial_state: Suspend state to set by default. |
94 | * @initial_mode: Mode to set at startup. | 94 | * @initial_mode: Mode to set at startup. |
95 | * @ramp_delay: Time to settle down after voltage change (unit: uV/us) | ||
95 | */ | 96 | */ |
96 | struct regulation_constraints { | 97 | struct regulation_constraints { |
97 | 98 | ||
@@ -125,6 +126,8 @@ struct regulation_constraints { | |||
125 | /* mode to set on startup */ | 126 | /* mode to set on startup */ |
126 | unsigned int initial_mode; | 127 | unsigned int initial_mode; |
127 | 128 | ||
129 | unsigned int ramp_delay; | ||
130 | |||
128 | /* constraint flags */ | 131 | /* constraint flags */ |
129 | unsigned always_on:1; /* regulator never off when system is on */ | 132 | unsigned always_on:1; /* regulator never off when system is on */ |
130 | unsigned boot_on:1; /* bootloader/firmware enabled regulator */ | 133 | unsigned boot_on:1; /* bootloader/firmware enabled regulator */ |
diff --git a/include/linux/rpmsg.h b/include/linux/rpmsg.h index a8e50e44203c..82a673905edb 100644 --- a/include/linux/rpmsg.h +++ b/include/linux/rpmsg.h | |||
@@ -38,6 +38,8 @@ | |||
38 | #include <linux/types.h> | 38 | #include <linux/types.h> |
39 | #include <linux/device.h> | 39 | #include <linux/device.h> |
40 | #include <linux/mod_devicetable.h> | 40 | #include <linux/mod_devicetable.h> |
41 | #include <linux/kref.h> | ||
42 | #include <linux/mutex.h> | ||
41 | 43 | ||
42 | /* The feature bitmap for virtio rpmsg */ | 44 | /* The feature bitmap for virtio rpmsg */ |
43 | #define VIRTIO_RPMSG_F_NS 0 /* RP supports name service notifications */ | 45 | #define VIRTIO_RPMSG_F_NS 0 /* RP supports name service notifications */ |
@@ -120,7 +122,9 @@ typedef void (*rpmsg_rx_cb_t)(struct rpmsg_channel *, void *, int, void *, u32); | |||
120 | /** | 122 | /** |
121 | * struct rpmsg_endpoint - binds a local rpmsg address to its user | 123 | * struct rpmsg_endpoint - binds a local rpmsg address to its user |
122 | * @rpdev: rpmsg channel device | 124 | * @rpdev: rpmsg channel device |
125 | * @refcount: when this drops to zero, the ept is deallocated | ||
123 | * @cb: rx callback handler | 126 | * @cb: rx callback handler |
127 | * @cb_lock: must be taken before accessing/changing @cb | ||
124 | * @addr: local rpmsg address | 128 | * @addr: local rpmsg address |
125 | * @priv: private data for the driver's use | 129 | * @priv: private data for the driver's use |
126 | * | 130 | * |
@@ -140,7 +144,9 @@ typedef void (*rpmsg_rx_cb_t)(struct rpmsg_channel *, void *, int, void *, u32); | |||
140 | */ | 144 | */ |
141 | struct rpmsg_endpoint { | 145 | struct rpmsg_endpoint { |
142 | struct rpmsg_channel *rpdev; | 146 | struct rpmsg_channel *rpdev; |
147 | struct kref refcount; | ||
143 | rpmsg_rx_cb_t cb; | 148 | rpmsg_rx_cb_t cb; |
149 | struct mutex cb_lock; | ||
144 | u32 addr; | 150 | u32 addr; |
145 | void *priv; | 151 | void *priv; |
146 | }; | 152 | }; |
diff --git a/include/linux/sched.h b/include/linux/sched.h index 4059c0f33f07..4a1f493e0fef 100644 --- a/include/linux/sched.h +++ b/include/linux/sched.h | |||
@@ -1871,22 +1871,12 @@ static inline void rcu_copy_process(struct task_struct *p) | |||
1871 | INIT_LIST_HEAD(&p->rcu_node_entry); | 1871 | INIT_LIST_HEAD(&p->rcu_node_entry); |
1872 | } | 1872 | } |
1873 | 1873 | ||
1874 | static inline void rcu_switch_from(struct task_struct *prev) | ||
1875 | { | ||
1876 | if (prev->rcu_read_lock_nesting != 0) | ||
1877 | rcu_preempt_note_context_switch(); | ||
1878 | } | ||
1879 | |||
1880 | #else | 1874 | #else |
1881 | 1875 | ||
1882 | static inline void rcu_copy_process(struct task_struct *p) | 1876 | static inline void rcu_copy_process(struct task_struct *p) |
1883 | { | 1877 | { |
1884 | } | 1878 | } |
1885 | 1879 | ||
1886 | static inline void rcu_switch_from(struct task_struct *prev) | ||
1887 | { | ||
1888 | } | ||
1889 | |||
1890 | #endif | 1880 | #endif |
1891 | 1881 | ||
1892 | #ifdef CONFIG_SMP | 1882 | #ifdef CONFIG_SMP |
@@ -1909,6 +1899,14 @@ static inline int set_cpus_allowed_ptr(struct task_struct *p, | |||
1909 | } | 1899 | } |
1910 | #endif | 1900 | #endif |
1911 | 1901 | ||
1902 | #ifdef CONFIG_NO_HZ | ||
1903 | void calc_load_enter_idle(void); | ||
1904 | void calc_load_exit_idle(void); | ||
1905 | #else | ||
1906 | static inline void calc_load_enter_idle(void) { } | ||
1907 | static inline void calc_load_exit_idle(void) { } | ||
1908 | #endif /* CONFIG_NO_HZ */ | ||
1909 | |||
1912 | #ifndef CONFIG_CPUMASK_OFFSTACK | 1910 | #ifndef CONFIG_CPUMASK_OFFSTACK |
1913 | static inline int set_cpus_allowed(struct task_struct *p, cpumask_t new_mask) | 1911 | static inline int set_cpus_allowed(struct task_struct *p, cpumask_t new_mask) |
1914 | { | 1912 | { |
diff --git a/include/linux/splice.h b/include/linux/splice.h index 26e5b613deda..09a545a7dfa3 100644 --- a/include/linux/splice.h +++ b/include/linux/splice.h | |||
@@ -51,7 +51,8 @@ struct partial_page { | |||
51 | struct splice_pipe_desc { | 51 | struct splice_pipe_desc { |
52 | struct page **pages; /* page map */ | 52 | struct page **pages; /* page map */ |
53 | struct partial_page *partial; /* pages[] may not be contig */ | 53 | struct partial_page *partial; /* pages[] may not be contig */ |
54 | int nr_pages; /* number of pages in map */ | 54 | int nr_pages; /* number of populated pages in map */ |
55 | unsigned int nr_pages_max; /* pages[] & partial[] arrays size */ | ||
55 | unsigned int flags; /* splice flags */ | 56 | unsigned int flags; /* splice flags */ |
56 | const struct pipe_buf_operations *ops;/* ops associated with output pipe */ | 57 | const struct pipe_buf_operations *ops;/* ops associated with output pipe */ |
57 | void (*spd_release)(struct splice_pipe_desc *, unsigned int); | 58 | void (*spd_release)(struct splice_pipe_desc *, unsigned int); |
@@ -85,9 +86,8 @@ extern ssize_t splice_direct_to_actor(struct file *, struct splice_desc *, | |||
85 | /* | 86 | /* |
86 | * for dynamic pipe sizing | 87 | * for dynamic pipe sizing |
87 | */ | 88 | */ |
88 | extern int splice_grow_spd(struct pipe_inode_info *, struct splice_pipe_desc *); | 89 | extern int splice_grow_spd(const struct pipe_inode_info *, struct splice_pipe_desc *); |
89 | extern void splice_shrink_spd(struct pipe_inode_info *, | 90 | extern void splice_shrink_spd(struct splice_pipe_desc *); |
90 | struct splice_pipe_desc *); | ||
91 | extern void spd_release_page(struct splice_pipe_desc *, unsigned int); | 91 | extern void spd_release_page(struct splice_pipe_desc *, unsigned int); |
92 | 92 | ||
93 | extern const struct pipe_buf_operations page_cache_pipe_buf_ops; | 93 | extern const struct pipe_buf_operations page_cache_pipe_buf_ops; |
diff --git a/include/net/sctp/structs.h b/include/net/sctp/structs.h index e4652fe58958..fecdf31816f2 100644 --- a/include/net/sctp/structs.h +++ b/include/net/sctp/structs.h | |||
@@ -912,6 +912,9 @@ struct sctp_transport { | |||
912 | /* Is this structure kfree()able? */ | 912 | /* Is this structure kfree()able? */ |
913 | malloced:1; | 913 | malloced:1; |
914 | 914 | ||
915 | /* Has this transport moved the ctsn since we last sacked */ | ||
916 | __u32 sack_generation; | ||
917 | |||
915 | struct flowi fl; | 918 | struct flowi fl; |
916 | 919 | ||
917 | /* This is the peer's IP address and port. */ | 920 | /* This is the peer's IP address and port. */ |
@@ -1584,6 +1587,7 @@ struct sctp_association { | |||
1584 | */ | 1587 | */ |
1585 | __u8 sack_needed; /* Do we need to sack the peer? */ | 1588 | __u8 sack_needed; /* Do we need to sack the peer? */ |
1586 | __u32 sack_cnt; | 1589 | __u32 sack_cnt; |
1590 | __u32 sack_generation; | ||
1587 | 1591 | ||
1588 | /* These are capabilities which our peer advertised. */ | 1592 | /* These are capabilities which our peer advertised. */ |
1589 | __u8 ecn_capable:1, /* Can peer do ECN? */ | 1593 | __u8 ecn_capable:1, /* Can peer do ECN? */ |
diff --git a/include/net/sctp/tsnmap.h b/include/net/sctp/tsnmap.h index e7728bc14ccf..2c5d2b4d5d1e 100644 --- a/include/net/sctp/tsnmap.h +++ b/include/net/sctp/tsnmap.h | |||
@@ -117,7 +117,8 @@ void sctp_tsnmap_free(struct sctp_tsnmap *map); | |||
117 | int sctp_tsnmap_check(const struct sctp_tsnmap *, __u32 tsn); | 117 | int sctp_tsnmap_check(const struct sctp_tsnmap *, __u32 tsn); |
118 | 118 | ||
119 | /* Mark this TSN as seen. */ | 119 | /* Mark this TSN as seen. */ |
120 | int sctp_tsnmap_mark(struct sctp_tsnmap *, __u32 tsn); | 120 | int sctp_tsnmap_mark(struct sctp_tsnmap *, __u32 tsn, |
121 | struct sctp_transport *trans); | ||
121 | 122 | ||
122 | /* Mark this TSN and all lower as seen. */ | 123 | /* Mark this TSN and all lower as seen. */ |
123 | void sctp_tsnmap_skip(struct sctp_tsnmap *map, __u32 tsn); | 124 | void sctp_tsnmap_skip(struct sctp_tsnmap *map, __u32 tsn); |
diff --git a/include/scsi/libsas.h b/include/scsi/libsas.h index f4f1c96dca72..10ce74f589c5 100644 --- a/include/scsi/libsas.h +++ b/include/scsi/libsas.h | |||
@@ -163,6 +163,8 @@ enum ata_command_set { | |||
163 | ATAPI_COMMAND_SET = 1, | 163 | ATAPI_COMMAND_SET = 1, |
164 | }; | 164 | }; |
165 | 165 | ||
166 | #define ATA_RESP_FIS_SIZE 24 | ||
167 | |||
166 | struct sata_device { | 168 | struct sata_device { |
167 | enum ata_command_set command_set; | 169 | enum ata_command_set command_set; |
168 | struct smp_resp rps_resp; /* report_phy_sata_resp */ | 170 | struct smp_resp rps_resp; /* report_phy_sata_resp */ |
@@ -171,7 +173,7 @@ struct sata_device { | |||
171 | 173 | ||
172 | struct ata_port *ap; | 174 | struct ata_port *ap; |
173 | struct ata_host ata_host; | 175 | struct ata_host ata_host; |
174 | struct ata_taskfile tf; | 176 | u8 fis[ATA_RESP_FIS_SIZE]; |
175 | }; | 177 | }; |
176 | 178 | ||
177 | enum { | 179 | enum { |
@@ -537,7 +539,7 @@ enum exec_status { | |||
537 | */ | 539 | */ |
538 | struct ata_task_resp { | 540 | struct ata_task_resp { |
539 | u16 frame_len; | 541 | u16 frame_len; |
540 | u8 ending_fis[24]; /* dev to host or data-in */ | 542 | u8 ending_fis[ATA_RESP_FIS_SIZE]; /* dev to host or data-in */ |
541 | }; | 543 | }; |
542 | 544 | ||
543 | #define SAS_STATUS_BUF_SIZE 96 | 545 | #define SAS_STATUS_BUF_SIZE 96 |
diff --git a/include/scsi/scsi_cmnd.h b/include/scsi/scsi_cmnd.h index 1e1198546c72..ac06cc595890 100644 --- a/include/scsi/scsi_cmnd.h +++ b/include/scsi/scsi_cmnd.h | |||
@@ -134,10 +134,16 @@ struct scsi_cmnd { | |||
134 | 134 | ||
135 | static inline struct scsi_driver *scsi_cmd_to_driver(struct scsi_cmnd *cmd) | 135 | static inline struct scsi_driver *scsi_cmd_to_driver(struct scsi_cmnd *cmd) |
136 | { | 136 | { |
137 | struct scsi_driver **sdp; | ||
138 | |||
137 | if (!cmd->request->rq_disk) | 139 | if (!cmd->request->rq_disk) |
138 | return NULL; | 140 | return NULL; |
139 | 141 | ||
140 | return *(struct scsi_driver **)cmd->request->rq_disk->private_data; | 142 | sdp = (struct scsi_driver **)cmd->request->rq_disk->private_data; |
143 | if (!sdp) | ||
144 | return NULL; | ||
145 | |||
146 | return *sdp; | ||
141 | } | 147 | } |
142 | 148 | ||
143 | extern struct scsi_cmnd *scsi_get_command(struct scsi_device *, gfp_t); | 149 | extern struct scsi_cmnd *scsi_get_command(struct scsi_device *, gfp_t); |