/****************************************************************************** * * Module Name: exstubs - Stub routines for the Example program * *****************************************************************************/ /* * Copyright (C) 2000 - 2013, Intel Corp. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions, and the following disclaimer, * without modification. * 2. Redistributions in binary form must reproduce at minimum a disclaimer * substantially similar to the "NO WARRANTY" disclaimer below * ("Disclaimer") and any redistribution must be conditioned upon * including a substantially similar Disclaimer requirement for further * binary redistribution. * 3. Neither the names of the above-listed copyright holders nor the names * of any contributors may be used to endorse or promote products derived * from this software without specific prior written permission. * * Alternatively, this software may be distributed under the terms of the * GNU General Public License ("GPL") version 2 as published by the Free * Software Foundation. * * NO WARRANTY * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT * HOLDERS OR CONTRIBUTORS BE LIABLE FOR SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, * STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE * POSSIBILITY OF SUCH DAMAGES. */ #include "examples.h" #include #include #include #define _COMPONENT ACPI_EXAMPLE ACPI_MODULE_NAME ("exstubs") /****************************************************************************** * * DESCRIPTION: Stubs used to facilitate linkage of the example program * *****************************************************************************/ /* Utilities */ void AcpiUtSubsystemShutdown ( void) { } ACPI_STATUS AcpiUtExecute_STA ( ACPI_NAMESPACE_NODE *DeviceNode, UINT32 *StatusFlags) { return (AE_NOT_IMPLEMENTED); } ACPI_STATUS AcpiUtExecute_HID ( ACPI_NAMESPACE_NODE *DeviceNode, ACPI_PNP_DEVICE_ID **ReturnId) { return (AE_NOT_IMPLEMENTED); } ACPI_STATUS AcpiUtExecute_CID ( ACPI_NAMESPACE_NODE *DeviceNode, ACPI_PNP_DEVICE_ID_LIST **ReturnCidList) { return (AE_NOT_IMPLEMENTED); } ACPI_STATUS AcpiUtExecute_UID ( ACPI_NAMESPACE_NODE *DeviceNode, ACPI_PNP_DEVICE_ID **ReturnId) { return (AE_NOT_IMPLEMENTED); } ACPI_STATUS AcpiUtExecute_SUB ( ACPI_NAMESPACE_NODE *DeviceNode, ACPI_PNP_DEVICE_ID **ReturnId) { return (AE_NOT_IMPLEMENTED); } ACPI_STATUS AcpiUtExecutePowerMethods ( ACPI_NAMESPACE_NODE *DeviceNode, const char **MethodNames, UINT8 MethodCount, UINT8 *OutValues) { return (AE_NOT_IMPLEMENTED); } ACPI_STATUS AcpiUtEvaluateNumericObject ( char *ObjectName, ACPI_NAMESPACE_NODE *DeviceNode, UINT64 *Value) { return (AE_NOT_IMPLEMENTED); } ACPI_STATUS AcpiUtGetResourceEndTag ( ACPI_OPERAND_OBJECT *ObjDesc, UINT8 **EndTag) { return (AE_OK); } /* Hardware manager */ UINT32 AcpiHwGetMode ( void) { return (0); } ACPI_STATUS AcpiHwReadPort ( ACPI_IO_ADDRESS Address, UINT32 *Value, UINT32 Width) { return (AE_OK); } ACPI_STATUS AcpiHwWritePort ( ACPI_IO_ADDRESS Address, UINT32 Value, UINT32 Width) { return (AE_OK); } /* Event manager */ ACPI_STATUS AcpiInstallNotifyHandler ( ACPI_HANDLE Device, UINT32 HandlerType, ACPI_NOTIFY_HANDLER Handler, void *Context) { return (AE_OK); } ACPI_STATUS AcpiEvInstallXruptHandlers ( void) { return (AE_OK); } ACPI_STATUS AcpiEvInitializeEvents ( void) { return (AE_OK); } ACPI_STATUS AcpiEvInstallRegionHandlers ( void) { return (AE_OK); } ACPI_STATUS AcpiEvInitializeOpRegions ( void) { return (AE_OK); } ACPI_STATUS AcpiEvInitializeRegion ( ACPI_OPERAND_OBJECT *RegionObj, BOOLEAN AcpiNsLocked) { return (AE_OK); } #if (!ACPI_REDUCED_HARDWARE) ACPI_STATUS AcpiEvDeleteGpeBlock ( ACPI_GPE_BLOCK_INFO *GpeBlock) { return (AE_OK); } ACPI_STATUS AcpiEnable ( void) { return (AE_OK); } #endif /* !ACPI_REDUCED_HARDWARE */ void AcpiEvUpdateGpes ( ACPI_OWNER_ID TableOwnerId) { } ACPI_STATUS AcpiEvAddressSpaceDispatch ( ACPI_OPERAND_OBJECT *RegionObj, ACPI_OPERAND_OBJECT *FieldObj, UINT32 Function, UINT32 RegionOffset, UINT32 BitWidth, UINT64 *Value) { return (AE_OK); } ACPI_STATUS AcpiEvAcquireGlobalLock ( UINT16 Timeout) { return (AE_OK); } ACPI_STATUS AcpiEvReleaseGlobalLock ( void) { return (AE_OK); } ACPI_STATUS AcpiEvQueueNotifyRequest ( ACPI_NAMESPACE_NODE *Node, UINT32 NotifyValue) { return (AE_OK); } BOOLEAN AcpiEvIsNotifyObject ( ACPI_NAMESPACE_NODE *Node) { return (TRUE); } /* Namespace manager */ ACPI_STATUS AcpiNsCheckReturnValue ( ACPI_NAMESPACE_NODE *Node, ACPI_EVALUATE_INFO *Info, UINT32 UserParamCount, ACPI_STATUS ReturnStatus, ACPI_OPERAND_OBJECT **ReturnObjectPtr) { return (AE_OK); } void AcpiNsCheckArgumentTypes ( ACPI_EVALUATE_INFO *Info) { return; } void AcpiNsCheckArgumentCount ( char *Pathname, ACPI_NAMESPACE_NODE *Node, UINT32 UserParamCount, const ACPI_PREDEFINED_INFO *Predefined) { return; } void AcpiNsCheckAcpiCompliance ( char *Pathname, ACPI_NAMESPACE_NODE *Node, const ACPI_PREDEFINED_INFO *Predefined) { return; } const ACPI_PREDEFINED_INFO * AcpiUtMatchPredefinedMethod ( char *Name) { return (NULL); } /* OSL interfaces */ ACPI_THREAD_ID AcpiOsGetThreadId ( void) { return (1); } ACPI_STATUS AcpiOsExecute ( ACPI_EXECUTE_TYPE Type, ACPI_OSD_EXEC_CALLBACK Function, void *Context) { return (AE_SUPPORT); }