From owner-cvs-src@FreeBSD.ORG Wed Jan 21 15:22:31 2004 Return-Path: Delivered-To: cvs-src@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 6DA2716A4CE; Wed, 21 Jan 2004 15:22:31 -0800 (PST) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id AF91143D1D; Wed, 21 Jan 2004 15:22:29 -0800 (PST) (envelope-from jhb@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.12.10/8.12.10) with ESMTP id i0LNMT0B097694; Wed, 21 Jan 2004 15:22:29 -0800 (PST) (envelope-from jhb@repoman.freebsd.org) Received: (from jhb@localhost) by repoman.freebsd.org (8.12.10/8.12.10/Submit) id i0LNMTIQ097693; Wed, 21 Jan 2004 15:22:29 -0800 (PST) (envelope-from jhb) Message-Id: <200401212322.i0LNMTIQ097693@repoman.freebsd.org> From: John Baldwin Date: Wed, 21 Jan 2004 15:22:29 -0800 (PST) To: src-committers@FreeBSD.org, cvs-src@FreeBSD.org, cvs-all@FreeBSD.org X-FreeBSD-CVS-Branch: HEAD Subject: cvs commit: src/sys/boot/i386/libi386 biosdisk.c X-BeenThere: cvs-src@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: CVS commit messages for the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 21 Jan 2004 23:22:31 -0000 jhb 2004/01/21 15:22:29 PST FreeBSD src repository Modified files: sys/boot/i386/libi386 biosdisk.c Log: If a transfer to or from a floppy disk crosses a 64k boundary, we have to use a bounce buffer for the actual transfer to avoid crossing a 64k boundary. To do this, we malloc a buffer twice as big as we need and then find an aligned block within that buffer to do the transfer. The check to see which part of the block we use used the wrong variable for part of the condition meaning that in certain edge cases we would ask the BIOS to cross a 64k boundary. The BIOS request would then fail resulting in file transfers that just magically fail in the middle without any apparent reason. Specifically, my tests for the splitfs boot floppies managed to trigger this edge case. MFC after: 1 week X-MFC-info: along with fixes to libstand filesystems Revision Changes Path 1.41 +2 -2 src/sys/boot/i386/libi386/biosdisk.c