From owner-svn-src-head@freebsd.org Mon May 23 19:52:09 2016 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id AFC2EB466D1; Mon, 23 May 2016 19:52:09 +0000 (UTC) (envelope-from ken@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 81A1D14D2; Mon, 23 May 2016 19:52:09 +0000 (UTC) (envelope-from ken@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id u4NJq8jB062659; Mon, 23 May 2016 19:52:08 GMT (envelope-from ken@FreeBSD.org) Received: (from ken@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id u4NJq8YH062658; Mon, 23 May 2016 19:52:08 GMT (envelope-from ken@FreeBSD.org) Message-Id: <201605231952.u4NJq8YH062658@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ken set sender to ken@FreeBSD.org using -f From: "Kenneth D. Merry" Date: Mon, 23 May 2016 19:52:08 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r300532 - head/sys/cam/ata X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.22 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 23 May 2016 19:52:09 -0000 Author: ken Date: Mon May 23 19:52:08 2016 New Revision: 300532 URL: https://svnweb.freebsd.org/changeset/base/300532 Log: Fix ada(4) trim support quirk setting. I broke broke the quirk in the ada(4) driver disabling NCQ trim support in revision 300207. The support flags were set before the quirks were loaded. sys/cam/ata/ata_da.c: Call adasetflags() after loading quirks, so that we'll set the flags accurately. Sponsored by: Spectra Logic Modified: head/sys/cam/ata/ata_da.c Modified: head/sys/cam/ata/ata_da.c ============================================================================== --- head/sys/cam/ata/ata_da.c Mon May 23 19:46:58 2016 (r300531) +++ head/sys/cam/ata/ata_da.c Mon May 23 19:52:08 2016 (r300532) @@ -1639,11 +1639,6 @@ adaregister(struct cam_periph *periph, v return(CAM_REQ_CMP_ERR); } - /* - * Set support flags based on the Identify data. - */ - adasetflags(softc, cgd); - periph->softc = softc; /* @@ -1683,6 +1678,12 @@ adaregister(struct cam_periph *periph, v snprintf(announce_buf, sizeof(announce_buf), "kern.cam.ada.%d.write_cache", periph->unit_number); TUNABLE_INT_FETCH(announce_buf, &softc->write_cache); + + /* + * Set support flags based on the Identify data and quirks. + */ + adasetflags(softc, cgd); + /* Disable queue sorting for non-rotational media by default. */ if (cgd->ident_data.media_rotation_rate == ATA_RATE_NON_ROTATING) { softc->rotating = 0;