From f71c8fb531f6db841248c66f814af859eb48f469 Mon Sep 17 00:00:00 2001 From: "H. Peter Anvin" Date: Thu, 13 May 2010 15:39:29 -0700 Subject: [PATCH] diskio: compare to the proper pointer We need to compare against the advanced pointer, not the original one. Signed-off-by: H. Peter Anvin --- core/fs/diskio.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/core/fs/diskio.c b/core/fs/diskio.c index d2f1671..464cca6 100644 --- a/core/fs/diskio.c +++ b/core/fs/diskio.c @@ -133,7 +133,7 @@ static int edd_rdwr_sectors(struct disk *disk, void *buf, freeseg = (0x10000 - ((size_t)ptr & 0xffff)) >> sector_shift; - if ((size_t)buf <= 0xf0000 && freeseg) { + if ((size_t)ptr <= 0xf0000 && freeseg) { /* Can do a direct load */ tptr = ptr; } else { -- 2.7.4