Received: by 2002:a05:7412:1703:b0:e2:908c:2ebd with SMTP id dm3csp3134735rdb; Tue, 29 Aug 2023 06:30:51 -0700 (PDT) X-Google-Smtp-Source: AGHT+IGSuRZBLQ8y6OmJ89w1082IEGbuS1iKYGz6RlzEnqbVJNEttYD5Xo4MSm7lTAAphm+Q1rcy X-Received: by 2002:a17:906:3199:b0:9a2:276d:d83c with SMTP id 25-20020a170906319900b009a2276dd83cmr10029798ejy.18.1693315850849; Tue, 29 Aug 2023 06:30:50 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1693315850; cv=none; d=google.com; s=arc-20160816; b=WNarPe7BlbPB6rVZU39u3VL97M2ZqyXuJKvEop0tEwY+oaJV9I4LB8SChQ8XIEZWCD ihinjpFagnuNXydCmMGbJJSkBVsUlyHq5VLjhWDcGB2NU1/ya32lnOO+DIwPlh1vb8u6 j7JoLIiBpZv0rIKzV1wumIUlOR2Vfm25Hk8JOw02r8iRcT0wyoXbTaDPLCZ3QtKfBwM8 eTg3F5gM3QbaudcYw/ndBdt4fsncH+gxEjpU87UZob7hVx2HOjMlAYZxrxqeW3S+IYxT wlbGsL6CNOK7wALeN0ivWHpMwrXLODi7tkIwshUE6wZcFPxfXXcSzEu6lC8CHd9mQTN7 /5iQ== 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 :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=ahEDdKJvfgvlryas2qqoUqx/YZLc0pnlpJ2dmFNr0VI=; fh=r/VVG12KmrF+nQv7lC2x2sQ0qQnFs7bJUsMqdUzXKDU=; b=B9Yn5Vt4UmnO16JaLoNc1+WySzr8c9fKoJrzwR2cQw88P9qYWKCxcUtAQVeMUyz1iy Xo8bTAHaUlXDWT9ROywjMgNMZ0ISFALi8LEZIVjVSO4GpCQ1012S6a4rMDYbedwuZsvS f8cIAHTLF8fKZ0ZnLTwg4j28zp8uQCRitTzOc5GM4qCGwSKY3psb7Mrntx2G56ps9IV8 7TtyN36aA+5ch2ooZKdpEZ8ISU/Y3mkbil6xnMOOmZAh5N+mI0s5KReNoZgaPm9vRe3I bla0ndPxOTu1RJtmLx9p02DJZ915ILPz56mjGkThNGX6XxdbMY4TcpOp4O/hjk/GEWeR f5og== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=OYEeptAr; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id h21-20020a1709060f5500b009930294ae72si5564141ejj.293.2023.08.29.06.30.13; Tue, 29 Aug 2023 06:30:50 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-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=@kernel.org header.s=k20201202 header.b=OYEeptAr; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232917AbjH2Kx0 (ORCPT + 99 others); Tue, 29 Aug 2023 06:53:26 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37906 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231858AbjH2Kw6 (ORCPT ); Tue, 29 Aug 2023 06:52:58 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7A68398 for ; Tue, 29 Aug 2023 03:52:56 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 1505C6545D for ; Tue, 29 Aug 2023 10:52:56 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 7F705C433CB; Tue, 29 Aug 2023 10:52:49 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1693306375; bh=QBvxkEj1DY0GKW8rngBNgzoMssSjhwO/YTw1SWluFmg=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=OYEeptArhVvkKvQD8GAnQQ7kKRo185LJvLlUxpD3JqffnV1vPta0QHepeL+Lm7Jy1 DHGfY2ZST9yW0xzmVbAlR2TRnDitkW94hHS2MeeY8i7E1QTYhTjCGl7E/u7BMlk+wO +PD/RKlgtKR+reTolmIj93qT8Be2pBpty0gMffEW3aetpwudUtJyKy1SRZfGirpkMl eCJm+zbBl8shmnRxgSoK3PEfis40j/3iu/qsI0zwGW7N2T9qUVPMv36qqSRUE0Wdts FBL8/1LdSBNw7q4Hy0sjfLe9B68r+zxXe4QALFXBMJZxRJKgPCzTV6RRGPg/xc4xjE 2gJq4lfwWqzNQ== From: Jisheng Zhang To: Giuseppe Cavallaro , Alexandre Torgue , Jose Abreu , "David S . Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Maxime Coquelin , Shawn Guo , Sascha Hauer , Pengutronix Kernel Team , Fabio Estevam , NXP Linux Team , Vladimir Zapolskiy , Neil Armstrong , Kevin Hilman , Jerome Brunet , Martin Blumenstingl , Emil Renner Berthing , Samin Guo , Chen-Yu Tsai , Jernej Skrabec , Samuel Holland , Thierry Reding , Jonathan Hunter , Nobuhiro Iwamatsu , Russell King , Matthias Brugger , AngeloGioacchino Del Regno , Bartosz Golaszewski Cc: netdev@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Subject: [PATCH net-next 04/22] net: stmmac: dwmac-generic: use devm_stmmac_pltfr_probe() Date: Tue, 29 Aug 2023 18:40:15 +0800 Message-Id: <20230829104033.955-5-jszhang@kernel.org> X-Mailer: git-send-email 2.40.0 In-Reply-To: <20230829104033.955-1-jszhang@kernel.org> References: <20230829104033.955-1-jszhang@kernel.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-7.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, 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-kernel@vger.kernel.org Use the devres variant of stmmac_pltfr_probe() and finally drop the remove() hook. Signed-off-by: Jisheng Zhang --- drivers/net/ethernet/stmicro/stmmac/dwmac-generic.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/net/ethernet/stmicro/stmmac/dwmac-generic.c b/drivers/net/ethernet/stmicro/stmmac/dwmac-generic.c index 84582fc04d2e..598eff926815 100644 --- a/drivers/net/ethernet/stmicro/stmmac/dwmac-generic.c +++ b/drivers/net/ethernet/stmicro/stmmac/dwmac-generic.c @@ -46,7 +46,7 @@ static int dwmac_generic_probe(struct platform_device *pdev) plat_dat->unicast_filter_entries = 1; } - return stmmac_pltfr_probe(pdev, plat_dat, &stmmac_res); + return devm_stmmac_pltfr_probe(pdev, plat_dat, &stmmac_res); } static const struct of_device_id dwmac_generic_match[] = { @@ -67,7 +67,6 @@ MODULE_DEVICE_TABLE(of, dwmac_generic_match); static struct platform_driver dwmac_generic_driver = { .probe = dwmac_generic_probe, - .remove_new = stmmac_pltfr_remove_no_dt, .driver = { .name = STMMAC_RESOURCE_NAME, .pm = &stmmac_pltfr_pm_ops, -- 2.40.1