Root/
Source at commit 2920 created 5 years 9 months ago. By ifabio, typo | |
---|---|
1 | /*␊ |
2 | * Copyright (c) 1998-2002 Apple Computer, Inc. All rights reserved.␊ |
3 | *␊ |
4 | * @APPLE_LICENSE_HEADER_START@␊ |
5 | *␊ |
6 | * The contents of this file constitute Original Code as defined in and␊ |
7 | * are subject to the Apple Public Source License Version 1.1 (the␊ |
8 | * "License"). You may not use this file except in compliance with the␊ |
9 | * License. Please obtain a copy of the License at␊ |
10 | * http://www.apple.com/publicsource and read it before using this file.␊ |
11 | *␊ |
12 | * This Original Code and all software distributed under the License are␊ |
13 | * distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY KIND, EITHER␊ |
14 | * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,␊ |
15 | * INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,␊ |
16 | * FITNESS FOR A PARTICULAR PURPOSE OR NON-INFRINGEMENT. Please see the␊ |
17 | * License for the specific language governing rights and limitations␊ |
18 | * under the License.␊ |
19 | *␊ |
20 | * @APPLE_LICENSE_HEADER_END@␊ |
21 | */␊ |
22 | ␊ |
23 | #ifndef __IOREMOTECONFIGDIRECTORY_H__␊ |
24 | #define __IOREMOTECONFIGDIRECTORY_H__␊ |
25 | ␊ |
26 | #include <libkern/c++/OSObject.h>␊ |
27 | #include <IOKit/IOReturn.h>␊ |
28 | ␊ |
29 | #include <IOKit/firewire/IOFireWireFamilyCommon.h>␊ |
30 | #include <IOKit/firewire/IOConfigDirectory.h>␊ |
31 | ␊ |
32 | #include "IOFireWireROMCache.h"␊ |
33 | ␊ |
34 | class OSString;␊ |
35 | class OSIterator;␊ |
36 | class IOFireWireDevice;␊ |
37 | ␊ |
38 | /*! @class IORemoteConfigDirectory␊ |
39 | */␊ |
40 | class IORemoteConfigDirectory : public IOConfigDirectory␊ |
41 | {␊ |
42 | OSDeclareDefaultStructors(IORemoteConfigDirectory);␊ |
43 | ␊ |
44 | protected:␊ |
45 | IOFireWireROMCache *fROM;␉␉␉␉// Our cache of the ROM␊ |
46 | ␊ |
47 | /*! @struct ExpansionData␊ |
48 | @discussion This structure will be used to expand the capablilties of the class in the future.␊ |
49 | */ ␊ |
50 | struct ExpansionData { };␊ |
51 | ␊ |
52 | /*! @var reserved␊ |
53 | Reserved for future use. (Internal use only) */␊ |
54 | ExpansionData *reserved;␊ |
55 | ␊ |
56 | virtual bool initWithOwnerOffset(IOFireWireROMCache *rom,␊ |
57 | int start, int type);␊ |
58 | virtual void free();␊ |
59 | ␊ |
60 | virtual const UInt32 *getBase();␊ |
61 | virtual IOConfigDirectory *getSubDir(int start, int type);␊ |
62 | ␊ |
63 | public:␊ |
64 | static IOConfigDirectory *withOwnerOffset(IOFireWireROMCache *rom,␊ |
65 | int start, int type);␊ |
66 | ␊ |
67 | ␊ |
68 | /*!␊ |
69 | @function update␊ |
70 | makes sure that the ROM has at least the specified capacity,␊ |
71 | and that the ROM is uptodate from its start to at least the␊ |
72 | specified quadlet offset.␊ |
73 | @result kIOReturnSuccess if the specified offset is now␊ |
74 | accessable at romBase[offset].␊ |
75 | */␊ |
76 | virtual IOReturn update(UInt32 offset, const UInt32 *&romBase);␊ |
77 | ␊ |
78 | protected:␊ |
79 | ␉␊ |
80 | ␉virtual const UInt32 * lockData( void );␊ |
81 | ␉virtual void unlockData( void );␊ |
82 | ␉virtual IOReturn updateROMCache( UInt32 offset, UInt32 length );␊ |
83 | ␉virtual IOReturn checkROMState( void );␊ |
84 | ␉␊ |
85 | private:␊ |
86 | OSMetaClassDeclareReservedUnused(IORemoteConfigDirectory, 0);␊ |
87 | OSMetaClassDeclareReservedUnused(IORemoteConfigDirectory, 1);␊ |
88 | OSMetaClassDeclareReservedUnused(IORemoteConfigDirectory, 2);␊ |
89 | };␊ |
90 | ␊ |
91 | ␊ |
92 | #endif /* __IOREMOTECONFIGDIRECTORY_H__ */␊ |
93 |