From owner-svn-src-all@FreeBSD.ORG Tue Jun 18 09:26:01 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 9E9356D6; Tue, 18 Jun 2013 09:26:01 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 90FD61A50; Tue, 18 Jun 2013 09:26:01 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.7/8.14.7) with ESMTP id r5I9Q19O083842; Tue, 18 Jun 2013 09:26:01 GMT (envelope-from mav@svn.freebsd.org) Received: (from mav@localhost) by svn.freebsd.org (8.14.7/8.14.5/Submit) id r5I9Q158083840; Tue, 18 Jun 2013 09:26:01 GMT (envelope-from mav@svn.freebsd.org) Message-Id: <201306180926.r5I9Q158083840@svn.freebsd.org> From: Alexander Motin Date: Tue, 18 Jun 2013 09:26:01 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org Subject: svn commit: r251918 - stable/9/sys/geom/gate X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 18 Jun 2013 09:26:01 -0000 Author: mav Date: Tue Jun 18 09:26:01 2013 New Revision: 251918 URL: http://svnweb.freebsd.org/changeset/base/251918 Log: MFC r248295 (by pjd): We don't need buffer to handle BIO_DELETE, so don't check buffer size for it. This fixes handling BIO_DELETE larger than MAXPHYS. Modified: stable/9/sys/geom/gate/g_gate.c Directory Properties: stable/9/sys/ (props changed) Modified: stable/9/sys/geom/gate/g_gate.c ============================================================================== --- stable/9/sys/geom/gate/g_gate.c Tue Jun 18 09:23:03 2013 (r251917) +++ stable/9/sys/geom/gate/g_gate.c Tue Jun 18 09:26:01 2013 (r251918) @@ -813,7 +813,7 @@ g_gate_ioctl(struct cdev *dev, u_long cm } } ggio->gctl_cmd = bp->bio_cmd; - if ((bp->bio_cmd == BIO_DELETE || bp->bio_cmd == BIO_WRITE) && + if (bp->bio_cmd == BIO_WRITE && bp->bio_length > ggio->gctl_length) { mtx_unlock(&sc->sc_queue_mtx); ggio->gctl_length = bp->bio_length;