cvs commit: src/sys/amd64/isa atpic.c src/sys/contrib/dev/oltr if_oltr.c src/sys/dev/aac aac_pci.c src/sys/dev/acpic

Nate Lawson nate at root.org
Mon Mar 22 12:06:18 PST 2004


On Mon, 22 Mar 2004, Bill Paul wrote:
> > The reason why we made this
> > change now is that API compatibility needs to be fixed before 5.3R.  I
> > MFCd the function itself to 4-STABLE, but it won't go into 5.2 or 5.2.1
> > due to the fact that only security changes are allowed there.
>
> I think you're missing the point. There are people with 5.2.1 CD kits --
> not just downloaded ISO images but actual physical CDs -- that don't have
> this API. You can't go out and change the contents of these CDs. I
> want to make it as painless as possible for people to just grab the
> existing NDISulator code and drop it into a 5.2.1 system, because the
> less trouble it is for them, the less trouble they make for me.

Yes, I know it doesn't work for CDs.  It also doesn't work for someone
running 4.9R (not 4-stable) if you produced a version for 4.x.

> Ok, just a minute. Do you want to:
>
> a) _Supplement_ bus_alloc_resource() with bus_alloc_resource_any()

Yes.

> Please be clear. Calling bus_alloc_resource_any() a "convenience function"
> implies that it's an addition to the API, which does not preclude me
> from using the older API routines if I really, really want to.

You can keep using whatever API you want.  I'd prefer you move to the
convenience function to keep in sync with the rest of the kernel.  The
goal is to keep things consistent when people cut/paste to build a new
driver.

> Please to be explaining why this isn't a macro:
>
> #define bus_alloc_resource_any(dev, type, rid, flags)	\
> 	bus_alloc_resource(dev, type, rid, 0ul, ~0ul, 1, flags)

We discussed using a macro or inline and imp@ preferred inline.

Again, it's a convenience function to codify the correct default values.
It would be nice if you added it back for 5.3R.  I just bumped FreeBSD
version (502109) so you can add an #if for compat with 5.2.1 and lower.
Or do nothing at all, whatever you prefer.

-Nate


More information about the cvs-src mailing list