Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/arch/x86/x86 fix incorrect check in efi_getcfgtblhead().



details:   https://anonhg.NetBSD.org/src/rev/e8144dc0bc94
branches:  trunk
changeset: 347401:e8144dc0bc94
user:      nonaka <nonaka%NetBSD.org@localhost>
date:      Wed Aug 24 10:27:23 2016 +0000

description:
fix incorrect check in efi_getcfgtblhead().

diffstat:

 sys/arch/x86/x86/efi.c |  8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)

diffs (29 lines):

diff -r 833417740539 -r e8144dc0bc94 sys/arch/x86/x86/efi.c
--- a/sys/arch/x86/x86/efi.c    Wed Aug 24 10:04:53 2016 +0000
+++ b/sys/arch/x86/x86/efi.c    Wed Aug 24 10:27:23 2016 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: efi.c,v 1.3 2016/06/10 07:50:15 pgoyette Exp $ */
+/*     $NetBSD: efi.c,v 1.4 2016/08/24 10:27:23 nonaka Exp $   */
 /*-
  * Copyright (c) 2016 The NetBSD Foundation, Inc.
  * All rights reserved.
@@ -25,7 +25,7 @@
  * POSSIBILITY OF SUCH DAMAGE.
  */
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: efi.c,v 1.3 2016/06/10 07:50:15 pgoyette Exp $");
+__KERNEL_RCSID(0, "$NetBSD: efi.c,v 1.4 2016/08/24 10:27:23 nonaka Exp $");
 #include <sys/kmem.h>
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -147,8 +147,8 @@
        paddr_t pa;
        vaddr_t va;
 
-       if (efi_cfgtblhead_va == NULL)
-               return NULL;
+       if (efi_cfgtblhead_va != NULL)
+               return efi_cfgtblhead_va;
 
        pa = (paddr_t) efi_systbl_va->st_cfgtbl;
        aprint_debug("efi: cfgtbl at pa %" PRIxPADDR "\n", pa);



Home | Main Index | Thread Index | Old Index