Grouping register dumps by 8 register values per group for better readability.
Remove trailing spaces within the register dumps. Signed-off-by: Frieder Ferlemann <Frieder.Ferlemann@web.de> Acked-by: Uwe Hermann <uwe@hermann-uwe.de> git-svn-id: svn://svn.coreboot.org/coreboot/trunk@2957 2b7e53f0-3cfb-0310-b3e9-8179ed1497e1
This commit is contained in:
parent
9c22e8625f
commit
a422c2d3c6
|
@ -82,9 +82,9 @@ static void dump_regs(const struct superio_registers reg_table[],
|
||||||
const int *idx;
|
const int *idx;
|
||||||
|
|
||||||
if (reg_table[i].ldn[j].ldn != NOLDN) {
|
if (reg_table[i].ldn[j].ldn != NOLDN) {
|
||||||
printf("LDN 0x%02x ", reg_table[i].ldn[j].ldn);
|
printf("LDN 0x%02x", reg_table[i].ldn[j].ldn);
|
||||||
if (reg_table[i].ldn[j].name != NULL)
|
if (reg_table[i].ldn[j].name != NULL)
|
||||||
printf("(%s)", reg_table[i].ldn[j].name);
|
printf(" (%s)", reg_table[i].ldn[j].name);
|
||||||
regwrite(port, 0x07, reg_table[i].ldn[j].ldn);
|
regwrite(port, 0x07, reg_table[i].ldn[j].ldn);
|
||||||
} else {
|
} else {
|
||||||
printf("Register dump:");
|
printf("Register dump:");
|
||||||
|
@ -92,33 +92,33 @@ static void dump_regs(const struct superio_registers reg_table[],
|
||||||
|
|
||||||
idx = reg_table[i].ldn[j].idx;
|
idx = reg_table[i].ldn[j].idx;
|
||||||
|
|
||||||
printf("\nidx ");
|
printf("\nidx");
|
||||||
for (k = 0; /* Nothing */; k++) {
|
for (k = 0; idx[k] != EOT; k++) {
|
||||||
if (idx[k] == EOT)
|
if (k && !(k % 8))
|
||||||
break;
|
putchar(' ');
|
||||||
printf("%02x ", idx[k]);
|
printf(" %02x", idx[k]);
|
||||||
}
|
}
|
||||||
|
|
||||||
printf("\nval ");
|
printf("\nval");
|
||||||
for (k = 0; /* Nothing */; k++) {
|
for (k = 0; idx[k] != EOT; k++) {
|
||||||
if (idx[k] == EOT)
|
if (k && !(k % 8))
|
||||||
break;
|
putchar(' ');
|
||||||
printf("%02x ", regval(port, idx[k]));
|
printf(" %02x", regval(port, idx[k]));
|
||||||
}
|
}
|
||||||
|
|
||||||
printf("\ndef ");
|
printf("\ndef");
|
||||||
idx = reg_table[i].ldn[j].def;
|
idx = reg_table[i].ldn[j].def;
|
||||||
for (k = 0; /* Nothing */; k++) {
|
for (k = 0; idx[k] != EOT; k++) {
|
||||||
if (idx[k] == EOT)
|
if (k && !(k % 8))
|
||||||
break;
|
putchar(' ');
|
||||||
else if (idx[k] == NANA)
|
if (idx[k] == NANA)
|
||||||
printf("NA ");
|
printf(" NA");
|
||||||
else if (idx[k] == RSVD)
|
else if (idx[k] == RSVD)
|
||||||
printf("RR ");
|
printf(" RR");
|
||||||
else if (idx[k] == MISC) /* TODO */
|
else if (idx[k] == MISC) /* TODO */
|
||||||
printf("MM ");
|
printf(" MM");
|
||||||
else
|
else
|
||||||
printf("%02x ", idx[k]);
|
printf(" %02x", idx[k]);
|
||||||
}
|
}
|
||||||
printf("\n");
|
printf("\n");
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue