Date: Sat, 24 Sep 2005 19:31:10 +0000 (UTC) From: Poul-Henning Kamp <phk@FreeBSD.org> To: src-committers@FreeBSD.org, cvs-src@FreeBSD.org, cvs-all@FreeBSD.org Subject: cvs commit: src/sys/sys bus.h rman.h types.h src/sys/kern subr_bus.c Message-ID: <200509241931.j8OJVAwm013470@repoman.freebsd.org>
next in thread | raw e-mail | index | archive | help
phk 2005-09-24 19:31:10 UTC FreeBSD src repository Modified files: sys/sys bus.h rman.h types.h sys/kern subr_bus.c Log: Add two convenience functions for device drivers: bus_alloc_resources() and bus_free_resources(). These functions take a list of resources and handle them all in one go. A flag makes it possible to mark a resource as optional. A typical device driver can save 10-30 lines of code by using these. Usage examples will follow RSN. MFC: A good idea, eventually. Revision Changes Path 1.186 +31 -0 src/sys/kern/subr_bus.c 1.72 +10 -5 src/sys/sys/bus.h 1.28 +1 -0 src/sys/sys/rman.h 1.93 +1 -0 src/sys/sys/types.h
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200509241931.j8OJVAwm013470>