From: David Miller <davem@davemloft.net>
To: jim_baxter@mentor.com
Cc: netdev@vger.kernel.org
Subject: Re: [PATCH 1/1] net: fec: fix miss init spinlock
Date: Thu, 21 Feb 2013 13:03:18 -0500 (EST) [thread overview]
Message-ID: <20130221.130318.641947665855008551.davem@davemloft.net> (raw)
In-Reply-To: <loom.20130221T185110-574@post.gmane.org>
From: Jim Baxter <jim_baxter@mentor.com>
Date: Thu, 21 Feb 2013 17:59:23 +0000 (UTC)
> Fabio Estevam <festevam <at> gmail.com> writes:
>
>>
>> On Thu, Feb 21, 2013 at 2:07 PM, Jim Baxter <jim_baxter <at> mentor.com> wrote:
>> > Is the general issue in this driver that the fec_probe function:
>> > request_irq(irq, fec_enet_interrupt, IRQF_DISABLED, pdev->name, ndev);
>> >
>> > is called before fec_ptp_init() and fec_enet_init() have been called so that
>> > there is a chance the fec_enet_interrupt can occur before the hardware and
> data
>> > structures are fully setup?
>>
>> The scenario you described is fixed by the patch that Frank proposed at:
>> http://patchwork.ozlabs.org/patch/222164/
>>
>
> That is a good patch that will stop interrupts occurring before request_irq is
> called.
>
> What about the problem of fec_enet_interrupt calling fec_ptp_start_cyclecounter
> before fec_ptp_init has been called?
>
> Should fec_enet_init and fec_ptp_init be setup before the request_irq is called?
This is a reocurring theme, and there is only one answer.
All software state MUCH be completely, and fully, initialized before
request_irq() is invoked.
There is no other valid way to proceed in this area.
next prev parent reply other threads:[~2013-02-21 18:03 UTC|newest]
Thread overview: 24+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-02-01 8:56 [PATCH 1/1] net: fec: fix miss init spinlock Frank Li
2013-02-03 4:08 ` David Miller
2013-02-04 2:22 ` Frank Li
2013-02-04 5:24 ` David Miller
2013-02-04 6:31 ` Frank Li
2013-02-04 20:03 ` David Miller
2013-02-04 16:52 ` Jim Baxter
2013-02-05 7:05 ` Frank Li
2013-02-05 10:18 ` Jim Baxter
2013-02-06 9:50 ` Frank Li
2013-02-06 13:48 ` Waskiewicz Jr, Peter P
2013-02-07 1:42 ` Frank Li
2013-02-22 12:25 ` Jim Baxter
2013-02-22 21:17 ` Fabio Estevam
2013-02-23 0:46 ` Frank Li
2013-02-23 2:08 ` Fabio Estevam
2013-02-04 23:23 ` Dmitry Eremin-Solenikov
2013-02-05 2:40 ` Frank Li
2013-02-21 17:07 ` Jim Baxter
2013-02-21 17:28 ` Fabio Estevam
2013-02-21 17:59 ` Jim Baxter
2013-02-21 18:03 ` David Miller [this message]
2013-02-21 18:04 ` Fabio Estevam
2013-02-21 19:04 ` Fabio Estevam
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=20130221.130318.641947665855008551.davem@davemloft.net \
--to=davem@davemloft.net \
--cc=jim_baxter@mentor.com \
--cc=netdev@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).