All of lore.kernel.org
 help / color / mirror / Atom feed
From: Richard Cochran <richardcochran@gmail.com>
To: Matthew Vick <matthew.vick@intel.com>
Cc: e1000-devel@lists.sourceforge.net, netdev@vger.kernel.org
Subject: igb: acknowledging time sync interrupts
Date: Sun, 26 May 2013 12:39:00 +0200	[thread overview]
Message-ID: <20130526103900.GA11682@netboy> (raw)

Matt,

In igb_main.c you have ISR code like:

	if (icr & E1000_ICR_TS) {
		u32 tsicr = rd32(E1000_TSICR);

		if (tsicr & E1000_TSICR_TXTS) {
			/* acknowledge the interrupt */
			wr32(E1000_TSICR, E1000_TSICR_TXTS);
			/* retrieve hardware timestamp */
			schedule_work(&adapter->ptp_tx_work);
		}
	}

In the datasheet for the 82580 and the i210, for TSICR it says,

   Note: Once ICR.Time_Sync is set, the internal value of this
         register should be cleared by writing 1b to all bits
         or cleared by a read to enable receiving an additional
         ^^^^^^^^^^^^^^^^^^^^
         ICR.Time_Sync interrupt.

and that implies that your write to acknowledge the interrupt is
superfluous, since you already read the TSICR.

Is this an error in the datasheets, or is the code doing extra,
unneeded work?

Thanks,
Richard

             reply	other threads:[~2013-05-26 10:39 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-05-26 10:39 Richard Cochran [this message]
2013-05-28 15:20 ` igb: acknowledging time sync interrupts Vick, Matthew
2013-05-28 16:06   ` Richard Cochran
2013-05-29 17:42     ` Vick, Matthew

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=20130526103900.GA11682@netboy \
    --to=richardcochran@gmail.com \
    --cc=e1000-devel@lists.sourceforge.net \
    --cc=matthew.vick@intel.com \
    --cc=netdev@vger.kernel.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.