Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 3 Jun 2013 16:46:37 +0000 (UTC)
From:      Jung-uk Kim <jkim@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org
Subject:   svn commit: r251307 - stable/9/usr.sbin/acpi/acpidump
Message-ID:  <201306031646.r53GkbA0074211@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: jkim
Date: Mon Jun  3 16:46:37 2013
New Revision: 251307
URL: http://svnweb.freebsd.org/changeset/base/251307

Log:
  MFC:	r251186
  
  Fix a long standing logic bug introduced in r167814.  The code was added to
  get RSDP from loader(8) hint via kenv(2) but the bug nullified the new code
  and we always fell back to the previous method, i. e., sysctlbyname(3).

Modified:
  stable/9/usr.sbin/acpi/acpidump/acpi_user.c
Directory Properties:
  stable/9/usr.sbin/acpi/acpidump/   (props changed)

Modified: stable/9/usr.sbin/acpi/acpidump/acpi_user.c
==============================================================================
--- stable/9/usr.sbin/acpi/acpidump/acpi_user.c	Mon Jun  3 16:22:19 2013	(r251306)
+++ stable/9/usr.sbin/acpi/acpidump/acpi_user.c	Mon Jun  3 16:46:37 2013	(r251307)
@@ -172,7 +172,7 @@ acpi_find_rsd_ptr(void)
 	addr = 0;
 
 	/* Attempt to use kenv or sysctl to find RSD PTR record. */
-	if (kenv(KENV_GET, hint_acpi_0_rsdp, buf, 20) == 0)
+	if (kenv(KENV_GET, hint_acpi_0_rsdp, buf, 20) > 0)
 		addr = strtoul(buf, NULL, 0);
 	if (addr == 0) {
 		len = sizeof(addr);



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201306031646.r53GkbA0074211>