Received: by 2002:ac8:7315:0:b0:429:955e:b7c6 with SMTP id x21csp211096qto; Fri, 26 Jan 2024 16:24:12 -0800 (PST) X-Google-Smtp-Source: AGHT+IHi5y3lPhMgiiYSH++F8/vovLVvtylSAYnvOtPSEJ2Rz36dv2CsJkCZGkynWPxNduWyTfU1 X-Received: by 2002:a05:600c:4f15:b0:40e:bed4:4d04 with SMTP id l21-20020a05600c4f1500b0040ebed44d04mr464769wmq.15.1706315051835; Fri, 26 Jan 2024 16:24:11 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1706315051; cv=pass; d=google.com; s=arc-20160816; b=wW5D5/pAhaKobT3Yo1L2BcH59vUmbRCkOOMqHhvZqCK+DCGdfJuje+9/l57Y9gvYuz uTfP9AWbcApIduPAtVioMYFzNJX/wwSa+7uu02jeGd3bLeAuPO7fZefFKc1gUfOA6NMG CkGFAvb7XNdPguQpdlgGZ1EsrlebYsMY1QaU64QmvigTLgke2J83rTVndfdTI4970vuQ /ZCMUo13WIU5PY74Hkj8F5Y5u9U3ERKzScZEFYXaTkkkZLOhfn06sbuNeuliBwuR2tmG S88/RrpHGsByNHaYbybi5cuxwNkav+gZnWzlY4iHTlQjNIAl1JV0PvfgWPT6MKermoAL S/xA== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:user-agent:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:date:message-id:dkim-signature; bh=z5Dmcn0tLMetworJ7ghrTDfwdElvkBrKOKq8NFKf98U=; fh=Ahzw9WpusEFEYnVn567yjdM3oQ5tWKzSXN4GqjStBc4=; b=CGpNYWN6BdcS93o2IyEB4c5xd1xCwfwYAHqSDbN3JuRzrb5GmMV6MMLeL4zSgYG+Hm F8RfWRr0VrmxkltGcRrjpb7wnFU7XLyQkAa1h9695weMPZsN7q5Xi/6f2FkorjbKSU4C glr9fYKB/akSZgIhTC2twXuIl0KTe0cvq7SClbD1etorBJYSm8jhOqeUH/J5vAxVBGuy 1UYPMjYmNPTXMpuYNoL/++3kgwUyvwFgMKdcoKvTF033p7b9mrk+ukkLzxZQX0ObWqMp UHXld7n5Rvbt2dgPreCkQW6sm3juOmfh8wSh2qtKX/teaPfxY+sc89jd7xNpnTeA6ZEb fI7Q== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@quicinc.com header.s=qcppdkim1 header.b=VReFo0qn; arc=pass (i=1 spf=pass spfdomain=quicinc.com dkim=pass dkdomain=quicinc.com dmarc=pass fromdomain=quicinc.com); spf=pass (google.com: domain of linux-wireless+bounces-2586-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) smtp.mailfrom="linux-wireless+bounces-2586-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=quicinc.com Return-Path: Received: from am.mirrors.kernel.org (am.mirrors.kernel.org. [2604:1380:4601:e00::3]) by mx.google.com with ESMTPS id cs11-20020a0564020c4b00b0055c7a672ae7si1119080edb.521.2024.01.26.16.24.11 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 26 Jan 2024 16:24:11 -0800 (PST) Received-SPF: pass (google.com: domain of linux-wireless+bounces-2586-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) client-ip=2604:1380:4601:e00::3; Authentication-Results: mx.google.com; dkim=pass header.i=@quicinc.com header.s=qcppdkim1 header.b=VReFo0qn; arc=pass (i=1 spf=pass spfdomain=quicinc.com dkim=pass dkdomain=quicinc.com dmarc=pass fromdomain=quicinc.com); spf=pass (google.com: domain of linux-wireless+bounces-2586-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) smtp.mailfrom="linux-wireless+bounces-2586-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=quicinc.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by am.mirrors.kernel.org (Postfix) with ESMTPS id 7EA801F22CE0 for ; Sat, 27 Jan 2024 00:24:11 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id F01A11873; Sat, 27 Jan 2024 00:24:04 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=quicinc.com header.i=@quicinc.com header.b="VReFo0qn" X-Original-To: linux-wireless@vger.kernel.org Received: from mx0b-0031df01.pphosted.com (mx0b-0031df01.pphosted.com [205.220.180.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 59BB8186E for ; Sat, 27 Jan 2024 00:24:02 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=205.220.180.131 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706315044; cv=none; b=gFoyvPigzxjgGW4oXJ6GlcFLmihk6yQ54dvrlEY78LBrbTIlNEFCgqV7CcznaSeL9ZUpUuHo1uVkghi28nWZhfBM4ulOjy9VSgVRZ7ElYTb3ckvEYJyoRL1pwCQoOj3ahd/Y6z7+0YBBKfHAeXkcjzSRK47INT+zUG3KfDwe8zg= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706315044; c=relaxed/simple; bh=F/shBDasmCKN+GEl+OibJu+7a1nxwI+uj91+DSFSswg=; h=Message-ID:Date:MIME-Version:Subject:To:CC:References:From: In-Reply-To:Content-Type; b=iB813bUUeDqeIs/JoXrDzsyNxAmMXKfe+QTofFsQiyG3eFQQcXuxMzmJKLNSTu3PK9x44R0GP0zjAp3XGO2LWTqk1dJ+8ScJhhg/gT+afiHXshanZdwg3mNex2CiJVn5oPYK+uDt4qosgPYubMviAneEYPjr6r+fTs008ElCM1U= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=quicinc.com; spf=pass smtp.mailfrom=quicinc.com; dkim=pass (2048-bit key) header.d=quicinc.com header.i=@quicinc.com header.b=VReFo0qn; arc=none smtp.client-ip=205.220.180.131 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=quicinc.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=quicinc.com Received: from pps.filterd (m0279873.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.17.1.24/8.17.1.24) with ESMTP id 40R0LX3P023033; Sat, 27 Jan 2024 00:23:59 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=quicinc.com; h= message-id:date:mime-version:subject:to:cc:references:from :in-reply-to:content-type:content-transfer-encoding; s= qcppdkim1; bh=z5Dmcn0tLMetworJ7ghrTDfwdElvkBrKOKq8NFKf98U=; b=VR eFo0qnmoIgOcCZWk/uBYYbj9Vu9+iya4StpuwCaF/+iA6AbVno63TlFUcXKjeeHP jnkDDweukyB3G3yMTaS1BAHHilRd7WvdUuKTh1rOEtma31JYLX+TDlBNXqpO/GVE MD9k8ZqwuM6qIABfuCg1iZmpuUnaLVun9yktZVfi4oFnXv74sYUs8ci5dN6U3IHz T1JLYwSDOYhvHOWogvo6un3iyaLH4aQzRyCZ+XSPKJTWbRShIFAqeJzKC3cahmS3 cIDP/eEEoM81mzqUniJxwl1+m7V/D5Z73jrSVwoV1cyRZsAfarDPgKozLjk0NkXm jgvySIGuSUyJh5w6Easg== Received: from nalasppmta02.qualcomm.com (Global_NAT1.qualcomm.com [129.46.96.20]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 3vvq6sg06v-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Sat, 27 Jan 2024 00:23:59 +0000 (GMT) Received: from nalasex01a.na.qualcomm.com (nalasex01a.na.qualcomm.com [10.47.209.196]) by NALASPPMTA02.qualcomm.com (8.17.1.5/8.17.1.5) with ESMTPS id 40R0NwN4031376 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Sat, 27 Jan 2024 00:23:58 GMT Received: from [10.110.0.209] (10.80.80.8) by nalasex01a.na.qualcomm.com (10.47.209.196) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.1118.40; Fri, 26 Jan 2024 16:23:57 -0800 Message-ID: <8cc71105-9901-4732-aafd-f8e116e485f3@quicinc.com> Date: Fri, 26 Jan 2024 16:23:57 -0800 Precedence: bulk X-Mailing-List: linux-wireless@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH v4 07/11] wifi: ath12k: fix broken structure wmi_vdev_create_cmd Content-Language: en-US To: Kang Yang , CC: References: <20240126115231.356658-1-quic_kangyang@quicinc.com> <20240126115231.356658-8-quic_kangyang@quicinc.com> From: Jeff Johnson In-Reply-To: <20240126115231.356658-8-quic_kangyang@quicinc.com> Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit X-ClientProxiedBy: nasanex01b.na.qualcomm.com (10.46.141.250) To nalasex01a.na.qualcomm.com (10.47.209.196) X-QCInternal: smtphost X-Proofpoint-Virus-Version: vendor=nai engine=6200 definitions=5800 signatures=585085 X-Proofpoint-GUID: W8CU0_xQDw2XLbMnrt3YR4EYZMLjDA1_ X-Proofpoint-ORIG-GUID: W8CU0_xQDw2XLbMnrt3YR4EYZMLjDA1_ X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.272,Aquarius:18.0.1011,Hydra:6.0.619,FMLib:17.11.176.26 definitions=2024-01-25_14,2024-01-25_01,2023-05-22_02 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 bulkscore=0 spamscore=0 phishscore=0 adultscore=0 clxscore=1015 malwarescore=0 priorityscore=1501 suspectscore=0 mlxscore=0 lowpriorityscore=0 mlxlogscore=841 impostorscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.19.0-2401190000 definitions=main-2401270001 On 1/26/2024 3:52 AM, Kang Yang wrote: > Current structure wmi_vdev_create_cmd is not matched to the firmware > definition. So update it. > > And update vdev_stats_id_valid for vdev_stats_id. > > Tested-on: WCN7850 hw2.0 PCI WLAN.HMT.1.0.c5-00481-QCAHMTSWPL_V1.0_V2.0_SILICONZ-3 > Tested-on: QCN9274 hw2.0 PCI WLAN.WBE.1.0.1-00029-QCAHKSWPL_SILICONZ-1 > > Signed-off-by: Kang Yang > --- > > v4: no change. > v3: no change. > v2: add Tested-on tag of QCN9274. > > --- > drivers/net/wireless/ath/ath12k/wmi.c | 5 +++++ > drivers/net/wireless/ath/ath12k/wmi.h | 3 +++ > 2 files changed, 8 insertions(+) > > diff --git a/drivers/net/wireless/ath/ath12k/wmi.c b/drivers/net/wireless/ath/ath12k/wmi.c > index c7e732c6c145..34e676799616 100644 > --- a/drivers/net/wireless/ath/ath12k/wmi.c > +++ b/drivers/net/wireless/ath/ath12k/wmi.c > @@ -828,7 +828,12 @@ int ath12k_wmi_vdev_create(struct ath12k *ar, u8 *macaddr, > cmd->vdev_subtype = cpu_to_le32(args->subtype); > cmd->num_cfg_txrx_streams = cpu_to_le32(WMI_NUM_SUPPORTED_BAND_MAX); > cmd->pdev_id = cpu_to_le32(args->pdev_id); > + if (args->if_stats_id != ATH12K_INVAL_VDEV_STATS_ID) > + cmd->vdev_stats_id_valid = cpu_to_le32(true); > + else > + cmd->vdev_stats_id_valid = cpu_to_le32(false); else clause is unnecessary since the struct is zeroed when allocated > cmd->vdev_stats_id = cpu_to_le32(args->if_stats_id); suggest this only be done inside: if (args->if_stats_id != ATH12K_INVAL_VDEV_STATS_ID) > + > ether_addr_copy(cmd->vdev_macaddr.addr, macaddr); > > ptr = skb->data + sizeof(*cmd); > diff --git a/drivers/net/wireless/ath/ath12k/wmi.h b/drivers/net/wireless/ath/ath12k/wmi.h > index 0efed12dd7ab..74b0ee9f86bf 100644 > --- a/drivers/net/wireless/ath/ath12k/wmi.h > +++ b/drivers/net/wireless/ath/ath12k/wmi.h > @@ -2712,6 +2712,9 @@ struct wmi_vdev_create_cmd { > struct ath12k_wmi_mac_addr_params vdev_macaddr; > __le32 num_cfg_txrx_streams; > __le32 pdev_id; > + __le32 mbssid_flags; > + __le32 mbssid_tx_vdev_id; > + __le32 vdev_stats_id_valid; > __le32 vdev_stats_id; > } __packed; >