[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20120226202710.GA23874@electric-eye.fr.zoreil.com>
Date: Sun, 26 Feb 2012 21:27:10 +0100
From: Francois Romieu <romieu@...zoreil.com>
To: Bart Van Assche <bvanassche@....org>
Cc: netdev@...r.kernel.org, Stephen Hemminger <shemminger@...l.org>,
Jeff Garzik <jeff@...zik.org>
Subject: Re: [PATCH, RFC] skge: Fix race in tx path
Bart Van Assche <bvanassche@....org> :
[...]
> diff --git a/drivers/net/ethernet/marvell/skge.c b/drivers/net/ethernet/marvell/skge.c
> index dea0cb4..2d805b9 100644
> --- a/drivers/net/ethernet/marvell/skge.c
> +++ b/drivers/net/ethernet/marvell/skge.c
> @@ -2793,7 +2793,8 @@ static netdev_tx_t skge_xmit_frame(struct sk_buff *skb,
> tf->control |= BMU_EOF | BMU_IRQ_EOF;
> }
> /* Make sure all the descriptors written */
> - wmb();
> + skge->tx_ring.to_use = e->next;
> + smp_wmb();
> td->control = BMU_OWN | BMU_SW | BMU_STF | control | len;
> wmb();
With this change it seems possible for skge_tx_done to unmap a buffer before
it is sent when the requests for skge_xmit_frame are close enough.
--
Ueimor
--
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