diff options
author | Michael Sevakis <jethead71@rockbox.org> | 2013-08-17 12:18:22 -0400 |
---|---|---|
committer | Michael Sevakis <jethead71@rockbox.org> | 2013-08-17 12:18:22 -0400 |
commit | a56f1ca1ed63b93eb61fd5319f47347b3eb1e364 (patch) | |
tree | 62a253ba44b23c1867cef59fee40b40092719ee1 /firmware/drivers/ata.c | |
parent | c13f21a4d5c27c638c9f0dedf6d7b1f9bbb4d682 (diff) | |
download | rockbox-a56f1ca1ed63b93eb61fd5319f47347b3eb1e364.tar.gz rockbox-a56f1ca1ed63b93eb61fd5319f47347b3eb1e364.zip |
Cleanup MV/MD macros a little.
When using variadic macros there's no need for IF_MD2/IF_MV2 to deal
with function parameters. IF_MD/IF_MV are enough.
Throw in IF_MD_DRV/ID_MV_VOL that return the parameter if MD/MV, or 0
if not.
Change-Id: I7605e6039f3be19cb47110c84dcb3c5516f2c3eb
Diffstat (limited to 'firmware/drivers/ata.c')
-rw-r--r-- | firmware/drivers/ata.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/firmware/drivers/ata.c b/firmware/drivers/ata.c index ec04ac1426..4b365a50ab 100644 --- a/firmware/drivers/ata.c +++ b/firmware/drivers/ata.c | |||
@@ -567,7 +567,7 @@ static int ata_transfer_sectors(unsigned long start, | |||
567 | } | 567 | } |
568 | 568 | ||
569 | #ifndef MAX_PHYS_SECTOR_SIZE | 569 | #ifndef MAX_PHYS_SECTOR_SIZE |
570 | int ata_read_sectors(IF_MD2(int drive,) | 570 | int ata_read_sectors(IF_MD(int drive,) |
571 | unsigned long start, | 571 | unsigned long start, |
572 | int incount, | 572 | int incount, |
573 | void* inbuf) | 573 | void* inbuf) |
@@ -581,7 +581,7 @@ int ata_read_sectors(IF_MD2(int drive,) | |||
581 | #endif | 581 | #endif |
582 | 582 | ||
583 | #ifndef MAX_PHYS_SECTOR_SIZE | 583 | #ifndef MAX_PHYS_SECTOR_SIZE |
584 | int ata_write_sectors(IF_MD2(int drive,) | 584 | int ata_write_sectors(IF_MD(int drive,) |
585 | unsigned long start, | 585 | unsigned long start, |
586 | int count, | 586 | int count, |
587 | const void* buf) | 587 | const void* buf) |
@@ -623,7 +623,7 @@ static inline int flush_current_sector(void) | |||
623 | sector_cache.data, true); | 623 | sector_cache.data, true); |
624 | } | 624 | } |
625 | 625 | ||
626 | int ata_read_sectors(IF_MD2(int drive,) | 626 | int ata_read_sectors(IF_MD(int drive,) |
627 | unsigned long start, | 627 | unsigned long start, |
628 | int incount, | 628 | int incount, |
629 | void* inbuf) | 629 | void* inbuf) |
@@ -689,7 +689,7 @@ int ata_read_sectors(IF_MD2(int drive,) | |||
689 | return rc; | 689 | return rc; |
690 | } | 690 | } |
691 | 691 | ||
692 | int ata_write_sectors(IF_MD2(int drive,) | 692 | int ata_write_sectors(IF_MD(int drive,) |
693 | unsigned long start, | 693 | unsigned long start, |
694 | int count, | 694 | int count, |
695 | const void* buf) | 695 | const void* buf) |
@@ -1480,7 +1480,7 @@ int ata_spinup_time(void) | |||
1480 | } | 1480 | } |
1481 | 1481 | ||
1482 | #ifdef STORAGE_GET_INFO | 1482 | #ifdef STORAGE_GET_INFO |
1483 | void ata_get_info(IF_MD2(int drive,)struct storage_info *info) | 1483 | void ata_get_info(IF_MD(int drive,)struct storage_info *info) |
1484 | { | 1484 | { |
1485 | unsigned short *src,*dest; | 1485 | unsigned short *src,*dest; |
1486 | static char vendor[8]; | 1486 | static char vendor[8]; |