diff options
author | njl <njl@FreeBSD.org> | 2003-07-13 22:45:34 +0000 |
---|---|---|
committer | njl <njl@FreeBSD.org> | 2003-07-13 22:45:34 +0000 |
commit | 935eed9d24bac0bfc2bee095035ca1cb7c6aee3b (patch) | |
tree | b38df159cd63b23f83795eb3b6fdb2b7f1d69e5f /sys/contrib/dev/acpica/tbget.c | |
parent | f668772b045b09705e4efd220d77bef71683290a (diff) | |
download | FreeBSD-src-935eed9d24bac0bfc2bee095035ca1cb7c6aee3b.zip FreeBSD-src-935eed9d24bac0bfc2bee095035ca1cb7c6aee3b.tar.gz |
Unmodified files from the vendor 0619 dist that should no longer be off the
vendor branch.
Diffstat (limited to 'sys/contrib/dev/acpica/tbget.c')
-rw-r--r-- | sys/contrib/dev/acpica/tbget.c | 17 |
1 files changed, 9 insertions, 8 deletions
diff --git a/sys/contrib/dev/acpica/tbget.c b/sys/contrib/dev/acpica/tbget.c index 9dc70b6..01fac0e 100644 --- a/sys/contrib/dev/acpica/tbget.c +++ b/sys/contrib/dev/acpica/tbget.c @@ -1,7 +1,7 @@ /****************************************************************************** * * Module Name: tbget - ACPI Table get* routines - * $Revision: 83 $ + * $Revision: 84 $ * *****************************************************************************/ @@ -547,18 +547,19 @@ AcpiTbGetTablePtr ( */ if (Instance == 1) { - /* - * Just pluck the pointer out of the global table! - * Will be null if no table is present - */ - *TablePtrLoc = AcpiGbl_AcpiTables[TableType].Pointer; + /* Get the first */ + + if (AcpiGbl_TableLists[TableType].Next) + { + *TablePtrLoc = AcpiGbl_TableLists[TableType].Next->Pointer; + } return_ACPI_STATUS (AE_OK); } /* * Check for instance out of range */ - if (Instance > AcpiGbl_AcpiTables[TableType].Count) + if (Instance > AcpiGbl_TableLists[TableType].Count) { return_ACPI_STATUS (AE_NOT_EXIST); } @@ -570,7 +571,7 @@ AcpiTbGetTablePtr ( * need to walk from the 2nd table until we reach the Instance * that the user is looking for and return its table pointer. */ - TableDesc = AcpiGbl_AcpiTables[TableType].Next; + TableDesc = AcpiGbl_TableLists[TableType].Next; for (i = 2; i < Instance; i++) { TableDesc = TableDesc->Next; |