Hi Mulyadi,<br><br><div class="gmail_quote">On Tue, Dec 21, 2010 at 9:59 AM, Mulyadi Santosa <span dir="ltr"><<a href="mailto:mulyadi.santosa@gmail.com" target="_blank">mulyadi.santosa@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
Hi Daniel.........<br>
<div><br>
On Tue, Dec 21, 2010 at 16:04, YOUNGWHAN SONG <<a href="mailto:breadncup@gmail.com" target="_blank">breadncup@gmail.com</a>> wrote:<br>
> test_foo = (struct foo*)regsva;<br>
<br>
</div>I was thinking differently, could it be that casting...as shown<br>
above...introduce this behaviour? what if you just point to the<br>
address...directly without any "container" such as struct foo?<br>
<div><br> </div></blockquote><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;"><div>
> printk(KERN_DBG "value TEST1: 0x%lx\n", readl(test_foo->TEST1));<br>
> printk(KERN_DBG "value 0: 0x%x\n", readw(&test_foo->a1[0]);<br>
> printk(KERN_DBG "value 1: 0x%x\n", readw(&test_foo->a1[1]);<br>
<br>
</div>in the above statement, it means "take the address of a1[0 and read<br>
some bytes from that address", right?<br>
<font color="#888888"><br>
--<br>
regards,<br>
<br>
Mulyadi Santosa<br>
Freelance Linux trainer and consultant<br>
<br>
blog: <a href="http://the-hydra.blogspot.com" target="_blank">the-hydra.blogspot.com</a><br>
training: <a href="http://mulyaditraining.blogspot.com" target="_blank">mulyaditraining.blogspot.com</a><br>
</font></blockquote></div><br>As we've talked, it looks the code would be ok, but I guess architecture doesn't handle the 16 bit address correctly. Our team will find a way to get through this by modifying the PCI module.<br>
<br>Thanks, Mulaydi for this post.<br><br>Have a great day.<br><br>Daniel<br>