[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID:
<PAXPR04MB8510F4E5D06C7060665C58FB887E2@PAXPR04MB8510.eurprd04.prod.outlook.com>
Date: Tue, 8 Oct 2024 06:37:04 +0000
From: Wei Fang <wei.fang@....com>
To: Linus Torvalds <torvalds@...ux-foundation.org>, Guenter Roeck
<linux@...ck-us.net>
CC: Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
Csókás, Bence <csokas.bence@...lan.hu>, Paolo Abeni
<pabeni@...hat.com>
Subject: RE: Linux 6.12-rc2
> -----Original Message-----
> From: Linus Torvalds <torvalds@...ux-foundation.org>
> Sent: 2024年10月8日 1:26
> To: Guenter Roeck <linux@...ck-us.net>
> Cc: Linux Kernel Mailing List <linux-kernel@...r.kernel.org>; Csókás, Bence
> <csokas.bence@...lan.hu>; Wei Fang <wei.fang@....com>; Paolo Abeni
> <pabeni@...hat.com>
> Subject: Re: Linux 6.12-rc2
>
> On Mon, 7 Oct 2024 at 10:00, Guenter Roeck <linux@...ck-us.net> wrote:
> >
> > The failed qemu tests are crashes, bisected to commit d9335d0232d2 ("net:
> fec: Reload PTP
> > registers after link-state change"). I copied the author and reviewers for
> feedback.
>
> It seems to be this in timecounter_read_delta() (inlined into
> timecounter_read()):
>
> /* read cycle counter: */
> cycle_now = tc->cc->read(tc->cc);
>
> where "tc->cc" is NULL (but that's just a guess from the fact that the
> exception happens very early in timecounter_read()).
>
> So presumably the timecounter_init() hasn't been called yet
> (fec_ptp_init -> fec_ptp_start_cyclecounter -> timecounter_init).
>
> And looking around, we have fec_probe() doing
>
> irq_cnt = fec_enet_get_irq_cnt(pdev);
> if (fep->bufdesc_ex)
> fec_ptp_init(pdev, irq_cnt);
>
> so the fec_ptp_init() is called conditionally, but
> fec_ptp_save_state() that does the timecounter_read() seems to be
> called unconditionally.
>
> So that commit d9335d0232d2 looks just broken. Either the
> timecounter_init() needs to be done unconditionally, or the
> timecounter_read() needs to be conditional on ptp being inited.
>
This analysis is absolutely correct. I have cooked up a patch for
this issue.
Thanks very much.
Powered by blists - more mailing lists