linux-sh.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Rob Landley <rob@landley.net>
To: John Paul Adrian Glaubitz <glaubitz@physik.fu-berlin.de>
Cc: Linux-sh list <linux-sh@vger.kernel.org>
Subject: Re: Kernel crash when syncing to usb-storage
Date: Thu, 19 Nov 2020 04:58:39 -0600	[thread overview]
Message-ID: <ede2a799-ce5f-4331-63f8-51f6a17427d7@landley.net> (raw)
In-Reply-To: <0133c4fc-81a9-7d8a-8aee-3756bd6d34a2@physik.fu-berlin.de>

On 11/18/20 4:09 AM, John Paul Adrian Glaubitz wrote:
> Hi Rob!
> 
> On 11/18/20 11:11 AM, Rob Landley wrote:
>>> Recently, I have started to see crashes when I try to sync a FAT filesystem
>>> on a USB pen drive. The crash is reproducible and seems to have been introduced
>>> in the 5.10 development cycle. I have not bisected the issue yet.
>>
>> Which board is this on? (Kernel config?)
> 
> SH-7785LCR, I'm attaching the kernel configuration for 5.9. I don't have the one
> for 5.10 at hand right now, but I used the same configuration for 5.9 and 5.10.
> 
>> Is it immediate or a ways into the backup?
> 
> It happens the moment the kernel tries to write the data to the USB drive.

Smells like an incorrectly initialized field in the interrupt state. Let's see...

# IRQ chip support
#
# end of IRQ chip support

# Interrupt controller options
#
CONFIG_INTC_USERIMASK=y
# CONFIG_INTC_MAPPING_DEBUG is not set
# end of SuperH / SH-Mobile Driver Options
# end of Kernel features

Very helpful.

CONFIG_IRQ_FORCED_THREADING=y
CONFIG_IRQ_WORK=y

I wonder what those do? I don't remember either...

> 5.9 is not affected, so it must be a regression with 5.10. I will bisect later
> this week.

There are many irq patches to choose from. And the DMA patches have potential
IRQ impact too (CONFIG_SH_DMA_IRQ_MULTI=y).

>> The stack trace says the idle tasks is handling an interrupt and crashing in the
>> interrupt controller code? Let's see...
>>
>> git log --no-merges v5.9..master arch/sh drivers/irqchip drivers/sh drivers/dma/sh
>>
>> This may not be a fat OR usb issue, there were some plumbing changes recently in
>> IRQ controllers and such, ala b388bdf2bac7 and f9ac7bbd6e45 and a7480c5d725c and
>> a00e85b581fd and 57733e009f0c and...
> 
> I will report back once I have found the culprit. I haven't had the time for bisecting
> yet.

Thanks.

I'm in Tokyo this month far _far_ away from my little blue board, and it's been
long enough since I've re-kerneled that I don't actually remember how anyway. (I
should poke you for a walkthrough over christmas...)

> Adrian
Rob

       reply	other threads:[~2020-11-19 10:47 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <d89a074e-c0ed-5d8b-a58e-ce3d420f579e@physik.fu-berlin.de>
     [not found] ` <3a807d90-44c6-7c97-ae1d-89a3f3414baf@landley.net>
     [not found]   ` <0133c4fc-81a9-7d8a-8aee-3756bd6d34a2@physik.fu-berlin.de>
2020-11-19 10:58     ` Rob Landley [this message]
2020-11-29 16:42 ` Kernel crash when syncing to usb-storage John Paul Adrian Glaubitz
2020-11-29 20:41   ` Rob Landley
2020-11-29 22:07     ` John Paul Adrian Glaubitz
2020-12-18 22:06 ` John Paul Adrian Glaubitz

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=ede2a799-ce5f-4331-63f8-51f6a17427d7@landley.net \
    --to=rob@landley.net \
    --cc=glaubitz@physik.fu-berlin.de \
    --cc=linux-sh@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).