All of lore.kernel.org
 help / color / mirror / Atom feed
From: Richard Cochran <richardcochran@gmail.com>
To: netdev@vger.kernel.org
Cc: David Miller <davem@davemloft.net>,
	bruce.w.allan@intel.com, Jacob Keller <jacob.e.keller@intel.com>,
	Jeff Kirsher <jeffrey.t.kirsher@intel.com>,
	John Ronciak <john.ronciak@intel.com>,
	Matthew Vick <matthew.vick@intel.com>
Subject: Re: [PATCH net-next 3/4] igb: enable internal PPS for the i210.
Date: Wed, 19 Nov 2014 07:37:24 +0100	[thread overview]
Message-ID: <20141119063724.GB4109@localhost.localdomain> (raw)
In-Reply-To: <e5b4ef7c56119e2d86e42f5680b1b82c9ec1a38e.1416265321.git.richardcochran@gmail.com>

On Tue, Nov 18, 2014 at 12:06:24AM +0100, Richard Cochran wrote:
> --- a/drivers/net/ethernet/intel/igb/igb_main.c
> +++ b/drivers/net/ethernet/intel/igb/igb_main.c
> @@ -5386,8 +5386,14 @@ void igb_update_stats(struct igb_adapter *adapter,
>  static void igb_tsync_interrupt(struct igb_adapter *adapter)
>  {
>  	struct e1000_hw *hw = &adapter->hw;
> +	struct ptp_clock_event event;
>  	u32 tsicr = rd32(E1000_TSICR);
>  
> +	if (tsicr & TSINTR_SYS_WRAP) {
> +		event.type = PTP_CLOCK_PPS;
> +		ptp_clock_event(adapter->ptp_clock, &event);

This causes a BUG for the 82580. When you enable E1000_TSICR_TXTS, it
seems that TSINTR_SYS_WRAP is also automatically enabled. Because the
82580 variant has no pps device enabled, the driver then dereferences
a null pointer.

So we need to make the call to ptp_clock_event() conditional based on
whether pps is enabled. I'll fix this in V2.

> +	}
> +

Thanks,
Richard

  parent reply	other threads:[~2014-11-19  6:37 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-11-17 23:06 [PATCH net-next 0/4] igb: auxiliary PHC functions for the i210 Richard Cochran
2014-11-17 23:06 ` [PATCH net-next 1/4] igb: refactor time sync interrupt handling Richard Cochran
2014-11-17 23:06 ` [PATCH net-next 2/4] igb: do not clobber the TSAUXC bits on reset Richard Cochran
2014-11-17 23:22   ` Keller, Jacob E
2014-11-17 23:06 ` [PATCH net-next 3/4] igb: enable internal PPS for the i210 Richard Cochran
2014-11-17 23:24   ` Keller, Jacob E
2014-11-19  6:37   ` Richard Cochran [this message]
2014-11-19 19:32     ` Keller, Jacob E
2014-11-19 20:26       ` Richard Cochran
2014-11-19 21:06         ` Keller, Jacob E
2014-11-20  9:18           ` Richard Cochran
2014-11-20 21:28             ` Keller, Jacob E
2014-11-21  5:49               ` Richard Cochran
2014-11-17 23:06 ` [PATCH net-next 4/4] igb: enable auxiliary PHC functions " Richard Cochran
2014-11-17 23:28   ` Keller, Jacob E
2014-11-17 23:15 ` [PATCH net-next 0/4] igb: " Jeff Kirsher
2014-11-19  6:31   ` Richard Cochran
2014-11-19  8:43     ` Jeff Kirsher

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=20141119063724.GB4109@localhost.localdomain \
    --to=richardcochran@gmail.com \
    --cc=bruce.w.allan@intel.com \
    --cc=davem@davemloft.net \
    --cc=jacob.e.keller@intel.com \
    --cc=jeffrey.t.kirsher@intel.com \
    --cc=john.ronciak@intel.com \
    --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.