From owner-freebsd-arch@FreeBSD.ORG Mon Oct 6 14:55:22 2003 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id F179E16A4BF for ; Mon, 6 Oct 2003 14:55:22 -0700 (PDT) Received: from critter.freebsd.dk (critter.freebsd.dk [212.242.86.163]) by mx1.FreeBSD.org (Postfix) with ESMTP id BF28743FE9 for ; Mon, 6 Oct 2003 14:55:21 -0700 (PDT) (envelope-from phk@phk.freebsd.dk) Received: from critter.freebsd.dk (localhost [127.0.0.1]) by critter.freebsd.dk (8.12.9/8.12.9) with ESMTP id h96LtH2B026370; Mon, 6 Oct 2003 23:55:18 +0200 (CEST) (envelope-from phk@phk.freebsd.dk) To: Garrett Wollman From: "Poul-Henning Kamp" In-Reply-To: Your message of "Mon, 06 Oct 2003 17:46:51 EDT." <200310062146.h96Lkpx0093486@khavrinen.lcs.mit.edu> Date: Mon, 06 Oct 2003 23:55:17 +0200 Message-ID: <26369.1065477317@critter.freebsd.dk> cc: arch@FreeBSD.org Subject: Re: Alignment of disk-I/O from userland. X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 06 Oct 2003 21:55:23 -0000 In message <200310062146.h96Lkpx0093486@khavrinen.lcs.mit.edu>, Garrett Wollman writes: >I think that gives us plenary authority to require appropriate >alignment of data buffers used to access disk devices directly. Well, apart from us wedging or botching the request rather than return a consistent error we're standards compliant then. It has been mentioned on #thatchannel that busdma should take care of this by copying the request as necessary. Faced with the prospect of a request several megabytes in size, I don't like the prospect of malloc/bcopy too much. All in all, I would advocate that we decide that disks in FreeBSD are allowed to return ENXIO if they get insufficiently aligned requests. -- Poul-Henning Kamp | UNIX since Zilog Zeus 3.20 phk@FreeBSD.ORG | TCP/IP since RFC 956 FreeBSD committer | BSD since 4.3-tahoe Never attribute to malice what can adequately be explained by incompetence.