Skip to content

Commit 4ad4383

Browse files
authored
Merge pull request #4 from paulmenzel/fix-whitespace-in-romheaders
Fix whitespace in romheaders
2 parents 499e813 + c7e59ce commit 4ad4383

1 file changed

Lines changed: 15 additions & 16 deletions

File tree

romheaders/romheaders.c

Lines changed: 15 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -63,18 +63,18 @@ static bool dump_rom_header(rom_header_t *data)
6363
const u16 pci_header_signature = 0x55aa;
6464
u16 sig=BIG_ENDIAN_WORD_FETCH(data->signature);
6565
int i;
66-
66+
6767
printf ("PCI Expansion ROM Header:\n");
68-
69-
printf (" Signature: 0x%04x (%s)\n",
68+
69+
printf (" Signature: 0x%04x (%s)\n",
7070
sig, sig == pci_header_signature ? "Ok":"Not Ok");
71-
71+
7272
printf (" CPU unique data:");
7373
for (i=0;i<16;i++) {
7474
printf(" 0x%02x",data->reserved[i]);
7575
if (i==7) printf("\n ");
7676
}
77-
77+
7878
printf ("\n Pointer to PCI Data Structure: 0x%04x\n\n",
7979
LITTLE_ENDIAN_WORD_FETCH(data->data_ptr));
8080

@@ -89,7 +89,7 @@ static bool dump_pci_data(pci_data_t *data)
8989
u32 classcode= CLASS_CODE_FETCH(data->class_code);
9090
u32 dlen = (u32)LITTLE_ENDIAN_WORD_FETCH(data->dlen);
9191
u32 ilen = (u32)LITTLE_ENDIAN_WORD_FETCH(data->ilen);
92-
92+
9393
printf("PCI Data Structure:\n");
9494
printf(" Signature: 0x%04x '%c%c%c%c' ", sig,
9595
sig>>24,(sig>>16)&0xff, (sig>>8)&0xff, sig&0xff);
@@ -119,7 +119,7 @@ static bool dump_pci_data(pci_data_t *data)
119119
static void dump_platform_extensions(u8 type, rom_header_t *data)
120120
{
121121
u32 entry;
122-
122+
123123
switch (type) {
124124
case 0x00:
125125
printf("Platform specific data for x86 compliant option rom:\n");
@@ -130,7 +130,7 @@ static void dump_platform_extensions(u8 type, rom_header_t *data)
130130
* to output correct offset for init code. Once again x86
131131
* is ugly.
132132
*/
133-
133+
134134
switch (data->reserved[1]) {
135135
case 0xeb: /* short jump */
136136
entry = data->reserved[2] + 2;
@@ -155,7 +155,7 @@ static void dump_platform_extensions(u8 type, rom_header_t *data)
155155
} else
156156
printf( " Unable to determine entry point for INIT"
157157
" function. Please report.\n\n");
158-
158+
159159
break;
160160
case 0x01:
161161
printf("Platform specific data for Open Firmware compliant rom:\n");
@@ -185,7 +185,7 @@ int main(int argc, char **argv)
185185
" specs 2.2 in human readable form\n\n");
186186
return -1;
187187
}
188-
188+
189189
if (stat(name,&finfo)) {
190190
printf("Error while reading file information.\n");
191191
return -1;
@@ -212,7 +212,7 @@ int main(int argc, char **argv)
212212
}
213213

214214
fclose(romfile);
215-
215+
216216
rom_header=(rom_header_t *)rom;
217217

218218
do {
@@ -221,17 +221,17 @@ int main(int argc, char **argv)
221221
printf("Rom Header error occured. Bailing out.\n");
222222
break;
223223
}
224-
224+
225225
pci_data = (pci_data_t *)((char *)rom_header +
226226
LITTLE_ENDIAN_WORD_FETCH(rom_header->data_ptr));
227-
227+
228228
if (!dump_pci_data(pci_data)) {
229229
printf("PCI Data error occured. Bailing out.\n");
230230
break;
231231
}
232-
232+
233233
dump_platform_extensions(pci_data->code_type, rom_header);
234-
234+
235235
rom_header = (rom_header_t *)((char *)rom_header +
236236
LITTLE_ENDIAN_WORD_FETCH(pci_data->ilen)*512);
237237
i++;
@@ -240,4 +240,3 @@ int main(int argc, char **argv)
240240

241241
return 0;
242242
}
243-

0 commit comments

Comments
 (0)