Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cleanup DOE header #2829

Merged
merged 1 commit into from
Sep 12, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 9 additions & 16 deletions include/industry_standard/pcidoe.h
Original file line number Diff line number Diff line change
Expand Up @@ -17,16 +17,15 @@

#pragma pack(1)


/* DOE header*/

/* DOE header
* The PCIe specification defines the size of a DW as four bytes. */
typedef struct {
uint16_t vendor_id;
uint8_t data_object_type;
uint8_t reserved;
/* length of the data object being transferred in number of DW, including the header (2 DW)
/* Length of the data object being transferred in number of DW, including the header (2 DW).
* It only includes bit[0~17], bit[18~31] are reserved.
* A value of 00000h indicate 2^18 DW == 2^20 byte.*/
* A value of 00000h indicate 2^18 DW == 2^20 bytes. */
uint32_t length;
/*uint32_t data_object_dw[length];*/
} pci_doe_data_object_header_t;
Expand All @@ -38,11 +37,9 @@ typedef struct {
#define PCI_DOE_DATA_OBJECT_TYPE_SECURED_SPDM 0x02

#define PCI_DOE_MAX_SIZE_IN_BYTE 0x00100000
#define PCI_DOE_MAX_SIZE_IN_DW 0x00040000


/* DOE Discovery*/
#define PCI_DOE_MAX_SIZE_IN_DW (PCI_DOE_MAX_SIZE_IN_BYTE / 4)

/* DOE Discovery */
typedef struct {
uint8_t index;
uint8_t version;
Expand All @@ -55,20 +52,16 @@ typedef struct {
uint8_t next_index;
} pci_doe_discovery_response_t;

/* SPDM Vendor Defined Message for PCI DOE. */

/* SPDM Vendor Defined Message for PCI DOE*/


/* PCI Protocol definition*/

/* PCI Protocol definition. */
typedef struct {
uint8_t protocol_id;
} pci_protocol_header_t;

#define PCI_PROTOCOL_ID_IDE_KM 0x00

/* Standard ID and Vendor ID for PCISIG*/

/* Standard ID and Vendor ID for PCISIG */
#define SPDM_STANDARD_ID_PCISIG SPDM_REGISTRY_ID_PCISIG
#define SPDM_VENDOR_ID_PCISIG 0x0001

Expand Down
Loading