From 627457cd4a72324235296eb7be1c4ebfd065534a Mon Sep 17 00:00:00 2001 From: John Baldwin Date: Thu, 25 Oct 2007 16:53:35 +0000 Subject: [PATCH] Break out of the I/O retry loop as soon as an I/O operation succeeds rather than always retrying operations three times. Submitted by: nyan --- sys/boot/i386/libi386/biosdisk.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/sys/boot/i386/libi386/biosdisk.c b/sys/boot/i386/libi386/biosdisk.c index 5e96af46caa8..bd4d9d7fd0fe 100644 --- a/sys/boot/i386/libi386/biosdisk.c +++ b/sys/boot/i386/libi386/biosdisk.c @@ -1251,6 +1251,8 @@ bd_io(struct open_disk *od, daddr_t dblk, int blks, caddr_t dest, int write) result = bd_edd_io(od, dblk, x, xp, write); else result = bd_chs_io(od, dblk, x, xp, write); + if (result == 0) + break; } if (write)