/* TLV Header Format * 3 2 1 * 1 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 * +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ * | Length |M|I|RSV| Type / ID | * +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ * * The TLV header format described above will be used for transferring * messages between the host and the firmware. To ensure byte ordering * we have defined all fields as being little endian. * Type/ID: Identifier for message and/or attribute * RSV: Reserved field for future use, likely as additional flags * I: cannot_ignore flag, identifies if unrecognized attribute can be ignored * M: is_msg, indicates that this is the start of a new message * Length: Total length of message in dwords including header * or * Total length of attribute in bytes including header
*/ struct fbnic_tlv_hdr { #ifdefined(__LITTLE_ENDIAN_BITFIELD)
u16 type : 12; /* 0 .. 11 Type / ID */
u16 rsvd : 2; /* 12 .. 13 Reserved for future use */
u16 cannot_ignore : 1; /* 14 Attribute can be ignored */
u16 is_msg : 1; /* 15 Header belongs to message */ #elifdefined(__BIG_ENDIAN_BITFIELD)
u16 is_msg : 1; /* 15 Header belongs to message */
u16 cannot_ignore : 1; /* 14 Attribute can be ignored */
u16 rsvd : 2; /* 13 .. 12 Reserved for future use */
u16 type : 12; /* 11 .. 0 Type / ID */ #else #error"Missing defines from byteorder.h" #endif
__le16 len; /* 16 .. 32 length including TLV header */
};
/* TLV Index * Defines the relationship between the attribute IDs and their types. * For each entry in the index there will be a size and type associated * with it so that we can use this to parse the data and verify it matches * the expected layout.
*/ struct fbnic_tlv_index {
u16 id;
u16 len; enum fbnic_tlv_type type;
};
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.