union hisi_ptt_4dw { struct {
uint32_t format : 2;
uint32_t type : 5;
uint32_t t9 : 1;
uint32_t t8 : 1;
uint32_t th : 1;
uint32_t so : 1;
uint32_t len : 10;
uint32_t time : 11;
};
uint32_t value;
};
staticvoid hisi_ptt_print_pkt(constunsignedchar *buf, int pos, constchar *desc)
{ constchar *color = PERF_COLOR_BLUE; int i;
printf(".");
color_fprintf(stdout, color, " %08x: ", pos); for (i = 0; i < HISI_PTT_FIELD_LENTH; i++)
color_fprintf(stdout, color, "%02x ", buf[pos + i]); for (i = 0; i < HISI_PTT_MAX_SPACE_LEN; i++)
color_fprintf(stdout, color, " ");
color_fprintf(stdout, color, " %s\n", desc);
}
staticint hisi_ptt_8dw_kpt_desc(constunsignedchar *buf, int pos)
{ int i;
for (i = 0; i < HISI_PTT_8DW_TYPE_MAX; i++) { /* Do not show 8DW check field and reserved fields */ if (i == HISI_PTT_8DW_CHK_AND_RSV0 || i == HISI_PTT_8DW_RSV1) {
pos += HISI_PTT_FIELD_LENTH; continue;
}
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.