[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-Id: <20140722.195720.2254769990435787100.davem@davemloft.net>
Date: Tue, 22 Jul 2014 19:57:20 -0700 (PDT)
From: David Miller <davem@...emloft.net>
To: stefan.sorensen@...ctralink.com
Cc: richardcochran@...il.com, netdev@...r.kernel.org
Subject: Re: [PATCH v2 net-next] dp83640: Fix receive timestamp race
condition
From: Stefan Sørensen <stefan.sorensen@...ctralink.com>
Date: Tue, 22 Jul 2014 15:20:45 +0200
> When timestamping received packets, rx_timestamp_work may be scheduled
> before the timestamps is received from the hardware resulting in the
> packet beeing delivered without the timestamp.
>
> This is fixed by changing the receive timestamp path:
>
> On receiving a packet that need timestamping, the rxts list is
> traversed. If a match is found, packet+timestamp are delivered,
> otherwise the packet is added to a rx_queue.
>
> When a timestamp arrives rx_queue is traversed and if a matching
> packet is found, it is delivered with the timestamp. Otherwise the
> timestamp is added to the rxts list for matching with packets arriving
> later.
>
> In case the hardware drops a timestamp, a workqueue regularly checks
> the queue for old packets and delivers them without a timestamp.
>
> Signed-off-by: Stefan Sørensen <stefan.sorensen@...ctralink.com>
Applied.
--
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