* Pran Joseph <[EMAIL PROTECTED]> [000825 00:11] wrote:
> Hi,
>
> I am trying to write a PCI ethernet driver for FreeBSD 3.4 release.
>
> I have some questions
>
> 1. How can I convert physical address to virtual address . What I want
> is to read the physical address from the device register and to copy it
> to host memory. From my earlier post I found that I can use vtopys
> macro to convert virtual to physical address. Now I want to do the
> reverse.
Um, I'm not sure what you mean here, a physical memory location can
be mapped vitually anywhere :), you have to keep track of the virtual
address somehow in your driver.
> 2. What are things should I do if I want the driver to work on alpha
> platform also.
Don't use i386 assumptions? example: use PAGE_SIZE rather than
hardcoding 4096, make sure you're using busdma rather than
hardcoding all your stuff.
Lastly buy and alpha. :)
--
-Alfred Perlstein - [[EMAIL PROTECTED]|[EMAIL PROTECTED]]
"I have the heart of a child; I keep it in a jar on my desk."
To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message