svn commit: r237326 - user/ae/bootcode/sys/boot/i386/libi386
Andrey V. Elsukov
ae at FreeBSD.org
Wed Jun 20 16:24:03 UTC 2012
Author: ae
Date: Wed Jun 20 16:24:02 2012
New Revision: 237326
URL: http://svn.freebsd.org/changeset/base/237326
Log:
Add bd_cleanup function.
Modified:
user/ae/bootcode/sys/boot/i386/libi386/biosdisk.c
Modified: user/ae/bootcode/sys/boot/i386/libi386/biosdisk.c
==============================================================================
--- user/ae/bootcode/sys/boot/i386/libi386/biosdisk.c Wed Jun 20 16:21:08 2012 (r237325)
+++ user/ae/bootcode/sys/boot/i386/libi386/biosdisk.c Wed Jun 20 16:24:02 2012 (r237326)
@@ -193,6 +193,19 @@ bd_init(void)
return(0);
}
+static void
+bd_cleanup(void)
+{
+ int i;
+
+ for (i = 0; i < nbdinfo; i++) {
+ if (bdinfo[i].bd_ptable != NULL) {
+ ptable_close(bdinfo[i].bd_ptable);
+ bdinfo[i].bd_ptable = NULL;
+ }
+ }
+}
+
/*
* Try to detect a device supported by the legacy int13 BIOS
*/
More information about the svn-src-user
mailing list