From nobody Tue Apr 25 16:17:54 2023 X-Original-To: bugs@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 4Q5RxG5MTmz47NQm for ; Tue, 25 Apr 2023 16:17:54 +0000 (UTC) (envelope-from bugzilla-noreply@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 4Q5RxG4JgTz3qwQ for ; Tue, 25 Apr 2023 16:17:54 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1682439474; 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: in-reply-to:in-reply-to:references:references; bh=LhoS5mWSrRzuiYsliZcRd9fsbB14OTe41d2X3UyVsWs=; b=PCPujLfC/PyWSfpkTux1QbC7l/aYhJFKAEJPfXkuXeOWj6sNDtGEFNeIpVMQUCURmUkI9+ geTDXwM/Ny8Sq0tEVY8LyjZj2YJctnk99Y3HhTw0esvbXxI3SuTDANuLzgVyLZfF5zYz2t plbbUB1tSXj8T/AUI0hm/eEBhGdXI3jLu6bG0qGB4Kz6RKVE4F9IwtIjG/EE+6NR4I7AUj iRjvDtCWOjZODYGyEo5hCr+PmzTXm9GzX458PhBm2/rcdyf3ZMdGS3w30XvwQrcrEa9TLJ mHXMyehE163k1rkwyW7PERKGt2AOo1d9dkWcXM0fAC1kn/M/Q2ownghiX9Yp+g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1682439474; a=rsa-sha256; cv=none; b=aDYwmPaOCbR4/Ee3zKWy7clTWKGYE8HsvdkMGdVIW+y3G7Jsczt+XwAbKJThB1IEven4iv JdYu6Jea1TTTUhDYbb9e3nJ3G4DjpmE7r6+TEM8LyX76QgJ5ouklTcD7op8a7b8FY2AtNP LzRkgZ6Q683Hka4pNzIy3AF5VU8PgbQwLcQ5HtlFOqQZESYLsCQ55WPkaoAtZvhPQOZrFA D4b1ydJgY44qur1I7ZvHgvAyJVOfg7yfxJou76mo23Mj+kNuRn6j5CThCGzJHQ/cEUEpNh FPIqClUP3bP3/9mUMowjBsqkqCdPn2/4oQ9Aoj0CTYX3ANvnjCzbrHrvkyCxsg== Received: from kenobi.freebsd.org (kenobi.freebsd.org [IPv6:2610:1c1:1:606c::50:1d]) (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 4Q5RxG3NyCz1DcX for ; Tue, 25 Apr 2023 16:17:54 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org ([127.0.1.5]) by kenobi.freebsd.org (8.15.2/8.15.2) with ESMTP id 33PGHsVp016040 for ; Tue, 25 Apr 2023 16:17:54 GMT (envelope-from bugzilla-noreply@freebsd.org) Received: (from www@localhost) by kenobi.freebsd.org (8.15.2/8.15.2/Submit) id 33PGHs6q016039 for bugs@FreeBSD.org; Tue, 25 Apr 2023 16:17:54 GMT (envelope-from bugzilla-noreply@freebsd.org) X-Authentication-Warning: kenobi.freebsd.org: www set sender to bugzilla-noreply@freebsd.org using -f From: bugzilla-noreply@freebsd.org To: bugs@FreeBSD.org Subject: [Bug 271062] [PATCH] add support for 28xx based device to isp(4) Date: Tue, 25 Apr 2023 16:17:54 +0000 X-Bugzilla-Reason: AssignedTo X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: Base System X-Bugzilla-Component: kern X-Bugzilla-Version: CURRENT X-Bugzilla-Keywords: X-Bugzilla-Severity: Affects Some People X-Bugzilla-Who: imp@FreeBSD.org X-Bugzilla-Status: New X-Bugzilla-Resolution: X-Bugzilla-Priority: --- X-Bugzilla-Assigned-To: bugs@FreeBSD.org X-Bugzilla-Flags: mfc-stable13? X-Bugzilla-Changed-Fields: cc Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: https://bugs.freebsd.org/bugzilla/ Auto-Submitted: auto-generated List-Id: Bug reports List-Archive: https://lists.freebsd.org/archives/freebsd-bugs List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-bugs@freebsd.org MIME-Version: 1.0 X-ThisMailContainsUnwantedMimeParts: N https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D271062 Warner Losh changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |imp@FreeBSD.org --- Comment #1 from Warner Losh --- I generally like this patch... however... - isp_prt(isp, ISP_LOGERR, "bad frame length (%d) from NVRAM- using %d", DEFAULT_FRAMESIZE(isp), ICB_DFLT_FRMLEN); - icbp->icb_maxfrmlen =3D ICB_DFLT_FRMLEN; + if (IS_28XX(isp)) { + isp_prt(isp, ISP_LOGERR, "bad frame length (%d) from NVRAM - using %d", DEFAULT_FRAMESIZE(isp), ICB_DFLT_FRMLEN_28XX); + icbp->icb_maxfrmlen =3D ICB_DFLT_FRMLEN_28XX; + } else { + isp_prt(isp, ISP_LOGERR, "bad frame length (%d) from NVRAM - using %d", DEFAULT_FRAMESIZE(isp), ICB_DFLT_FRMLEN); + icbp->icb_maxfrmlen =3D ICB_DFLT_FRMLEN; + } looks a little ugly to me. I'd be tempted to add a icbp->icb_dflt_frmlen fi= eld where we detect the 2800, set a different value. That way, we'd not need th= e if here with the code duplication. Other than that, the patch looks very good. --=20 You are receiving this mail because: You are the assignee for the bug.=