#define SIGNATURE_32(A, B, C, D) \
(SIGNATURE_16(A, B) | (SIGNATURE_16(C, D) << 16))
#define SIGNATURE_64(A, B, C, D, E, F, G, H) \
- (SIGNATURE_32(A, B, C, D) | ((U64)(SIGNATURE_32(E, F, G, H)) << 32))
+ (SIGNATURE_32(A, B, C, D) | ((u64)(SIGNATURE_32(E, F, G, H)) << 32))
#ifndef lengthof
#define lengthof(TYPE, MEMBER) (sizeof(((TYPE *)0)->MEMBER))
#pragma pack(push, 1) /* both GCC and VC now allow this pragma */
/* Common Channel Header */
typedef struct _CHANNEL_HEADER {
- U64 Signature; /* Signature */
+ u64 Signature; /* Signature */
u32 LegacyState; /* DEPRECATED - being replaced by */
/* / SrvState, CliStateBoot, and CliStateOS below */
u32 HeaderSize; /* sizeof(CHANNEL_HEADER) */
- U64 Size; /* Total size of this channel in bytes */
- U64 Features; /* Flags to modify behavior */
+ u64 Size; /* Total size of this channel in bytes */
+ u64 Features; /* Flags to modify behavior */
uuid_le Type; /* Channel type: data, bus, control, etc. */
- U64 PartitionHandle; /* ID of guest partition */
- U64 Handle; /* Device number of this channel in client */
- U64 oChannelSpace; /* Offset in bytes to channel specific area */
+ u64 PartitionHandle; /* ID of guest partition */
+ u64 Handle; /* Device number of this channel in client */
+ u64 oChannelSpace; /* Offset in bytes to channel specific area */
u32 VersionId; /* CHANNEL_HEADER Version ID */
u32 PartitionIndex; /* Index of guest partition */
uuid_le ZoneGuid; /* Guid of Channel's zone */
/* 1st cache line */
u32 VersionId; /* SIGNAL_QUEUE_HEADER Version ID */
u32 Type; /* Queue type: storage, network */
- U64 Size; /* Total size of this queue in bytes */
- U64 oSignalBase; /* Offset to signal queue area */
- U64 FeatureFlags; /* Flags to modify behavior */
- U64 NumSignalsSent; /* Total # of signals placed in this queue */
- U64 NumOverflows; /* Total # of inserts failed due to
+ u64 Size; /* Total size of this queue in bytes */
+ u64 oSignalBase; /* Offset to signal queue area */
+ u64 FeatureFlags; /* Flags to modify behavior */
+ u64 NumSignalsSent; /* Total # of signals placed in this queue */
+ u64 NumOverflows; /* Total # of inserts failed due to
* full queue */
u32 SignalSize; /* Total size of a signal for this queue */
u32 MaxSignalSlots; /* Max # of slots in queue, 1 slot is
* (MaxSignalSlots-1) */
u32 Head; /* Queue head signal # */
/* 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
* cache line) */
u32 Reserved1; /* Reserved field */
- U64 Reserved2; /* Resrved field */
- U64 ClientQueue;
- U64 NumInterruptsReceived; /* Total # of Interrupts received. This
+ u64 Reserved2; /* Resrved field */
+ u64 ClientQueue;
+ u64 NumInterruptsReceived; /* Total # of Interrupts received. This
* is incremented by the ISR in the
* guest windows driver */
- U64 NumEmptyCnt; /* Number of times that visor_signal_remove
+ u64 NumEmptyCnt; /* Number of times that visor_signal_remove
* is called and returned Empty
* Status. */
u32 ErrorFlags; /* Error bits set during SignalReinit
ULTRA_check_channel_client(void __iomem *pChannel,
uuid_le expectedTypeGuid,
char *channelName,
- U64 expectedMinBytes,
+ u64 expectedMinBytes,
u32 expectedVersionId,
- U64 expectedSignature,
+ u64 expectedSignature,
char *fileName, int lineNumber, void *logCtx)
{
if (uuid_le_cmp(expectedTypeGuid, NULL_UUID_LE) != 0)
static inline int
ULTRA_check_channel_server(uuid_le typeGuid,
char *channelName,
- U64 expectedMinBytes,
- U64 actualBytes,
+ u64 expectedMinBytes,
+ u64 actualBytes,
char *fileName, int lineNumber, void *logCtx)
{
if (expectedMinBytes > 0) /* caller wants us to verify
1, 1, 0, 0, 1, 1, 1, 0
};
typedef union {
- U64 Full;
+ u64 Full;
struct {
u8 Major; /* will be 1 for the first release and
* increment thereafter */
* interrupt. Currently this is used by IOPart-SP to wake
* up GP when Data Channel transitions from empty to
* non-empty.*/
- U64 sendInterruptHandle;
+ u64 sendInterruptHandle;
/**< specifies interrupt handle. It is used to retrieve the
* corresponding interrupt pin from Monitor; and the
* interrupt pin is used to connect to the corresponding
* intrrupt. Used by IOPart-GP only. */
- U64 recvInterruptHandle;
+ u64 recvInterruptHandle;
/**< specifies interrupt vector. It, interrupt pin, and shared are
* used to connect to the corresponding interrupt. Used by
} ULTRA_TOOL_ACTIONS;
typedef struct _ULTRA_EFI_SPAR_INDICATION {
- U64 BootToFirmwareUI:1; /* Bit 0: Stop in uefi ui */
- U64 ClearNvram:1; /* Bit 1: Clear NVRAM */
- U64 ClearCmos:1; /* Bit 2: Clear CMOS */
- U64 BootToTool:1; /* Bit 3: Run install tool */
+ u64 BootToFirmwareUI:1; /* Bit 0: Stop in uefi ui */
+ u64 ClearNvram:1; /* Bit 1: Clear NVRAM */
+ u64 ClearCmos:1; /* Bit 2: Clear CMOS */
+ u64 BootToTool:1; /* Bit 3: Run install tool */
/* remaining bits are available */
} ULTRA_EFI_SPAR_INDICATION;
/* remaining bits in this 32-bit word are available */
} Flags;
u32 Reserved; /* Natural alignment */
- U64 MessageHandle; /* Identifies the particular message instance,
+ u64 MessageHandle; /* Identifies the particular message instance,
* and is used to match particular */
/* 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 */
u32 PayloadMaxBytes; /* Maximum bytes allocated in payload
* area of ControlVm segment */
/* Control uses header SegmentIndex field to access bus 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
* of this ControlVm command */
- U64 channelBytes; /**< specifies size of the channel in bytes */
+ u64 channelBytes; /**< specifies size of the channel in bytes */
uuid_le dataTypeGuid;/**< specifies format of data in channel */
uuid_le devInstGuid; /**< instance guid for the device */
struct InterruptInfo intr; /**< specifies interrupt information */
/* Control uses header SegmentIndex field to access bus number... */
u32 deviceCount; /*< indicates the max number of
* devices on this bus */
- U64 channelAddr; /*< Guest physical address of the
+ u64 channelAddr; /*< Guest physical address of the
* channel, which can be
* dereferenced by the receiver
* of this ControlVm command */
- U64 channelBytes; /*< size of the channel in bytes */
+ u64 channelBytes; /*< size of the channel in bytes */
uuid_le busDataTypeGuid;/*< indicates format of data in
bus channel */
uuid_le busInstGuid; /*< instance guid for the bus */
/* Control uses header SegmentIndex field to access bus number... */
u32 reserved1; /* for alignment purposes */
- U64 guestHandle; /* This is used to convert
+ u64 guestHandle; /* This is used to convert
* guest physical address to real
* physical address for DMA, for ex. */
- U64 recvBusInterruptHandle;/*< specifies interrupt
+ u64 recvBusInterruptHandle;/*< specifies interrupt
* info. It is used by SP to register
* to receive interrupts from the CP.
* This interrupt is used for bus
/* BEGIN Ack messages */
/* END Ack messages */
- U64 addr; /*< a physical address of something, that
+ u64 addr; /*< a physical address of something, that
* can be dereferenced by the receiver of
* this ControlVm command (depends on
* command id) */
- U64 handle; /*< a handle of something (depends on
+ u64 handle; /*< a handle of something (depends on
* command id) */
};
} CONTROLVM_MESSAGE_PACKET;
typedef struct _DEVICE_MAP {
GUEST_PHYSICAL_ADDRESS DeviceChannelAddress;
- U64 DeviceChannelSize;
+ u64 DeviceChannelSize;
u32 CA_Index;
u32 Reserved; /* natural alignment */
- U64 Reserved2; /* Align structure on 32-byte boundary */
+ u64 Reserved2; /* Align structure on 32-byte boundary */
} DEVICE_MAP;
typedef struct _GUEST_DEVICES {
* ROM disk */
GUEST_PHYSICAL_ADDRESS gpNvram; /* guest phys addr of NVRAM
* channel */
- U64 RequestPayloadOffset; /* Offset to request payload area */
- U64 EventPayloadOffset; /* Offset to event payload area */
+ u64 RequestPayloadOffset; /* Offset to request payload area */
+ u64 EventPayloadOffset; /* Offset to event payload area */
u32 RequestPayloadBytes; /* Bytes available in request payload
* area */
u32 EventPayloadBytes; /* Bytes available in event payload area */
GUEST_PHYSICAL_ADDRESS VirtualGuestFirmwareEntryPoint;
/* guest EFI firmware image size */
- U64 VirtualGuestFirmwareImageSize;
+ u64 VirtualGuestFirmwareImageSize;
/* GPA = 1MB where EFI firmware image is copied to */
GUEST_PHYSICAL_ADDRESS VirtualGuestFirmwareBootBase;
GUEST_PHYSICAL_ADDRESS VirtualGuestImageBase;
GUEST_PHYSICAL_ADDRESS VirtualGuestImageSize;
- U64 PrototypeControlChannelOffset;
+ u64 PrototypeControlChannelOffset;
GUEST_PHYSICAL_ADDRESS VirtualGuestPartitionHandle;
u16 RestoreAction; /* Restore Action field to restore the guest
u16 LogicalProcessorNumber;
u8 ComponentType; /* ULTRA_COMPONENT_TYPES */
u8 Subsystem;
- u16 Reserved0; /* pad to U64 alignment */
+ u16 Reserved0; /* pad to u64 alignment */
u32 BlockNumber; /* filled in by DiagSwitch as pool blocks are
* filled */
u32 BlockNumberHigh;
#pragma pack(push, 1)
struct guest_phys_info {
- U64 address;
- U64 length;
+ u64 address;
+ u64 length;
};
#define GPI_ENTRIES_PER_PAGE (PAGE_SIZE / sizeof(struct guest_phys_info))
* to be describable */
struct phys_info frag; /* physical page information for the
* single fragment 2K rcv buf */
- U64 UniqueNum; /* This is used to make sure that
+ u64 UniqueNum; /* This is used to make sure that
* receive posts are returned to */
/* the Adapter which sent them origonally. */
};
* that must be chained; */
/* each entry is a receive buffer provided by NET_RCV_POST. */
/* NOTE: first rcvbuf in the chain will also be provided in net.buf. */
- U64 UniqueNum;
+ u64 UniqueNum;
u32 RcvsDroppedDelta;
};
struct vhba_wwnn *wwnn,
struct vhba_config_max *max,
unsigned char *clientStr,
- u32 clientStrLen, U64 bytes) {
+ u32 clientStrLen, u64 bytes) {
MEMSET(x, 0, sizeof(ULTRA_IO_CHANNEL_PROTOCOL));
x->ChannelHeader.VersionId = ULTRA_VHBA_CHANNEL_PROTOCOL_VERSIONID;
x->ChannelHeader.Signature = ULTRA_VHBA_CHANNEL_PROTOCOL_SIGNATURE;
uuid_le zoneGuid,
unsigned char *clientStr,
u32 clientStrLen,
- U64 bytes) {
+ u64 bytes) {
MEMSET(x, 0, sizeof(ULTRA_IO_CHANNEL_PROTOCOL));
x->ChannelHeader.VersionId = ULTRA_VNIC_CHANNEL_PROTOCOL_VERSIONID;
x->ChannelHeader.Signature = ULTRA_VNIC_CHANNEL_PROTOCOL_SIGNATURE;
/* ///////////// ONLY STRUCT TYPE SHOULD BE BELOW */
#pragma pack(push, 1)
struct phys_info {
- U64 pi_pfn;
+ u64 pi_pfn;
u16 pi_off;
u16 pi_len;
};
typedef struct _VMCALL_IO_CONTROLVM_ADDR_PARAMS {
/* The Guest-relative physical address of the ControlVm channel.
* This VMCall fills this in with the appropriate address. */
- 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
* in with the appropriate address. */
u32 ChannelBytes; /* contents provided by this VMCALL (OUT) */
typedef struct _VMCALL_IO_DIAG_ADDR_PARAMS {
/* The Guest-relative physical address of the diagnostic channel.
* This VMCall fills this in with the appropriate address. */
- U64 ChannelAddress; /* contents provided by this VMCALL (OUT) */
+ u64 ChannelAddress; /* contents provided by this VMCALL (OUT) */
} VMCALL_IO_DIAG_ADDR_PARAMS;
#pragma pack(pop)
/* The Guest-relative physical address of the serial console
* channel. This VMCall fills this in with the appropriate
* address. */
- U64 ChannelAddress; /* contents provided by this VMCALL (OUT) */
+ u64 ChannelAddress; /* contents provided by this VMCALL (OUT) */
} VMCALL_IO_VISORSERIAL_ADDR_PARAMS;
#pragma pack(pop)
#include <syslog.h>
#endif
-#define U64 uint64_t
#define S8 int8_t
#define S16 int16_t
#define S32 int32_t
#ifdef CONFIG_X86_32
#define UINTN u32
#else
-#define UINTN U64
+#define UINTN u64
#endif
#else
#if __WORDSIZE == 32
#define UINTN u32
#elif __WORDSIZE == 64
-#define UINTN U64
+#define UINTN u64
#else
#error Unsupported __WORDSIZE
#endif
#endif
-typedef U64 GUEST_PHYSICAL_ADDRESS;
+typedef u64 GUEST_PHYSICAL_ADDRESS;
#define MEMSET(ptr, val, len) memset(ptr, val, len)
#define MEMCMP(m1, m2, len) memcmp(m1, m2, len)
fil, lin); \
} while (0)
-#define CHANNEL_u32_MISMATCH(chType, chName, field, expected, actual, fil, \
+#define CHANNEL_U32_MISMATCH(chType, chName, field, expected, actual, fil, \
lin, logCtx) \
do { \
syslog(LOG_USER | LOG_ERR, \
#define POSTCODE_LINUX_A(DRIVER_PC, EVENT_PC, pc32bit, severity) \
do { \
unsigned long long post_code_temp; \
- post_code_temp = (((U64)DRIVER_PC) << 56) | (((U64)EVENT_PC) << 44) | \
- ((((U64)__LINE__) & 0xFFF) << 32) | \
- (((U64)pc32bit) & 0xFFFFFFFF); \
+ post_code_temp = (((u64)DRIVER_PC) << 56) | (((u64)EVENT_PC) << 44) | \
+ ((((u64)__LINE__) & 0xFFF) << 32) | \
+ (((u64)pc32bit) & 0xFFFFFFFF); \
ISSUE_IO_VMCALL_POSTCODE_SEVERITY(post_code_temp, severity); \
} while (0)
#define POSTCODE_LINUX_B(DRIVER_PC, EVENT_PC, pc16bit1, pc16bit2, severity) \
do { \
unsigned long long post_code_temp; \
- post_code_temp = (((U64)DRIVER_PC) << 56) | (((U64)EVENT_PC) << 44) | \
- ((((U64)__LINE__) & 0xFFF) << 32) | \
- ((((U64)pc16bit1) & 0xFFFF) << 16) | \
- (((U64)pc16bit2) & 0xFFFF); \
+ post_code_temp = (((u64)DRIVER_PC) << 56) | (((u64)EVENT_PC) << 44) | \
+ ((((u64)__LINE__) & 0xFFF) << 32) | \
+ ((((u64)pc16bit1) & 0xFFFF) << 16) | \
+ (((u64)pc16bit2) & 0xFFFF); \
ISSUE_IO_VMCALL_POSTCODE_SEVERITY(post_code_temp, severity); \
} while (0)
/* channel containing queues in which scsi commands &
* responses are queued
*/
- U64 packets_sent;
- U64 packets_received;
- U64 interrupts_sent;
- U64 interrupts_received;
- U64 max_not_empty_cnt;
- U64 total_wakeup_cnt;
- U64 non_empty_wakeup_cnt;
+ u64 packets_sent;
+ u64 packets_received;
+ u64 interrupts_sent;
+ u64 interrupts_received;
+ u64 max_not_empty_cnt;
+ u64 total_wakeup_cnt;
+ u64 non_empty_wakeup_cnt;
struct {
SIGNAL_QUEUE_HEADER Reserved1; /* */
unsigned int (*send_int_if_needed)(struct uisqueue_info *info,
unsigned int whichcqueue,
unsigned char issueInterruptIfEmpty,
- U64 interruptHandle,
+ u64 interruptHandle,
unsigned char io_termination);
};
unsigned int uisqueue_send_int_if_needed(struct uisqueue_info *pqueueinfo,
unsigned int whichqueue,
unsigned char issueInterruptIfEmpty,
- U64 interruptHandle,
+ u64 interruptHandle,
unsigned char io_termination);
int uisqueue_put_cmdrsp_with_lock_client(struct uisqueue_info *queueinfo,
unsigned int queue,
void *insertlock,
unsigned char issueInterruptIfEmpty,
- U64 interruptHandle,
+ u64 interruptHandle,
char oktowait,
u8 *channelId);
struct device_info {
void __iomem *chanptr;
- U64 channelAddr;
- U64 channelBytes;
+ u64 channelAddr;
+ u64 channelBytes;
uuid_le channelTypeGuid;
uuid_le devInstGuid;
struct InterruptInfo intr;
struct bus_info {
u32 busNo, deviceCount;
struct device_info **device;
- U64 guestHandle, recvBusInterruptHandle;
+ u64 guestHandle, recvBusInterruptHandle;
uuid_le busInstGuid;
ULTRA_VBUS_CHANNEL_PROTOCOL __iomem *pBusChannel;
int busChannelBytes;
struct add_virt_iopart {
void *chanptr; /* pointer to data channel */
- U64 guestHandle; /* used to convert guest physical
+ u64 guestHandle; /* used to convert guest physical
* address to real physical address
* for DMA, for ex. */
- U64 recvBusInterruptHandle; /* used to register to receive
+ u64 recvBusInterruptHandle; /* used to register to receive
* bus level interrupts. */
struct InterruptInfo intr; /* contains recv & send
* interrupt info */
unsigned long min_channel_bytes;
int (*Server_Channel_Ok)(unsigned long channelBytes);
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];
struct list_head list_link; /* links into ReqHandlerInfo_list */
} ReqHandlerInfo_t;
channelBytes),
int (*Server_Channel_Init)
(void *x, unsigned char *clientStr,
- u32 clientStrLen, U64 bytes));
+ u32 clientStrLen, u64 bytes));
ReqHandlerInfo_t *ReqHandlerFind(uuid_le switchTypeGuid);
int ReqHandlerDel(uuid_le switchTypeGuid);
dbg_ioremap_cache(addr, size, __FILE__, __LINE__)
static inline void __iomem *
-dbg_ioremap_cache(U64 addr, unsigned long size, char *file, int line)
+dbg_ioremap_cache(u64 addr, unsigned long size, char *file, int line)
{
void __iomem *new;
new = ioremap_cache(addr, size);
#define uislib_ioremap(addr, size) dbg_ioremap(addr, size, __FILE__, __LINE__)
static inline void *
-dbg_ioremap(U64 addr, unsigned long size, char *file, int line)
+dbg_ioremap(u64 addr, unsigned long size, char *file, int line)
{
void *new;
new = ioremap(addr, size);
channelBytes),
int (*Server_Channel_Init)
(void *x, unsigned char *clientStr,
- u32 clientStrLen, U64 bytes),
+ u32 clientStrLen, u64 bytes),
ULTRA_VBUS_DEVICEINFO *chipset_DriverInfo);
int uisctrl_unregister_req_handler_ex(uuid_le switchTypeGuid);
void uislib_server_inject_del_vnic(u32 switchNo, u32 busNo, u32 numIntPorts,
u32 numExtPorts);
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_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,
struct InterruptInfo *intr);
int uislib_client_inject_pause_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_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,
struct InterruptInfo *intr);
int uislib_client_inject_pause_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);
#ifdef STORAGE_CHANNEL
-U64 uislib_storage_channel(int client_id);
+u64 uislib_storage_channel(int client_id);
#endif
int uislib_get_owned_pdest(struct uisscsi_dest *pdest);
struct phys_info frags[]);
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;
int result = VMCALL_SUCCESS;
- U64 physaddr;
+ u64 physaddr;
physaddr = virt_to_phys(¶ms);
ISSUE_IO_VMCALL(VMCALL_IO_CONTROLVM_ADDR, physaddr, result);
return result;
}
-static inline unsigned int Issue_VMCALL_IO_DIAG_ADDR(U64 *DiagChannelAddress)
+static inline unsigned int Issue_VMCALL_IO_DIAG_ADDR(u64 *DiagChannelAddress)
{
VMCALL_IO_DIAG_ADDR_PARAMS params;
int result = VMCALL_SUCCESS;
- U64 physaddr;
+ u64 physaddr;
physaddr = virt_to_phys(¶ms);
ISSUE_IO_VMCALL(VMCALL_IO_DIAG_ADDR, physaddr, result);
}
static inline unsigned int
-Issue_VMCALL_IO_VISORSERIAL_ADDR(U64 *DiagChannelAddress)
+Issue_VMCALL_IO_VISORSERIAL_ADDR(u64 *DiagChannelAddress)
{
VMCALL_IO_VISORSERIAL_ADDR_PARAMS params;
int result = VMCALL_SUCCESS;
- U64 physaddr;
+ u64 physaddr;
physaddr = virt_to_phys(¶ms);
ISSUE_IO_VMCALL(VMCALL_IO_VISORSERIAL_ADDR, physaddr, result);
static inline S64 Issue_VMCALL_QUERY_GUEST_VIRTUAL_TIME_OFFSET(void)
{
- U64 result = VMCALL_SUCCESS;
- U64 physaddr = 0;
+ u64 result = VMCALL_SUCCESS;
+ u64 physaddr = 0;
ISSUE_IO_VMCALL(VMCALL_QUERY_GUEST_VIRTUAL_TIME_OFFSET, physaddr,
result);
static inline S64 Issue_VMCALL_MEASUREMENT_DO_NOTHING(void)
{
- U64 result = VMCALL_SUCCESS;
- U64 physaddr = 0;
+ u64 result = VMCALL_SUCCESS;
+ u64 physaddr = 0;
ISSUE_IO_VMCALL(VMCALL_MEASUREMENT_DO_NOTHING, physaddr, result);
return result;
unsigned long long min_delta[64];
};
-static inline int Issue_VMCALL_UPDATE_PHYSICAL_TIME(U64 adjustment)
+static inline int Issue_VMCALL_UPDATE_PHYSICAL_TIME(u64 adjustment)
{
int result = VMCALL_SUCCESS;
{
VMCALL_CHANNEL_VERSION_MISMATCH_PARAMS params;
int result = VMCALL_SUCCESS;
- U64 physaddr;
+ u64 physaddr;
char *last_slash = NULL;
strlcpy(params.ChannelName, ChannelName,
static inline unsigned int Issue_VMCALL_FATAL_BYE_BYE(void)
{
int result = VMCALL_SUCCESS;
- U64 physaddr = 0;
+ u64 physaddr = 0;
ISSUE_IO_VMCALL(VMCALL_GENERIC_SURRENDER_QUANTUM_FOREVER, physaddr,
result);
static rwlock_t BusListLock;
static int BusListCount; /* number of buses in the list */
static int MaxBusCount; /* maximum number of buses expected */
-static U64 PhysicalDataChan;
+static u64 PhysicalDataChan;
static int PlatformNumber;
static struct uisthread_info Incoming_ThreadInfo;
}
static __iomem void *
-init_vbus_channel(U64 channelAddr, u32 channelBytes)
+init_vbus_channel(u64 channelAddr, u32 channelBytes)
{
void __iomem *rc = NULL;
void __iomem *pChan = uislib_ioremap_cache(channelAddr, channelBytes);
struct bus_info *bus;
u32 busNo, devNo;
int result = CONTROLVM_RESP_SUCCESS;
- U64 minSize = MIN_IO_CHANNEL_SIZE;
+ u64 minSize = MIN_IO_CHANNEL_SIZE;
ReqHandlerInfo_t *pReqHandler;
busNo = msg->cmd.createDevice.busNo;
int
uislib_client_inject_add_bus(u32 busNo, uuid_le instGuid,
- U64 channelAddr, ulong nChannelBytes)
+ u64 channelAddr, ulong nChannelBytes)
{
CONTROLVM_MESSAGE msg;
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,
struct InterruptInfo *intr)
{
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,
struct InterruptInfo *intr)
{
void *pSignal,
spinlock_t *lock,
unsigned char issueInterruptIfEmpty,
- U64 interruptHandle, u8 *channelId)
+ u64 interruptHandle, u8 *channelId)
{
unsigned long flags;
unsigned char queueWasEmpty;
unsigned int whichqueue,
void *insertlock,
unsigned char issueInterruptIfEmpty,
- U64 interruptHandle,
+ u64 interruptHandle,
char oktowait, u8 *channelId)
{
while (!do_locked_client_insert(queueinfo, whichqueue, cmdrsp,
channelBytes),
int (*Server_Channel_Init)
(void *x, unsigned char *clientStr,
- u32 clientStrLen, U64 bytes),
+ u32 clientStrLen, u64 bytes),
ULTRA_VBUS_DEVICEINFO *chipset_DriverInfo)
{
ReqHandlerInfo_t *pReqHandlerInfo;
unsigned long min_channel_bytes,
int (*Server_Channel_Ok)(unsigned long channelBytes),
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;
unsigned long long interrupts_notme;
unsigned long long interrupts_disabled;
struct work_struct serverdown_completion;
- U64 __iomem *flags_addr;
+ u64 __iomem *flags_addr;
atomic_t interrupt_rcvd;
wait_queue_head_t rsp_queue;
struct virtdisk_info head;
struct virthba_info *virthbainfo = (struct virthba_info *) dev_id;
CHANNEL_HEADER __iomem *pChannelHeader;
SIGNAL_QUEUE_HEADER __iomem *pqhdr;
- U64 mask;
+ u64 mask;
unsigned long long rc1;
if (virthbainfo == NULL)
irq_handler_t handler = virthba_ISR;
CHANNEL_HEADER __iomem *pChannelHeader;
SIGNAL_QUEUE_HEADER __iomem *pqhdr;
- U64 mask;
+ u64 mask;
LOGVER("entering virthba_probe...\n");
LOGVER("virtpcidev busNo<<%d>>devNo<<%d>>", virtpcidev->busNo,
virthbainfo->interrupt_vector = -1;
POSTCODE_LINUX_2(VHBA_PROBE_FAILURE_PC, POSTCODE_SEVERITY_ERR);
} else {
- U64 __iomem *Features_addr =
+ u64 __iomem *Features_addr =
&virthbainfo->chinfo.queueinfo->chan->Features;
LOGERR("request_irq(%d) uislib_virthba_ISR request succeeded\n",
virthbainfo->interrupt_vector);
uisqueue_put_cmdrsp_with_lock_client(virthbainfo->chinfo.queueinfo,
cmdrsp, IOCHAN_TO_IOPART,
&virthbainfo->chinfo.insertlock,
- DONT_ISSUE_INTERRUPT, (U64) NULL,
+ DONT_ISSUE_INTERRUPT, (u64) NULL,
OK_TO_WAIT, "vhba");
LOGINF("VdiskMgmt waiting on event notifyevent=0x%p\n",
cmdrsp->scsitaskmgmt.notify);
uisqueue_put_cmdrsp_with_lock_client(virthbainfo->chinfo.queueinfo,
cmdrsp, IOCHAN_TO_IOPART,
&virthbainfo->chinfo.insertlock,
- DONT_ISSUE_INTERRUPT, (U64) NULL,
+ DONT_ISSUE_INTERRUPT, (u64) NULL,
OK_TO_WAIT, "vhba");
LOGINF("TaskMgmt waiting on event notifyevent=0x%p\n",
cmdrsp->scsitaskmgmt.notify);
&virthbainfo->chinfo.
insertlock,
DONT_ISSUE_INTERRUPT,
- (U64) NULL, DONT_WAIT, "vhba");
+ (u64) NULL, DONT_WAIT, "vhba");
if (i == 0) {
/* queue must be full - and we said don't wait - return busy */
LOGERR("uisqueue_put_cmdrsp_with_lock ****FAILED\n");
struct chaninfo *dc = &virthbainfo->chinfo;
struct uiscmdrsp *cmdrsp = NULL;
const int SZ = sizeof(struct uiscmdrsp);
- U64 mask;
+ u64 mask;
unsigned long long rc1;
UIS_DAEMONIZE("vhba_incoming");
{
ssize_t bytes_read = 0;
int str_pos = 0;
- U64 phys_flags_addr;
+ u64 phys_flags_addr;
int i;
struct virthba_info *virthbainfo;
char *vbuf;
int i, new_value;
struct virthba_info *virthbainfo;
- U64 __iomem *Features_addr;
- U64 mask;
+ u64 __iomem *Features_addr;
+ u64 mask;
if (count >= ARRAY_SIZE(buf))
return -EINVAL;
#include "memregion.h"
#include "channel.h"
#ifndef HOSTADDRESS
-#define HOSTADDRESS U64
+#define HOSTADDRESS u64
#endif
#ifndef BOOL
#define BOOL int
ulong visorchannel_get_nbytes(VISORCHANNEL *channel);
char *visorchannel_id(VISORCHANNEL *channel, char *s);
char *visorchannel_zoneid(VISORCHANNEL *channel, char *s);
-U64 visorchannel_get_clientpartition(VISORCHANNEL *channel);
+u64 visorchannel_get_clientpartition(VISORCHANNEL *channel);
uuid_le visorchannel_get_uuid(VISORCHANNEL *channel);
MEMREGION *visorchannel_get_memregion(VISORCHANNEL *channel);
char *visorchannel_uuid_id(uuid_le *guid, char *s);
};
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)
{
int allocbytes = sizeof(PARSER_CONTEXT) + bytes;
}
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);
}
* parser_byteStream_get() to obtain the data.
*/
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);
}
typedef struct PARSER_CONTEXT_Tag PARSER_CONTEXT;
-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(u64 addr, u32 bytes, BOOL isLocal, BOOL *tryAgain);
+PARSER_CONTEXT *parser_init_byteStream(u64 addr, u32 bytes, BOOL isLocal,
BOOL *tryAgain);
void parser_param_start(PARSER_CONTEXT *ctx, PARSER_WHICH_STRING which_string);
void *parser_param_get(PARSER_CONTEXT *ctx, char *nam, int namesize);
VISORCHIPSET_ADDRESSTYPE addrType;
HOSTADDRESS channelAddr;
struct InterruptInfo intr;
- U64 nChannelBytes;
+ u64 nChannelBytes;
uuid_le channelTypeGuid;
uuid_le channelInstGuid;
VISORCHIPSET_STATE state;
VISORCHIPSET_CHANNEL_INFO chanInfo;
u32 Reserved1; /* CONTROLVM_ID */
- U64 Reserved2;
+ u64 Reserved2;
u32 switchNo; /* when devState.attached==1 */
u32 internalPortNo; /* when devState.attached==1 */
CONTROLVM_MESSAGE_HEADER pendingMsgHdr; /* CONTROLVM_MESSAGE */
VISORCHIPSET_STATE state;
VISORCHIPSET_CHANNEL_INFO chanInfo;
uuid_le partitionGuid;
- U64 partitionHandle;
+ u64 partitionHandle;
u8 *name; /* UTF8 */
u8 *description; /* UTF8 */
- U64 Reserved1;
+ u64 Reserved1;
u32 Reserved2;
MYPROCOBJECT *procObject;
struct {
CONTROLVM_MESSAGE_HEADER pendingMsgHdr; /* CONTROLVM MsgHdr */
/** For private use by the bus driver */
void *bus_driver_context;
- U64 devNo;
+ u64 devNo;
} VISORCHIPSET_BUS_INFO;
u8 *authService2;
u8 *authService3;
u8 *securityContext;
- U64 Reserved;
+ u64 Reserved;
u32 Reserved2; /* CONTROLVM_ID */
struct device dev;
BOOL dev_exists;
u8 *ipNetwork;
u8 *ipGateway;
u8 *ipDNS;
- U64 Reserved1;
+ u64 Reserved1;
u32 Reserved2; /* CONTROLVM_ID */
struct device dev;
BOOL dev_exists;
VISORCHIPSET_STATE state;
u32 busNo; /* valid only when state.attached == 1 */
u32 devNo; /* valid only when state.attached == 1 */
- U64 Reserved1;
+ u64 Reserved1;
u32 Reserved2; /* CONTROLVM_ID */
CONTROLVM_MESSAGE_HEADER pendingMsgHdr;
MYPROCOBJECT *procObject;
typedef struct {
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 */
u32 bytes; /* number of bytes in payload pool */
} CONTROLVM_PAYLOAD_INFO;
* for failure.
*/
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)
{
u8 __iomem *payload = NULL;
initialize_controlvm_payload(void)
{
HOSTADDRESS phys_addr = visorchannel_get_physaddr(ControlVm_channel);
- U64 payloadOffset = 0;
+ u64 payloadOffset = 0;
u32 payloadBytes = 0;
if (visorchannel_read(ControlVm_channel,
offsetof(ULTRA_CONTROLVM_CHANNEL_PROTOCOL,
handle_command(CONTROLVM_MESSAGE inmsg, HOSTADDRESS channel_addr)
{
CONTROLVM_MESSAGE_PACKET *cmd = &inmsg.cmd;
- U64 parametersAddr = 0;
+ u64 parametersAddr = 0;
u32 parametersBytes = 0;
PARSER_CONTEXT *parser_ctx = NULL;
BOOL isLocalAddr = FALSE;
HOSTADDRESS controlvm_get_channel_address(void)
{
- U64 addr = 0;
+ u64 addr = 0;
u32 size = 0;
if (!VMCALL_SUCCESSFUL(Issue_VMCALL_IO_CONTROLVM_ADDR(&addr, &size))) {
CONTROLVM_MESSAGE inmsg;
BOOL gotACommand = FALSE;
BOOL handle_command_failed = FALSE;
- static U64 Poll_Count;
+ static u64 Poll_Count;
/* make sure visorbus server is registered for controlvm callbacks */
if (visorchipset_serverregwait && !serverregistered)