tech-kern archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: Kernel code documentation and pci data structures (was: Problem with Intel WiFi card)
Hi :)!
> Sent: Thursday, May 18, 2017 at 9:29 PM
> From: "Taylor R Campbell" <campbell+netbsd-tech-kern%mumble.net@localhost>
> To: "Rocky Hotas" <rockyhotas%post.com@localhost>
> Cc: msaitoh%netbsd.org@localhost, tech-kern%netbsd.org@localhost
> Subject: Re: Kernel code documentation and pci data structures (was: Problem with Intel WiFi card)
>
> Wild guess: Doing
>
> extent_alloc(pa->pa_ioex, size, alignment, boundary, flags, &addr)
>
> in OpenBSD, where addr is an unsigned long, is like doing
>
> bus_space_alloc(pa->pa_iot, 0, -1, size, alignment, boundary, flags,
> &addr, NULL)
>
> in NetBSD, where addr is a bus_addr_t, and likewise with OpenBSD
> pa->pa_memex / NetBSD pa->pa_memt.
First of all, thank you for your answer and the "wild guess".
I remind you that the function called inside the OpenBSD
`ppb_alloc_resources' is `extent_alloc_subregion'. Maybe the NetBSD
`reg_start' and `reg_end' (type `bus_addr_t') can be equivalent of
OpenBSD `substart' and `subend' (type `ulong').
You are basically stating that in NetBSD the `extents' could be avoided,
achieving the same result? If so, remember that the OpenBSD
`struct pci_attach_args' has a member `pa_iot' too (surely
belonging to the initial NetBSD code), but it is not used in this case.
Bye!
Rocky
Home |
Main Index |
Thread Index |
Old Index