Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 17 May 2010 15:58:50 -0700
From:      Oleksandr Tymoshenko <gonzo@bluezbox.com>
To:        Sam Leffler <sam@errno.com>
Cc:        freebsd-hackers@freebsd.org
Subject:   Re: hifn(4) DMA fix for review
Message-ID:  <ACFC9169-B235-4F4F-8501-1EAF307BE1BA@bluezbox.com>
In-Reply-To: <892C86B0-81B0-433D-BF9C-7CDBD479F6CC@errno.com>
References:  <4BE46650.7010008@bluezbox.com> <892C86B0-81B0-433D-BF9C-7CDBD479F6CC@errno.com>

next in thread | previous in thread | raw e-mail | index | archive | help

On 2010-05-10, at 8:23 AM, Sam Leffler wrote:

>=20
> On May 7, 2010, at 12:13 PM, Oleksandr Tymoshenko wrote:
>=20
>>   Proposed patch addresses hifn(4) problems on FreeBSD/mips. Current
>> implementation keeps some of the state information (indexes in
>> buffers, etc) in DMA-mapped memory and bus_dma code invalidates them
>> during sync operations. This fix moves data that doesn't belong to =
DMA
>> ring to softc structure.
>>=20
>> Patch: http://people.freebsd.org/~gonzo/hifn.diff
>> Stats for original driver:
>>   http://people.freebsd.org/~gonzo/hifn.stats.orig.txt
>> Stats for patched version:
>>   http://people.freebsd.org/~gonzo/hifn.stats.patched.txt
>>=20
>>=20
>=20
> The changes look fine and make sense (did something similar for some =
other drivers for when the dma data structures were mapped uncached).  I =
can't see any performance change in your stats; but I'm just eyeballing =
the numbers side-by-side.  Was this on x86? (where there should be zero =
difference)  It would be good to present these numbers better (e.g. =
curves on the same graph, ministat output, etc).


I took some time to learn gnuplot and here is result:

http://people.freebsd.org/~gonzo/hifn-cmp.png

The red ones are data from original driver, the blue ones are patched. =
There are some=20
fluctuations but I think they're OK. I made three measurements for =
original drivers and=20
there are fluctuations too with comparable order of magnitude:

http://people.freebsd.org/~gonzo/hifn-orig.png=20

If it's OK - I'll commit fixes

--=20
gonzo






Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?ACFC9169-B235-4F4F-8501-1EAF307BE1BA>