staging: unisys: remove U32 type
This patch switches all use of the U32 typedef to use the kernel's u32 type instead. Signed-off-by: Benjamin Romer <benjamin.romer@unisys.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
b06bdf7d5b
commit
b3c55b13a1
23 changed files with 315 additions and 316 deletions
|
@ -44,7 +44,7 @@
|
||||||
* 1 if the insertion succeeds, 0 if the queue was full.
|
* 1 if the insertion succeeds, 0 if the queue was full.
|
||||||
*/
|
*/
|
||||||
unsigned char
|
unsigned char
|
||||||
visor_signal_insert(CHANNEL_HEADER __iomem *pChannel, U32 Queue, void *pSignal)
|
visor_signal_insert(CHANNEL_HEADER __iomem *pChannel, u32 Queue, void *pSignal)
|
||||||
{
|
{
|
||||||
void __iomem *psignal;
|
void __iomem *psignal;
|
||||||
unsigned int head, tail, nof;
|
unsigned int head, tail, nof;
|
||||||
|
@ -102,7 +102,7 @@ EXPORT_SYMBOL_GPL(visor_signal_insert);
|
||||||
* 1 if the removal succeeds, 0 if the queue was empty.
|
* 1 if the removal succeeds, 0 if the queue was empty.
|
||||||
*/
|
*/
|
||||||
unsigned char
|
unsigned char
|
||||||
visor_signal_remove(CHANNEL_HEADER __iomem *pChannel, U32 Queue, void *pSignal)
|
visor_signal_remove(CHANNEL_HEADER __iomem *pChannel, u32 Queue, void *pSignal)
|
||||||
{
|
{
|
||||||
void __iomem *psource;
|
void __iomem *psource;
|
||||||
unsigned int head, tail;
|
unsigned int head, tail;
|
||||||
|
@ -157,7 +157,7 @@ EXPORT_SYMBOL_GPL(visor_signal_remove);
|
||||||
* # of signals copied.
|
* # of signals copied.
|
||||||
*/
|
*/
|
||||||
unsigned int
|
unsigned int
|
||||||
SignalRemoveAll(pCHANNEL_HEADER pChannel, U32 Queue, void *pSignal)
|
SignalRemoveAll(pCHANNEL_HEADER pChannel, u32 Queue, void *pSignal)
|
||||||
{
|
{
|
||||||
void *psource;
|
void *psource;
|
||||||
unsigned int head, tail, signalCount = 0;
|
unsigned int head, tail, signalCount = 0;
|
||||||
|
@ -208,7 +208,7 @@ SignalRemoveAll(pCHANNEL_HEADER pChannel, U32 Queue, void *pSignal)
|
||||||
* 1 if the signal queue is empty, 0 otherwise.
|
* 1 if the signal queue is empty, 0 otherwise.
|
||||||
*/
|
*/
|
||||||
unsigned char
|
unsigned char
|
||||||
visor_signalqueue_empty(CHANNEL_HEADER __iomem *pChannel, U32 Queue)
|
visor_signalqueue_empty(CHANNEL_HEADER __iomem *pChannel, u32 Queue)
|
||||||
{
|
{
|
||||||
SIGNAL_QUEUE_HEADER __iomem *pqhdr =
|
SIGNAL_QUEUE_HEADER __iomem *pqhdr =
|
||||||
(SIGNAL_QUEUE_HEADER __iomem *) ((char __iomem *) pChannel +
|
(SIGNAL_QUEUE_HEADER __iomem *) ((char __iomem *) pChannel +
|
||||||
|
|
|
@ -42,7 +42,7 @@ channel_mod_exit(void)
|
||||||
}
|
}
|
||||||
|
|
||||||
unsigned char
|
unsigned char
|
||||||
SignalInsert_withLock(CHANNEL_HEADER __iomem *pChannel, U32 Queue,
|
SignalInsert_withLock(CHANNEL_HEADER __iomem *pChannel, u32 Queue,
|
||||||
void *pSignal, spinlock_t *lock)
|
void *pSignal, spinlock_t *lock)
|
||||||
{
|
{
|
||||||
unsigned char result;
|
unsigned char result;
|
||||||
|
@ -54,7 +54,7 @@ SignalInsert_withLock(CHANNEL_HEADER __iomem *pChannel, U32 Queue,
|
||||||
}
|
}
|
||||||
|
|
||||||
unsigned char
|
unsigned char
|
||||||
SignalRemove_withLock(CHANNEL_HEADER __iomem *pChannel, U32 Queue,
|
SignalRemove_withLock(CHANNEL_HEADER __iomem *pChannel, u32 Queue,
|
||||||
void *pSignal, spinlock_t *lock)
|
void *pSignal, spinlock_t *lock)
|
||||||
{
|
{
|
||||||
unsigned char result;
|
unsigned char result;
|
||||||
|
|
|
@ -15,9 +15,9 @@
|
||||||
|
|
||||||
#ifndef __CHANSTUB_H__
|
#ifndef __CHANSTUB_H__
|
||||||
#define __CHANSTUB_H__
|
#define __CHANSTUB_H__
|
||||||
unsigned char SignalInsert_withLock(CHANNEL_HEADER __iomem *pChannel, U32 Queue,
|
unsigned char SignalInsert_withLock(CHANNEL_HEADER __iomem *pChannel, u32 Queue,
|
||||||
void *pSignal, spinlock_t *lock);
|
void *pSignal, spinlock_t *lock);
|
||||||
unsigned char SignalRemove_withLock(CHANNEL_HEADER __iomem *pChannel, U32 Queue,
|
unsigned char SignalRemove_withLock(CHANNEL_HEADER __iomem *pChannel, u32 Queue,
|
||||||
void *pSignal, spinlock_t *lock);
|
void *pSignal, spinlock_t *lock);
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -71,7 +71,7 @@ typedef enum {
|
||||||
* access channel anytime */
|
* access channel anytime */
|
||||||
} CHANNEL_CLIENTSTATE;
|
} CHANNEL_CLIENTSTATE;
|
||||||
static inline const u8 *
|
static inline const u8 *
|
||||||
ULTRA_CHANNELCLI_STRING(U32 v)
|
ULTRA_CHANNELCLI_STRING(u32 v)
|
||||||
{
|
{
|
||||||
switch (v) {
|
switch (v) {
|
||||||
case CHANNELCLI_DETACHED:
|
case CHANNELCLI_DETACHED:
|
||||||
|
@ -210,33 +210,33 @@ ULTRA_CHANNELCLI_STRING(U32 v)
|
||||||
/* Common Channel Header */
|
/* Common Channel Header */
|
||||||
typedef struct _CHANNEL_HEADER {
|
typedef struct _CHANNEL_HEADER {
|
||||||
U64 Signature; /* Signature */
|
U64 Signature; /* Signature */
|
||||||
U32 LegacyState; /* DEPRECATED - being replaced by */
|
u32 LegacyState; /* DEPRECATED - being replaced by */
|
||||||
/* / SrvState, CliStateBoot, and CliStateOS below */
|
/* / SrvState, CliStateBoot, and CliStateOS below */
|
||||||
U32 HeaderSize; /* sizeof(CHANNEL_HEADER) */
|
u32 HeaderSize; /* sizeof(CHANNEL_HEADER) */
|
||||||
U64 Size; /* Total size of this channel in bytes */
|
U64 Size; /* Total size of this channel in bytes */
|
||||||
U64 Features; /* Flags to modify behavior */
|
U64 Features; /* Flags to modify behavior */
|
||||||
uuid_le Type; /* Channel type: data, bus, control, etc. */
|
uuid_le Type; /* Channel type: data, bus, control, etc. */
|
||||||
U64 PartitionHandle; /* ID of guest partition */
|
U64 PartitionHandle; /* ID of guest partition */
|
||||||
U64 Handle; /* Device number of this channel in client */
|
U64 Handle; /* Device number of this channel in client */
|
||||||
U64 oChannelSpace; /* Offset in bytes to channel specific area */
|
U64 oChannelSpace; /* Offset in bytes to channel specific area */
|
||||||
U32 VersionId; /* CHANNEL_HEADER Version ID */
|
u32 VersionId; /* CHANNEL_HEADER Version ID */
|
||||||
U32 PartitionIndex; /* Index of guest partition */
|
u32 PartitionIndex; /* Index of guest partition */
|
||||||
uuid_le ZoneGuid; /* Guid of Channel's zone */
|
uuid_le ZoneGuid; /* Guid of Channel's zone */
|
||||||
U32 oClientString; /* offset from channel header to
|
u32 oClientString; /* offset from channel header to
|
||||||
* nul-terminated ClientString (0 if
|
* nul-terminated ClientString (0 if
|
||||||
* ClientString not present) */
|
* ClientString not present) */
|
||||||
U32 CliStateBoot; /* CHANNEL_CLIENTSTATE of pre-boot
|
u32 CliStateBoot; /* CHANNEL_CLIENTSTATE of pre-boot
|
||||||
* EFI client of this channel */
|
* EFI client of this channel */
|
||||||
U32 CmdStateCli; /* CHANNEL_COMMANDSTATE (overloaded in
|
u32 CmdStateCli; /* CHANNEL_COMMANDSTATE (overloaded in
|
||||||
* Windows drivers, see ServerStateUp,
|
* Windows drivers, see ServerStateUp,
|
||||||
* ServerStateDown, etc) */
|
* ServerStateDown, etc) */
|
||||||
U32 CliStateOS; /* CHANNEL_CLIENTSTATE of Guest OS
|
u32 CliStateOS; /* CHANNEL_CLIENTSTATE of Guest OS
|
||||||
* client of this channel */
|
* client of this channel */
|
||||||
U32 ChannelCharacteristics; /* CHANNEL_CHARACTERISTIC_<xxx> */
|
u32 ChannelCharacteristics; /* CHANNEL_CHARACTERISTIC_<xxx> */
|
||||||
U32 CmdStateSrv; /* CHANNEL_COMMANDSTATE (overloaded in
|
u32 CmdStateSrv; /* CHANNEL_COMMANDSTATE (overloaded in
|
||||||
* Windows drivers, see ServerStateUp,
|
* Windows drivers, see ServerStateUp,
|
||||||
* ServerStateDown, etc) */
|
* ServerStateDown, etc) */
|
||||||
U32 SrvState; /* CHANNEL_SERVERSTATE */
|
u32 SrvState; /* CHANNEL_SERVERSTATE */
|
||||||
u8 CliErrorBoot; /* bits to indicate err states for
|
u8 CliErrorBoot; /* bits to indicate err states for
|
||||||
* boot clients, so err messages can
|
* boot clients, so err messages can
|
||||||
* be throttled */
|
* be throttled */
|
||||||
|
@ -253,25 +253,25 @@ typedef struct _CHANNEL_HEADER {
|
||||||
/* Subheader for the Signal Type variation of the Common Channel */
|
/* Subheader for the Signal Type variation of the Common Channel */
|
||||||
typedef struct _SIGNAL_QUEUE_HEADER {
|
typedef struct _SIGNAL_QUEUE_HEADER {
|
||||||
/* 1st cache line */
|
/* 1st cache line */
|
||||||
U32 VersionId; /* SIGNAL_QUEUE_HEADER Version ID */
|
u32 VersionId; /* SIGNAL_QUEUE_HEADER Version ID */
|
||||||
U32 Type; /* Queue type: storage, network */
|
u32 Type; /* Queue type: storage, network */
|
||||||
U64 Size; /* Total size of this queue in bytes */
|
U64 Size; /* Total size of this queue in bytes */
|
||||||
U64 oSignalBase; /* Offset to signal queue area */
|
U64 oSignalBase; /* Offset to signal queue area */
|
||||||
U64 FeatureFlags; /* Flags to modify behavior */
|
U64 FeatureFlags; /* Flags to modify behavior */
|
||||||
U64 NumSignalsSent; /* Total # of signals placed in this queue */
|
U64 NumSignalsSent; /* Total # of signals placed in this queue */
|
||||||
U64 NumOverflows; /* Total # of inserts failed due to
|
U64 NumOverflows; /* Total # of inserts failed due to
|
||||||
* full queue */
|
* full queue */
|
||||||
U32 SignalSize; /* Total size of a signal for this queue */
|
u32 SignalSize; /* Total size of a signal for this queue */
|
||||||
U32 MaxSignalSlots; /* Max # of slots in queue, 1 slot is
|
u32 MaxSignalSlots; /* Max # of slots in queue, 1 slot is
|
||||||
* always empty */
|
* always empty */
|
||||||
U32 MaxSignals; /* Max # of signals in queue
|
u32 MaxSignals; /* Max # of signals in queue
|
||||||
* (MaxSignalSlots-1) */
|
* (MaxSignalSlots-1) */
|
||||||
U32 Head; /* Queue head signal # */
|
u32 Head; /* Queue head signal # */
|
||||||
/* 2nd cache line */
|
/* 2nd cache line */
|
||||||
U64 NumSignalsReceived; /* Total # of signals removed from this queue */
|
U64 NumSignalsReceived; /* Total # of signals removed from this queue */
|
||||||
U32 Tail; /* Queue tail signal # (on separate
|
u32 Tail; /* Queue tail signal # (on separate
|
||||||
* cache line) */
|
* cache line) */
|
||||||
U32 Reserved1; /* Reserved field */
|
u32 Reserved1; /* Reserved field */
|
||||||
U64 Reserved2; /* Resrved field */
|
U64 Reserved2; /* Resrved field */
|
||||||
U64 ClientQueue;
|
U64 ClientQueue;
|
||||||
U64 NumInterruptsReceived; /* Total # of Interrupts received. This
|
U64 NumInterruptsReceived; /* Total # of Interrupts received. This
|
||||||
|
@ -280,7 +280,7 @@ typedef struct _SIGNAL_QUEUE_HEADER {
|
||||||
U64 NumEmptyCnt; /* Number of times that visor_signal_remove
|
U64 NumEmptyCnt; /* Number of times that visor_signal_remove
|
||||||
* is called and returned Empty
|
* is called and returned Empty
|
||||||
* Status. */
|
* Status. */
|
||||||
U32 ErrorFlags; /* Error bits set during SignalReinit
|
u32 ErrorFlags; /* Error bits set during SignalReinit
|
||||||
* to denote trouble with client's
|
* to denote trouble with client's
|
||||||
* fields */
|
* fields */
|
||||||
u8 Filler[12]; /* Pad out to 64 byte cacheline */
|
u8 Filler[12]; /* Pad out to 64 byte cacheline */
|
||||||
|
@ -312,7 +312,7 @@ ULTRA_check_channel_client(void __iomem *pChannel,
|
||||||
uuid_le expectedTypeGuid,
|
uuid_le expectedTypeGuid,
|
||||||
char *channelName,
|
char *channelName,
|
||||||
U64 expectedMinBytes,
|
U64 expectedMinBytes,
|
||||||
U32 expectedVersionId,
|
u32 expectedVersionId,
|
||||||
U64 expectedSignature,
|
U64 expectedSignature,
|
||||||
char *fileName, int lineNumber, void *logCtx)
|
char *fileName, int lineNumber, void *logCtx)
|
||||||
{
|
{
|
||||||
|
@ -588,7 +588,7 @@ ULTRA_channel_client_release_os(void __iomem *pChannel, u8 *chanId,
|
||||||
* full.
|
* full.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
unsigned char visor_signal_insert(CHANNEL_HEADER __iomem *pChannel, U32 Queue,
|
unsigned char visor_signal_insert(CHANNEL_HEADER __iomem *pChannel, u32 Queue,
|
||||||
void *pSignal);
|
void *pSignal);
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
@ -610,7 +610,7 @@ unsigned char visor_signal_insert(CHANNEL_HEADER __iomem *pChannel, U32 Queue,
|
||||||
* empty.
|
* empty.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
unsigned char visor_signal_remove(CHANNEL_HEADER __iomem *pChannel, U32 Queue,
|
unsigned char visor_signal_remove(CHANNEL_HEADER __iomem *pChannel, u32 Queue,
|
||||||
void *pSignal);
|
void *pSignal);
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
@ -632,7 +632,7 @@ unsigned char visor_signal_remove(CHANNEL_HEADER __iomem *pChannel, U32 Queue,
|
||||||
* Return value:
|
* Return value:
|
||||||
* # of signals copied.
|
* # of signals copied.
|
||||||
*/
|
*/
|
||||||
unsigned int SignalRemoveAll(pCHANNEL_HEADER pChannel, U32 Queue,
|
unsigned int SignalRemoveAll(pCHANNEL_HEADER pChannel, u32 Queue,
|
||||||
void *pSignal);
|
void *pSignal);
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
@ -647,6 +647,6 @@ unsigned int SignalRemoveAll(pCHANNEL_HEADER pChannel, U32 Queue,
|
||||||
* 1 if the signal queue is empty, 0 otherwise.
|
* 1 if the signal queue is empty, 0 otherwise.
|
||||||
*/
|
*/
|
||||||
unsigned char visor_signalqueue_empty(CHANNEL_HEADER __iomem *pChannel,
|
unsigned char visor_signalqueue_empty(CHANNEL_HEADER __iomem *pChannel,
|
||||||
U32 Queue);
|
u32 Queue);
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -70,7 +70,7 @@ typedef union {
|
||||||
* increment thereafter */
|
* increment thereafter */
|
||||||
u8 Minor;
|
u8 Minor;
|
||||||
u16 Maintenance;
|
u16 Maintenance;
|
||||||
U32 Revision; /* Subversion revision */
|
u32 Revision; /* Subversion revision */
|
||||||
} Part;
|
} Part;
|
||||||
} ULTRA_COMPONENT_VERSION;
|
} ULTRA_COMPONENT_VERSION;
|
||||||
|
|
||||||
|
|
|
@ -137,7 +137,7 @@ struct InterruptInfo {
|
||||||
/**< specifies interrupt vector. It, interrupt pin, and shared are
|
/**< specifies interrupt vector. It, interrupt pin, and shared are
|
||||||
* used to connect to the corresponding interrupt. Used by
|
* used to connect to the corresponding interrupt. Used by
|
||||||
* IOPart-GP only. */
|
* IOPart-GP only. */
|
||||||
U32 recvInterruptVector;
|
u32 recvInterruptVector;
|
||||||
|
|
||||||
/**< specifies if the recvInterrupt is shared. It, interrupt pin
|
/**< specifies if the recvInterrupt is shared. It, interrupt pin
|
||||||
* and vector are used to connect to 0 = not shared; 1 = shared.
|
* and vector are used to connect to 0 = not shared; 1 = shared.
|
||||||
|
@ -159,33 +159,33 @@ struct PciConfigHdr {
|
||||||
u16 SubSysVendor;
|
u16 SubSysVendor;
|
||||||
u16 DeviceId;
|
u16 DeviceId;
|
||||||
u16 SubSysDevice;
|
u16 SubSysDevice;
|
||||||
U32 ClassCode;
|
u32 ClassCode;
|
||||||
U32 Reserved; /* Natural alignment purposes */
|
u32 Reserved; /* Natural alignment purposes */
|
||||||
};
|
};
|
||||||
|
|
||||||
struct ScsiId {
|
struct ScsiId {
|
||||||
U32 Bus;
|
u32 Bus;
|
||||||
U32 Target;
|
u32 Target;
|
||||||
U32 Lun;
|
u32 Lun;
|
||||||
U32 Host; /* Command should ignore this for *
|
u32 Host; /* Command should ignore this for *
|
||||||
* DiskArrival/RemovalEvents */
|
* DiskArrival/RemovalEvents */
|
||||||
};
|
};
|
||||||
|
|
||||||
struct WWID {
|
struct WWID {
|
||||||
U32 wwid1;
|
u32 wwid1;
|
||||||
U32 wwid2;
|
u32 wwid2;
|
||||||
};
|
};
|
||||||
|
|
||||||
struct virtDiskInfo {
|
struct virtDiskInfo {
|
||||||
U32 switchNo; /* defined by SWITCH_CREATE */
|
u32 switchNo; /* defined by SWITCH_CREATE */
|
||||||
U32 externalPortNo; /* 0 for SAS RAID provided (external)
|
u32 externalPortNo; /* 0 for SAS RAID provided (external)
|
||||||
* virtual disks, 1 for virtual disk
|
* virtual disks, 1 for virtual disk
|
||||||
* images, 2 for gold disk images */
|
* images, 2 for gold disk images */
|
||||||
u16 VirtualDiskIndex; /* Index of disk descriptor in the
|
u16 VirtualDiskIndex; /* Index of disk descriptor in the
|
||||||
* VirtualDisk segment associated with
|
* VirtualDisk segment associated with
|
||||||
* externalPortNo */
|
* externalPortNo */
|
||||||
u16 Reserved1;
|
u16 Reserved1;
|
||||||
U32 Reserved2;
|
u32 Reserved2;
|
||||||
};
|
};
|
||||||
|
|
||||||
typedef enum {
|
typedef enum {
|
||||||
|
@ -237,59 +237,59 @@ typedef enum {
|
||||||
* looking at the flags.response field.
|
* looking at the flags.response field.
|
||||||
*/
|
*/
|
||||||
typedef struct _CONTROLVM_MESSAGE_HEADER {
|
typedef struct _CONTROLVM_MESSAGE_HEADER {
|
||||||
U32 Id; /* See CONTROLVM_ID. */
|
u32 Id; /* See CONTROLVM_ID. */
|
||||||
/* For requests, indicates the message type. */
|
/* For requests, indicates the message type. */
|
||||||
/* For responses, indicates the type of message we are responding to. */
|
/* For responses, indicates the type of message we are responding to. */
|
||||||
|
|
||||||
U32 MessageSize; /* Includes size of this struct + size
|
u32 MessageSize; /* Includes size of this struct + size
|
||||||
* of message */
|
* of message */
|
||||||
U32 SegmentIndex; /* Index of segment containing Vm
|
u32 SegmentIndex; /* Index of segment containing Vm
|
||||||
* message/information */
|
* message/information */
|
||||||
U32 CompletionStatus; /* Error status code or result of
|
u32 CompletionStatus; /* Error status code or result of
|
||||||
* message completion */
|
* message completion */
|
||||||
struct {
|
struct {
|
||||||
U32 failed:1; /**< =1 in a response to * signify
|
u32 failed:1; /**< =1 in a response to * signify
|
||||||
* failure */
|
* failure */
|
||||||
U32 responseExpected:1; /**< =1 in all messages that expect a
|
u32 responseExpected:1; /**< =1 in all messages that expect a
|
||||||
* response (Control ignores this
|
* response (Control ignores this
|
||||||
* bit) */
|
* bit) */
|
||||||
U32 server:1; /**< =1 in all bus & device-related
|
u32 server:1; /**< =1 in all bus & device-related
|
||||||
* messages where the message
|
* messages where the message
|
||||||
* receiver is to act as the bus or
|
* receiver is to act as the bus or
|
||||||
* device server */
|
* device server */
|
||||||
U32 testMessage:1; /**< =1 for testing use only
|
u32 testMessage:1; /**< =1 for testing use only
|
||||||
* (Control and Command ignore this
|
* (Control and Command ignore this
|
||||||
* bit) */
|
* bit) */
|
||||||
U32 partialCompletion:1; /**< =1 if there are forthcoming
|
u32 partialCompletion:1; /**< =1 if there are forthcoming
|
||||||
* responses/acks associated
|
* responses/acks associated
|
||||||
* with this message */
|
* with this message */
|
||||||
U32 preserve:1; /**< =1 this is to let us know to
|
u32 preserve:1; /**< =1 this is to let us know to
|
||||||
* preserve channel contents
|
* preserve channel contents
|
||||||
* (for running guests)*/
|
* (for running guests)*/
|
||||||
U32 writerInDiag:1; /**< =1 the DiagWriter is active in the
|
u32 writerInDiag:1; /**< =1 the DiagWriter is active in the
|
||||||
* Diagnostic Partition*/
|
* Diagnostic Partition*/
|
||||||
|
|
||||||
/* remaining bits in this 32-bit word are available */
|
/* remaining bits in this 32-bit word are available */
|
||||||
} Flags;
|
} Flags;
|
||||||
U32 Reserved; /* Natural alignment */
|
u32 Reserved; /* Natural alignment */
|
||||||
U64 MessageHandle; /* Identifies the particular message instance,
|
U64 MessageHandle; /* Identifies the particular message instance,
|
||||||
* and is used to match particular */
|
* and is used to match particular */
|
||||||
/* request instances with the corresponding response instance. */
|
/* request instances with the corresponding response instance. */
|
||||||
U64 PayloadVmOffset; /* Offset of payload area from start of this
|
U64 PayloadVmOffset; /* Offset of payload area from start of this
|
||||||
* instance of ControlVm segment */
|
* instance of ControlVm segment */
|
||||||
U32 PayloadMaxBytes; /* Maximum bytes allocated in payload
|
u32 PayloadMaxBytes; /* Maximum bytes allocated in payload
|
||||||
* area of ControlVm segment */
|
* area of ControlVm segment */
|
||||||
U32 PayloadBytes; /* Actual number of bytes of payload
|
u32 PayloadBytes; /* Actual number of bytes of payload
|
||||||
* area to copy between IO/Command; */
|
* area to copy between IO/Command; */
|
||||||
/* if non-zero, there is a payload to copy. */
|
/* if non-zero, there is a payload to copy. */
|
||||||
} CONTROLVM_MESSAGE_HEADER;
|
} CONTROLVM_MESSAGE_HEADER;
|
||||||
|
|
||||||
typedef struct _CONTROLVM_PACKET_DEVICE_CREATE {
|
typedef struct _CONTROLVM_PACKET_DEVICE_CREATE {
|
||||||
U32 busNo; /**< bus # (0..n-1) from the msg receiver's
|
u32 busNo; /**< bus # (0..n-1) from the msg receiver's
|
||||||
* perspective */
|
* perspective */
|
||||||
|
|
||||||
/* Control uses header SegmentIndex field to access bus number... */
|
/* Control uses header SegmentIndex field to access bus number... */
|
||||||
U32 devNo; /**< bus-relative (0..n-1) device number */
|
u32 devNo; /**< bus-relative (0..n-1) device number */
|
||||||
U64 channelAddr; /**< Guest physical address of the channel, which
|
U64 channelAddr; /**< Guest physical address of the channel, which
|
||||||
* can be dereferenced by the receiver
|
* can be dereferenced by the receiver
|
||||||
* of this ControlVm command */
|
* of this ControlVm command */
|
||||||
|
@ -300,11 +300,11 @@ typedef struct _CONTROLVM_PACKET_DEVICE_CREATE {
|
||||||
} CONTROLVM_PACKET_DEVICE_CREATE; /* for CONTROLVM_DEVICE_CREATE */
|
} CONTROLVM_PACKET_DEVICE_CREATE; /* for CONTROLVM_DEVICE_CREATE */
|
||||||
|
|
||||||
typedef struct _CONTROLVM_PACKET_DEVICE_CONFIGURE {
|
typedef struct _CONTROLVM_PACKET_DEVICE_CONFIGURE {
|
||||||
U32 busNo; /**< bus # (0..n-1) from the msg
|
u32 busNo; /**< bus # (0..n-1) from the msg
|
||||||
* receiver's perspective */
|
* receiver's perspective */
|
||||||
|
|
||||||
/* Control uses header SegmentIndex field to access bus number... */
|
/* Control uses header SegmentIndex field to access bus number... */
|
||||||
U32 devNo; /**< bus-relative (0..n-1) device number */
|
u32 devNo; /**< bus-relative (0..n-1) device number */
|
||||||
} CONTROLVM_PACKET_DEVICE_CONFIGURE; /* for CONTROLVM_DEVICE_CONFIGURE */
|
} CONTROLVM_PACKET_DEVICE_CONFIGURE; /* for CONTROLVM_DEVICE_CONFIGURE */
|
||||||
|
|
||||||
typedef struct _CONTROLVM_MESSAGE_DEVICE_CREATE {
|
typedef struct _CONTROLVM_MESSAGE_DEVICE_CREATE {
|
||||||
|
@ -323,11 +323,11 @@ typedef struct _CONTROLVM_MESSAGE_PACKET {
|
||||||
|
|
||||||
/* BEGIN Request messages */
|
/* BEGIN Request messages */
|
||||||
struct {
|
struct {
|
||||||
U32 busNo; /*< bus # (0..n-1) from the msg
|
u32 busNo; /*< bus # (0..n-1) from the msg
|
||||||
* receiver's perspective */
|
* receiver's perspective */
|
||||||
|
|
||||||
/* Control uses header SegmentIndex field to access bus number... */
|
/* Control uses header SegmentIndex field to access bus number... */
|
||||||
U32 deviceCount; /*< indicates the max number of
|
u32 deviceCount; /*< indicates the max number of
|
||||||
* devices on this bus */
|
* devices on this bus */
|
||||||
U64 channelAddr; /*< Guest physical address of the
|
U64 channelAddr; /*< Guest physical address of the
|
||||||
* channel, which can be
|
* channel, which can be
|
||||||
|
@ -339,19 +339,19 @@ typedef struct _CONTROLVM_MESSAGE_PACKET {
|
||||||
uuid_le busInstGuid; /*< instance guid for the bus */
|
uuid_le busInstGuid; /*< instance guid for the bus */
|
||||||
} createBus; /* for CONTROLVM_BUS_CREATE */
|
} createBus; /* for CONTROLVM_BUS_CREATE */
|
||||||
struct {
|
struct {
|
||||||
U32 busNo; /*< bus # (0..n-1) from the msg
|
u32 busNo; /*< bus # (0..n-1) from the msg
|
||||||
* receiver's perspective */
|
* receiver's perspective */
|
||||||
|
|
||||||
/* Control uses header SegmentIndex field to access bus number... */
|
/* Control uses header SegmentIndex field to access bus number... */
|
||||||
U32 reserved; /* Natural alignment purposes */
|
u32 reserved; /* Natural alignment purposes */
|
||||||
} destroyBus; /* for CONTROLVM_BUS_DESTROY */
|
} destroyBus; /* for CONTROLVM_BUS_DESTROY */
|
||||||
struct {
|
struct {
|
||||||
U32 busNo; /*< bus # (0..n-1) from the
|
u32 busNo; /*< bus # (0..n-1) from the
|
||||||
* msg receiver's
|
* msg receiver's
|
||||||
* perspective */
|
* perspective */
|
||||||
|
|
||||||
/* Control uses header SegmentIndex field to access bus number... */
|
/* Control uses header SegmentIndex field to access bus number... */
|
||||||
U32 reserved1; /* for alignment purposes */
|
u32 reserved1; /* for alignment purposes */
|
||||||
U64 guestHandle; /* This is used to convert
|
U64 guestHandle; /* This is used to convert
|
||||||
* guest physical address to real
|
* guest physical address to real
|
||||||
* physical address for DMA, for ex. */
|
* physical address for DMA, for ex. */
|
||||||
|
@ -368,57 +368,57 @@ typedef struct _CONTROLVM_MESSAGE_PACKET {
|
||||||
/* for CONTROLVM_DEVICE_CREATE */
|
/* for CONTROLVM_DEVICE_CREATE */
|
||||||
CONTROLVM_PACKET_DEVICE_CREATE createDevice;
|
CONTROLVM_PACKET_DEVICE_CREATE createDevice;
|
||||||
struct {
|
struct {
|
||||||
U32 busNo; /*< bus # (0..n-1) from the msg
|
u32 busNo; /*< bus # (0..n-1) from the msg
|
||||||
* receiver's perspective */
|
* receiver's perspective */
|
||||||
|
|
||||||
/* Control uses header SegmentIndex field to access bus number... */
|
/* Control uses header SegmentIndex field to access bus number... */
|
||||||
U32 devNo; /*< bus-relative (0..n-1) device
|
u32 devNo; /*< bus-relative (0..n-1) device
|
||||||
* number */
|
* number */
|
||||||
} destroyDevice; /* for CONTROLVM_DEVICE_DESTROY */
|
} destroyDevice; /* for CONTROLVM_DEVICE_DESTROY */
|
||||||
|
|
||||||
/* for CONTROLVM_DEVICE_CONFIGURE */
|
/* for CONTROLVM_DEVICE_CONFIGURE */
|
||||||
CONTROLVM_PACKET_DEVICE_CONFIGURE configureDevice;
|
CONTROLVM_PACKET_DEVICE_CONFIGURE configureDevice;
|
||||||
struct {
|
struct {
|
||||||
U32 busNo; /*< bus # (0..n-1) from the msg
|
u32 busNo; /*< bus # (0..n-1) from the msg
|
||||||
* receiver's perspective */
|
* receiver's perspective */
|
||||||
|
|
||||||
/* Control uses header SegmentIndex field to access bus number... */
|
/* Control uses header SegmentIndex field to access bus number... */
|
||||||
U32 devNo; /*< bus-relative (0..n-1) device
|
u32 devNo; /*< bus-relative (0..n-1) device
|
||||||
* number */
|
* number */
|
||||||
} reconfigureDevice; /* for CONTROLVM_DEVICE_RECONFIGURE */
|
} reconfigureDevice; /* for CONTROLVM_DEVICE_RECONFIGURE */
|
||||||
struct {
|
struct {
|
||||||
U32 busNo;
|
u32 busNo;
|
||||||
ULTRA_SEGMENT_STATE state;
|
ULTRA_SEGMENT_STATE state;
|
||||||
u8 reserved[2]; /* Natural alignment purposes */
|
u8 reserved[2]; /* Natural alignment purposes */
|
||||||
} busChangeState; /* for CONTROLVM_BUS_CHANGESTATE */
|
} busChangeState; /* for CONTROLVM_BUS_CHANGESTATE */
|
||||||
struct {
|
struct {
|
||||||
U32 busNo;
|
u32 busNo;
|
||||||
U32 devNo;
|
u32 devNo;
|
||||||
ULTRA_SEGMENT_STATE state;
|
ULTRA_SEGMENT_STATE state;
|
||||||
struct {
|
struct {
|
||||||
U32 physicalDevice:1; /* =1 if message is for
|
u32 physicalDevice:1; /* =1 if message is for
|
||||||
* a physical device */
|
* a physical device */
|
||||||
/* remaining bits in this 32-bit word are available */
|
/* remaining bits in this 32-bit word are available */
|
||||||
} flags;
|
} flags;
|
||||||
u8 reserved[2]; /* Natural alignment purposes */
|
u8 reserved[2]; /* Natural alignment purposes */
|
||||||
} deviceChangeState; /* for CONTROLVM_DEVICE_CHANGESTATE */
|
} deviceChangeState; /* for CONTROLVM_DEVICE_CHANGESTATE */
|
||||||
struct {
|
struct {
|
||||||
U32 busNo;
|
u32 busNo;
|
||||||
U32 devNo;
|
u32 devNo;
|
||||||
ULTRA_SEGMENT_STATE state;
|
ULTRA_SEGMENT_STATE state;
|
||||||
u8 reserved[6]; /* Natural alignment purposes */
|
u8 reserved[6]; /* Natural alignment purposes */
|
||||||
} deviceChangeStateEvent; /* for CONTROLVM_DEVICE_CHANGESTATE_EVENT */
|
} deviceChangeStateEvent; /* for CONTROLVM_DEVICE_CHANGESTATE_EVENT */
|
||||||
struct {
|
struct {
|
||||||
U32 busCount; /*< indicates the max number of busses */
|
u32 busCount; /*< indicates the max number of busses */
|
||||||
U32 switchCount; /*< indicates the max number of
|
u32 switchCount; /*< indicates the max number of
|
||||||
* switches (applicable for service
|
* switches (applicable for service
|
||||||
* partition only) */
|
* partition only) */
|
||||||
ULTRA_CHIPSET_FEATURE features;
|
ULTRA_CHIPSET_FEATURE features;
|
||||||
U32 platformNumber; /* Platform Number */
|
u32 platformNumber; /* Platform Number */
|
||||||
} initChipset; /* for CONTROLVM_CHIPSET_INIT */
|
} initChipset; /* for CONTROLVM_CHIPSET_INIT */
|
||||||
struct {
|
struct {
|
||||||
U32 Options; /*< reserved */
|
u32 Options; /*< reserved */
|
||||||
U32 Test; /*< bit 0 set to run embedded selftest */
|
u32 Test; /*< bit 0 set to run embedded selftest */
|
||||||
} chipsetSelftest; /* for CONTROLVM_CHIPSET_SELFTEST */
|
} chipsetSelftest; /* for CONTROLVM_CHIPSET_SELFTEST */
|
||||||
|
|
||||||
/* END Request messages */
|
/* END Request messages */
|
||||||
|
@ -452,8 +452,8 @@ typedef struct _CONTROLVM_MESSAGE {
|
||||||
typedef struct _DEVICE_MAP {
|
typedef struct _DEVICE_MAP {
|
||||||
GUEST_PHYSICAL_ADDRESS DeviceChannelAddress;
|
GUEST_PHYSICAL_ADDRESS DeviceChannelAddress;
|
||||||
U64 DeviceChannelSize;
|
U64 DeviceChannelSize;
|
||||||
U32 CA_Index;
|
u32 CA_Index;
|
||||||
U32 Reserved; /* natural alignment */
|
u32 Reserved; /* natural alignment */
|
||||||
U64 Reserved2; /* Align structure on 32-byte boundary */
|
U64 Reserved2; /* Align structure on 32-byte boundary */
|
||||||
} DEVICE_MAP;
|
} DEVICE_MAP;
|
||||||
|
|
||||||
|
@ -463,8 +463,8 @@ typedef struct _GUEST_DEVICES {
|
||||||
DEVICE_MAP NetworkChannel;
|
DEVICE_MAP NetworkChannel;
|
||||||
DEVICE_MAP StorageChannel;
|
DEVICE_MAP StorageChannel;
|
||||||
DEVICE_MAP ConsoleChannel;
|
DEVICE_MAP ConsoleChannel;
|
||||||
U32 PartitionIndex;
|
u32 PartitionIndex;
|
||||||
U32 Pad;
|
u32 Pad;
|
||||||
} GUEST_DEVICES;
|
} GUEST_DEVICES;
|
||||||
|
|
||||||
typedef struct _ULTRA_CONTROLVM_CHANNEL_PROTOCOL {
|
typedef struct _ULTRA_CONTROLVM_CHANNEL_PROTOCOL {
|
||||||
|
@ -489,13 +489,13 @@ typedef struct _ULTRA_CONTROLVM_CHANNEL_PROTOCOL {
|
||||||
* channel */
|
* channel */
|
||||||
U64 RequestPayloadOffset; /* Offset to request payload area */
|
U64 RequestPayloadOffset; /* Offset to request payload area */
|
||||||
U64 EventPayloadOffset; /* Offset to event payload area */
|
U64 EventPayloadOffset; /* Offset to event payload area */
|
||||||
U32 RequestPayloadBytes; /* Bytes available in request payload
|
u32 RequestPayloadBytes; /* Bytes available in request payload
|
||||||
* area */
|
* area */
|
||||||
U32 EventPayloadBytes; /* Bytes available in event payload area */
|
u32 EventPayloadBytes; /* Bytes available in event payload area */
|
||||||
U32 ControlChannelBytes;
|
u32 ControlChannelBytes;
|
||||||
U32 NvramChannelBytes; /* Bytes in PartitionNvram segment */
|
u32 NvramChannelBytes; /* Bytes in PartitionNvram segment */
|
||||||
U32 MessageBytes; /* sizeof(CONTROLVM_MESSAGE) */
|
u32 MessageBytes; /* sizeof(CONTROLVM_MESSAGE) */
|
||||||
U32 MessageCount; /* CONTROLVM_MESSAGE_MAX */
|
u32 MessageCount; /* CONTROLVM_MESSAGE_MAX */
|
||||||
GUEST_PHYSICAL_ADDRESS gpSmbiosTable; /* guest phys addr of SMBIOS
|
GUEST_PHYSICAL_ADDRESS gpSmbiosTable; /* guest phys addr of SMBIOS
|
||||||
* tables */
|
* tables */
|
||||||
GUEST_PHYSICAL_ADDRESS gpPhysicalSmbiosTable; /* guest phys addr of
|
GUEST_PHYSICAL_ADDRESS gpPhysicalSmbiosTable; /* guest phys addr of
|
||||||
|
@ -525,11 +525,11 @@ typedef struct _ULTRA_CONTROLVM_CHANNEL_PROTOCOL {
|
||||||
* is running in dump mode */
|
* is running in dump mode */
|
||||||
u16 NvramFailCount;
|
u16 NvramFailCount;
|
||||||
u16 SavedCrashMsgCount; /* = CONTROLVM_CRASHMSG_MAX */
|
u16 SavedCrashMsgCount; /* = CONTROLVM_CRASHMSG_MAX */
|
||||||
U32 SavedCrashMsgOffset; /* Offset to request payload area needed
|
u32 SavedCrashMsgOffset; /* Offset to request payload area needed
|
||||||
* for crash dump */
|
* for crash dump */
|
||||||
U32 InstallationError; /* Type of error encountered during
|
u32 InstallationError; /* Type of error encountered during
|
||||||
* installation */
|
* installation */
|
||||||
U32 InstallationTextId; /* Id of string to display */
|
u32 InstallationTextId; /* Id of string to display */
|
||||||
u16 InstallationRemainingSteps; /* Number of remaining installation
|
u16 InstallationRemainingSteps; /* Number of remaining installation
|
||||||
* steps (for progress bars) */
|
* steps (for progress bars) */
|
||||||
u8 ToolAction; /* ULTRA_TOOL_ACTIONS Installation Action
|
u8 ToolAction; /* ULTRA_TOOL_ACTIONS Installation Action
|
||||||
|
@ -537,7 +537,7 @@ typedef struct _ULTRA_CONTROLVM_CHANNEL_PROTOCOL {
|
||||||
u8 Reserved; /* alignment */
|
u8 Reserved; /* alignment */
|
||||||
ULTRA_EFI_SPAR_INDICATION EfiSparIndication;
|
ULTRA_EFI_SPAR_INDICATION EfiSparIndication;
|
||||||
ULTRA_EFI_SPAR_INDICATION EfiSparIndicationSupported;
|
ULTRA_EFI_SPAR_INDICATION EfiSparIndicationSupported;
|
||||||
U32 SPReserved;
|
u32 SPReserved;
|
||||||
u8 Reserved2[28]; /* Force signals to begin on 128-byte cache
|
u8 Reserved2[28]; /* Force signals to begin on 128-byte cache
|
||||||
* line */
|
* line */
|
||||||
SIGNAL_QUEUE_HEADER RequestQueue; /* Service or guest partition
|
SIGNAL_QUEUE_HEADER RequestQueue; /* Service or guest partition
|
||||||
|
@ -600,21 +600,21 @@ typedef struct _ULTRA_CONTROLVM_CHANNEL_PROTOCOL {
|
||||||
* https://ustr-linux-1.na.uis.unisys.com/spar/index.php/ControlVm_Parameters_Area
|
* https://ustr-linux-1.na.uis.unisys.com/spar/index.php/ControlVm_Parameters_Area
|
||||||
*/
|
*/
|
||||||
typedef struct _ULTRA_CONTROLVM_PARAMETERS_HEADER {
|
typedef struct _ULTRA_CONTROLVM_PARAMETERS_HEADER {
|
||||||
U32 TotalLength;
|
u32 TotalLength;
|
||||||
U32 HeaderLength;
|
u32 HeaderLength;
|
||||||
U32 ConnectionOffset;
|
u32 ConnectionOffset;
|
||||||
U32 ConnectionLength;
|
u32 ConnectionLength;
|
||||||
U32 InitiatorOffset;
|
u32 InitiatorOffset;
|
||||||
U32 InitiatorLength;
|
u32 InitiatorLength;
|
||||||
U32 TargetOffset;
|
u32 TargetOffset;
|
||||||
U32 TargetLength;
|
u32 TargetLength;
|
||||||
U32 ClientOffset;
|
u32 ClientOffset;
|
||||||
U32 ClientLength;
|
u32 ClientLength;
|
||||||
U32 NameOffset;
|
u32 NameOffset;
|
||||||
U32 NameLength;
|
u32 NameLength;
|
||||||
uuid_le Id;
|
uuid_le Id;
|
||||||
U32 Revision;
|
u32 Revision;
|
||||||
U32 Reserved; /* Natural alignment */
|
u32 Reserved; /* Natural alignment */
|
||||||
} ULTRA_CONTROLVM_PARAMETERS_HEADER;
|
} ULTRA_CONTROLVM_PARAMETERS_HEADER;
|
||||||
|
|
||||||
#endif /* __CONTROLVMCHANNEL_H__ */
|
#endif /* __CONTROLVMCHANNEL_H__ */
|
||||||
|
|
|
@ -113,7 +113,7 @@ typedef struct _DIAG_EFI_TIME {
|
||||||
u8 Minute; /* 0 - 59 */
|
u8 Minute; /* 0 - 59 */
|
||||||
u8 Second; /* 0 - 59 */
|
u8 Second; /* 0 - 59 */
|
||||||
u8 Pad1;
|
u8 Pad1;
|
||||||
U32 Nanosecond; /* 0 - 999, 999, 999 */
|
u32 Nanosecond; /* 0 - 999, 999, 999 */
|
||||||
S16 TimeZone; /* -1440 to 1440 or 2047 */
|
S16 TimeZone; /* -1440 to 1440 or 2047 */
|
||||||
u8 Daylight;
|
u8 Daylight;
|
||||||
u8 Pad2;
|
u8 Pad2;
|
||||||
|
@ -156,24 +156,24 @@ typedef enum {
|
||||||
* AdditionalInfo: Array of characters for additional event info (may be
|
* AdditionalInfo: Array of characters for additional event info (may be
|
||||||
* empty). */
|
* empty). */
|
||||||
typedef struct _DIAG_CHANNEL_EVENT {
|
typedef struct _DIAG_CHANNEL_EVENT {
|
||||||
U32 EventId;
|
u32 EventId;
|
||||||
U32 Severity;
|
u32 Severity;
|
||||||
u8 ModuleName[MAX_MODULE_NAME_SIZE];
|
u8 ModuleName[MAX_MODULE_NAME_SIZE];
|
||||||
U32 LineNumber;
|
u32 LineNumber;
|
||||||
DIAG_EFI_TIME Timestamp; /* Size = 16 bytes */
|
DIAG_EFI_TIME Timestamp; /* Size = 16 bytes */
|
||||||
U32 PartitionNumber; /* Filled in by Diag Switch as pool blocks are
|
u32 PartitionNumber; /* Filled in by Diag Switch as pool blocks are
|
||||||
* filled */
|
* filled */
|
||||||
u16 VirtualProcessorNumber;
|
u16 VirtualProcessorNumber;
|
||||||
u16 LogicalProcessorNumber;
|
u16 LogicalProcessorNumber;
|
||||||
u8 ComponentType; /* ULTRA_COMPONENT_TYPES */
|
u8 ComponentType; /* ULTRA_COMPONENT_TYPES */
|
||||||
u8 Subsystem;
|
u8 Subsystem;
|
||||||
u16 Reserved0; /* pad to U64 alignment */
|
u16 Reserved0; /* pad to U64 alignment */
|
||||||
U32 BlockNumber; /* filled in by DiagSwitch as pool blocks are
|
u32 BlockNumber; /* filled in by DiagSwitch as pool blocks are
|
||||||
* filled */
|
* filled */
|
||||||
U32 BlockNumberHigh;
|
u32 BlockNumberHigh;
|
||||||
U32 EventNumber; /* filled in by DiagSwitch as pool blocks are
|
u32 EventNumber; /* filled in by DiagSwitch as pool blocks are
|
||||||
* filled */
|
* filled */
|
||||||
U32 EventNumberHigh;
|
u32 EventNumberHigh;
|
||||||
|
|
||||||
/* The BlockNumber and EventNumber fields are set only by DiagSwitch
|
/* The BlockNumber and EventNumber fields are set only by DiagSwitch
|
||||||
* and referenced only by WinDiagDisplay formatting tool as
|
* and referenced only by WinDiagDisplay formatting tool as
|
||||||
|
@ -363,7 +363,7 @@ typedef enum {
|
||||||
* particular subsystem below this level will be discarded.
|
* particular subsystem below this level will be discarded.
|
||||||
*/
|
*/
|
||||||
typedef struct _DIAG_CHANNEL_PROTOCOL_HEADER {
|
typedef struct _DIAG_CHANNEL_PROTOCOL_HEADER {
|
||||||
volatile U32 DiagLock;
|
volatile u32 DiagLock;
|
||||||
u8 IsChannelInitialized;
|
u8 IsChannelInitialized;
|
||||||
u8 Reserved[3];
|
u8 Reserved[3];
|
||||||
u8 SubsystemSeverityFilter[64];
|
u8 SubsystemSeverityFilter[64];
|
||||||
|
|
|
@ -257,28 +257,28 @@ struct guest_phys_info {
|
||||||
#define GPI_ENTRIES_PER_PAGE (PAGE_SIZE / sizeof(struct guest_phys_info))
|
#define GPI_ENTRIES_PER_PAGE (PAGE_SIZE / sizeof(struct guest_phys_info))
|
||||||
|
|
||||||
struct uisscsi_dest {
|
struct uisscsi_dest {
|
||||||
U32 channel; /* channel == bus number */
|
u32 channel; /* channel == bus number */
|
||||||
U32 id; /* id == target number */
|
u32 id; /* id == target number */
|
||||||
U32 lun; /* lun == logical unit number */
|
u32 lun; /* lun == logical unit number */
|
||||||
};
|
};
|
||||||
|
|
||||||
struct vhba_wwnn {
|
struct vhba_wwnn {
|
||||||
U32 wwnn1;
|
u32 wwnn1;
|
||||||
U32 wwnn2;
|
u32 wwnn2;
|
||||||
};
|
};
|
||||||
|
|
||||||
/* WARNING: Values stired in this structure must contain maximum counts (not
|
/* WARNING: Values stired in this structure must contain maximum counts (not
|
||||||
* maximum values). */
|
* maximum values). */
|
||||||
struct vhba_config_max { /* 20 bytes */
|
struct vhba_config_max { /* 20 bytes */
|
||||||
U32 max_channel; /* maximum channel for devices attached to this
|
u32 max_channel; /* maximum channel for devices attached to this
|
||||||
* bus */
|
* bus */
|
||||||
U32 max_id; /* maximum SCSI ID for devices attached to this
|
u32 max_id; /* maximum SCSI ID for devices attached to this
|
||||||
* bus */
|
* bus */
|
||||||
U32 max_lun; /* maximum SCSI LUN for devices attached to this
|
u32 max_lun; /* maximum SCSI LUN for devices attached to this
|
||||||
* bus */
|
* bus */
|
||||||
U32 cmd_per_lun; /* maximum number of outstanding commands per
|
u32 cmd_per_lun; /* maximum number of outstanding commands per
|
||||||
* lun that are allowed at one time */
|
* lun that are allowed at one time */
|
||||||
U32 max_io_size; /* maximum io size for devices attached to this
|
u32 max_io_size; /* maximum io size for devices attached to this
|
||||||
* bus */
|
* bus */
|
||||||
/* max io size is often determined by the resource of the hba. e.g */
|
/* max io size is often determined by the resource of the hba. e.g */
|
||||||
/* max scatter gather list length * page size / sector size */
|
/* max scatter gather list length * page size / sector size */
|
||||||
|
@ -288,7 +288,7 @@ struct uiscmdrsp_scsi {
|
||||||
void *scsicmd; /* the handle to the cmd that was received -
|
void *scsicmd; /* the handle to the cmd that was received -
|
||||||
* send it back as is in the rsp packet. */
|
* send it back as is in the rsp packet. */
|
||||||
u8 cmnd[MAX_CMND_SIZE]; /* the cdb for the command */
|
u8 cmnd[MAX_CMND_SIZE]; /* the cdb for the command */
|
||||||
U32 bufflen; /* length of data to be transferred out or in */
|
u32 bufflen; /* length of data to be transferred out or in */
|
||||||
u16 guest_phys_entries; /* Number of entries in scatter-gather (sg)
|
u16 guest_phys_entries; /* Number of entries in scatter-gather (sg)
|
||||||
* list */
|
* list */
|
||||||
struct guest_phys_info gpi_list[MAX_PHYS_INFO]; /* physical address
|
struct guest_phys_info gpi_list[MAX_PHYS_INFO]; /* physical address
|
||||||
|
@ -492,10 +492,10 @@ struct net_pkt_xmt {
|
||||||
u8 hrawoffv; /* 1 = hwrafoff is valid */
|
u8 hrawoffv; /* 1 = hwrafoff is valid */
|
||||||
u8 nhrawoffv; /* 1 = nhwrafoff is valid */
|
u8 nhrawoffv; /* 1 = nhwrafoff is valid */
|
||||||
u16 protocol; /* specifies packet protocol */
|
u16 protocol; /* specifies packet protocol */
|
||||||
U32 csum; /* value used to set skb->csum at IOPart */
|
u32 csum; /* value used to set skb->csum at IOPart */
|
||||||
U32 hrawoff; /* value used to set skb->h.raw at IOPart */
|
u32 hrawoff; /* value used to set skb->h.raw at IOPart */
|
||||||
/* hrawoff points to the start of the TRANSPORT LAYER HEADER */
|
/* hrawoff points to the start of the TRANSPORT LAYER HEADER */
|
||||||
U32 nhrawoff; /* value used to set skb->nh.raw at IOPart */
|
u32 nhrawoff; /* value used to set skb->nh.raw at IOPart */
|
||||||
/* nhrawoff points to the start of the NETWORK LAYER HEADER */
|
/* nhrawoff points to the start of the NETWORK LAYER HEADER */
|
||||||
} lincsum;
|
} lincsum;
|
||||||
|
|
||||||
|
@ -508,7 +508,7 @@ struct net_pkt_xmt {
|
||||||
};
|
};
|
||||||
|
|
||||||
struct net_pkt_xmtdone {
|
struct net_pkt_xmtdone {
|
||||||
U32 xmt_done_result; /* result of NET_XMIT */
|
u32 xmt_done_result; /* result of NET_XMIT */
|
||||||
#define XMIT_SUCCESS 0
|
#define XMIT_SUCCESS 0
|
||||||
#define XMIT_FAILED 1
|
#define XMIT_FAILED 1
|
||||||
};
|
};
|
||||||
|
@ -538,7 +538,7 @@ struct net_pkt_rcv {
|
||||||
|
|
||||||
/* the number of receive buffers that can be chained */
|
/* the number of receive buffers that can be chained */
|
||||||
/* is based on max mtu and size of each rcv buf */
|
/* is based on max mtu and size of each rcv buf */
|
||||||
U32 rcv_done_len; /* length of received data */
|
u32 rcv_done_len; /* length of received data */
|
||||||
u8 numrcvbufs; /* number of receive buffers that contain the */
|
u8 numrcvbufs; /* number of receive buffers that contain the */
|
||||||
/* incoming data; guest end MUST chain these together. */
|
/* incoming data; guest end MUST chain these together. */
|
||||||
void *rcvbuf[MAX_NET_RCV_CHAIN]; /* the list of receive buffers
|
void *rcvbuf[MAX_NET_RCV_CHAIN]; /* the list of receive buffers
|
||||||
|
@ -546,7 +546,7 @@ struct net_pkt_rcv {
|
||||||
/* each entry is a receive buffer provided by NET_RCV_POST. */
|
/* each entry is a receive buffer provided by NET_RCV_POST. */
|
||||||
/* NOTE: first rcvbuf in the chain will also be provided in net.buf. */
|
/* NOTE: first rcvbuf in the chain will also be provided in net.buf. */
|
||||||
U64 UniqueNum;
|
U64 UniqueNum;
|
||||||
U32 RcvsDroppedDelta;
|
u32 RcvsDroppedDelta;
|
||||||
};
|
};
|
||||||
|
|
||||||
struct net_pkt_enbdis {
|
struct net_pkt_enbdis {
|
||||||
|
@ -618,7 +618,7 @@ struct uiscmdrsp_disknotify {
|
||||||
u8 add; /* 0-remove, 1-add */
|
u8 add; /* 0-remove, 1-add */
|
||||||
void *vHba; /* Pointer to vhba_info for channel info to
|
void *vHba; /* Pointer to vhba_info for channel info to
|
||||||
* route msg */
|
* route msg */
|
||||||
U32 channel, id, lun; /* SCSI Path of Disk to added or removed */
|
u32 channel, id, lun; /* SCSI Path of Disk to added or removed */
|
||||||
};
|
};
|
||||||
|
|
||||||
/* The following is used by virthba/vSCSI to send the Acquire/Release commands
|
/* The following is used by virthba/vSCSI to send the Acquire/Release commands
|
||||||
|
@ -696,8 +696,8 @@ typedef struct _ULTRA_IO_CHANNEL_PROTOCOL {
|
||||||
} vhba; /* 28 */
|
} vhba; /* 28 */
|
||||||
struct {
|
struct {
|
||||||
u8 macaddr[MAX_MACADDR_LEN]; /* 6 bytes */
|
u8 macaddr[MAX_MACADDR_LEN]; /* 6 bytes */
|
||||||
U32 num_rcv_bufs; /* 4 */
|
u32 num_rcv_bufs; /* 4 */
|
||||||
U32 mtu; /* 4 */
|
u32 mtu; /* 4 */
|
||||||
uuid_le zoneGuid; /* 16 */
|
uuid_le zoneGuid; /* 16 */
|
||||||
} vnic; /* total 30 */
|
} vnic; /* total 30 */
|
||||||
};
|
};
|
||||||
|
@ -777,9 +777,9 @@ typedef struct _ULTRA_IO_CHANNEL_PROTOCOL {
|
||||||
OFFSETOF(type, clientString); \
|
OFFSETOF(type, clientString); \
|
||||||
MEMCPY(chan->clientString, clientStr, \
|
MEMCPY(chan->clientString, clientStr, \
|
||||||
MINNUM(clientStrLen, \
|
MINNUM(clientStrLen, \
|
||||||
(U32) (MAX_CLIENTSTRING_LEN - 1))); \
|
(u32) (MAX_CLIENTSTRING_LEN - 1))); \
|
||||||
chan->clientString[MINNUM(clientStrLen, \
|
chan->clientString[MINNUM(clientStrLen, \
|
||||||
(U32) (MAX_CLIENTSTRING_LEN \
|
(u32) (MAX_CLIENTSTRING_LEN \
|
||||||
- 1))] \
|
- 1))] \
|
||||||
= '\0'; \
|
= '\0'; \
|
||||||
} \
|
} \
|
||||||
|
@ -801,7 +801,7 @@ static inline int ULTRA_VHBA_init_channel(ULTRA_IO_CHANNEL_PROTOCOL *x,
|
||||||
struct vhba_wwnn *wwnn,
|
struct vhba_wwnn *wwnn,
|
||||||
struct vhba_config_max *max,
|
struct vhba_config_max *max,
|
||||||
unsigned char *clientStr,
|
unsigned char *clientStr,
|
||||||
U32 clientStrLen, U64 bytes) {
|
u32 clientStrLen, U64 bytes) {
|
||||||
MEMSET(x, 0, sizeof(ULTRA_IO_CHANNEL_PROTOCOL));
|
MEMSET(x, 0, sizeof(ULTRA_IO_CHANNEL_PROTOCOL));
|
||||||
x->ChannelHeader.VersionId = ULTRA_VHBA_CHANNEL_PROTOCOL_VERSIONID;
|
x->ChannelHeader.VersionId = ULTRA_VHBA_CHANNEL_PROTOCOL_VERSIONID;
|
||||||
x->ChannelHeader.Signature = ULTRA_VHBA_CHANNEL_PROTOCOL_SIGNATURE;
|
x->ChannelHeader.Signature = ULTRA_VHBA_CHANNEL_PROTOCOL_SIGNATURE;
|
||||||
|
@ -833,10 +833,10 @@ static inline void ULTRA_VHBA_set_max(ULTRA_IO_CHANNEL_PROTOCOL *x,
|
||||||
|
|
||||||
static inline int ULTRA_VNIC_init_channel(ULTRA_IO_CHANNEL_PROTOCOL *x,
|
static inline int ULTRA_VNIC_init_channel(ULTRA_IO_CHANNEL_PROTOCOL *x,
|
||||||
unsigned char *macaddr,
|
unsigned char *macaddr,
|
||||||
U32 num_rcv_bufs, U32 mtu,
|
u32 num_rcv_bufs, u32 mtu,
|
||||||
uuid_le zoneGuid,
|
uuid_le zoneGuid,
|
||||||
unsigned char *clientStr,
|
unsigned char *clientStr,
|
||||||
U32 clientStrLen,
|
u32 clientStrLen,
|
||||||
U64 bytes) {
|
U64 bytes) {
|
||||||
MEMSET(x, 0, sizeof(ULTRA_IO_CHANNEL_PROTOCOL));
|
MEMSET(x, 0, sizeof(ULTRA_IO_CHANNEL_PROTOCOL));
|
||||||
x->ChannelHeader.VersionId = ULTRA_VNIC_CHANNEL_PROTOCOL_VERSIONID;
|
x->ChannelHeader.VersionId = ULTRA_VNIC_CHANNEL_PROTOCOL_VERSIONID;
|
||||||
|
@ -883,11 +883,11 @@ static inline int ULTRA_VNIC_init_channel(ULTRA_IO_CHANNEL_PROTOCOL *x,
|
||||||
* room)
|
* room)
|
||||||
*/
|
*/
|
||||||
static INLINE u16
|
static INLINE u16
|
||||||
add_physinfo_entries(U32 inp_pfn, /* input - specifies the pfn to be used
|
add_physinfo_entries(u32 inp_pfn, /* input - specifies the pfn to be used
|
||||||
* to add entries */
|
* to add entries */
|
||||||
u16 inp_off, /* input - specifies the off to be used
|
u16 inp_off, /* input - specifies the off to be used
|
||||||
* to add entries */
|
* to add entries */
|
||||||
U32 inp_len, /* input - specifies the len to be used
|
u32 inp_len, /* input - specifies the len to be used
|
||||||
* to add entries */
|
* to add entries */
|
||||||
u16 index, /* input - index in array at which new
|
u16 index, /* input - index in array at which new
|
||||||
* entries are added */
|
* entries are added */
|
||||||
|
@ -896,7 +896,7 @@ add_physinfo_entries(U32 inp_pfn, /* input - specifies the pfn to be used
|
||||||
struct phys_info pi_arr[]) /* input & output - array to
|
struct phys_info pi_arr[]) /* input & output - array to
|
||||||
* which entries are added */
|
* which entries are added */
|
||||||
{
|
{
|
||||||
U32 len;
|
u32 len;
|
||||||
u16 i, firstlen;
|
u16 i, firstlen;
|
||||||
|
|
||||||
firstlen = PI_PAGE_SIZE - inp_off;
|
firstlen = PI_PAGE_SIZE - inp_off;
|
||||||
|
@ -925,7 +925,7 @@ add_physinfo_entries(U32 inp_pfn, /* input - specifies the pfn to be used
|
||||||
else {
|
else {
|
||||||
pi_arr[index + i].pi_off = 0;
|
pi_arr[index + i].pi_off = 0;
|
||||||
pi_arr[index + i].pi_len =
|
pi_arr[index + i].pi_len =
|
||||||
(u16) MINNUM(len, (U32) PI_PAGE_SIZE);
|
(u16) MINNUM(len, (u32) PI_PAGE_SIZE);
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -63,15 +63,15 @@ static const uuid_le UltraVbusChannelProtocolGuid =
|
||||||
|
|
||||||
#pragma pack(push, 1) /* both GCC and VC now allow this pragma */
|
#pragma pack(push, 1) /* both GCC and VC now allow this pragma */
|
||||||
typedef struct _ULTRA_VBUS_HEADERINFO {
|
typedef struct _ULTRA_VBUS_HEADERINFO {
|
||||||
U32 structBytes; /* size of this struct in bytes */
|
u32 structBytes; /* size of this struct in bytes */
|
||||||
U32 deviceInfoStructBytes; /* sizeof(ULTRA_VBUS_DEVICEINFO) */
|
u32 deviceInfoStructBytes; /* sizeof(ULTRA_VBUS_DEVICEINFO) */
|
||||||
U32 devInfoCount; /* num of items in DevInfo member */
|
u32 devInfoCount; /* num of items in DevInfo member */
|
||||||
/* (this is the allocated size) */
|
/* (this is the allocated size) */
|
||||||
U32 chpInfoByteOffset; /* byte offset from beginning of this struct */
|
u32 chpInfoByteOffset; /* byte offset from beginning of this struct */
|
||||||
/* to the the ChpInfo struct (below) */
|
/* to the the ChpInfo struct (below) */
|
||||||
U32 busInfoByteOffset; /* byte offset from beginning of this struct */
|
u32 busInfoByteOffset; /* byte offset from beginning of this struct */
|
||||||
/* to the the BusInfo struct (below) */
|
/* to the the BusInfo struct (below) */
|
||||||
U32 devInfoByteOffset; /* byte offset from beginning of this struct */
|
u32 devInfoByteOffset; /* byte offset from beginning of this struct */
|
||||||
/* to the the DevInfo array (below) */
|
/* to the the DevInfo array (below) */
|
||||||
u8 reserved[104];
|
u8 reserved[104];
|
||||||
} ULTRA_VBUS_HEADERINFO;
|
} ULTRA_VBUS_HEADERINFO;
|
||||||
|
|
|
@ -88,7 +88,7 @@ typedef enum { /* VMCALL identification tuples */
|
||||||
* not used much */
|
* not used much */
|
||||||
#define ISSUE_IO_VMCALL_POSTCODE_SEVERITY(postcode, severity) \
|
#define ISSUE_IO_VMCALL_POSTCODE_SEVERITY(postcode, severity) \
|
||||||
do { \
|
do { \
|
||||||
U32 _tempresult = VMCALL_SUCCESS; \
|
u32 _tempresult = VMCALL_SUCCESS; \
|
||||||
ISSUE_IO_EXTENDED_VMCALL(VMCALL_POST_CODE_LOGEVENT, severity, \
|
ISSUE_IO_EXTENDED_VMCALL(VMCALL_POST_CODE_LOGEVENT, severity, \
|
||||||
MDS_APPOS, postcode, _tempresult); \
|
MDS_APPOS, postcode, _tempresult); \
|
||||||
} while (0)
|
} while (0)
|
||||||
|
@ -119,7 +119,7 @@ typedef struct _VMCALL_IO_CONTROLVM_ADDR_PARAMS {
|
||||||
U64 ChannelAddress; /* contents provided by this VMCALL (OUT) */
|
U64 ChannelAddress; /* contents provided by this VMCALL (OUT) */
|
||||||
/* the size of the ControlVm channel in bytes This VMCall fills this
|
/* the size of the ControlVm channel in bytes This VMCall fills this
|
||||||
* in with the appropriate address. */
|
* in with the appropriate address. */
|
||||||
U32 ChannelBytes; /* contents provided by this VMCALL (OUT) */
|
u32 ChannelBytes; /* contents provided by this VMCALL (OUT) */
|
||||||
u8 Unused[4]; /* Unused Bytes in the 64-Bit Aligned Struct */
|
u8 Unused[4]; /* Unused Bytes in the 64-Bit Aligned Struct */
|
||||||
} VMCALL_IO_CONTROLVM_ADDR_PARAMS;
|
} VMCALL_IO_CONTROLVM_ADDR_PARAMS;
|
||||||
|
|
||||||
|
@ -159,7 +159,7 @@ typedef struct _VMCALL_CHANNEL_VERSION_MISMATCH_PARAMS {
|
||||||
* (IN) */
|
* (IN) */
|
||||||
u8 ItemName[32]; /* Null terminated string giving name of
|
u8 ItemName[32]; /* Null terminated string giving name of
|
||||||
* mismatched item (IN) */
|
* mismatched item (IN) */
|
||||||
U32 SourceLineNumber; /* line# where invoked. (IN) */
|
u32 SourceLineNumber; /* line# where invoked. (IN) */
|
||||||
u8 SourceFileName[36]; /* source code where invoked - Null terminated
|
u8 SourceFileName[36]; /* source code where invoked - Null terminated
|
||||||
* string (IN) */
|
* string (IN) */
|
||||||
} VMCALL_CHANNEL_VERSION_MISMATCH_PARAMS;
|
} VMCALL_CHANNEL_VERSION_MISMATCH_PARAMS;
|
||||||
|
|
|
@ -30,7 +30,6 @@
|
||||||
#include <syslog.h>
|
#include <syslog.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#define U32 uint32_t
|
|
||||||
#define U64 uint64_t
|
#define U64 uint64_t
|
||||||
#define S8 int8_t
|
#define S8 int8_t
|
||||||
#define S16 int16_t
|
#define S16 int16_t
|
||||||
|
@ -40,7 +39,7 @@
|
||||||
#ifdef __KERNEL__
|
#ifdef __KERNEL__
|
||||||
|
|
||||||
#ifdef CONFIG_X86_32
|
#ifdef CONFIG_X86_32
|
||||||
#define UINTN U32
|
#define UINTN u32
|
||||||
#else
|
#else
|
||||||
#define UINTN U64
|
#define UINTN U64
|
||||||
#endif
|
#endif
|
||||||
|
@ -49,7 +48,7 @@
|
||||||
|
|
||||||
#include <stdint.h>
|
#include <stdint.h>
|
||||||
#if __WORDSIZE == 32
|
#if __WORDSIZE == 32
|
||||||
#define UINTN U32
|
#define UINTN u32
|
||||||
#elif __WORDSIZE == 64
|
#elif __WORDSIZE == 64
|
||||||
#define UINTN U64
|
#define UINTN U64
|
||||||
#else
|
#else
|
||||||
|
@ -121,7 +120,7 @@ typedef U64 GUEST_PHYSICAL_ADDRESS;
|
||||||
fil, lin); \
|
fil, lin); \
|
||||||
} while (0)
|
} while (0)
|
||||||
|
|
||||||
#define CHANNEL_U32_MISMATCH(chType, chName, field, expected, actual, fil, \
|
#define CHANNEL_u32_MISMATCH(chType, chName, field, expected, actual, fil, \
|
||||||
lin, logCtx) \
|
lin, logCtx) \
|
||||||
do { \
|
do { \
|
||||||
syslog(LOG_USER | LOG_ERR, \
|
syslog(LOG_USER | LOG_ERR, \
|
||||||
|
|
|
@ -112,7 +112,7 @@ struct extport_info {
|
||||||
/* if 1, indicates this extport slot is occupied
|
/* if 1, indicates this extport slot is occupied
|
||||||
* if 0, indicates that extport slot is unoccupied */
|
* if 0, indicates that extport slot is unoccupied */
|
||||||
|
|
||||||
U32 num_devs_using;
|
u32 num_devs_using;
|
||||||
/* When extport is added, this is set to 0. For exports
|
/* When extport is added, this is set to 0. For exports
|
||||||
* located in NETWORK switches:
|
* located in NETWORK switches:
|
||||||
* Each time a VNIC, i.e., intport, is added to the switch this
|
* Each time a VNIC, i.e., intport, is added to the switch this
|
||||||
|
@ -144,8 +144,8 @@ struct device_info {
|
||||||
char devid[30]; /* "vbus<busno>:dev<devno>" */
|
char devid[30]; /* "vbus<busno>:dev<devno>" */
|
||||||
u16 polling;
|
u16 polling;
|
||||||
struct semaphore interrupt_callback_lock;
|
struct semaphore interrupt_callback_lock;
|
||||||
U32 busNo;
|
u32 busNo;
|
||||||
U32 devNo;
|
u32 devNo;
|
||||||
int (*interrupt)(void *);
|
int (*interrupt)(void *);
|
||||||
void *interrupt_context;
|
void *interrupt_context;
|
||||||
void *private_data;
|
void *private_data;
|
||||||
|
@ -161,7 +161,7 @@ typedef enum {
|
||||||
} SWITCH_TYPE;
|
} SWITCH_TYPE;
|
||||||
|
|
||||||
struct bus_info {
|
struct bus_info {
|
||||||
U32 busNo, deviceCount;
|
u32 busNo, deviceCount;
|
||||||
struct device_info **device;
|
struct device_info **device;
|
||||||
U64 guestHandle, recvBusInterruptHandle;
|
U64 guestHandle, recvBusInterruptHandle;
|
||||||
uuid_le busInstGuid;
|
uuid_le busInstGuid;
|
||||||
|
@ -190,12 +190,12 @@ struct sn_list_entry {
|
||||||
};
|
};
|
||||||
|
|
||||||
struct networkPolicy {
|
struct networkPolicy {
|
||||||
U32 promiscuous:1;
|
u32 promiscuous:1;
|
||||||
U32 macassign:1;
|
u32 macassign:1;
|
||||||
U32 peerforwarding:1;
|
u32 peerforwarding:1;
|
||||||
U32 nonotify:1;
|
u32 nonotify:1;
|
||||||
U32 standby:1;
|
u32 standby:1;
|
||||||
U32 callhome:2;
|
u32 callhome:2;
|
||||||
char ip_addr[30];
|
char ip_addr[30];
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -251,8 +251,8 @@ struct add_virt_iopart {
|
||||||
* needs to use G2G copy. */
|
* needs to use G2G copy. */
|
||||||
u8 Filler[7];
|
u8 Filler[7];
|
||||||
|
|
||||||
U32 busNo;
|
u32 busNo;
|
||||||
U32 devNo;
|
u32 devNo;
|
||||||
char *params;
|
char *params;
|
||||||
ulong params_bytes;
|
ulong params_bytes;
|
||||||
|
|
||||||
|
@ -264,22 +264,22 @@ struct add_vdisk_iopart {
|
||||||
struct uisscsi_dest vdest; /* scsi bus, target, lun for virt disk */
|
struct uisscsi_dest vdest; /* scsi bus, target, lun for virt disk */
|
||||||
struct uisscsi_dest pdest; /* scsi bus, target, lun for phys disk */
|
struct uisscsi_dest pdest; /* scsi bus, target, lun for phys disk */
|
||||||
u8 sernum[MAX_SERIAL_NUM]; /* serial num of physical disk */
|
u8 sernum[MAX_SERIAL_NUM]; /* serial num of physical disk */
|
||||||
U32 serlen; /* length of serial num */
|
u32 serlen; /* length of serial num */
|
||||||
U32 busNo;
|
u32 busNo;
|
||||||
U32 devNo;
|
u32 devNo;
|
||||||
};
|
};
|
||||||
|
|
||||||
struct del_vdisk_iopart {
|
struct del_vdisk_iopart {
|
||||||
void *chanptr; /* pointer to data channel */
|
void *chanptr; /* pointer to data channel */
|
||||||
struct uisscsi_dest vdest; /* scsi bus, target, lun for virt disk */
|
struct uisscsi_dest vdest; /* scsi bus, target, lun for virt disk */
|
||||||
U32 busNo;
|
u32 busNo;
|
||||||
U32 devNo;
|
u32 devNo;
|
||||||
};
|
};
|
||||||
|
|
||||||
struct del_virt_iopart {
|
struct del_virt_iopart {
|
||||||
void *chanptr; /* pointer to data channel */
|
void *chanptr; /* pointer to data channel */
|
||||||
U32 busNo;
|
u32 busNo;
|
||||||
U32 devNo;
|
u32 devNo;
|
||||||
};
|
};
|
||||||
|
|
||||||
struct det_virt_iopart { /* detach internal port */
|
struct det_virt_iopart { /* detach internal port */
|
||||||
|
@ -355,14 +355,14 @@ typedef enum {
|
||||||
struct add_vbus_guestpart {
|
struct add_vbus_guestpart {
|
||||||
void __iomem *chanptr; /* pointer to data channel for bus -
|
void __iomem *chanptr; /* pointer to data channel for bus -
|
||||||
* NOT YET USED */
|
* NOT YET USED */
|
||||||
U32 busNo; /* bus number to be created/deleted */
|
u32 busNo; /* bus number to be created/deleted */
|
||||||
U32 deviceCount; /* max num of devices on bus */
|
u32 deviceCount; /* max num of devices on bus */
|
||||||
uuid_le busTypeGuid; /* indicates type of bus */
|
uuid_le busTypeGuid; /* indicates type of bus */
|
||||||
uuid_le busInstGuid; /* instance guid for device */
|
uuid_le busInstGuid; /* instance guid for device */
|
||||||
};
|
};
|
||||||
|
|
||||||
struct del_vbus_guestpart {
|
struct del_vbus_guestpart {
|
||||||
U32 busNo; /* bus number to be deleted */
|
u32 busNo; /* bus number to be deleted */
|
||||||
/* once we start using the bus's channel, add can dump busNo
|
/* once we start using the bus's channel, add can dump busNo
|
||||||
* into the channel header and then delete will need only one
|
* into the channel header and then delete will need only one
|
||||||
* parameter, chanptr. */
|
* parameter, chanptr. */
|
||||||
|
@ -370,8 +370,8 @@ struct del_vbus_guestpart {
|
||||||
|
|
||||||
struct add_virt_guestpart {
|
struct add_virt_guestpart {
|
||||||
void __iomem *chanptr; /* pointer to data channel */
|
void __iomem *chanptr; /* pointer to data channel */
|
||||||
U32 busNo; /* bus number for the operation */
|
u32 busNo; /* bus number for the operation */
|
||||||
U32 deviceNo; /* number of device on the bus */
|
u32 deviceNo; /* number of device on the bus */
|
||||||
uuid_le devInstGuid; /* instance guid for device */
|
uuid_le devInstGuid; /* instance guid for device */
|
||||||
struct InterruptInfo intr; /* recv/send interrupt info */
|
struct InterruptInfo intr; /* recv/send interrupt info */
|
||||||
/* recvInterruptHandle contains info needed in order to
|
/* recvInterruptHandle contains info needed in order to
|
||||||
|
@ -395,8 +395,8 @@ struct del_virt_guestpart {
|
||||||
};
|
};
|
||||||
|
|
||||||
struct init_chipset_guestpart {
|
struct init_chipset_guestpart {
|
||||||
U32 busCount; /* indicates the max number of busses */
|
u32 busCount; /* indicates the max number of busses */
|
||||||
U32 switchCount; /* indicates the max number of switches */
|
u32 switchCount; /* indicates the max number of switches */
|
||||||
};
|
};
|
||||||
|
|
||||||
struct guest_msgs {
|
struct guest_msgs {
|
||||||
|
|
|
@ -60,7 +60,7 @@ typedef struct ReqHandlerInfo_struct {
|
||||||
unsigned long min_channel_bytes;
|
unsigned long min_channel_bytes;
|
||||||
int (*Server_Channel_Ok)(unsigned long channelBytes);
|
int (*Server_Channel_Ok)(unsigned long channelBytes);
|
||||||
int (*Server_Channel_Init)
|
int (*Server_Channel_Init)
|
||||||
(void *x, unsigned char *clientStr, U32 clientStrLen, U64 bytes);
|
(void *x, unsigned char *clientStr, u32 clientStrLen, U64 bytes);
|
||||||
char switch_type_name[99];
|
char switch_type_name[99];
|
||||||
struct list_head list_link; /* links into ReqHandlerInfo_list */
|
struct list_head list_link; /* links into ReqHandlerInfo_list */
|
||||||
} ReqHandlerInfo_t;
|
} ReqHandlerInfo_t;
|
||||||
|
@ -73,7 +73,7 @@ ReqHandlerInfo_t *ReqHandlerAdd(uuid_le switchTypeGuid,
|
||||||
channelBytes),
|
channelBytes),
|
||||||
int (*Server_Channel_Init)
|
int (*Server_Channel_Init)
|
||||||
(void *x, unsigned char *clientStr,
|
(void *x, unsigned char *clientStr,
|
||||||
U32 clientStrLen, U64 bytes));
|
u32 clientStrLen, U64 bytes));
|
||||||
ReqHandlerInfo_t *ReqHandlerFind(uuid_le switchTypeGuid);
|
ReqHandlerInfo_t *ReqHandlerFind(uuid_le switchTypeGuid);
|
||||||
int ReqHandlerDel(uuid_le switchTypeGuid);
|
int ReqHandlerDel(uuid_le switchTypeGuid);
|
||||||
|
|
||||||
|
@ -121,7 +121,7 @@ int uisctrl_register_req_handler_ex(uuid_le switchTypeGuid,
|
||||||
channelBytes),
|
channelBytes),
|
||||||
int (*Server_Channel_Init)
|
int (*Server_Channel_Init)
|
||||||
(void *x, unsigned char *clientStr,
|
(void *x, unsigned char *clientStr,
|
||||||
U32 clientStrLen, U64 bytes),
|
u32 clientStrLen, U64 bytes),
|
||||||
ULTRA_VBUS_DEVICEINFO *chipset_DriverInfo);
|
ULTRA_VBUS_DEVICEINFO *chipset_DriverInfo);
|
||||||
|
|
||||||
int uisctrl_unregister_req_handler_ex(uuid_le switchTypeGuid);
|
int uisctrl_unregister_req_handler_ex(uuid_le switchTypeGuid);
|
||||||
|
@ -129,29 +129,29 @@ unsigned char *util_map_virt(struct phys_info *sg);
|
||||||
void util_unmap_virt(struct phys_info *sg);
|
void util_unmap_virt(struct phys_info *sg);
|
||||||
unsigned char *util_map_virt_atomic(struct phys_info *sg);
|
unsigned char *util_map_virt_atomic(struct phys_info *sg);
|
||||||
void util_unmap_virt_atomic(void *buf);
|
void util_unmap_virt_atomic(void *buf);
|
||||||
int uislib_server_inject_add_vnic(U32 switchNo, U32 BusNo, U32 numIntPorts,
|
int uislib_server_inject_add_vnic(u32 switchNo, u32 BusNo, u32 numIntPorts,
|
||||||
U32 numExtPorts, MACARRAY pmac[],
|
u32 numExtPorts, MACARRAY pmac[],
|
||||||
pCHANNEL_HEADER **chan);
|
pCHANNEL_HEADER **chan);
|
||||||
void uislib_server_inject_del_vnic(U32 switchNo, U32 busNo, U32 numIntPorts,
|
void uislib_server_inject_del_vnic(u32 switchNo, u32 busNo, u32 numIntPorts,
|
||||||
U32 numExtPorts);
|
u32 numExtPorts);
|
||||||
int uislib_client_inject_add_bus(U32 busNo, uuid_le instGuid,
|
int uislib_client_inject_add_bus(u32 busNo, uuid_le instGuid,
|
||||||
U64 channelAddr, ulong nChannelBytes);
|
U64 channelAddr, ulong nChannelBytes);
|
||||||
int uislib_client_inject_del_bus(U32 busNo);
|
int uislib_client_inject_del_bus(u32 busNo);
|
||||||
|
|
||||||
int uislib_client_inject_add_vhba(U32 busNo, U32 devNo,
|
int uislib_client_inject_add_vhba(u32 busNo, u32 devNo,
|
||||||
U64 phys_chan_addr, U32 chan_bytes,
|
U64 phys_chan_addr, u32 chan_bytes,
|
||||||
int is_test_addr, uuid_le instGuid,
|
int is_test_addr, uuid_le instGuid,
|
||||||
struct InterruptInfo *intr);
|
struct InterruptInfo *intr);
|
||||||
int uislib_client_inject_pause_vhba(U32 busNo, U32 devNo);
|
int uislib_client_inject_pause_vhba(u32 busNo, u32 devNo);
|
||||||
int uislib_client_inject_resume_vhba(U32 busNo, U32 devNo);
|
int uislib_client_inject_resume_vhba(u32 busNo, u32 devNo);
|
||||||
int uislib_client_inject_del_vhba(U32 busNo, U32 devNo);
|
int uislib_client_inject_del_vhba(u32 busNo, u32 devNo);
|
||||||
int uislib_client_inject_add_vnic(U32 busNo, U32 devNo,
|
int uislib_client_inject_add_vnic(u32 busNo, u32 devNo,
|
||||||
U64 phys_chan_addr, U32 chan_bytes,
|
U64 phys_chan_addr, u32 chan_bytes,
|
||||||
int is_test_addr, uuid_le instGuid,
|
int is_test_addr, uuid_le instGuid,
|
||||||
struct InterruptInfo *intr);
|
struct InterruptInfo *intr);
|
||||||
int uislib_client_inject_pause_vnic(U32 busNo, U32 devNo);
|
int uislib_client_inject_pause_vnic(u32 busNo, u32 devNo);
|
||||||
int uislib_client_inject_resume_vnic(U32 busNo, U32 devNo);
|
int uislib_client_inject_resume_vnic(u32 busNo, u32 devNo);
|
||||||
int uislib_client_inject_del_vnic(U32 busNo, U32 devNo);
|
int uislib_client_inject_del_vnic(u32 busNo, u32 devNo);
|
||||||
#ifdef STORAGE_CHANNEL
|
#ifdef STORAGE_CHANNEL
|
||||||
U64 uislib_storage_channel(int client_id);
|
U64 uislib_storage_channel(int client_id);
|
||||||
#endif
|
#endif
|
||||||
|
@ -220,7 +220,7 @@ unsigned int uisutil_copy_fragsinfo_from_skb(unsigned char *calling_ctx,
|
||||||
struct phys_info frags[]);
|
struct phys_info frags[]);
|
||||||
|
|
||||||
static inline unsigned int
|
static inline unsigned int
|
||||||
Issue_VMCALL_IO_CONTROLVM_ADDR(U64 *ControlAddress, U32 *ControlBytes)
|
Issue_VMCALL_IO_CONTROLVM_ADDR(U64 *ControlAddress, u32 *ControlBytes)
|
||||||
{
|
{
|
||||||
VMCALL_IO_CONTROLVM_ADDR_PARAMS params;
|
VMCALL_IO_CONTROLVM_ADDR_PARAMS params;
|
||||||
int result = VMCALL_SUCCESS;
|
int result = VMCALL_SUCCESS;
|
||||||
|
@ -300,7 +300,7 @@ static inline int Issue_VMCALL_UPDATE_PHYSICAL_TIME(U64 adjustment)
|
||||||
static inline unsigned int
|
static inline unsigned int
|
||||||
Issue_VMCALL_CHANNEL_MISMATCH(const char *ChannelName,
|
Issue_VMCALL_CHANNEL_MISMATCH(const char *ChannelName,
|
||||||
const char *ItemName,
|
const char *ItemName,
|
||||||
U32 SourceLineNumber, const char *path_n_fn)
|
u32 SourceLineNumber, const char *path_n_fn)
|
||||||
{
|
{
|
||||||
VMCALL_CHANNEL_VERSION_MISMATCH_PARAMS params;
|
VMCALL_CHANNEL_VERSION_MISMATCH_PARAMS params;
|
||||||
int result = VMCALL_SUCCESS;
|
int result = VMCALL_SUCCESS;
|
||||||
|
@ -347,10 +347,10 @@ void uislib_cache_free(struct kmem_cache *cur_pool, void *p, char *fn, int ln);
|
||||||
#define UISCACHEFREE(cur_pool, p) \
|
#define UISCACHEFREE(cur_pool, p) \
|
||||||
uislib_cache_free(cur_pool, p, __FILE__, __LINE__)
|
uislib_cache_free(cur_pool, p, __FILE__, __LINE__)
|
||||||
|
|
||||||
void uislib_enable_channel_interrupts(U32 busNo, U32 devNo,
|
void uislib_enable_channel_interrupts(u32 busNo, u32 devNo,
|
||||||
int (*interrupt)(void *),
|
int (*interrupt)(void *),
|
||||||
void *interrupt_context);
|
void *interrupt_context);
|
||||||
void uislib_disable_channel_interrupts(U32 busNo, U32 devNo);
|
void uislib_disable_channel_interrupts(u32 busNo, u32 devNo);
|
||||||
void uislib_force_channel_interrupt(U32 busNo, U32 devNo);
|
void uislib_force_channel_interrupt(u32 busNo, u32 devNo);
|
||||||
|
|
||||||
#endif /* __UISUTILS__H__ */
|
#endif /* __UISUTILS__H__ */
|
||||||
|
|
|
@ -120,7 +120,7 @@ static const struct file_operations debugfs_info_fops = {
|
||||||
};
|
};
|
||||||
|
|
||||||
static void
|
static void
|
||||||
init_msg_header(CONTROLVM_MESSAGE *msg, U32 id, uint rsp, uint svr)
|
init_msg_header(CONTROLVM_MESSAGE *msg, u32 id, uint rsp, uint svr)
|
||||||
{
|
{
|
||||||
memset(msg, 0, sizeof(CONTROLVM_MESSAGE));
|
memset(msg, 0, sizeof(CONTROLVM_MESSAGE));
|
||||||
msg->hdr.Id = id;
|
msg->hdr.Id = id;
|
||||||
|
@ -129,7 +129,7 @@ init_msg_header(CONTROLVM_MESSAGE *msg, U32 id, uint rsp, uint svr)
|
||||||
}
|
}
|
||||||
|
|
||||||
static __iomem void *
|
static __iomem void *
|
||||||
init_vbus_channel(U64 channelAddr, U32 channelBytes)
|
init_vbus_channel(U64 channelAddr, u32 channelBytes)
|
||||||
{
|
{
|
||||||
void __iomem *rc = NULL;
|
void __iomem *rc = NULL;
|
||||||
void __iomem *pChan = uislib_ioremap_cache(channelAddr, channelBytes);
|
void __iomem *pChan = uislib_ioremap_cache(channelAddr, channelBytes);
|
||||||
|
@ -154,7 +154,7 @@ Away:
|
||||||
static int
|
static int
|
||||||
create_bus(CONTROLVM_MESSAGE *msg, char *buf)
|
create_bus(CONTROLVM_MESSAGE *msg, char *buf)
|
||||||
{
|
{
|
||||||
U32 busNo, deviceCount;
|
u32 busNo, deviceCount;
|
||||||
struct bus_info *tmp, *bus;
|
struct bus_info *tmp, *bus;
|
||||||
size_t size;
|
size_t size;
|
||||||
|
|
||||||
|
@ -273,7 +273,7 @@ destroy_bus(CONTROLVM_MESSAGE *msg, char *buf)
|
||||||
{
|
{
|
||||||
int i;
|
int i;
|
||||||
struct bus_info *bus, *prev = NULL;
|
struct bus_info *bus, *prev = NULL;
|
||||||
U32 busNo;
|
u32 busNo;
|
||||||
|
|
||||||
busNo = msg->cmd.destroyBus.busNo;
|
busNo = msg->cmd.destroyBus.busNo;
|
||||||
|
|
||||||
|
@ -341,7 +341,7 @@ create_device(CONTROLVM_MESSAGE *msg, char *buf)
|
||||||
{
|
{
|
||||||
struct device_info *dev;
|
struct device_info *dev;
|
||||||
struct bus_info *bus;
|
struct bus_info *bus;
|
||||||
U32 busNo, devNo;
|
u32 busNo, devNo;
|
||||||
int result = CONTROLVM_RESP_SUCCESS;
|
int result = CONTROLVM_RESP_SUCCESS;
|
||||||
U64 minSize = MIN_IO_CHANNEL_SIZE;
|
U64 minSize = MIN_IO_CHANNEL_SIZE;
|
||||||
ReqHandlerInfo_t *pReqHandler;
|
ReqHandlerInfo_t *pReqHandler;
|
||||||
|
@ -535,7 +535,7 @@ Away:
|
||||||
static int
|
static int
|
||||||
pause_device(CONTROLVM_MESSAGE *msg)
|
pause_device(CONTROLVM_MESSAGE *msg)
|
||||||
{
|
{
|
||||||
U32 busNo, devNo;
|
u32 busNo, devNo;
|
||||||
struct bus_info *bus;
|
struct bus_info *bus;
|
||||||
struct device_info *dev;
|
struct device_info *dev;
|
||||||
struct guest_msgs cmd;
|
struct guest_msgs cmd;
|
||||||
|
@ -607,7 +607,7 @@ pause_device(CONTROLVM_MESSAGE *msg)
|
||||||
static int
|
static int
|
||||||
resume_device(CONTROLVM_MESSAGE *msg)
|
resume_device(CONTROLVM_MESSAGE *msg)
|
||||||
{
|
{
|
||||||
U32 busNo, devNo;
|
u32 busNo, devNo;
|
||||||
struct bus_info *bus;
|
struct bus_info *bus;
|
||||||
struct device_info *dev;
|
struct device_info *dev;
|
||||||
struct guest_msgs cmd;
|
struct guest_msgs cmd;
|
||||||
|
@ -679,7 +679,7 @@ resume_device(CONTROLVM_MESSAGE *msg)
|
||||||
static int
|
static int
|
||||||
destroy_device(CONTROLVM_MESSAGE *msg, char *buf)
|
destroy_device(CONTROLVM_MESSAGE *msg, char *buf)
|
||||||
{
|
{
|
||||||
U32 busNo, devNo;
|
u32 busNo, devNo;
|
||||||
struct bus_info *bus;
|
struct bus_info *bus;
|
||||||
struct device_info *dev;
|
struct device_info *dev;
|
||||||
struct guest_msgs cmd;
|
struct guest_msgs cmd;
|
||||||
|
@ -791,7 +791,7 @@ init_chipset(CONTROLVM_MESSAGE *msg, char *buf)
|
||||||
}
|
}
|
||||||
|
|
||||||
static int
|
static int
|
||||||
delete_bus_glue(U32 busNo)
|
delete_bus_glue(u32 busNo)
|
||||||
{
|
{
|
||||||
CONTROLVM_MESSAGE msg;
|
CONTROLVM_MESSAGE msg;
|
||||||
|
|
||||||
|
@ -805,7 +805,7 @@ delete_bus_glue(U32 busNo)
|
||||||
}
|
}
|
||||||
|
|
||||||
static int
|
static int
|
||||||
delete_device_glue(U32 busNo, U32 devNo)
|
delete_device_glue(u32 busNo, u32 devNo)
|
||||||
{
|
{
|
||||||
CONTROLVM_MESSAGE msg;
|
CONTROLVM_MESSAGE msg;
|
||||||
|
|
||||||
|
@ -821,7 +821,7 @@ delete_device_glue(U32 busNo, U32 devNo)
|
||||||
}
|
}
|
||||||
|
|
||||||
int
|
int
|
||||||
uislib_client_inject_add_bus(U32 busNo, uuid_le instGuid,
|
uislib_client_inject_add_bus(u32 busNo, uuid_le instGuid,
|
||||||
U64 channelAddr, ulong nChannelBytes)
|
U64 channelAddr, ulong nChannelBytes)
|
||||||
{
|
{
|
||||||
CONTROLVM_MESSAGE msg;
|
CONTROLVM_MESSAGE msg;
|
||||||
|
@ -872,14 +872,14 @@ EXPORT_SYMBOL_GPL(uislib_client_inject_add_bus);
|
||||||
|
|
||||||
|
|
||||||
int
|
int
|
||||||
uislib_client_inject_del_bus(U32 busNo)
|
uislib_client_inject_del_bus(u32 busNo)
|
||||||
{
|
{
|
||||||
return delete_bus_glue(busNo);
|
return delete_bus_glue(busNo);
|
||||||
}
|
}
|
||||||
EXPORT_SYMBOL_GPL(uislib_client_inject_del_bus);
|
EXPORT_SYMBOL_GPL(uislib_client_inject_del_bus);
|
||||||
|
|
||||||
int
|
int
|
||||||
uislib_client_inject_pause_vhba(U32 busNo, U32 devNo)
|
uislib_client_inject_pause_vhba(u32 busNo, u32 devNo)
|
||||||
{
|
{
|
||||||
CONTROLVM_MESSAGE msg;
|
CONTROLVM_MESSAGE msg;
|
||||||
int rc;
|
int rc;
|
||||||
|
@ -899,7 +899,7 @@ uislib_client_inject_pause_vhba(U32 busNo, U32 devNo)
|
||||||
EXPORT_SYMBOL_GPL(uislib_client_inject_pause_vhba);
|
EXPORT_SYMBOL_GPL(uislib_client_inject_pause_vhba);
|
||||||
|
|
||||||
int
|
int
|
||||||
uislib_client_inject_resume_vhba(U32 busNo, U32 devNo)
|
uislib_client_inject_resume_vhba(u32 busNo, u32 devNo)
|
||||||
{
|
{
|
||||||
CONTROLVM_MESSAGE msg;
|
CONTROLVM_MESSAGE msg;
|
||||||
int rc;
|
int rc;
|
||||||
|
@ -920,8 +920,8 @@ uislib_client_inject_resume_vhba(U32 busNo, U32 devNo)
|
||||||
EXPORT_SYMBOL_GPL(uislib_client_inject_resume_vhba);
|
EXPORT_SYMBOL_GPL(uislib_client_inject_resume_vhba);
|
||||||
|
|
||||||
int
|
int
|
||||||
uislib_client_inject_add_vhba(U32 busNo, U32 devNo,
|
uislib_client_inject_add_vhba(u32 busNo, u32 devNo,
|
||||||
U64 phys_chan_addr, U32 chan_bytes,
|
U64 phys_chan_addr, u32 chan_bytes,
|
||||||
int is_test_addr, uuid_le instGuid,
|
int is_test_addr, uuid_le instGuid,
|
||||||
struct InterruptInfo *intr)
|
struct InterruptInfo *intr)
|
||||||
{
|
{
|
||||||
|
@ -972,15 +972,15 @@ uislib_client_inject_add_vhba(U32 busNo, U32 devNo,
|
||||||
EXPORT_SYMBOL_GPL(uislib_client_inject_add_vhba);
|
EXPORT_SYMBOL_GPL(uislib_client_inject_add_vhba);
|
||||||
|
|
||||||
int
|
int
|
||||||
uislib_client_inject_del_vhba(U32 busNo, U32 devNo)
|
uislib_client_inject_del_vhba(u32 busNo, u32 devNo)
|
||||||
{
|
{
|
||||||
return delete_device_glue(busNo, devNo);
|
return delete_device_glue(busNo, devNo);
|
||||||
}
|
}
|
||||||
EXPORT_SYMBOL_GPL(uislib_client_inject_del_vhba);
|
EXPORT_SYMBOL_GPL(uislib_client_inject_del_vhba);
|
||||||
|
|
||||||
int
|
int
|
||||||
uislib_client_inject_add_vnic(U32 busNo, U32 devNo,
|
uislib_client_inject_add_vnic(u32 busNo, u32 devNo,
|
||||||
U64 phys_chan_addr, U32 chan_bytes,
|
U64 phys_chan_addr, u32 chan_bytes,
|
||||||
int is_test_addr, uuid_le instGuid,
|
int is_test_addr, uuid_le instGuid,
|
||||||
struct InterruptInfo *intr)
|
struct InterruptInfo *intr)
|
||||||
{
|
{
|
||||||
|
@ -1032,7 +1032,7 @@ uislib_client_inject_add_vnic(U32 busNo, U32 devNo,
|
||||||
EXPORT_SYMBOL_GPL(uislib_client_inject_add_vnic);
|
EXPORT_SYMBOL_GPL(uislib_client_inject_add_vnic);
|
||||||
|
|
||||||
int
|
int
|
||||||
uislib_client_inject_pause_vnic(U32 busNo, U32 devNo)
|
uislib_client_inject_pause_vnic(u32 busNo, u32 devNo)
|
||||||
{
|
{
|
||||||
CONTROLVM_MESSAGE msg;
|
CONTROLVM_MESSAGE msg;
|
||||||
int rc;
|
int rc;
|
||||||
|
@ -1052,7 +1052,7 @@ uislib_client_inject_pause_vnic(U32 busNo, U32 devNo)
|
||||||
EXPORT_SYMBOL_GPL(uislib_client_inject_pause_vnic);
|
EXPORT_SYMBOL_GPL(uislib_client_inject_pause_vnic);
|
||||||
|
|
||||||
int
|
int
|
||||||
uislib_client_inject_resume_vnic(U32 busNo, U32 devNo)
|
uislib_client_inject_resume_vnic(u32 busNo, u32 devNo)
|
||||||
{
|
{
|
||||||
CONTROLVM_MESSAGE msg;
|
CONTROLVM_MESSAGE msg;
|
||||||
int rc;
|
int rc;
|
||||||
|
@ -1073,14 +1073,14 @@ uislib_client_inject_resume_vnic(U32 busNo, U32 devNo)
|
||||||
EXPORT_SYMBOL_GPL(uislib_client_inject_resume_vnic);
|
EXPORT_SYMBOL_GPL(uislib_client_inject_resume_vnic);
|
||||||
|
|
||||||
int
|
int
|
||||||
uislib_client_inject_del_vnic(U32 busNo, U32 devNo)
|
uislib_client_inject_del_vnic(u32 busNo, u32 devNo)
|
||||||
{
|
{
|
||||||
return delete_device_glue(busNo, devNo);
|
return delete_device_glue(busNo, devNo);
|
||||||
}
|
}
|
||||||
EXPORT_SYMBOL_GPL(uislib_client_inject_del_vnic);
|
EXPORT_SYMBOL_GPL(uislib_client_inject_del_vnic);
|
||||||
|
|
||||||
static int
|
static int
|
||||||
uislib_client_add_vnic(U32 busNo)
|
uislib_client_add_vnic(u32 busNo)
|
||||||
{
|
{
|
||||||
BOOL busCreated = FALSE;
|
BOOL busCreated = FALSE;
|
||||||
int devNo = 0; /* Default to 0, since only one device
|
int devNo = 0; /* Default to 0, since only one device
|
||||||
|
@ -1129,7 +1129,7 @@ AwayCleanup:
|
||||||
EXPORT_SYMBOL_GPL(uislib_client_add_vnic);
|
EXPORT_SYMBOL_GPL(uislib_client_add_vnic);
|
||||||
|
|
||||||
static int
|
static int
|
||||||
uislib_client_delete_vnic(U32 busNo)
|
uislib_client_delete_vnic(u32 busNo)
|
||||||
{
|
{
|
||||||
int devNo = 0; /* Default to 0, since only one device
|
int devNo = 0; /* Default to 0, since only one device
|
||||||
* will be created for this bus... */
|
* will be created for this bus... */
|
||||||
|
@ -1285,7 +1285,7 @@ info_debugfs_read(struct file *file, char __user *buf,
|
||||||
}
|
}
|
||||||
|
|
||||||
static struct device_info *
|
static struct device_info *
|
||||||
find_dev(U32 busNo, U32 devNo)
|
find_dev(u32 busNo, u32 devNo)
|
||||||
{
|
{
|
||||||
struct bus_info *bus;
|
struct bus_info *bus;
|
||||||
struct device_info *dev = NULL;
|
struct device_info *dev = NULL;
|
||||||
|
@ -1458,7 +1458,7 @@ Initialize_incoming_thread(void)
|
||||||
* function.
|
* function.
|
||||||
*/
|
*/
|
||||||
void
|
void
|
||||||
uislib_enable_channel_interrupts(U32 busNo, U32 devNo,
|
uislib_enable_channel_interrupts(u32 busNo, u32 devNo,
|
||||||
int (*interrupt)(void *),
|
int (*interrupt)(void *),
|
||||||
void *interrupt_context)
|
void *interrupt_context)
|
||||||
{
|
{
|
||||||
|
@ -1484,7 +1484,7 @@ EXPORT_SYMBOL_GPL(uislib_enable_channel_interrupts);
|
||||||
* Process_Incoming().
|
* Process_Incoming().
|
||||||
*/
|
*/
|
||||||
void
|
void
|
||||||
uislib_disable_channel_interrupts(U32 busNo, U32 devNo)
|
uislib_disable_channel_interrupts(u32 busNo, u32 devNo)
|
||||||
{
|
{
|
||||||
struct device_info *dev;
|
struct device_info *dev;
|
||||||
dev = find_dev(busNo, devNo);
|
dev = find_dev(busNo, devNo);
|
||||||
|
@ -1517,7 +1517,7 @@ static DECLARE_WORK(Work_wakeup_polling_device_channels,
|
||||||
* your device might have more requests.
|
* your device might have more requests.
|
||||||
*/
|
*/
|
||||||
void
|
void
|
||||||
uislib_force_channel_interrupt(U32 busNo, U32 devNo)
|
uislib_force_channel_interrupt(u32 busNo, u32 devNo)
|
||||||
{
|
{
|
||||||
if (en_smart_wakeup == 0)
|
if (en_smart_wakeup == 0)
|
||||||
return;
|
return;
|
||||||
|
|
|
@ -112,7 +112,7 @@ uisctrl_register_req_handler_ex(uuid_le switchTypeGuid,
|
||||||
channelBytes),
|
channelBytes),
|
||||||
int (*Server_Channel_Init)
|
int (*Server_Channel_Init)
|
||||||
(void *x, unsigned char *clientStr,
|
(void *x, unsigned char *clientStr,
|
||||||
U32 clientStrLen, U64 bytes),
|
u32 clientStrLen, U64 bytes),
|
||||||
ULTRA_VBUS_DEVICEINFO *chipset_DriverInfo)
|
ULTRA_VBUS_DEVICEINFO *chipset_DriverInfo)
|
||||||
{
|
{
|
||||||
ReqHandlerInfo_t *pReqHandlerInfo;
|
ReqHandlerInfo_t *pReqHandlerInfo;
|
||||||
|
@ -279,7 +279,7 @@ ReqHandlerAdd(uuid_le switchTypeGuid,
|
||||||
unsigned long min_channel_bytes,
|
unsigned long min_channel_bytes,
|
||||||
int (*Server_Channel_Ok)(unsigned long channelBytes),
|
int (*Server_Channel_Ok)(unsigned long channelBytes),
|
||||||
int (*Server_Channel_Init)
|
int (*Server_Channel_Init)
|
||||||
(void *x, unsigned char *clientStr, U32 clientStrLen, U64 bytes))
|
(void *x, unsigned char *clientStr, u32 clientStrLen, U64 bytes))
|
||||||
{
|
{
|
||||||
ReqHandlerInfo_t *rc = NULL;
|
ReqHandlerInfo_t *rc = NULL;
|
||||||
|
|
||||||
|
|
|
@ -160,8 +160,8 @@ struct scsipending {
|
||||||
#define VIRTHBA_ERROR_COUNT 30
|
#define VIRTHBA_ERROR_COUNT 30
|
||||||
#define IOS_ERROR_THRESHOLD 1000
|
#define IOS_ERROR_THRESHOLD 1000
|
||||||
struct virtdisk_info {
|
struct virtdisk_info {
|
||||||
U32 valid;
|
u32 valid;
|
||||||
U32 channel, id, lun; /* Disk Path */
|
u32 channel, id, lun; /* Disk Path */
|
||||||
atomic_t ios_threshold;
|
atomic_t ios_threshold;
|
||||||
atomic_t error_count;
|
atomic_t error_count;
|
||||||
struct virtdisk_info *next;
|
struct virtdisk_info *next;
|
||||||
|
@ -198,7 +198,7 @@ struct virthba_info {
|
||||||
struct diskaddremove {
|
struct diskaddremove {
|
||||||
u8 add; /* 0-remove, 1-add */
|
u8 add; /* 0-remove, 1-add */
|
||||||
struct Scsi_Host *shost; /* Scsi Host for this virthba instance */
|
struct Scsi_Host *shost; /* Scsi Host for this virthba instance */
|
||||||
U32 channel, id, lun; /* Disk Path */
|
u32 channel, id, lun; /* Disk Path */
|
||||||
struct diskaddremove *next;
|
struct diskaddremove *next;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -58,8 +58,8 @@ struct virtpci_dev {
|
||||||
* this device */
|
* this device */
|
||||||
unsigned short vendor; /* vendor id for device */
|
unsigned short vendor; /* vendor id for device */
|
||||||
unsigned short device; /* device id for device */
|
unsigned short device; /* device id for device */
|
||||||
U32 busNo; /* number of bus on which device exists */
|
u32 busNo; /* number of bus on which device exists */
|
||||||
U32 deviceNo; /* device's number on the bus */
|
u32 deviceNo; /* device's number on the bus */
|
||||||
struct InterruptInfo intr; /* interrupt info */
|
struct InterruptInfo intr; /* interrupt info */
|
||||||
struct device generic_dev; /* generic device */
|
struct device generic_dev; /* generic device */
|
||||||
union {
|
union {
|
||||||
|
|
|
@ -56,10 +56,10 @@ int visorchannel_write(VISORCHANNEL *channel, ulong offset,
|
||||||
void *local, ulong nbytes);
|
void *local, ulong nbytes);
|
||||||
int visorchannel_clear(VISORCHANNEL *channel, ulong offset,
|
int visorchannel_clear(VISORCHANNEL *channel, ulong offset,
|
||||||
u8 ch, ulong nbytes);
|
u8 ch, ulong nbytes);
|
||||||
BOOL visorchannel_signalremove(VISORCHANNEL *channel, U32 queue, void *msg);
|
BOOL visorchannel_signalremove(VISORCHANNEL *channel, u32 queue, void *msg);
|
||||||
BOOL visorchannel_signalinsert(VISORCHANNEL *channel, U32 queue, void *msg);
|
BOOL visorchannel_signalinsert(VISORCHANNEL *channel, u32 queue, void *msg);
|
||||||
int visorchannel_signalqueue_slots_avail(VISORCHANNEL *channel, U32 queue);
|
int visorchannel_signalqueue_slots_avail(VISORCHANNEL *channel, u32 queue);
|
||||||
int visorchannel_signalqueue_max_slots(VISORCHANNEL *channel, U32 queue);
|
int visorchannel_signalqueue_max_slots(VISORCHANNEL *channel, u32 queue);
|
||||||
|
|
||||||
HOSTADDRESS visorchannel_get_physaddr(VISORCHANNEL *channel);
|
HOSTADDRESS visorchannel_get_physaddr(VISORCHANNEL *channel);
|
||||||
ulong visorchannel_get_nbytes(VISORCHANNEL *channel);
|
ulong visorchannel_get_nbytes(VISORCHANNEL *channel);
|
||||||
|
@ -70,7 +70,7 @@ uuid_le visorchannel_get_uuid(VISORCHANNEL *channel);
|
||||||
MEMREGION *visorchannel_get_memregion(VISORCHANNEL *channel);
|
MEMREGION *visorchannel_get_memregion(VISORCHANNEL *channel);
|
||||||
char *visorchannel_uuid_id(uuid_le *guid, char *s);
|
char *visorchannel_uuid_id(uuid_le *guid, char *s);
|
||||||
void visorchannel_debug(VISORCHANNEL *channel, int nQueues,
|
void visorchannel_debug(VISORCHANNEL *channel, int nQueues,
|
||||||
struct seq_file *seq, U32 off);
|
struct seq_file *seq, u32 off);
|
||||||
void visorchannel_dump_section(VISORCHANNEL *chan, char *s,
|
void visorchannel_dump_section(VISORCHANNEL *chan, char *s,
|
||||||
int off, int len, struct seq_file *seq);
|
int off, int len, struct seq_file *seq);
|
||||||
void __iomem *visorchannel_get_header(VISORCHANNEL *channel);
|
void __iomem *visorchannel_get_header(VISORCHANNEL *channel);
|
||||||
|
|
|
@ -310,7 +310,7 @@ EXPORT_SYMBOL_GPL(visorchannel_get_header);
|
||||||
sizeof((sig_hdr)->FIELD)) >= 0)
|
sizeof((sig_hdr)->FIELD)) >= 0)
|
||||||
|
|
||||||
static BOOL
|
static BOOL
|
||||||
sig_read_header(VISORCHANNEL *channel, U32 queue,
|
sig_read_header(VISORCHANNEL *channel, u32 queue,
|
||||||
SIGNAL_QUEUE_HEADER *sig_hdr)
|
SIGNAL_QUEUE_HEADER *sig_hdr)
|
||||||
{
|
{
|
||||||
BOOL rc = FALSE;
|
BOOL rc = FALSE;
|
||||||
|
@ -336,8 +336,8 @@ Away:
|
||||||
}
|
}
|
||||||
|
|
||||||
static BOOL
|
static BOOL
|
||||||
sig_do_data(VISORCHANNEL *channel, U32 queue,
|
sig_do_data(VISORCHANNEL *channel, u32 queue,
|
||||||
SIGNAL_QUEUE_HEADER *sig_hdr, U32 slot, void *data, BOOL is_write)
|
SIGNAL_QUEUE_HEADER *sig_hdr, u32 slot, void *data, BOOL is_write)
|
||||||
{
|
{
|
||||||
BOOL rc = FALSE;
|
BOOL rc = FALSE;
|
||||||
int signal_data_offset = SIG_DATA_OFFSET(&channel->chan_hdr, queue,
|
int signal_data_offset = SIG_DATA_OFFSET(&channel->chan_hdr, queue,
|
||||||
|
@ -362,15 +362,15 @@ Away:
|
||||||
}
|
}
|
||||||
|
|
||||||
static inline BOOL
|
static inline BOOL
|
||||||
sig_read_data(VISORCHANNEL *channel, U32 queue,
|
sig_read_data(VISORCHANNEL *channel, u32 queue,
|
||||||
SIGNAL_QUEUE_HEADER *sig_hdr, U32 slot, void *data)
|
SIGNAL_QUEUE_HEADER *sig_hdr, u32 slot, void *data)
|
||||||
{
|
{
|
||||||
return sig_do_data(channel, queue, sig_hdr, slot, data, FALSE);
|
return sig_do_data(channel, queue, sig_hdr, slot, data, FALSE);
|
||||||
}
|
}
|
||||||
|
|
||||||
static inline BOOL
|
static inline BOOL
|
||||||
sig_write_data(VISORCHANNEL *channel, U32 queue,
|
sig_write_data(VISORCHANNEL *channel, u32 queue,
|
||||||
SIGNAL_QUEUE_HEADER *sig_hdr, U32 slot, void *data)
|
SIGNAL_QUEUE_HEADER *sig_hdr, u32 slot, void *data)
|
||||||
{
|
{
|
||||||
return sig_do_data(channel, queue, sig_hdr, slot, data, TRUE);
|
return sig_do_data(channel, queue, sig_hdr, slot, data, TRUE);
|
||||||
}
|
}
|
||||||
|
@ -378,7 +378,7 @@ sig_write_data(VISORCHANNEL *channel, U32 queue,
|
||||||
static inline unsigned char
|
static inline unsigned char
|
||||||
safe_sig_queue_validate(pSIGNAL_QUEUE_HEADER psafe_sqh,
|
safe_sig_queue_validate(pSIGNAL_QUEUE_HEADER psafe_sqh,
|
||||||
pSIGNAL_QUEUE_HEADER punsafe_sqh,
|
pSIGNAL_QUEUE_HEADER punsafe_sqh,
|
||||||
U32 *phead, U32 *ptail)
|
u32 *phead, u32 *ptail)
|
||||||
{
|
{
|
||||||
if ((*phead >= psafe_sqh->MaxSignalSlots)
|
if ((*phead >= psafe_sqh->MaxSignalSlots)
|
||||||
|| (*ptail >= psafe_sqh->MaxSignalSlots)) {
|
|| (*ptail >= psafe_sqh->MaxSignalSlots)) {
|
||||||
|
@ -398,7 +398,7 @@ safe_sig_queue_validate(pSIGNAL_QUEUE_HEADER psafe_sqh,
|
||||||
} /* end safe_sig_queue_validate */
|
} /* end safe_sig_queue_validate */
|
||||||
|
|
||||||
BOOL
|
BOOL
|
||||||
visorchannel_signalremove(VISORCHANNEL *channel, U32 queue, void *msg)
|
visorchannel_signalremove(VISORCHANNEL *channel, u32 queue, void *msg)
|
||||||
{
|
{
|
||||||
BOOL rc = FALSE;
|
BOOL rc = FALSE;
|
||||||
SIGNAL_QUEUE_HEADER sig_hdr;
|
SIGNAL_QUEUE_HEADER sig_hdr;
|
||||||
|
@ -444,7 +444,7 @@ Away:
|
||||||
EXPORT_SYMBOL_GPL(visorchannel_signalremove);
|
EXPORT_SYMBOL_GPL(visorchannel_signalremove);
|
||||||
|
|
||||||
BOOL
|
BOOL
|
||||||
visorchannel_signalinsert(VISORCHANNEL *channel, U32 queue, void *msg)
|
visorchannel_signalinsert(VISORCHANNEL *channel, u32 queue, void *msg)
|
||||||
{
|
{
|
||||||
BOOL rc = FALSE;
|
BOOL rc = FALSE;
|
||||||
SIGNAL_QUEUE_HEADER sig_hdr;
|
SIGNAL_QUEUE_HEADER sig_hdr;
|
||||||
|
@ -498,11 +498,11 @@ EXPORT_SYMBOL_GPL(visorchannel_signalinsert);
|
||||||
|
|
||||||
|
|
||||||
int
|
int
|
||||||
visorchannel_signalqueue_slots_avail(VISORCHANNEL *channel, U32 queue)
|
visorchannel_signalqueue_slots_avail(VISORCHANNEL *channel, u32 queue)
|
||||||
{
|
{
|
||||||
SIGNAL_QUEUE_HEADER sig_hdr;
|
SIGNAL_QUEUE_HEADER sig_hdr;
|
||||||
U32 slots_avail, slots_used;
|
u32 slots_avail, slots_used;
|
||||||
U32 head, tail;
|
u32 head, tail;
|
||||||
|
|
||||||
if (!sig_read_header(channel, queue, &sig_hdr))
|
if (!sig_read_header(channel, queue, &sig_hdr))
|
||||||
return 0;
|
return 0;
|
||||||
|
@ -517,7 +517,7 @@ visorchannel_signalqueue_slots_avail(VISORCHANNEL *channel, U32 queue)
|
||||||
EXPORT_SYMBOL_GPL(visorchannel_signalqueue_slots_avail);
|
EXPORT_SYMBOL_GPL(visorchannel_signalqueue_slots_avail);
|
||||||
|
|
||||||
int
|
int
|
||||||
visorchannel_signalqueue_max_slots(VISORCHANNEL *channel, U32 queue)
|
visorchannel_signalqueue_max_slots(VISORCHANNEL *channel, u32 queue)
|
||||||
{
|
{
|
||||||
SIGNAL_QUEUE_HEADER sig_hdr;
|
SIGNAL_QUEUE_HEADER sig_hdr;
|
||||||
if (!sig_read_header(channel, queue, &sig_hdr))
|
if (!sig_read_header(channel, queue, &sig_hdr))
|
||||||
|
@ -552,7 +552,7 @@ sigqueue_debug(SIGNAL_QUEUE_HEADER *q, int which, struct seq_file *seq)
|
||||||
|
|
||||||
void
|
void
|
||||||
visorchannel_debug(VISORCHANNEL *channel, int nQueues,
|
visorchannel_debug(VISORCHANNEL *channel, int nQueues,
|
||||||
struct seq_file *seq, U32 off)
|
struct seq_file *seq, u32 off)
|
||||||
{
|
{
|
||||||
HOSTADDRESS addr = 0;
|
HOSTADDRESS addr = 0;
|
||||||
ulong nbytes = 0, nbytes_region = 0;
|
ulong nbytes = 0, nbytes_region = 0;
|
||||||
|
|
|
@ -41,7 +41,7 @@ struct PARSER_CONTEXT_Tag {
|
||||||
};
|
};
|
||||||
|
|
||||||
static PARSER_CONTEXT *
|
static PARSER_CONTEXT *
|
||||||
parser_init_guts(U64 addr, U32 bytes, BOOL isLocal,
|
parser_init_guts(U64 addr, u32 bytes, BOOL isLocal,
|
||||||
BOOL hasStandardPayloadHeader, BOOL *tryAgain)
|
BOOL hasStandardPayloadHeader, BOOL *tryAgain)
|
||||||
{
|
{
|
||||||
int allocbytes = sizeof(PARSER_CONTEXT) + bytes;
|
int allocbytes = sizeof(PARSER_CONTEXT) + bytes;
|
||||||
|
@ -152,7 +152,7 @@ Away:
|
||||||
}
|
}
|
||||||
|
|
||||||
PARSER_CONTEXT *
|
PARSER_CONTEXT *
|
||||||
parser_init(U64 addr, U32 bytes, BOOL isLocal, BOOL *tryAgain)
|
parser_init(U64 addr, u32 bytes, BOOL isLocal, BOOL *tryAgain)
|
||||||
{
|
{
|
||||||
return parser_init_guts(addr, bytes, isLocal, TRUE, tryAgain);
|
return parser_init_guts(addr, bytes, isLocal, TRUE, tryAgain);
|
||||||
}
|
}
|
||||||
|
@ -163,7 +163,7 @@ parser_init(U64 addr, U32 bytes, BOOL isLocal, BOOL *tryAgain)
|
||||||
* parser_byteStream_get() to obtain the data.
|
* parser_byteStream_get() to obtain the data.
|
||||||
*/
|
*/
|
||||||
PARSER_CONTEXT *
|
PARSER_CONTEXT *
|
||||||
parser_init_byteStream(U64 addr, U32 bytes, BOOL isLocal, BOOL *tryAgain)
|
parser_init_byteStream(U64 addr, u32 bytes, BOOL isLocal, BOOL *tryAgain)
|
||||||
{
|
{
|
||||||
return parser_init_guts(addr, bytes, isLocal, FALSE, tryAgain);
|
return parser_init_guts(addr, bytes, isLocal, FALSE, tryAgain);
|
||||||
}
|
}
|
||||||
|
|
|
@ -33,8 +33,8 @@ typedef enum {
|
||||||
|
|
||||||
typedef struct PARSER_CONTEXT_Tag PARSER_CONTEXT;
|
typedef struct PARSER_CONTEXT_Tag PARSER_CONTEXT;
|
||||||
|
|
||||||
PARSER_CONTEXT *parser_init(U64 addr, U32 bytes, BOOL isLocal, BOOL *tryAgain);
|
PARSER_CONTEXT *parser_init(U64 addr, u32 bytes, BOOL isLocal, BOOL *tryAgain);
|
||||||
PARSER_CONTEXT *parser_init_byteStream(U64 addr, U32 bytes, BOOL isLocal,
|
PARSER_CONTEXT *parser_init_byteStream(U64 addr, u32 bytes, BOOL isLocal,
|
||||||
BOOL *tryAgain);
|
BOOL *tryAgain);
|
||||||
void parser_param_start(PARSER_CONTEXT *ctx, PARSER_WHICH_STRING which_string);
|
void parser_param_start(PARSER_CONTEXT *ctx, PARSER_WHICH_STRING which_string);
|
||||||
void *parser_param_get(PARSER_CONTEXT *ctx, char *nam, int namesize);
|
void *parser_param_get(PARSER_CONTEXT *ctx, char *nam, int namesize);
|
||||||
|
|
|
@ -32,10 +32,10 @@
|
||||||
* been received for a bus or device.
|
* been received for a bus or device.
|
||||||
*/
|
*/
|
||||||
typedef struct {
|
typedef struct {
|
||||||
U32 created:1;
|
u32 created:1;
|
||||||
U32 attached:1;
|
u32 attached:1;
|
||||||
U32 configured:1;
|
u32 configured:1;
|
||||||
U32 running:1;
|
u32 running:1;
|
||||||
/* Add new fields above. */
|
/* Add new fields above. */
|
||||||
/* Remaining bits in this 32-bit word are unused. */
|
/* Remaining bits in this 32-bit word are unused. */
|
||||||
} VISORCHIPSET_STATE;
|
} VISORCHIPSET_STATE;
|
||||||
|
@ -77,15 +77,15 @@ typedef struct {
|
||||||
*/
|
*/
|
||||||
typedef struct {
|
typedef struct {
|
||||||
struct list_head entry;
|
struct list_head entry;
|
||||||
U32 busNo;
|
u32 busNo;
|
||||||
U32 devNo;
|
u32 devNo;
|
||||||
uuid_le devInstGuid;
|
uuid_le devInstGuid;
|
||||||
VISORCHIPSET_STATE state;
|
VISORCHIPSET_STATE state;
|
||||||
VISORCHIPSET_CHANNEL_INFO chanInfo;
|
VISORCHIPSET_CHANNEL_INFO chanInfo;
|
||||||
U32 Reserved1; /* CONTROLVM_ID */
|
u32 Reserved1; /* CONTROLVM_ID */
|
||||||
U64 Reserved2;
|
U64 Reserved2;
|
||||||
U32 switchNo; /* when devState.attached==1 */
|
u32 switchNo; /* when devState.attached==1 */
|
||||||
U32 internalPortNo; /* when devState.attached==1 */
|
u32 internalPortNo; /* when devState.attached==1 */
|
||||||
CONTROLVM_MESSAGE_HEADER pendingMsgHdr; /* CONTROLVM_MESSAGE */
|
CONTROLVM_MESSAGE_HEADER pendingMsgHdr; /* CONTROLVM_MESSAGE */
|
||||||
/** For private use by the bus driver */
|
/** For private use by the bus driver */
|
||||||
void *bus_driver_context;
|
void *bus_driver_context;
|
||||||
|
@ -93,7 +93,7 @@ typedef struct {
|
||||||
} VISORCHIPSET_DEVICE_INFO;
|
} VISORCHIPSET_DEVICE_INFO;
|
||||||
|
|
||||||
static inline VISORCHIPSET_DEVICE_INFO *
|
static inline VISORCHIPSET_DEVICE_INFO *
|
||||||
finddevice(struct list_head *list, U32 busNo, U32 devNo)
|
finddevice(struct list_head *list, u32 busNo, u32 devNo)
|
||||||
{
|
{
|
||||||
VISORCHIPSET_DEVICE_INFO *p;
|
VISORCHIPSET_DEVICE_INFO *p;
|
||||||
|
|
||||||
|
@ -104,7 +104,7 @@ finddevice(struct list_head *list, U32 busNo, U32 devNo)
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
static inline void delbusdevices(struct list_head *list, U32 busNo)
|
static inline void delbusdevices(struct list_head *list, u32 busNo)
|
||||||
{
|
{
|
||||||
VISORCHIPSET_DEVICE_INFO *p, *tmp;
|
VISORCHIPSET_DEVICE_INFO *p, *tmp;
|
||||||
|
|
||||||
|
@ -124,7 +124,7 @@ static inline void delbusdevices(struct list_head *list, U32 busNo)
|
||||||
*/
|
*/
|
||||||
typedef struct {
|
typedef struct {
|
||||||
struct list_head entry;
|
struct list_head entry;
|
||||||
U32 busNo;
|
u32 busNo;
|
||||||
VISORCHIPSET_STATE state;
|
VISORCHIPSET_STATE state;
|
||||||
VISORCHIPSET_CHANNEL_INFO chanInfo;
|
VISORCHIPSET_CHANNEL_INFO chanInfo;
|
||||||
uuid_le partitionGuid;
|
uuid_le partitionGuid;
|
||||||
|
@ -132,10 +132,10 @@ typedef struct {
|
||||||
u8 *name; /* UTF8 */
|
u8 *name; /* UTF8 */
|
||||||
u8 *description; /* UTF8 */
|
u8 *description; /* UTF8 */
|
||||||
U64 Reserved1;
|
U64 Reserved1;
|
||||||
U32 Reserved2;
|
u32 Reserved2;
|
||||||
MYPROCOBJECT *procObject;
|
MYPROCOBJECT *procObject;
|
||||||
struct {
|
struct {
|
||||||
U32 server:1;
|
u32 server:1;
|
||||||
/* Add new fields above. */
|
/* Add new fields above. */
|
||||||
/* Remaining bits in this 32-bit word are unused. */
|
/* Remaining bits in this 32-bit word are unused. */
|
||||||
} flags;
|
} flags;
|
||||||
|
@ -147,7 +147,7 @@ typedef struct {
|
||||||
} VISORCHIPSET_BUS_INFO;
|
} VISORCHIPSET_BUS_INFO;
|
||||||
|
|
||||||
static inline VISORCHIPSET_BUS_INFO *
|
static inline VISORCHIPSET_BUS_INFO *
|
||||||
findbus(struct list_head *list, U32 busNo)
|
findbus(struct list_head *list, u32 busNo)
|
||||||
{
|
{
|
||||||
VISORCHIPSET_BUS_INFO *p;
|
VISORCHIPSET_BUS_INFO *p;
|
||||||
|
|
||||||
|
@ -161,7 +161,7 @@ findbus(struct list_head *list, U32 busNo)
|
||||||
/** Attributes for a particular Supervisor switch.
|
/** Attributes for a particular Supervisor switch.
|
||||||
*/
|
*/
|
||||||
typedef struct {
|
typedef struct {
|
||||||
U32 switchNo;
|
u32 switchNo;
|
||||||
VISORCHIPSET_STATE state;
|
VISORCHIPSET_STATE state;
|
||||||
uuid_le switchTypeGuid;
|
uuid_le switchTypeGuid;
|
||||||
u8 *authService1;
|
u8 *authService1;
|
||||||
|
@ -169,7 +169,7 @@ typedef struct {
|
||||||
u8 *authService3;
|
u8 *authService3;
|
||||||
u8 *securityContext;
|
u8 *securityContext;
|
||||||
U64 Reserved;
|
U64 Reserved;
|
||||||
U32 Reserved2; /* CONTROLVM_ID */
|
u32 Reserved2; /* CONTROLVM_ID */
|
||||||
struct device dev;
|
struct device dev;
|
||||||
BOOL dev_exists;
|
BOOL dev_exists;
|
||||||
CONTROLVM_MESSAGE_HEADER pendingMsgHdr;
|
CONTROLVM_MESSAGE_HEADER pendingMsgHdr;
|
||||||
|
@ -180,8 +180,8 @@ typedef struct {
|
||||||
* to a specific switch.
|
* to a specific switch.
|
||||||
*/
|
*/
|
||||||
typedef struct {
|
typedef struct {
|
||||||
U32 switchNo;
|
u32 switchNo;
|
||||||
U32 externalPortNo;
|
u32 externalPortNo;
|
||||||
VISORCHIPSET_STATE state;
|
VISORCHIPSET_STATE state;
|
||||||
uuid_le networkZoneGuid;
|
uuid_le networkZoneGuid;
|
||||||
int pdPort;
|
int pdPort;
|
||||||
|
@ -192,7 +192,7 @@ typedef struct {
|
||||||
u8 *ipGateway;
|
u8 *ipGateway;
|
||||||
u8 *ipDNS;
|
u8 *ipDNS;
|
||||||
U64 Reserved1;
|
U64 Reserved1;
|
||||||
U32 Reserved2; /* CONTROLVM_ID */
|
u32 Reserved2; /* CONTROLVM_ID */
|
||||||
struct device dev;
|
struct device dev;
|
||||||
BOOL dev_exists;
|
BOOL dev_exists;
|
||||||
CONTROLVM_MESSAGE_HEADER pendingMsgHdr;
|
CONTROLVM_MESSAGE_HEADER pendingMsgHdr;
|
||||||
|
@ -203,13 +203,13 @@ typedef struct {
|
||||||
* device connects to a particular switch.
|
* device connects to a particular switch.
|
||||||
*/
|
*/
|
||||||
typedef struct {
|
typedef struct {
|
||||||
U32 switchNo;
|
u32 switchNo;
|
||||||
U32 internalPortNo;
|
u32 internalPortNo;
|
||||||
VISORCHIPSET_STATE state;
|
VISORCHIPSET_STATE state;
|
||||||
U32 busNo; /* valid only when state.attached == 1 */
|
u32 busNo; /* valid only when state.attached == 1 */
|
||||||
U32 devNo; /* valid only when state.attached == 1 */
|
u32 devNo; /* valid only when state.attached == 1 */
|
||||||
U64 Reserved1;
|
U64 Reserved1;
|
||||||
U32 Reserved2; /* CONTROLVM_ID */
|
u32 Reserved2; /* CONTROLVM_ID */
|
||||||
CONTROLVM_MESSAGE_HEADER pendingMsgHdr;
|
CONTROLVM_MESSAGE_HEADER pendingMsgHdr;
|
||||||
MYPROCOBJECT *procObject;
|
MYPROCOBJECT *procObject;
|
||||||
|
|
||||||
|
|
|
@ -107,7 +107,7 @@ typedef struct {
|
||||||
u8 __iomem *ptr; /* pointer to base address of payload pool */
|
u8 __iomem *ptr; /* pointer to base address of payload pool */
|
||||||
U64 offset; /* offset from beginning of controlvm
|
U64 offset; /* offset from beginning of controlvm
|
||||||
* channel to beginning of payload * pool */
|
* channel to beginning of payload * pool */
|
||||||
U32 bytes; /* number of bytes in payload pool */
|
u32 bytes; /* number of bytes in payload pool */
|
||||||
} CONTROLVM_PAYLOAD_INFO;
|
} CONTROLVM_PAYLOAD_INFO;
|
||||||
|
|
||||||
/* Manages the request payload in the controlvm channel */
|
/* Manages the request payload in the controlvm channel */
|
||||||
|
@ -695,7 +695,7 @@ controlvm_init_response(CONTROLVM_MESSAGE *msg,
|
||||||
msg->hdr.PayloadMaxBytes = 0;
|
msg->hdr.PayloadMaxBytes = 0;
|
||||||
if (response < 0) {
|
if (response < 0) {
|
||||||
msg->hdr.Flags.failed = 1;
|
msg->hdr.Flags.failed = 1;
|
||||||
msg->hdr.CompletionStatus = (U32) (-response);
|
msg->hdr.CompletionStatus = (u32) (-response);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -756,7 +756,7 @@ controlvm_respond_physdev_changestate(CONTROLVM_MESSAGE_HEADER *msgHdr,
|
||||||
void
|
void
|
||||||
visorchipset_save_message(CONTROLVM_MESSAGE *msg, CRASH_OBJ_TYPE type)
|
visorchipset_save_message(CONTROLVM_MESSAGE *msg, CRASH_OBJ_TYPE type)
|
||||||
{
|
{
|
||||||
U32 localSavedCrashMsgOffset;
|
u32 localSavedCrashMsgOffset;
|
||||||
u16 localSavedCrashMsgCount;
|
u16 localSavedCrashMsgCount;
|
||||||
|
|
||||||
/* get saved message count */
|
/* get saved message count */
|
||||||
|
@ -783,7 +783,7 @@ visorchipset_save_message(CONTROLVM_MESSAGE *msg, CRASH_OBJ_TYPE type)
|
||||||
if (visorchannel_read(ControlVm_channel,
|
if (visorchannel_read(ControlVm_channel,
|
||||||
offsetof(ULTRA_CONTROLVM_CHANNEL_PROTOCOL,
|
offsetof(ULTRA_CONTROLVM_CHANNEL_PROTOCOL,
|
||||||
SavedCrashMsgOffset),
|
SavedCrashMsgOffset),
|
||||||
&localSavedCrashMsgOffset, sizeof(U32)) < 0) {
|
&localSavedCrashMsgOffset, sizeof(u32)) < 0) {
|
||||||
LOGERR("failed to get Saved Message Offset");
|
LOGERR("failed to get Saved Message Offset");
|
||||||
POSTCODE_LINUX_2(CRASH_DEV_CTRL_RD_FAILURE_PC,
|
POSTCODE_LINUX_2(CRASH_DEV_CTRL_RD_FAILURE_PC,
|
||||||
POSTCODE_SEVERITY_ERR);
|
POSTCODE_SEVERITY_ERR);
|
||||||
|
@ -840,7 +840,7 @@ bus_responder(CONTROLVM_ID cmdId, ulong busNo, int response)
|
||||||
LOGERR("bus_responder no pending msg");
|
LOGERR("bus_responder no pending msg");
|
||||||
return; /* no controlvm response needed */
|
return; /* no controlvm response needed */
|
||||||
}
|
}
|
||||||
if (p->pendingMsgHdr.Id != (U32) cmdId) {
|
if (p->pendingMsgHdr.Id != (u32) cmdId) {
|
||||||
LOGERR("expected=%d, found=%d", cmdId, p->pendingMsgHdr.Id);
|
LOGERR("expected=%d, found=%d", cmdId, p->pendingMsgHdr.Id);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
@ -911,7 +911,7 @@ device_responder(CONTROLVM_ID cmdId, ulong busNo, ulong devNo, int response)
|
||||||
LOGERR("device_responder no pending msg");
|
LOGERR("device_responder no pending msg");
|
||||||
return; /* no controlvm response needed */
|
return; /* no controlvm response needed */
|
||||||
}
|
}
|
||||||
if (p->pendingMsgHdr.Id != (U32) cmdId) {
|
if (p->pendingMsgHdr.Id != (u32) cmdId) {
|
||||||
LOGERR("expected=%d, found=%d", cmdId, p->pendingMsgHdr.Id);
|
LOGERR("expected=%d, found=%d", cmdId, p->pendingMsgHdr.Id);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
@ -922,8 +922,8 @@ device_responder(CONTROLVM_ID cmdId, ulong busNo, ulong devNo, int response)
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
bus_epilog(U32 busNo,
|
bus_epilog(u32 busNo,
|
||||||
U32 cmd, CONTROLVM_MESSAGE_HEADER *msgHdr,
|
u32 cmd, CONTROLVM_MESSAGE_HEADER *msgHdr,
|
||||||
int response, BOOL needResponse)
|
int response, BOOL needResponse)
|
||||||
{
|
{
|
||||||
BOOL notified = FALSE;
|
BOOL notified = FALSE;
|
||||||
|
@ -989,7 +989,7 @@ bus_epilog(U32 busNo,
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
device_epilog(U32 busNo, U32 devNo, ULTRA_SEGMENT_STATE state, U32 cmd,
|
device_epilog(u32 busNo, u32 devNo, ULTRA_SEGMENT_STATE state, u32 cmd,
|
||||||
CONTROLVM_MESSAGE_HEADER *msgHdr, int response,
|
CONTROLVM_MESSAGE_HEADER *msgHdr, int response,
|
||||||
BOOL needResponse, BOOL for_visorbus)
|
BOOL needResponse, BOOL for_visorbus)
|
||||||
{
|
{
|
||||||
|
@ -1366,7 +1366,7 @@ Away:
|
||||||
* for failure.
|
* for failure.
|
||||||
*/
|
*/
|
||||||
static int
|
static int
|
||||||
initialize_controlvm_payload_info(HOSTADDRESS phys_addr, U64 offset, U32 bytes,
|
initialize_controlvm_payload_info(HOSTADDRESS phys_addr, U64 offset, u32 bytes,
|
||||||
CONTROLVM_PAYLOAD_INFO *info)
|
CONTROLVM_PAYLOAD_INFO *info)
|
||||||
{
|
{
|
||||||
u8 __iomem *payload = NULL;
|
u8 __iomem *payload = NULL;
|
||||||
|
@ -1424,7 +1424,7 @@ initialize_controlvm_payload(void)
|
||||||
{
|
{
|
||||||
HOSTADDRESS phys_addr = visorchannel_get_physaddr(ControlVm_channel);
|
HOSTADDRESS phys_addr = visorchannel_get_physaddr(ControlVm_channel);
|
||||||
U64 payloadOffset = 0;
|
U64 payloadOffset = 0;
|
||||||
U32 payloadBytes = 0;
|
u32 payloadBytes = 0;
|
||||||
if (visorchannel_read(ControlVm_channel,
|
if (visorchannel_read(ControlVm_channel,
|
||||||
offsetof(ULTRA_CONTROLVM_CHANNEL_PROTOCOL,
|
offsetof(ULTRA_CONTROLVM_CHANNEL_PROTOCOL,
|
||||||
RequestPayloadOffset),
|
RequestPayloadOffset),
|
||||||
|
@ -1764,7 +1764,7 @@ handle_command(CONTROLVM_MESSAGE inmsg, HOSTADDRESS channel_addr)
|
||||||
{
|
{
|
||||||
CONTROLVM_MESSAGE_PACKET *cmd = &inmsg.cmd;
|
CONTROLVM_MESSAGE_PACKET *cmd = &inmsg.cmd;
|
||||||
U64 parametersAddr = 0;
|
U64 parametersAddr = 0;
|
||||||
U32 parametersBytes = 0;
|
u32 parametersBytes = 0;
|
||||||
PARSER_CONTEXT *parser_ctx = NULL;
|
PARSER_CONTEXT *parser_ctx = NULL;
|
||||||
BOOL isLocalAddr = FALSE;
|
BOOL isLocalAddr = FALSE;
|
||||||
CONTROLVM_MESSAGE ackmsg;
|
CONTROLVM_MESSAGE ackmsg;
|
||||||
|
@ -1900,7 +1900,7 @@ handle_command(CONTROLVM_MESSAGE inmsg, HOSTADDRESS channel_addr)
|
||||||
HOSTADDRESS controlvm_get_channel_address(void)
|
HOSTADDRESS controlvm_get_channel_address(void)
|
||||||
{
|
{
|
||||||
U64 addr = 0;
|
U64 addr = 0;
|
||||||
U32 size = 0;
|
u32 size = 0;
|
||||||
|
|
||||||
if (!VMCALL_SUCCESSFUL(Issue_VMCALL_IO_CONTROLVM_ADDR(&addr, &size))) {
|
if (!VMCALL_SUCCESSFUL(Issue_VMCALL_IO_CONTROLVM_ADDR(&addr, &size))) {
|
||||||
ERRDRV("%s - vmcall to determine controlvm channel addr failed",
|
ERRDRV("%s - vmcall to determine controlvm channel addr failed",
|
||||||
|
@ -2027,7 +2027,7 @@ setup_crash_devices_work_queue(struct work_struct *work)
|
||||||
CONTROLVM_MESSAGE localCrashCreateBusMsg;
|
CONTROLVM_MESSAGE localCrashCreateBusMsg;
|
||||||
CONTROLVM_MESSAGE localCrashCreateDevMsg;
|
CONTROLVM_MESSAGE localCrashCreateDevMsg;
|
||||||
CONTROLVM_MESSAGE msg;
|
CONTROLVM_MESSAGE msg;
|
||||||
U32 localSavedCrashMsgOffset;
|
u32 localSavedCrashMsgOffset;
|
||||||
u16 localSavedCrashMsgCount;
|
u16 localSavedCrashMsgCount;
|
||||||
|
|
||||||
/* make sure visorbus server is registered for controlvm callbacks */
|
/* make sure visorbus server is registered for controlvm callbacks */
|
||||||
|
@ -2073,7 +2073,7 @@ setup_crash_devices_work_queue(struct work_struct *work)
|
||||||
if (visorchannel_read(ControlVm_channel,
|
if (visorchannel_read(ControlVm_channel,
|
||||||
offsetof(ULTRA_CONTROLVM_CHANNEL_PROTOCOL,
|
offsetof(ULTRA_CONTROLVM_CHANNEL_PROTOCOL,
|
||||||
SavedCrashMsgOffset),
|
SavedCrashMsgOffset),
|
||||||
&localSavedCrashMsgOffset, sizeof(U32)) < 0) {
|
&localSavedCrashMsgOffset, sizeof(u32)) < 0) {
|
||||||
LOGERR("failed to get Saved Message Offset");
|
LOGERR("failed to get Saved Message Offset");
|
||||||
POSTCODE_LINUX_2(CRASH_DEV_CTRL_RD_FAILURE_PC,
|
POSTCODE_LINUX_2(CRASH_DEV_CTRL_RD_FAILURE_PC,
|
||||||
POSTCODE_SEVERITY_ERR);
|
POSTCODE_SEVERITY_ERR);
|
||||||
|
|
Loading…
Add table
Reference in a new issue