RE: Okay, I give up. How *do* you use ioremap()?

Ingo Molnar (mingo@chiara.csoma.elte.hu)
Sun, 14 Nov 1999 22:49:10 +0100 (CET)


On Sun, 14 Nov 1999, Ingles, Raymond wrote:

> >> info->mem_base = ioremap(info->reg_base,
> >> JS_PCI_VORTEX_MEM_SIZE);
> >> regval = readl(info->mem_base +
> >> JS_PCI_VORTEX2_LEGACY_CR);
>
> >> joy-pci: reg_base 1: de000000
> >> joy-pci: using reg_base of de000000
> >> joy-pci: ioremapped, mem_base is c806b000
> >> Unable to handle kernel paging request at virtual address c8113030
>
> >it looks like as if JS_PCI_VORTEX2_LEGACY_CR is overflowing above the
> >mapped area. Is JS_PCI_VORTEX_MEM_SIZE big enough, and is
> >JS_PCI_VORTEX2_LEGACY_CR correct?
>
> You know, that's actually weird. MEM_SIZE is 0x40000 (262144 bytes),
> and LEGACY_CR is 0x2a00c. So that shouldn't be a problem. But where on

(Maybe mem_base is not 'char *' and the pointer aritmetics lead to a
bigger address than intended?)

-- mingo

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/