On Tue, Apr 22, 2008 at 01:10:54PM +0800, 张世乐 wrote: > Thank you, Doctor Scott. I'm very grateful to you for you kindly help. > > I'll try the way you suggested soon. > > And, my code for light the led run as follows: > > void set_led_a_red(void) > { > /*PDIRC: 0xfc010d40*/ > /*PPARC: 0xfc010d44*/ > /*PODRC: 0xfc010d4c*/ > /*PDATC: 0xfc010d50*/ > *((unsigned long *)(0xfb010d40)) |= 0x000000d4; > *((unsigned long *)(0xfb010d44)) &= ~0x000000d4; > *((unsigned long *)(0xfb010d4c)) &= ~0x000000d4; > *((unsigned long *)(0xfb010d50)) |= 0x00000004; > *((unsigned long *)(0xfb010d50)) &= ~0x00000010; > }
Use out_be32(), and put a dcbf at the end. If the dcbf doesn't help, try not accessing any I/O until after the MMU is set up, and use a cache-inhibited BAT mapping. It's usually not between enabling caches and enabling the MMU that something goes wrong, but it is a rather annoying debug barrier. As for early debug output not working, another possibility besides the descriptor address is that ppc_md.probe is failing, or that your board file doesn't set ppc_md.progress to udbg_progress. -Scott _______________________________________________ Linuxppc-embedded mailing list Linuxppc-embedded@ozlabs.org https://ozlabs.org/mailman/listinfo/linuxppc-embedded