Hi...
We are using linux kernel 2.6.9 and mpc8540 as a network card in the host
x86.mpc8540 acts as a agent and runs on u-boot.
The steps that we followed to accomplish the above task is as follows:-
1.)Allocated memory using kmalloc and returned the ptrdata....
ptrdata = (unsigned long *) kmalloc( sizeof (unsigned long) , GFP_KERNEL);
2.)We write to pci outbound registers......
(a)pci translation register (b)pci base register (c) pci attribute register.
ulTemp = ( unsigned volatile long ) virt_to_bus( ( void * ) ptrdata);
ulTemp = swap(ulTemp >> 12) ;
//Outbound Translatiom Register
writel(ulTemp, (unsigned long)ioaddr+ 0x8C20);
//ioaddr is address that we got after remapping
ioaddr = ioremap_nocache((pio_start), pio_len);
//Outbound Base Address Register
writel((swap(0xE0000000 >> 12)) , (unsigned long)ioaddr+ 0x8C28);
//Outbound Attribute Register
writel(swap(0x8005501C), (unsigned long)ioaddr+ 0x8C30);
3.)We used the minicom to check whether we are able to access the host
memory from the agent by doing md 0xE000_0000.But we are getting all values as
zeroes.
Cud anybody solve our problem. tell us if we are missing anything,any
step.Please respond to our request.It is urgent.
Thanks
Aishwariya
---------------------------------
Expecting? Get great news right away with email Auto-Check.
Try the Yahoo! Mail Beta._______________________________________________
Linuxppc-embedded mailing list
[email protected]
https://ozlabs.org/mailman/listinfo/linuxppc-embedded