mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Richard Cochran <richardcochran@gmail.com>
To: Takahiro Shimizu <tshimizu818@gmail.com>
Cc: jeffrey.t.kirsher@intel.com, davem@davemloft.net,
	lucas.demarchi@profusion.mobi, mirq-linux@rere.qmqm.pl,
	paul.gortmaker@windriver.com, jdmason@kudzu.us,
	john.stultz@linaro.org, arnd@arndb.de, khc@pm.waw.pl,
	netdev@vger.kernel.org, linux-kernel@vger.kernel.org,
	qi.wang@intel.com, yong.y.wang@intel.com, joel.clark@intel.com,
	kok.howg.ewe@intel.com
Subject: Re: [PATCH RE-SUBMIT 2/2] net/pch_gbe: supports eg20t ptp clock
Date: Mon, 12 Mar 2012 07:17:02 +0100	[thread overview]
Message-ID: <20120312061702.GA1911@netboy.at.omicron.at> (raw)
In-Reply-To: <CAHBEfB8bAyGDAtP1O8OFoTw5GAs9C2Sht-idXiXUYkc7vWVSTQ@mail.gmail.com>

On Mon, Mar 12, 2012 at 09:35:44AM +0900, Takahiro Shimizu wrote:
> Hello Richard,
> 
> Thank you for the comment.
> 
> > +     if ((sk_run_filter(skb, ptp_filter) != PTP_CLASS_V2_IPV4) &&
> > > +             (sk_run_filter(skb, ptp_filter) != PTP_CLASS_V1_IPV4)) {
> >
> > No, just run the filter once and test the result twice.
> >
> > Also, doesn't the timestamping unit work with IPv6 and L2?  If so,
> > don't restrict the driver to IPv4.
> >
> >
> According to the EG20T spec, it support IPv6 too. But I did not any test
> about IPv6 now.
> Do you mean I don't restrict anything here?

No, what I mean is that you only accept PTP_CLASS_V1_IPV4 or
PTP_CLASS_V2_IPV4. You should accept any packet type supported by the
hardware.

If someone tries to use your driver with PTPv2 over UDPv6, for
example, then the filter will return PTP_CLASS_V2_IPV6, and the match
will fail. It will also fail for PTPv2 L2 and PTPv2 L2/VLAN.

It does not make sense to me to limit the driver in this way.

Richard



  parent reply	other threads:[~2012-03-12  6:17 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-03-08  8:16 [PATCH RE-SUBMIT 1/2] " Takahiro Shimizu
2012-03-08  8:16 ` [PATCH RE-SUBMIT 2/2] net/pch_gbe: " Takahiro Shimizu
2012-03-09 21:56   ` David Miller
2012-03-10 11:11   ` Richard Cochran
     [not found]     ` <CAHBEfB8bAyGDAtP1O8OFoTw5GAs9C2Sht-idXiXUYkc7vWVSTQ@mail.gmail.com>
2012-03-12  6:17       ` Richard Cochran [this message]
2012-03-09 21:56 ` [PATCH RE-SUBMIT 1/2] " David Miller
2012-03-10 11:02 ` Richard Cochran

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=20120312061702.GA1911@netboy.at.omicron.at \
    --to=richardcochran@gmail.com \
    --cc=arnd@arndb.de \
    --cc=davem@davemloft.net \
    --cc=jdmason@kudzu.us \
    --cc=jeffrey.t.kirsher@intel.com \
    --cc=joel.clark@intel.com \
    --cc=john.stultz@linaro.org \
    --cc=khc@pm.waw.pl \
    --cc=kok.howg.ewe@intel.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=lucas.demarchi@profusion.mobi \
    --cc=mirq-linux@rere.qmqm.pl \
    --cc=netdev@vger.kernel.org \
    --cc=paul.gortmaker@windriver.com \
    --cc=qi.wang@intel.com \
    --cc=tshimizu818@gmail.com \
    --cc=yong.y.wang@intel.com \
    /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

all inboxes | Powered by JetHome®