From nobody Thu Oct 19 03:24:54 2023 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4S9tPf2bWgz4xt3y; Thu, 19 Oct 2023 03:24:54 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S9tPf25Y8z4JNb; Thu, 19 Oct 2023 03:24:54 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1697685894; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=P1G2UhIzh58uT5rLgi9LSTXhxaFL7hRGEhagzD5CJMc=; b=V0B3z3l9tt8o3CTI5CqoZknkcvDf1UOeNchzzdDrzZvysDEUPe/01vkvhoCUjrjsNRgXjR kZTpHNITNR03+X9oOqAl91a3gDTkWNllATC0c1Xq50JDvqALDobKOkIpV3Cv6N3fF6Z0/5 6CAUP1ygPpnGOnHp4B8KmV+vUE4OGdx2PmCOm810DSNqhoB+pLjHIvUifDUqdjsRxampa3 2VGcxnWC82buIuV7EQyXpNeBr9fo1ilhVsxVKnSng0z2nj/pAvjUOaamfrm1jEA330JGhF afBYg+ekRsgbiiaXxPiKyE3pw5UH0WLzkKmrDE5HaE8u0DfG4m/eSRDgyH9fEg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1697685894; a=rsa-sha256; cv=none; b=YRMO5jV9Lj6ytGA21SvG1Jtj1MymXUr4672rbtqCDdn3J6Tdx1OvpgPLPF/5hK+twTNR0p ChGWkGPuMkp93E4uMCCyOfeHezvJD80eHMxhkrYcLOXYgmMrKK2MI5B6E23lT8dKOTQbfm cerDRRo81u90bAUxa6WF0JDmYUZX3i2v87ymgchY+iEm/Kpygcnnt+GgB2GX7SwJ9cZqCM SHOPEEompxq6hvFNLMqbZA4tItBUxcc807mMTi9xwpRnLcjmNyiIEQRwgxsrgXLulkzlWo zCrKWSqCrdu9asI5gaeERlWKv6sNpkcjyjTPTdzONcNF/Do7DrO/IHcSoTmqNg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1697685894; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=P1G2UhIzh58uT5rLgi9LSTXhxaFL7hRGEhagzD5CJMc=; b=Hg7EBe5FTO/wU+FTWCFxdGU9ngYhAUhYghPLD+63b4LCqS6tFjBMErFjVAzOHT42GAUXUt YBnL71lWiTxqRQX/c7Kck9sJH6pm8gWzqM41FsCQ5HqF1BQF8YTmpKePG5wKGdqWC7IS7S 8nV4hlXYdX/GR9a+sqVCb3wGbkGMOHqRd/xOt0QlPHTmD4556Hhosq+T47gcpDDP7jMCci z8x2DPFmHPFV24w4Hft7hQgrhJXuqDYjoBb6gJ3yk7nazof0ZiFlqmoarLc8Cj1wZdA0Av 6b1AcBJ2o3WZ7YFa2azHsuoykNqcDUP1HanWSZVVqiAJWDyYHs+ovlYk3iYlCw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4S9tPf18v4zYdm; Thu, 19 Oct 2023 03:24:54 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 39J3Os7w078939; Thu, 19 Oct 2023 03:24:54 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 39J3OsqK078936; Thu, 19 Oct 2023 03:24:54 GMT (envelope-from git) Date: Thu, 19 Oct 2023 03:24:54 GMT Message-Id: <202310190324.39J3OsqK078936@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Warner Losh Subject: git: f07b267d8cc8 - main - smartpqi: Change alignment for dma tags List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-all@freebsd.org X-BeenThere: dev-commits-src-all@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: f07b267d8cc87e88be3c78aa69504b5ebc6571ee Auto-Submitted: auto-generated The branch main has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=f07b267d8cc87e88be3c78aa69504b5ebc6571ee commit f07b267d8cc87e88be3c78aa69504b5ebc6571ee Author: John Hall AuthorDate: 2023-10-19 03:10:58 +0000 Commit: Warner Losh CommitDate: 2023-10-19 03:12:27 +0000 smartpqi: Change alignment for dma tags Problem: Under certain I/O conditions, a program doing large block disk reads can cause a controller to crash. Root Cause: The SCSI read request and destination address in the BDMA descriptor is incorrect, causing the BDMA engine in the controller to assert. Fix: Change the alignment for creating bus_dma_tags in the driver from PAGE_SIZE (4k) to 1, which allows the controller to manage it's own address range for BDMA transactions. Risk: Medium Exposure: This reverts a change first made to support NVMe drives on Excalibur. At that time a 4k alignment was necessary. This no longer seems to be the case. PR: 259541 Reported by: Ka Ho Ng Reviewed by: imp Differential Revision: https://reviews.freebsd.org/D41619 --- sys/dev/smartpqi/smartpqi_main.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/dev/smartpqi/smartpqi_main.c b/sys/dev/smartpqi/smartpqi_main.c index e79a6f0a173f..402841bbf4d6 100644 --- a/sys/dev/smartpqi/smartpqi_main.c +++ b/sys/dev/smartpqi/smartpqi_main.c @@ -629,8 +629,8 @@ smartpqi_attach(device_t dev) * Create DMA tag for mapping buffers into controller-addressable space. */ if (bus_dma_tag_create(softs->os_specific.pqi_parent_dmat,/* parent */ - PAGE_SIZE, 0, /* algnmnt, boundary */ - BUS_SPACE_MAXADDR,/* lowaddr */ + 1, 0, /* algnmnt, boundary */ + BUS_SPACE_MAXADDR, /* lowaddr */ BUS_SPACE_MAXADDR, /* highaddr */ NULL, NULL, /* filter, filterarg */ (bus_size_t)softs->pqi_cap.max_sg_elem*PAGE_SIZE,/* maxsize */