[coreboot] patch: fix USB ports on DBE62, and other cs5536-based platforms
Stefan Reinauer
stepan at coresystems.de
Wed Jun 4 19:32:56 CEST 2008
Marc Jones wrote:
> ron minnich wrote:
>
>> This change adds some debug prints, and a comment warning to dts on cs5536.
>>
>> Most importantly it fixes a simple programming error which made it so most of
>> the sets on the USB were not doing anything. The bug is also in V2.
>>
>>
>
>
>
>> /* the /sizeof(u32) is to convert byte offsets into u32 offsets */
>> #define HCCPARAMS (0x08/sizeof(u32))
>>
>
>
>
> I don't understand this change. This is standard MMIO. The memory mapped
> registers are defined 0h, 04h, 08h, 0Ah...
>
> You could
> *(bar + 08h) |= 1 << 9;
> or
> *(bar + 09h) |= 1 << 1;
>
Yes, this looks much saner...
on i945 i am using a couple of defines for accessing MMIO registers (in
this case the MCHBAR registers)
#define MCHBAR8(x) *((volatile u8 *)(DEFAULT_MCHBAR + x))
#define MCHBAR16(x) *((volatile u16 *)(DEFAULT_MCHBAR + x))
#define MCHBAR32(x) *((volatile u32 *)(DEFAULT_MCHBAR + x))
so you can write
MCHBAR8(DCC) |= (1<<1);
for maximum readablility
> Can you please explain?
>
--
coresystems GmbH • Brahmsstr. 16 • D-79104 Freiburg i. Br.
Tel.: +49 761 7668825 • Fax: +49 761 7664613
Email: info at coresystems.de • http://www.coresystems.de/
Registergericht: Amtsgericht Freiburg • HRB 7656
Geschäftsführer: Stefan Reinauer • Ust-IdNr.: DE245674866
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.coreboot.org/pipermail/coreboot/attachments/20080604/96c904d8/attachment.html>
More information about the coreboot
mailing list