Chameleon

Chameleon Svn Source Tree

Root/branches/rewrite/i386/include/IOKit/avc/IOFireWireAVCCommand.h

Source at commit 1129 created 12 years 11 months ago.
By meklort, Change options.o so that it reloads the system config as well. Also change it so that it uses that config for variables (NOTE: if the calue exists in chameleonConfig, it's used instead.
1/*
2 * Copyright (c) 1998-2001 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#ifndef _IOKIT_IOFireWireAVCCommand_H
23#define _IOKIT_IOFireWireAVCCommand_H
24
25#include <IOKit/firewire/IOFWCommand.h>
26
27/*! @class IOFireWireAVCCommand
28*/
29class IOFireWireAVCCommand : public IOFWCommand
30{
31 OSDeclareDefaultStructors(IOFireWireAVCCommand)
32
33protected:
34 IOFWCommand *fWriteCmd;
35 IOMemoryDescriptor*fMem;
36 const UInt8 *fCommand;
37
38 UInt32 fCmdLen;
39 UInt8 *fResponse;
40 UInt32 *fResponseLen;
41 intfCurRetries;
42 intfMaxRetries;
43
44 UInt32fWriteGen;
45 UInt16fWriteNodeID;
46 boolbypassRobustCommandResponseMatching;
47
48/*! @struct ExpansionData
49 @discussion This structure will be used to expand the capablilties of the class in the future.
50 */
51 struct ExpansionData {
52bool fStarted;
53bool fSyncWakeupSignaled;
54};
55
56/*! @var reserved
57 Reserved for future use. (Internal use only) */
58 ExpansionData *fIOFireWireAVCCommandExpansion;
59
60 static void writeDone(void *refcon, IOReturn status, IOFireWireNub *device, IOFWCommand *fwCmd);
61
62 virtual IOReturncomplete(IOReturn status);
63 virtual IOReturnexecute();
64 virtual voidfree();
65
66public:
67 virtual bool init(IOFireWireNub *device, const UInt8 * command, UInt32 cmdLen,
68 UInt8 * response, UInt32 * responseLen);
69 virtual IOReturn reinit(IOFireWireNub *device, const UInt8 * command, UInt32 cmdLen,
70 UInt8 * response, UInt32 * responseLen);
71
72 static IOFireWireAVCCommand *withNub(IOFireWireNub *device, const UInt8 * command, UInt32 cmdLen,
73 UInt8 * response, UInt32 * responseLen);
74
75 static IOFireWireAVCCommand *withNub(IOFireWireNub *device, UInt32 generation,
76 const UInt8 * command, UInt32 cmdLen, UInt8 * response, UInt32 * responseLen);
77
78 virtual UInt32 handleResponse(UInt16 nodeID, UInt32 len, const void *buf);
79
80 virtual IOReturn resetInterimTimeout();
81
82virtual UInt32 handleResponseWithSimpleMatching(UInt16 nodeID, UInt32 len, const void *buf);
83
84 virtual IOReturn submit(bool queue = false);
85
86private:
87 OSMetaClassDeclareReservedUsed(IOFireWireAVCCommand, 0);
88 OSMetaClassDeclareReservedUnused(IOFireWireAVCCommand, 1);
89 OSMetaClassDeclareReservedUnused(IOFireWireAVCCommand, 2);
90 OSMetaClassDeclareReservedUnused(IOFireWireAVCCommand, 3);
91};
92
93#endif // _IOKIT_IOFireWireAVCCommand_H
94
95

Archive Download this file

Revision: 1129