[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <200803252155.56082.florian.fainelli@telecomint.eu>
Date: Tue, 25 Mar 2008 21:55:55 +0100
From: Florian Fainelli <florian.fainelli@...ecomint.eu>
To: Francois Romieu <romieu@...zoreil.com>
Cc: Johannes Berg <johannes@...solutions.net>,
David Miller <davem@...emloft.net>, netdev@...r.kernel.org,
Jeff Garzik <jeff@...zik.org>, Felix Fietkau <nbd@...nwrt.org>
Subject: Re: [PATCH] Add support the Korina (IDT RC32434) Ethernet MAC
Hello Francois,
Le mercredi 19 mars 2008, Francois Romieu a écrit :
> ^ space before tab
Fixed.
> If the allocation fails, the driver will have to handle a shorter
> than expected ring (it is probably ok, I have not checked it). You
> may consider initializing the link field for each descriptor if
> possible. See epic_init_ring() for some inspiration.
That is why I use the i variable such that if a break in the loop happens, the
ring and last/first decscriptors are properly set.
> The irqs will be disabled for whatever device shares them...
>
> [...]
>
> > + free_irq(lp->rx_irq, dev);
> > + free_irq(lp->tx_irq, dev);
> > + free_irq(lp->ovr_irq, dev);
> > + free_irq(lp->und_irq, dev);
>
> ... and they will not be enabled again.
>
> You should avoid disable_irq here and disable the irq with some
> korina register write prior to free_irq instead.
Ethernet MAC datasheet does not seem to mention a way to disable IRQ unless
reseting the ethernet logic itself. Since this MAC is used in an embedded
system, closing the ethernet driver usually mean shutting down the device as
well. I will try to work around this.
> It will work as is but you could merge both of those in a single
> variable (name it 'rc' and the consequences will appear directly
> in the diff between this patch and the next version).
Fixed, must have been particularly braindead not to realize that before.
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists