From 0eff6509d21617ec97f4723119f3f87b7b7f840a Mon Sep 17 00:00:00 2001 From: Sasha Levin Date: Fri, 26 Jun 2020 14:07:36 -0400 Subject: [PATCH] Fixes for 4.19 Signed-off-by: Sasha Levin --- ...-add-headset-button-supported-for-th.patch | 62 +++++++++ ...-enable-micmute-led-on-and-hp-system.patch | 43 ++++++ ...ltek-enable-mute-led-on-an-hp-system.patch | 71 ++++++++++ ...-enable-the-headset-of-asus-b9450fa-.patch | 63 +++++++++ ...ching_thread-use-btrfs_find_next_key.patch | 62 +++++++++ ...d64-add-family-17h-model-30h-pci-ids.patch | 83 ++++++++++++ ...sparc32-fix-register-window-handling.patch | 46 +++++++ ...dd-missing-kerneldoc-for-some-fields.patch | 66 ++++++++++ ...i2c-tegra-cleanup-kerneldoc-comments.patch | 77 +++++++++++ .../i2c-tegra-fix-maximum-transfer-size.patch | 122 ++++++++++++++++++ ...-support-for-mlx5_cmd_op_init2init_q.patch | 43 ++++++ ...ell-fix-the-condition-on-a-return-co.patch | 55 ++++++++ .../net-bcmgenet-remove-hfb_ctrl-access.patch | 39 ++++++ ...le-about-silly-gso-requests-coming-f.patch | 74 +++++++++++ ...et-sched-export-__netdev_watchdog_up.patch | 42 ++++++ queue-4.19/series | 15 +++ 16 files changed, 963 insertions(+) create mode 100644 queue-4.19/alsa-hda-realtek-add-headset-button-supported-for-th.patch create mode 100644 queue-4.19/alsa-hda-realtek-enable-micmute-led-on-and-hp-system.patch create mode 100644 queue-4.19/alsa-hda-realtek-enable-mute-led-on-an-hp-system.patch create mode 100644 queue-4.19/alsa-hda-realtek-enable-the-headset-of-asus-b9450fa-.patch create mode 100644 queue-4.19/btrfs-make-caching_thread-use-btrfs_find_next_key.patch create mode 100644 queue-4.19/edac-amd64-add-family-17h-model-30h-pci-ids.patch create mode 100644 queue-4.19/fix-a-braino-in-sparc32-fix-register-window-handling.patch create mode 100644 queue-4.19/i2c-tegra-add-missing-kerneldoc-for-some-fields.patch create mode 100644 queue-4.19/i2c-tegra-cleanup-kerneldoc-comments.patch create mode 100644 queue-4.19/i2c-tegra-fix-maximum-transfer-size.patch create mode 100644 queue-4.19/ib-mlx5-fix-devx-support-for-mlx5_cmd_op_init2init_q.patch create mode 100644 queue-4.19/mtd-rawnand-marvell-fix-the-condition-on-a-return-co.patch create mode 100644 queue-4.19/net-bcmgenet-remove-hfb_ctrl-access.patch create mode 100644 queue-4.19/net-be-more-gentle-about-silly-gso-requests-coming-f.patch create mode 100644 queue-4.19/net-sched-export-__netdev_watchdog_up.patch diff --git a/queue-4.19/alsa-hda-realtek-add-headset-button-supported-for-th.patch b/queue-4.19/alsa-hda-realtek-add-headset-button-supported-for-th.patch new file mode 100644 index 00000000000..4f02b2377a4 --- /dev/null +++ b/queue-4.19/alsa-hda-realtek-add-headset-button-supported-for-th.patch @@ -0,0 +1,62 @@ +From 84b154894c62602e0afe276dd7c25d58cd0f6a8c Mon Sep 17 00:00:00 2001 +From: Sasha Levin +Date: Mon, 10 Feb 2020 16:30:26 +0800 +Subject: ALSA: hda/realtek - Add Headset Button supported for ThinkPad X1 + +From: Kailang Yang + +[ Upstream commit 76f7dec08fd64e9e3ad0810a1a8a60b0a846d348 ] + +ThinkPad want to support Headset Button control. +This patch will enable it. + +Signed-off-by: Kailang Yang +Cc: +Link: https://lore.kernel.org/r/7f0b7128f40f41f6b5582ff610adc33d@realtek.com +Signed-off-by: Takashi Iwai +Signed-off-by: Sasha Levin +--- + sound/pci/hda/patch_realtek.c | 13 +++++++++---- + 1 file changed, 9 insertions(+), 4 deletions(-) + +diff --git a/sound/pci/hda/patch_realtek.c b/sound/pci/hda/patch_realtek.c +index 623ebe2e7db43..1bcbd5b5a067f 100644 +--- a/sound/pci/hda/patch_realtek.c ++++ b/sound/pci/hda/patch_realtek.c +@@ -5747,7 +5747,7 @@ enum { + ALC289_FIXUP_DUAL_SPK, + ALC294_FIXUP_SPK2_TO_DAC1, + ALC294_FIXUP_ASUS_DUAL_SPK, +- ++ ALC285_FIXUP_THINKPAD_HEADSET_JACK, + }; + + static const struct hda_fixup alc269_fixups[] = { +@@ -6836,7 +6836,12 @@ static const struct hda_fixup alc269_fixups[] = { + .chained = true, + .chain_id = ALC294_FIXUP_SPK2_TO_DAC1 + }, +- ++ [ALC285_FIXUP_THINKPAD_HEADSET_JACK] = { ++ .type = HDA_FIXUP_FUNC, ++ .v.func = alc_fixup_headset_jack, ++ .chained = true, ++ .chain_id = ALC285_FIXUP_SPEAKER2_TO_DAC1 ++ }, + }; + + static const struct snd_pci_quirk alc269_fixup_tbl[] = { +@@ -7070,8 +7075,8 @@ static const struct snd_pci_quirk alc269_fixup_tbl[] = { + SND_PCI_QUIRK(0x17aa, 0x224c, "Thinkpad", ALC298_FIXUP_TPT470_DOCK), + SND_PCI_QUIRK(0x17aa, 0x224d, "Thinkpad", ALC298_FIXUP_TPT470_DOCK), + SND_PCI_QUIRK(0x17aa, 0x225d, "Thinkpad T480", ALC269_FIXUP_LIMIT_INT_MIC_BOOST), +- SND_PCI_QUIRK(0x17aa, 0x2292, "Thinkpad X1 Yoga 7th", ALC285_FIXUP_SPEAKER2_TO_DAC1), +- SND_PCI_QUIRK(0x17aa, 0x2293, "Thinkpad X1 Carbon 7th", ALC285_FIXUP_SPEAKER2_TO_DAC1), ++ SND_PCI_QUIRK(0x17aa, 0x2292, "Thinkpad X1 Yoga 7th", ALC285_FIXUP_THINKPAD_HEADSET_JACK), ++ SND_PCI_QUIRK(0x17aa, 0x2293, "Thinkpad X1 Carbon 7th", ALC285_FIXUP_THINKPAD_HEADSET_JACK), + SND_PCI_QUIRK(0x17aa, 0x30bb, "ThinkCentre AIO", ALC233_FIXUP_LENOVO_LINE2_MIC_HOTKEY), + SND_PCI_QUIRK(0x17aa, 0x30e2, "ThinkCentre AIO", ALC233_FIXUP_LENOVO_LINE2_MIC_HOTKEY), + SND_PCI_QUIRK(0x17aa, 0x310c, "ThinkCentre Station", ALC294_FIXUP_LENOVO_MIC_LOCATION), +-- +2.25.1 + diff --git a/queue-4.19/alsa-hda-realtek-enable-micmute-led-on-and-hp-system.patch b/queue-4.19/alsa-hda-realtek-enable-micmute-led-on-and-hp-system.patch new file mode 100644 index 00000000000..90d4ffd2809 --- /dev/null +++ b/queue-4.19/alsa-hda-realtek-enable-micmute-led-on-and-hp-system.patch @@ -0,0 +1,43 @@ +From 974ccc8e03e3b89604fdbbc891cae3f0f0ad39ce Mon Sep 17 00:00:00 2001 +From: Sasha Levin +Date: Thu, 30 Apr 2020 16:32:52 +0800 +Subject: ALSA: hda/realtek - Enable micmute LED on and HP system + +From: Kai-Heng Feng + +[ Upstream commit 3e0650ab26e2010ee312311612e40e076ed1feca ] + +Though the system uses DMIC, headset mic still uses the HDA, let's use +GPIO 0x1 to control the micmute LED. + +The micmute LED GPIO has a different polarity to the mute LED GPIO, we +can use the newly added micmute_led_polarity to indicate that. + +Signed-off-by: Kai-Heng Feng +Link: https://lore.kernel.org/r/20200430083255.5093-2-kai.heng.feng@canonical.com +Signed-off-by: Takashi Iwai +Signed-off-by: Sasha Levin +--- + sound/pci/hda/patch_realtek.c | 6 +++++- + 1 file changed, 5 insertions(+), 1 deletion(-) + +diff --git a/sound/pci/hda/patch_realtek.c b/sound/pci/hda/patch_realtek.c +index 45177c4eadad3..25c9ded284712 100644 +--- a/sound/pci/hda/patch_realtek.c ++++ b/sound/pci/hda/patch_realtek.c +@@ -3921,7 +3921,11 @@ static void alc269_fixup_hp_gpio_led(struct hda_codec *codec, + static void alc285_fixup_hp_gpio_led(struct hda_codec *codec, + const struct hda_fixup *fix, int action) + { +- alc_fixup_hp_gpio_led(codec, action, 0x04, 0x00); ++ struct alc_spec *spec = codec->spec; ++ ++ spec->micmute_led_polarity = 1; ++ ++ alc_fixup_hp_gpio_led(codec, action, 0x04, 0x01); + } + + static void alc286_fixup_hp_gpio_led(struct hda_codec *codec, +-- +2.25.1 + diff --git a/queue-4.19/alsa-hda-realtek-enable-mute-led-on-an-hp-system.patch b/queue-4.19/alsa-hda-realtek-enable-mute-led-on-an-hp-system.patch new file mode 100644 index 00000000000..210861e1bb6 --- /dev/null +++ b/queue-4.19/alsa-hda-realtek-enable-mute-led-on-an-hp-system.patch @@ -0,0 +1,71 @@ +From 777a8059934a8448ca580b7441ef9511b42c11a0 Mon Sep 17 00:00:00 2001 +From: Sasha Levin +Date: Fri, 27 Mar 2020 12:46:25 +0800 +Subject: ALSA: hda/realtek: Enable mute LED on an HP system + +From: Kai-Heng Feng + +[ Upstream commit f5a88b0accc24c4a9021247d7a3124f90aa4c586 ] + +The system in question uses ALC285, and it uses GPIO 0x04 to control its +mute LED. + +The mic mute LED can be controlled by GPIO 0x01, however the system uses +DMIC so we should use that to control mic mute LED. + +Signed-off-by: Kai-Heng Feng +Cc: +Link: https://lore.kernel.org/r/20200327044626.29582-1-kai.heng.feng@canonical.com +Signed-off-by: Takashi Iwai +Signed-off-by: Sasha Levin +--- + sound/pci/hda/patch_realtek.c | 12 ++++++++++++ + 1 file changed, 12 insertions(+) + +diff --git a/sound/pci/hda/patch_realtek.c b/sound/pci/hda/patch_realtek.c +index 70f722392cf50..45177c4eadad3 100644 +--- a/sound/pci/hda/patch_realtek.c ++++ b/sound/pci/hda/patch_realtek.c +@@ -3918,6 +3918,12 @@ static void alc269_fixup_hp_gpio_led(struct hda_codec *codec, + alc_fixup_hp_gpio_led(codec, action, 0x08, 0x10); + } + ++static void alc285_fixup_hp_gpio_led(struct hda_codec *codec, ++ const struct hda_fixup *fix, int action) ++{ ++ alc_fixup_hp_gpio_led(codec, action, 0x04, 0x00); ++} ++ + static void alc286_fixup_hp_gpio_led(struct hda_codec *codec, + const struct hda_fixup *fix, int action) + { +@@ -5749,6 +5755,7 @@ enum { + ALC294_FIXUP_ASUS_DUAL_SPK, + ALC285_FIXUP_THINKPAD_HEADSET_JACK, + ALC294_FIXUP_ASUS_HPE, ++ ALC285_FIXUP_HP_GPIO_LED, + }; + + static const struct hda_fixup alc269_fixups[] = { +@@ -6854,6 +6861,10 @@ static const struct hda_fixup alc269_fixups[] = { + .chained = true, + .chain_id = ALC294_FIXUP_ASUS_HEADSET_MIC + }, ++ [ALC285_FIXUP_HP_GPIO_LED] = { ++ .type = HDA_FIXUP_FUNC, ++ .v.func = alc285_fixup_hp_gpio_led, ++ }, + }; + + static const struct snd_pci_quirk alc269_fixup_tbl[] = { +@@ -6998,6 +7009,7 @@ static const struct snd_pci_quirk alc269_fixup_tbl[] = { + SND_PCI_QUIRK(0x103c, 0x83b9, "HP Spectre x360", ALC269_FIXUP_HP_MUTE_LED_MIC3), + SND_PCI_QUIRK(0x103c, 0x8497, "HP Envy x360", ALC269_FIXUP_HP_MUTE_LED_MIC3), + SND_PCI_QUIRK(0x103c, 0x84e7, "HP Pavilion 15", ALC269_FIXUP_HP_MUTE_LED_MIC3), ++ SND_PCI_QUIRK(0x103c, 0x8736, "HP", ALC285_FIXUP_HP_GPIO_LED), + SND_PCI_QUIRK(0x1043, 0x103e, "ASUS X540SA", ALC256_FIXUP_ASUS_MIC), + SND_PCI_QUIRK(0x1043, 0x103f, "ASUS TX300", ALC282_FIXUP_ASUS_TX300), + SND_PCI_QUIRK(0x1043, 0x106d, "Asus K53BE", ALC269_FIXUP_LIMIT_INT_MIC_BOOST), +-- +2.25.1 + diff --git a/queue-4.19/alsa-hda-realtek-enable-the-headset-of-asus-b9450fa-.patch b/queue-4.19/alsa-hda-realtek-enable-the-headset-of-asus-b9450fa-.patch new file mode 100644 index 00000000000..5db956eeb80 --- /dev/null +++ b/queue-4.19/alsa-hda-realtek-enable-the-headset-of-asus-b9450fa-.patch @@ -0,0 +1,63 @@ +From 1eb05359781ae05bd53866dd30fcbb1e5cc521b2 Mon Sep 17 00:00:00 2001 +From: Sasha Levin +Date: Tue, 25 Feb 2020 15:29:21 +0800 +Subject: ALSA: hda/realtek - Enable the headset of ASUS B9450FA with ALC294 + +From: Jian-Hong Pan + +[ Upstream commit 8b33a134a9cc2a501f8fc731d91caef39237d495 ] + +A headset on the laptop like ASUS B9450FA does not work, until quirk +ALC294_FIXUP_ASUS_HPE is applied. + +Signed-off-by: Jian-Hong Pan +Signed-off-by: Kailang Yang +Cc: +Link: https://lore.kernel.org/r/20200225072920.109199-1-jian-hong@endlessm.com +Signed-off-by: Takashi Iwai +Signed-off-by: Sasha Levin +--- + sound/pci/hda/patch_realtek.c | 13 +++++++++++++ + 1 file changed, 13 insertions(+) + +diff --git a/sound/pci/hda/patch_realtek.c b/sound/pci/hda/patch_realtek.c +index 1bcbd5b5a067f..70f722392cf50 100644 +--- a/sound/pci/hda/patch_realtek.c ++++ b/sound/pci/hda/patch_realtek.c +@@ -5748,6 +5748,7 @@ enum { + ALC294_FIXUP_SPK2_TO_DAC1, + ALC294_FIXUP_ASUS_DUAL_SPK, + ALC285_FIXUP_THINKPAD_HEADSET_JACK, ++ ALC294_FIXUP_ASUS_HPE, + }; + + static const struct hda_fixup alc269_fixups[] = { +@@ -6842,6 +6843,17 @@ static const struct hda_fixup alc269_fixups[] = { + .chained = true, + .chain_id = ALC285_FIXUP_SPEAKER2_TO_DAC1 + }, ++ [ALC294_FIXUP_ASUS_HPE] = { ++ .type = HDA_FIXUP_VERBS, ++ .v.verbs = (const struct hda_verb[]) { ++ /* Set EAPD high */ ++ { 0x20, AC_VERB_SET_COEF_INDEX, 0x0f }, ++ { 0x20, AC_VERB_SET_PROC_COEF, 0x7774 }, ++ { } ++ }, ++ .chained = true, ++ .chain_id = ALC294_FIXUP_ASUS_HEADSET_MIC ++ }, + }; + + static const struct snd_pci_quirk alc269_fixup_tbl[] = { +@@ -7004,6 +7016,7 @@ static const struct snd_pci_quirk alc269_fixup_tbl[] = { + SND_PCI_QUIRK(0x1043, 0x16e3, "ASUS UX50", ALC269_FIXUP_STEREO_DMIC), + SND_PCI_QUIRK(0x1043, 0x17d1, "ASUS UX431FL", ALC294_FIXUP_ASUS_DUAL_SPK), + SND_PCI_QUIRK(0x1043, 0x18b1, "Asus MJ401TA", ALC256_FIXUP_ASUS_HEADSET_MIC), ++ SND_PCI_QUIRK(0x1043, 0x19ce, "ASUS B9450FA", ALC294_FIXUP_ASUS_HPE), + SND_PCI_QUIRK(0x1043, 0x1a13, "Asus G73Jw", ALC269_FIXUP_ASUS_G73JW), + SND_PCI_QUIRK(0x1043, 0x1a30, "ASUS X705UD", ALC256_FIXUP_ASUS_MIC), + SND_PCI_QUIRK(0x1043, 0x1b13, "Asus U41SV", ALC269_FIXUP_INV_DMIC), +-- +2.25.1 + diff --git a/queue-4.19/btrfs-make-caching_thread-use-btrfs_find_next_key.patch b/queue-4.19/btrfs-make-caching_thread-use-btrfs_find_next_key.patch new file mode 100644 index 00000000000..89401cd0fa5 --- /dev/null +++ b/queue-4.19/btrfs-make-caching_thread-use-btrfs_find_next_key.patch @@ -0,0 +1,62 @@ +From a002fcae9fff7c24e61e106ccd983e2494eac478 Mon Sep 17 00:00:00 2001 +From: Sasha Levin +Date: Thu, 20 Jun 2019 15:37:52 -0400 +Subject: btrfs: make caching_thread use btrfs_find_next_key + +From: Josef Bacik + +[ Upstream commit 6a9fb468f1152d6254f49fee6ac28c3cfa3367e5 ] + +extent-tree.c has a find_next_key that just walks up the path to find +the next key, but it is used for both the caching stuff and the snapshot +delete stuff. The snapshot deletion stuff is special so it can't really +use btrfs_find_next_key, but the caching thread stuff can. We just need +to fix btrfs_find_next_key to deal with ->skip_locking and then it works +exactly the same as the private find_next_key helper. + +Signed-off-by: Josef Bacik +Signed-off-by: David Sterba +Signed-off-by: Sasha Levin +--- + fs/btrfs/ctree.c | 4 ++-- + fs/btrfs/extent-tree.c | 2 +- + 2 files changed, 3 insertions(+), 3 deletions(-) + +diff --git a/fs/btrfs/ctree.c b/fs/btrfs/ctree.c +index c9943d70e2cb2..d03944735ee42 100644 +--- a/fs/btrfs/ctree.c ++++ b/fs/btrfs/ctree.c +@@ -5665,7 +5665,7 @@ int btrfs_find_next_key(struct btrfs_root *root, struct btrfs_path *path, + int slot; + struct extent_buffer *c; + +- WARN_ON(!path->keep_locks); ++ WARN_ON(!path->keep_locks && !path->skip_locking); + while (level < BTRFS_MAX_LEVEL) { + if (!path->nodes[level]) + return 1; +@@ -5681,7 +5681,7 @@ int btrfs_find_next_key(struct btrfs_root *root, struct btrfs_path *path, + !path->nodes[level + 1]) + return 1; + +- if (path->locks[level + 1]) { ++ if (path->locks[level + 1] || path->skip_locking) { + level++; + continue; + } +diff --git a/fs/btrfs/extent-tree.c b/fs/btrfs/extent-tree.c +index 271e70c45d5bd..954e558c4380f 100644 +--- a/fs/btrfs/extent-tree.c ++++ b/fs/btrfs/extent-tree.c +@@ -436,7 +436,7 @@ static int load_extent_tree_free(struct btrfs_caching_control *caching_ctl) + if (path->slots[0] < nritems) { + btrfs_item_key_to_cpu(leaf, &key, path->slots[0]); + } else { +- ret = find_next_key(path, 0, &key); ++ ret = btrfs_find_next_key(extent_root, path, &key, 0, 0); + if (ret) + break; + +-- +2.25.1 + diff --git a/queue-4.19/edac-amd64-add-family-17h-model-30h-pci-ids.patch b/queue-4.19/edac-amd64-add-family-17h-model-30h-pci-ids.patch new file mode 100644 index 00000000000..4edde460a97 --- /dev/null +++ b/queue-4.19/edac-amd64-add-family-17h-model-30h-pci-ids.patch @@ -0,0 +1,83 @@ +From 24a57d73e43bcc41c8a0d786e40cd91ab5f56aa1 Mon Sep 17 00:00:00 2001 +From: Sasha Levin +Date: Thu, 28 Feb 2019 15:36:09 +0000 +Subject: EDAC/amd64: Add Family 17h Model 30h PCI IDs + +From: Yazen Ghannam + +[ Upstream commit 6e846239e5487cbb89ac8192d5f11437d010130e ] + +Add the new Family 17h Model 30h PCI IDs to the AMD64 EDAC module. + +This also fixes a probe failure that appeared when some other PCI IDs +for Family 17h Model 30h were added to the AMD NB code. + +Fixes: be3518a16ef2 (x86/amd_nb: Add PCI device IDs for family 17h, model 30h) +Signed-off-by: Yazen Ghannam +Signed-off-by: Borislav Petkov +Tested-by: Kim Phillips +Cc: James Morse +Cc: Mauro Carvalho Chehab +Cc: linux-edac +Link: https://lkml.kernel.org/r/20190228153558.127292-1-Yazen.Ghannam@amd.com +Signed-off-by: Sasha Levin +--- + drivers/edac/amd64_edac.c | 13 +++++++++++++ + drivers/edac/amd64_edac.h | 3 +++ + 2 files changed, 16 insertions(+) + +diff --git a/drivers/edac/amd64_edac.c b/drivers/edac/amd64_edac.c +index 05d6f9c86ac38..268ada29cd987 100644 +--- a/drivers/edac/amd64_edac.c ++++ b/drivers/edac/amd64_edac.c +@@ -2209,6 +2209,15 @@ static struct amd64_family_type family_types[] = { + .dbam_to_cs = f17_base_addr_to_cs_size, + } + }, ++ [F17_M30H_CPUS] = { ++ .ctl_name = "F17h_M30h", ++ .f0_id = PCI_DEVICE_ID_AMD_17H_M30H_DF_F0, ++ .f6_id = PCI_DEVICE_ID_AMD_17H_M30H_DF_F6, ++ .ops = { ++ .early_channel_count = f17_early_channel_count, ++ .dbam_to_cs = f17_base_addr_to_cs_size, ++ } ++ }, + }; + + /* +@@ -3212,6 +3221,10 @@ static struct amd64_family_type *per_family_init(struct amd64_pvt *pvt) + fam_type = &family_types[F17_M10H_CPUS]; + pvt->ops = &family_types[F17_M10H_CPUS].ops; + break; ++ } else if (pvt->model >= 0x30 && pvt->model <= 0x3f) { ++ fam_type = &family_types[F17_M30H_CPUS]; ++ pvt->ops = &family_types[F17_M30H_CPUS].ops; ++ break; + } + fam_type = &family_types[F17_CPUS]; + pvt->ops = &family_types[F17_CPUS].ops; +diff --git a/drivers/edac/amd64_edac.h b/drivers/edac/amd64_edac.h +index 4242f8e39c18f..de8dbb0b42b55 100644 +--- a/drivers/edac/amd64_edac.h ++++ b/drivers/edac/amd64_edac.h +@@ -117,6 +117,8 @@ + #define PCI_DEVICE_ID_AMD_17H_DF_F6 0x1466 + #define PCI_DEVICE_ID_AMD_17H_M10H_DF_F0 0x15e8 + #define PCI_DEVICE_ID_AMD_17H_M10H_DF_F6 0x15ee ++#define PCI_DEVICE_ID_AMD_17H_M30H_DF_F0 0x1490 ++#define PCI_DEVICE_ID_AMD_17H_M30H_DF_F6 0x1496 + + /* + * Function 1 - Address Map +@@ -284,6 +286,7 @@ enum amd_families { + F16_M30H_CPUS, + F17_CPUS, + F17_M10H_CPUS, ++ F17_M30H_CPUS, + NUM_FAMILIES, + }; + +-- +2.25.1 + diff --git a/queue-4.19/fix-a-braino-in-sparc32-fix-register-window-handling.patch b/queue-4.19/fix-a-braino-in-sparc32-fix-register-window-handling.patch new file mode 100644 index 00000000000..1897ba10c25 --- /dev/null +++ b/queue-4.19/fix-a-braino-in-sparc32-fix-register-window-handling.patch @@ -0,0 +1,46 @@ +From 5fd64dc2a34e3f584ec55ea3c1574774fe6b9d8f Mon Sep 17 00:00:00 2001 +From: Sasha Levin +Date: Sat, 6 Jun 2020 23:44:24 -0400 +Subject: fix a braino in "sparc32: fix register window handling in + genregs32_[gs]et()" + +From: Al Viro + +[ Upstream commit 9d964e1b82d8182184153b70174f445ea616f053 ] + +lost npc in PTRACE_SETREGSET, breaking PTRACE_SETREGS as well + +Fixes: cf51e129b968 "sparc32: fix register window handling in genregs32_[gs]et()" +Signed-off-by: Al Viro +Signed-off-by: Sasha Levin +--- + arch/sparc/kernel/ptrace_32.c | 9 +++++++-- + 1 file changed, 7 insertions(+), 2 deletions(-) + +diff --git a/arch/sparc/kernel/ptrace_32.c b/arch/sparc/kernel/ptrace_32.c +index 60f7205ebe40d..646dd58169ecb 100644 +--- a/arch/sparc/kernel/ptrace_32.c ++++ b/arch/sparc/kernel/ptrace_32.c +@@ -168,12 +168,17 @@ static int genregs32_set(struct task_struct *target, + if (ret || !count) + return ret; + ret = user_regset_copyin(&pos, &count, &kbuf, &ubuf, +- ®s->y, ++ ®s->npc, + 34 * sizeof(u32), 35 * sizeof(u32)); + if (ret || !count) + return ret; ++ ret = user_regset_copyin(&pos, &count, &kbuf, &ubuf, ++ ®s->y, ++ 35 * sizeof(u32), 36 * sizeof(u32)); ++ if (ret || !count) ++ return ret; + return user_regset_copyin_ignore(&pos, &count, &kbuf, &ubuf, +- 35 * sizeof(u32), 38 * sizeof(u32)); ++ 36 * sizeof(u32), 38 * sizeof(u32)); + } + + static int fpregs32_get(struct task_struct *target, +-- +2.25.1 + diff --git a/queue-4.19/i2c-tegra-add-missing-kerneldoc-for-some-fields.patch b/queue-4.19/i2c-tegra-add-missing-kerneldoc-for-some-fields.patch new file mode 100644 index 00000000000..aea69dc8e83 --- /dev/null +++ b/queue-4.19/i2c-tegra-add-missing-kerneldoc-for-some-fields.patch @@ -0,0 +1,66 @@ +From 7aa0ce3f685736ab78510c4f35a6076494fd6287 Mon Sep 17 00:00:00 2001 +From: Sasha Levin +Date: Mon, 17 Dec 2018 15:16:53 +0100 +Subject: i2c: tegra: Add missing kerneldoc for some fields + +From: Thierry Reding + +[ Upstream commit 0604ee4aefa20f493a32dc223599f922fb615367 ] + +Not all fields were properly documented. Add kerneldoc for the missing +fields to prevent the build from flagging them. + +Reported-by: Wolfram Sang +Signed-off-by: Thierry Reding +Signed-off-by: Wolfram Sang +Signed-off-by: Sasha Levin +--- + drivers/i2c/busses/i2c-tegra.c | 15 +++++++++++++++ + 1 file changed, 15 insertions(+) + +diff --git a/drivers/i2c/busses/i2c-tegra.c b/drivers/i2c/busses/i2c-tegra.c +index 9a6b9a1b88aef..917f416787b10 100644 +--- a/drivers/i2c/busses/i2c-tegra.c ++++ b/drivers/i2c/busses/i2c-tegra.c +@@ -154,6 +154,16 @@ enum msg_end_type { + * @clk_divisor_std_fast_mode: Clock divisor in standard/fast mode. It is + * applicable if there is no fast clock source i.e. single clock + * source. ++ * @clk_divisor_fast_plus_mode: Clock divisor in fast mode plus. It is ++ * applicable if there is no fast clock source (i.e. single ++ * clock source). ++ * @has_multi_master_mode: The I2C controller supports running in single-master ++ * or multi-master mode. ++ * @has_slcg_override_reg: The I2C controller supports a register that ++ * overrides the second level clock gating. ++ * @has_mst_fifo: The I2C controller contains the new MST FIFO interface that ++ * provides additional features and allows for longer messages to ++ * be transferred in one go. + */ + struct tegra_i2c_hw_feature { + bool has_continue_xfer_support; +@@ -175,9 +185,11 @@ struct tegra_i2c_hw_feature { + * @adapter: core I2C layer adapter information + * @div_clk: clock reference for div clock of I2C controller + * @fast_clk: clock reference for fast clock of I2C controller ++ * @rst: reset control for the I2C controller + * @base: ioremapped registers cookie + * @cont_id: I2C controller ID, used for packet header + * @irq: IRQ number of transfer complete interrupt ++ * @irq_disabled: used to track whether or not the interrupt is enabled + * @is_dvc: identifies the DVC I2C controller, has a different register layout + * @msg_complete: transfer completion notifier + * @msg_err: error code for completed message +@@ -185,6 +197,9 @@ struct tegra_i2c_hw_feature { + * @msg_buf_remaining: size of unsent data in the message buffer + * @msg_read: identifies read transfers + * @bus_clk_rate: current I2C bus clock rate ++ * @clk_divisor_non_hs_mode: clock divider for non-high-speed modes ++ * @is_multimaster_mode: track if I2C controller is in multi-master mode ++ * @xfer_lock: lock to serialize transfer submission and processing + */ + struct tegra_i2c_dev { + struct device *dev; +-- +2.25.1 + diff --git a/queue-4.19/i2c-tegra-cleanup-kerneldoc-comments.patch b/queue-4.19/i2c-tegra-cleanup-kerneldoc-comments.patch new file mode 100644 index 00000000000..f841bd846dc --- /dev/null +++ b/queue-4.19/i2c-tegra-cleanup-kerneldoc-comments.patch @@ -0,0 +1,77 @@ +From 1b96451ca36fcfb6808ed787f0399111f247977d Mon Sep 17 00:00:00 2001 +From: Sasha Levin +Date: Mon, 17 Dec 2018 15:16:52 +0100 +Subject: i2c: tegra: Cleanup kerneldoc comments + +From: Thierry Reding + +[ Upstream commit c990bbafdb11c608bba2d529f72ded9bdff88678 ] + +Some of the kerneldoc uses a strange spelling for abbreviations. Turn +them into all-uppercase and clean up some whitespace issues while at it. + +Signed-off-by: Thierry Reding +Signed-off-by: Wolfram Sang +Signed-off-by: Sasha Levin +--- + drivers/i2c/busses/i2c-tegra.c | 23 +++++++++++------------ + 1 file changed, 11 insertions(+), 12 deletions(-) + +diff --git a/drivers/i2c/busses/i2c-tegra.c b/drivers/i2c/busses/i2c-tegra.c +index 47d196c026ba6..9a6b9a1b88aef 100644 +--- a/drivers/i2c/busses/i2c-tegra.c ++++ b/drivers/i2c/busses/i2c-tegra.c +@@ -145,8 +145,8 @@ enum msg_end_type { + * @has_continue_xfer_support: Continue transfer supports. + * @has_per_pkt_xfer_complete_irq: Has enable/disable capability for transfer + * complete interrupt per packet basis. +- * @has_single_clk_source: The i2c controller has single clock source. Tegra30 +- * and earlier Socs has two clock sources i.e. div-clk and ++ * @has_single_clk_source: The I2C controller has single clock source. Tegra30 ++ * and earlier SoCs have two clock sources i.e. div-clk and + * fast-clk. + * @has_config_load_reg: Has the config load register to load the new + * configuration. +@@ -155,7 +155,6 @@ enum msg_end_type { + * applicable if there is no fast clock source i.e. single clock + * source. + */ +- + struct tegra_i2c_hw_feature { + bool has_continue_xfer_support; + bool has_per_pkt_xfer_complete_irq; +@@ -170,22 +169,22 @@ struct tegra_i2c_hw_feature { + }; + + /** +- * struct tegra_i2c_dev - per device i2c context ++ * struct tegra_i2c_dev - per device I2C context + * @dev: device reference for power management +- * @hw: Tegra i2c hw feature. +- * @adapter: core i2c layer adapter information +- * @div_clk: clock reference for div clock of i2c controller. +- * @fast_clk: clock reference for fast clock of i2c controller. ++ * @hw: Tegra I2C HW feature ++ * @adapter: core I2C layer adapter information ++ * @div_clk: clock reference for div clock of I2C controller ++ * @fast_clk: clock reference for fast clock of I2C controller + * @base: ioremapped registers cookie +- * @cont_id: i2c controller id, used for for packet header +- * @irq: irq number of transfer complete interrupt +- * @is_dvc: identifies the DVC i2c controller, has a different register layout ++ * @cont_id: I2C controller ID, used for packet header ++ * @irq: IRQ number of transfer complete interrupt ++ * @is_dvc: identifies the DVC I2C controller, has a different register layout + * @msg_complete: transfer completion notifier + * @msg_err: error code for completed message + * @msg_buf: pointer to current message data + * @msg_buf_remaining: size of unsent data in the message buffer + * @msg_read: identifies read transfers +- * @bus_clk_rate: current i2c bus clock rate ++ * @bus_clk_rate: current I2C bus clock rate + */ + struct tegra_i2c_dev { + struct device *dev; +-- +2.25.1 + diff --git a/queue-4.19/i2c-tegra-fix-maximum-transfer-size.patch b/queue-4.19/i2c-tegra-fix-maximum-transfer-size.patch new file mode 100644 index 00000000000..e638bc7833c --- /dev/null +++ b/queue-4.19/i2c-tegra-fix-maximum-transfer-size.patch @@ -0,0 +1,122 @@ +From 530446810b6ce5ef26e9aa0efd33b00a0ed9b15d Mon Sep 17 00:00:00 2001 +From: Sasha Levin +Date: Tue, 8 Jan 2019 13:59:10 -0800 +Subject: i2c: tegra: Fix Maximum transfer size + +From: Sowjanya Komatineni + +[ Upstream commit b67d4530cdade7ebfafa2c6b46f2a0dad3e41bcb ] + +Tegra194 supports maximum 64K Bytes transfer per packet. +Tegra186 and prior supports maximum 4K Bytes transfer per packet. + +This patch fixes this payload difference between Tegra194 and prior +Tegra chipsets using separate i2c_adapter_quirks. + +Signed-off-by: Sowjanya Komatineni +Acked-by: Thierry Reding +Signed-off-by: Wolfram Sang +Signed-off-by: Sasha Levin +--- + drivers/i2c/busses/i2c-tegra.c | 15 ++++++++++++++- + 1 file changed, 14 insertions(+), 1 deletion(-) + +diff --git a/drivers/i2c/busses/i2c-tegra.c b/drivers/i2c/busses/i2c-tegra.c +index 917f416787b10..af06198851f1b 100644 +--- a/drivers/i2c/busses/i2c-tegra.c ++++ b/drivers/i2c/busses/i2c-tegra.c +@@ -164,6 +164,8 @@ enum msg_end_type { + * @has_mst_fifo: The I2C controller contains the new MST FIFO interface that + * provides additional features and allows for longer messages to + * be transferred in one go. ++ * @quirks: i2c adapter quirks for limiting write/read transfer size and not ++ * allowing 0 length transfers. + */ + struct tegra_i2c_hw_feature { + bool has_continue_xfer_support; +@@ -176,6 +178,7 @@ struct tegra_i2c_hw_feature { + bool has_multi_master_mode; + bool has_slcg_override_reg; + bool has_mst_fifo; ++ const struct i2c_adapter_quirks *quirks; + }; + + /** +@@ -847,6 +850,10 @@ static const struct i2c_adapter_quirks tegra_i2c_quirks = { + .max_write_len = 4096 - 12, + }; + ++static const struct i2c_adapter_quirks tegra194_i2c_quirks = { ++ .flags = I2C_AQ_NO_ZERO_LEN, ++}; ++ + static const struct tegra_i2c_hw_feature tegra20_i2c_hw = { + .has_continue_xfer_support = false, + .has_per_pkt_xfer_complete_irq = false, +@@ -858,6 +865,7 @@ static const struct tegra_i2c_hw_feature tegra20_i2c_hw = { + .has_multi_master_mode = false, + .has_slcg_override_reg = false, + .has_mst_fifo = false, ++ .quirks = &tegra_i2c_quirks, + }; + + static const struct tegra_i2c_hw_feature tegra30_i2c_hw = { +@@ -871,6 +879,7 @@ static const struct tegra_i2c_hw_feature tegra30_i2c_hw = { + .has_multi_master_mode = false, + .has_slcg_override_reg = false, + .has_mst_fifo = false, ++ .quirks = &tegra_i2c_quirks, + }; + + static const struct tegra_i2c_hw_feature tegra114_i2c_hw = { +@@ -884,6 +893,7 @@ static const struct tegra_i2c_hw_feature tegra114_i2c_hw = { + .has_multi_master_mode = false, + .has_slcg_override_reg = false, + .has_mst_fifo = false, ++ .quirks = &tegra_i2c_quirks, + }; + + static const struct tegra_i2c_hw_feature tegra124_i2c_hw = { +@@ -897,6 +907,7 @@ static const struct tegra_i2c_hw_feature tegra124_i2c_hw = { + .has_multi_master_mode = false, + .has_slcg_override_reg = true, + .has_mst_fifo = false, ++ .quirks = &tegra_i2c_quirks, + }; + + static const struct tegra_i2c_hw_feature tegra210_i2c_hw = { +@@ -910,6 +921,7 @@ static const struct tegra_i2c_hw_feature tegra210_i2c_hw = { + .has_multi_master_mode = true, + .has_slcg_override_reg = true, + .has_mst_fifo = false, ++ .quirks = &tegra_i2c_quirks, + }; + + static const struct tegra_i2c_hw_feature tegra194_i2c_hw = { +@@ -923,6 +935,7 @@ static const struct tegra_i2c_hw_feature tegra194_i2c_hw = { + .has_multi_master_mode = true, + .has_slcg_override_reg = true, + .has_mst_fifo = true, ++ .quirks = &tegra194_i2c_quirks, + }; + + /* Match table for of_platform binding */ +@@ -974,7 +987,6 @@ static int tegra_i2c_probe(struct platform_device *pdev) + i2c_dev->base = base; + i2c_dev->div_clk = div_clk; + i2c_dev->adapter.algo = &tegra_i2c_algo; +- i2c_dev->adapter.quirks = &tegra_i2c_quirks; + i2c_dev->irq = irq; + i2c_dev->cont_id = pdev->id; + i2c_dev->dev = &pdev->dev; +@@ -990,6 +1002,7 @@ static int tegra_i2c_probe(struct platform_device *pdev) + i2c_dev->hw = of_device_get_match_data(&pdev->dev); + i2c_dev->is_dvc = of_device_is_compatible(pdev->dev.of_node, + "nvidia,tegra20-i2c-dvc"); ++ i2c_dev->adapter.quirks = i2c_dev->hw->quirks; + init_completion(&i2c_dev->msg_complete); + spin_lock_init(&i2c_dev->xfer_lock); + +-- +2.25.1 + diff --git a/queue-4.19/ib-mlx5-fix-devx-support-for-mlx5_cmd_op_init2init_q.patch b/queue-4.19/ib-mlx5-fix-devx-support-for-mlx5_cmd_op_init2init_q.patch new file mode 100644 index 00000000000..cd589ee4b81 --- /dev/null +++ b/queue-4.19/ib-mlx5-fix-devx-support-for-mlx5_cmd_op_init2init_q.patch @@ -0,0 +1,43 @@ +From 4a44f30b02b158dc9c7e91c00e5cadf78672031c Mon Sep 17 00:00:00 2001 +From: Sasha Levin +Date: Wed, 27 May 2020 16:57:03 +0300 +Subject: IB/mlx5: Fix DEVX support for MLX5_CMD_OP_INIT2INIT_QP command + +From: Mark Zhang + +[ Upstream commit d246a3061528be6d852156d25c02ea69d6db7e65 ] + +The commit citied in the Fixes line wasn't complete and solved +only part of the problems. Update the mlx5_ib to properly support +MLX5_CMD_OP_INIT2INIT_QP command in the DEVX, that is required when +modify the QP tx_port_affinity. + +Fixes: 819f7427bafd ("RDMA/mlx5: Add init2init as a modify command") +Link: https://lore.kernel.org/r/20200527135703.482501-1-leon@kernel.org +Signed-off-by: Mark Zhang +Reviewed-by: Maor Gottlieb +Signed-off-by: Leon Romanovsky +Signed-off-by: Jason Gunthorpe +Signed-off-by: Sasha Levin +--- + drivers/infiniband/hw/mlx5/devx.c | 4 ++++ + 1 file changed, 4 insertions(+) + +diff --git a/drivers/infiniband/hw/mlx5/devx.c b/drivers/infiniband/hw/mlx5/devx.c +index 4c90a007e09db..bd8da83149dc5 100644 +--- a/drivers/infiniband/hw/mlx5/devx.c ++++ b/drivers/infiniband/hw/mlx5/devx.c +@@ -211,6 +211,10 @@ static int devx_is_valid_obj_id(struct devx_obj *obj, const void *in) + case MLX5_CMD_OP_RST2INIT_QP: + obj_id = MLX5_GET(rst2init_qp_in, in, qpn); + break; ++ case MLX5_CMD_OP_INIT2INIT_QP: ++ obj_id = get_enc_obj_id(MLX5_CMD_OP_CREATE_QP, ++ MLX5_GET(init2init_qp_in, in, qpn)); ++ break; + case MLX5_CMD_OP_INIT2RTR_QP: + obj_id = MLX5_GET(init2rtr_qp_in, in, qpn); + break; +-- +2.25.1 + diff --git a/queue-4.19/mtd-rawnand-marvell-fix-the-condition-on-a-return-co.patch b/queue-4.19/mtd-rawnand-marvell-fix-the-condition-on-a-return-co.patch new file mode 100644 index 00000000000..d8fcc48223c --- /dev/null +++ b/queue-4.19/mtd-rawnand-marvell-fix-the-condition-on-a-return-co.patch @@ -0,0 +1,55 @@ +From 91dad627554d5ea93ee371cf675b018380e97776 Mon Sep 17 00:00:00 2001 +From: Sasha Levin +Date: Fri, 24 Apr 2020 18:44:56 +0200 +Subject: mtd: rawnand: marvell: Fix the condition on a return code + +From: Miquel Raynal + +[ Upstream commit c27075772d1f1c8aaf276db9943b35adda8a8b65 ] + +In a previous fix, I changed the condition on which the timeout of an +IRQ is reached from: + + if (!ret) + +into: + + if (ret && !pending) + +While having a non-zero return code is usual in the Linux kernel, here +ret comes from a wait_for_completion_timeout() which returns 0 when +the waiting period is too long. + +Hence, the revised condition should be: + + if (!ret && !pending) + +The faulty patch did not produce any error because of the !pending +condition so this change is finally purely cosmetic and does not +change the actual driver behavior. + +Fixes: cafb56dd741e ("mtd: rawnand: marvell: prevent timeouts on a loaded machine") +Signed-off-by: Miquel Raynal +Reviewed-by: Boris Brezillon +Link: https://lore.kernel.org/linux-mtd/20200424164501.26719-2-miquel.raynal@bootlin.com +Signed-off-by: Sasha Levin +--- + drivers/mtd/nand/raw/marvell_nand.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/drivers/mtd/nand/raw/marvell_nand.c b/drivers/mtd/nand/raw/marvell_nand.c +index 3e542224dd115..a917bc242c9cc 100644 +--- a/drivers/mtd/nand/raw/marvell_nand.c ++++ b/drivers/mtd/nand/raw/marvell_nand.c +@@ -637,7 +637,7 @@ static int marvell_nfc_wait_op(struct nand_chip *chip, unsigned int timeout_ms) + * In case the interrupt was not served in the required time frame, + * check if the ISR was not served or if something went actually wrong. + */ +- if (ret && !pending) { ++ if (!ret && !pending) { + dev_err(nfc->dev, "Timeout waiting for RB signal\n"); + return -ETIMEDOUT; + } +-- +2.25.1 + diff --git a/queue-4.19/net-bcmgenet-remove-hfb_ctrl-access.patch b/queue-4.19/net-bcmgenet-remove-hfb_ctrl-access.patch new file mode 100644 index 00000000000..c7cd9cc87a1 --- /dev/null +++ b/queue-4.19/net-bcmgenet-remove-hfb_ctrl-access.patch @@ -0,0 +1,39 @@ +From 2d61169906762fb24d222190c87a56b99b55f0c1 Mon Sep 17 00:00:00 2001 +From: Sasha Levin +Date: Tue, 20 Nov 2018 15:17:01 -0800 +Subject: net: bcmgenet: remove HFB_CTRL access + +From: Doug Berger + +[ Upstream commit 24d476db6dfb0f85130e348ca1bbd14afb73a8be ] + +Commit c5a54bbcecec ("net: bcmgenet: abort suspend on error") +mistakenly introduced register accesses that should not occur +in bcmgenet_wol_power_up_cfg(). + +Fixes: c5a54bbcecec ("net: bcmgenet: abort suspend on error") +Signed-off-by: Doug Berger +Signed-off-by: David S. Miller +Signed-off-by: Sasha Levin +--- + drivers/net/ethernet/broadcom/genet/bcmgenet_wol.c | 4 ---- + 1 file changed, 4 deletions(-) + +diff --git a/drivers/net/ethernet/broadcom/genet/bcmgenet_wol.c b/drivers/net/ethernet/broadcom/genet/bcmgenet_wol.c +index b3596e0ee47ba..57582efa362df 100644 +--- a/drivers/net/ethernet/broadcom/genet/bcmgenet_wol.c ++++ b/drivers/net/ethernet/broadcom/genet/bcmgenet_wol.c +@@ -191,10 +191,6 @@ void bcmgenet_wol_power_up_cfg(struct bcmgenet_priv *priv, + reg &= ~MPD_EN; + bcmgenet_umac_writel(priv, reg, UMAC_MPD_CTRL); + +- reg = bcmgenet_hfb_reg_readl(priv, HFB_CTRL); +- reg &= ~(RBUF_HFB_EN | RBUF_ACPI_EN); +- bcmgenet_hfb_reg_writel(priv, reg, HFB_CTRL); +- + /* Disable CRC Forward */ + reg = bcmgenet_umac_readl(priv, UMAC_CMD); + reg &= ~CMD_CRC_FWD; +-- +2.25.1 + diff --git a/queue-4.19/net-be-more-gentle-about-silly-gso-requests-coming-f.patch b/queue-4.19/net-be-more-gentle-about-silly-gso-requests-coming-f.patch new file mode 100644 index 00000000000..8ce01125536 --- /dev/null +++ b/queue-4.19/net-be-more-gentle-about-silly-gso-requests-coming-f.patch @@ -0,0 +1,74 @@ +From 6de89f46d574a79357859fa1f4f9005bda8c7edf Mon Sep 17 00:00:00 2001 +From: Sasha Levin +Date: Thu, 28 May 2020 14:57:47 -0700 +Subject: net: be more gentle about silly gso requests coming from user + +From: Eric Dumazet + +[ Upstream commit 7c6d2ecbda83150b2036a2b36b21381ad4667762 ] + +Recent change in virtio_net_hdr_to_skb() broke some packetdrill tests. + +When --mss=XXX option is set, packetdrill always provide gso_type & gso_size +for its inbound packets, regardless of packet size. + + if (packet->tcp && packet->mss) { + if (packet->ipv4) + gso.gso_type = VIRTIO_NET_HDR_GSO_TCPV4; + else + gso.gso_type = VIRTIO_NET_HDR_GSO_TCPV6; + gso.gso_size = packet->mss; + } + +Since many other programs could do the same, relax virtio_net_hdr_to_skb() +to no longer return an error, but instead ignore gso settings. + +This keeps Willem intent to make sure no malicious packet could +reach gso stack. + +Note that TCP stack has a special logic in tcp_set_skb_tso_segs() +to clear gso_size for small packets. + +Fixes: 6dd912f82680 ("net: check untrusted gso_size at kernel entry") +Signed-off-by: Eric Dumazet +Cc: Willem de Bruijn +Acked-by: Willem de Bruijn +Signed-off-by: David S. Miller +Signed-off-by: Sasha Levin +--- + include/linux/virtio_net.h | 17 +++++++++-------- + 1 file changed, 9 insertions(+), 8 deletions(-) + +diff --git a/include/linux/virtio_net.h b/include/linux/virtio_net.h +index 1c296f370e461..f32fe7080d2ec 100644 +--- a/include/linux/virtio_net.h ++++ b/include/linux/virtio_net.h +@@ -109,16 +109,17 @@ static inline int virtio_net_hdr_to_skb(struct sk_buff *skb, + + if (hdr->gso_type != VIRTIO_NET_HDR_GSO_NONE) { + u16 gso_size = __virtio16_to_cpu(little_endian, hdr->gso_size); ++ struct skb_shared_info *shinfo = skb_shinfo(skb); + +- if (skb->len - p_off <= gso_size) +- return -EINVAL; +- +- skb_shinfo(skb)->gso_size = gso_size; +- skb_shinfo(skb)->gso_type = gso_type; ++ /* Too small packets are not really GSO ones. */ ++ if (skb->len - p_off > gso_size) { ++ shinfo->gso_size = gso_size; ++ shinfo->gso_type = gso_type; + +- /* Header must be checked, and gso_segs computed. */ +- skb_shinfo(skb)->gso_type |= SKB_GSO_DODGY; +- skb_shinfo(skb)->gso_segs = 0; ++ /* Header must be checked, and gso_segs computed. */ ++ shinfo->gso_type |= SKB_GSO_DODGY; ++ shinfo->gso_segs = 0; ++ } + } + + return 0; +-- +2.25.1 + diff --git a/queue-4.19/net-sched-export-__netdev_watchdog_up.patch b/queue-4.19/net-sched-export-__netdev_watchdog_up.patch new file mode 100644 index 00000000000..66be3b96256 --- /dev/null +++ b/queue-4.19/net-sched-export-__netdev_watchdog_up.patch @@ -0,0 +1,42 @@ +From 720cbe2c77f4a4840addde6fbf898a9ac22ff1cf Mon Sep 17 00:00:00 2001 +From: Sasha Levin +Date: Tue, 9 Jun 2020 22:11:54 +0200 +Subject: net: sched: export __netdev_watchdog_up() + +From: Valentin Longchamp + +[ Upstream commit 1a3db27ad9a72d033235b9673653962c02e3486e ] + +Since the quiesce/activate rework, __netdev_watchdog_up() is directly +called in the ucc_geth driver. + +Unfortunately, this function is not available for modules and thus +ucc_geth cannot be built as a module anymore. Fix it by exporting +__netdev_watchdog_up(). + +Since the commit introducing the regression was backported to stable +branches, this one should ideally be as well. + +Fixes: 79dde73cf9bc ("net/ethernet/freescale: rework quiesce/activate for ucc_geth") +Signed-off-by: Valentin Longchamp +Signed-off-by: David S. Miller +Signed-off-by: Sasha Levin +--- + net/sched/sch_generic.c | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/net/sched/sch_generic.c b/net/sched/sch_generic.c +index 8a4d01e427a22..119e20cad662b 100644 +--- a/net/sched/sch_generic.c ++++ b/net/sched/sch_generic.c +@@ -487,6 +487,7 @@ void __netdev_watchdog_up(struct net_device *dev) + dev_hold(dev); + } + } ++EXPORT_SYMBOL_GPL(__netdev_watchdog_up); + + static void dev_watchdog_up(struct net_device *dev) + { +-- +2.25.1 + diff --git a/queue-4.19/series b/queue-4.19/series index dfcd55736fe..db3738e8a5f 100644 --- a/queue-4.19/series +++ b/queue-4.19/series @@ -1,3 +1,18 @@ net-be-more-gentle-about-silly-gso-requests-coming-from-user.patch block-bio-integrity-don-t-free-buf-if-bio_integrity_add_page-failed.patch fanotify-fix-ignore-mask-logic-for-events-on-child-and-on-dir.patch +mtd-rawnand-marvell-fix-the-condition-on-a-return-co.patch +net-bcmgenet-remove-hfb_ctrl-access.patch +net-sched-export-__netdev_watchdog_up.patch +net-be-more-gentle-about-silly-gso-requests-coming-f.patch +edac-amd64-add-family-17h-model-30h-pci-ids.patch +ib-mlx5-fix-devx-support-for-mlx5_cmd_op_init2init_q.patch +i2c-tegra-cleanup-kerneldoc-comments.patch +i2c-tegra-add-missing-kerneldoc-for-some-fields.patch +i2c-tegra-fix-maximum-transfer-size.patch +btrfs-make-caching_thread-use-btrfs_find_next_key.patch +fix-a-braino-in-sparc32-fix-register-window-handling.patch +alsa-hda-realtek-add-headset-button-supported-for-th.patch +alsa-hda-realtek-enable-the-headset-of-asus-b9450fa-.patch +alsa-hda-realtek-enable-mute-led-on-an-hp-system.patch +alsa-hda-realtek-enable-micmute-led-on-and-hp-system.patch -- 2.47.3