The Design and Implementation of the FreeBSD Operating System, Second Edition
Now available: The Design and Implementation of the FreeBSD Operating System (Second Edition)


[ source navigation ] [ diff markup ] [ identifier search ] [ freetext search ] [ file search ] [ list types ] [ track identifier ]

FreeBSD/Linux Kernel Cross Reference
sys/iokit/IOKit/IODeviceTreeSupport.h

Version: -  FREEBSD  -  FREEBSD-13-STABLE  -  FREEBSD-13-0  -  FREEBSD-12-STABLE  -  FREEBSD-12-0  -  FREEBSD-11-STABLE  -  FREEBSD-11-0  -  FREEBSD-10-STABLE  -  FREEBSD-10-0  -  FREEBSD-9-STABLE  -  FREEBSD-9-0  -  FREEBSD-8-STABLE  -  FREEBSD-8-0  -  FREEBSD-7-STABLE  -  FREEBSD-7-0  -  FREEBSD-6-STABLE  -  FREEBSD-6-0  -  FREEBSD-5-STABLE  -  FREEBSD-5-0  -  FREEBSD-4-STABLE  -  FREEBSD-3-STABLE  -  FREEBSD22  -  l41  -  OPENBSD  -  linux-2.6  -  MK84  -  PLAN9  -  xnu-8792 
SearchContext: -  none  -  3  -  10 

    1 /*
    2  * Copyright (c) 1998-2000 Apple Computer, Inc. All rights reserved.
    3  *
    4  * @APPLE_OSREFERENCE_LICENSE_HEADER_START@
    5  * 
    6  * This file contains Original Code and/or Modifications of Original Code
    7  * as defined in and that are subject to the Apple Public Source License
    8  * Version 2.0 (the 'License'). You may not use this file except in
    9  * compliance with the License. The rights granted to you under the License
   10  * may not be used to create, or enable the creation or redistribution of,
   11  * unlawful or unlicensed copies of an Apple operating system, or to
   12  * circumvent, violate, or enable the circumvention or violation of, any
   13  * terms of an Apple operating system software license agreement.
   14  * 
   15  * Please obtain a copy of the License at
   16  * http://www.opensource.apple.com/apsl/ and read it before using this file.
   17  * 
   18  * The Original Code and all software distributed under the License are
   19  * distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
   20  * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
   21  * INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
   22  * FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
   23  * Please see the License for the specific language governing rights and
   24  * limitations under the License.
   25  * 
   26  * @APPLE_OSREFERENCE_LICENSE_HEADER_END@
   27  */
   28 /*
   29  * Copyright (c) 1998 Apple Computer, Inc.  All rights reserved. 
   30  *
   31  * HISTORY
   32  *
   33  */
   34 
   35 #ifndef _IOKIT_IODEVICETREE_H
   36 #define _IOKIT_IODEVICETREE_H
   37 
   38 #include <IOKit/IORegistryEntry.h>
   39 #include <libkern/c++/OSData.h>
   40 
   41 class IODeviceMemory;
   42 class IOService;
   43 
   44 extern const IORegistryPlane *  gIODTPlane;
   45 
   46 extern const OSSymbol *         gIODTPHandleKey;
   47 
   48 extern const OSSymbol *         gIODTCompatibleKey;
   49 extern const OSSymbol *         gIODTTypeKey;
   50 extern const OSSymbol *         gIODTModelKey;
   51 
   52 extern const OSSymbol *         gIODTAAPLInterruptsKey;
   53 extern const OSSymbol *         gIODTDefaultInterruptController;
   54 extern const OSSymbol *         gIODTNWInterruptMappingKey;
   55 
   56 IORegistryEntry * IODeviceTreeAlloc( void * dtTop );
   57 
   58 
   59 bool IODTMatchNubWithKeys( IORegistryEntry * nub,
   60                                     const char * keys );
   61 
   62 bool IODTCompareNubName( const IORegistryEntry * regEntry,
   63                          OSString * name, OSString ** matchingName );
   64 
   65 enum {
   66     kIODTRecursive      = 0x00000001,
   67     kIODTExclusive      = 0x00000002
   68 };
   69 
   70 OSCollectionIterator * IODTFindMatchingEntries( IORegistryEntry * from,
   71                         IOOptionBits options, const char * keys );
   72 
   73 typedef SInt32 (*IODTCompareAddressCellFunc)
   74         (UInt32 cellCount, UInt32 left[], UInt32 right[]);
   75 
   76 typedef SInt64 (*IODTCompareAddressCell64Func)
   77         (UInt32 cellCount, UInt32 left[], UInt32 right[]);
   78 
   79 typedef void (*IODTNVLocationFunc)
   80         (IORegistryEntry * entry,
   81         UInt8 * busNum, UInt8 * deviceNum, UInt8 * functionNum );
   82 
   83 void IODTSetResolving( IORegistryEntry *        regEntry,
   84                 IODTCompareAddressCellFunc      compareFunc,
   85                 IODTNVLocationFunc              locationFunc );
   86 
   87 bool IODTResolveAddressCell( IORegistryEntry * regEntry,
   88                              UInt32 cellsIn[],
   89                              IOPhysicalAddress * phys, IOPhysicalLength * len );
   90 
   91 OSArray * IODTResolveAddressing( IORegistryEntry * regEntry,
   92                         const char * addressPropertyName,
   93                         IODeviceMemory * parent );
   94 
   95 struct IONVRAMDescriptor {
   96     unsigned int format:4;
   97     unsigned int marker:1;
   98     unsigned int bridgeCount:3;
   99     unsigned int busNum:2;
  100     unsigned int bridgeDevices:6 * 5;
  101     unsigned int functionNum:3;
  102     unsigned int deviceNum:5;
  103 } __attribute__((aligned(2), packed));
  104 
  105 IOReturn IODTMakeNVDescriptor( IORegistryEntry * regEntry,
  106                                 IONVRAMDescriptor * hdr );
  107 
  108 OSData * IODTFindSlotName( IORegistryEntry * regEntry, UInt32 deviceNumber );
  109 
  110 const OSSymbol * IODTInterruptControllerName(
  111                         IORegistryEntry * regEntry );
  112 
  113 bool IODTMapInterrupts( IORegistryEntry * regEntry );
  114 
  115 enum {
  116     kIODTInterruptShared = 0x00000001
  117 };
  118 IOReturn IODTGetInterruptOptions( IORegistryEntry * regEntry, int source, IOOptionBits * options );
  119 
  120 #ifdef __cplusplus
  121 extern "C" {
  122 #endif
  123 
  124 IOReturn IONDRVLibrariesInitialize( IOService * provider );
  125 
  126 #ifdef __cplusplus
  127 }
  128 #endif
  129 
  130 #endif /* _IOKIT_IODEVICETREE_H */
  131 

Cache object: 79f5657f4a21de930c69c2970046286f


[ source navigation ] [ diff markup ] [ identifier search ] [ freetext search ] [ file search ] [ list types ] [ track identifier ]


This page is part of the FreeBSD/Linux Linux Kernel Cross-Reference, and was automatically generated using a modified version of the LXR engine.