diff --git a/sys/dev/acpi/acpi_display.c b/sys/dev/acpi/acpi_display.c index 23eea11a0648..a8192a03bc58 100644 --- a/sys/dev/acpi/acpi_display.c +++ b/sys/dev/acpi/acpi_display.c @@ -1,4 +1,4 @@ -/* $NetBSD: acpi_display.c,v 1.1 2010/10/12 19:10:50 gsutre Exp $ */ +/* $NetBSD: acpi_display.c,v 1.2 2010/10/25 17:06:58 jruoho Exp $ */ /*- * Copyright (c) 2010 The NetBSD Foundation, Inc. @@ -66,11 +66,12 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: acpi_display.c,v 1.1 2010/10/12 19:10:50 gsutre Exp $"); +__KERNEL_RCSID(0, "$NetBSD: acpi_display.c,v 1.2 2010/10/25 17:06:58 jruoho Exp $"); #include #include #include +#include #include #include #include @@ -2004,3 +2005,30 @@ acpidisp_array_search(const uint8_t *a, uint16_t n, int v, uint8_t *l, uint8_t * *u = a[j]; return; } + +#ifdef _MODULE + +MODULE(MODULE_CLASS_DRIVER, acpivga, NULL); + +#include "ioconf.c" + +static int +acpivga_modcmd(modcmd_t cmd, void *context) +{ + + switch (cmd) { + + case MODULE_CMD_INIT: + return config_init_component(cfdriver_ioconf_acpivga, + cfattach_ioconf_acpivga, cfdata_ioconf_acpivga); + + case MODULE_CMD_FINI: + return config_fini_component(cfdriver_ioconf_acpivga, + cfattach_ioconf_acpivga, cfdata_ioconf_acpivga); + + default: + return ENOTTY; + } +} + +#endif /* _MODULE */ diff --git a/sys/dev/acpi/acpi_tz.c b/sys/dev/acpi/acpi_tz.c index 28be51b33c03..7db4b246b767 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.74 2010/06/07 17:28:17 jruoho Exp $ */ +/* $NetBSD: acpi_tz.c,v 1.75 2010/10/25 17:06:58 jruoho Exp $ */ /* * Copyright (c) 2003 Jared D. McNeill @@ -30,12 +30,13 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: acpi_tz.c,v 1.74 2010/06/07 17:28:17 jruoho Exp $"); +__KERNEL_RCSID(0, "$NetBSD: acpi_tz.c,v 1.75 2010/10/25 17:06:58 jruoho Exp $"); #include #include #include #include +#include #include #include @@ -796,3 +797,30 @@ acpitz_get_limits(struct sysmon_envsys *sme, envsys_data_t *edata, break; } } + +#ifdef _MODULE + +MODULE(MODULE_CLASS_DRIVER, acpitz, NULL); + +#include "ioconf.c" + +static int +acpitz_modcmd(modcmd_t cmd, void *context) +{ + + switch (cmd) { + + case MODULE_CMD_INIT: + return config_init_component(cfdriver_ioconf_acpitz, + cfattach_ioconf_acpitz, cfdata_ioconf_acpitz); + + case MODULE_CMD_FINI: + return config_fini_component(cfdriver_ioconf_acpitz, + cfattach_ioconf_acpitz, cfdata_ioconf_acpitz); + + default: + return ENOTTY; + } +} + +#endif /* _MODULE */ diff --git a/sys/dev/acpi/atk0110.c b/sys/dev/acpi/atk0110.c index 42f608ee7c7b..3e9d0a25f190 100644 --- a/sys/dev/acpi/atk0110.c +++ b/sys/dev/acpi/atk0110.c @@ -1,4 +1,4 @@ -/* $NetBSD: atk0110.c,v 1.12 2010/07/28 16:02:33 jruoho Exp $ */ +/* $NetBSD: atk0110.c,v 1.13 2010/10/25 17:06:58 jruoho Exp $ */ /* $OpenBSD: atk0110.c,v 1.1 2009/07/23 01:38:16 cnst Exp $ */ /* @@ -18,10 +18,11 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: atk0110.c,v 1.12 2010/07/28 16:02:33 jruoho Exp $"); +__KERNEL_RCSID(0, "$NetBSD: atk0110.c,v 1.13 2010/10/25 17:06:58 jruoho Exp $"); #include #include +#include #include #include @@ -414,3 +415,30 @@ aibs_get_limits(struct sysmon_envsys *sme, envsys_data_t *edata, break; } } + +#ifdef _MODULE + +MODULE(MODULE_CLASS_DRIVER, aibs, NULL); + +#include "ioconf.c" + +static int +aibs_modcmd(modcmd_t cmd, void *context) +{ + + switch (cmd) { + + case MODULE_CMD_INIT: + return config_init_component(cfdriver_ioconf_aibs, + cfattach_ioconf_aibs, cfdata_ioconf_aibs); + + case MODULE_CMD_FINI: + return config_fini_component(cfdriver_ioconf_aibs, + cfattach_ioconf_aibs, cfdata_ioconf_aibs); + + default: + return ENOTTY; + } +} + +#endif /* _MODULE */ diff --git a/sys/dev/acpi/dalb_acpi.c b/sys/dev/acpi/dalb_acpi.c index 841bfe4e7760..099758638f15 100644 --- a/sys/dev/acpi/dalb_acpi.c +++ b/sys/dev/acpi/dalb_acpi.c @@ -1,4 +1,4 @@ -/* $NetBSD: dalb_acpi.c,v 1.15 2010/04/24 19:36:14 jruoho Exp $ */ +/* $NetBSD: dalb_acpi.c,v 1.16 2010/10/25 17:06:58 jruoho Exp $ */ /*- * Copyright (c) 2008 Christoph Egger @@ -27,7 +27,7 @@ * POSSIBILITY OF SUCH DAMAGE. */ #include -__KERNEL_RCSID(0, "$NetBSD: dalb_acpi.c,v 1.15 2010/04/24 19:36:14 jruoho Exp $"); +__KERNEL_RCSID(0, "$NetBSD: dalb_acpi.c,v 1.16 2010/10/25 17:06:58 jruoho Exp $"); /* * Direct Application Launch Button: @@ -36,6 +36,7 @@ __KERNEL_RCSID(0, "$NetBSD: dalb_acpi.c,v 1.15 2010/04/24 19:36:14 jruoho Exp $" #include #include +#include #include #include @@ -197,7 +198,7 @@ acpi_dalb_notify_handler(ACPI_HANDLE hdl, uint32_t notify, void *opaque) case DALB_SYSTEM_RUNTIME: rv = AcpiOsExecute(OSL_NOTIFY_HANDLER, acpi_dalb_get_runtime_hotkeys, dev); - break; + break; default: aprint_error_dev(dev, @@ -259,3 +260,30 @@ acpi_dalb_resume(device_t dev, const pmf_qual_t *qual) return true; } + +#ifdef _MODULE + +MODULE(MODULE_CLASS_DRIVER, acpidalb, NULL); + +#include "ioconf.c" + +static int +acpidalb_modcmd(modcmd_t cmd, void *context) +{ + + switch (cmd) { + + case MODULE_CMD_INIT: + return config_init_component(cfdriver_ioconf_acpidalb, + cfattach_ioconf_acpidalb, cfdata_ioconf_acpidalb); + + case MODULE_CMD_FINI: + return config_fini_component(cfdriver_ioconf_acpidalb, + cfattach_ioconf_acpidalb, cfdata_ioconf_acpidalb); + + default: + return ENOTTY; + } +} + +#endif /* _MODULE */