Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 13 Jun 2010 07:50:50 +0000
From:      Navdeep Parhar <np@FreeBSD.org>
To:        Lawrence Stewart <lstewart@freebsd.org>
Cc:        svn-src-head@FreeBSD.org, svn-src-all@FreeBSD.org, src-committers@FreeBSD.org
Subject:   Re: svn commit: r209116 - head/sys/dev/cxgb
Message-ID:  <20100613075049.GA76297@hub.freebsd.org>
In-Reply-To: <4C146694.3000508@freebsd.org>
References:  <201006122233.o5CMX4Fc032367@svn.freebsd.org> <4C146694.3000508@freebsd.org>

next in thread | previous in thread | raw e-mail | index | archive | help
On Sun, Jun 13, 2010 at 03:03:16PM +1000, Lawrence Stewart wrote:
> Hi Navdeep,
> 
> On 06/13/10 08:33, Navdeep Parhar wrote:
> >Log:
> >   cxgb(4): add knob to get packet timestamps from the hardware.
> >
> >   The T3 ASIC can provide an incoming packet's timestamp instead of its 
> >   RSS hash.
> >   The timestamp is just a counter running off the card's clock.  With a 
> >   175MHz
> >   clock an increment represents ~5.7ns and the 32 bit value wraps around 
> >   in ~25s.
> >
> >   # sysctl -d dev.cxgbc.0.pkt_timestamp
> >   dev.cxgbc.0.pkt_timestamp: provide packet timestamp instead of 
> >   connection hash
> >
> >   # sysctl -d dev.cxgbc.0.core_clock
> >   dev.cxgbc.0.core_clock: core clock frequency (in KHz)
> >   # sysctl dev.cxgbc.0.core_clock
> >   dev.cxgbc.0.core_clock: 175000
> 
> Is this really a "one or the other" feature, or is it technically 
> possible to support both simultaneously at some point in the future if 
> additional work was done?
> 
> Just curious...

Both hash+timestamp will be supported in the future.  If the kernel is
going to grow the ability to let a NIC driver pass up a timestamp it
should allow both simultaneously.  This "one or the other" just happens
to be the way this particular generation of this particular chip does
it.

By the way, the packet is still hashed so RSS based load distribution
works even with timestamping enabled, just that the hash itself is not
provided.

Regards,
Navdeep



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20100613075049.GA76297>