Re: Adpter card read old memory value
Arjan van de Ven (arjanv@redhat.com)
Tue, 1 Oct 2002 10:45:52 -0400
On Tue, Oct 01, 2002 at 05:44:07PM +0300, Eitan Ben-Nun wrote:
> ok thanks,
> An adapter card on the pci bus send a message to pc i386 Linux to update a memory address.
> Then it reads the address and sees an old value, even though the pc cpu have performed an update to this memory address. Here is referance to my driver code:
> int update_cluster_operation_mode(unsigned long new_mode,
> unsigned long phys_addr);
> {
> unsigned long* vir_addr = 0;
> vir_addr = __ioremap(phys_addr, PAGE_SIZE, _PAGE_PWT | _PAGE_PCD);
> *vir_addr = new_mode;
> return 0;
> }
> phys_addr - is always on page bonderies and the address is between 512M-640M.
this is only a part of the source, is there a full source available?
also your code is already buggy; you should use writel(); and also read up
on PCI posting....
Greetings,
Arjan van de Ven
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/