can: grcan: only use the NAPI poll budget for RX
authorAndreas Larsson <andreas@gaisler.com>
Fri, 29 Apr 2022 08:46:56 +0000 (10:46 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 12 May 2022 10:30:09 +0000 (12:30 +0200)
commit56a5ff94807d8dfcc3985df3a3ffe3bfb29427a2
treea52d72fe7bfd032fcef2db94de9cabb2d21ae341
parentab5adbcead0018e8ae6bd9927fa479b35b4ca73f
can: grcan: only use the NAPI poll budget for RX

commit 2873d4d52f7c52d60b316ba6c47bd7122b5a9861 upstream.

The previous split budget between TX and RX made it return not using
the entire budget but at the same time not having calling called
napi_complete. This sometimes led to the poll to not be called, and at
the same time having TX and RX interrupts disabled resulting in the
driver getting stuck.

Fixes: 6cec9b07fe6a ("can: grcan: Add device driver for GRCAN and GRHCAN cores")
Link: https://lore.kernel.org/all/20220429084656.29788-4-andreas@gaisler.com
Cc: stable@vger.kernel.org
Signed-off-by: Andreas Larsson <andreas@gaisler.com>
Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/net/can/grcan.c