On Mon, 2004-10-11 at 19:44, Lothar Wassmann wrote:
> > 2) I now know the meaning of Fld, FExtrt etc. but these are defined in
> > header file "bitfield.h", which is only available for certain arm-based
> > archs. You use them to create a proper PTD structure. This was one of my
> > problems (creating a proper PTD), and I really like your way, but I
> > cannot use it on an i386 arch. Now apart from that, this is a very
> > platform-specific solution, so we should really come up with a more
> > general way of doing it. Any ideas? (or opinions as to why my
> > assumptions are wrong. I really am new to all of this, so I might be
> > missing something...)
> > 
> These are generic macros that could be used on any platform. Why they
> are located in include/asm-arm/arch-pxa/ I don't know. But we could
> achieve the same without using those macros.
> 
OK, that's good news, but I have the same problem with asm/hardware.h
asm/mach-types.h and asm/arch/dma.h . This whole thing is very
arm-specific... So in my i386 platform, it doesn't compile. Anyway, I
guess I don't need things like mach-types, so we should #ifdef their use
maybe? And if you agree, what is the best #define statement that we
should use to check?

> > 4) What about REG_ACCESS_[R,W,RW,M,MASK]? Why do you need all these? And
> > although I've not checked all your code with detail, I can see that you
> > only use them when debugging. I'm particularly intrigued with M and
> > MASK...
> > 
> I introduced them to trap illegal register accesses like writing a
> read-only register or accessing a 16bit register with a 32bit access.
> Furthermore there are some registers in the chip that implement only
> part of the bits from the OHCI spec. The remaining bits are stored in
> a shadow copy of the register and maintained by the driver. The 'M'
> bit tells the register functions that a merge of the value from the HW
> register with the shadow copy is required.
> 
Perfectly understood, except the 'MASK'. I mean it even has the same
number (0x600) as 'RW'... And while RW is R+W masks together, why have
the same thing with another name?

Thanks,
Dimitris

Attachment: signature.asc
Description: This is a digitally signed message part

Reply via email to