From nobody Fri Aug 05 01:32:46 2022 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 4LzSlM1bH5z4YZK6; Fri, 5 Aug 2022 01:32:47 +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 4LzSlM0zvLz3D5d; Fri, 5 Aug 2022 01:32:47 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1659663167; 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=38Ptr0Ga8GSZoQxpwTrf76HNF2FKEPXj9CPHoADGg6k=; b=AJxA19n8MkvgAFSVF0PFqPPbiDTqHZB+KV8h6Y0toq4agWkbCqCZGxyhFGOk+oL5n5rNMe WZFhyCk99WXK8M+9A8dYlAYulgmDEltGEFN5rvCXWtaK8OAfM5ZOSv9/pC+q5iCIfSrUN1 U5EvUkhvp51coRpN8us2kTegue01qskhwNKHuuj4NFs9FA4omgHCz6hvr4Suaj2u0KmtEG hm9TRYfg2qUPO8fnK3p7RbjzDQI21HM1yCWEqJEOpU3cJHgW0d6JUL+a6oQDJJJx1nTNlt qTtDWCcytn7bbMGLi0lty6dC7UzIKfoR838krD6RK4XRROJ8PjVgKXzQJU/HWg== 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 4LzSlM02QjzcCx; Fri, 5 Aug 2022 01:32:47 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 2751Wk8E007048; Fri, 5 Aug 2022 01:32:46 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 2751Wkl6007047; Fri, 5 Aug 2022 01:32:46 GMT (envelope-from git) Date: Fri, 5 Aug 2022 01:32:46 GMT Message-Id: <202208050132.2751Wkl6007047@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Justin Hibbits Subject: git: c0665d5c8240 - main - powerpc/fsl_sata: Properly clamp maxio to pessimized size 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: jhibbits X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: c0665d5c82407a41591532ac75bc37a13d3314e6 Auto-Submitted: auto-generated ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1659663167; 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=38Ptr0Ga8GSZoQxpwTrf76HNF2FKEPXj9CPHoADGg6k=; b=oifWY/IjFyKgLtz0pqVRkGFtYifob0Yr00x8/nL3scgmjH6hG8yJWlSCdnDnnggAiahtDE kPOwU9nOQc8gWl6t/Ak9T4jjdSjjE9MgFHDbBP2FH1fWIrdhwK/YpCaW9A6GWbsG2ofhlC U65MoYafozFL/6louMZWqxDJpCIMipAHbUZVidyQ3X0R1BZCHWFWVNOr6VEU9VN97pnbEK D9f21nAC1hPCVlKtp2fD1JiYy+INOaCYTeoUKByCaAolPlrWW5yLgDFFIN4fpuiqIstrFe ddKzZK4GROnfetXwSCQ51XRQBQtf4JE7TZ3tkC3+kmO9aZ6v/N+zpfl11m3UXw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1659663167; a=rsa-sha256; cv=none; b=Y/87ejUE6KjWEaOwdDGUl7UTxJDLVZaHztKqekz9hAgMl/I1+rgI8xxwnS9HSPFKFdPYUj al+3qq171jhnowt42h7tW21umBtnjM+Tl2YEe/KWoPr4N9lIp4cF4/eLP8bsI0UhhN7Evr citzO7zJb+w3m1zey9cfIq4FGDzthnNQamPjIPEFUl79p6eZyfsA9A1UnfW9n9ZHY9gsLY IK0U0hCFUDg7s3mt1e2Www76f4lg08aM6DYvbp0qW7lvp2CEav/KzTiwkjzK323pvFC3Ro 3PBUPXJmFpV6izQsywPPA66h8Ndy7gFcVpeHzRFgiankp5Bg7+IyDVqo+ZllhQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none X-ThisMailContainsUnwantedMimeParts: N The branch main has been updated by jhibbits: URL: https://cgit.FreeBSD.org/src/commit/?id=c0665d5c82407a41591532ac75bc37a13d3314e6 commit c0665d5c82407a41591532ac75bc37a13d3314e6 Author: Justin Hibbits AuthorDate: 2022-08-05 01:28:21 +0000 Commit: Justin Hibbits CommitDate: 2022-08-05 01:32:03 +0000 powerpc/fsl_sata: Properly clamp maxio to pessimized size The CAM 'maxio' is a 'pessimized' size, assuming 4k pages and one page per segment. Since there are at most 63 segments in a transaction with this driver, and one would necessarily be the indirect segment marker, clamp the maxio to the minimum of maxphys (tunable) or (63 - 1) pages (248k). MFC after: 3 days --- sys/powerpc/mpc85xx/fsl_sata.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/powerpc/mpc85xx/fsl_sata.c b/sys/powerpc/mpc85xx/fsl_sata.c index ffd340a557d8..22b9a7baf0fb 100644 --- a/sys/powerpc/mpc85xx/fsl_sata.c +++ b/sys/powerpc/mpc85xx/fsl_sata.c @@ -1871,7 +1871,7 @@ fsl_sataaction(struct cam_sim *sim, union ccb *ccb) cpi->transport_version = XPORT_VERSION_UNSPECIFIED; cpi->protocol = PROTO_ATA; cpi->protocol_version = PROTO_VERSION_UNSPECIFIED; - cpi->maxio = maxphys; + cpi->maxio = (FSL_SATA_SG_ENTRIES - 1) * PAGE_SIZE; cpi->ccb_h.status = CAM_REQ_CMP; break; }