From 388682d79b64e0030e411b99c4926abcab844fa1 Mon Sep 17 00:00:00 2001 From: Greg Kroah-Hartman Date: Sun, 1 Jul 2018 11:00:42 +0200 Subject: [PATCH] 3.18-stable patches added patches: asoc-cirrus-i2s-fix-lrclk-configuration.patch asoc-cirrus-i2s-fix-tx-rx-linctrldata-setup.patch asoc-dapm-delete-dapm_kcontrol_data-paths-list-before-freeing-it.patch m68k-mm-adjust-vm-area-to-be-unmapped-by-gap-size-for-__iounmap.patch mips-ftrace-fix-static-function-graph-tracing.patch signal-xtensa-consistenly-use-sigbus-in-do_unaligned_user.patch usb-do-not-reset-if-a-low-speed-or-full-speed-device-timed-out.patch --- ...c-cirrus-i2s-fix-lrclk-configuration.patch | 80 +++++++++++++++++ ...rrus-i2s-fix-tx-rx-linctrldata-setup.patch | 85 +++++++++++++++++++ ...ol_data-paths-list-before-freeing-it.patch | 38 +++++++++ ...e-unmapped-by-gap-size-for-__iounmap.patch | 56 ++++++++++++ ...ce-fix-static-function-graph-tracing.patch | 80 +++++++++++++++++ queue-3.18/series | 7 ++ ...enly-use-sigbus-in-do_unaligned_user.patch | 39 +++++++++ ...speed-or-full-speed-device-timed-out.patch | 37 ++++++++ 8 files changed, 422 insertions(+) create mode 100644 queue-3.18/asoc-cirrus-i2s-fix-lrclk-configuration.patch create mode 100644 queue-3.18/asoc-cirrus-i2s-fix-tx-rx-linctrldata-setup.patch create mode 100644 queue-3.18/asoc-dapm-delete-dapm_kcontrol_data-paths-list-before-freeing-it.patch create mode 100644 queue-3.18/m68k-mm-adjust-vm-area-to-be-unmapped-by-gap-size-for-__iounmap.patch create mode 100644 queue-3.18/mips-ftrace-fix-static-function-graph-tracing.patch create mode 100644 queue-3.18/signal-xtensa-consistenly-use-sigbus-in-do_unaligned_user.patch create mode 100644 queue-3.18/usb-do-not-reset-if-a-low-speed-or-full-speed-device-timed-out.patch diff --git a/queue-3.18/asoc-cirrus-i2s-fix-lrclk-configuration.patch b/queue-3.18/asoc-cirrus-i2s-fix-lrclk-configuration.patch new file mode 100644 index 00000000000..37236559132 --- /dev/null +++ b/queue-3.18/asoc-cirrus-i2s-fix-lrclk-configuration.patch @@ -0,0 +1,80 @@ +From 2d534113be9a2aa532a1ae127a57e83558aed358 Mon Sep 17 00:00:00 2001 +From: Alexander Sverdlin +Date: Sat, 28 Apr 2018 22:51:38 +0200 +Subject: ASoC: cirrus: i2s: Fix LRCLK configuration + +From: Alexander Sverdlin + +commit 2d534113be9a2aa532a1ae127a57e83558aed358 upstream. + +The bit responsible for LRCLK polarity is i2s_tlrs (0), not i2s_trel (2) +(refer to "EP93xx User's Guide"). + +Previously card drivers which specified SND_SOC_DAIFMT_NB_IF actually got +SND_SOC_DAIFMT_NB_NF, an adaptation is necessary to retain the old +behavior. + +Signed-off-by: Alexander Sverdlin +Signed-off-by: Mark Brown +Cc: stable@vger.kernel.org +Signed-off-by: Greg Kroah-Hartman + +--- + sound/soc/cirrus/edb93xx.c | 2 +- + sound/soc/cirrus/ep93xx-i2s.c | 8 ++++---- + sound/soc/cirrus/snappercl15.c | 2 +- + 3 files changed, 6 insertions(+), 6 deletions(-) + +--- a/sound/soc/cirrus/edb93xx.c ++++ b/sound/soc/cirrus/edb93xx.c +@@ -67,7 +67,7 @@ static struct snd_soc_dai_link edb93xx_d + .cpu_dai_name = "ep93xx-i2s", + .codec_name = "spi0.0", + .codec_dai_name = "cs4271-hifi", +- .dai_fmt = SND_SOC_DAIFMT_I2S | SND_SOC_DAIFMT_NB_IF | ++ .dai_fmt = SND_SOC_DAIFMT_I2S | SND_SOC_DAIFMT_NB_NF | + SND_SOC_DAIFMT_CBS_CFS, + .ops = &edb93xx_ops, + }; +--- a/sound/soc/cirrus/ep93xx-i2s.c ++++ b/sound/soc/cirrus/ep93xx-i2s.c +@@ -213,24 +213,24 @@ static int ep93xx_i2s_set_dai_fmt(struct + switch (fmt & SND_SOC_DAIFMT_INV_MASK) { + case SND_SOC_DAIFMT_NB_NF: + /* Negative bit clock, lrclk low on left word */ +- clk_cfg &= ~(EP93XX_I2S_CLKCFG_CKP | EP93XX_I2S_CLKCFG_REL); ++ clk_cfg &= ~(EP93XX_I2S_CLKCFG_CKP | EP93XX_I2S_CLKCFG_LRS); + break; + + case SND_SOC_DAIFMT_NB_IF: + /* Negative bit clock, lrclk low on right word */ + clk_cfg &= ~EP93XX_I2S_CLKCFG_CKP; +- clk_cfg |= EP93XX_I2S_CLKCFG_REL; ++ clk_cfg |= EP93XX_I2S_CLKCFG_LRS; + break; + + case SND_SOC_DAIFMT_IB_NF: + /* Positive bit clock, lrclk low on left word */ + clk_cfg |= EP93XX_I2S_CLKCFG_CKP; +- clk_cfg &= ~EP93XX_I2S_CLKCFG_REL; ++ clk_cfg &= ~EP93XX_I2S_CLKCFG_LRS; + break; + + case SND_SOC_DAIFMT_IB_IF: + /* Positive bit clock, lrclk low on right word */ +- clk_cfg |= EP93XX_I2S_CLKCFG_CKP | EP93XX_I2S_CLKCFG_REL; ++ clk_cfg |= EP93XX_I2S_CLKCFG_CKP | EP93XX_I2S_CLKCFG_LRS; + break; + } + +--- a/sound/soc/cirrus/snappercl15.c ++++ b/sound/soc/cirrus/snappercl15.c +@@ -72,7 +72,7 @@ static struct snd_soc_dai_link snappercl + .codec_dai_name = "tlv320aic23-hifi", + .codec_name = "tlv320aic23-codec.0-001a", + .platform_name = "ep93xx-i2s", +- .dai_fmt = SND_SOC_DAIFMT_I2S | SND_SOC_DAIFMT_NB_IF | ++ .dai_fmt = SND_SOC_DAIFMT_I2S | SND_SOC_DAIFMT_NB_NF | + SND_SOC_DAIFMT_CBS_CFS, + .ops = &snappercl15_ops, + }; diff --git a/queue-3.18/asoc-cirrus-i2s-fix-tx-rx-linctrldata-setup.patch b/queue-3.18/asoc-cirrus-i2s-fix-tx-rx-linctrldata-setup.patch new file mode 100644 index 00000000000..26de25e7ce8 --- /dev/null +++ b/queue-3.18/asoc-cirrus-i2s-fix-tx-rx-linctrldata-setup.patch @@ -0,0 +1,85 @@ +From 5d302ed3cc80564fb835bed5fdba1e1250ecc9e5 Mon Sep 17 00:00:00 2001 +From: Alexander Sverdlin +Date: Sat, 28 Apr 2018 22:51:39 +0200 +Subject: ASoC: cirrus: i2s: Fix {TX|RX}LinCtrlData setup +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +From: Alexander Sverdlin + +commit 5d302ed3cc80564fb835bed5fdba1e1250ecc9e5 upstream. + +According to "EP93xx User’s Guide", I2STXLinCtrlData and I2SRXLinCtrlData +registers actually have different format. The only currently used bit +(Left_Right_Justify) has different position. Fix this and simplify the +whole setup taking into account the fact that both registers have zero +default value. + +The practical effect of the above is repaired SND_SOC_DAIFMT_RIGHT_J +support (currently unused). + +Signed-off-by: Alexander Sverdlin +Signed-off-by: Mark Brown +Cc: stable@vger.kernel.org +Signed-off-by: Greg Kroah-Hartman + +--- + sound/soc/cirrus/ep93xx-i2s.c | 18 ++++++++++-------- + 1 file changed, 10 insertions(+), 8 deletions(-) + +--- a/sound/soc/cirrus/ep93xx-i2s.c ++++ b/sound/soc/cirrus/ep93xx-i2s.c +@@ -51,7 +51,9 @@ + #define EP93XX_I2S_WRDLEN_24 (1 << 0) + #define EP93XX_I2S_WRDLEN_32 (2 << 0) + +-#define EP93XX_I2S_LINCTRLDATA_R_JUST (1 << 2) /* Right justify */ ++#define EP93XX_I2S_RXLINCTRLDATA_R_JUST BIT(1) /* Right justify */ ++ ++#define EP93XX_I2S_TXLINCTRLDATA_R_JUST BIT(2) /* Right justify */ + + #define EP93XX_I2S_CLKCFG_LRS (1 << 0) /* lrclk polarity */ + #define EP93XX_I2S_CLKCFG_CKP (1 << 1) /* Bit clock polarity */ +@@ -170,25 +172,25 @@ static int ep93xx_i2s_set_dai_fmt(struct + unsigned int fmt) + { + struct ep93xx_i2s_info *info = snd_soc_dai_get_drvdata(cpu_dai); +- unsigned int clk_cfg, lin_ctrl; ++ unsigned int clk_cfg; ++ unsigned int txlin_ctrl = 0; ++ unsigned int rxlin_ctrl = 0; + + clk_cfg = ep93xx_i2s_read_reg(info, EP93XX_I2S_RXCLKCFG); +- lin_ctrl = ep93xx_i2s_read_reg(info, EP93XX_I2S_RXLINCTRLDATA); + + switch (fmt & SND_SOC_DAIFMT_FORMAT_MASK) { + case SND_SOC_DAIFMT_I2S: + clk_cfg |= EP93XX_I2S_CLKCFG_REL; +- lin_ctrl &= ~EP93XX_I2S_LINCTRLDATA_R_JUST; + break; + + case SND_SOC_DAIFMT_LEFT_J: + clk_cfg &= ~EP93XX_I2S_CLKCFG_REL; +- lin_ctrl &= ~EP93XX_I2S_LINCTRLDATA_R_JUST; + break; + + case SND_SOC_DAIFMT_RIGHT_J: + clk_cfg &= ~EP93XX_I2S_CLKCFG_REL; +- lin_ctrl |= EP93XX_I2S_LINCTRLDATA_R_JUST; ++ rxlin_ctrl |= EP93XX_I2S_RXLINCTRLDATA_R_JUST; ++ txlin_ctrl |= EP93XX_I2S_TXLINCTRLDATA_R_JUST; + break; + + default: +@@ -237,8 +239,8 @@ static int ep93xx_i2s_set_dai_fmt(struct + /* Write new register values */ + ep93xx_i2s_write_reg(info, EP93XX_I2S_RXCLKCFG, clk_cfg); + ep93xx_i2s_write_reg(info, EP93XX_I2S_TXCLKCFG, clk_cfg); +- ep93xx_i2s_write_reg(info, EP93XX_I2S_RXLINCTRLDATA, lin_ctrl); +- ep93xx_i2s_write_reg(info, EP93XX_I2S_TXLINCTRLDATA, lin_ctrl); ++ ep93xx_i2s_write_reg(info, EP93XX_I2S_RXLINCTRLDATA, rxlin_ctrl); ++ ep93xx_i2s_write_reg(info, EP93XX_I2S_TXLINCTRLDATA, txlin_ctrl); + return 0; + } + diff --git a/queue-3.18/asoc-dapm-delete-dapm_kcontrol_data-paths-list-before-freeing-it.patch b/queue-3.18/asoc-dapm-delete-dapm_kcontrol_data-paths-list-before-freeing-it.patch new file mode 100644 index 00000000000..fbd962610ea --- /dev/null +++ b/queue-3.18/asoc-dapm-delete-dapm_kcontrol_data-paths-list-before-freeing-it.patch @@ -0,0 +1,38 @@ +From ff2faf1289c1f81b5b26b9451dd1c2006aac8db8 Mon Sep 17 00:00:00 2001 +From: Srinivas Kandagatla +Date: Mon, 4 Jun 2018 12:13:26 +0100 +Subject: ASoC: dapm: delete dapm_kcontrol_data paths list before freeing it + +From: Srinivas Kandagatla + +commit ff2faf1289c1f81b5b26b9451dd1c2006aac8db8 upstream. + +dapm_kcontrol_data is freed as part of dapm_kcontrol_free(), leaving the +paths pointer dangling in the list. + +This leads to system crash when we try to unload and reload sound card. +I hit this bug during ADSP crash/reboot test case on Dragon board DB410c. + +Without this patch, on SLAB Poisoning enabled build, kernel crashes with +"BUG kmalloc-128 (Tainted: G W ): Poison overwritten" + +Signed-off-by: Srinivas Kandagatla +Signed-off-by: Mark Brown +Cc: stable@vger.kernel.org +Signed-off-by: Greg Kroah-Hartman + +--- + sound/soc/soc-dapm.c | 2 ++ + 1 file changed, 2 insertions(+) + +--- a/sound/soc/soc-dapm.c ++++ b/sound/soc/soc-dapm.c +@@ -254,6 +254,8 @@ static int dapm_kcontrol_data_alloc(stru + static void dapm_kcontrol_free(struct snd_kcontrol *kctl) + { + struct dapm_kcontrol_data *data = snd_kcontrol_chip(kctl); ++ ++ list_del(&data->paths); + kfree(data->wlist); + kfree(data); + } diff --git a/queue-3.18/m68k-mm-adjust-vm-area-to-be-unmapped-by-gap-size-for-__iounmap.patch b/queue-3.18/m68k-mm-adjust-vm-area-to-be-unmapped-by-gap-size-for-__iounmap.patch new file mode 100644 index 00000000000..7a28e81b1f2 --- /dev/null +++ b/queue-3.18/m68k-mm-adjust-vm-area-to-be-unmapped-by-gap-size-for-__iounmap.patch @@ -0,0 +1,56 @@ +From 3f90f9ef2dda316d64e420d5d51ba369587ccc55 Mon Sep 17 00:00:00 2001 +From: Michael Schmitz +Date: Mon, 14 May 2018 23:10:53 +1200 +Subject: m68k/mm: Adjust VM area to be unmapped by gap size for __iounmap() + +From: Michael Schmitz + +commit 3f90f9ef2dda316d64e420d5d51ba369587ccc55 upstream. + +If 020/030 support is enabled, get_io_area() leaves an IO_SIZE gap +between mappings which is added to the vm_struct representing the +mapping. __ioremap() uses the actual requested size (after alignment), +while __iounmap() is passed the size from the vm_struct. + +On 020/030, early termination descriptors are used to set up mappings of +extent 'size', which are validated on unmapping. The unmapped gap of +size IO_SIZE defeats the sanity check of the pmd tables, causing +__iounmap() to loop forever on 030. + +On 040/060, unmapping of page table entries does not check for a valid +mapping, so the umapping loop always completes there. + +Adjust size to be unmapped by the gap that had been added in the +vm_struct prior. + +This fixes the hang in atari_platform_init() reported a long time ago, +and a similar one reported by Finn recently (addressed by removing +ioremap() use from the SWIM driver. + +Tested on my Falcon in 030 mode - untested but should work the same on +040/060 (the extra page tables cleared there would never have been set +up anyway). + +Signed-off-by: Michael Schmitz +[geert: Minor commit description improvements] +[geert: This was fixed in 2.4.23, but not in 2.5.x] +Signed-off-by: Geert Uytterhoeven +Cc: stable@vger.kernel.org +Signed-off-by: Greg Kroah-Hartman + +--- + arch/m68k/mm/kmap.c | 3 ++- + 1 file changed, 2 insertions(+), 1 deletion(-) + +--- a/arch/m68k/mm/kmap.c ++++ b/arch/m68k/mm/kmap.c +@@ -88,7 +88,8 @@ static inline void free_io_area(void *ad + for (p = &iolist ; (tmp = *p) ; p = &tmp->next) { + if (tmp->addr == addr) { + *p = tmp->next; +- __iounmap(tmp->addr, tmp->size); ++ /* remove gap added in get_io_area() */ ++ __iounmap(tmp->addr, tmp->size - IO_SIZE); + kfree(tmp); + return; + } diff --git a/queue-3.18/mips-ftrace-fix-static-function-graph-tracing.patch b/queue-3.18/mips-ftrace-fix-static-function-graph-tracing.patch new file mode 100644 index 00000000000..67b00934294 --- /dev/null +++ b/queue-3.18/mips-ftrace-fix-static-function-graph-tracing.patch @@ -0,0 +1,80 @@ +From 6fb8656646f996d1eef42e6d56203c4915cb9e08 Mon Sep 17 00:00:00 2001 +From: Matthias Schiffer +Date: Sat, 24 Mar 2018 17:57:49 +0100 +Subject: mips: ftrace: fix static function graph tracing + +From: Matthias Schiffer + +commit 6fb8656646f996d1eef42e6d56203c4915cb9e08 upstream. + +ftrace_graph_caller was never run after calling ftrace_trace_function, +breaking the function graph tracer. Fix this, bringing it in line with the +x86 implementation. + +While we're at it, also streamline the control flow of _mcount a bit to +reduce the number of branches. + +This issue was reported before: +https://www.linux-mips.org/archives/linux-mips/2014-11/msg00295.html + +Signed-off-by: Matthias Schiffer +Tested-by: Matt Redfearn +Patchwork: https://patchwork.linux-mips.org/patch/18929/ +Signed-off-by: Paul Burton +Cc: stable@vger.kernel.org # v3.17+ +Signed-off-by: Greg Kroah-Hartman + +--- + arch/mips/kernel/mcount.S | 27 ++++++++++++--------------- + 1 file changed, 12 insertions(+), 15 deletions(-) + +--- a/arch/mips/kernel/mcount.S ++++ b/arch/mips/kernel/mcount.S +@@ -116,10 +116,20 @@ ftrace_stub: + NESTED(_mcount, PT_SIZE, ra) + PTR_LA t1, ftrace_stub + PTR_L t2, ftrace_trace_function /* Prepare t2 for (1) */ +- bne t1, t2, static_trace ++ beq t1, t2, fgraph_trace + nop + ++ MCOUNT_SAVE_REGS ++ ++ move a0, ra /* arg1: self return address */ ++ jalr t2 /* (1) call *ftrace_trace_function */ ++ move a1, AT /* arg2: parent's return address */ ++ ++ MCOUNT_RESTORE_REGS ++ ++fgraph_trace: + #ifdef CONFIG_FUNCTION_GRAPH_TRACER ++ PTR_LA t1, ftrace_stub + PTR_L t3, ftrace_graph_return + bne t1, t3, ftrace_graph_caller + nop +@@ -128,24 +138,11 @@ NESTED(_mcount, PT_SIZE, ra) + bne t1, t3, ftrace_graph_caller + nop + #endif +- b ftrace_stub +-#ifdef CONFIG_32BIT +- addiu sp, sp, 8 +-#else +- nop +-#endif +- +-static_trace: +- MCOUNT_SAVE_REGS +- +- move a0, ra /* arg1: self return address */ +- jalr t2 /* (1) call *ftrace_trace_function */ +- move a1, AT /* arg2: parent's return address */ + +- MCOUNT_RESTORE_REGS + #ifdef CONFIG_32BIT + addiu sp, sp, 8 + #endif ++ + .globl ftrace_stub + ftrace_stub: + RETURN_BACK diff --git a/queue-3.18/series b/queue-3.18/series index 84c514a1c39..583a58549f1 100644 --- a/queue-3.18/series +++ b/queue-3.18/series @@ -44,3 +44,10 @@ libata-zpodd-small-read-overflow-in-eject_tray.patch libata-drop-sandisk-sd7ub3q-g1001-nolpm-quirk.patch w1-mxc_w1-enable-clock-before-calling-clk_get_rate-on-it.patch fs-binfmt_misc.c-do-not-allow-offset-overflow.patch +m68k-mm-adjust-vm-area-to-be-unmapped-by-gap-size-for-__iounmap.patch +signal-xtensa-consistenly-use-sigbus-in-do_unaligned_user.patch +usb-do-not-reset-if-a-low-speed-or-full-speed-device-timed-out.patch +asoc-dapm-delete-dapm_kcontrol_data-paths-list-before-freeing-it.patch +asoc-cirrus-i2s-fix-lrclk-configuration.patch +asoc-cirrus-i2s-fix-tx-rx-linctrldata-setup.patch +mips-ftrace-fix-static-function-graph-tracing.patch diff --git a/queue-3.18/signal-xtensa-consistenly-use-sigbus-in-do_unaligned_user.patch b/queue-3.18/signal-xtensa-consistenly-use-sigbus-in-do_unaligned_user.patch new file mode 100644 index 00000000000..42c224d4e9e --- /dev/null +++ b/queue-3.18/signal-xtensa-consistenly-use-sigbus-in-do_unaligned_user.patch @@ -0,0 +1,39 @@ +From 7de712ccc096b81d23cc0a941cd9b8cb3956605d Mon Sep 17 00:00:00 2001 +From: "Eric W. Biederman" +Date: Fri, 20 Apr 2018 09:14:56 -0500 +Subject: signal/xtensa: Consistenly use SIGBUS in do_unaligned_user + +From: Eric W. Biederman + +commit 7de712ccc096b81d23cc0a941cd9b8cb3956605d upstream. + +While working on changing this code to use force_sig_fault I +discovered that do_unaliged_user is sets si_signo to SIGBUS and passes +SIGSEGV to force_sig_info. Which is just b0rked. + +The code is reporting a SIGBUS error so replace the SIGSEGV with SIGBUS. + +Cc: Chris Zankel +Cc: Max Filippov +Cc: linux-xtensa@linux-xtensa.org +Cc: stable@vger.kernel.org +Acked-by: Max Filippov +Fixes: 5a0015d62668 ("[PATCH] xtensa: Architecture support for Tensilica Xtensa Part 3") +Signed-off-by: "Eric W. Biederman" +Signed-off-by: Greg Kroah-Hartman + +--- + arch/xtensa/kernel/traps.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +--- a/arch/xtensa/kernel/traps.c ++++ b/arch/xtensa/kernel/traps.c +@@ -280,7 +280,7 @@ do_unaligned_user (struct pt_regs *regs) + info.si_errno = 0; + info.si_code = BUS_ADRALN; + info.si_addr = (void *) regs->excvaddr; +- force_sig_info(SIGSEGV, &info, current); ++ force_sig_info(SIGBUS, &info, current); + + } + #endif diff --git a/queue-3.18/usb-do-not-reset-if-a-low-speed-or-full-speed-device-timed-out.patch b/queue-3.18/usb-do-not-reset-if-a-low-speed-or-full-speed-device-timed-out.patch new file mode 100644 index 00000000000..fe1e7299358 --- /dev/null +++ b/queue-3.18/usb-do-not-reset-if-a-low-speed-or-full-speed-device-timed-out.patch @@ -0,0 +1,37 @@ +From 6e01827ed93947895680fbdad68c072a0f4e2450 Mon Sep 17 00:00:00 2001 +From: Maxim Moseychuk +Date: Thu, 4 Jan 2018 21:43:03 +0300 +Subject: usb: do not reset if a low-speed or full-speed device timed out + +From: Maxim Moseychuk + +commit 6e01827ed93947895680fbdad68c072a0f4e2450 upstream. + +Some low-speed and full-speed devices (for example, bluetooth) +do not have time to initialize. For them, ETIMEDOUT is a valid error. +We need to give them another try. Otherwise, they will +never be initialized correctly and in dmesg will be messages +"Bluetooth: hci0 command 0x1002 tx timeout" or similars. + +Fixes: 264904ccc33c ("usb: retry reset if a device times out") +Cc: stable +Signed-off-by: Maxim Moseychuk +Signed-off-by: Greg Kroah-Hartman + +--- + drivers/usb/core/hub.c | 4 +++- + 1 file changed, 3 insertions(+), 1 deletion(-) + +--- a/drivers/usb/core/hub.c ++++ b/drivers/usb/core/hub.c +@@ -4405,7 +4405,9 @@ hub_port_init (struct usb_hub *hub, stru + * reset. But only on the first attempt, + * lest we get into a time out/reset loop + */ +- if (r == 0 || (r == -ETIMEDOUT && retries == 0)) ++ if (r == 0 || (r == -ETIMEDOUT && ++ retries == 0 && ++ udev->speed > USB_SPEED_FULL)) + break; + } + udev->descriptor.bMaxPacketSize0 = -- 2.47.3