Gentoo Archives: gentoo-commits

From: "Mike Pagano (mpagano)" <mpagano@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] linux-patches r2457 - genpatches-2.6/trunk/3.0
Date: Mon, 29 Jul 2013 00:45:20
Message-Id: 20130729004513.C42382171C@flycatcher.gentoo.org
1 Author: mpagano
2 Date: 2013-07-29 00:45:13 +0000 (Mon, 29 Jul 2013)
3 New Revision: 2457
4
5 Added:
6 genpatches-2.6/trunk/3.0/1087_linux-3.0.88.patch
7 Modified:
8 genpatches-2.6/trunk/3.0/0000_README
9 Log:
10 Linux patch 3.0.88
11
12 Modified: genpatches-2.6/trunk/3.0/0000_README
13 ===================================================================
14 --- genpatches-2.6/trunk/3.0/0000_README 2013-07-29 00:42:34 UTC (rev 2456)
15 +++ genpatches-2.6/trunk/3.0/0000_README 2013-07-29 00:45:13 UTC (rev 2457)
16 @@ -383,6 +383,10 @@
17 From: http://www.kernel.org
18 Desc: Linux 3.0.87
19
20 +Patch: 1087_linux-3.0.88.patch
21 +From: http://www.kernel.org
22 +Desc: Linux 3.0.88
23 +
24 Patch: 1500_XATTR_USER_PREFIX.patch
25 From: https://bugs.gentoo.org/show_bug.cgi?id=470644
26 Desc: Support for namespace user.pax.* on tmpfs.
27
28 Added: genpatches-2.6/trunk/3.0/1087_linux-3.0.88.patch
29 ===================================================================
30 --- genpatches-2.6/trunk/3.0/1087_linux-3.0.88.patch (rev 0)
31 +++ genpatches-2.6/trunk/3.0/1087_linux-3.0.88.patch 2013-07-29 00:45:13 UTC (rev 2457)
32 @@ -0,0 +1,1325 @@
33 +diff --git a/Makefile b/Makefile
34 +index 03aa17e..2b40b0a 100644
35 +--- a/Makefile
36 ++++ b/Makefile
37 +@@ -1,6 +1,6 @@
38 + VERSION = 3
39 + PATCHLEVEL = 0
40 +-SUBLEVEL = 87
41 ++SUBLEVEL = 88
42 + EXTRAVERSION =
43 + NAME = Sneaky Weasel
44 +
45 +diff --git a/arch/sparc/kernel/asm-offsets.c b/arch/sparc/kernel/asm-offsets.c
46 +index 68f7e11..ce48203 100644
47 +--- a/arch/sparc/kernel/asm-offsets.c
48 ++++ b/arch/sparc/kernel/asm-offsets.c
49 +@@ -34,6 +34,8 @@ int foo(void)
50 + DEFINE(AOFF_task_thread, offsetof(struct task_struct, thread));
51 + BLANK();
52 + DEFINE(AOFF_mm_context, offsetof(struct mm_struct, context));
53 ++ BLANK();
54 ++ DEFINE(VMA_VM_MM, offsetof(struct vm_area_struct, vm_mm));
55 +
56 + /* DEFINE(NUM_USER_SEGMENTS, TASK_SIZE>>28); */
57 + return 0;
58 +diff --git a/arch/sparc/mm/hypersparc.S b/arch/sparc/mm/hypersparc.S
59 +index 44aad32..969f964 100644
60 +--- a/arch/sparc/mm/hypersparc.S
61 ++++ b/arch/sparc/mm/hypersparc.S
62 +@@ -74,7 +74,7 @@ hypersparc_flush_cache_mm_out:
63 +
64 + /* The things we do for performance... */
65 + hypersparc_flush_cache_range:
66 +- ld [%o0 + 0x0], %o0 /* XXX vma->vm_mm, GROSS XXX */
67 ++ ld [%o0 + VMA_VM_MM], %o0
68 + #ifndef CONFIG_SMP
69 + ld [%o0 + AOFF_mm_context], %g1
70 + cmp %g1, -1
71 +@@ -163,7 +163,7 @@ hypersparc_flush_cache_range_out:
72 + */
73 + /* Verified, my ass... */
74 + hypersparc_flush_cache_page:
75 +- ld [%o0 + 0x0], %o0 /* XXX vma->vm_mm, GROSS XXX */
76 ++ ld [%o0 + VMA_VM_MM], %o0
77 + ld [%o0 + AOFF_mm_context], %g2
78 + #ifndef CONFIG_SMP
79 + cmp %g2, -1
80 +@@ -284,7 +284,7 @@ hypersparc_flush_tlb_mm_out:
81 + sta %g5, [%g1] ASI_M_MMUREGS
82 +
83 + hypersparc_flush_tlb_range:
84 +- ld [%o0 + 0x00], %o0 /* XXX vma->vm_mm GROSS XXX */
85 ++ ld [%o0 + VMA_VM_MM], %o0
86 + mov SRMMU_CTX_REG, %g1
87 + ld [%o0 + AOFF_mm_context], %o3
88 + lda [%g1] ASI_M_MMUREGS, %g5
89 +@@ -307,7 +307,7 @@ hypersparc_flush_tlb_range_out:
90 + sta %g5, [%g1] ASI_M_MMUREGS
91 +
92 + hypersparc_flush_tlb_page:
93 +- ld [%o0 + 0x00], %o0 /* XXX vma->vm_mm GROSS XXX */
94 ++ ld [%o0 + VMA_VM_MM], %o0
95 + mov SRMMU_CTX_REG, %g1
96 + ld [%o0 + AOFF_mm_context], %o3
97 + andn %o1, (PAGE_SIZE - 1), %o1
98 +diff --git a/arch/sparc/mm/init_64.c b/arch/sparc/mm/init_64.c
99 +index 6ff4d78..b4989f9 100644
100 +--- a/arch/sparc/mm/init_64.c
101 ++++ b/arch/sparc/mm/init_64.c
102 +@@ -1071,7 +1071,14 @@ static int __init grab_mblocks(struct mdesc_handle *md)
103 + m->size = *val;
104 + val = mdesc_get_property(md, node,
105 + "address-congruence-offset", NULL);
106 +- m->offset = *val;
107 ++
108 ++ /* The address-congruence-offset property is optional.
109 ++ * Explicity zero it be identifty this.
110 ++ */
111 ++ if (val)
112 ++ m->offset = *val;
113 ++ else
114 ++ m->offset = 0UL;
115 +
116 + numadbg("MBLOCK[%d]: base[%llx] size[%llx] offset[%llx]\n",
117 + count - 1, m->base, m->size, m->offset);
118 +diff --git a/arch/sparc/mm/swift.S b/arch/sparc/mm/swift.S
119 +index c801c39..5d2b88d 100644
120 +--- a/arch/sparc/mm/swift.S
121 ++++ b/arch/sparc/mm/swift.S
122 +@@ -105,7 +105,7 @@ swift_flush_cache_mm_out:
123 +
124 + .globl swift_flush_cache_range
125 + swift_flush_cache_range:
126 +- ld [%o0 + 0x0], %o0 /* XXX vma->vm_mm, GROSS XXX */
127 ++ ld [%o0 + VMA_VM_MM], %o0
128 + sub %o2, %o1, %o2
129 + sethi %hi(4096), %o3
130 + cmp %o2, %o3
131 +@@ -116,7 +116,7 @@ swift_flush_cache_range:
132 +
133 + .globl swift_flush_cache_page
134 + swift_flush_cache_page:
135 +- ld [%o0 + 0x0], %o0 /* XXX vma->vm_mm, GROSS XXX */
136 ++ ld [%o0 + VMA_VM_MM], %o0
137 + 70:
138 + ld [%o0 + AOFF_mm_context], %g2
139 + cmp %g2, -1
140 +@@ -219,7 +219,7 @@ swift_flush_sig_insns:
141 + .globl swift_flush_tlb_range
142 + .globl swift_flush_tlb_all
143 + swift_flush_tlb_range:
144 +- ld [%o0 + 0x00], %o0 /* XXX vma->vm_mm GROSS XXX */
145 ++ ld [%o0 + VMA_VM_MM], %o0
146 + swift_flush_tlb_mm:
147 + ld [%o0 + AOFF_mm_context], %g2
148 + cmp %g2, -1
149 +@@ -233,7 +233,7 @@ swift_flush_tlb_all_out:
150 +
151 + .globl swift_flush_tlb_page
152 + swift_flush_tlb_page:
153 +- ld [%o0 + 0x00], %o0 /* XXX vma->vm_mm GROSS XXX */
154 ++ ld [%o0 + VMA_VM_MM], %o0
155 + mov SRMMU_CTX_REG, %g1
156 + ld [%o0 + AOFF_mm_context], %o3
157 + andn %o1, (PAGE_SIZE - 1), %o1
158 +diff --git a/arch/sparc/mm/tlb.c b/arch/sparc/mm/tlb.c
159 +index afd021e..072f553 100644
160 +--- a/arch/sparc/mm/tlb.c
161 ++++ b/arch/sparc/mm/tlb.c
162 +@@ -115,8 +115,8 @@ no_cache_flush:
163 + }
164 +
165 + if (!tb->active) {
166 +- global_flush_tlb_page(mm, vaddr);
167 + flush_tsb_user_page(mm, vaddr);
168 ++ global_flush_tlb_page(mm, vaddr);
169 + goto out;
170 + }
171 +
172 +diff --git a/arch/sparc/mm/tsunami.S b/arch/sparc/mm/tsunami.S
173 +index 4e55e8f..bf10a34 100644
174 +--- a/arch/sparc/mm/tsunami.S
175 ++++ b/arch/sparc/mm/tsunami.S
176 +@@ -24,7 +24,7 @@
177 + /* Sliiick... */
178 + tsunami_flush_cache_page:
179 + tsunami_flush_cache_range:
180 +- ld [%o0 + 0x0], %o0 /* XXX vma->vm_mm, GROSS XXX */
181 ++ ld [%o0 + VMA_VM_MM], %o0
182 + tsunami_flush_cache_mm:
183 + ld [%o0 + AOFF_mm_context], %g2
184 + cmp %g2, -1
185 +@@ -46,7 +46,7 @@ tsunami_flush_sig_insns:
186 +
187 + /* More slick stuff... */
188 + tsunami_flush_tlb_range:
189 +- ld [%o0 + 0x00], %o0 /* XXX vma->vm_mm GROSS XXX */
190 ++ ld [%o0 + VMA_VM_MM], %o0
191 + tsunami_flush_tlb_mm:
192 + ld [%o0 + AOFF_mm_context], %g2
193 + cmp %g2, -1
194 +@@ -65,7 +65,7 @@ tsunami_flush_tlb_out:
195 +
196 + /* This one can be done in a fine grained manner... */
197 + tsunami_flush_tlb_page:
198 +- ld [%o0 + 0x00], %o0 /* XXX vma->vm_mm GROSS XXX */
199 ++ ld [%o0 + VMA_VM_MM], %o0
200 + mov SRMMU_CTX_REG, %g1
201 + ld [%o0 + AOFF_mm_context], %o3
202 + andn %o1, (PAGE_SIZE - 1), %o1
203 +diff --git a/arch/sparc/mm/viking.S b/arch/sparc/mm/viking.S
204 +index 6dfcc13..a516372 100644
205 +--- a/arch/sparc/mm/viking.S
206 ++++ b/arch/sparc/mm/viking.S
207 +@@ -109,7 +109,7 @@ viking_mxcc_flush_page:
208 + viking_flush_cache_page:
209 + viking_flush_cache_range:
210 + #ifndef CONFIG_SMP
211 +- ld [%o0 + 0x0], %o0 /* XXX vma->vm_mm, GROSS XXX */
212 ++ ld [%o0 + VMA_VM_MM], %o0
213 + #endif
214 + viking_flush_cache_mm:
215 + #ifndef CONFIG_SMP
216 +@@ -149,7 +149,7 @@ viking_flush_tlb_mm:
217 + #endif
218 +
219 + viking_flush_tlb_range:
220 +- ld [%o0 + 0x00], %o0 /* XXX vma->vm_mm GROSS XXX */
221 ++ ld [%o0 + VMA_VM_MM], %o0
222 + mov SRMMU_CTX_REG, %g1
223 + ld [%o0 + AOFF_mm_context], %o3
224 + lda [%g1] ASI_M_MMUREGS, %g5
225 +@@ -174,7 +174,7 @@ viking_flush_tlb_range:
226 + #endif
227 +
228 + viking_flush_tlb_page:
229 +- ld [%o0 + 0x00], %o0 /* XXX vma->vm_mm GROSS XXX */
230 ++ ld [%o0 + VMA_VM_MM], %o0
231 + mov SRMMU_CTX_REG, %g1
232 + ld [%o0 + AOFF_mm_context], %o3
233 + lda [%g1] ASI_M_MMUREGS, %g5
234 +@@ -240,7 +240,7 @@ sun4dsmp_flush_tlb_range:
235 + tst %g5
236 + bne 3f
237 + mov SRMMU_CTX_REG, %g1
238 +- ld [%o0 + 0x00], %o0 /* XXX vma->vm_mm GROSS XXX */
239 ++ ld [%o0 + VMA_VM_MM], %o0
240 + ld [%o0 + AOFF_mm_context], %o3
241 + lda [%g1] ASI_M_MMUREGS, %g5
242 + sethi %hi(~((1 << SRMMU_PGDIR_SHIFT) - 1)), %o4
243 +@@ -266,7 +266,7 @@ sun4dsmp_flush_tlb_page:
244 + tst %g5
245 + bne 2f
246 + mov SRMMU_CTX_REG, %g1
247 +- ld [%o0 + 0x00], %o0 /* XXX vma->vm_mm GROSS XXX */
248 ++ ld [%o0 + VMA_VM_MM], %o0
249 + ld [%o0 + AOFF_mm_context], %o3
250 + lda [%g1] ASI_M_MMUREGS, %g5
251 + and %o1, PAGE_MASK, %o1
252 +diff --git a/drivers/net/dummy.c b/drivers/net/dummy.c
253 +index 098ff31..d74c431 100644
254 +--- a/drivers/net/dummy.c
255 ++++ b/drivers/net/dummy.c
256 +@@ -186,6 +186,8 @@ static int __init dummy_init_module(void)
257 +
258 + rtnl_lock();
259 + err = __rtnl_link_register(&dummy_link_ops);
260 ++ if (err < 0)
261 ++ goto out;
262 +
263 + for (i = 0; i < numdummies && !err; i++) {
264 + err = dummy_init_one();
265 +@@ -193,6 +195,8 @@ static int __init dummy_init_module(void)
266 + }
267 + if (err < 0)
268 + __rtnl_link_unregister(&dummy_link_ops);
269 ++
270 ++out:
271 + rtnl_unlock();
272 +
273 + return err;
274 +diff --git a/drivers/net/ifb.c b/drivers/net/ifb.c
275 +index 2b98461..902ba2f 100644
276 +--- a/drivers/net/ifb.c
277 ++++ b/drivers/net/ifb.c
278 +@@ -33,6 +33,7 @@
279 + #include <linux/etherdevice.h>
280 + #include <linux/init.h>
281 + #include <linux/moduleparam.h>
282 ++#include <linux/sched.h>
283 + #include <net/pkt_sched.h>
284 + #include <net/net_namespace.h>
285 +
286 +@@ -251,11 +252,17 @@ static int __init ifb_init_module(void)
287 +
288 + rtnl_lock();
289 + err = __rtnl_link_register(&ifb_link_ops);
290 ++ if (err < 0)
291 ++ goto out;
292 +
293 +- for (i = 0; i < numifbs && !err; i++)
294 ++ for (i = 0; i < numifbs && !err; i++) {
295 + err = ifb_init_one(i);
296 ++ cond_resched();
297 ++ }
298 + if (err)
299 + __rtnl_link_unregister(&ifb_link_ops);
300 ++
301 ++out:
302 + rtnl_unlock();
303 +
304 + return err;
305 +diff --git a/drivers/net/sunvnet.c b/drivers/net/sunvnet.c
306 +index bf3c762..cc77f70 100644
307 +--- a/drivers/net/sunvnet.c
308 ++++ b/drivers/net/sunvnet.c
309 +@@ -1248,6 +1248,8 @@ static int vnet_port_remove(struct vio_dev *vdev)
310 + dev_set_drvdata(&vdev->dev, NULL);
311 +
312 + kfree(port);
313 ++
314 ++ unregister_netdev(vp->dev);
315 + }
316 + return 0;
317 + }
318 +diff --git a/drivers/net/wireless/rt2x00/rt2800lib.c b/drivers/net/wireless/rt2x00/rt2800lib.c
319 +index d44ce30..9457987 100644
320 +--- a/drivers/net/wireless/rt2x00/rt2800lib.c
321 ++++ b/drivers/net/wireless/rt2x00/rt2800lib.c
322 +@@ -4075,8 +4075,8 @@ int rt2800_probe_hw_mode(struct rt2x00_dev *rt2x00dev)
323 + default_power2 = rt2x00_eeprom_addr(rt2x00dev, EEPROM_TXPOWER_A2);
324 +
325 + for (i = 14; i < spec->num_channels; i++) {
326 +- info[i].default_power1 = default_power1[i];
327 +- info[i].default_power2 = default_power2[i];
328 ++ info[i].default_power1 = default_power1[i - 14];
329 ++ info[i].default_power2 = default_power2[i - 14];
330 + }
331 + }
332 +
333 +diff --git a/drivers/net/wireless/rt2x00/rt61pci.c b/drivers/net/wireless/rt2x00/rt61pci.c
334 +index 17de24e..dd31588 100644
335 +--- a/drivers/net/wireless/rt2x00/rt61pci.c
336 ++++ b/drivers/net/wireless/rt2x00/rt61pci.c
337 +@@ -2830,7 +2830,8 @@ static int rt61pci_probe_hw_mode(struct rt2x00_dev *rt2x00dev)
338 + tx_power = rt2x00_eeprom_addr(rt2x00dev, EEPROM_TXPOWER_A_START);
339 + for (i = 14; i < spec->num_channels; i++) {
340 + info[i].max_power = MAX_TXPOWER;
341 +- info[i].default_power1 = TXPOWER_FROM_DEV(tx_power[i]);
342 ++ info[i].default_power1 =
343 ++ TXPOWER_FROM_DEV(tx_power[i - 14]);
344 + }
345 + }
346 +
347 +diff --git a/drivers/net/wireless/rt2x00/rt73usb.c b/drivers/net/wireless/rt2x00/rt73usb.c
348 +index 1a06231..3b68155 100644
349 +--- a/drivers/net/wireless/rt2x00/rt73usb.c
350 ++++ b/drivers/net/wireless/rt2x00/rt73usb.c
351 +@@ -2167,7 +2167,8 @@ static int rt73usb_probe_hw_mode(struct rt2x00_dev *rt2x00dev)
352 + tx_power = rt2x00_eeprom_addr(rt2x00dev, EEPROM_TXPOWER_A_START);
353 + for (i = 14; i < spec->num_channels; i++) {
354 + info[i].max_power = MAX_TXPOWER;
355 +- info[i].default_power1 = TXPOWER_FROM_DEV(tx_power[i]);
356 ++ info[i].default_power1 =
357 ++ TXPOWER_FROM_DEV(tx_power[i - 14]);
358 + }
359 + }
360 +
361 +diff --git a/drivers/s390/scsi/zfcp_aux.c b/drivers/s390/scsi/zfcp_aux.c
362 +index 61da2cd..fc669c0 100644
363 +--- a/drivers/s390/scsi/zfcp_aux.c
364 ++++ b/drivers/s390/scsi/zfcp_aux.c
365 +@@ -3,7 +3,7 @@
366 + *
367 + * Module interface and handling of zfcp data structures.
368 + *
369 +- * Copyright IBM Corporation 2002, 2010
370 ++ * Copyright IBM Corp. 2002, 2013
371 + */
372 +
373 + /*
374 +@@ -23,6 +23,7 @@
375 + * Christof Schmitt
376 + * Martin Petermann
377 + * Sven Schuetz
378 ++ * Steffen Maier
379 + */
380 +
381 + #define KMSG_COMPONENT "zfcp"
382 +@@ -414,6 +415,8 @@ struct zfcp_adapter *zfcp_adapter_enqueue(struct ccw_device *ccw_device)
383 + adapter->dma_parms.max_segment_size = ZFCP_QDIO_SBALE_LEN;
384 + adapter->ccw_device->dev.dma_parms = &adapter->dma_parms;
385 +
386 ++ adapter->stat_read_buf_num = FSF_STATUS_READS_RECOM;
387 ++
388 + if (!zfcp_scsi_adapter_register(adapter))
389 + return adapter;
390 +
391 +diff --git a/drivers/s390/scsi/zfcp_fsf.c b/drivers/s390/scsi/zfcp_fsf.c
392 +index 6e73bfe..ceb7f7c 100644
393 +--- a/drivers/s390/scsi/zfcp_fsf.c
394 ++++ b/drivers/s390/scsi/zfcp_fsf.c
395 +@@ -3,7 +3,7 @@
396 + *
397 + * Implementation of FSF commands.
398 + *
399 +- * Copyright IBM Corporation 2002, 2010
400 ++ * Copyright IBM Corp. 2002, 2013
401 + */
402 +
403 + #define KMSG_COMPONENT "zfcp"
404 +@@ -455,11 +455,8 @@ static int zfcp_fsf_exchange_config_evaluate(struct zfcp_fsf_req *req)
405 +
406 + fc_host_port_name(shost) = nsp->fl_wwpn;
407 + fc_host_node_name(shost) = nsp->fl_wwnn;
408 +- fc_host_port_id(shost) = ntoh24(bottom->s_id);
409 +- fc_host_speed(shost) = bottom->fc_link_speed;
410 + fc_host_supported_classes(shost) = FC_COS_CLASS2 | FC_COS_CLASS3;
411 +
412 +- adapter->hydra_version = bottom->adapter_type;
413 + adapter->timer_ticks = bottom->timer_interval & ZFCP_FSF_TIMER_INT_MASK;
414 + adapter->stat_read_buf_num = max(bottom->status_read_buf_num,
415 + (u16)FSF_STATUS_READS_RECOM);
416 +@@ -467,6 +464,18 @@ static int zfcp_fsf_exchange_config_evaluate(struct zfcp_fsf_req *req)
417 + if (fc_host_permanent_port_name(shost) == -1)
418 + fc_host_permanent_port_name(shost) = fc_host_port_name(shost);
419 +
420 ++ zfcp_scsi_set_prot(adapter);
421 ++
422 ++ /* no error return above here, otherwise must fix call chains */
423 ++ /* do not evaluate invalid fields */
424 ++ if (req->qtcb->header.fsf_status == FSF_EXCHANGE_CONFIG_DATA_INCOMPLETE)
425 ++ return 0;
426 ++
427 ++ fc_host_port_id(shost) = ntoh24(bottom->s_id);
428 ++ fc_host_speed(shost) = bottom->fc_link_speed;
429 ++
430 ++ adapter->hydra_version = bottom->adapter_type;
431 ++
432 + switch (bottom->fc_topology) {
433 + case FSF_TOPO_P2P:
434 + adapter->peer_d_id = ntoh24(bottom->peer_d_id);
435 +@@ -488,8 +497,6 @@ static int zfcp_fsf_exchange_config_evaluate(struct zfcp_fsf_req *req)
436 + return -EIO;
437 + }
438 +
439 +- zfcp_scsi_set_prot(adapter);
440 +-
441 + return 0;
442 + }
443 +
444 +@@ -534,8 +541,14 @@ static void zfcp_fsf_exchange_config_data_handler(struct zfcp_fsf_req *req)
445 + fc_host_port_type(shost) = FC_PORTTYPE_UNKNOWN;
446 + adapter->hydra_version = 0;
447 +
448 ++ /* avoids adapter shutdown to be able to recognize
449 ++ * events such as LINK UP */
450 ++ atomic_set_mask(ZFCP_STATUS_ADAPTER_XCONFIG_OK,
451 ++ &adapter->status);
452 + zfcp_fsf_link_down_info_eval(req,
453 + &qtcb->header.fsf_status_qual.link_down_info);
454 ++ if (zfcp_fsf_exchange_config_evaluate(req))
455 ++ return;
456 + break;
457 + default:
458 + zfcp_erp_adapter_shutdown(adapter, 0, "fsecdh3");
459 +diff --git a/drivers/scsi/bnx2fc/bnx2fc_io.c b/drivers/scsi/bnx2fc/bnx2fc_io.c
460 +index 454c72c..ca4be24 100644
461 +--- a/drivers/scsi/bnx2fc/bnx2fc_io.c
462 ++++ b/drivers/scsi/bnx2fc/bnx2fc_io.c
463 +@@ -1618,7 +1618,7 @@ static void bnx2fc_parse_fcp_rsp(struct bnx2fc_cmd *io_req,
464 + fcp_sns_len = SCSI_SENSE_BUFFERSIZE;
465 + }
466 +
467 +- memset(sc_cmd->sense_buffer, 0, sizeof(sc_cmd->sense_buffer));
468 ++ memset(sc_cmd->sense_buffer, 0, SCSI_SENSE_BUFFERSIZE);
469 + if (fcp_sns_len)
470 + memcpy(sc_cmd->sense_buffer, rq_data, fcp_sns_len);
471 +
472 +diff --git a/drivers/scsi/megaraid/megaraid_sas_base.c b/drivers/scsi/megaraid/megaraid_sas_base.c
473 +index 931cb11..5eac650 100644
474 +--- a/drivers/scsi/megaraid/megaraid_sas_base.c
475 ++++ b/drivers/scsi/megaraid/megaraid_sas_base.c
476 +@@ -4746,10 +4746,12 @@ megasas_mgmt_fw_ioctl(struct megasas_instance *instance,
477 + sense, sense_handle);
478 + }
479 +
480 +- for (i = 0; i < ioc->sge_count && kbuff_arr[i]; i++) {
481 +- dma_free_coherent(&instance->pdev->dev,
482 +- kern_sge32[i].length,
483 +- kbuff_arr[i], kern_sge32[i].phys_addr);
484 ++ for (i = 0; i < ioc->sge_count; i++) {
485 ++ if (kbuff_arr[i])
486 ++ dma_free_coherent(&instance->pdev->dev,
487 ++ kern_sge32[i].length,
488 ++ kbuff_arr[i],
489 ++ kern_sge32[i].phys_addr);
490 + }
491 +
492 + megasas_return_cmd(instance, cmd);
493 +diff --git a/drivers/scsi/mpt2sas/mpt2sas_scsih.c b/drivers/scsi/mpt2sas/mpt2sas_scsih.c
494 +index aa51195..d6e8353 100644
495 +--- a/drivers/scsi/mpt2sas/mpt2sas_scsih.c
496 ++++ b/drivers/scsi/mpt2sas/mpt2sas_scsih.c
497 +@@ -3740,11 +3740,7 @@ _scsih_qcmd_lck(struct scsi_cmnd *scmd, void (*done)(struct scsi_cmnd *))
498 + else
499 + mpi_control |= MPI2_SCSIIO_CONTROL_SIMPLEQ;
500 + } else
501 +-/* MPI Revision I (UNIT = 0xA) - removed MPI2_SCSIIO_CONTROL_UNTAGGED */
502 +-/* mpi_control |= MPI2_SCSIIO_CONTROL_UNTAGGED;
503 +- */
504 +- mpi_control |= (0x500);
505 +-
506 ++ mpi_control |= MPI2_SCSIIO_CONTROL_SIMPLEQ;
507 + } else
508 + mpi_control |= MPI2_SCSIIO_CONTROL_SIMPLEQ;
509 + /* Make sure Device is not raid volume.
510 +diff --git a/drivers/usb/serial/cp210x.c b/drivers/usb/serial/cp210x.c
511 +index 913a178..c408ff7 100644
512 +--- a/drivers/usb/serial/cp210x.c
513 ++++ b/drivers/usb/serial/cp210x.c
514 +@@ -60,6 +60,7 @@ static const struct usb_device_id id_table[] = {
515 + { USB_DEVICE(0x0489, 0xE000) }, /* Pirelli Broadband S.p.A, DP-L10 SIP/GSM Mobile */
516 + { USB_DEVICE(0x0489, 0xE003) }, /* Pirelli Broadband S.p.A, DP-L10 SIP/GSM Mobile */
517 + { USB_DEVICE(0x0745, 0x1000) }, /* CipherLab USB CCD Barcode Scanner 1000 */
518 ++ { USB_DEVICE(0x0846, 0x1100) }, /* NetGear Managed Switch M4100 series, M5300 series, M7100 series */
519 + { USB_DEVICE(0x08e6, 0x5501) }, /* Gemalto Prox-PU/CU contactless smartcard reader */
520 + { USB_DEVICE(0x08FD, 0x000A) }, /* Digianswer A/S , ZigBee/802.15.4 MAC Device */
521 + { USB_DEVICE(0x0BED, 0x1100) }, /* MEI (TM) Cashflow-SC Bill/Voucher Acceptor */
522 +@@ -124,6 +125,8 @@ static const struct usb_device_id id_table[] = {
523 + { USB_DEVICE(0x10C4, 0x85F8) }, /* Virtenio Preon32 */
524 + { USB_DEVICE(0x10C4, 0x8664) }, /* AC-Services CAN-IF */
525 + { USB_DEVICE(0x10C4, 0x8665) }, /* AC-Services OBD-IF */
526 ++ { USB_DEVICE(0x10C4, 0x88A4) }, /* MMB Networks ZigBee USB Device */
527 ++ { USB_DEVICE(0x10C4, 0x88A5) }, /* Planet Innovation Ingeni ZigBee USB Device */
528 + { USB_DEVICE(0x10C4, 0xEA60) }, /* Silicon Labs factory default */
529 + { USB_DEVICE(0x10C4, 0xEA61) }, /* Silicon Labs factory default */
530 + { USB_DEVICE(0x10C4, 0xEA70) }, /* Silicon Labs factory default */
531 +@@ -154,6 +157,7 @@ static const struct usb_device_id id_table[] = {
532 + { USB_DEVICE(0x17F4, 0xAAAA) }, /* Wavesense Jazz blood glucose meter */
533 + { USB_DEVICE(0x1843, 0x0200) }, /* Vaisala USB Instrument Cable */
534 + { USB_DEVICE(0x18EF, 0xE00F) }, /* ELV USB-I2C-Interface */
535 ++ { USB_DEVICE(0x1ADB, 0x0001) }, /* Schweitzer Engineering C662 Cable */
536 + { USB_DEVICE(0x1BE3, 0x07A6) }, /* WAGO 750-923 USB Service Cable */
537 + { USB_DEVICE(0x1E29, 0x0102) }, /* Festo CPX-USB */
538 + { USB_DEVICE(0x1E29, 0x0501) }, /* Festo CMSP */
539 +diff --git a/drivers/usb/serial/option.c b/drivers/usb/serial/option.c
540 +index b8365a7..c2103f4 100644
541 +--- a/drivers/usb/serial/option.c
542 ++++ b/drivers/usb/serial/option.c
543 +@@ -347,17 +347,12 @@ static void option_instat_callback(struct urb *urb);
544 + #define OLIVETTI_VENDOR_ID 0x0b3c
545 + #define OLIVETTI_PRODUCT_OLICARD100 0xc000
546 + #define OLIVETTI_PRODUCT_OLICARD145 0xc003
547 ++#define OLIVETTI_PRODUCT_OLICARD200 0xc005
548 +
549 + /* Celot products */
550 + #define CELOT_VENDOR_ID 0x211f
551 + #define CELOT_PRODUCT_CT680M 0x6801
552 +
553 +-/* ONDA Communication vendor id */
554 +-#define ONDA_VENDOR_ID 0x1ee8
555 +-
556 +-/* ONDA MT825UP HSDPA 14.2 modem */
557 +-#define ONDA_MT825UP 0x000b
558 +-
559 + /* Samsung products */
560 + #define SAMSUNG_VENDOR_ID 0x04e8
561 + #define SAMSUNG_PRODUCT_GT_B3730 0x6889
562 +@@ -450,7 +445,8 @@ static void option_instat_callback(struct urb *urb);
563 +
564 + /* Hyundai Petatel Inc. products */
565 + #define PETATEL_VENDOR_ID 0x1ff4
566 +-#define PETATEL_PRODUCT_NP10T 0x600e
567 ++#define PETATEL_PRODUCT_NP10T_600A 0x600a
568 ++#define PETATEL_PRODUCT_NP10T_600E 0x600e
569 +
570 + /* TP-LINK Incorporated products */
571 + #define TPLINK_VENDOR_ID 0x2357
572 +@@ -797,6 +793,7 @@ static const struct usb_device_id option_ids[] = {
573 + { USB_DEVICE(KYOCERA_VENDOR_ID, KYOCERA_PRODUCT_KPC680) },
574 + { USB_DEVICE(QUALCOMM_VENDOR_ID, 0x6000)}, /* ZTE AC8700 */
575 + { USB_DEVICE(QUALCOMM_VENDOR_ID, 0x6613)}, /* Onda H600/ZTE MF330 */
576 ++ { USB_DEVICE(QUALCOMM_VENDOR_ID, 0x0023)}, /* ONYX 3G device */
577 + { USB_DEVICE(QUALCOMM_VENDOR_ID, 0x9000)}, /* SIMCom SIM5218 */
578 + { USB_DEVICE(CMOTECH_VENDOR_ID, CMOTECH_PRODUCT_6280) }, /* BP3-USB & BP3-EXT HSDPA */
579 + { USB_DEVICE(CMOTECH_VENDOR_ID, CMOTECH_PRODUCT_6008) },
580 +@@ -832,7 +829,8 @@ static const struct usb_device_id option_ids[] = {
581 + { USB_DEVICE_AND_INTERFACE_INFO(ZTE_VENDOR_ID, 0x0017, 0xff, 0xff, 0xff),
582 + .driver_info = (kernel_ulong_t)&net_intf3_blacklist },
583 + { USB_DEVICE_AND_INTERFACE_INFO(ZTE_VENDOR_ID, 0x0018, 0xff, 0xff, 0xff) },
584 +- { USB_DEVICE_AND_INTERFACE_INFO(ZTE_VENDOR_ID, 0x0019, 0xff, 0xff, 0xff) },
585 ++ { USB_DEVICE_AND_INTERFACE_INFO(ZTE_VENDOR_ID, 0x0019, 0xff, 0xff, 0xff),
586 ++ .driver_info = (kernel_ulong_t)&net_intf3_blacklist },
587 + { USB_DEVICE_AND_INTERFACE_INFO(ZTE_VENDOR_ID, 0x0020, 0xff, 0xff, 0xff) },
588 + { USB_DEVICE_AND_INTERFACE_INFO(ZTE_VENDOR_ID, 0x0021, 0xff, 0xff, 0xff),
589 + .driver_info = (kernel_ulong_t)&net_intf4_blacklist },
590 +@@ -1278,8 +1276,8 @@ static const struct usb_device_id option_ids[] = {
591 +
592 + { USB_DEVICE(OLIVETTI_VENDOR_ID, OLIVETTI_PRODUCT_OLICARD100) },
593 + { USB_DEVICE(OLIVETTI_VENDOR_ID, OLIVETTI_PRODUCT_OLICARD145) },
594 ++ { USB_DEVICE(OLIVETTI_VENDOR_ID, OLIVETTI_PRODUCT_OLICARD200) },
595 + { USB_DEVICE(CELOT_VENDOR_ID, CELOT_PRODUCT_CT680M) }, /* CT-650 CDMA 450 1xEVDO modem */
596 +- { USB_DEVICE(ONDA_VENDOR_ID, ONDA_MT825UP) }, /* ONDA MT825UP modem */
597 + { USB_DEVICE_AND_INTERFACE_INFO(SAMSUNG_VENDOR_ID, SAMSUNG_PRODUCT_GT_B3730, USB_CLASS_CDC_DATA, 0x00, 0x00) }, /* Samsung GT-B3730 LTE USB modem.*/
598 + { USB_DEVICE(YUGA_VENDOR_ID, YUGA_PRODUCT_CEM600) },
599 + { USB_DEVICE(YUGA_VENDOR_ID, YUGA_PRODUCT_CEM610) },
600 +@@ -1351,9 +1349,12 @@ static const struct usb_device_id option_ids[] = {
601 + { USB_DEVICE_AND_INTERFACE_INFO(MEDIATEK_VENDOR_ID, MEDIATEK_PRODUCT_DC_4COM2, 0xff, 0x02, 0x01) },
602 + { USB_DEVICE_AND_INTERFACE_INFO(MEDIATEK_VENDOR_ID, MEDIATEK_PRODUCT_DC_4COM2, 0xff, 0x00, 0x00) },
603 + { USB_DEVICE(CELLIENT_VENDOR_ID, CELLIENT_PRODUCT_MEN200) },
604 +- { USB_DEVICE(PETATEL_VENDOR_ID, PETATEL_PRODUCT_NP10T) },
605 ++ { USB_DEVICE(PETATEL_VENDOR_ID, PETATEL_PRODUCT_NP10T_600A) },
606 ++ { USB_DEVICE(PETATEL_VENDOR_ID, PETATEL_PRODUCT_NP10T_600E) },
607 + { USB_DEVICE(TPLINK_VENDOR_ID, TPLINK_PRODUCT_MA180),
608 + .driver_info = (kernel_ulong_t)&net_intf4_blacklist },
609 ++ { USB_DEVICE(TPLINK_VENDOR_ID, 0x9000), /* TP-Link MA260 */
610 ++ .driver_info = (kernel_ulong_t)&net_intf4_blacklist },
611 + { USB_DEVICE(CHANGHONG_VENDOR_ID, CHANGHONG_PRODUCT_CH690) },
612 + { USB_DEVICE_AND_INTERFACE_INFO(0x2001, 0x7d01, 0xff, 0x02, 0x01) }, /* D-Link DWM-156 (variant) */
613 + { USB_DEVICE_AND_INTERFACE_INFO(0x2001, 0x7d01, 0xff, 0x00, 0x00) }, /* D-Link DWM-156 (variant) */
614 +@@ -1361,6 +1362,8 @@ static const struct usb_device_id option_ids[] = {
615 + { USB_DEVICE_AND_INTERFACE_INFO(0x2001, 0x7d02, 0xff, 0x00, 0x00) },
616 + { USB_DEVICE_AND_INTERFACE_INFO(0x2001, 0x7d03, 0xff, 0x02, 0x01) },
617 + { USB_DEVICE_AND_INTERFACE_INFO(0x2001, 0x7d03, 0xff, 0x00, 0x00) },
618 ++ { USB_DEVICE_AND_INTERFACE_INFO(0x07d1, 0x3e01, 0xff, 0xff, 0xff) }, /* D-Link DWM-152/C1 */
619 ++ { USB_DEVICE_AND_INTERFACE_INFO(0x07d1, 0x3e02, 0xff, 0xff, 0xff) }, /* D-Link DWM-156/C1 */
620 + { } /* Terminating entry */
621 + };
622 + MODULE_DEVICE_TABLE(usb, option_ids);
623 +diff --git a/fs/block_dev.c b/fs/block_dev.c
624 +index 97e4cb5..b5eb8c1 100644
625 +--- a/fs/block_dev.c
626 ++++ b/fs/block_dev.c
627 +@@ -55,13 +55,21 @@ EXPORT_SYMBOL(I_BDEV);
628 + static void bdev_inode_switch_bdi(struct inode *inode,
629 + struct backing_dev_info *dst)
630 + {
631 ++ bool wakeup_bdi = false;
632 ++
633 + spin_lock(&inode_wb_list_lock);
634 + spin_lock(&inode->i_lock);
635 + inode->i_data.backing_dev_info = dst;
636 +- if (inode->i_state & I_DIRTY)
637 ++ if (inode->i_state & I_DIRTY) {
638 ++ if (bdi_cap_writeback_dirty(dst) && !wb_has_dirty_io(&dst->wb))
639 ++ wakeup_bdi = true;
640 + list_move(&inode->i_wb_list, &dst->wb.b_dirty);
641 ++ }
642 + spin_unlock(&inode->i_lock);
643 + spin_unlock(&inode_wb_list_lock);
644 ++
645 ++ if (wakeup_bdi)
646 ++ bdi_wakeup_thread_delayed(dst);
647 + }
648 +
649 + sector_t blkdev_max_block(struct block_device *bdev)
650 +diff --git a/fs/lockd/svclock.c b/fs/lockd/svclock.c
651 +index 6e31695..db7be3a 100644
652 +--- a/fs/lockd/svclock.c
653 ++++ b/fs/lockd/svclock.c
654 +@@ -913,6 +913,7 @@ nlmsvc_retry_blocked(void)
655 + unsigned long timeout = MAX_SCHEDULE_TIMEOUT;
656 + struct nlm_block *block;
657 +
658 ++ spin_lock(&nlm_blocked_lock);
659 + while (!list_empty(&nlm_blocked) && !kthread_should_stop()) {
660 + block = list_entry(nlm_blocked.next, struct nlm_block, b_list);
661 +
662 +@@ -922,6 +923,7 @@ nlmsvc_retry_blocked(void)
663 + timeout = block->b_when - jiffies;
664 + break;
665 + }
666 ++ spin_unlock(&nlm_blocked_lock);
667 +
668 + dprintk("nlmsvc_retry_blocked(%p, when=%ld)\n",
669 + block, block->b_when);
670 +@@ -931,7 +933,9 @@ nlmsvc_retry_blocked(void)
671 + retry_deferred_block(block);
672 + } else
673 + nlmsvc_grant_blocked(block);
674 ++ spin_lock(&nlm_blocked_lock);
675 + }
676 ++ spin_unlock(&nlm_blocked_lock);
677 +
678 + return timeout;
679 + }
680 +diff --git a/include/linux/if_pppox.h b/include/linux/if_pppox.h
681 +index 397921b..3c7d8ba 100644
682 +--- a/include/linux/if_pppox.h
683 ++++ b/include/linux/if_pppox.h
684 +@@ -127,11 +127,11 @@ struct pppoe_tag {
685 +
686 + struct pppoe_hdr {
687 + #if defined(__LITTLE_ENDIAN_BITFIELD)
688 +- __u8 ver : 4;
689 + __u8 type : 4;
690 ++ __u8 ver : 4;
691 + #elif defined(__BIG_ENDIAN_BITFIELD)
692 +- __u8 type : 4;
693 + __u8 ver : 4;
694 ++ __u8 type : 4;
695 + #else
696 + #error "Please fix <asm/byteorder.h>"
697 + #endif
698 +diff --git a/include/net/addrconf.h b/include/net/addrconf.h
699 +index 582e4ae..561fd2a 100644
700 +--- a/include/net/addrconf.h
701 ++++ b/include/net/addrconf.h
702 +@@ -81,6 +81,9 @@ extern int ipv6_dev_get_saddr(struct net *net,
703 + const struct in6_addr *daddr,
704 + unsigned int srcprefs,
705 + struct in6_addr *saddr);
706 ++extern int __ipv6_get_lladdr(struct inet6_dev *idev,
707 ++ struct in6_addr *addr,
708 ++ unsigned char banned_flags);
709 + extern int ipv6_get_lladdr(struct net_device *dev,
710 + struct in6_addr *addr,
711 + unsigned char banned_flags);
712 +diff --git a/include/net/udp.h b/include/net/udp.h
713 +index 67ea6fc..e723c9d 100644
714 +--- a/include/net/udp.h
715 ++++ b/include/net/udp.h
716 +@@ -180,6 +180,7 @@ extern int udp_get_port(struct sock *sk, unsigned short snum,
717 + extern void udp_err(struct sk_buff *, u32);
718 + extern int udp_sendmsg(struct kiocb *iocb, struct sock *sk,
719 + struct msghdr *msg, size_t len);
720 ++extern int udp_push_pending_frames(struct sock *sk);
721 + extern void udp_flush_pending_frames(struct sock *sk);
722 + extern int udp_rcv(struct sk_buff *skb);
723 + extern int udp_ioctl(struct sock *sk, int cmd, unsigned long arg);
724 +diff --git a/kernel/events/core.c b/kernel/events/core.c
725 +index b582650..da60cfa 100644
726 +--- a/kernel/events/core.c
727 ++++ b/kernel/events/core.c
728 +@@ -651,8 +651,18 @@ perf_lock_task_context(struct task_struct *task, int ctxn, unsigned long *flags)
729 + {
730 + struct perf_event_context *ctx;
731 +
732 +- rcu_read_lock();
733 + retry:
734 ++ /*
735 ++ * One of the few rules of preemptible RCU is that one cannot do
736 ++ * rcu_read_unlock() while holding a scheduler (or nested) lock when
737 ++ * part of the read side critical section was preemptible -- see
738 ++ * rcu_read_unlock_special().
739 ++ *
740 ++ * Since ctx->lock nests under rq->lock we must ensure the entire read
741 ++ * side critical section is non-preemptible.
742 ++ */
743 ++ preempt_disable();
744 ++ rcu_read_lock();
745 + ctx = rcu_dereference(task->perf_event_ctxp[ctxn]);
746 + if (ctx) {
747 + /*
748 +@@ -668,6 +678,8 @@ retry:
749 + raw_spin_lock_irqsave(&ctx->lock, *flags);
750 + if (ctx != rcu_dereference(task->perf_event_ctxp[ctxn])) {
751 + raw_spin_unlock_irqrestore(&ctx->lock, *flags);
752 ++ rcu_read_unlock();
753 ++ preempt_enable();
754 + goto retry;
755 + }
756 +
757 +@@ -677,6 +689,7 @@ retry:
758 + }
759 + }
760 + rcu_read_unlock();
761 ++ preempt_enable();
762 + return ctx;
763 + }
764 +
765 +@@ -1616,7 +1629,16 @@ static int __perf_event_enable(void *info)
766 + struct perf_cpu_context *cpuctx = __get_cpu_context(ctx);
767 + int err;
768 +
769 +- if (WARN_ON_ONCE(!ctx->is_active))
770 ++ /*
771 ++ * There's a time window between 'ctx->is_active' check
772 ++ * in perf_event_enable function and this place having:
773 ++ * - IRQs on
774 ++ * - ctx->lock unlocked
775 ++ *
776 ++ * where the task could be killed and 'ctx' deactivated
777 ++ * by perf_event_exit_task.
778 ++ */
779 ++ if (!ctx->is_active)
780 + return -EINVAL;
781 +
782 + raw_spin_lock(&ctx->lock);
783 +@@ -7064,7 +7086,7 @@ inherit_task_group(struct perf_event *event, struct task_struct *parent,
784 + * child.
785 + */
786 +
787 +- child_ctx = alloc_perf_context(event->pmu, child);
788 ++ child_ctx = alloc_perf_context(parent_ctx->pmu, child);
789 + if (!child_ctx)
790 + return -ENOMEM;
791 +
792 +diff --git a/kernel/hrtimer.c b/kernel/hrtimer.c
793 +index ca3bd3c..80ec91d 100644
794 +--- a/kernel/hrtimer.c
795 ++++ b/kernel/hrtimer.c
796 +@@ -707,17 +707,20 @@ static int hrtimer_switch_to_hres(void)
797 + return 1;
798 + }
799 +
800 ++static void clock_was_set_work(struct work_struct *work)
801 ++{
802 ++ clock_was_set();
803 ++}
804 ++
805 ++static DECLARE_WORK(hrtimer_work, clock_was_set_work);
806 ++
807 + /*
808 +- * Called from timekeeping code to reprogramm the hrtimer interrupt
809 +- * device. If called from the timer interrupt context we defer it to
810 +- * softirq context.
811 ++ * Called from timekeeping and resume code to reprogramm the hrtimer
812 ++ * interrupt device on all cpus.
813 + */
814 + void clock_was_set_delayed(void)
815 + {
816 +- struct hrtimer_cpu_base *cpu_base = &__get_cpu_var(hrtimer_bases);
817 +-
818 +- cpu_base->clock_was_set = 1;
819 +- __raise_softirq_irqoff(HRTIMER_SOFTIRQ);
820 ++ schedule_work(&hrtimer_work);
821 + }
822 +
823 + #else
824 +@@ -766,8 +769,10 @@ void hrtimers_resume(void)
825 + WARN_ONCE(!irqs_disabled(),
826 + KERN_INFO "hrtimers_resume() called with IRQs enabled!");
827 +
828 ++ /* Retrigger on the local CPU */
829 + retrigger_next_event(NULL);
830 +- timerfd_clock_was_set();
831 ++ /* And schedule a retrigger for all others */
832 ++ clock_was_set_delayed();
833 + }
834 +
835 + static inline void timer_stats_hrtimer_set_start_info(struct hrtimer *timer)
836 +@@ -1416,13 +1421,6 @@ void hrtimer_peek_ahead_timers(void)
837 +
838 + static void run_hrtimer_softirq(struct softirq_action *h)
839 + {
840 +- struct hrtimer_cpu_base *cpu_base = &__get_cpu_var(hrtimer_bases);
841 +-
842 +- if (cpu_base->clock_was_set) {
843 +- cpu_base->clock_was_set = 0;
844 +- clock_was_set();
845 +- }
846 +-
847 + hrtimer_peek_ahead_timers();
848 + }
849 +
850 +diff --git a/kernel/time/tick-broadcast.c b/kernel/time/tick-broadcast.c
851 +index e9df75d..20ba7b4 100644
852 +--- a/kernel/time/tick-broadcast.c
853 ++++ b/kernel/time/tick-broadcast.c
854 +@@ -396,7 +396,15 @@ void tick_check_oneshot_broadcast(int cpu)
855 + if (cpumask_test_cpu(cpu, to_cpumask(tick_broadcast_oneshot_mask))) {
856 + struct tick_device *td = &per_cpu(tick_cpu_device, cpu);
857 +
858 +- clockevents_set_mode(td->evtdev, CLOCK_EVT_MODE_ONESHOT);
859 ++ /*
860 ++ * We might be in the middle of switching over from
861 ++ * periodic to oneshot. If the CPU has not yet
862 ++ * switched over, leave the device alone.
863 ++ */
864 ++ if (td->mode == TICKDEV_MODE_ONESHOT) {
865 ++ clockevents_set_mode(td->evtdev,
866 ++ CLOCK_EVT_MODE_ONESHOT);
867 ++ }
868 + }
869 + }
870 +
871 +diff --git a/kernel/trace/trace.c b/kernel/trace/trace.c
872 +index c62ae75..91b8e9a 100644
873 +--- a/kernel/trace/trace.c
874 ++++ b/kernel/trace/trace.c
875 +@@ -628,7 +628,15 @@ __update_max_tr(struct trace_array *tr, struct task_struct *tsk, int cpu)
876 +
877 + memcpy(max_data->comm, tsk->comm, TASK_COMM_LEN);
878 + max_data->pid = tsk->pid;
879 +- max_data->uid = task_uid(tsk);
880 ++ /*
881 ++ * If tsk == current, then use current_uid(), as that does not use
882 ++ * RCU. The irq tracer can be called out of RCU scope.
883 ++ */
884 ++ if (tsk == current)
885 ++ max_data->uid = current_uid();
886 ++ else
887 ++ max_data->uid = task_uid(tsk);
888 ++
889 + max_data->nice = tsk->static_prio - 20 - MAX_RT_PRIO;
890 + max_data->policy = tsk->policy;
891 + max_data->rt_priority = tsk->rt_priority;
892 +diff --git a/kernel/trace/trace_syscalls.c b/kernel/trace/trace_syscalls.c
893 +index ee7b5a0..9b7dad8 100644
894 +--- a/kernel/trace/trace_syscalls.c
895 ++++ b/kernel/trace/trace_syscalls.c
896 +@@ -304,6 +304,8 @@ void ftrace_syscall_enter(void *ignore, struct pt_regs *regs, long id)
897 + struct ring_buffer *buffer;
898 + int size;
899 + int syscall_nr;
900 ++ unsigned long irq_flags;
901 ++ int pc;
902 +
903 + syscall_nr = syscall_get_nr(current, regs);
904 + if (syscall_nr < 0)
905 +@@ -317,8 +319,11 @@ void ftrace_syscall_enter(void *ignore, struct pt_regs *regs, long id)
906 +
907 + size = sizeof(*entry) + sizeof(unsigned long) * sys_data->nb_args;
908 +
909 ++ local_save_flags(irq_flags);
910 ++ pc = preempt_count();
911 ++
912 + event = trace_current_buffer_lock_reserve(&buffer,
913 +- sys_data->enter_event->event.type, size, 0, 0);
914 ++ sys_data->enter_event->event.type, size, irq_flags, pc);
915 + if (!event)
916 + return;
917 +
918 +@@ -328,7 +333,8 @@ void ftrace_syscall_enter(void *ignore, struct pt_regs *regs, long id)
919 +
920 + if (!filter_current_check_discard(buffer, sys_data->enter_event,
921 + entry, event))
922 +- trace_current_buffer_unlock_commit(buffer, event, 0, 0);
923 ++ trace_current_buffer_unlock_commit(buffer, event,
924 ++ irq_flags, pc);
925 + }
926 +
927 + void ftrace_syscall_exit(void *ignore, struct pt_regs *regs, long ret)
928 +@@ -338,6 +344,8 @@ void ftrace_syscall_exit(void *ignore, struct pt_regs *regs, long ret)
929 + struct ring_buffer_event *event;
930 + struct ring_buffer *buffer;
931 + int syscall_nr;
932 ++ unsigned long irq_flags;
933 ++ int pc;
934 +
935 + syscall_nr = syscall_get_nr(current, regs);
936 + if (syscall_nr < 0)
937 +@@ -350,7 +358,8 @@ void ftrace_syscall_exit(void *ignore, struct pt_regs *regs, long ret)
938 + return;
939 +
940 + event = trace_current_buffer_lock_reserve(&buffer,
941 +- sys_data->exit_event->event.type, sizeof(*entry), 0, 0);
942 ++ sys_data->exit_event->event.type, sizeof(*entry),
943 ++ irq_flags, pc);
944 + if (!event)
945 + return;
946 +
947 +@@ -360,7 +369,8 @@ void ftrace_syscall_exit(void *ignore, struct pt_regs *regs, long ret)
948 +
949 + if (!filter_current_check_discard(buffer, sys_data->exit_event,
950 + entry, event))
951 +- trace_current_buffer_unlock_commit(buffer, event, 0, 0);
952 ++ trace_current_buffer_unlock_commit(buffer, event,
953 ++ irq_flags, pc);
954 + }
955 +
956 + int reg_event_syscall_enter(struct ftrace_event_call *call)
957 +diff --git a/net/8021q/vlan_dev.c b/net/8021q/vlan_dev.c
958 +index d548456..b172407 100644
959 +--- a/net/8021q/vlan_dev.c
960 ++++ b/net/8021q/vlan_dev.c
961 +@@ -70,6 +70,8 @@ vlan_dev_get_egress_qos_mask(struct net_device *dev, struct sk_buff *skb)
962 + {
963 + struct vlan_priority_tci_mapping *mp;
964 +
965 ++ smp_rmb(); /* coupled with smp_wmb() in vlan_dev_set_egress_priority() */
966 ++
967 + mp = vlan_dev_info(dev)->egress_priority_map[(skb->priority & 0xF)];
968 + while (mp) {
969 + if (mp->priority == skb->priority) {
970 +@@ -230,6 +232,11 @@ int vlan_dev_set_egress_priority(const struct net_device *dev,
971 + np->next = mp;
972 + np->priority = skb_prio;
973 + np->vlan_qos = vlan_qos;
974 ++ /* Before inserting this element in hash table, make sure all its fields
975 ++ * are committed to memory.
976 ++ * coupled with smp_rmb() in vlan_dev_get_egress_qos_mask()
977 ++ */
978 ++ smp_wmb();
979 + vlan->egress_priority_map[skb_prio & 0xF] = np;
980 + if (vlan_qos)
981 + vlan->nr_egress_mappings++;
982 +diff --git a/net/bridge/br_multicast.c b/net/bridge/br_multicast.c
983 +index e78269d..940c001 100644
984 +--- a/net/bridge/br_multicast.c
985 ++++ b/net/bridge/br_multicast.c
986 +@@ -467,8 +467,9 @@ static struct sk_buff *br_ip6_multicast_alloc_query(struct net_bridge *br,
987 + skb_set_transport_header(skb, skb->len);
988 + mldq = (struct mld_msg *) icmp6_hdr(skb);
989 +
990 +- interval = ipv6_addr_any(group) ? br->multicast_last_member_interval :
991 +- br->multicast_query_response_interval;
992 ++ interval = ipv6_addr_any(group) ?
993 ++ br->multicast_query_response_interval :
994 ++ br->multicast_last_member_interval;
995 +
996 + mldq->mld_type = ICMPV6_MGM_QUERY;
997 + mldq->mld_code = 0;
998 +diff --git a/net/core/neighbour.c b/net/core/neighbour.c
999 +index 34032f2..f268c34 100644
1000 +--- a/net/core/neighbour.c
1001 ++++ b/net/core/neighbour.c
1002 +@@ -237,7 +237,7 @@ static void neigh_flush_dev(struct neigh_table *tbl, struct net_device *dev)
1003 + we must kill timers etc. and move
1004 + it to safe state.
1005 + */
1006 +- skb_queue_purge(&n->arp_queue);
1007 ++ __skb_queue_purge(&n->arp_queue);
1008 + n->output = neigh_blackhole;
1009 + if (n->nud_state & NUD_VALID)
1010 + n->nud_state = NUD_NOARP;
1011 +@@ -291,7 +291,7 @@ static struct neighbour *neigh_alloc(struct neigh_table *tbl)
1012 + if (!n)
1013 + goto out_entries;
1014 +
1015 +- skb_queue_head_init(&n->arp_queue);
1016 ++ __skb_queue_head_init(&n->arp_queue);
1017 + rwlock_init(&n->lock);
1018 + seqlock_init(&n->ha_lock);
1019 + n->updated = n->used = now;
1020 +@@ -712,7 +712,9 @@ void neigh_destroy(struct neighbour *neigh)
1021 + hh_cache_put(hh);
1022 + }
1023 +
1024 +- skb_queue_purge(&neigh->arp_queue);
1025 ++ write_lock_bh(&neigh->lock);
1026 ++ __skb_queue_purge(&neigh->arp_queue);
1027 ++ write_unlock_bh(&neigh->lock);
1028 +
1029 + dev_put(neigh->dev);
1030 + neigh_parms_put(neigh->parms);
1031 +@@ -864,7 +866,7 @@ static void neigh_invalidate(struct neighbour *neigh)
1032 + neigh->ops->error_report(neigh, skb);
1033 + write_lock(&neigh->lock);
1034 + }
1035 +- skb_queue_purge(&neigh->arp_queue);
1036 ++ __skb_queue_purge(&neigh->arp_queue);
1037 + }
1038 +
1039 + /* Called when a timer expires for a neighbour entry. */
1040 +@@ -1188,7 +1190,7 @@ int neigh_update(struct neighbour *neigh, const u8 *lladdr, u8 new,
1041 +
1042 + write_lock_bh(&neigh->lock);
1043 + }
1044 +- skb_queue_purge(&neigh->arp_queue);
1045 ++ __skb_queue_purge(&neigh->arp_queue);
1046 + }
1047 + out:
1048 + if (update_isrouter) {
1049 +diff --git a/net/ipv4/udp.c b/net/ipv4/udp.c
1050 +index 198f75b..ce46ab2 100644
1051 +--- a/net/ipv4/udp.c
1052 ++++ b/net/ipv4/udp.c
1053 +@@ -765,7 +765,7 @@ send:
1054 + /*
1055 + * Push out all pending data as one UDP datagram. Socket is locked.
1056 + */
1057 +-static int udp_push_pending_frames(struct sock *sk)
1058 ++int udp_push_pending_frames(struct sock *sk)
1059 + {
1060 + struct udp_sock *up = udp_sk(sk);
1061 + struct inet_sock *inet = inet_sk(sk);
1062 +@@ -784,6 +784,7 @@ out:
1063 + up->pending = 0;
1064 + return err;
1065 + }
1066 ++EXPORT_SYMBOL(udp_push_pending_frames);
1067 +
1068 + int udp_sendmsg(struct kiocb *iocb, struct sock *sk, struct msghdr *msg,
1069 + size_t len)
1070 +diff --git a/net/ipv6/addrconf.c b/net/ipv6/addrconf.c
1071 +index 3a07320..9c6099d 100644
1072 +--- a/net/ipv6/addrconf.c
1073 ++++ b/net/ipv6/addrconf.c
1074 +@@ -1235,6 +1235,23 @@ try_nextdev:
1075 + }
1076 + EXPORT_SYMBOL(ipv6_dev_get_saddr);
1077 +
1078 ++int __ipv6_get_lladdr(struct inet6_dev *idev, struct in6_addr *addr,
1079 ++ unsigned char banned_flags)
1080 ++{
1081 ++ struct inet6_ifaddr *ifp;
1082 ++ int err = -EADDRNOTAVAIL;
1083 ++
1084 ++ list_for_each_entry(ifp, &idev->addr_list, if_list) {
1085 ++ if (ifp->scope == IFA_LINK &&
1086 ++ !(ifp->flags & banned_flags)) {
1087 ++ ipv6_addr_copy(addr, &ifp->addr);
1088 ++ err = 0;
1089 ++ break;
1090 ++ }
1091 ++ }
1092 ++ return err;
1093 ++}
1094 ++
1095 + int ipv6_get_lladdr(struct net_device *dev, struct in6_addr *addr,
1096 + unsigned char banned_flags)
1097 + {
1098 +@@ -1244,17 +1261,8 @@ int ipv6_get_lladdr(struct net_device *dev, struct in6_addr *addr,
1099 + rcu_read_lock();
1100 + idev = __in6_dev_get(dev);
1101 + if (idev) {
1102 +- struct inet6_ifaddr *ifp;
1103 +-
1104 + read_lock_bh(&idev->lock);
1105 +- list_for_each_entry(ifp, &idev->addr_list, if_list) {
1106 +- if (ifp->scope == IFA_LINK &&
1107 +- !(ifp->flags & banned_flags)) {
1108 +- ipv6_addr_copy(addr, &ifp->addr);
1109 +- err = 0;
1110 +- break;
1111 +- }
1112 +- }
1113 ++ err = __ipv6_get_lladdr(idev, addr, banned_flags);
1114 + read_unlock_bh(&idev->lock);
1115 + }
1116 + rcu_read_unlock();
1117 +@@ -2357,6 +2365,9 @@ static void init_loopback(struct net_device *dev)
1118 + if (sp_ifa->flags & (IFA_F_DADFAILED | IFA_F_TENTATIVE))
1119 + continue;
1120 +
1121 ++ if (sp_ifa->rt)
1122 ++ continue;
1123 ++
1124 + sp_rt = addrconf_dst_alloc(idev, &sp_ifa->addr, 0);
1125 +
1126 + /* Failure cases are ignored */
1127 +diff --git a/net/ipv6/ip6_output.c b/net/ipv6/ip6_output.c
1128 +index 4e49ab0..1fea459 100644
1129 +--- a/net/ipv6/ip6_output.c
1130 ++++ b/net/ipv6/ip6_output.c
1131 +@@ -925,11 +925,17 @@ static struct dst_entry *ip6_sk_dst_check(struct sock *sk,
1132 + const struct flowi6 *fl6)
1133 + {
1134 + struct ipv6_pinfo *np = inet6_sk(sk);
1135 +- struct rt6_info *rt = (struct rt6_info *)dst;
1136 ++ struct rt6_info *rt;
1137 +
1138 + if (!dst)
1139 + goto out;
1140 +
1141 ++ if (dst->ops->family != AF_INET6) {
1142 ++ dst_release(dst);
1143 ++ return NULL;
1144 ++ }
1145 ++
1146 ++ rt = (struct rt6_info *)dst;
1147 + /* Yes, checking route validity in not connected
1148 + * case is not very simple. Take into account,
1149 + * that we do not support routing by source, TOS,
1150 +diff --git a/net/ipv6/mcast.c b/net/ipv6/mcast.c
1151 +index f2d74ea..c7ec4bb 100644
1152 +--- a/net/ipv6/mcast.c
1153 ++++ b/net/ipv6/mcast.c
1154 +@@ -1334,8 +1334,9 @@ mld_scount(struct ifmcaddr6 *pmc, int type, int gdeleted, int sdeleted)
1155 + return scount;
1156 + }
1157 +
1158 +-static struct sk_buff *mld_newpack(struct net_device *dev, int size)
1159 ++static struct sk_buff *mld_newpack(struct inet6_dev *idev, int size)
1160 + {
1161 ++ struct net_device *dev = idev->dev;
1162 + struct net *net = dev_net(dev);
1163 + struct sock *sk = net->ipv6.igmp_sk;
1164 + struct sk_buff *skb;
1165 +@@ -1358,7 +1359,7 @@ static struct sk_buff *mld_newpack(struct net_device *dev, int size)
1166 +
1167 + skb_reserve(skb, LL_RESERVED_SPACE(dev));
1168 +
1169 +- if (ipv6_get_lladdr(dev, &addr_buf, IFA_F_TENTATIVE)) {
1170 ++ if (__ipv6_get_lladdr(idev, &addr_buf, IFA_F_TENTATIVE)) {
1171 + /* <draft-ietf-magma-mld-source-05.txt>:
1172 + * use unspecified address as the source address
1173 + * when a valid link-local address is not available.
1174 +@@ -1461,7 +1462,7 @@ static struct sk_buff *add_grhead(struct sk_buff *skb, struct ifmcaddr6 *pmc,
1175 + struct mld2_grec *pgr;
1176 +
1177 + if (!skb)
1178 +- skb = mld_newpack(dev, dev->mtu);
1179 ++ skb = mld_newpack(pmc->idev, dev->mtu);
1180 + if (!skb)
1181 + return NULL;
1182 + pgr = (struct mld2_grec *)skb_put(skb, sizeof(struct mld2_grec));
1183 +@@ -1481,7 +1482,8 @@ static struct sk_buff *add_grhead(struct sk_buff *skb, struct ifmcaddr6 *pmc,
1184 + static struct sk_buff *add_grec(struct sk_buff *skb, struct ifmcaddr6 *pmc,
1185 + int type, int gdeleted, int sdeleted)
1186 + {
1187 +- struct net_device *dev = pmc->idev->dev;
1188 ++ struct inet6_dev *idev = pmc->idev;
1189 ++ struct net_device *dev = idev->dev;
1190 + struct mld2_report *pmr;
1191 + struct mld2_grec *pgr = NULL;
1192 + struct ip6_sf_list *psf, *psf_next, *psf_prev, **psf_list;
1193 +@@ -1510,7 +1512,7 @@ static struct sk_buff *add_grec(struct sk_buff *skb, struct ifmcaddr6 *pmc,
1194 + AVAILABLE(skb) < grec_size(pmc, type, gdeleted, sdeleted)) {
1195 + if (skb)
1196 + mld_sendpack(skb);
1197 +- skb = mld_newpack(dev, dev->mtu);
1198 ++ skb = mld_newpack(idev, dev->mtu);
1199 + }
1200 + }
1201 + first = 1;
1202 +@@ -1537,7 +1539,7 @@ static struct sk_buff *add_grec(struct sk_buff *skb, struct ifmcaddr6 *pmc,
1203 + pgr->grec_nsrcs = htons(scount);
1204 + if (skb)
1205 + mld_sendpack(skb);
1206 +- skb = mld_newpack(dev, dev->mtu);
1207 ++ skb = mld_newpack(idev, dev->mtu);
1208 + first = 1;
1209 + scount = 0;
1210 + }
1211 +@@ -1592,8 +1594,8 @@ static void mld_send_report(struct inet6_dev *idev, struct ifmcaddr6 *pmc)
1212 + struct sk_buff *skb = NULL;
1213 + int type;
1214 +
1215 ++ read_lock_bh(&idev->lock);
1216 + if (!pmc) {
1217 +- read_lock_bh(&idev->lock);
1218 + for (pmc=idev->mc_list; pmc; pmc=pmc->next) {
1219 + if (pmc->mca_flags & MAF_NOREPORT)
1220 + continue;
1221 +@@ -1605,7 +1607,6 @@ static void mld_send_report(struct inet6_dev *idev, struct ifmcaddr6 *pmc)
1222 + skb = add_grec(skb, pmc, type, 0, 0);
1223 + spin_unlock_bh(&pmc->mca_lock);
1224 + }
1225 +- read_unlock_bh(&idev->lock);
1226 + } else {
1227 + spin_lock_bh(&pmc->mca_lock);
1228 + if (pmc->mca_sfcount[MCAST_EXCLUDE])
1229 +@@ -1615,6 +1616,7 @@ static void mld_send_report(struct inet6_dev *idev, struct ifmcaddr6 *pmc)
1230 + skb = add_grec(skb, pmc, type, 0, 0);
1231 + spin_unlock_bh(&pmc->mca_lock);
1232 + }
1233 ++ read_unlock_bh(&idev->lock);
1234 + if (skb)
1235 + mld_sendpack(skb);
1236 + }
1237 +diff --git a/net/ipv6/udp.c b/net/ipv6/udp.c
1238 +index cd89d6c..214405b 100644
1239 +--- a/net/ipv6/udp.c
1240 ++++ b/net/ipv6/udp.c
1241 +@@ -892,11 +892,16 @@ static int udp_v6_push_pending_frames(struct sock *sk)
1242 + struct udphdr *uh;
1243 + struct udp_sock *up = udp_sk(sk);
1244 + struct inet_sock *inet = inet_sk(sk);
1245 +- struct flowi6 *fl6 = &inet->cork.fl.u.ip6;
1246 ++ struct flowi6 *fl6;
1247 + int err = 0;
1248 + int is_udplite = IS_UDPLITE(sk);
1249 + __wsum csum = 0;
1250 +
1251 ++ if (up->pending == AF_INET)
1252 ++ return udp_push_pending_frames(sk);
1253 ++
1254 ++ fl6 = &inet->cork.fl.u.ip6;
1255 ++
1256 + /* Grab the skbuff where UDP header space exists. */
1257 + if ((skb = skb_peek(&sk->sk_write_queue)) == NULL)
1258 + goto out;
1259 +diff --git a/net/key/af_key.c b/net/key/af_key.c
1260 +index 8f92cf8..01eb92c 100644
1261 +--- a/net/key/af_key.c
1262 ++++ b/net/key/af_key.c
1263 +@@ -1705,6 +1705,7 @@ static int key_notify_sa_flush(const struct km_event *c)
1264 + hdr->sadb_msg_version = PF_KEY_V2;
1265 + hdr->sadb_msg_errno = (uint8_t) 0;
1266 + hdr->sadb_msg_len = (sizeof(struct sadb_msg) / sizeof(uint64_t));
1267 ++ hdr->sadb_msg_reserved = 0;
1268 +
1269 + pfkey_broadcast(skb, GFP_ATOMIC, BROADCAST_ALL, NULL, c->net);
1270 +
1271 +@@ -2686,6 +2687,7 @@ static int key_notify_policy_flush(const struct km_event *c)
1272 + hdr->sadb_msg_version = PF_KEY_V2;
1273 + hdr->sadb_msg_errno = (uint8_t) 0;
1274 + hdr->sadb_msg_len = (sizeof(struct sadb_msg) / sizeof(uint64_t));
1275 ++ hdr->sadb_msg_reserved = 0;
1276 + pfkey_broadcast(skb_out, GFP_ATOMIC, BROADCAST_ALL, NULL, c->net);
1277 + return 0;
1278 +
1279 +diff --git a/net/l2tp/l2tp_ppp.c b/net/l2tp/l2tp_ppp.c
1280 +index 4613225..2366914 100644
1281 +--- a/net/l2tp/l2tp_ppp.c
1282 ++++ b/net/l2tp/l2tp_ppp.c
1283 +@@ -1771,7 +1771,8 @@ static const struct proto_ops pppol2tp_ops = {
1284 +
1285 + static const struct pppox_proto pppol2tp_proto = {
1286 + .create = pppol2tp_create,
1287 +- .ioctl = pppol2tp_ioctl
1288 ++ .ioctl = pppol2tp_ioctl,
1289 ++ .owner = THIS_MODULE,
1290 + };
1291 +
1292 + #ifdef CONFIG_L2TP_V3
1293 +diff --git a/net/x25/af_x25.c b/net/x25/af_x25.c
1294 +index fb37356..5867429 100644
1295 +--- a/net/x25/af_x25.c
1296 ++++ b/net/x25/af_x25.c
1297 +@@ -1584,11 +1584,11 @@ out_cud_release:
1298 + case SIOCX25CALLACCPTAPPRV: {
1299 + rc = -EINVAL;
1300 + lock_sock(sk);
1301 +- if (sk->sk_state != TCP_CLOSE)
1302 +- break;
1303 +- clear_bit(X25_ACCPT_APPRV_FLAG, &x25->flags);
1304 ++ if (sk->sk_state == TCP_CLOSE) {
1305 ++ clear_bit(X25_ACCPT_APPRV_FLAG, &x25->flags);
1306 ++ rc = 0;
1307 ++ }
1308 + release_sock(sk);
1309 +- rc = 0;
1310 + break;
1311 + }
1312 +
1313 +@@ -1596,14 +1596,15 @@ out_cud_release:
1314 + rc = -EINVAL;
1315 + lock_sock(sk);
1316 + if (sk->sk_state != TCP_ESTABLISHED)
1317 +- break;
1318 ++ goto out_sendcallaccpt_release;
1319 + /* must call accptapprv above */
1320 + if (test_bit(X25_ACCPT_APPRV_FLAG, &x25->flags))
1321 +- break;
1322 ++ goto out_sendcallaccpt_release;
1323 + x25_write_internal(sk, X25_CALL_ACCEPTED);
1324 + x25->state = X25_STATE_3;
1325 +- release_sock(sk);
1326 + rc = 0;
1327 ++out_sendcallaccpt_release:
1328 ++ release_sock(sk);
1329 + break;
1330 + }
1331 +
1332 +diff --git a/sound/soc/codecs/sgtl5000.h b/sound/soc/codecs/sgtl5000.h
1333 +index eec3ab3..b79eb80 100644
1334 +--- a/sound/soc/codecs/sgtl5000.h
1335 ++++ b/sound/soc/codecs/sgtl5000.h
1336 +@@ -347,7 +347,7 @@
1337 + #define SGTL5000_PLL_INT_DIV_MASK 0xf800
1338 + #define SGTL5000_PLL_INT_DIV_SHIFT 11
1339 + #define SGTL5000_PLL_INT_DIV_WIDTH 5
1340 +-#define SGTL5000_PLL_FRAC_DIV_MASK 0x0700
1341 ++#define SGTL5000_PLL_FRAC_DIV_MASK 0x07ff
1342 + #define SGTL5000_PLL_FRAC_DIV_SHIFT 0
1343 + #define SGTL5000_PLL_FRAC_DIV_WIDTH 11
1344 +
1345 +diff --git a/sound/usb/6fire/pcm.c b/sound/usb/6fire/pcm.c
1346 +index d144cdb..d2fb012 100644
1347 +--- a/sound/usb/6fire/pcm.c
1348 ++++ b/sound/usb/6fire/pcm.c
1349 +@@ -541,7 +541,7 @@ static snd_pcm_uframes_t usb6fire_pcm_pointer(
1350 + snd_pcm_uframes_t ret;
1351 +
1352 + if (rt->panic || !sub)
1353 +- return SNDRV_PCM_STATE_XRUN;
1354 ++ return SNDRV_PCM_POS_XRUN;
1355 +
1356 + spin_lock_irqsave(&sub->lock, flags);
1357 + ret = sub->dma_off;