From: Patrick Williams <patrick@stwcx.xyz>
To: Billy Tsai <billy_tsai@aspeedtech.com>
Cc: OpenBMC List <openbmc@lists.ozlabs.org>, Peter Delevoryas <pdel@fb.com>
Subject: Re: aspeed-adc driver kpanic
Date: Mon, 4 Oct 2021 13:54:02 -0500 [thread overview]
Message-ID: <YVtNypUnYfp/kztP@heinlein> (raw)
In-Reply-To: <YVtJTrgm3b3W4PY9@heinlein>
[-- Attachment #1: Type: text/plain, Size: 1291 bytes --]
On Mon, Oct 04, 2021 at 01:34:54PM -0500, Patrick Williams wrote:
> Hi Billy,
>
> When I run the latest linux-5.14 on QEMU with the Witherspoon config, I end up
> with a kernel panic[1]. I think there is an ordering problem in the aspeed_adc
> driver.
>
> See [2,3]. The code registers with devm a pointer to the prescaler object which
> is not yet created. I think it is possible that the struct value contains
> uninitialized data as well. Can you please take a look at this?
>
> 1. https://gist.github.com/williamspatrick/4a0f0d1e0ca6f54816461a8df09e6cb8
> 2. https://github.com/openbmc/linux/blob/dev-5.14/drivers/iio/adc/aspeed_adc.c#L513
> 3. https://github.com/openbmc/linux/blob/dev-5.14/drivers/iio/adc/aspeed_adc.c#L527
>
> --
> Patrick Williams
Also, Peter D. has been working on getting the QEMU code for the ADC working
and I cherry-picked his commits[1] and the code gets farther but crashes with
what seems like a memory alignment issue in a read at [2]. New gist of kernel panic
at [3].
1. https://github.com/peterdelevoryas/qemu/tree/adc-support-v2
2. https://github.com/openbmc/linux/blob/dev-5.14/drivers/iio/adc/aspeed_adc.c#L248
3. https://gist.github.com/williamspatrick/76827c99e2db8fce385b9a87f7526d33
--
Patrick Williams
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
next prev parent reply other threads:[~2021-10-04 18:54 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-10-04 18:34 aspeed-adc driver kpanic Patrick Williams
2021-10-04 18:54 ` Patrick Williams [this message]
2021-10-04 19:26 ` Peter Delevoryas
2021-10-04 22:25 ` Patrick Williams
2021-10-05 0:00 ` Joel Stanley
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=YVtNypUnYfp/kztP@heinlein \
--to=patrick@stwcx.xyz \
--cc=billy_tsai@aspeedtech.com \
--cc=openbmc@lists.ozlabs.org \
--cc=pdel@fb.com \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.