Source-Changes-HG archive

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

[src/trunk]: src/usr.sbin/acpitools/acpidump Don't print X_PM_TMR_BLK if the ...



details:   https://anonhg.NetBSD.org/src/rev/44b162b2188c
branches:  trunk
changeset: 445210:44b162b2188c
user:      msaitoh <msaitoh%NetBSD.org@localhost>
date:      Thu Oct 18 05:04:44 2018 +0000

description:
Don't print X_PM_TMR_BLK if the address value is 0.

diffstat:

 usr.sbin/acpitools/acpidump/acpi.c |  10 ++++++----
 1 files changed, 6 insertions(+), 4 deletions(-)

diffs (31 lines):

diff -r 51d3ef87f2f3 -r 44b162b2188c usr.sbin/acpitools/acpidump/acpi.c
--- a/usr.sbin/acpitools/acpidump/acpi.c        Thu Oct 18 04:52:00 2018 +0000
+++ b/usr.sbin/acpitools/acpidump/acpi.c        Thu Oct 18 05:04:44 2018 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: acpi.c,v 1.36 2018/10/18 04:52:00 msaitoh Exp $ */
+/* $NetBSD: acpi.c,v 1.37 2018/10/18 05:04:44 msaitoh Exp $ */
 
 /*-
  * Copyright (c) 1998 Doug Rabson
@@ -30,7 +30,7 @@
  */
 
 #include <sys/cdefs.h>
-__RCSID("$NetBSD: acpi.c,v 1.36 2018/10/18 04:52:00 msaitoh Exp $");
+__RCSID("$NetBSD: acpi.c,v 1.37 2018/10/18 05:04:44 msaitoh Exp $");
 
 #include <sys/param.h>
 #include <sys/endian.h>
@@ -3589,8 +3589,10 @@
                printf("\n\tX_PM2_CNT_BLK=");
                acpi_print_gas(&fadt->XPm2ControlBlock);
        }
-       printf("\n\tX_PM_TMR_BLK=");
-       acpi_print_gas(&fadt->XPmTimerBlock);
+       if (fadt->XPmTimerBlock.Address != 0) {
+               printf("\n\tX_PM_TMR_BLK=");
+               acpi_print_gas(&fadt->XPmTimerBlock);
+       }
        if (fadt->XGpe0Block.Address != 0) {
                printf("\n\tX_GPE0_BLK=");
                acpi_print_gas(&fadt->XGpe0Block);



Home | Main Index | Thread Index | Old Index