Gentoo Archives: gentoo-commits

From: Mike Pagano <mpagano@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] proj/linux-patches:4.14 commit in: /
Date: Wed, 14 Nov 2018 14:01:00
Message-Id: 1542204041.db8975bdd31badd12aef9ca8a8829987f6606264.mpagano@gentoo
1 commit: db8975bdd31badd12aef9ca8a8829987f6606264
2 Author: Alice Ferrazzi <alicef <AT> gentoo <DOT> org>
3 AuthorDate: Wed Aug 22 10:01:43 2018 +0000
4 Commit: Mike Pagano <mpagano <AT> gentoo <DOT> org>
5 CommitDate: Wed Nov 14 14:00:41 2018 +0000
6 URL: https://gitweb.gentoo.org/proj/linux-patches.git/commit/?id=db8975bd
7
8 linux kernel 4.14.65
9
10 Signed-off-by: Mike Pagano <mpagano <AT> gentoo.org>
11
12 0000_README | 4 +
13 1065_linux-4.14.66.patch | 683 +++++++++++++++++++++++++++++++++++++++++++++++
14 2 files changed, 687 insertions(+)
15
16 diff --git a/0000_README b/0000_README
17 index 1cd1371..352e3ec 100644
18 --- a/0000_README
19 +++ b/0000_README
20 @@ -303,6 +303,10 @@ Patch: 1064_linux-4.14.65.patch
21 From: http://www.kernel.org
22 Desc: Linux 4.14.65
23
24 +Patch: 1065_linux-4.14.66.patch
25 +From: http://www.kernel.org
26 +Desc: Linux 4.14.66
27 +
28 Patch: 1500_XATTR_USER_PREFIX.patch
29 From: https://bugs.gentoo.org/show_bug.cgi?id=470644
30 Desc: Support for namespace user.pax.* on tmpfs.
31
32 diff --git a/1065_linux-4.14.66.patch b/1065_linux-4.14.66.patch
33 new file mode 100644
34 index 0000000..149a83c
35 --- /dev/null
36 +++ b/1065_linux-4.14.66.patch
37 @@ -0,0 +1,683 @@
38 +diff --git a/Makefile b/Makefile
39 +index 7995690ff1aa..e69d0d091742 100644
40 +--- a/Makefile
41 ++++ b/Makefile
42 +@@ -1,7 +1,7 @@
43 + # SPDX-License-Identifier: GPL-2.0
44 + VERSION = 4
45 + PATCHLEVEL = 14
46 +-SUBLEVEL = 65
47 ++SUBLEVEL = 66
48 + EXTRAVERSION =
49 + NAME = Petit Gorille
50 +
51 +diff --git a/drivers/acpi/sleep.c b/drivers/acpi/sleep.c
52 +index 2ef0ad6a33d6..7a0af16f86f2 100644
53 +--- a/drivers/acpi/sleep.c
54 ++++ b/drivers/acpi/sleep.c
55 +@@ -338,6 +338,14 @@ static const struct dmi_system_id acpisleep_dmi_table[] __initconst = {
56 + DMI_MATCH(DMI_PRODUCT_NAME, "K54HR"),
57 + },
58 + },
59 ++ {
60 ++ .callback = init_nvs_save_s3,
61 ++ .ident = "Asus 1025C",
62 ++ .matches = {
63 ++ DMI_MATCH(DMI_SYS_VENDOR, "ASUSTeK COMPUTER INC."),
64 ++ DMI_MATCH(DMI_PRODUCT_NAME, "1025C"),
65 ++ },
66 ++ },
67 + /*
68 + * https://bugzilla.kernel.org/show_bug.cgi?id=189431
69 + * Lenovo G50-45 is a platform later than 2012, but needs nvs memory
70 +diff --git a/drivers/isdn/i4l/isdn_common.c b/drivers/isdn/i4l/isdn_common.c
71 +index 38a5bb764c7b..598724ffde4e 100644
72 +--- a/drivers/isdn/i4l/isdn_common.c
73 ++++ b/drivers/isdn/i4l/isdn_common.c
74 +@@ -1640,13 +1640,7 @@ isdn_ioctl(struct file *file, uint cmd, ulong arg)
75 + } else
76 + return -EINVAL;
77 + case IIOCDBGVAR:
78 +- if (arg) {
79 +- if (copy_to_user(argp, &dev, sizeof(ulong)))
80 +- return -EFAULT;
81 +- return 0;
82 +- } else
83 +- return -EINVAL;
84 +- break;
85 ++ return -EINVAL;
86 + default:
87 + if ((cmd & IIOCDRVCTL) == IIOCDRVCTL)
88 + cmd = ((cmd >> _IOC_NRSHIFT) & _IOC_NRMASK) & ISDN_DRVIOCTL_MASK;
89 +diff --git a/drivers/misc/sram.c b/drivers/misc/sram.c
90 +index fc0415771c00..4dd0d868ff88 100644
91 +--- a/drivers/misc/sram.c
92 ++++ b/drivers/misc/sram.c
93 +@@ -407,13 +407,20 @@ static int sram_probe(struct platform_device *pdev)
94 + if (init_func) {
95 + ret = init_func();
96 + if (ret)
97 +- return ret;
98 ++ goto err_disable_clk;
99 + }
100 +
101 + dev_dbg(sram->dev, "SRAM pool: %zu KiB @ 0x%p\n",
102 + gen_pool_size(sram->pool) / 1024, sram->virt_base);
103 +
104 + return 0;
105 ++
106 ++err_disable_clk:
107 ++ if (sram->clk)
108 ++ clk_disable_unprepare(sram->clk);
109 ++ sram_free_partitions(sram);
110 ++
111 ++ return ret;
112 + }
113 +
114 + static int sram_remove(struct platform_device *pdev)
115 +diff --git a/drivers/net/ethernet/aquantia/atlantic/hw_atl/hw_atl_b0.c b/drivers/net/ethernet/aquantia/atlantic/hw_atl/hw_atl_b0.c
116 +index 36fddb199160..f4b3554b0b67 100644
117 +--- a/drivers/net/ethernet/aquantia/atlantic/hw_atl/hw_atl_b0.c
118 ++++ b/drivers/net/ethernet/aquantia/atlantic/hw_atl/hw_atl_b0.c
119 +@@ -752,7 +752,7 @@ static int hw_atl_b0_hw_packet_filter_set(struct aq_hw_s *self,
120 +
121 + rpfl2promiscuous_mode_en_set(self, IS_FILTER_ENABLED(IFF_PROMISC));
122 + rpfl2multicast_flr_en_set(self,
123 +- IS_FILTER_ENABLED(IFF_MULTICAST), 0);
124 ++ IS_FILTER_ENABLED(IFF_ALLMULTI), 0);
125 +
126 + rpfl2_accept_all_mc_packets_set(self,
127 + IS_FILTER_ENABLED(IFF_ALLMULTI));
128 +diff --git a/drivers/tty/serial/8250/8250_dw.c b/drivers/tty/serial/8250/8250_dw.c
129 +index 3015789265dd..27c5b2b46b8d 100644
130 +--- a/drivers/tty/serial/8250/8250_dw.c
131 ++++ b/drivers/tty/serial/8250/8250_dw.c
132 +@@ -260,7 +260,7 @@ static void dw8250_set_termios(struct uart_port *p, struct ktermios *termios,
133 + long rate;
134 + int ret;
135 +
136 +- if (IS_ERR(d->clk) || !old)
137 ++ if (IS_ERR(d->clk))
138 + goto out;
139 +
140 + clk_disable_unprepare(d->clk);
141 +@@ -672,6 +672,7 @@ static const struct acpi_device_id dw8250_acpi_match[] = {
142 + { "APMC0D08", 0},
143 + { "AMD0020", 0 },
144 + { "AMDI0020", 0 },
145 ++ { "BRCM2032", 0 },
146 + { "HISI0031", 0 },
147 + { },
148 + };
149 +diff --git a/drivers/tty/serial/8250/8250_exar.c b/drivers/tty/serial/8250/8250_exar.c
150 +index e0aa5f03004c..411b4b03457b 100644
151 +--- a/drivers/tty/serial/8250/8250_exar.c
152 ++++ b/drivers/tty/serial/8250/8250_exar.c
153 +@@ -436,7 +436,11 @@ static irqreturn_t exar_misc_handler(int irq, void *data)
154 + struct exar8250 *priv = data;
155 +
156 + /* Clear all PCI interrupts by reading INT0. No effect on IIR */
157 +- ioread8(priv->virt + UART_EXAR_INT0);
158 ++ readb(priv->virt + UART_EXAR_INT0);
159 ++
160 ++ /* Clear INT0 for Expansion Interface slave ports, too */
161 ++ if (priv->board->num_ports > 8)
162 ++ readb(priv->virt + 0x2000 + UART_EXAR_INT0);
163 +
164 + return IRQ_HANDLED;
165 + }
166 +diff --git a/drivers/tty/serial/8250/8250_port.c b/drivers/tty/serial/8250/8250_port.c
167 +index be456ea27ab2..ecf3d631bc09 100644
168 +--- a/drivers/tty/serial/8250/8250_port.c
169 ++++ b/drivers/tty/serial/8250/8250_port.c
170 +@@ -94,8 +94,7 @@ static const struct serial8250_config uart_config[] = {
171 + .name = "16550A",
172 + .fifo_size = 16,
173 + .tx_loadsz = 16,
174 +- .fcr = UART_FCR_ENABLE_FIFO | UART_FCR_R_TRIG_10 |
175 +- UART_FCR_CLEAR_RCVR | UART_FCR_CLEAR_XMIT,
176 ++ .fcr = UART_FCR_ENABLE_FIFO | UART_FCR_R_TRIG_10,
177 + .rxtrig_bytes = {1, 4, 8, 14},
178 + .flags = UART_CAP_FIFO,
179 + },
180 +diff --git a/drivers/usb/serial/option.c b/drivers/usb/serial/option.c
181 +index d4124551fb56..0600dadd6a0c 100644
182 +--- a/drivers/usb/serial/option.c
183 ++++ b/drivers/usb/serial/option.c
184 +@@ -199,6 +199,8 @@ static void option_instat_callback(struct urb *urb);
185 + #define DELL_PRODUCT_5800_V2_MINICARD_VZW 0x8196 /* Novatel E362 */
186 + #define DELL_PRODUCT_5804_MINICARD_ATT 0x819b /* Novatel E371 */
187 +
188 ++#define DELL_PRODUCT_5821E 0x81d7
189 ++
190 + #define KYOCERA_VENDOR_ID 0x0c88
191 + #define KYOCERA_PRODUCT_KPC650 0x17da
192 + #define KYOCERA_PRODUCT_KPC680 0x180a
193 +@@ -1033,6 +1035,8 @@ static const struct usb_device_id option_ids[] = {
194 + { USB_DEVICE_AND_INTERFACE_INFO(DELL_VENDOR_ID, DELL_PRODUCT_5800_MINICARD_VZW, 0xff, 0xff, 0xff) },
195 + { USB_DEVICE_AND_INTERFACE_INFO(DELL_VENDOR_ID, DELL_PRODUCT_5800_V2_MINICARD_VZW, 0xff, 0xff, 0xff) },
196 + { USB_DEVICE_AND_INTERFACE_INFO(DELL_VENDOR_ID, DELL_PRODUCT_5804_MINICARD_ATT, 0xff, 0xff, 0xff) },
197 ++ { USB_DEVICE(DELL_VENDOR_ID, DELL_PRODUCT_5821E),
198 ++ .driver_info = RSVD(0) | RSVD(1) | RSVD(6) },
199 + { USB_DEVICE(ANYDATA_VENDOR_ID, ANYDATA_PRODUCT_ADU_E100A) }, /* ADU-E100, ADU-310 */
200 + { USB_DEVICE(ANYDATA_VENDOR_ID, ANYDATA_PRODUCT_ADU_500A) },
201 + { USB_DEVICE(ANYDATA_VENDOR_ID, ANYDATA_PRODUCT_ADU_620UW) },
202 +diff --git a/drivers/usb/serial/pl2303.c b/drivers/usb/serial/pl2303.c
203 +index 34c5a75f98a7..2153e67eeeee 100644
204 +--- a/drivers/usb/serial/pl2303.c
205 ++++ b/drivers/usb/serial/pl2303.c
206 +@@ -55,6 +55,8 @@ static const struct usb_device_id id_table[] = {
207 + .driver_info = PL2303_QUIRK_ENDPOINT_HACK },
208 + { USB_DEVICE(ATEN_VENDOR_ID, ATEN_PRODUCT_UC485),
209 + .driver_info = PL2303_QUIRK_ENDPOINT_HACK },
210 ++ { USB_DEVICE(ATEN_VENDOR_ID, ATEN_PRODUCT_UC232B),
211 ++ .driver_info = PL2303_QUIRK_ENDPOINT_HACK },
212 + { USB_DEVICE(ATEN_VENDOR_ID, ATEN_PRODUCT_ID2) },
213 + { USB_DEVICE(ATEN_VENDOR_ID2, ATEN_PRODUCT_ID) },
214 + { USB_DEVICE(ELCOM_VENDOR_ID, ELCOM_PRODUCT_ID) },
215 +diff --git a/drivers/usb/serial/pl2303.h b/drivers/usb/serial/pl2303.h
216 +index 123289085ee2..cec7141245ef 100644
217 +--- a/drivers/usb/serial/pl2303.h
218 ++++ b/drivers/usb/serial/pl2303.h
219 +@@ -29,6 +29,7 @@
220 + #define ATEN_VENDOR_ID2 0x0547
221 + #define ATEN_PRODUCT_ID 0x2008
222 + #define ATEN_PRODUCT_UC485 0x2021
223 ++#define ATEN_PRODUCT_UC232B 0x2022
224 + #define ATEN_PRODUCT_ID2 0x2118
225 +
226 + #define IODATA_VENDOR_ID 0x04bb
227 +diff --git a/drivers/usb/serial/sierra.c b/drivers/usb/serial/sierra.c
228 +index 4c4ac4705ac0..a9c5564b6b65 100644
229 +--- a/drivers/usb/serial/sierra.c
230 ++++ b/drivers/usb/serial/sierra.c
231 +@@ -773,9 +773,9 @@ static void sierra_close(struct usb_serial_port *port)
232 + kfree(urb->transfer_buffer);
233 + usb_free_urb(urb);
234 + usb_autopm_put_interface_async(serial->interface);
235 +- spin_lock(&portdata->lock);
236 ++ spin_lock_irq(&portdata->lock);
237 + portdata->outstanding_urbs--;
238 +- spin_unlock(&portdata->lock);
239 ++ spin_unlock_irq(&portdata->lock);
240 + }
241 +
242 + sierra_stop_rx_urbs(port);
243 +diff --git a/drivers/vhost/vhost.c b/drivers/vhost/vhost.c
244 +index 244e5256c526..3cf74f54c7a1 100644
245 +--- a/drivers/vhost/vhost.c
246 ++++ b/drivers/vhost/vhost.c
247 +@@ -1578,9 +1578,12 @@ int vhost_init_device_iotlb(struct vhost_dev *d, bool enabled)
248 + d->iotlb = niotlb;
249 +
250 + for (i = 0; i < d->nvqs; ++i) {
251 +- mutex_lock(&d->vqs[i]->mutex);
252 +- d->vqs[i]->iotlb = niotlb;
253 +- mutex_unlock(&d->vqs[i]->mutex);
254 ++ struct vhost_virtqueue *vq = d->vqs[i];
255 ++
256 ++ mutex_lock(&vq->mutex);
257 ++ vq->iotlb = niotlb;
258 ++ __vhost_vq_meta_reset(vq);
259 ++ mutex_unlock(&vq->mutex);
260 + }
261 +
262 + vhost_umem_clean(oiotlb);
263 +diff --git a/include/net/af_vsock.h b/include/net/af_vsock.h
264 +index f9fb566e75cf..5fb3f6361090 100644
265 +--- a/include/net/af_vsock.h
266 ++++ b/include/net/af_vsock.h
267 +@@ -62,7 +62,8 @@ struct vsock_sock {
268 + struct list_head pending_links;
269 + struct list_head accept_queue;
270 + bool rejected;
271 +- struct delayed_work dwork;
272 ++ struct delayed_work connect_work;
273 ++ struct delayed_work pending_work;
274 + struct delayed_work close_work;
275 + bool close_work_scheduled;
276 + u32 peer_shutdown;
277 +@@ -75,7 +76,6 @@ struct vsock_sock {
278 +
279 + s64 vsock_stream_has_data(struct vsock_sock *vsk);
280 + s64 vsock_stream_has_space(struct vsock_sock *vsk);
281 +-void vsock_pending_work(struct work_struct *work);
282 + struct sock *__vsock_create(struct net *net,
283 + struct socket *sock,
284 + struct sock *parent,
285 +diff --git a/include/net/llc.h b/include/net/llc.h
286 +index dc35f25eb679..890a87318014 100644
287 +--- a/include/net/llc.h
288 ++++ b/include/net/llc.h
289 +@@ -116,6 +116,11 @@ static inline void llc_sap_hold(struct llc_sap *sap)
290 + refcount_inc(&sap->refcnt);
291 + }
292 +
293 ++static inline bool llc_sap_hold_safe(struct llc_sap *sap)
294 ++{
295 ++ return refcount_inc_not_zero(&sap->refcnt);
296 ++}
297 ++
298 + void llc_sap_close(struct llc_sap *sap);
299 +
300 + static inline void llc_sap_put(struct llc_sap *sap)
301 +diff --git a/net/bluetooth/sco.c b/net/bluetooth/sco.c
302 +index 795e920a3281..81fe3949c158 100644
303 +--- a/net/bluetooth/sco.c
304 ++++ b/net/bluetooth/sco.c
305 +@@ -393,7 +393,8 @@ static void sco_sock_cleanup_listen(struct sock *parent)
306 + */
307 + static void sco_sock_kill(struct sock *sk)
308 + {
309 +- if (!sock_flag(sk, SOCK_ZAPPED) || sk->sk_socket)
310 ++ if (!sock_flag(sk, SOCK_ZAPPED) || sk->sk_socket ||
311 ++ sock_flag(sk, SOCK_DEAD))
312 + return;
313 +
314 + BT_DBG("sk %p state %d", sk, sk->sk_state);
315 +diff --git a/net/dccp/ccids/ccid2.c b/net/dccp/ccids/ccid2.c
316 +index 3887bc115762..fc31c02d616c 100644
317 +--- a/net/dccp/ccids/ccid2.c
318 ++++ b/net/dccp/ccids/ccid2.c
319 +@@ -228,14 +228,16 @@ static void ccid2_cwnd_restart(struct sock *sk, const u32 now)
320 + struct ccid2_hc_tx_sock *hc = ccid2_hc_tx_sk(sk);
321 + u32 cwnd = hc->tx_cwnd, restart_cwnd,
322 + iwnd = rfc3390_bytes_to_packets(dccp_sk(sk)->dccps_mss_cache);
323 ++ s32 delta = now - hc->tx_lsndtime;
324 +
325 + hc->tx_ssthresh = max(hc->tx_ssthresh, (cwnd >> 1) + (cwnd >> 2));
326 +
327 + /* don't reduce cwnd below the initial window (IW) */
328 + restart_cwnd = min(cwnd, iwnd);
329 +- cwnd >>= (now - hc->tx_lsndtime) / hc->tx_rto;
330 +- hc->tx_cwnd = max(cwnd, restart_cwnd);
331 +
332 ++ while ((delta -= hc->tx_rto) >= 0 && cwnd > restart_cwnd)
333 ++ cwnd >>= 1;
334 ++ hc->tx_cwnd = max(cwnd, restart_cwnd);
335 + hc->tx_cwnd_stamp = now;
336 + hc->tx_cwnd_used = 0;
337 +
338 +diff --git a/net/ipv6/ip6_tunnel.c b/net/ipv6/ip6_tunnel.c
339 +index 84ee2eb88121..ee8dbd228fe2 100644
340 +--- a/net/ipv6/ip6_tunnel.c
341 ++++ b/net/ipv6/ip6_tunnel.c
342 +@@ -1134,12 +1134,8 @@ route_lookup:
343 + max_headroom += 8;
344 + mtu -= 8;
345 + }
346 +- if (skb->protocol == htons(ETH_P_IPV6)) {
347 +- if (mtu < IPV6_MIN_MTU)
348 +- mtu = IPV6_MIN_MTU;
349 +- } else if (mtu < 576) {
350 +- mtu = 576;
351 +- }
352 ++ mtu = max(mtu, skb->protocol == htons(ETH_P_IPV6) ?
353 ++ IPV6_MIN_MTU : IPV4_MIN_MTU);
354 +
355 + skb_dst_update_pmtu(skb, mtu);
356 + if (skb->len - t->tun_hlen - eth_hlen > mtu && !skb_is_gso(skb)) {
357 +diff --git a/net/l2tp/l2tp_core.c b/net/l2tp/l2tp_core.c
358 +index 316869df91e8..5c87f1d3e525 100644
359 +--- a/net/l2tp/l2tp_core.c
360 ++++ b/net/l2tp/l2tp_core.c
361 +@@ -1211,7 +1211,7 @@ int l2tp_xmit_skb(struct l2tp_session *session, struct sk_buff *skb, int hdr_len
362 +
363 + /* Get routing info from the tunnel socket */
364 + skb_dst_drop(skb);
365 +- skb_dst_set(skb, dst_clone(__sk_dst_check(sk, 0)));
366 ++ skb_dst_set(skb, sk_dst_check(sk, 0));
367 +
368 + inet = inet_sk(sk);
369 + fl = &inet->cork.fl;
370 +diff --git a/net/llc/llc_core.c b/net/llc/llc_core.c
371 +index 89041260784c..260b3dc1b4a2 100644
372 +--- a/net/llc/llc_core.c
373 ++++ b/net/llc/llc_core.c
374 +@@ -73,8 +73,8 @@ struct llc_sap *llc_sap_find(unsigned char sap_value)
375 +
376 + rcu_read_lock_bh();
377 + sap = __llc_sap_find(sap_value);
378 +- if (sap)
379 +- llc_sap_hold(sap);
380 ++ if (!sap || !llc_sap_hold_safe(sap))
381 ++ sap = NULL;
382 + rcu_read_unlock_bh();
383 + return sap;
384 + }
385 +diff --git a/net/sched/cls_matchall.c b/net/sched/cls_matchall.c
386 +index 3684153cd8a9..6499aecfbfc4 100644
387 +--- a/net/sched/cls_matchall.c
388 ++++ b/net/sched/cls_matchall.c
389 +@@ -112,6 +112,8 @@ static void mall_destroy(struct tcf_proto *tp)
390 + if (!head)
391 + return;
392 +
393 ++ tcf_unbind_filter(tp, &head->res);
394 ++
395 + if (tc_should_offload(dev, head->flags))
396 + mall_destroy_hw_filter(tp, head, (unsigned long) head);
397 +
398 +diff --git a/net/sched/cls_tcindex.c b/net/sched/cls_tcindex.c
399 +index a76937ee0b2d..52829fdc280b 100644
400 +--- a/net/sched/cls_tcindex.c
401 ++++ b/net/sched/cls_tcindex.c
402 +@@ -464,11 +464,6 @@ tcindex_set_parms(struct net *net, struct tcf_proto *tp, unsigned long base,
403 + tcf_bind_filter(tp, &cr.res, base);
404 + }
405 +
406 +- if (old_r)
407 +- tcf_exts_change(&r->exts, &e);
408 +- else
409 +- tcf_exts_change(&cr.exts, &e);
410 +-
411 + if (old_r && old_r != r) {
412 + err = tcindex_filter_result_init(old_r);
413 + if (err < 0) {
414 +@@ -479,12 +474,15 @@ tcindex_set_parms(struct net *net, struct tcf_proto *tp, unsigned long base,
415 +
416 + oldp = p;
417 + r->res = cr.res;
418 ++ tcf_exts_change(&r->exts, &e);
419 ++
420 + rcu_assign_pointer(tp->root, cp);
421 +
422 + if (r == &new_filter_result) {
423 + struct tcindex_filter *nfp;
424 + struct tcindex_filter __rcu **fp;
425 +
426 ++ f->result.res = r->res;
427 + tcf_exts_change(&f->result.exts, &r->exts);
428 +
429 + fp = cp->h + (handle % cp->hash);
430 +diff --git a/net/vmw_vsock/af_vsock.c b/net/vmw_vsock/af_vsock.c
431 +index dfc8c51e4d74..f2fd556c1233 100644
432 +--- a/net/vmw_vsock/af_vsock.c
433 ++++ b/net/vmw_vsock/af_vsock.c
434 +@@ -449,14 +449,14 @@ static int vsock_send_shutdown(struct sock *sk, int mode)
435 + return transport->shutdown(vsock_sk(sk), mode);
436 + }
437 +
438 +-void vsock_pending_work(struct work_struct *work)
439 ++static void vsock_pending_work(struct work_struct *work)
440 + {
441 + struct sock *sk;
442 + struct sock *listener;
443 + struct vsock_sock *vsk;
444 + bool cleanup;
445 +
446 +- vsk = container_of(work, struct vsock_sock, dwork.work);
447 ++ vsk = container_of(work, struct vsock_sock, pending_work.work);
448 + sk = sk_vsock(vsk);
449 + listener = vsk->listener;
450 + cleanup = true;
451 +@@ -496,7 +496,6 @@ out:
452 + sock_put(sk);
453 + sock_put(listener);
454 + }
455 +-EXPORT_SYMBOL_GPL(vsock_pending_work);
456 +
457 + /**** SOCKET OPERATIONS ****/
458 +
459 +@@ -595,6 +594,8 @@ static int __vsock_bind(struct sock *sk, struct sockaddr_vm *addr)
460 + return retval;
461 + }
462 +
463 ++static void vsock_connect_timeout(struct work_struct *work);
464 ++
465 + struct sock *__vsock_create(struct net *net,
466 + struct socket *sock,
467 + struct sock *parent,
468 +@@ -637,6 +638,8 @@ struct sock *__vsock_create(struct net *net,
469 + vsk->sent_request = false;
470 + vsk->ignore_connecting_rst = false;
471 + vsk->peer_shutdown = 0;
472 ++ INIT_DELAYED_WORK(&vsk->connect_work, vsock_connect_timeout);
473 ++ INIT_DELAYED_WORK(&vsk->pending_work, vsock_pending_work);
474 +
475 + psk = parent ? vsock_sk(parent) : NULL;
476 + if (parent) {
477 +@@ -1116,7 +1119,7 @@ static void vsock_connect_timeout(struct work_struct *work)
478 + struct vsock_sock *vsk;
479 + int cancel = 0;
480 +
481 +- vsk = container_of(work, struct vsock_sock, dwork.work);
482 ++ vsk = container_of(work, struct vsock_sock, connect_work.work);
483 + sk = sk_vsock(vsk);
484 +
485 + lock_sock(sk);
486 +@@ -1220,9 +1223,7 @@ static int vsock_stream_connect(struct socket *sock, struct sockaddr *addr,
487 + * timeout fires.
488 + */
489 + sock_hold(sk);
490 +- INIT_DELAYED_WORK(&vsk->dwork,
491 +- vsock_connect_timeout);
492 +- schedule_delayed_work(&vsk->dwork, timeout);
493 ++ schedule_delayed_work(&vsk->connect_work, timeout);
494 +
495 + /* Skip ahead to preserve error code set above. */
496 + goto out_wait;
497 +diff --git a/net/vmw_vsock/vmci_transport.c b/net/vmw_vsock/vmci_transport.c
498 +index 10ae7823a19d..d5be519b0271 100644
499 +--- a/net/vmw_vsock/vmci_transport.c
500 ++++ b/net/vmw_vsock/vmci_transport.c
501 +@@ -1091,8 +1091,7 @@ static int vmci_transport_recv_listen(struct sock *sk,
502 + vpending->listener = sk;
503 + sock_hold(sk);
504 + sock_hold(pending);
505 +- INIT_DELAYED_WORK(&vpending->dwork, vsock_pending_work);
506 +- schedule_delayed_work(&vpending->dwork, HZ);
507 ++ schedule_delayed_work(&vpending->pending_work, HZ);
508 +
509 + out:
510 + return err;
511 +diff --git a/sound/core/memalloc.c b/sound/core/memalloc.c
512 +index 7f89d3c79a4b..753d5fc4b284 100644
513 +--- a/sound/core/memalloc.c
514 ++++ b/sound/core/memalloc.c
515 +@@ -242,16 +242,12 @@ int snd_dma_alloc_pages_fallback(int type, struct device *device, size_t size,
516 + int err;
517 +
518 + while ((err = snd_dma_alloc_pages(type, device, size, dmab)) < 0) {
519 +- size_t aligned_size;
520 + if (err != -ENOMEM)
521 + return err;
522 + if (size <= PAGE_SIZE)
523 + return -ENOMEM;
524 +- aligned_size = PAGE_SIZE << get_order(size);
525 +- if (size != aligned_size)
526 +- size = aligned_size;
527 +- else
528 +- size >>= 1;
529 ++ size >>= 1;
530 ++ size = PAGE_SIZE << get_order(size);
531 + }
532 + if (! dmab->area)
533 + return -ENOMEM;
534 +diff --git a/sound/core/seq/seq_virmidi.c b/sound/core/seq/seq_virmidi.c
535 +index 289ae6bb81d9..8ebbca554e99 100644
536 +--- a/sound/core/seq/seq_virmidi.c
537 ++++ b/sound/core/seq/seq_virmidi.c
538 +@@ -163,6 +163,7 @@ static void snd_virmidi_output_trigger(struct snd_rawmidi_substream *substream,
539 + int count, res;
540 + unsigned char buf[32], *pbuf;
541 + unsigned long flags;
542 ++ bool check_resched = !in_atomic();
543 +
544 + if (up) {
545 + vmidi->trigger = 1;
546 +@@ -200,6 +201,15 @@ static void snd_virmidi_output_trigger(struct snd_rawmidi_substream *substream,
547 + vmidi->event.type = SNDRV_SEQ_EVENT_NONE;
548 + }
549 + }
550 ++ if (!check_resched)
551 ++ continue;
552 ++ /* do temporary unlock & cond_resched() for avoiding
553 ++ * CPU soft lockup, which may happen via a write from
554 ++ * a huge rawmidi buffer
555 ++ */
556 ++ spin_unlock_irqrestore(&substream->runtime->lock, flags);
557 ++ cond_resched();
558 ++ spin_lock_irqsave(&substream->runtime->lock, flags);
559 + }
560 + out:
561 + spin_unlock_irqrestore(&substream->runtime->lock, flags);
562 +diff --git a/sound/pci/cs5535audio/cs5535audio.h b/sound/pci/cs5535audio/cs5535audio.h
563 +index f4fcdf93f3c8..d84620a0c26c 100644
564 +--- a/sound/pci/cs5535audio/cs5535audio.h
565 ++++ b/sound/pci/cs5535audio/cs5535audio.h
566 +@@ -67,9 +67,9 @@ struct cs5535audio_dma_ops {
567 + };
568 +
569 + struct cs5535audio_dma_desc {
570 +- u32 addr;
571 +- u16 size;
572 +- u16 ctlreserved;
573 ++ __le32 addr;
574 ++ __le16 size;
575 ++ __le16 ctlreserved;
576 + };
577 +
578 + struct cs5535audio_dma {
579 +diff --git a/sound/pci/cs5535audio/cs5535audio_pcm.c b/sound/pci/cs5535audio/cs5535audio_pcm.c
580 +index ee7065f6e162..326caec854e1 100644
581 +--- a/sound/pci/cs5535audio/cs5535audio_pcm.c
582 ++++ b/sound/pci/cs5535audio/cs5535audio_pcm.c
583 +@@ -158,8 +158,8 @@ static int cs5535audio_build_dma_packets(struct cs5535audio *cs5535au,
584 + lastdesc->addr = cpu_to_le32((u32) dma->desc_buf.addr);
585 + lastdesc->size = 0;
586 + lastdesc->ctlreserved = cpu_to_le16(PRD_JMP);
587 +- jmpprd_addr = cpu_to_le32(lastdesc->addr +
588 +- (sizeof(struct cs5535audio_dma_desc)*periods));
589 ++ jmpprd_addr = (u32)dma->desc_buf.addr +
590 ++ sizeof(struct cs5535audio_dma_desc) * periods;
591 +
592 + dma->substream = substream;
593 + dma->period_bytes = period_bytes;
594 +diff --git a/sound/pci/hda/hda_intel.c b/sound/pci/hda/hda_intel.c
595 +index 62fbdbe74b93..22c13ad6a9ae 100644
596 +--- a/sound/pci/hda/hda_intel.c
597 ++++ b/sound/pci/hda/hda_intel.c
598 +@@ -2205,7 +2205,7 @@ out_free:
599 + */
600 + static struct snd_pci_quirk power_save_blacklist[] = {
601 + /* https://bugzilla.redhat.com/show_bug.cgi?id=1525104 */
602 +- SND_PCI_QUIRK(0x1849, 0x0c0c, "Asrock B85M-ITX", 0),
603 ++ SND_PCI_QUIRK(0x1849, 0xc892, "Asrock B85M-ITX", 0),
604 + /* https://bugzilla.redhat.com/show_bug.cgi?id=1525104 */
605 + SND_PCI_QUIRK(0x1043, 0x8733, "Asus Prime X370-Pro", 0),
606 + /* https://bugzilla.redhat.com/show_bug.cgi?id=1572975 */
607 +diff --git a/sound/pci/hda/patch_conexant.c b/sound/pci/hda/patch_conexant.c
608 +index 88ce2f1022e1..16197ad4512a 100644
609 +--- a/sound/pci/hda/patch_conexant.c
610 ++++ b/sound/pci/hda/patch_conexant.c
611 +@@ -211,6 +211,7 @@ static void cx_auto_reboot_notify(struct hda_codec *codec)
612 + struct conexant_spec *spec = codec->spec;
613 +
614 + switch (codec->core.vendor_id) {
615 ++ case 0x14f12008: /* CX8200 */
616 + case 0x14f150f2: /* CX20722 */
617 + case 0x14f150f4: /* CX20724 */
618 + break;
619 +@@ -218,13 +219,14 @@ static void cx_auto_reboot_notify(struct hda_codec *codec)
620 + return;
621 + }
622 +
623 +- /* Turn the CX20722 codec into D3 to avoid spurious noises
624 ++ /* Turn the problematic codec into D3 to avoid spurious noises
625 + from the internal speaker during (and after) reboot */
626 + cx_auto_turn_eapd(codec, spec->num_eapds, spec->eapds, false);
627 +
628 + snd_hda_codec_set_power_to_all(codec, codec->core.afg, AC_PWRST_D3);
629 + snd_hda_codec_write(codec, codec->core.afg, 0,
630 + AC_VERB_SET_POWER_STATE, AC_PWRST_D3);
631 ++ msleep(10);
632 + }
633 +
634 + static void cx_auto_free(struct hda_codec *codec)
635 +diff --git a/sound/pci/vx222/vx222_ops.c b/sound/pci/vx222/vx222_ops.c
636 +index d4298af6d3ee..c0d0bf44f365 100644
637 +--- a/sound/pci/vx222/vx222_ops.c
638 ++++ b/sound/pci/vx222/vx222_ops.c
639 +@@ -275,7 +275,7 @@ static void vx2_dma_write(struct vx_core *chip, struct snd_pcm_runtime *runtime,
640 + length >>= 2; /* in 32bit words */
641 + /* Transfer using pseudo-dma. */
642 + for (; length > 0; length--) {
643 +- outl(cpu_to_le32(*addr), port);
644 ++ outl(*addr, port);
645 + addr++;
646 + }
647 + addr = (u32 *)runtime->dma_area;
648 +@@ -285,7 +285,7 @@ static void vx2_dma_write(struct vx_core *chip, struct snd_pcm_runtime *runtime,
649 + count >>= 2; /* in 32bit words */
650 + /* Transfer using pseudo-dma. */
651 + for (; count > 0; count--) {
652 +- outl(cpu_to_le32(*addr), port);
653 ++ outl(*addr, port);
654 + addr++;
655 + }
656 +
657 +@@ -313,7 +313,7 @@ static void vx2_dma_read(struct vx_core *chip, struct snd_pcm_runtime *runtime,
658 + length >>= 2; /* in 32bit words */
659 + /* Transfer using pseudo-dma. */
660 + for (; length > 0; length--)
661 +- *addr++ = le32_to_cpu(inl(port));
662 ++ *addr++ = inl(port);
663 + addr = (u32 *)runtime->dma_area;
664 + pipe->hw_ptr = 0;
665 + }
666 +@@ -321,7 +321,7 @@ static void vx2_dma_read(struct vx_core *chip, struct snd_pcm_runtime *runtime,
667 + count >>= 2; /* in 32bit words */
668 + /* Transfer using pseudo-dma. */
669 + for (; count > 0; count--)
670 +- *addr++ = le32_to_cpu(inl(port));
671 ++ *addr++ = inl(port);
672 +
673 + vx2_release_pseudo_dma(chip);
674 + }
675 +diff --git a/sound/pcmcia/vx/vxp_ops.c b/sound/pcmcia/vx/vxp_ops.c
676 +index 8cde40226355..4c4ef1fec69f 100644
677 +--- a/sound/pcmcia/vx/vxp_ops.c
678 ++++ b/sound/pcmcia/vx/vxp_ops.c
679 +@@ -375,7 +375,7 @@ static void vxp_dma_write(struct vx_core *chip, struct snd_pcm_runtime *runtime,
680 + length >>= 1; /* in 16bit words */
681 + /* Transfer using pseudo-dma. */
682 + for (; length > 0; length--) {
683 +- outw(cpu_to_le16(*addr), port);
684 ++ outw(*addr, port);
685 + addr++;
686 + }
687 + addr = (unsigned short *)runtime->dma_area;
688 +@@ -385,7 +385,7 @@ static void vxp_dma_write(struct vx_core *chip, struct snd_pcm_runtime *runtime,
689 + count >>= 1; /* in 16bit words */
690 + /* Transfer using pseudo-dma. */
691 + for (; count > 0; count--) {
692 +- outw(cpu_to_le16(*addr), port);
693 ++ outw(*addr, port);
694 + addr++;
695 + }
696 + vx_release_pseudo_dma(chip);
697 +@@ -417,7 +417,7 @@ static void vxp_dma_read(struct vx_core *chip, struct snd_pcm_runtime *runtime,
698 + length >>= 1; /* in 16bit words */
699 + /* Transfer using pseudo-dma. */
700 + for (; length > 0; length--)
701 +- *addr++ = le16_to_cpu(inw(port));
702 ++ *addr++ = inw(port);
703 + addr = (unsigned short *)runtime->dma_area;
704 + pipe->hw_ptr = 0;
705 + }
706 +@@ -425,12 +425,12 @@ static void vxp_dma_read(struct vx_core *chip, struct snd_pcm_runtime *runtime,
707 + count >>= 1; /* in 16bit words */
708 + /* Transfer using pseudo-dma. */
709 + for (; count > 1; count--)
710 +- *addr++ = le16_to_cpu(inw(port));
711 ++ *addr++ = inw(port);
712 + /* Disable DMA */
713 + pchip->regDIALOG &= ~VXP_DLG_DMAREAD_SEL_MASK;
714 + vx_outb(chip, DIALOG, pchip->regDIALOG);
715 + /* Read the last word (16 bits) */
716 +- *addr = le16_to_cpu(inw(port));
717 ++ *addr = inw(port);
718 + /* Disable 16-bit accesses */
719 + pchip->regDIALOG &= ~VXP_DLG_DMA16_SEL_MASK;
720 + vx_outb(chip, DIALOG, pchip->regDIALOG);