ACPI_FUNCTION_TRACE((char *)(uintptr_t)__func__);
- //lwkt_serialize_init(&acpi_sxlock);
sc = device_get_softc(dev);
sc->acpi_dev = dev;
callout_init(&sc->susp_force_to);
panic("acpi rman_init memory failed");
/* Initialise the ACPI mutex */
-#ifdef notyet
- spin_init(&acpi_mutex);
-#endif
+ ACPI_LOCK_INIT(acpi, "acpi");
+ ACPI_SERIAL_INIT(acpi);
/*
* Set the globals from our tunables. This is needed because ACPI-CA
int
acpi_ReqSleepState(struct acpi_softc *sc, int state)
{
+#ifdef notyet
struct apm_clone_data *clone;
+#endif
if (state < ACPI_STATE_S1 || state > ACPI_STATE_S5)
return (EINVAL);
kfree(devlist, M_TEMP);
return (error);
}
-#ifdef notye
+#ifdef notyet
for (i = 0; i < numdevs; i++) {
child = devlist[i];
acpi_wake_sysctl_walk(child);
if (error != 0)
return (error);
+ ACPI_SERIAL_INIT(acad);
+
if (device_get_unit(dev) == 0) {
acpi_sc = acpi_device_get_parent_softc(dev);
SYSCTL_ADD_PROC(&acpi_sc->acpi_sysctl_ctx,
int error;
error = 0;
+ ACPI_SERIAL_INIT(battery);
ACPI_SERIAL_BEGIN(battery);
if (!acpi_batteries_initted)
error = acpi_battery_init();
handle = acpi_get_handle(dev);
sc->dev = dev;
+ ACPI_SERIAL_INIT(cmbat);
+
timespecclear(&sc->bst_lastupdated);
error = acpi_battery_register(dev);
params = acpi_get_private(dev);
sc->ec_dev = dev;
sc->ec_handle = acpi_get_handle(dev);
+ ACPI_SERIAL_INIT(ec);
/* Retrieve previously probed values via device ivars. */
sc->ec_glk = params->glk;
sc->lid_dev = dev;
sc->lid_handle = acpi_get_handle(dev);
+ ACPI_SERIAL_INIT(lid);
+
/*
* If a system does not get lid events, it may make sense to change
* the type to ACPI_ALL_NOTIFY. Some systems generate both a wake and
device_printf(dev, "domain=%d, physical bus=%d\n",
domain, busno);
+ ACPI_SERIAL_INIT(pci_powerstate);
+
/*
* First, PCI devices are added as in the normal PCI bus driver.
* Afterwards, the ACPI namespace under the bridge driver is
sc = device_get_softc(dev);
sc->pl_dev = dev;
+ ACPI_SERIAL_INIT(pci_link);
ACPI_SERIAL_BEGIN(pci_link);
/*
if (!acpi_DeviceIsPresent(dev))
return_VALUE(ENXIO);
+ ACPI_SERIAL_INIT(pcib);
+
/*
* Get the PCI interrupt routing table for this bus. If we can't
* get it, this is not an error but may reduce functionality. There
static void
acpi_pwr_init(void *junk)
{
+ ACPI_SERIAL_INIT(powerres);
TAILQ_INIT(&acpi_powerresources);
TAILQ_INIT(&acpi_powerconsumers);
}
-// SYSINIT(acpi_powerresource, SI_SUB_TUNABLES, SI_ORDER_ANY, acpi_pwr_init, NULL);
+SYSINIT(acpi_powerresource, SI_BOOT1_TUNABLES, SI_ORDER_ANY, acpi_pwr_init, NULL);
/*
* Register a power resource.