Received: by 2002:a5d:9c59:0:0:0:0:0 with SMTP id 25csp2202892iof; Tue, 7 Jun 2022 23:05:47 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxNd5J096Mzvf9aVyYjjULpJzJQmdF+EC1XUhZVHQohUCEg+LdOoN6HyGQCxyDIvwiRwZU5 X-Received: by 2002:a65:6943:0:b0:3fd:8a02:59f2 with SMTP id w3-20020a656943000000b003fd8a0259f2mr15283517pgq.375.1654668346983; Tue, 07 Jun 2022 23:05:46 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1654668346; cv=none; d=google.com; s=arc-20160816; b=EKbfxpfoKpEI+Xbf+18bdCuI0AO9KZslQlgwod1ocNsf5RB8aS+Ogmy9akFlh/nKug kZfa38GXxt29OCFKFUahtuBaKWB0k5v4wD+ke37Ysq95oKEPTa/pze9fmeQtoHGvGisE BZcScm9jEYGqn3u8WdD4SfpznzCHoV2bTJ7wjc7loFuLy27o4r132kxGaWrI75TZZ6fy xG5Vt27jIMFMe52hK0yMf+jeatvSugCLimy6HBAf/S3dCMEM5OEGR36pJCijSvxCrqqz f4DMzSD1pIZYWpWVXLxqFyG033L/0ul8rJD2CBs60TYohaV7yMAJhyEJfIPnWG1PsgaU y8zw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=M1wNqnIAYiiFgEqqnXb7Rct+cxPBF3yd0w+EbsEZYr4=; b=eryQQgfFaKQ2N/ZdMo6vuEQkwrtsPY/1AXj079dhJs3NBFEybLeZdEh5DBR4guVZad bti8XJHERjMHTaZ27LtGv3WIQdwEKyaRElKNF4uPcnDK+ThRH8kbyxc9YLKdWhBZKQcw vH6O4NT75ZylQCnVLSRN9cVqbc1s6NaVG8MLn1o/yZikyZCifQsuSWJosxggMP1czM4P d8WC/FdJliu7kwfYhAAlIHRMxnYuAr8DpCG3AeBzLEMsXBerxB15vJ065dXWdMukoJyw rCURP/TGeijQvCygqMHlqeV1aBFBDZO5XpEWLv+npqPJfGKPawsmUpV0Nwv+tmbXgERY RhUw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=1gnxW557; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [2620:137:e000::1:18]) by mx.google.com with ESMTPS id t1-20020a63f341000000b003fbb35b5d88si27619725pgj.347.2022.06.07.23.05.46 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 07 Jun 2022 23:05:46 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) client-ip=2620:137:e000::1:18; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=1gnxW557; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id AB6D548ABA8; Tue, 7 Jun 2022 22:30:34 -0700 (PDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1389554AbiFHB2n (ORCPT + 99 others); Tue, 7 Jun 2022 21:28:43 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49796 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1384242AbiFGWUT (ORCPT ); Tue, 7 Jun 2022 18:20:19 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 358332632AE; Tue, 7 Jun 2022 12:20:49 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 0DED560907; Tue, 7 Jun 2022 19:20:39 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 16DACC385A5; Tue, 7 Jun 2022 19:20:37 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1654629638; bh=ZB5KUxuvNQ0yTaFTUxeKiF3Scpi+CLvkddXIlq4z0cY=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=1gnxW557vtIskEm9smjrUApV4jHbMGZ+RPw1yaXJu8reY133528/nat+oEjncByxy vFS5otkmc9RDnAUF+qunUZ+Knr8mI+QWyXoYD5CPCXa/VFby/2mc2+K0VGfrHY6Aor Nv4XYRXa7vC/jtrdZ6w40BWJLCVvNTQkg2rhq+LU= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Avraham Stern , Gregory Greenman , Johannes Berg Subject: [PATCH 5.18 722/879] iwlwifi: mei: clear the sap data header before sending Date: Tue, 7 Jun 2022 19:04:00 +0200 Message-Id: <20220607165023.811326528@linuxfoundation.org> X-Mailer: git-send-email 2.36.1 In-Reply-To: <20220607165002.659942637@linuxfoundation.org> References: <20220607165002.659942637@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-3.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,RDNS_NONE,SPF_HELO_NONE,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Avraham Stern commit 55cf10488d7a9fa1b1b473a5e44a80666932e094 upstream. The SAP data header has some fields that are marked as reserved but are actually in use by CSME. Clear those fields before sending the data to avoid having random values in those fields. Cc: stable@vger.kernel.org Signed-off-by: Avraham Stern Signed-off-by: Gregory Greenman Link: https://lore.kernel.org/r/20220517120045.8dd3423cf683.I02976028eaa6aab395cb2e701fa7127212762eb7@changeid Signed-off-by: Johannes Berg Signed-off-by: Greg Kroah-Hartman --- drivers/net/wireless/intel/iwlwifi/mei/main.c | 1 + 1 file changed, 1 insertion(+) --- a/drivers/net/wireless/intel/iwlwifi/mei/main.c +++ b/drivers/net/wireless/intel/iwlwifi/mei/main.c @@ -493,6 +493,7 @@ void iwl_mei_add_data_to_ring(struct sk_ if (cb_tx) { struct iwl_sap_cb_data *cb_hdr = skb_push(skb, sizeof(*cb_hdr)); + memset(cb_hdr, 0, sizeof(*cb_hdr)); cb_hdr->hdr.type = cpu_to_le16(SAP_MSG_CB_DATA_PACKET); cb_hdr->hdr.len = cpu_to_le16(skb->len - sizeof(cb_hdr->hdr)); cb_hdr->hdr.seq_num = cpu_to_le32(atomic_inc_return(&mei->sap_seq_no));