mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-28 02:32:09 -04:00
drivers/block/floppy.c: remove LAST_OUT macro
Macros with hidden returns are not nice. Convert the 2 uses to use direct code. Signed-off-by: Joe Perches <[email protected]> Cc: Stephen Hemminger <[email protected]> Cc: Jens Axboe <[email protected]> Cc: Marcin Slusarz <[email protected]> Cc: Bartlomiej Zolnierkiewicz <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
This commit is contained in:
parent
d7b2b2ecd8
commit
2300f90e31
1 changed files with 8 additions and 4 deletions
|
|
@ -1198,8 +1198,6 @@ static int output_byte(char byte)
|
|||
return -1;
|
||||
}
|
||||
|
||||
#define LAST_OUT(x) if (output_byte(x)<0){ reset_fdc();return;}
|
||||
|
||||
/* gets the response from the fdc */
|
||||
static int result(void)
|
||||
{
|
||||
|
|
@ -1679,7 +1677,10 @@ static void seek_floppy(void)
|
|||
do_floppy = seek_interrupt;
|
||||
output_byte(FD_SEEK);
|
||||
output_byte(UNIT(current_drive));
|
||||
LAST_OUT(track);
|
||||
if (output_byte(track) < 0) {
|
||||
reset_fdc();
|
||||
return;
|
||||
}
|
||||
debugt("seek command:");
|
||||
}
|
||||
|
||||
|
|
@ -1809,7 +1810,10 @@ static void recalibrate_floppy(void)
|
|||
debugt("recalibrate floppy:");
|
||||
do_floppy = recal_interrupt;
|
||||
output_byte(FD_RECALIBRATE);
|
||||
LAST_OUT(UNIT(current_drive));
|
||||
if (output_byte(UNIT(current_drive)) < 0) {
|
||||
reset_fdc();
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
|
|
|
|||
Loading…
Reference in a new issue