Gentoo Archives: gentoo-commits

From: Mike Pagano <mpagano@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] proj/linux-patches:4.19 commit in: /
Date: Wed, 18 May 2022 09:50:17
Message-Id: 1652867386.3921da7798e3803bbcbfcb34b3fc631326321161.mpagano@gentoo
1 commit: 3921da7798e3803bbcbfcb34b3fc631326321161
2 Author: Mike Pagano <mpagano <AT> gentoo <DOT> org>
3 AuthorDate: Wed May 18 09:49:46 2022 +0000
4 Commit: Mike Pagano <mpagano <AT> gentoo <DOT> org>
5 CommitDate: Wed May 18 09:49:46 2022 +0000
6 URL: https://gitweb.gentoo.org/proj/linux-patches.git/commit/?id=3921da77
7
8 Linux patch 4.19.244
9
10 Signed-off-by: Mike Pagano <mpagano <AT> gentoo.org>
11
12 0000_README | 4 +
13 1243_linux-4.19.244.patch | 708 ++++++++++++++++++++++++++++++++++++++++++++++
14 2 files changed, 712 insertions(+)
15
16 diff --git a/0000_README b/0000_README
17 index 5dc0a832..e473c6e1 100644
18 --- a/0000_README
19 +++ b/0000_README
20 @@ -1011,6 +1011,10 @@ Patch: 1242_linux-4.19.243.patch
21 From: https://www.kernel.org
22 Desc: Linux 4.19.243
23
24 +Patch: 1243_linux-4.19.244.patch
25 +From: https://www.kernel.org
26 +Desc: Linux 4.19.244
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/1243_linux-4.19.244.patch b/1243_linux-4.19.244.patch
33 new file mode 100644
34 index 00000000..a66f3a42
35 --- /dev/null
36 +++ b/1243_linux-4.19.244.patch
37 @@ -0,0 +1,708 @@
38 +diff --git a/Makefile b/Makefile
39 +index 6899a8fc4c466..ca86541c67394 100644
40 +--- a/Makefile
41 ++++ b/Makefile
42 +@@ -1,7 +1,7 @@
43 + # SPDX-License-Identifier: GPL-2.0
44 + VERSION = 4
45 + PATCHLEVEL = 19
46 +-SUBLEVEL = 243
47 ++SUBLEVEL = 244
48 + EXTRAVERSION =
49 + NAME = "People's Front"
50 +
51 +diff --git a/arch/mips/generic/board-ocelot_pcb123.its.S b/arch/mips/generic/board-ocelot_pcb123.its.S
52 +index 5a7d5e1c878af..6dd54b7c2f076 100644
53 +--- a/arch/mips/generic/board-ocelot_pcb123.its.S
54 ++++ b/arch/mips/generic/board-ocelot_pcb123.its.S
55 +@@ -1,23 +1,23 @@
56 + /* SPDX-License-Identifier: (GPL-2.0 OR MIT) */
57 + / {
58 + images {
59 +- fdt@ocelot_pcb123 {
60 ++ fdt-ocelot_pcb123 {
61 + description = "MSCC Ocelot PCB123 Device Tree";
62 + data = /incbin/("boot/dts/mscc/ocelot_pcb123.dtb");
63 + type = "flat_dt";
64 + arch = "mips";
65 + compression = "none";
66 +- hash@0 {
67 ++ hash {
68 + algo = "sha1";
69 + };
70 + };
71 + };
72 +
73 + configurations {
74 +- conf@ocelot_pcb123 {
75 ++ conf-ocelot_pcb123 {
76 + description = "Ocelot Linux kernel";
77 +- kernel = "kernel@0";
78 +- fdt = "fdt@ocelot_pcb123";
79 ++ kernel = "kernel";
80 ++ fdt = "fdt-ocelot_pcb123";
81 + };
82 + };
83 + };
84 +diff --git a/arch/s390/Makefile b/arch/s390/Makefile
85 +index 9a3a698c8fca5..4d0082f3de47d 100644
86 +--- a/arch/s390/Makefile
87 ++++ b/arch/s390/Makefile
88 +@@ -27,6 +27,16 @@ KBUILD_CFLAGS_DECOMPRESSOR += $(call cc-option,-ffreestanding)
89 + KBUILD_CFLAGS_DECOMPRESSOR += $(call cc-disable-warning, address-of-packed-member)
90 + KBUILD_CFLAGS_DECOMPRESSOR += $(if $(CONFIG_DEBUG_INFO),-g)
91 + KBUILD_CFLAGS_DECOMPRESSOR += $(if $(CONFIG_DEBUG_INFO_DWARF4), $(call cc-option, -gdwarf-4,))
92 ++
93 ++ifdef CONFIG_CC_IS_GCC
94 ++ ifeq ($(call cc-ifversion, -ge, 1200, y), y)
95 ++ ifeq ($(call cc-ifversion, -lt, 1300, y), y)
96 ++ KBUILD_CFLAGS += $(call cc-disable-warning, array-bounds)
97 ++ KBUILD_CFLAGS_DECOMPRESSOR += $(call cc-disable-warning, array-bounds)
98 ++ endif
99 ++ endif
100 ++endif
101 ++
102 + UTS_MACHINE := s390x
103 + STACK_SIZE := 16384
104 + CHECKFLAGS += -D__s390__ -D__s390x__
105 +diff --git a/drivers/gpu/drm/vmwgfx/vmwgfx_fb.c b/drivers/gpu/drm/vmwgfx/vmwgfx_fb.c
106 +index 2a9112515f464..2fe48e3158ddd 100644
107 +--- a/drivers/gpu/drm/vmwgfx/vmwgfx_fb.c
108 ++++ b/drivers/gpu/drm/vmwgfx/vmwgfx_fb.c
109 +@@ -498,7 +498,7 @@ static int vmw_fb_kms_detach(struct vmw_fb_par *par,
110 +
111 + static int vmw_fb_kms_framebuffer(struct fb_info *info)
112 + {
113 +- struct drm_mode_fb_cmd2 mode_cmd;
114 ++ struct drm_mode_fb_cmd2 mode_cmd = {0};
115 + struct vmw_fb_par *par = info->par;
116 + struct fb_var_screeninfo *var = &info->var;
117 + struct drm_framebuffer *cur_fb;
118 +diff --git a/drivers/hwmon/Kconfig b/drivers/hwmon/Kconfig
119 +index c7adaca2ab013..d150d0cab1b6f 100644
120 +--- a/drivers/hwmon/Kconfig
121 ++++ b/drivers/hwmon/Kconfig
122 +@@ -791,7 +791,7 @@ config SENSORS_LTC4261
123 +
124 + config SENSORS_LTQ_CPUTEMP
125 + bool "Lantiq cpu temperature sensor driver"
126 +- depends on LANTIQ
127 ++ depends on SOC_XWAY
128 + help
129 + If you say yes here you get support for the temperature
130 + sensor inside your CPU.
131 +diff --git a/drivers/hwmon/f71882fg.c b/drivers/hwmon/f71882fg.c
132 +index ca54ce5c8e10c..4010b61743f5b 100644
133 +--- a/drivers/hwmon/f71882fg.c
134 ++++ b/drivers/hwmon/f71882fg.c
135 +@@ -1590,8 +1590,9 @@ static ssize_t show_temp(struct device *dev, struct device_attribute *devattr,
136 + temp *= 125;
137 + if (sign)
138 + temp -= 128000;
139 +- } else
140 +- temp = data->temp[nr] * 1000;
141 ++ } else {
142 ++ temp = ((s8)data->temp[nr]) * 1000;
143 ++ }
144 +
145 + return sprintf(buf, "%d\n", temp);
146 + }
147 +diff --git a/drivers/hwmon/tmp401.c b/drivers/hwmon/tmp401.c
148 +index 1f2d13dc94396..99b0d7e0a27ab 100644
149 +--- a/drivers/hwmon/tmp401.c
150 ++++ b/drivers/hwmon/tmp401.c
151 +@@ -756,10 +756,21 @@ static int tmp401_probe(struct i2c_client *client,
152 + return 0;
153 + }
154 +
155 ++static const struct of_device_id __maybe_unused tmp4xx_of_match[] = {
156 ++ { .compatible = "ti,tmp401", },
157 ++ { .compatible = "ti,tmp411", },
158 ++ { .compatible = "ti,tmp431", },
159 ++ { .compatible = "ti,tmp432", },
160 ++ { .compatible = "ti,tmp435", },
161 ++ { },
162 ++};
163 ++MODULE_DEVICE_TABLE(of, tmp4xx_of_match);
164 ++
165 + static struct i2c_driver tmp401_driver = {
166 + .class = I2C_CLASS_HWMON,
167 + .driver = {
168 + .name = "tmp401",
169 ++ .of_match_table = of_match_ptr(tmp4xx_of_match),
170 + },
171 + .probe = tmp401_probe,
172 + .id_table = tmp401_id,
173 +diff --git a/drivers/net/ethernet/sfc/ef10.c b/drivers/net/ethernet/sfc/ef10.c
174 +index 1f971d31ec302..6b0a4dc1ced14 100644
175 +--- a/drivers/net/ethernet/sfc/ef10.c
176 ++++ b/drivers/net/ethernet/sfc/ef10.c
177 +@@ -6146,6 +6146,11 @@ static int efx_ef10_mtd_probe(struct efx_nic *efx)
178 + n_parts++;
179 + }
180 +
181 ++ if (!n_parts) {
182 ++ kfree(parts);
183 ++ return 0;
184 ++ }
185 ++
186 + rc = efx_mtd_add(efx, &parts[0].common, n_parts, sizeof(*parts));
187 + fail:
188 + if (rc)
189 +diff --git a/drivers/net/wireless/mac80211_hwsim.c b/drivers/net/wireless/mac80211_hwsim.c
190 +index c84ee5ba53812..3d8e17bb8a101 100644
191 +--- a/drivers/net/wireless/mac80211_hwsim.c
192 ++++ b/drivers/net/wireless/mac80211_hwsim.c
193 +@@ -2082,11 +2082,13 @@ static void hw_scan_work(struct work_struct *work)
194 + if (req->ie_len)
195 + skb_put_data(probe, req->ie, req->ie_len);
196 +
197 ++ rcu_read_lock();
198 + if (!ieee80211_tx_prepare_skb(hwsim->hw,
199 + hwsim->hw_scan_vif,
200 + probe,
201 + hwsim->tmp_chan->band,
202 + NULL)) {
203 ++ rcu_read_unlock();
204 + kfree_skb(probe);
205 + continue;
206 + }
207 +@@ -2094,6 +2096,7 @@ static void hw_scan_work(struct work_struct *work)
208 + local_bh_disable();
209 + mac80211_hwsim_tx_frame(hwsim->hw, probe,
210 + hwsim->tmp_chan);
211 ++ rcu_read_unlock();
212 + local_bh_enable();
213 + }
214 + }
215 +diff --git a/drivers/s390/net/ctcm_mpc.c b/drivers/s390/net/ctcm_mpc.c
216 +index e02f295d38a9b..07d9668137df3 100644
217 +--- a/drivers/s390/net/ctcm_mpc.c
218 ++++ b/drivers/s390/net/ctcm_mpc.c
219 +@@ -625,8 +625,6 @@ static void mpc_rcvd_sweep_resp(struct mpcg_info *mpcginfo)
220 + ctcm_clear_busy_do(dev);
221 + }
222 +
223 +- kfree(mpcginfo);
224 +-
225 + return;
226 +
227 + }
228 +@@ -1205,10 +1203,10 @@ static void ctcmpc_unpack_skb(struct channel *ch, struct sk_buff *pskb)
229 + CTCM_FUNTAIL, dev->name);
230 + priv->stats.rx_dropped++;
231 + /* mpcginfo only used for non-data transfers */
232 +- kfree(mpcginfo);
233 + if (do_debug_data)
234 + ctcmpc_dump_skb(pskb, -8);
235 + }
236 ++ kfree(mpcginfo);
237 + }
238 + done:
239 +
240 +@@ -1991,7 +1989,6 @@ static void mpc_action_rcvd_xid0(fsm_instance *fsm, int event, void *arg)
241 + }
242 + break;
243 + }
244 +- kfree(mpcginfo);
245 +
246 + CTCM_PR_DEBUG("ctcmpc:%s() %s xid2:%i xid7:%i xidt_p2:%i \n",
247 + __func__, ch->id, grp->outstanding_xid2,
248 +@@ -2052,7 +2049,6 @@ static void mpc_action_rcvd_xid7(fsm_instance *fsm, int event, void *arg)
249 + mpc_validate_xid(mpcginfo);
250 + break;
251 + }
252 +- kfree(mpcginfo);
253 + return;
254 + }
255 +
256 +diff --git a/drivers/s390/net/ctcm_sysfs.c b/drivers/s390/net/ctcm_sysfs.c
257 +index ded1930a00b2d..e3813a7aa5e68 100644
258 +--- a/drivers/s390/net/ctcm_sysfs.c
259 ++++ b/drivers/s390/net/ctcm_sysfs.c
260 +@@ -39,11 +39,12 @@ static ssize_t ctcm_buffer_write(struct device *dev,
261 + struct ctcm_priv *priv = dev_get_drvdata(dev);
262 + int rc;
263 +
264 +- ndev = priv->channel[CTCM_READ]->netdev;
265 +- if (!(priv && priv->channel[CTCM_READ] && ndev)) {
266 ++ if (!(priv && priv->channel[CTCM_READ] &&
267 ++ priv->channel[CTCM_READ]->netdev)) {
268 + CTCM_DBF_TEXT(SETUP, CTC_DBF_ERROR, "bfnondev");
269 + return -ENODEV;
270 + }
271 ++ ndev = priv->channel[CTCM_READ]->netdev;
272 +
273 + rc = kstrtouint(buf, 0, &bs1);
274 + if (rc)
275 +diff --git a/drivers/s390/net/lcs.c b/drivers/s390/net/lcs.c
276 +index 2d9fe7e4ee400..d8f99ff53a94f 100644
277 +--- a/drivers/s390/net/lcs.c
278 ++++ b/drivers/s390/net/lcs.c
279 +@@ -1735,10 +1735,11 @@ lcs_get_control(struct lcs_card *card, struct lcs_cmd *cmd)
280 + lcs_schedule_recovery(card);
281 + break;
282 + case LCS_CMD_STOPLAN:
283 +- pr_warn("Stoplan for %s initiated by LGW\n",
284 +- card->dev->name);
285 +- if (card->dev)
286 ++ if (card->dev) {
287 ++ pr_warn("Stoplan for %s initiated by LGW\n",
288 ++ card->dev->name);
289 + netif_carrier_off(card->dev);
290 ++ }
291 + break;
292 + default:
293 + LCS_DBF_TEXT(5, trace, "noLGWcmd");
294 +diff --git a/drivers/slimbus/qcom-ctrl.c b/drivers/slimbus/qcom-ctrl.c
295 +index db1f5135846aa..3140adf1c5ad8 100644
296 +--- a/drivers/slimbus/qcom-ctrl.c
297 ++++ b/drivers/slimbus/qcom-ctrl.c
298 +@@ -515,9 +515,9 @@ static int qcom_slim_probe(struct platform_device *pdev)
299 + }
300 +
301 + ctrl->irq = platform_get_irq(pdev, 0);
302 +- if (!ctrl->irq) {
303 ++ if (ctrl->irq < 0) {
304 + dev_err(&pdev->dev, "no slimbus IRQ\n");
305 +- return -ENODEV;
306 ++ return ctrl->irq;
307 + }
308 +
309 + sctrl = &ctrl->ctrl;
310 +diff --git a/drivers/tty/serial/digicolor-usart.c b/drivers/tty/serial/digicolor-usart.c
311 +index 13ac36e2da4f0..4446c13629b1c 100644
312 +--- a/drivers/tty/serial/digicolor-usart.c
313 ++++ b/drivers/tty/serial/digicolor-usart.c
314 +@@ -472,10 +472,10 @@ static int digicolor_uart_probe(struct platform_device *pdev)
315 + return PTR_ERR(uart_clk);
316 +
317 + res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
318 +- dp->port.mapbase = res->start;
319 + dp->port.membase = devm_ioremap_resource(&pdev->dev, res);
320 + if (IS_ERR(dp->port.membase))
321 + return PTR_ERR(dp->port.membase);
322 ++ dp->port.mapbase = res->start;
323 +
324 + irq = platform_get_irq(pdev, 0);
325 + if (irq < 0)
326 +diff --git a/drivers/usb/class/cdc-wdm.c b/drivers/usb/class/cdc-wdm.c
327 +index 48e775fff16d6..b60a4200fc2be 100644
328 +--- a/drivers/usb/class/cdc-wdm.c
329 ++++ b/drivers/usb/class/cdc-wdm.c
330 +@@ -755,6 +755,7 @@ static int wdm_release(struct inode *inode, struct file *file)
331 + poison_urbs(desc);
332 + spin_lock_irq(&desc->iuspin);
333 + desc->resp_count = 0;
334 ++ clear_bit(WDM_RESPONDING, &desc->flags);
335 + spin_unlock_irq(&desc->iuspin);
336 + desc->manage_power(desc->intf, 0);
337 + unpoison_urbs(desc);
338 +diff --git a/drivers/usb/serial/option.c b/drivers/usb/serial/option.c
339 +index cf77ec17ef3f4..0699b770e058c 100644
340 +--- a/drivers/usb/serial/option.c
341 ++++ b/drivers/usb/serial/option.c
342 +@@ -2123,10 +2123,14 @@ static const struct usb_device_id option_ids[] = {
343 + .driver_info = RSVD(3) },
344 + { USB_DEVICE(0x1508, 0x1001), /* Fibocom NL668 (IOT version) */
345 + .driver_info = RSVD(4) | RSVD(5) | RSVD(6) },
346 ++ { USB_DEVICE(0x1782, 0x4d10) }, /* Fibocom L610 (AT mode) */
347 ++ { USB_DEVICE_INTERFACE_CLASS(0x1782, 0x4d11, 0xff) }, /* Fibocom L610 (ECM/RNDIS mode) */
348 + { USB_DEVICE(0x2cb7, 0x0104), /* Fibocom NL678 series */
349 + .driver_info = RSVD(4) | RSVD(5) },
350 + { USB_DEVICE_INTERFACE_CLASS(0x2cb7, 0x0105, 0xff), /* Fibocom NL678 series */
351 + .driver_info = RSVD(6) },
352 ++ { USB_DEVICE_INTERFACE_CLASS(0x2cb7, 0x0106, 0xff) }, /* Fibocom MA510 (ECM mode w/ diag intf.) */
353 ++ { USB_DEVICE_INTERFACE_CLASS(0x2cb7, 0x010a, 0xff) }, /* Fibocom MA510 (ECM mode) */
354 + { USB_DEVICE_AND_INTERFACE_INFO(0x2cb7, 0x010b, 0xff, 0xff, 0x30) }, /* Fibocom FG150 Diag */
355 + { USB_DEVICE_AND_INTERFACE_INFO(0x2cb7, 0x010b, 0xff, 0, 0) }, /* Fibocom FG150 AT */
356 + { USB_DEVICE_INTERFACE_CLASS(0x2cb7, 0x01a0, 0xff) }, /* Fibocom NL668-AM/NL652-EU (laptop MBIM) */
357 +diff --git a/drivers/usb/serial/pl2303.c b/drivers/usb/serial/pl2303.c
358 +index 2e8cb6d8ba41f..4bbccc30748a2 100644
359 +--- a/drivers/usb/serial/pl2303.c
360 ++++ b/drivers/usb/serial/pl2303.c
361 +@@ -100,6 +100,7 @@ static const struct usb_device_id id_table[] = {
362 + { USB_DEVICE(HP_VENDOR_ID, HP_LCM220_PRODUCT_ID) },
363 + { USB_DEVICE(HP_VENDOR_ID, HP_LCM960_PRODUCT_ID) },
364 + { USB_DEVICE(HP_VENDOR_ID, HP_LM920_PRODUCT_ID) },
365 ++ { USB_DEVICE(HP_VENDOR_ID, HP_LM930_PRODUCT_ID) },
366 + { USB_DEVICE(HP_VENDOR_ID, HP_LM940_PRODUCT_ID) },
367 + { USB_DEVICE(HP_VENDOR_ID, HP_TD620_PRODUCT_ID) },
368 + { USB_DEVICE(CRESSI_VENDOR_ID, CRESSI_EDY_PRODUCT_ID) },
369 +diff --git a/drivers/usb/serial/pl2303.h b/drivers/usb/serial/pl2303.h
370 +index 15f746e977a71..873e50088a36e 100644
371 +--- a/drivers/usb/serial/pl2303.h
372 ++++ b/drivers/usb/serial/pl2303.h
373 +@@ -129,6 +129,7 @@
374 + #define HP_TD620_PRODUCT_ID 0x0956
375 + #define HP_LD960_PRODUCT_ID 0x0b39
376 + #define HP_LD381_PRODUCT_ID 0x0f7f
377 ++#define HP_LM930_PRODUCT_ID 0x0f9b
378 + #define HP_LCM220_PRODUCT_ID 0x3139
379 + #define HP_LCM960_PRODUCT_ID 0x3239
380 + #define HP_LD220_PRODUCT_ID 0x3524
381 +diff --git a/drivers/usb/serial/qcserial.c b/drivers/usb/serial/qcserial.c
382 +index b1b9923162a04..3f437f07356b4 100644
383 +--- a/drivers/usb/serial/qcserial.c
384 ++++ b/drivers/usb/serial/qcserial.c
385 +@@ -166,6 +166,8 @@ static const struct usb_device_id id_table[] = {
386 + {DEVICE_SWI(0x1199, 0x9090)}, /* Sierra Wireless EM7565 QDL */
387 + {DEVICE_SWI(0x1199, 0x9091)}, /* Sierra Wireless EM7565 */
388 + {DEVICE_SWI(0x1199, 0x90d2)}, /* Sierra Wireless EM9191 QDL */
389 ++ {DEVICE_SWI(0x1199, 0xc080)}, /* Sierra Wireless EM7590 QDL */
390 ++ {DEVICE_SWI(0x1199, 0xc081)}, /* Sierra Wireless EM7590 */
391 + {DEVICE_SWI(0x413c, 0x81a2)}, /* Dell Wireless 5806 Gobi(TM) 4G LTE Mobile Broadband Card */
392 + {DEVICE_SWI(0x413c, 0x81a3)}, /* Dell Wireless 5570 HSPA+ (42Mbps) Mobile Broadband Card */
393 + {DEVICE_SWI(0x413c, 0x81a4)}, /* Dell Wireless 5570e HSPA+ (42Mbps) Mobile Broadband Card */
394 +diff --git a/drivers/usb/typec/tcpci.c b/drivers/usb/typec/tcpci.c
395 +index 2c34add377085..9f98376d9bef4 100644
396 +--- a/drivers/usb/typec/tcpci.c
397 ++++ b/drivers/usb/typec/tcpci.c
398 +@@ -601,7 +601,7 @@ static int tcpci_remove(struct i2c_client *client)
399 + /* Disable chip interrupts before unregistering port */
400 + err = tcpci_write16(chip->tcpci, TCPC_ALERT_MASK, 0);
401 + if (err < 0)
402 +- return err;
403 ++ dev_warn(&client->dev, "Failed to disable irqs (%pe)\n", ERR_PTR(err));
404 +
405 + tcpci_unregister_port(chip->tcpci);
406 +
407 +diff --git a/fs/gfs2/bmap.c b/fs/gfs2/bmap.c
408 +index 53ba5019ad063..150cec85c416d 100644
409 +--- a/fs/gfs2/bmap.c
410 ++++ b/fs/gfs2/bmap.c
411 +@@ -1168,13 +1168,12 @@ static int gfs2_iomap_end(struct inode *inode, loff_t pos, loff_t length,
412 +
413 + if (length != written && (iomap->flags & IOMAP_F_NEW)) {
414 + /* Deallocate blocks that were just allocated. */
415 +- loff_t blockmask = i_blocksize(inode) - 1;
416 +- loff_t end = (pos + length) & ~blockmask;
417 ++ loff_t hstart = round_up(pos + written, i_blocksize(inode));
418 ++ loff_t hend = iomap->offset + iomap->length;
419 +
420 +- pos = (pos + written + blockmask) & ~blockmask;
421 +- if (pos < end) {
422 +- truncate_pagecache_range(inode, pos, end - 1);
423 +- punch_hole(ip, pos, end - pos);
424 ++ if (hstart < hend) {
425 ++ truncate_pagecache_range(inode, hstart, hend - 1);
426 ++ punch_hole(ip, hstart, hend - hstart);
427 + }
428 + }
429 +
430 +diff --git a/include/linux/netdev_features.h b/include/linux/netdev_features.h
431 +index 2a8105d204a96..78411dc4a040f 100644
432 +--- a/include/linux/netdev_features.h
433 ++++ b/include/linux/netdev_features.h
434 +@@ -156,7 +156,7 @@ enum {
435 + #define NETIF_F_HW_TLS_TX __NETIF_F(HW_TLS_TX)
436 + #define NETIF_F_HW_TLS_RX __NETIF_F(HW_TLS_RX)
437 +
438 +-/* Finds the next feature with the highest number of the range of start till 0.
439 ++/* Finds the next feature with the highest number of the range of start-1 till 0.
440 + */
441 + static inline int find_next_netdev_feature(u64 feature, unsigned long start)
442 + {
443 +@@ -175,7 +175,7 @@ static inline int find_next_netdev_feature(u64 feature, unsigned long start)
444 + for ((bit) = find_next_netdev_feature((mask_addr), \
445 + NETDEV_FEATURE_COUNT); \
446 + (bit) >= 0; \
447 +- (bit) = find_next_netdev_feature((mask_addr), (bit) - 1))
448 ++ (bit) = find_next_netdev_feature((mask_addr), (bit)))
449 +
450 + /* Features valid for ethtool to change */
451 + /* = all defined minus driver/device-class-related */
452 +diff --git a/include/net/tc_act/tc_pedit.h b/include/net/tc_act/tc_pedit.h
453 +index fac3ad4a86de9..bd74e94527a2a 100644
454 +--- a/include/net/tc_act/tc_pedit.h
455 ++++ b/include/net/tc_act/tc_pedit.h
456 +@@ -14,6 +14,7 @@ struct tcf_pedit {
457 + struct tc_action common;
458 + unsigned char tcfp_nkeys;
459 + unsigned char tcfp_flags;
460 ++ u32 tcfp_off_max_hint;
461 + struct tc_pedit_key *tcfp_keys;
462 + struct tcf_pedit_key_ex *tcfp_keys_ex;
463 + };
464 +diff --git a/kernel/cgroup/cpuset.c b/kernel/cgroup/cpuset.c
465 +index 153628277a487..dcd5755b1fe2a 100644
466 +--- a/kernel/cgroup/cpuset.c
467 ++++ b/kernel/cgroup/cpuset.c
468 +@@ -2403,8 +2403,11 @@ static struct notifier_block cpuset_track_online_nodes_nb = {
469 + */
470 + void __init cpuset_init_smp(void)
471 + {
472 +- cpumask_copy(top_cpuset.cpus_allowed, cpu_active_mask);
473 +- top_cpuset.mems_allowed = node_states[N_MEMORY];
474 ++ /*
475 ++ * cpus_allowd/mems_allowed set to v2 values in the initial
476 ++ * cpuset_bind() call will be reset to v1 values in another
477 ++ * cpuset_bind() call when v1 cpuset is mounted.
478 ++ */
479 + top_cpuset.old_mems_allowed = top_cpuset.mems_allowed;
480 +
481 + cpumask_copy(top_cpuset.effective_cpus, cpu_active_mask);
482 +diff --git a/net/batman-adv/fragmentation.c b/net/batman-adv/fragmentation.c
483 +index cc062b69fc8d8..a62eedf889eb3 100644
484 +--- a/net/batman-adv/fragmentation.c
485 ++++ b/net/batman-adv/fragmentation.c
486 +@@ -490,6 +490,17 @@ int batadv_frag_send_packet(struct sk_buff *skb,
487 + goto free_skb;
488 + }
489 +
490 ++ /* GRO might have added fragments to the fragment list instead of
491 ++ * frags[]. But this is not handled by skb_split and must be
492 ++ * linearized to avoid incorrect length information after all
493 ++ * batman-adv fragments were created and submitted to the
494 ++ * hard-interface
495 ++ */
496 ++ if (skb_has_frag_list(skb) && __skb_linearize(skb)) {
497 ++ ret = -ENOMEM;
498 ++ goto free_skb;
499 ++ }
500 ++
501 + /* Create one header to be copied to all fragments */
502 + frag_header.packet_type = BATADV_UNICAST_FRAG;
503 + frag_header.version = BATADV_COMPAT_VERSION;
504 +diff --git a/net/core/secure_seq.c b/net/core/secure_seq.c
505 +index af6ad467ed615..3a8128341e6ac 100644
506 +--- a/net/core/secure_seq.c
507 ++++ b/net/core/secure_seq.c
508 +@@ -22,6 +22,8 @@
509 + static siphash_key_t net_secret __read_mostly;
510 + static siphash_key_t ts_secret __read_mostly;
511 +
512 ++#define EPHEMERAL_PORT_SHUFFLE_PERIOD (10 * HZ)
513 ++
514 + static __always_inline void net_secret_init(void)
515 + {
516 + net_get_random_once(&net_secret, sizeof(net_secret));
517 +@@ -100,11 +102,13 @@ u32 secure_ipv6_port_ephemeral(const __be32 *saddr, const __be32 *daddr,
518 + const struct {
519 + struct in6_addr saddr;
520 + struct in6_addr daddr;
521 ++ unsigned int timeseed;
522 + __be16 dport;
523 + } __aligned(SIPHASH_ALIGNMENT) combined = {
524 + .saddr = *(struct in6_addr *)saddr,
525 + .daddr = *(struct in6_addr *)daddr,
526 +- .dport = dport
527 ++ .timeseed = jiffies / EPHEMERAL_PORT_SHUFFLE_PERIOD,
528 ++ .dport = dport,
529 + };
530 + net_secret_init();
531 + return siphash(&combined, offsetofend(typeof(combined), dport),
532 +@@ -145,8 +149,10 @@ EXPORT_SYMBOL_GPL(secure_tcp_seq);
533 + u32 secure_ipv4_port_ephemeral(__be32 saddr, __be32 daddr, __be16 dport)
534 + {
535 + net_secret_init();
536 +- return siphash_3u32((__force u32)saddr, (__force u32)daddr,
537 +- (__force u16)dport, &net_secret);
538 ++ return siphash_4u32((__force u32)saddr, (__force u32)daddr,
539 ++ (__force u16)dport,
540 ++ jiffies / EPHEMERAL_PORT_SHUFFLE_PERIOD,
541 ++ &net_secret);
542 + }
543 + EXPORT_SYMBOL_GPL(secure_ipv4_port_ephemeral);
544 + #endif
545 +diff --git a/net/ipv4/ping.c b/net/ipv4/ping.c
546 +index b068eb01fe993..2e7abad48d83c 100644
547 +--- a/net/ipv4/ping.c
548 ++++ b/net/ipv4/ping.c
549 +@@ -309,6 +309,7 @@ static int ping_check_bind_addr(struct sock *sk, struct inet_sock *isk,
550 + struct net *net = sock_net(sk);
551 + if (sk->sk_family == AF_INET) {
552 + struct sockaddr_in *addr = (struct sockaddr_in *) uaddr;
553 ++ u32 tb_id = RT_TABLE_LOCAL;
554 + int chk_addr_ret;
555 +
556 + if (addr_len < sizeof(*addr))
557 +@@ -322,7 +323,8 @@ static int ping_check_bind_addr(struct sock *sk, struct inet_sock *isk,
558 + pr_debug("ping_check_bind_addr(sk=%p,addr=%pI4,port=%d)\n",
559 + sk, &addr->sin_addr.s_addr, ntohs(addr->sin_port));
560 +
561 +- chk_addr_ret = inet_addr_type(net, addr->sin_addr.s_addr);
562 ++ tb_id = l3mdev_fib_table_by_index(net, sk->sk_bound_dev_if) ? : tb_id;
563 ++ chk_addr_ret = inet_addr_type_table(net, addr->sin_addr.s_addr, tb_id);
564 +
565 + if (addr->sin_addr.s_addr == htonl(INADDR_ANY))
566 + chk_addr_ret = RTN_LOCAL;
567 +@@ -363,6 +365,14 @@ static int ping_check_bind_addr(struct sock *sk, struct inet_sock *isk,
568 + return -ENODEV;
569 + }
570 + }
571 ++
572 ++ if (!dev && sk->sk_bound_dev_if) {
573 ++ dev = dev_get_by_index_rcu(net, sk->sk_bound_dev_if);
574 ++ if (!dev) {
575 ++ rcu_read_unlock();
576 ++ return -ENODEV;
577 ++ }
578 ++ }
579 + has_addr = pingv6_ops.ipv6_chk_addr(net, &addr->sin6_addr, dev,
580 + scoped);
581 + rcu_read_unlock();
582 +diff --git a/net/ipv4/route.c b/net/ipv4/route.c
583 +index b41d4acc57e69..d7f17581df7da 100644
584 +--- a/net/ipv4/route.c
585 ++++ b/net/ipv4/route.c
586 +@@ -1728,6 +1728,7 @@ static int ip_route_input_mc(struct sk_buff *skb, __be32 daddr, __be32 saddr,
587 + #endif
588 + RT_CACHE_STAT_INC(in_slow_mc);
589 +
590 ++ skb_dst_drop(skb);
591 + skb_dst_set(skb, &rth->dst);
592 + return 0;
593 + }
594 +diff --git a/net/netlink/af_netlink.c b/net/netlink/af_netlink.c
595 +index e2120221b9578..6ffa83319d08b 100644
596 +--- a/net/netlink/af_netlink.c
597 ++++ b/net/netlink/af_netlink.c
598 +@@ -1978,7 +1978,6 @@ static int netlink_recvmsg(struct socket *sock, struct msghdr *msg, size_t len,
599 + copied = len;
600 + }
601 +
602 +- skb_reset_transport_header(data_skb);
603 + err = skb_copy_datagram_msg(data_skb, 0, msg, copied);
604 +
605 + if (msg->msg_name) {
606 +diff --git a/net/sched/act_pedit.c b/net/sched/act_pedit.c
607 +index ce14fafb36a1c..fec0f7fdb015d 100644
608 +--- a/net/sched/act_pedit.c
609 ++++ b/net/sched/act_pedit.c
610 +@@ -148,7 +148,7 @@ static int tcf_pedit_init(struct net *net, struct nlattr *nla,
611 + struct nlattr *pattr;
612 + struct tcf_pedit *p;
613 + int ret = 0, err;
614 +- int ksize;
615 ++ int i, ksize;
616 + u32 index;
617 +
618 + if (!nla) {
619 +@@ -221,6 +221,18 @@ static int tcf_pedit_init(struct net *net, struct nlattr *nla,
620 + p->tcfp_nkeys = parm->nkeys;
621 + }
622 + memcpy(p->tcfp_keys, parm->keys, ksize);
623 ++ p->tcfp_off_max_hint = 0;
624 ++ for (i = 0; i < p->tcfp_nkeys; ++i) {
625 ++ u32 cur = p->tcfp_keys[i].off;
626 ++
627 ++ /* The AT option can read a single byte, we can bound the actual
628 ++ * value with uchar max.
629 ++ */
630 ++ cur += (0xff & p->tcfp_keys[i].offmask) >> p->tcfp_keys[i].shift;
631 ++
632 ++ /* Each key touches 4 bytes starting from the computed offset */
633 ++ p->tcfp_off_max_hint = max(p->tcfp_off_max_hint, cur + 4);
634 ++ }
635 +
636 + p->tcfp_flags = parm->flags;
637 + p->tcf_action = parm->action;
638 +@@ -298,13 +310,18 @@ static int tcf_pedit_act(struct sk_buff *skb, const struct tc_action *a,
639 + struct tcf_result *res)
640 + {
641 + struct tcf_pedit *p = to_pedit(a);
642 ++ u32 max_offset;
643 + int i;
644 +
645 +- if (skb_unclone(skb, GFP_ATOMIC))
646 +- return p->tcf_action;
647 +-
648 + spin_lock(&p->tcf_lock);
649 +
650 ++ max_offset = (skb_transport_header_was_set(skb) ?
651 ++ skb_transport_offset(skb) :
652 ++ skb_network_offset(skb)) +
653 ++ p->tcfp_off_max_hint;
654 ++ if (skb_ensure_writable(skb, min(skb->len, max_offset)))
655 ++ goto unlock;
656 ++
657 + tcf_lastuse_update(&p->tcf_tm);
658 +
659 + if (p->tcfp_nkeys > 0) {
660 +@@ -393,6 +410,7 @@ bad:
661 + p->tcf_qstats.overlimits++;
662 + done:
663 + bstats_update(&p->tcf_bstats, skb);
664 ++unlock:
665 + spin_unlock(&p->tcf_lock);
666 + return p->tcf_action;
667 + }
668 +diff --git a/net/smc/smc_rx.c b/net/smc/smc_rx.c
669 +index 36340912df48a..a7a4e3ce211a2 100644
670 +--- a/net/smc/smc_rx.c
671 ++++ b/net/smc/smc_rx.c
672 +@@ -349,12 +349,12 @@ int smc_rx_recvmsg(struct smc_sock *smc, struct msghdr *msg,
673 + }
674 + break;
675 + }
676 ++ if (!timeo)
677 ++ return -EAGAIN;
678 + if (signal_pending(current)) {
679 + read_done = sock_intr_errno(timeo);
680 + break;
681 + }
682 +- if (!timeo)
683 +- return -EAGAIN;
684 + }
685 +
686 + if (!smc_rx_data_available(conn)) {
687 +diff --git a/sound/soc/codecs/max98090.c b/sound/soc/codecs/max98090.c
688 +index a5b0c40ee545f..b9f15a260c789 100644
689 +--- a/sound/soc/codecs/max98090.c
690 ++++ b/sound/soc/codecs/max98090.c
691 +@@ -419,6 +419,9 @@ static int max98090_put_enab_tlv(struct snd_kcontrol *kcontrol,
692 +
693 + val = (val >> mc->shift) & mask;
694 +
695 ++ if (sel < 0 || sel > mc->max)
696 ++ return -EINVAL;
697 ++
698 + *select = sel;
699 +
700 + /* Setting a volume is only valid if it is already On */
701 +@@ -433,7 +436,7 @@ static int max98090_put_enab_tlv(struct snd_kcontrol *kcontrol,
702 + mask << mc->shift,
703 + sel << mc->shift);
704 +
705 +- return 0;
706 ++ return *select != val;
707 + }
708 +
709 + static const char *max98090_perf_pwr_text[] =
710 +diff --git a/sound/soc/soc-ops.c b/sound/soc/soc-ops.c
711 +index c88bc6bb41cfe..7a37312c8e0c2 100644
712 +--- a/sound/soc/soc-ops.c
713 ++++ b/sound/soc/soc-ops.c
714 +@@ -523,7 +523,15 @@ int snd_soc_put_volsw_range(struct snd_kcontrol *kcontrol,
715 + unsigned int mask = (1 << fls(max)) - 1;
716 + unsigned int invert = mc->invert;
717 + unsigned int val, val_mask;
718 +- int err, ret;
719 ++ int err, ret, tmp;
720 ++
721 ++ tmp = ucontrol->value.integer.value[0];
722 ++ if (tmp < 0)
723 ++ return -EINVAL;
724 ++ if (mc->platform_max && tmp > mc->platform_max)
725 ++ return -EINVAL;
726 ++ if (tmp > mc->max - mc->min + 1)
727 ++ return -EINVAL;
728 +
729 + if (invert)
730 + val = (max - ucontrol->value.integer.value[0]) & mask;
731 +@@ -538,6 +546,14 @@ int snd_soc_put_volsw_range(struct snd_kcontrol *kcontrol,
732 + ret = err;
733 +
734 + if (snd_soc_volsw_is_stereo(mc)) {
735 ++ tmp = ucontrol->value.integer.value[1];
736 ++ if (tmp < 0)
737 ++ return -EINVAL;
738 ++ if (mc->platform_max && tmp > mc->platform_max)
739 ++ return -EINVAL;
740 ++ if (tmp > mc->max - mc->min + 1)
741 ++ return -EINVAL;
742 ++
743 + if (invert)
744 + val = (max - ucontrol->value.integer.value[1]) & mask;
745 + else