From nobody Mon Oct 9 23:16:11 2023 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 4S4FJq3wvFz4wgxX; Mon, 9 Oct 2023 23:16:11 +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 4S4FJq3R4Fz3QH7; Mon, 9 Oct 2023 23:16:11 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696893371; 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=E7GigrtdxzyEEfcDaHGUI1Vk6rHE5i8G/wHCGKdih/Q=; b=lAnb0DY7tcYfMNZF615/nDEvhrVJBaZY85ctfCjPSvSDfAqHD7LlpaMf3TkxOLQx3VtACh SFy3ResNzwKhEV/amYUdE+QAnPoaFYEoH6zWyBtuDyWrvn3VdXP6uluL5xQvUDSH4FImnB nP++4H1ZOKVArmVwpxYQfU5p9YDhap3UjlyDvHAdpH0rKB4xAznCOJDz1LDP8zWinyVt0V AXjW30e9r84yMuLBRyk0iI+cFZXZuJ5PgcpghA5U3Gab5BspYHgxUd7HRHiTaqFM0VtJU7 P7i1m0lLWUY/RI/1b2cBRL9ipjcaEir/4GJAPSA8kca3mfqXK+NJinSmXp76ww== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696893371; a=rsa-sha256; cv=none; b=MAcVt6L7Cp32y3c4vMmfzmi5CjZy2r62FLSbkUoZUTBoHWF1WQ2MMuk+cgOhpSbwAAnYyg 2Yiuf6yg4A65OZNJby+40FG6JG7FsAagxW3YDSvpTwxPDhCYU+9rTnKdV6WUbYFMSFF2kx vUseVT5Sao4dL7k+0Fl+ns4+L1oAMF8fNnDeZQ2Ij6CNB9Jx3N6k1d7Y4X5zWOz8jSRFKy Th75QyCZGjB1qSAsQVr2IGAW/utq0TIdezII1fXyWxLqQueD+PmXuGSrEZ+ApkmWIPneQk +FbbXm5RbI5NwY6hKUQ+UVpvV+24GhQ+2acXAHI42w0NnrtCPHj57iTUX6W2EQ== 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=1696893371; 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=E7GigrtdxzyEEfcDaHGUI1Vk6rHE5i8G/wHCGKdih/Q=; b=L8TLGTOio9dVwkQuUe+BEaSn5mvERYllo8GY7XROgl/7dsT2ioPM9h8k53t1cvSk1qqR15 ytGSUhujUoa2mEAb56i1t6U0j3jhChdGK1M+vnzM1CjaNYAk0J8PtmbYk229R0YyJzNDRB D7QGPQJQYgVCu1QkvdWlNkNdWvFHVDbRNU/1YlVtTF5AEbtF5XMOhKsEZta1c1m/uH5ivU 3XE409IzNe4cRDvlGkw3cN9Q+JCcNEyPH+rkIYs3kHg6wVKUSE3KRiFrOKWBzG7T2WXJKm l9rAExe4x1aCB6KSt6L3GdYnZVq/GNjDcK2NMxJYRKbLo85pvsI4ThVRgCETxg== 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 4S4FJq2Y7Lzh4; Mon, 9 Oct 2023 23:16:11 +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 399NGBjT071086; Mon, 9 Oct 2023 23:16:11 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 399NGB5J071083; Mon, 9 Oct 2023 23:16:11 GMT (envelope-from git) Date: Mon, 9 Oct 2023 23:16:11 GMT Message-Id: <202310092316.399NGB5J071083@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: "Bjoern A. Zeeb" Subject: git: 35a61e071b84 - releng/14.0 - iwlwifi: fix a bug in iwl_ssid_exist() 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: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: bz X-Git-Repository: src X-Git-Refname: refs/heads/releng/14.0 X-Git-Reftype: branch X-Git-Commit: 35a61e071b84eb6a3969ffd796c73399e0555e13 Auto-Submitted: auto-generated The branch releng/14.0 has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=35a61e071b84eb6a3969ffd796c73399e0555e13 commit 35a61e071b84eb6a3969ffd796c73399e0555e13 Author: Bjoern A. Zeeb AuthorDate: 2023-09-14 17:22:04 +0000 Commit: Bjoern A. Zeeb CommitDate: 2023-10-09 23:14:52 +0000 iwlwifi: fix a bug in iwl_ssid_exist() Rather than always comparing a given SSID to the first SSID of the IE list, compare it to the the iterator one. That way duplicates can be found. Sponsored by: The FreeBSD Foundation Approved by: re (gjb) (cherry picked from commit ee7077f24f5b02bde8cf5c202848128f18733398) (cherry picked from commit a513f65b92b672830c89acfa04b93c3b77d3f97d) --- sys/contrib/dev/iwlwifi/mvm/scan.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/sys/contrib/dev/iwlwifi/mvm/scan.c b/sys/contrib/dev/iwlwifi/mvm/scan.c index a4077053e374..8c5d6860914b 100644 --- a/sys/contrib/dev/iwlwifi/mvm/scan.c +++ b/sys/contrib/dev/iwlwifi/mvm/scan.c @@ -447,7 +447,11 @@ static int iwl_ssid_exist(u8 *ssid, u8 ssid_len, struct iwl_ssid_ie *ssid_list) if (!ssid_list[i].len) break; if (ssid_list[i].len == ssid_len && +#if defined(__linux__) !memcmp(ssid_list->ssid, ssid, ssid_len)) +#elif defined(__FreeBSD__) + !memcmp(ssid_list[i].ssid, ssid, ssid_len)) +#endif return i; } return -1;