Thread (31 messages) 31 messages, 3 authors, 2014-05-02

Re: [PATCH 02/26] can: c_can: Fix startup logic

From: Marc Kleine-Budde <mkl@pengutronix.de>
Date: 2014-05-02 12:38:07
Also in: linux-can

On 04/29/2014 09:29 AM, Yegor Yefremov wrote:
On Fri, Apr 25, 2014 at 12:00 AM, Marc Kleine-Budde [off-list ref] wrote:
quoted
From: Thomas Gleixner <redacted>

c_can_start() enables interrupts way too early. The first enabling
happens when setting the control mode in c_can_chip_config() and then
again at the end of the function.

But that happens before napi_enable() and that means that an interrupt
which comes in will disable interrupts again and call napi_schedule,
which ignores the request and the later napi_enable() is not making
thinks work either. So the interface is up with all device interrupts
disabled.

Move the device interrupt after napi_enable() and add it to the other
callsites of c_can_start() in c_can_set_mode() and c_can_power_up()

Signed-off-by: Thomas Gleixner <redacted>
Tested-by: Alexander Stein <redacted>
Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
Tested-by: Yegor Yefremov <redacted>
Thanks, as this branch is already merged by David, it's too late to add
your Tested-by.

Marc

-- 
Pengutronix e.K.                  | Marc Kleine-Budde           |
Industrial Linux Solutions        | Phone: +49-231-2826-924     |
Vertretung West/Dortmund          | Fax:   +49-5121-206917-5555 |
Amtsgericht Hildesheim, HRA 2686  | http://www.pengutronix.de   |
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help