Source-Changes archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: CVS commit: src/sys/dev/ic
christianbiere%gmx.de@localhostさん wrote:
> On ARM (at least with GCC) sizeof (struct example) won't be 2.
In your example it requires packed.
In re(4) case it doesn't (currently) so we don't bother to add it.
That's all.
> > The offsets of descriptor members are specified by hardware design
> > of bus-master, so you can't pad it.
>
> I'm not sure how you mean that.
The busmaster reads host's memory via DMA.
The read addresses are spcified by busmaster hardware.
The structure is used to represent the offsets.
On some hardware, such offsets or addresses could be programmed,
but it could not on others.
> Since this struct rtx_desc is not
> used in many places and you need endian-conversion anyway, I would
> suggest using accessor functions instead of this struct.
I can't see any benefits by using such functions.
---
Izumi Tsutsui
Home |
Main Index |
Thread Index |
Old Index