On 08-May-00 Coleman Kane wrote:
> the memory region mapped by the PCI BIOS (in this case the 0x1000000 region
> between 0xec000000 and 0xecffffff), or an address of a mapped region within
> kernel memory area? I had it return the former and it crashed the machine,
> trying to use bus_alloc_resource(...) with the SYS_RES_MEMORY parameter just
> won't map any memory
The return type is the errno for the mmap() call..
You need to inform the VM systems about it.
The meat of your mmap call should be ->
return(i386_btop(vtophys(rman_get_virtual(sc->g_membase.reshandle)) +
offset));
rman_get_virtual() gets the kernel virtual address out of the memeory handle,
vtophys turns it into a physical address (hmm.. come to think of it I could
probably replace those two with rman_get_start), and i386_btop does, err, magic
:)
---
Daniel O'Connor software and network engineer
for Genesis Software - http://www.gsoft.com.au
"The nice thing about standards is that there
are so many of them to choose from."
-- Andrew Tanenbaum
To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message