From nobody Sun Dec 1 04:57:51 2024 X-Original-To: dev-commits-src-branches@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 4Y1F681vbMz5gDFj; Sun, 01 Dec 2024 04:57:52 +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 "R10" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4Y1F680lpBz4Cnf; Sun, 1 Dec 2024 04:57:52 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733029072; 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=Q70V0mImQRh8OUFVQ7P7XA3CiwILdh+480oN44KGsiE=; b=diXMWsyD629VTgaXcVpWTB0wj+T33tARGRf0q2T/qO5OSpjo9/wojLvv2Qm2vGEAwee6N8 f5qbOGg9nz50Ho1srug/Mw5bOnzICU6CRzNbSQT/uBpaKW7o4RN58JlgcEyYJ0XY3+f1F6 2GmeCuaCA4xyyR/6DwNVnBQoyejg8n78+PJ9TVMpi7zv1bGhVRcG2qPRc0vOK2AglYarDW rOOgd7jlSAwwNQxiUfy5rFQ6/uK4o6emqD7gnCw/o+UwMOt0ng1gDyLZeXpq6xIEnPHp0v jqEb0fWoXw2wAEl8+Joh8rBdcVvFIpJ3uzn+yO0DIs9Nv4aZyZWDYKKhfD8/nQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733029072; 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=Q70V0mImQRh8OUFVQ7P7XA3CiwILdh+480oN44KGsiE=; b=OUTkkgn+fMUTwn327r0hTmpfs+39pD9eOGbMakCWlTlvFRIijDojKflIeVVuz3utjzm9cf 5NSqDmG4Q6j2iAnVY3P140expVkGoEwT11Un6bowKrUvjO+4EXwXXUMTAIIQNVIc+5GQ8i 1Y17DDeOXLB52mSsACZxzeavDOpX8+lcM5MSdWxkQfzIhJG+qalj3a+aX2yHz1PukXvWk1 dIDDD7Q0AGlKENRBCSzzV6rq9Zz4erEeKAKail3vnBb7zVqEuc1a1SQW6BmeYZ9Otpnlv5 bCvw3YRTZTf/9T6XYVzaarQ2JXQlkPHcARjn76azueEwgk7cKWuZ1cRx/dnPFg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733029072; a=rsa-sha256; cv=none; b=sp/cMGWsSF58FSXNg5BcE5YJZTSll7nbrpka7242lyt52K2FT5DgJ4EWhh4o53paB7edQG 7tJqftwjRyBmRCU6Otrcn1AH0OCkiA78TMD7M18v1YO62FnvS/Z9qx4z0vCpli5eSHhh5y 55ES0EsS9N/SfzLokwdnX2Dip1eDS66vl53ChR5/FPkI7cX1OyH2Yv40VY2ptuNFmnsdom XM9goms1hHcFZsxMf0w1csX6mgs6egcY/G9MINrTJS34SWZHciFsMWvzdMrFXymdbEtxM5 CZm1wJ2JrD4WXAZezy6gxqx/qDs3gUagYhs4ZaTMFow2OclvSon4FAWuboaRyw== 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 4Y1F680KFBzfJD; Sun, 1 Dec 2024 04:57:52 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 4B14vpRc097147; Sun, 1 Dec 2024 04:57:51 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4B14vpXf097144; Sun, 1 Dec 2024 04:57:51 GMT (envelope-from git) Date: Sun, 1 Dec 2024 04:57:51 GMT Message-Id: <202412010457.4B14vpXf097144@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: John Baldwin Subject: git: c93b892f71cf - stable/13 - ctl_report_supported_opcodes: Rename invalid label to invalid_options List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: jhb X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: c93b892f71cfe1e624b82adbba8492e460a8f235 Auto-Submitted: auto-generated The branch stable/13 has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=c93b892f71cfe1e624b82adbba8492e460a8f235 commit c93b892f71cfe1e624b82adbba8492e460a8f235 Author: John Baldwin AuthorDate: 2024-09-25 14:20:22 +0000 Commit: John Baldwin CommitDate: 2024-11-30 21:38:28 +0000 ctl_report_supported_opcodes: Rename invalid label to invalid_options This error handling is specific to an invalid value in the REPORTING OPTIONS field of a REPORT SUPPORTED OPERATION CODES command. While here, reuse the label for another case. Reviewed by: imp, emaste Differential Revision: https://reviews.freebsd.org/D46775 (cherry picked from commit 0063ef79f9e6b9ad47969af3b94ae63e7888852c) --- sys/cam/ctl/ctl.c | 15 ++++----------- 1 file changed, 4 insertions(+), 11 deletions(-) diff --git a/sys/cam/ctl/ctl.c b/sys/cam/ctl/ctl.c index 13b7995fd74c..02feb19cd8f0 100644 --- a/sys/cam/ctl/ctl.c +++ b/sys/cam/ctl/ctl.c @@ -7493,33 +7493,26 @@ ctl_report_supported_opcodes(struct ctl_scsiio *ctsio) break; case RSO_OPTIONS_OC: if (ctl_cmd_table[opcode].flags & CTL_CMD_FLAG_SA5) { - ctl_set_invalid_field(/*ctsio*/ ctsio, - /*sks_valid*/ 1, - /*command*/ 1, - /*field*/ 2, - /*bit_valid*/ 1, - /*bit*/ 2); - ctl_done((union ctl_io *)ctsio); - return (CTL_RETVAL_COMPLETE); + goto invalid_options; } total_len = sizeof(struct scsi_report_supported_opcodes_one) + 32; break; case RSO_OPTIONS_OC_SA: if ((ctl_cmd_table[opcode].flags & CTL_CMD_FLAG_SA5) == 0 || service_action >= 32) { - goto invalid; + goto invalid_options; } total_len = sizeof(struct scsi_report_supported_opcodes_one) + 32; break; case RSO_OPTIONS_OC_ASA: if ((ctl_cmd_table[opcode].flags & CTL_CMD_FLAG_SA5) != 0 && service_action >= 32) { - goto invalid; + goto invalid_options; } total_len = sizeof(struct scsi_report_supported_opcodes_one) + 32; break; default: -invalid: +invalid_options: ctl_set_invalid_field(/*ctsio*/ ctsio, /*sks_valid*/ 1, /*command*/ 1,