Commit 1e3ab521 authored by Erik Arfvidson's avatar Erik Arfvidson Committed by Greg Kroah-Hartman

staging: unisys: fix comments for controlvmchannel.h

This patch simply fixes all trailing */ by modifying the comments
structures while trying to reduce the total number of lines
Signed-off-by: default avatarErik Arfvidson <erik.arfvidson@unisys.com>
Signed-off-by: default avatarBenjamin Romer <benjamin.romer@unisys.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 6924af76
...@@ -55,22 +55,25 @@ ...@@ -55,22 +55,25 @@
#define CONTROLVM_CRASHMSG_MAX 2 #define CONTROLVM_CRASHMSG_MAX 2
struct spar_segment_state { struct spar_segment_state {
u16 enabled:1; /* Bit 0: May enter other states */ /* Bit 0: May enter other states */
u16 active:1; /* Bit 1: Assigned to active partition */ u16 enabled:1;
u16 alive:1; /* Bit 2: Configure message sent to /* Bit 1: Assigned to active partition */
* service/server */ u16 active:1;
u16 revoked:1; /* Bit 3: similar to partition state /* Bit 2: Configure message sent to service/server */
* ShuttingDown */ u16 alive:1;
u16 allocated:1; /* Bit 4: memory (device/port number) /* Bit 3: similar to partition state ShuttingDown */
* has been selected by Command */ u16 revoked:1;
u16 known:1; /* Bit 5: has been introduced to the /* Bit 4: memory (device/port number) has been selected by Command */
* service/guest partition */ u16 allocated:1;
u16 ready:1; /* Bit 6: service/Guest partition has /* Bit 5: has been introduced to the service/guest partition */
* responded to introduction */ u16 known:1;
u16 operating:1; /* Bit 7: resource is configured and /* Bit 6: service/Guest partition has responded to introduction */
* operating */ u16 ready:1;
/* Note: don't use high bit unless we need to switch to ushort /* Bit 7: resource is configured and operating */
* which is non-compliant */ u16 operating:1;
/* Note: don't use high bit unless we need to switch to ushort
* which is non-compliant
*/
}; };
static const struct spar_segment_state segment_state_running = { static const struct spar_segment_state segment_state_running = {
...@@ -177,53 +180,53 @@ struct controlvm_message_header { ...@@ -177,53 +180,53 @@ struct controlvm_message_header {
/* 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 message_size; /* Includes size of this struct + size /* Includes size of this struct + size of message */
* of message */ u32 message_size;
u32 segment_index; /* Index of segment containing Vm /* Index of segment containing Vm message/information */
* message/information */ u32 segment_index;
u32 completion_status; /* Error status code or result of /* Error status code or result of message completion */
* message completion */ u32 completion_status;
struct { struct {
u32 failed:1; /* =1 in a response to * signify /* =1 in a response to signify failure */
* failure */ u32 failed:1;
u32 response_expected:1; /* =1 in all messages that expect a /* =1 in all messages that expect a response */
* response (Control ignores this u32 response_expected:1;
* bit) */ /* =1 in all bus & device-related messages where the message
u32 server:1; /* =1 in all bus & device-related * receiver is to act as the bus or device server
* messages where the message */
* receiver is to act as the bus or u32 server:1;
* device server */ /* =1 for testing use only (Control and Command ignore this */
u32 test_message:1; /* =1 for testing use only u32 test_message:1;
* (Control and Command ignore this /* =1 if there are forthcoming responses/acks associated
* bit) */ * with this message
u32 partial_completion:1; /* =1 if there are forthcoming */
* responses/acks associated u32 partial_completion:1;
* with this message */ /* =1 this is to let us know to preserve channel contents */
u32 preserve:1; /* =1 this is to let us know to u32 preserve:1;
* preserve channel contents /* =1 the DiagWriter is active in the Diagnostic Partition */
* (for running guests)*/ u32 writer_in_diag:1;
u32 writer_in_diag:1; /* =1 the DiagWriter is active in the
* Diagnostic Partition*/
} flags; } flags;
u32 reserved; /* Natural alignment */ /* Natural alignment */
u64 message_handle; /* Identifies the particular message instance, u32 reserved;
* and is used to match particular */ /* Identifies the particular message instance */
u64 message_handle;
/* request instances with the corresponding response instance. */ /* request instances with the corresponding response instance. */
u64 payload_vm_offset; /* Offset of payload area from start of this /* Offset of payload area from start of this instance */
* instance of ControlVm segment */ u64 payload_vm_offset;
u32 payload_max_bytes; /* Maximum bytes allocated in payload /* Maximum bytes allocated in payload area of ControlVm segment */
* area of ControlVm segment */ u32 payload_max_bytes;
u32 payload_bytes; /* Actual number of bytes of payload /* Actual number of bytes of payload area to copy between IO/Command */
* area to copy between IO/Command; */ u32 payload_bytes;
/* if non-zero, there is a payload to copy. */ /* if non-zero, there is a payload to copy. */
}; };
struct controlvm_packet_device_create { struct controlvm_packet_device_create {
u32 bus_no; /* bus # (0..n-1) from the msg receiver's end */ u32 bus_no; /* bus # (0..n-1) from the msg receiver's end */
u32 dev_no; /* bus-relative (0..n-1) device number */ u32 dev_no; /* bus-relative (0..n-1) device number */
u64 channel_addr; /* Guest physical address of the channel, which /* Guest physical address of the channel, which can be dereferenced by
* can be dereferenced by the receiver of this * the receiver of this ControlVm command
* ControlVm command */ */
u64 channel_addr;
u64 channel_bytes; /* specifies size of the channel in bytes */ u64 channel_bytes; /* specifies size of the channel in bytes */
uuid_le data_type_uuid; /* specifies format of data in channel */ uuid_le data_type_uuid; /* specifies format of data in channel */
uuid_le dev_inst_uuid; /* instance guid for the device */ uuid_le dev_inst_uuid; /* instance guid for the device */
...@@ -231,8 +234,8 @@ struct controlvm_packet_device_create { ...@@ -231,8 +234,8 @@ struct controlvm_packet_device_create {
}; /* for CONTROLVM_DEVICE_CREATE */ }; /* for CONTROLVM_DEVICE_CREATE */
struct controlvm_packet_device_configure { struct controlvm_packet_device_configure {
u32 bus_no; /* bus # (0..n-1) from the msg /* bus # (0..n-1) from the msg receiver's perspective */
* receiver's perspective */ u32 bus_no;
/* Control uses header SegmentIndex field to access bus number... */ /* Control uses header SegmentIndex field to access bus number... */
u32 dev_no; /* bus-relative (0..n-1) device number */ u32 dev_no; /* bus-relative (0..n-1) device number */
} ; /* for CONTROLVM_DEVICE_CONFIGURE */ } ; /* for CONTROLVM_DEVICE_CONFIGURE */
...@@ -251,50 +254,50 @@ struct controlvm_message_device_configure { ...@@ -251,50 +254,50 @@ struct controlvm_message_device_configure {
struct controlvm_message_packet { struct controlvm_message_packet {
union { union {
struct { struct {
u32 bus_no; /* bus # (0..n-1) from the msg /* bus # (0..n-1) from the msg receiver's perspective */
* receiver's perspective */ u32 bus_no;
u32 dev_count; /* indicates the max number of /* indicates the max number of devices on this bus */
* devices on this bus */ u32 dev_count;
u64 channel_addr; /* Guest physical address of /* Guest physical address of the channel, which can be
* the channel, which can be * dereferenced by the receiver of this ControlVm command
* dereferenced by the receiver */
* of this ControlVm command */ u64 channel_addr;
u64 channel_bytes; /* size of the channel */ u64 channel_bytes; /* size of the channel */
uuid_le bus_data_type_uuid; /* indicates format of /* indicates format of data in bus channel*/
* data in bus channel*/ uuid_le bus_data_type_uuid;
uuid_le bus_inst_uuid; /* instance uuid for the bus */ uuid_le bus_inst_uuid; /* instance uuid for the bus */
} create_bus; /* for CONTROLVM_BUS_CREATE */ } create_bus; /* for CONTROLVM_BUS_CREATE */
struct { struct {
u32 bus_no; /* bus # (0..n-1) from the msg /* bus # (0..n-1) from the msg receiver's perspective */
* receiver's perspective */ u32 bus_no;
u32 reserved; /* Natural alignment purposes */ u32 reserved; /* Natural alignment purposes */
} destroy_bus; /* for CONTROLVM_BUS_DESTROY */ } destroy_bus; /* for CONTROLVM_BUS_DESTROY */
struct { struct {
u32 bus_no; /* bus # (0..n-1) from the receiver's /* bus # (0..n-1) from the receiver's perspective */
* perspective */ u32 bus_no;
u32 reserved1; /* for alignment purposes */ u32 reserved1; /* for alignment purposes */
u64 guest_handle; /* This is used to convert /* This is used to convert guest physical address to physical address */
* guest physical address to u64 guest_handle;
* physical address */
u64 recv_bus_irq_handle; u64 recv_bus_irq_handle;
/* specifies interrupt info. It is used by SP /* specifies interrupt info. It is used by SP
* to register to receive interrupts from the * to register to receive interrupts from the
* CP. This interrupt is used for bus level * CP. This interrupt is used for bus level
* notifications. The corresponding * notifications. The corresponding
* sendBusInterruptHandle is kept in CP. */ * sendBusInterruptHandle is kept in CP.
*/
} configure_bus; /* for CONTROLVM_BUS_CONFIGURE */ } configure_bus; /* for CONTROLVM_BUS_CONFIGURE */
/* for CONTROLVM_DEVICE_CREATE */ /* for CONTROLVM_DEVICE_CREATE */
struct controlvm_packet_device_create create_device; struct controlvm_packet_device_create create_device;
struct { struct {
u32 bus_no; /* bus # (0..n-1) from the msg /* bus # (0..n-1) from the msg receiver's perspective */
* receiver's perspective */ u32 bus_no;
u32 dev_no; /* bus-relative (0..n-1) device # */ u32 dev_no; /* bus-relative (0..n-1) device # */
} destroy_device; /* for CONTROLVM_DEVICE_DESTROY */ } destroy_device; /* for CONTROLVM_DEVICE_DESTROY */
/* for CONTROLVM_DEVICE_CONFIGURE */ /* for CONTROLVM_DEVICE_CONFIGURE */
struct controlvm_packet_device_configure configure_device; struct controlvm_packet_device_configure configure_device;
struct { struct {
u32 bus_no; /* bus # (0..n-1) from the msg /* bus # (0..n-1) from the msg receiver's perspective */
* receiver's perspective */ u32 bus_no;
u32 dev_no; /* bus-relative (0..n-1) device # */ u32 dev_no; /* bus-relative (0..n-1) device # */
} reconfigure_device; /* for CONTROLVM_DEVICE_RECONFIGURE */ } reconfigure_device; /* for CONTROLVM_DEVICE_RECONFIGURE */
struct { struct {
...@@ -307,8 +310,8 @@ struct controlvm_message_packet { ...@@ -307,8 +310,8 @@ struct controlvm_message_packet {
u32 dev_no; u32 dev_no;
struct spar_segment_state state; struct spar_segment_state state;
struct { struct {
u32 phys_device:1; /* =1 if message is for /* =1 if message is for a physical device */
* a physical device */ u32 phys_device:1;
} flags; } flags;
u8 reserved[2]; /* Natural alignment purposes */ u8 reserved[2]; /* Natural alignment purposes */
} device_change_state; /* for CONTROLVM_DEVICE_CHANGESTATE */ } device_change_state; /* for CONTROLVM_DEVICE_CHANGESTATE */
...@@ -320,9 +323,10 @@ struct controlvm_message_packet { ...@@ -320,9 +323,10 @@ struct controlvm_message_packet {
} device_change_state_event; } device_change_state_event;
/* for CONTROLVM_DEVICE_CHANGESTATE_EVENT */ /* for CONTROLVM_DEVICE_CHANGESTATE_EVENT */
struct { struct {
u32 bus_count; /* indicates the max number of busses */ /* indicates the max number of busses */
u32 switch_count; /* indicates the max number of u32 bus_count;
* switches if a service partition */ /* indicates the max number of switches */
u32 switch_count;
enum ultra_chipset_feature features; enum ultra_chipset_feature features;
u32 platform_number; /* Platform Number */ u32 platform_number; /* Platform Number */
} init_chipset; /* for CONTROLVM_CHIPSET_INIT */ } init_chipset; /* for CONTROLVM_CHIPSET_INIT */
...@@ -330,11 +334,12 @@ struct controlvm_message_packet { ...@@ -330,11 +334,12 @@ struct controlvm_message_packet {
u32 options; /* reserved */ u32 options; /* reserved */
u32 test; /* bit 0 set to run embedded selftest */ u32 test; /* bit 0 set to run embedded selftest */
} chipset_selftest; /* for CONTROLVM_CHIPSET_SELFTEST */ } chipset_selftest; /* for CONTROLVM_CHIPSET_SELFTEST */
u64 addr; /* a physical address of something, that can be /* a physical address of something, that can be dereferenced
* dereferenced by the receiver of this * by the receiver of this ControlVm command
* ControlVm command (depends on command id) */ */
u64 handle; /* a handle of something (depends on command u64 addr;
* id) */ /* a handle of something (depends on command id) */
u64 handle;
}; };
}; };
...@@ -357,8 +362,8 @@ struct spar_controlvm_channel_protocol { ...@@ -357,8 +362,8 @@ struct spar_controlvm_channel_protocol {
u64 gp_nvram; /* guest phys addr of NVRAM channel */ u64 gp_nvram; /* guest phys addr of NVRAM channel */
u64 request_payload_offset; /* Offset to request payload area */ u64 request_payload_offset; /* Offset to request payload area */
u64 event_payload_offset; /* Offset to event payload area */ u64 event_payload_offset; /* Offset to event payload area */
u32 request_payload_bytes; /* Bytes available in request payload /* Bytes available in request payload area */
* area */ u32 request_payload_bytes;
u32 event_payload_bytes;/* Bytes available in event payload area */ u32 event_payload_bytes;/* Bytes available in event payload area */
u32 control_channel_bytes; u32 control_channel_bytes;
u32 nvram_channel_bytes; /* Bytes in PartitionNvram segment */ u32 nvram_channel_bytes; /* Bytes in PartitionNvram segment */
...@@ -384,41 +389,37 @@ struct spar_controlvm_channel_protocol { ...@@ -384,41 +389,37 @@ struct spar_controlvm_channel_protocol {
u64 virtual_guest_image_size; u64 virtual_guest_image_size;
u64 prototype_control_channel_offset; u64 prototype_control_channel_offset;
u64 virtual_guest_partition_handle; u64 virtual_guest_partition_handle;
/* Restore Action field to restore the guest partition */
u16 restore_action; /* Restore Action field to restore the guest u16 restore_action;
* partition */ /* For Windows guests it shows if the visordisk is in dump mode */
u16 dump_action; /* For Windows guests it shows if the visordisk u16 dump_action;
* is running in dump mode */
u16 nvram_fail_count; u16 nvram_fail_count;
u16 saved_crash_message_count; /* = CONTROLVM_CRASHMSG_MAX */ u16 saved_crash_message_count; /* = CONTROLVM_CRASHMSG_MAX */
u32 saved_crash_message_offset; /* Offset to request payload area needed /* Offset to request payload area needed for crash dump */
* for crash dump */ u32 saved_crash_message_offset;
u32 installation_error; /* Type of error encountered during /* Type of error encountered during installation */
* installation */ u32 installation_error;
u32 installation_text_id; /* Id of string to display */ u32 installation_text_id; /* Id of string to display */
u16 installation_remaining_steps;/* Number of remaining installation /* Number of remaining installation steps (for progress bars) */
* steps (for progress bars) */ u16 installation_remaining_steps;
u8 tool_action; /* ULTRA_TOOL_ACTIONS Installation Action /* ULTRA_TOOL_ACTIONS Installation Action field */
* field */ u8 tool_action;
u8 reserved; /* alignment */ u8 reserved; /* alignment */
struct efi_spar_indication efi_spar_ind; struct efi_spar_indication efi_spar_ind;
struct efi_spar_indication efi_spar_ind_supported; struct efi_spar_indication efi_spar_ind_supported;
u32 sp_reserved; u32 sp_reserved;
u8 reserved2[28]; /* Force signals to begin on 128-byte cache /* Force signals to begin on 128-byte cache line */
* line */ u8 reserved2[28];
struct signal_queue_header request_queue;/* Service or guest partition /* guest partition uses this queue to send requests to Control */
* uses this queue to send struct signal_queue_header request_queue;
* requests to Control */ /* Control uses this queue to respond to service or guest
struct signal_queue_header response_queue;/* Control uses this queue to * partition requests
* respond to service or guest */
* partition requests */ struct signal_queue_header response_queue;
struct signal_queue_header event_queue; /* Control uses this queue to /* Control uses this queue to send events to guest partition */
* send events to service or struct signal_queue_header event_queue;
* guest partition */ /* Service or guest partition uses this queue to ack Control events */
struct signal_queue_header event_ack_queue;/* Service or guest partition struct signal_queue_header event_ack_queue;
* uses this queue to ack
* Control events */
/* Request fixed-size message pool - does not include payload */ /* Request fixed-size message pool - does not include payload */
struct controlvm_message request_msg[CONTROLVM_MESSAGE_MAX]; struct controlvm_message request_msg[CONTROLVM_MESSAGE_MAX];
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment