Revision b1503cda hw/fdc.c
b/hw/fdc.c | ||
---|---|---|
1851 | 1851 |
int i, j; |
1852 | 1852 |
|
1853 | 1853 |
/* Fill 'command_to_handler' lookup table */ |
1854 |
for (i = sizeof(handlers)/sizeof(handlers[0]) - 1; i >= 0; i--) {
|
|
1854 |
for (i = ARRAY_SIZE(handlers) - 1; i >= 0; i--) {
|
|
1855 | 1855 |
for (j = 0; j < sizeof(command_to_handler); j++) { |
1856 | 1856 |
if ((j & handlers[i].mask) == handlers[i].value) |
1857 | 1857 |
command_to_handler[j] = i; |
Also available in: Unified diff