From 01558f7ee2e9d8b44c125793dc0850dccf030190 Mon Sep 17 00:00:00 2001 From: mycroft Date: Mon, 3 Nov 2003 17:24:22 +0000 Subject: [PATCH] Clean up some messages: * Use AcpiFormatException() in a bunch of places. * acpi_resource_parse() already prints an error, so don't do it in the callers. --- sys/dev/acpi/acpi.c | 25 ++++++++++++++----------- sys/dev/acpi/acpi_acad.c | 16 ++++++++-------- sys/dev/acpi/acpi_bat.c | 33 +++++++++++++++++---------------- sys/dev/acpi/acpi_button.c | 11 ++++++----- sys/dev/acpi/acpi_lid.c | 11 ++++++----- sys/dev/acpi/acpi_resource.c | 8 ++++---- sys/dev/acpi/acpi_tz.c | 18 +++++++++--------- sys/dev/acpi/com_acpi.c | 8 +++----- sys/dev/acpi/fdc_acpi.c | 16 +++++++--------- sys/dev/acpi/lpt_acpi.c | 8 +++----- sys/dev/acpi/pckbc_acpi.c | 8 +++----- sys/dev/acpi/wss_acpi.c | 9 +++------ 12 files changed, 83 insertions(+), 88 deletions(-) diff --git a/sys/dev/acpi/acpi.c b/sys/dev/acpi/acpi.c index 51994a5f1c24..e44eb41cfdd4 100644 --- a/sys/dev/acpi/acpi.c +++ b/sys/dev/acpi/acpi.c @@ -1,4 +1,4 @@ -/* $NetBSD: acpi.c,v 1.54 2003/11/03 06:03:47 kochi Exp $ */ +/* $NetBSD: acpi.c,v 1.55 2003/11/03 17:24:22 mycroft Exp $ */ /*- * Copyright (c) 2003 The NetBSD Foundation, Inc. @@ -77,7 +77,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: acpi.c,v 1.54 2003/11/03 06:03:47 kochi Exp $"); +__KERNEL_RCSID(0, "$NetBSD: acpi.c,v 1.55 2003/11/03 17:24:22 mycroft Exp $"); #include "opt_acpi.h" @@ -192,7 +192,8 @@ acpi_probe(void) rv = AcpiInitializeSubsystem(); if (rv != AE_OK) { - printf("ACPI: unable to initialize ACPICA: %d\n", rv); + printf("ACPI: unable to initialize ACPICA: %s\n", + AcpiFormatException(rv)); return (0); } @@ -203,7 +204,8 @@ acpi_probe(void) rv = AcpiLoadTables(); if (rv != AE_OK) { - printf("ACPI: unable to load tables: %d\n", rv); + printf("ACPI: unable to load tables: %s\n", + AcpiFormatException(rv)); return (0); } @@ -287,14 +289,14 @@ acpi_attach(struct device *parent, struct device *self, void *aux) rv = AcpiEnableSubsystem(0); if (rv != AE_OK) { - printf("%s: unable to enable ACPI: %d\n", - sc->sc_dev.dv_xname, rv); + printf("%s: unable to enable ACPI: %s\n", + sc->sc_dev.dv_xname, AcpiFormatException(rv)); return; } rv = AcpiInitializeObjects(0); if (rv != AE_OK) { - printf("%s: unable to initialize ACPI objects: %d\n", - sc->sc_dev.dv_xname, rv); + printf("%s: unable to initialize ACPI objects: %s\n", + sc->sc_dev.dv_xname, AcpiFormatException(rv)); return; } acpi_active = 1; @@ -533,8 +535,8 @@ acpi_make_devnode(ACPI_HANDLE handle, UINT32 level, void *context, rv = AcpiGetObjectInfo(handle, &buf); if (rv != AE_OK) { #ifdef ACPI_DEBUG - printf("%s: AcpiGetObjectInfo failed\n", - sc->sc_dev.dv_xname); + printf("%s: AcpiGetObjectInfo failed: %s\n", + sc->sc_dev.dv_xname, AcpiFormatException(rv)); #endif goto out; /* XXX why return OK */ } @@ -739,7 +741,8 @@ acpi_fixed_button_handler(void *context) acpi_fixed_button_pressed, smpsw); if (rv != AE_OK) printf("%s: WARNING: unable to queue fixed button pressed " - "callback: %d\n", smpsw->smpsw_name, rv); + "callback: %s\n", smpsw->smpsw_name, + AcpiFormatException(rv)); return (ACPI_INTERRUPT_HANDLED); } diff --git a/sys/dev/acpi/acpi_acad.c b/sys/dev/acpi/acpi_acad.c index 4c83cde3f011..f3557b476d06 100644 --- a/sys/dev/acpi/acpi_acad.c +++ b/sys/dev/acpi/acpi_acad.c @@ -1,4 +1,4 @@ -/* $NetBSD: acpi_acad.c,v 1.10 2003/11/03 06:03:47 kochi Exp $ */ +/* $NetBSD: acpi_acad.c,v 1.11 2003/11/03 17:24:22 mycroft Exp $ */ /* * Copyright 2001 Wasabi Systems, Inc. @@ -44,7 +44,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: acpi_acad.c,v 1.10 2003/11/03 06:03:47 kochi Exp $"); +__KERNEL_RCSID(0, "$NetBSD: acpi_acad.c,v 1.11 2003/11/03 17:24:22 mycroft Exp $"); #include #include @@ -166,8 +166,8 @@ acpiacad_attach(struct device *parent, struct device *self, void *aux) rv = AcpiInstallNotifyHandler(sc->sc_node->ad_handle, ACPI_DEVICE_NOTIFY, acpiacad_notify_handler, sc); if (rv != AE_OK) { - printf("%s: unable to register DEVICE NOTIFY handler: %d\n", - sc->sc_dev.dv_xname, rv); + printf("%s: unable to register DEVICE NOTIFY handler: %s\n", + sc->sc_dev.dv_xname, AcpiFormatException(rv)); return; } @@ -175,8 +175,8 @@ acpiacad_attach(struct device *parent, struct device *self, void *aux) rv = AcpiInstallNotifyHandler(sc->sc_node->ad_handle, ACPI_SYSTEM_NOTIFY, acpiacad_notify_handler, sc); if (rv != AE_OK) { - printf("%s: unable to register SYSTEM NOTIFY handler: %d\n", - sc->sc_dev.dv_xname, rv); + printf("%s: unable to register SYSTEM NOTIFY handler: %s\n", + sc->sc_dev.dv_xname, AcpiFormatException(rv)); return; } @@ -257,8 +257,8 @@ acpiacad_notify_handler(ACPI_HANDLE handle, UINT32 notify, void *context) rv = AcpiOsQueueForExecution(OSD_PRIORITY_LO, acpiacad_get_status, sc); if (rv != AE_OK) - printf("%s: unable to queue status check: %d\n", - sc->sc_dev.dv_xname, rv); + printf("%s: unable to queue status check: %s\n", + sc->sc_dev.dv_xname, AcpiFormatException(rv)); break; default: diff --git a/sys/dev/acpi/acpi_bat.c b/sys/dev/acpi/acpi_bat.c index e1f482bc7c83..5cc192275bdc 100644 --- a/sys/dev/acpi/acpi_bat.c +++ b/sys/dev/acpi/acpi_bat.c @@ -1,4 +1,4 @@ -/* $NetBSD: acpi_bat.c,v 1.33 2003/11/03 06:03:47 kochi Exp $ */ +/* $NetBSD: acpi_bat.c,v 1.34 2003/11/03 17:24:22 mycroft Exp $ */ /*- * Copyright (c) 2003 The NetBSD Foundation, Inc. @@ -86,7 +86,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: acpi_bat.c,v 1.33 2003/11/03 06:03:47 kochi Exp $"); +__KERNEL_RCSID(0, "$NetBSD: acpi_bat.c,v 1.34 2003/11/03 17:24:22 mycroft Exp $"); #include #include @@ -271,8 +271,8 @@ acpibat_attach(struct device *parent, struct device *self, void *aux) ACPI_DEVICE_NOTIFY, acpibat_notify_handler, sc); if (rv != AE_OK) { - printf("%s: unable to register DEVICE NOTIFY handler: %d\n", - sc->sc_dev.dv_xname, rv); + printf("%s: unable to register DEVICE NOTIFY handler: %s\n", + sc->sc_dev.dv_xname, AcpiFormatException(rv)); return; } @@ -281,8 +281,8 @@ acpibat_attach(struct device *parent, struct device *self, void *aux) ACPI_SYSTEM_NOTIFY, acpibat_notify_handler, sc); if (rv != AE_OK) { - printf("%s: unable to register SYSTEM NOTIFY handler: %d\n", - sc->sc_dev.dv_xname, rv); + printf("%s: unable to register SYSTEM NOTIFY handler: %s\n", + sc->sc_dev.dv_xname, AcpiFormatException(rv)); return; } @@ -356,8 +356,8 @@ acpibat_battery_present(struct acpibat_softc *sc) rv = acpi_eval_integer(sc->sc_node->ad_handle, "_STA", &val); if (rv != AE_OK) { - printf("%s: failed to evaluate _STA: %x\n", - sc->sc_dev.dv_xname, rv); + printf("%s: failed to evaluate _STA: %s\n", + sc->sc_dev.dv_xname, AcpiFormatException(rv)); return (-1); } @@ -392,8 +392,8 @@ acpibat_get_info(struct acpibat_softc *sc) rv = acpi_eval_struct(sc->sc_node->ad_handle, "_BIF", &buf); if (rv != AE_OK) { - printf("%s: failed to evaluate _BIF: 0x%x\n", - sc->sc_dev.dv_xname, rv); + printf("%s: failed to evaluate _BIF: %s\n", + sc->sc_dev.dv_xname, AcpiFormatException(rv)); return (rv); } p1 = (ACPI_OBJECT *)buf.Pointer; @@ -482,7 +482,8 @@ acpibat_get_status(struct acpibat_softc *sc) rv = acpi_eval_struct(sc->sc_node->ad_handle, "_BST", &buf); if (rv != AE_OK) { - printf("bat: failed to evaluate _BST: 0x%x\n", rv); + printf("%s: failed to evaluate _BST: %s\n", + sc->sc_dev.dv_xname, AcpiFormatException(rv)); return (rv); } p1 = (ACPI_OBJECT *)buf.Pointer; @@ -552,7 +553,7 @@ acpibat_print_info(struct acpibat_softc *sc) else tech = "primary"; - printf("%s: %s battery, Design %d.%03d%s, Predicted %d.%03d%s" + printf("%s: %s battery, Design %d.%03d%s, Last full %d.%03d%s" "Warn %d.%03d%s Low %d.%03d%s\n", sc->sc_dev.dv_xname, tech, SCALE(sc->sc_data[ACPIBAT_DCAPACITY].cur.data_s), CAPUNITS(sc), @@ -677,8 +678,8 @@ acpibat_notify_handler(ACPI_HANDLE handle, UINT32 notify, void *context) rv = AcpiOsQueueForExecution(OSD_PRIORITY_LO, acpibat_update, sc); if (rv != AE_OK) - printf("%s: unable to queue status check: %d\n", - sc->sc_dev.dv_xname, rv); + printf("%s: unable to queue status check: %s\n", + sc->sc_dev.dv_xname, AcpiFormatException(rv)); break; case ACPI_NOTIFY_BatteryStatusChanged: @@ -688,8 +689,8 @@ acpibat_notify_handler(ACPI_HANDLE handle, UINT32 notify, void *context) rv = AcpiOsQueueForExecution(OSD_PRIORITY_LO, acpibat_update, sc); if (rv != AE_OK) - printf("%s: unable to queue status check: %d\n", - sc->sc_dev.dv_xname, rv); + printf("%s: unable to queue status check: %s\n", + sc->sc_dev.dv_xname, AcpiFormatException(rv)); break; default: diff --git a/sys/dev/acpi/acpi_button.c b/sys/dev/acpi/acpi_button.c index a943a3375547..77556a2dee8d 100644 --- a/sys/dev/acpi/acpi_button.c +++ b/sys/dev/acpi/acpi_button.c @@ -1,4 +1,4 @@ -/* $NetBSD: acpi_button.c,v 1.11 2003/11/03 06:03:47 kochi Exp $ */ +/* $NetBSD: acpi_button.c,v 1.12 2003/11/03 17:24:22 mycroft Exp $ */ /* * Copyright 2001, 2003 Wasabi Systems, Inc. @@ -40,7 +40,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: acpi_button.c,v 1.11 2003/11/03 06:03:47 kochi Exp $"); +__KERNEL_RCSID(0, "$NetBSD: acpi_button.c,v 1.12 2003/11/03 17:24:22 mycroft Exp $"); #include #include @@ -131,8 +131,8 @@ acpibut_attach(struct device *parent, struct device *self, void *aux) rv = AcpiInstallNotifyHandler(sc->sc_node->ad_handle, ACPI_DEVICE_NOTIFY, acpibut_notify_handler, sc); if (rv != AE_OK) { - printf("%s: unable to register device notify handler: %d\n", - sc->sc_dev.dv_xname, rv); + printf("%s: unable to register DEVICE NOTIFY handler: %s\n", + sc->sc_dev.dv_xname, AcpiFormatException(rv)); return; } @@ -182,7 +182,8 @@ acpibut_notify_handler(ACPI_HANDLE handle, UINT32 notify, void *context) acpibut_pressed_event, sc); if (rv != AE_OK) printf("%s: WARNING: unable to queue button pressed " - "callback: %d\n", sc->sc_dev.dv_xname, rv); + "callback: %s\n", sc->sc_dev.dv_xname, + AcpiFormatException(rv)); break; /* XXX ACPI_NOTIFY_DeviceWake?? */ diff --git a/sys/dev/acpi/acpi_lid.c b/sys/dev/acpi/acpi_lid.c index fe4da148a440..8faaf9f8b63c 100644 --- a/sys/dev/acpi/acpi_lid.c +++ b/sys/dev/acpi/acpi_lid.c @@ -1,4 +1,4 @@ -/* $NetBSD: acpi_lid.c,v 1.10 2003/11/03 06:03:47 kochi Exp $ */ +/* $NetBSD: acpi_lid.c,v 1.11 2003/11/03 17:24:22 mycroft Exp $ */ /* * Copyright 2001, 2003 Wasabi Systems, Inc. @@ -40,7 +40,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: acpi_lid.c,v 1.10 2003/11/03 06:03:47 kochi Exp $"); +__KERNEL_RCSID(0, "$NetBSD: acpi_lid.c,v 1.11 2003/11/03 17:24:22 mycroft Exp $"); #include #include @@ -115,8 +115,8 @@ acpilid_attach(struct device *parent, struct device *self, void *aux) rv = AcpiInstallNotifyHandler(sc->sc_node->ad_handle, ACPI_DEVICE_NOTIFY, acpilid_notify_handler, sc); if (rv != AE_OK) { - printf("%s: unable to register device notify handler: %d\n", - sc->sc_dev.dv_xname, rv); + printf("%s: unable to register DEVICE NOTIFY handler: %s\n", + sc->sc_dev.dv_xname, AcpiFormatException(rv)); return; } } @@ -161,7 +161,8 @@ acpilid_notify_handler(ACPI_HANDLE handle, UINT32 notify, void *context) acpilid_status_changed, sc); if (rv != AE_OK) printf("%s: WARNING: unable to queue lid change " - "event: %d\n", sc->sc_dev.dv_xname, rv); + "callback: %s\n", sc->sc_dev.dv_xname, + AcpiFormatException(rv)); break; default: diff --git a/sys/dev/acpi/acpi_resource.c b/sys/dev/acpi/acpi_resource.c index 89fc026c3a0f..28e48df0687d 100644 --- a/sys/dev/acpi/acpi_resource.c +++ b/sys/dev/acpi/acpi_resource.c @@ -1,4 +1,4 @@ -/* $NetBSD: acpi_resource.c,v 1.7 2003/11/02 11:12:53 jdolecek Exp $ */ +/* $NetBSD: acpi_resource.c,v 1.8 2003/11/03 17:24:22 mycroft Exp $ */ /* * Copyright 2001 Wasabi Systems, Inc. @@ -67,7 +67,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: acpi_resource.c,v 1.7 2003/11/02 11:12:53 jdolecek Exp $"); +__KERNEL_RCSID(0, "$NetBSD: acpi_resource.c,v 1.8 2003/11/03 17:24:22 mycroft Exp $"); #include #include @@ -110,8 +110,8 @@ acpi_resource_parse(struct device *dev, struct acpi_devnode *ad, status = acpi_get(ad->ad_handle, &buf, AcpiGetCurrentResources); if (status != AE_OK) { - printf("%s: ACPI: unable to get Current Resources: %d\n", - dev->dv_xname, status); + printf("%s: ACPI: unable to get Current Resources: %s\n", + dev->dv_xname, AcpiFormatException(status)); return_ACPI_STATUS(status); } diff --git a/sys/dev/acpi/acpi_tz.c b/sys/dev/acpi/acpi_tz.c index f30a5f025cfa..1d70ff366cdd 100644 --- a/sys/dev/acpi/acpi_tz.c +++ b/sys/dev/acpi/acpi_tz.c @@ -1,4 +1,4 @@ -/* $NetBSD: acpi_tz.c,v 1.4 2003/10/31 21:52:11 mycroft Exp $ */ +/* $NetBSD: acpi_tz.c,v 1.5 2003/11/03 17:24:22 mycroft Exp $ */ /* * Copyright (c) 2003 Jared D. McNeill @@ -30,7 +30,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: acpi_tz.c,v 1.4 2003/10/31 21:52:11 mycroft Exp $"); +__KERNEL_RCSID(0, "$NetBSD: acpi_tz.c,v 1.5 2003/11/03 17:24:22 mycroft Exp $"); #include #include @@ -171,8 +171,8 @@ acpitz_attach(struct device *parent, struct device *self, void *aux) rv = AcpiInstallNotifyHandler(sc->sc_devnode->ad_handle, ACPI_SYSTEM_NOTIFY, acpitz_notify_handler, sc); if (rv != AE_OK) { - printf("%s: unable to install system notify handler\n", - sc->sc_dev.dv_xname); + printf("%s: unable to install SYSTEM NOTIFY handler: %s\n", + sc->sc_dev.dv_xname, AcpiFormatException(rv)); return; } @@ -192,8 +192,8 @@ acpitz_get_status(void *opaque) rv = acpi_eval_integer(sc->sc_devnode->ad_handle, "_TMP", &sc->sc_zone.tmp); if (rv != AE_OK) { - printf("%s: failed to evaluate _TMP: 0x%x\n", - sc->sc_dev.dv_xname, rv); + printf("%s: failed to evaluate _TMP: %s\n", + sc->sc_dev.dv_xname, AcpiFormatException(rv)); return; } @@ -228,12 +228,12 @@ acpitz_notify_handler(ACPI_HANDLE hdl, UINT32 notify, void *opaque) rv = AcpiOsQueueForExecution(OSD_PRIORITY_LO, acpitz_get_status, sc); if (rv != AE_OK) { - printf("%s: unable to queue status check\n", - sc->sc_dev.dv_xname); + printf("%s: unable to queue status check: %s\n", + sc->sc_dev.dv_xname, AcpiFormatException(rv)); } break; default: - printf("%s: received unhandled notify message %d\n", + printf("%s: received unhandled notify message 0x%x\n", sc->sc_dev.dv_xname, notify); break; } diff --git a/sys/dev/acpi/com_acpi.c b/sys/dev/acpi/com_acpi.c index c8d70b6a304d..0d1e12b9670e 100644 --- a/sys/dev/acpi/com_acpi.c +++ b/sys/dev/acpi/com_acpi.c @@ -1,4 +1,4 @@ -/* $NetBSD: com_acpi.c,v 1.9 2003/11/03 06:03:47 kochi Exp $ */ +/* $NetBSD: com_acpi.c,v 1.10 2003/11/03 17:24:22 mycroft Exp $ */ /* * Copyright (c) 2002 Jared D. McNeill @@ -26,7 +26,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: com_acpi.c,v 1.9 2003/11/03 06:03:47 kochi Exp $"); +__KERNEL_RCSID(0, "$NetBSD: com_acpi.c,v 1.10 2003/11/03 17:24:22 mycroft Exp $"); #include #include @@ -105,10 +105,8 @@ com_acpi_attach(struct device *parent, struct device *self, void *aux) /* parse resources */ rv = acpi_resource_parse(&sc->sc_dev, aa->aa_node, &res, &acpi_resource_parse_ops_default); - if (rv != AE_OK) { - printf("%s: unable to parse resources\n", sc->sc_dev.dv_xname); + if (rv != AE_OK) return; - } /* find our i/o registers */ io = acpi_res_io(&res, 0); diff --git a/sys/dev/acpi/fdc_acpi.c b/sys/dev/acpi/fdc_acpi.c index 1b09f835e144..e1f31d4eb3a6 100644 --- a/sys/dev/acpi/fdc_acpi.c +++ b/sys/dev/acpi/fdc_acpi.c @@ -1,4 +1,4 @@ -/* $NetBSD: fdc_acpi.c,v 1.15 2003/11/03 06:03:47 kochi Exp $ */ +/* $NetBSD: fdc_acpi.c,v 1.16 2003/11/03 17:24:22 mycroft Exp $ */ /* * Copyright (c) 2002 Jared D. McNeill @@ -31,7 +31,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: fdc_acpi.c,v 1.15 2003/11/03 06:03:47 kochi Exp $"); +__KERNEL_RCSID(0, "$NetBSD: fdc_acpi.c,v 1.16 2003/11/03 17:24:22 mycroft Exp $"); #include "rnd.h" @@ -128,10 +128,8 @@ fdc_acpi_attach(struct device *parent, struct device *self, void *aux) /* parse resources */ rv = acpi_resource_parse(&sc->sc_dev, aa->aa_node, &asc->res, &acpi_resource_parse_ops_default); - if (rv != AE_OK) { - printf("%s: unable to parse resources\n", sc->sc_dev.dv_xname); + if (rv != AE_OK) return; - } /* find our i/o registers */ io = acpi_res_io(&asc->res, 0); @@ -242,8 +240,8 @@ fdc_acpi_enumerate(struct fdc_acpi_softc *asc) rv = acpi_eval_struct(asc->sc_node->ad_handle, "_FDE", &buf); if (rv != AE_OK) { #ifdef ACPI_FDC_DEBUG - printf("%s: failed to evaluate _FDE: %x\n", - sc->sc_dev.dv_xname, rv); + printf("%s: failed to evaluate _FDE: %s\n", + sc->sc_dev.dv_xname, rv, AcpiFormatException(rv)); #endif return drives; } @@ -305,8 +303,8 @@ fdc_acpi_getknownfds(struct fdc_acpi_softc *asc) rv = acpi_eval_struct(asc->sc_node->ad_handle, "_FDI", &buf); if (rv != AE_OK) { #ifdef ACPI_FDC_DEBUG - printf("%s: failed to evaluate _FDI: %x on drive %d\n", - sc->sc_dev.dv_xname, rv, i); + printf("%s: failed to evaluate _FDI: %s on drive %d\n", + sc->sc_dev.dv_xname, AcpiFormatException(rv), i); #endif /* XXX if _FDI fails, assume 1.44MB floppy */ sc->sc_knownfds[i] = &fdc_acpi_fdtypes[0]; diff --git a/sys/dev/acpi/lpt_acpi.c b/sys/dev/acpi/lpt_acpi.c index 02ba26b8f031..9ada1cfacf10 100644 --- a/sys/dev/acpi/lpt_acpi.c +++ b/sys/dev/acpi/lpt_acpi.c @@ -1,4 +1,4 @@ -/* $NetBSD: lpt_acpi.c,v 1.4 2003/11/03 06:03:47 kochi Exp $ */ +/* $NetBSD: lpt_acpi.c,v 1.5 2003/11/03 17:24:22 mycroft Exp $ */ /* * Copyright (c) 2002 Jared D. McNeill @@ -26,7 +26,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: lpt_acpi.c,v 1.4 2003/11/03 06:03:47 kochi Exp $"); +__KERNEL_RCSID(0, "$NetBSD: lpt_acpi.c,v 1.5 2003/11/03 17:24:22 mycroft Exp $"); #include #include @@ -101,10 +101,8 @@ lpt_acpi_attach(struct device *parent, struct device *self, void *aux) /* parse resources */ rv = acpi_resource_parse(&sc->sc_dev, aa->aa_node, &res, &acpi_resource_parse_ops_default); - if (rv != AE_OK) { - printf("%s: unable to parse resources\n", sc->sc_dev.dv_xname); + if (rv != AE_OK) return; - } /* find our i/o registers */ io = acpi_res_io(&res, 0); diff --git a/sys/dev/acpi/pckbc_acpi.c b/sys/dev/acpi/pckbc_acpi.c index 73bc7155dcc1..29c831116d02 100644 --- a/sys/dev/acpi/pckbc_acpi.c +++ b/sys/dev/acpi/pckbc_acpi.c @@ -1,4 +1,4 @@ -/* $NetBSD: pckbc_acpi.c,v 1.7 2003/11/03 06:03:47 kochi Exp $ */ +/* $NetBSD: pckbc_acpi.c,v 1.8 2003/11/03 17:24:22 mycroft Exp $ */ /*- * Copyright (c) 2000 The NetBSD Foundation, Inc. @@ -49,7 +49,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: pckbc_acpi.c,v 1.7 2003/11/03 06:03:47 kochi Exp $"); +__KERNEL_RCSID(0, "$NetBSD: pckbc_acpi.c,v 1.8 2003/11/03 17:24:22 mycroft Exp $"); #include #include @@ -156,10 +156,8 @@ pckbc_acpi_attach(struct device *parent, /* parse resources */ rv = acpi_resource_parse(&sc->sc_dv, aa->aa_node, &res, &acpi_resource_parse_ops_default); - if (rv != AE_OK) { - printf("%s: unable to parse resources\n", sc->sc_dv.dv_xname); + if (rv != AE_OK) return; - } /* find our IRQ */ irq = acpi_res_irq(&res, 0); diff --git a/sys/dev/acpi/wss_acpi.c b/sys/dev/acpi/wss_acpi.c index 52e88ae9dc87..a9478fe27be9 100644 --- a/sys/dev/acpi/wss_acpi.c +++ b/sys/dev/acpi/wss_acpi.c @@ -1,4 +1,4 @@ -/* $NetBSD: wss_acpi.c,v 1.7 2003/11/03 06:03:47 kochi Exp $ */ +/* $NetBSD: wss_acpi.c,v 1.8 2003/11/03 17:24:22 mycroft Exp $ */ /* * Copyright (c) 2002 Jared D. McNeill @@ -26,7 +26,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: wss_acpi.c,v 1.7 2003/11/03 06:03:47 kochi Exp $"); +__KERNEL_RCSID(0, "$NetBSD: wss_acpi.c,v 1.8 2003/11/03 17:24:22 mycroft Exp $"); #include #include @@ -132,11 +132,8 @@ wss_acpi_attach(struct device *parent, struct device *self, void *aux) /* Parse our resources */ rv = acpi_resource_parse(&sc->sc_ad1848.sc_ad1848.sc_dev, aa->aa_node, &res, &acpi_resource_parse_ops_default); - if (rv != AE_OK) { - printf("%s: unable to parse resources\n", - sc->sc_ad1848.sc_ad1848.sc_dev.dv_xname); + if (rv != AE_OK) return; - } /* Find and map our i/o registers */ sc->sc_iot = aa->aa_iot;