Received: by 2002:a05:6358:a55:b0:ec:fcf4:3ecf with SMTP id 21csp905315rwb; Fri, 13 Jan 2023 05:45:07 -0800 (PST) X-Google-Smtp-Source: AMrXdXsRhL4ZHkKXoG8YwbKuSASeMTqrRc4bThC6xi97HVOfgdAHO+F+g1JIITOtm1PjW91pW6Hv X-Received: by 2002:a17:907:8b1a:b0:84d:34a4:46fd with SMTP id sz26-20020a1709078b1a00b0084d34a446fdmr3485147ejc.71.1673617507286; Fri, 13 Jan 2023 05:45:07 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1673617507; cv=none; d=google.com; s=arc-20160816; b=HbqGsUPk4prjZqHEnmEYLOJSBGr7pX0Lz0gobNd5BjnvP6a5w7LaRtqs3KL54MykyQ hm3a4ua+Hmbvr0MvOkPlyANGQ0Mh7dVQmVMEiBdryZFcg9tJZaGKWSJT8HpMVksRLRyj 0cybx2Ngfmp077/kBIpSOyeafWjmFLBZ3n4mYL5erRAPoIhhhIMZAIaFAxKrSK24jF6c L+NuU6PEyHlVH/CUD3AOuFY0Sp+iH86pz96A0Ouz3YNkkICa36S4o2LdOCoGnBba1w3C JbQT5ng97C5k9MKYgZE/yVzR0r2Q9edg14btahTgXwcSHiOpKzfSH67ib3j1rGU6Ah9D yAeA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:message-id:date:subject:cc:to:from :dkim-signature; bh=5R8MW5PsrFpUHW2/Qso1Ea/UZDqrP1AU/pa+y91SHfc=; b=woS1CiDz1ckkMCQeHvHar2mVR0qHPCV2LE/zvrwfe6ZfIDWtR0zb723ES3Bk4bW0vu nz3YDZiCzoyuvhrcj6uaJP448rCth3EVxcOrHpgMg/5s90gq7aEkd01lwSkjuJ5PIMFA DtWbbnPMTFDAgfS4i1Sbv8a0bpK2HVK0JY7ROQbyAQvyJcU81QIEQmL3ZyR4ZiZejZLP gTBw4heKIoqbPginVRU5arwJxrqnrcwEhmCXXOW9Gm36P9ljflIjMmoJrGh6/27emGwO xx2v+cxl5Q3+5Bdtf301IOcc/yXC2MVrsqGQzreAzj9xqsHunv7oNIvCLbQQKVFWGmyH 7w7w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@163.com header.s=s110527 header.b=i34dA0h1; spf=pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=163.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id wt13-20020a170906ee8d00b007cb0cf0b18asi21602598ejb.743.2023.01.13.05.44.49; Fri, 13 Jan 2023 05:45:07 -0800 (PST) Received-SPF: pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@163.com header.s=s110527 header.b=i34dA0h1; spf=pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=163.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233277AbjAMNoh (ORCPT + 65 others); Fri, 13 Jan 2023 08:44:37 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:41324 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S240277AbjAMNmk (ORCPT ); Fri, 13 Jan 2023 08:42:40 -0500 Received: from m12.mail.163.com (m12.mail.163.com [123.126.96.234]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 0714F249; Fri, 13 Jan 2023 05:36:27 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=163.com; s=s110527; h=From:Subject:Date:Message-Id; bh=5R8MW5PsrFpUHW2/Qs o1Ea/UZDqrP1AU/pa+y91SHfc=; b=i34dA0h1bYou2dmJ0i8xL4wac/UEIJTh2c ZrR19AzAxyKn1dyPwzDxUEyxRltsoWTQ3FROg6F5klG+LYAXg6Te6ntK8IuWyAgy +pjS/OgbcKFwTelRZiI8PFZJ7shsndqYDeSUD2pBXfmcs8wcoz6DIlenHdNfjwd8 TLT+SYQCc= Received: from localhost.localdomain (unknown [114.107.204.148]) by smtp20 (Coremail) with SMTP id H91pCgDnZMAKXsFj1Gk1AQ--.2429S4; Fri, 13 Jan 2023 21:35:46 +0800 (CST) From: Lizhe To: kvalo@kernel.org, davem@davemloft.net, edumazet@google.com, kuba@kernel.org, pabeni@redhat.com, johannes.berg@intel.com, alexander@wetzel-home.de Cc: linux-wireless@vger.kernel.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org, Lizhe Subject: [PATCH v1] wireless/at76c50x-usb.c : Use devm_kzalloc replaces kmalloc Date: Fri, 13 Jan 2023 05:35:03 -0800 Message-Id: <20230113133503.58336-1-sensor1010@163.com> X-Mailer: git-send-email 2.17.1 X-CM-TRANSID: H91pCgDnZMAKXsFj1Gk1AQ--.2429S4 X-Coremail-Antispam: 1Uf129KBjvdXoWrtrWkXF4DCFWxJr43tw43Jrb_yoWfZFc_uF 4Igrn7JFWUJFs2gry7Cr47ZFySkF1xXFn7uanxKay3uw12vrW8ZrZ5ZFyavFZrurWfAFy3 Ar1DtFy5ZayvgjkaLaAFLSUrUUUUUb8apTn2vfkv8UJUUUU8Yxn0WfASr-VFAUDa7-sFnT 9fnUUvcSsGvfC2KfnxnUUI43ZEXa7sRXtxfUUUUUU== X-Originating-IP: [114.107.204.148] X-CM-SenderInfo: 5vhq20jurqiii6rwjhhfrp/1tbiSBT1q1+FgsklaAABsf X-Spam-Status: No, score=-1.8 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_ENVFROM_END_DIGIT, FREEMAIL_FROM,SPF_HELO_NONE,SPF_PASS autolearn=ham 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-wireless@vger.kernel.org use devm_kzalloc replaces kamlloc Signed-off-by: Lizhe --- drivers/net/wireless/atmel/at76c50x-usb.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/net/wireless/atmel/at76c50x-usb.c b/drivers/net/wireless/atmel/at76c50x-usb.c index 009bca34ece3..ebd8ef525557 100644 --- a/drivers/net/wireless/atmel/at76c50x-usb.c +++ b/drivers/net/wireless/atmel/at76c50x-usb.c @@ -2444,7 +2444,7 @@ static int at76_probe(struct usb_interface *interface, udev = usb_get_dev(interface_to_usbdev(interface)); - fwv = kmalloc(sizeof(*fwv), GFP_KERNEL); + fwv = devm_kzalloc(sizeof(*fwv), GFP_KERNEL); if (!fwv) { ret = -ENOMEM; goto exit; @@ -2535,7 +2535,6 @@ static int at76_probe(struct usb_interface *interface, at76_delete_device(priv); exit: - kfree(fwv); if (ret < 0) usb_put_dev(udev); return ret; -- 2.17.1