Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

if_iy's use of bus_space_write_{_multi)_2

1 view
Skip to first unread message

Ignatios Souvatzis

unread,
Jul 20, 2000, 3:00:00 AM7/20/00
to
Hello,

my own driver (sys/dev/isa/if_iy.c) looks fishy to me.

When writing network packet data, and the multicast setup stuff, shouldn't
I use the _stream_ version of said access methods? (see functions
iy_mc_setup, iystart, and iyget)

The funny thing is that it works on a little-endian (i386) machine...

Regards,
Ignatios

Jason R Thorpe

unread,
Jul 20, 2000, 3:00:00 AM7/20/00
to
On Thu, Jul 20, 2000 at 05:16:27PM +0200, Ignatios Souvatzis wrote:

> When writing network packet data, and the multicast setup stuff, shouldn't
> I use the _stream_ version of said access methods? (see functions
> iy_mc_setup, iystart, and iyget)

Yes, you should.

> The funny thing is that it works on a little-endian (i386) machine...

Of course it does; the chip is Intel, and thus little-endian (no swapping
necessary).

--
-- Jason R. Thorpe <tho...@zembu.com>

Manuel Bouyer

unread,
Jul 20, 2000, 3:00:00 AM7/20/00
to
On Thu, Jul 20, 2000 at 05:16:27PM +0200, Ignatios Souvatzis wrote:
> Hello,
>
> my own driver (sys/dev/isa/if_iy.c) looks fishy to me.
>
> When writing network packet data, and the multicast setup stuff, shouldn't
> I use the _stream_ version of said access methods? (see functions
> iy_mc_setup, iystart, and iyget)

I think this would be correct, yes.

>
> The funny thing is that it works on a little-endian (i386) machine...

i386 and ISA are both little endian, so the _strean_ and non _stream_ versions
are identical. You would have problems on big-endian boxes.

--
Manuel Bouyer <bou...@antioche.eu.org>
--

David Brownlee

unread,
Jul 20, 2000, 3:00:00 AM7/20/00
to
Didn't Jason mention he once thought about providing a debugging
bus_space implementation that would bounce everything on i386
and pick up various programming errors. Would it be possible
to catch this as well in such a hypothetical set of code? :)

David/absolute
-- www.netbsd.org: A pmap for every occasion --

Jason R Thorpe

unread,
Jul 21, 2000, 3:00:00 AM7/21/00
to
On Fri, Jul 21, 2000 at 12:41:41AM +0100, David Brownlee wrote:

> Didn't Jason mention he once thought about providing a debugging
> bus_space implementation that would bounce everything on i386
> and pick up various programming errors. Would it be possible
> to catch this as well in such a hypothetical set of code? :)

That would be bus_dma, so that people could use PCs to debug
more interesting architectures (e.g. cache coherency issues).

0 new messages