1*617994efSAndrew Turner /*-
2*617994efSAndrew Turner * Copyright (c) 2015 The FreeBSD Foundation
3*617994efSAndrew Turner *
4*617994efSAndrew Turner * This software was developed by Andrew Turner under
5*617994efSAndrew Turner * sponsorship from the FreeBSD Foundation.
6*617994efSAndrew Turner *
7*617994efSAndrew Turner * Redistribution and use in source and binary forms, with or without
8*617994efSAndrew Turner * modification, are permitted provided that the following conditions
9*617994efSAndrew Turner * are met:
10*617994efSAndrew Turner * 1. Redistributions of source code must retain the above copyright
11*617994efSAndrew Turner * notice, this list of conditions and the following disclaimer.
12*617994efSAndrew Turner * 2. Redistributions in binary form must reproduce the above copyright
13*617994efSAndrew Turner * notice, this list of conditions and the following disclaimer in the
14*617994efSAndrew Turner * documentation and/or other materials provided with the distribution.
15*617994efSAndrew Turner *
16*617994efSAndrew Turner * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
17*617994efSAndrew Turner * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
18*617994efSAndrew Turner * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
19*617994efSAndrew Turner * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
20*617994efSAndrew Turner * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
21*617994efSAndrew Turner * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
22*617994efSAndrew Turner * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
23*617994efSAndrew Turner * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
24*617994efSAndrew Turner * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
25*617994efSAndrew Turner * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
26*617994efSAndrew Turner * SUCH DAMAGE.
27*617994efSAndrew Turner */
28*617994efSAndrew Turner
29*617994efSAndrew Turner #include <sys/param.h>
30*617994efSAndrew Turner #include <sys/bus.h>
31*617994efSAndrew Turner #include <sys/kernel.h>
32*617994efSAndrew Turner
33*617994efSAndrew Turner #include <contrib/dev/acpica/include/acpi.h>
34*617994efSAndrew Turner
35*617994efSAndrew Turner #include <dev/acpica/acpivar.h>
36*617994efSAndrew Turner
37*617994efSAndrew Turner /*
38*617994efSAndrew Turner * ARM64TODO: Implement this.
39*617994efSAndrew Turner */
40*617994efSAndrew Turner int
acpi_sleep_machdep(struct acpi_softc * sc,int state)41*617994efSAndrew Turner acpi_sleep_machdep(struct acpi_softc *sc, int state)
42*617994efSAndrew Turner {
43*617994efSAndrew Turner
44*617994efSAndrew Turner return (-1);
45*617994efSAndrew Turner }
46*617994efSAndrew Turner
47*617994efSAndrew Turner int
acpi_wakeup_machdep(struct acpi_softc * sc,int state,int sleep_result,int intr_enabled)48*617994efSAndrew Turner acpi_wakeup_machdep(struct acpi_softc *sc, int state, int sleep_result,
49*617994efSAndrew Turner int intr_enabled)
50*617994efSAndrew Turner {
51*617994efSAndrew Turner
52*617994efSAndrew Turner /* ARM64TODO: We will need this with acpi_sleep_machdep */
53*617994efSAndrew Turner KASSERT(sleep_result == -1,
54*617994efSAndrew Turner ("acpi_wakeup_machdep: Invalid sleep result"));
55*617994efSAndrew Turner
56*617994efSAndrew Turner return (sleep_result);
57*617994efSAndrew Turner }
58