From: Ivo van Doorn <ivdoorn@gmail.com>
To: Johannes Berg <johannes@sipsolutions.net>
Cc: linville@tuxdriver.com,
linux-wireless <linux-wireless@vger.kernel.org>,
rt2400-devel@lists.sourceforge.net
Subject: Re: [PATCH 4/4] rt2x00: Report RX end time for rt2400pci
Date: Fri, 4 Jul 2008 14:25:00 +0200 [thread overview]
Message-ID: <200807041425.00591.IvDoorn@gmail.com> (raw)
In-Reply-To: <1215171723.19862.4.camel@johannes.berg>
On Friday 04 July 2008, Johannes Berg wrote:
>
> > rt2x00_desc_read(entry_priv->desc, 0, &word0);
> > rt2x00_desc_read(entry_priv->desc, 2, &word2);
> > rt2x00_desc_read(entry_priv->desc, 3, &word3);
> > + rt2x00_desc_read(entry_priv->desc, 4, &word4);
> >
> > if (rt2x00_get_field32(word0, RXD_W0_CRC_ERROR))
> > rxdesc->flags |= RX_FLAG_FAILED_FCS_CRC;
> > @@ -1106,6 +1108,7 @@ static void rt2400pci_fill_rxdone(struct queue_entry *entry,
> > * The signal is the PLCP value, and needs to be stripped
> > * of the preamble bit (0x08).
> > */
> > + rxdesc->timestamp = rt2x00_get_field32(word4, RXD_W4_RX_END_TIME);
>
> You really should extend that, like this it's going to cause trouble as
> soon as it has overflowed 32 bits once.
Ok, but if I do the get_tsf() callback, to grab the upper 32 bytes of the timestamp,
you will get the same problems during wraparounds, because the upper 32 bytes
can be from _after_ the wrapround while the lower 32 bytes from the descriptor
are still from _before_ the wraparound.
Ivo
next prev parent reply other threads:[~2008-07-04 12:18 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <200807041340.28103.IvDoorn@gmail.com>
2008-07-04 11:41 ` [PATCH 2/4] rt2x00: Decrease alignment headroom Ivo van Doorn
2008-07-04 12:56 ` [PATCH 2/4 v2] " Ivo van Doorn
[not found] ` <200807041340.53147.IvDoorn@gmail.com>
2008-07-04 11:41 ` [PATCH 3/4] rt2x00: Use ieee80211_hw->workqueue again Ivo van Doorn
2008-07-04 11:41 ` [PATCH 4/4] rt2x00: Report RX end time for rt2400pci Ivo van Doorn
2008-07-04 11:42 ` Johannes Berg
2008-07-04 12:25 ` Ivo van Doorn [this message]
2008-07-04 12:23 ` Johannes Berg
2008-07-04 12:53 ` Ivo van Doorn
2008-07-04 14:14 ` [PATCH 4/4 v2] " Ivo van Doorn
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=200807041425.00591.IvDoorn@gmail.com \
--to=ivdoorn@gmail.com \
--cc=johannes@sipsolutions.net \
--cc=linux-wireless@vger.kernel.org \
--cc=linville@tuxdriver.com \
--cc=rt2400-devel@lists.sourceforge.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).