Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp1287259pxj; Sat, 12 Jun 2021 04:12:59 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzoGHewiyhOTP+Oz0c+AqVoobx2jv8XKozXw4b9flJLamLViKXYinU0ruv5njxvyTYp/zEn X-Received: by 2002:a17:906:bb0e:: with SMTP id jz14mr7416855ejb.285.1623496379324; Sat, 12 Jun 2021 04:12:59 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1623496379; cv=none; d=google.com; s=arc-20160816; b=a7WosOEJdJ1VvcURpXteWKvHbj0sobnlXXOKZoqgDR7c5HtRQYnkaVf91mh9waFm7V LWHsHeOdRtOcB4xP3XjjAzunN94ZRfs7FZBlv/EH5H5+92zYMXZGQNnSbwm5uNeTdcCJ tBfUlOTLeZVO4IllYvKpYR39CPL2jdRztIHC6reC2RfQ4r8JoINfQFwnKNpJiIRfex08 DZbry45Q/BoW7CZomlkXpO1xcoul7U1f6zReIoKxMrOAlx1smYrWR7EjvVKgNG3nmNgv 2ODkqVrWw6qi8OumMvFZONPvnlaFRr7qb1CIeU2Cn/z+5hDXdNuq6at4sFl91LVHbX21 6NoQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:user-agent:message-id:in-reply-to :date:references:subject:cc:to:from:dmarc-filter:sender :dkim-signature; bh=kjHxY9YDTUvdbQnJ/lulcSlCbEzIXndXJy3S2twb1II=; b=nZmnjb3CxKkepMDLWcN6FXkyHJZykevBS99w9mq7pCVP10jtwZMd0/g0VV1xXg9W9S flLkN1yBBYIcCTO8KsT6/VKo/vf1aTrWCouyXvzZUMvvjvH7KKYL3S1Xe1thKWUi5XQw 5lOFfbcly66aJHx5N9xpQY01HcVt6X0vdId6owws3SK8+lXVlg4BJ86jey7dWZDg1UNZ DT356CqrrQRABoJhEEoRkgOUQq0Q4/3MasxQFAo/zNKBnTELnqio0Rx31nPbjaKgaFqX ibNCMzd2n05P0uUBAKmx0no6sokgHW5ouvh75MJtuifpv/LUm3dS9E8GVG+jP3wGKpFw nzHw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@mg.codeaurora.org header.s=smtp header.b="OXP6J/Sz"; spf=pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id i4si1246349edc.17.2021.06.12.04.12.27; Sat, 12 Jun 2021 04:12:59 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@mg.codeaurora.org header.s=smtp header.b="OXP6J/Sz"; spf=pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231157AbhFLLHF (ORCPT + 99 others); Sat, 12 Jun 2021 07:07:05 -0400 Received: from m43-7.mailgun.net ([69.72.43.7]:20736 "EHLO m43-7.mailgun.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229584AbhFLLHD (ORCPT ); Sat, 12 Jun 2021 07:07:03 -0400 DKIM-Signature: a=rsa-sha256; v=1; c=relaxed/relaxed; d=mg.codeaurora.org; q=dns/txt; s=smtp; t=1623495904; h=Content-Type: MIME-Version: Message-ID: In-Reply-To: Date: References: Subject: Cc: To: From: Sender; bh=kjHxY9YDTUvdbQnJ/lulcSlCbEzIXndXJy3S2twb1II=; b=OXP6J/SzchQ3zk0ZvhukKx18JUUAHd8SzAgl2OIL/kwQcbquwO2iQGaYegS2t47tYOPvVdCB atZ64JrXdIpX3Tf3trrX1pXZgchzvvvr63ZeA1PjW9edQHuvHaCCBvjQjC6xuq0iHJdMM+1G CfEBo4RSMOnmz8dWGNr+3wiPTP0= X-Mailgun-Sending-Ip: 69.72.43.7 X-Mailgun-Sid: WyI3YTAwOSIsICJsaW51eC13aXJlbGVzc0B2Z2VyLmtlcm5lbC5vcmciLCAiYmU5ZTRhIl0= Received: from smtp.codeaurora.org (ec2-35-166-182-171.us-west-2.compute.amazonaws.com [35.166.182.171]) by smtp-out-n01.prod.us-east-1.postgun.com with SMTP id 60c494bdabfd22a3dc554f0f (version=TLS1.2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256); Sat, 12 Jun 2021 11:04:29 GMT Sender: kvalo=codeaurora.org@mg.codeaurora.org Received: by smtp.codeaurora.org (Postfix, from userid 1001) id A5D74C43460; Sat, 12 Jun 2021 11:04:28 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-caf-mail-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.9 required=2.0 tests=ALL_TRUSTED,BAYES_00,SPF_FAIL, URIBL_BLOCKED autolearn=no autolearn_force=no version=3.4.0 Received: from tykki (tynnyri.adurom.net [51.15.11.48]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) (Authenticated sender: kvalo) by smtp.codeaurora.org (Postfix) with ESMTPSA id 46F8CC433D3; Sat, 12 Jun 2021 11:04:26 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 smtp.codeaurora.org 46F8CC433D3 Authentication-Results: aws-us-west-2-caf-mail-1.web.codeaurora.org; dmarc=none (p=none dis=none) header.from=codeaurora.org Authentication-Results: aws-us-west-2-caf-mail-1.web.codeaurora.org; spf=fail smtp.mailfrom=kvalo@codeaurora.org From: Kalle Valo To: Bryan O'Donoghue Cc: wcn36xx@lists.infradead.org, linux-wireless@vger.kernel.org, shawn.guo@linaro.org, benl@squareup.com, loic.poulain@linaro.org, bjorn.andersson@linaro.org Subject: Re: [PATCH] wcn36xx: Move hal_buf allocation to devm_kmalloc in probe References: <20210605173347.2266003-1-bryan.odonoghue@linaro.org> Date: Sat, 12 Jun 2021 14:04:21 +0300 In-Reply-To: <20210605173347.2266003-1-bryan.odonoghue@linaro.org> (Bryan O'Donoghue's message of "Sat, 5 Jun 2021 18:33:47 +0100") Message-ID: <875yyjz6mi.fsf@codeaurora.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.1 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org Bryan O'Donoghue writes: > Right now wcn->hal_buf is allocated in wcn36xx_start(). This is a problem > since we should have setup all of the buffers we required by the time > ieee80211_register_hw() is called. > > struct ieee80211_ops callbacks may run prior to mac_start() and therefore > wcn->hal_buf must be initialized. > > This is easily remediated by moving the allocation to probe() taking the > opportunity to tidy up freeing memory by using devm_kmalloc(). > > Fixes: 8e84c2582169 ('wcn36xx: mac80211 driver for Qualcomm WCN3660/WCN3680 > hardware') Fixes tag is wrong, it should be like this and all in one line: Fixes: 8e84c2582169 ("wcn36xx: mac80211 driver for Qualcomm WCN3660/WCN3680 hardware") I fixed it in the pending branch, no need to resend. -- https://patchwork.kernel.org/project/linux-wireless/list/ https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches