xref: /titanic_51/usr/src/uts/i86pc/os/acpi_stubs.c (revision 2df1fe9ca32bb227b9158c67f5c00b54c20b10fd)
1*2df1fe9cSrandyf /*
2*2df1fe9cSrandyf  * CDDL HEADER START
3*2df1fe9cSrandyf  *
4*2df1fe9cSrandyf  * The contents of this file are subject to the terms of the
5*2df1fe9cSrandyf  * Common Development and Distribution License (the "License").
6*2df1fe9cSrandyf  * You may not use this file except in compliance with the License.
7*2df1fe9cSrandyf  *
8*2df1fe9cSrandyf  * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
9*2df1fe9cSrandyf  * or http://www.opensolaris.org/os/licensing.
10*2df1fe9cSrandyf  * See the License for the specific language governing permissions
11*2df1fe9cSrandyf  * and limitations under the License.
12*2df1fe9cSrandyf  *
13*2df1fe9cSrandyf  * When distributing Covered Code, include this CDDL HEADER in each
14*2df1fe9cSrandyf  * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
15*2df1fe9cSrandyf  * If applicable, add the following below this CDDL HEADER, with the
16*2df1fe9cSrandyf  * fields enclosed by brackets "[]" replaced with your own identifying
17*2df1fe9cSrandyf  * information: Portions Copyright [yyyy] [name of copyright owner]
18*2df1fe9cSrandyf  *
19*2df1fe9cSrandyf  * CDDL HEADER END
20*2df1fe9cSrandyf  */
21*2df1fe9cSrandyf /*
22*2df1fe9cSrandyf  * Copyright 2007 Sun Microsystems, Inc.  All rights reserved.
23*2df1fe9cSrandyf  * Use is subject to license terms.
24*2df1fe9cSrandyf  */
25*2df1fe9cSrandyf 
26*2df1fe9cSrandyf #pragma ident	"%Z%%M%	%I%	%E% SMI"
27*2df1fe9cSrandyf 
28*2df1fe9cSrandyf #include <sys/types.h>
29*2df1fe9cSrandyf 
30*2df1fe9cSrandyf #include <sys/acpi/acpi.h>
31*2df1fe9cSrandyf #include <sys/acpica.h>
32*2df1fe9cSrandyf 
33*2df1fe9cSrandyf /*
34*2df1fe9cSrandyf  * This file contains ACPI functions that are needed by the kernel before
35*2df1fe9cSrandyf  * the ACPI module is loaded.  Any functions or definitions need to be
36*2df1fe9cSrandyf  * able to deal with the possibility that ACPI doesn't get loaded, or
37*2df1fe9cSrandyf  * doesn't contain the required method.
38*2df1fe9cSrandyf  */
39*2df1fe9cSrandyf 
40*2df1fe9cSrandyf int (*acpi_fp_setwake)();
41*2df1fe9cSrandyf 
42*2df1fe9cSrandyf /*
43*2df1fe9cSrandyf  *
44*2df1fe9cSrandyf  */
45*2df1fe9cSrandyf int
46*2df1fe9cSrandyf acpi_ddi_setwake(dev_info_t *dip, int level)
47*2df1fe9cSrandyf {
48*2df1fe9cSrandyf 	if (acpi_fp_setwake == NULL)
49*2df1fe9cSrandyf 		return (AE_ERROR);
50*2df1fe9cSrandyf 
51*2df1fe9cSrandyf 	return ((*acpi_fp_setwake)(dip, level));
52*2df1fe9cSrandyf }
53