[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <5265037D.2080908@pengutronix.de>
Date: Mon, 21 Oct 2013 12:35:41 +0200
From: Marc Kleine-Budde <mkl@...gutronix.de>
To: Ben Hutchings <ben@...adent.org.uk>
CC: linux-kernel@...r.kernel.org, stable@...r.kernel.org,
akpm@...ux-foundation.org,
Lothar Waßmann <LW@...O-electronics.de>
Subject: Re: [PATCH 3.2 094/149] can: flexcan: fix flexcan_chip_start() on
imx6
On 10/21/2013 10:46 AM, Ben Hutchings wrote:
> 3.2.52-rc1 review patch. If anyone has any objections, please let me know.
Please postpone until:
d5a7b40 can: flexcan: flexcan_chip_start: fix regression, mark one MB
for TX and abort pending TX
hits mainline as this patch (fix flexcan_chip_start() on imx6) causes
another problem.
As soon as both are mainline, please apply them:
d5a7b40 can: flexcan: flexcan_chip_start: fix regression, mark one MB
for TX and abort pending TX
0d1862e can: flexcan: fix flexcan_chip_start() on imx6
Marc
>
> ------------------
>
> From: Marc Kleine-Budde <mkl@...gutronix.de>
>
> commit 0d1862ea1a5bb876cf05555a7307080cb75bf379 upstream.
>
> In the flexcan_chip_start() function first the flexcan core is going through
> the soft reset sequence, then the RX FIFO is enabled.
>
> With the hardware is put into FIFO mode, message buffers 1...7 are reserved by
> the FIFO engine. The remaining message buffers are in reset default values.
> This patch removes the bogus initialization of the message buffers, as it
> causes an imprecise external abort on imx6.
>
> Reported-by: Lothar Waßmann <LW@...O-electronics.de>
> Tested-by: Lothar Waßmann <LW@...O-electronics.de>
> Signed-off-by: Marc Kleine-Budde <mkl@...gutronix.de>
> Signed-off-by: Ben Hutchings <ben@...adent.org.uk>
> ---
> drivers/net/can/flexcan.c | 12 ------------
> 1 file changed, 12 deletions(-)
>
> --- a/drivers/net/can/flexcan.c
> +++ b/drivers/net/can/flexcan.c
> @@ -666,7 +666,6 @@ static int flexcan_chip_start(struct net
> {
> struct flexcan_priv *priv = netdev_priv(dev);
> struct flexcan_regs __iomem *regs = priv->base;
> - unsigned int i;
> int err;
> u32 reg_mcr, reg_ctrl;
>
> @@ -732,17 +731,6 @@ static int flexcan_chip_start(struct net
> dev_dbg(dev->dev.parent, "%s: writing ctrl=0x%08x", __func__, reg_ctrl);
> flexcan_write(reg_ctrl, ®s->ctrl);
>
> - for (i = 0; i < ARRAY_SIZE(regs->cantxfg); i++) {
> - flexcan_write(0, ®s->cantxfg[i].can_ctrl);
> - flexcan_write(0, ®s->cantxfg[i].can_id);
> - flexcan_write(0, ®s->cantxfg[i].data[0]);
> - flexcan_write(0, ®s->cantxfg[i].data[1]);
> -
> - /* put MB into rx queue */
> - flexcan_write(FLEXCAN_MB_CNT_CODE(0x4),
> - ®s->cantxfg[i].can_ctrl);
> - }
> -
> /* acceptance mask/acceptance code (accept everything) */
> flexcan_write(0x0, ®s->rxgmask);
> flexcan_write(0x0, ®s->rx14mask);
>
>
--
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 |
Download attachment "signature.asc" of type "application/pgp-signature" (260 bytes)
Powered by blists - more mailing lists