| To: | Ian Campbell <icampbell@xxxxxxxxx> |
|---|---|
| Subject: | Re: "deadlock" between smc91x driver and link_watch |
| From: | Nicolas Pitre <nico@xxxxxxx> |
| Date: | Wed, 24 Nov 2004 10:21:06 -0500 (EST) |
| Cc: | Andrew Morton <akpm@xxxxxxxx>, linux-kernel@xxxxxxxxxxxxxxx, netdev@xxxxxxxxxxx |
| In-reply-to: | <1101290297.10841.15.camel@icampbell-debian> |
| References: | <1101230194.14370.12.camel@icampbell-debian> <20041123153158.6f20a7d7.akpm@xxxxxxxx> <1101289309.10841.9.camel@icampbell-debian> <20041124014650.47af8ae4.akpm@xxxxxxxx> <1101290297.10841.15.camel@icampbell-debian> |
| Sender: | netdev-bounce@xxxxxxxxxxx |
On Wed, 24 Nov 2004, Ian Campbell wrote:
> Quite right. Fixed patch included.
Small question:
> + * smc_phy_configure_wq
> + *
> + * The net_device is referenced when the work was scheduled to avoid
> + * the need for a flush_scheduled_work() in smc_close(). Drop the
> + * reference and then do the configuration.
You probably want to invert the comment here too.
> +static void smc_phy_configure_wq(void *data)
> +{
> + struct net_device *dev = data;
> + smc_phy_configure(data);
> + dev_put(dev);
> +}
[...]
> @@ -1536,10 +1553,8 @@
> /* clear everything */
> smc_shutdown(dev);
>
> - if (lp->phy_type != 0) {
> - flush_scheduled_work();
> + if (lp->phy_type != 0)
> smc_phy_powerdown(dev, lp->mii.phy_id);
How do you ensure that smc_phy_configure() can't end up being called
after smc_phy_powerdown() here?
Nicolas
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| ||
| Previous by Date: | [e1000] print bus type/speed/width on probe, Lennert Buytenhek |
|---|---|
| Next by Date: | Re: "deadlock" between smc91x driver and link_watch, Ian Campbell |
| Previous by Thread: | Re: "deadlock" between smc91x driver and link_watch, Ian Campbell |
| Next by Thread: | Re: "deadlock" between smc91x driver and link_watch, Ian Campbell |
| Indexes: | [Date] [Thread] [Top] [All Lists] |