From patchwork Thu Jun 1 08:25:53 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Uwe_Kleine-K=C3=B6nig?= X-Patchwork-Id: 688197 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 8A29DC77B7E for ; Thu, 1 Jun 2023 08:26:20 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231437AbjFAI0T (ORCPT ); Thu, 1 Jun 2023 04:26:19 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:38798 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231378AbjFAI0Q (ORCPT ); Thu, 1 Jun 2023 04:26:16 -0400 Received: from metis.ext.pengutronix.de (metis.ext.pengutronix.de [IPv6:2001:67c:670:201:290:27ff:fe1d:cc33]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 54430E7 for ; Thu, 1 Jun 2023 01:26:15 -0700 (PDT) Received: from drehscheibe.grey.stw.pengutronix.de ([2a0a:edc0:0:c01:1d::a2]) by metis.ext.pengutronix.de with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1q4ddE-0002tt-GT; Thu, 01 Jun 2023 10:26:04 +0200 Received: from [2a0a:edc0:0:900:1d::77] (helo=ptz.office.stw.pengutronix.de) by drehscheibe.grey.stw.pengutronix.de with esmtp (Exim 4.94.2) (envelope-from ) id 1q4ddC-004JKe-VT; Thu, 01 Jun 2023 10:26:02 +0200 Received: from ukl by ptz.office.stw.pengutronix.de with local (Exim 4.94.2) (envelope-from ) id 1q4ddB-00A5yW-Tw; Thu, 01 Jun 2023 10:26:01 +0200 From: =?utf-8?q?Uwe_Kleine-K=C3=B6nig?= To: Kalle Valo , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni Cc: ath10k@lists.infradead.org, linux-wireless@vger.kernel.org, netdev@vger.kernel.org, kernel@pengutronix.de Subject: [PATCH net-next 1/4] ath10k: Drop cleaning of driver data from probe error path and remove Date: Thu, 1 Jun 2023 10:25:53 +0200 Message-Id: <20230601082556.2738446-2-u.kleine-koenig@pengutronix.de> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230601082556.2738446-1-u.kleine-koenig@pengutronix.de> References: <20230601082556.2738446-1-u.kleine-koenig@pengutronix.de> MIME-Version: 1.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=942; i=u.kleine-koenig@pengutronix.de; h=from:subject; bh=/b+eoSPz9HG2VPpR1UR16uVKTcTD7gKSXld+WjvDuk4=; b=owEBbQGS/pANAwAKAY+A+1h9Ev5OAcsmYgBkeFYMjksFhfS3h1NyC7+gR5ba3ymfDLI1F5L1W gHLt4wuLt2JATMEAAEKAB0WIQQ/gaxpOnoeWYmt/tOPgPtYfRL+TgUCZHhWDAAKCRCPgPtYfRL+ TskTCAC7CWyAAZFHB8MYkQ+a5zOuyFeqHkD8VWZl7bDu3yq6x4OTYwLbvQnLT+r42HFnISJV69m xjJhmqV5zUGCSt9SUQKeNHfJFjUX1mK1q7i2jhKPD6Nk6n3Za+72WIB4tv5V8bVQEri5h37OffV OSt9rmwBRHSCAyClqqI0jiU6iZKzkIKyxkmew+rhrKepaIrhFvx3CoB9rk7sObsHF8IydpaM+J4 0OcEbDAPIvWahtN/xETDwsYYNK9xF3oSlCFpGxNM/9CuJDR770Nuvo8wvobCsAm3WkxZb02qUnX /0xx6DGSmkw/xM3wfEvl0OyC+ib8XuR0Y/ukEhc4PUB6SQ2F X-Developer-Key: i=u.kleine-koenig@pengutronix.de; a=openpgp; fpr=0D2511F322BFAB1C1580266BE2DCDD9132669BD6 X-SA-Exim-Connect-IP: 2a0a:edc0:0:c01:1d::a2 X-SA-Exim-Mail-From: ukl@pengutronix.de X-SA-Exim-Scanned: No (on metis.ext.pengutronix.de); SAEximRunCond expanded to false X-PTX-Original-Recipient: linux-wireless@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org The driver core cares for resetting driver data if probe fails and after remove. So drop the explicit and duplicate cleanup in the driver's functions. Signed-off-by: Uwe Kleine-König Reviewed-by: Simon Horman --- drivers/net/wireless/ath/ath10k/ahb.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/drivers/net/wireless/ath/ath10k/ahb.c b/drivers/net/wireless/ath/ath10k/ahb.c index f0c615fa5614..7bb45c66cff7 100644 --- a/drivers/net/wireless/ath/ath10k/ahb.c +++ b/drivers/net/wireless/ath/ath10k/ahb.c @@ -816,7 +816,6 @@ static int ath10k_ahb_probe(struct platform_device *pdev) err_core_destroy: ath10k_core_destroy(ar); - platform_set_drvdata(pdev, NULL); return ret; } @@ -845,8 +844,6 @@ static int ath10k_ahb_remove(struct platform_device *pdev) ath10k_ahb_resource_deinit(ar); ath10k_core_destroy(ar); - platform_set_drvdata(pdev, NULL); - return 0; } From patchwork Thu Jun 1 08:25:54 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Uwe_Kleine-K=C3=B6nig?= X-Patchwork-Id: 688198 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 0A9CDC77B7A for ; Thu, 1 Jun 2023 08:26:19 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231642AbjFAI0R (ORCPT ); Thu, 1 Jun 2023 04:26:17 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:38796 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231151AbjFAI0Q (ORCPT ); Thu, 1 Jun 2023 04:26:16 -0400 Received: from metis.ext.pengutronix.de (metis.ext.pengutronix.de [IPv6:2001:67c:670:201:290:27ff:fe1d:cc33]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0966E125 for ; Thu, 1 Jun 2023 01:26:15 -0700 (PDT) Received: from drehscheibe.grey.stw.pengutronix.de ([2a0a:edc0:0:c01:1d::a2]) by metis.ext.pengutronix.de with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1q4ddE-0002th-GT; Thu, 01 Jun 2023 10:26:04 +0200 Received: from [2a0a:edc0:0:900:1d::77] (helo=ptz.office.stw.pengutronix.de) by drehscheibe.grey.stw.pengutronix.de with esmtp (Exim 4.94.2) (envelope-from ) id 1q4ddC-004JKY-Se; Thu, 01 Jun 2023 10:26:02 +0200 Received: from ukl by ptz.office.stw.pengutronix.de with local (Exim 4.94.2) (envelope-from ) id 1q4ddC-00A5yZ-4N; Thu, 01 Jun 2023 10:26:02 +0200 From: =?utf-8?q?Uwe_Kleine-K=C3=B6nig?= To: Kalle Valo , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni Cc: ath10k@lists.infradead.org, linux-wireless@vger.kernel.org, netdev@vger.kernel.org, kernel@pengutronix.de Subject: [PATCH net-next 2/4] ath10k: Drop checks that are always false Date: Thu, 1 Jun 2023 10:25:54 +0200 Message-Id: <20230601082556.2738446-3-u.kleine-koenig@pengutronix.de> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230601082556.2738446-1-u.kleine-koenig@pengutronix.de> References: <20230601082556.2738446-1-u.kleine-koenig@pengutronix.de> MIME-Version: 1.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=1156; i=u.kleine-koenig@pengutronix.de; h=from:subject; bh=Yfnwqnu04xN5zBPB75lffig/GKnzspVu8L0rjK4grlM=; b=owEBbQGS/pANAwAKAY+A+1h9Ev5OAcsmYgBkeFYNH9B9+cgVgG1rALdO44a+2awW1rJORFSvx 5lBEbtN+3eJATMEAAEKAB0WIQQ/gaxpOnoeWYmt/tOPgPtYfRL+TgUCZHhWDQAKCRCPgPtYfRL+ TpRCB/47yB+eQRU7pdV1LYcp0fUx1OeF3hlOATCnnNXYV4ZMpzUEemcA9EZktaH4Ako6XjMW9D9 3wDC53dbWEhhRYJ/NNnaz9NZp9cG88rtC3ij4HdEwjSeGUdU2UhSfhaEFwNWtzhKLPeCbEgZhTH FGgtQ5Hiriu79W9CPXymRD1QXisW8Hs8ZOUtmE7ddnS5xnXJiHB3s3OZ7VGGsbKPjDxerJ895mo YRBLWh3Trd8eaBSRbjxqeDLHZEKe0iod0ea7buh3YFZYzCgacYMFcwe2dV0eUhPm3PGfABPrHrL RZ0q6czA2fUYs93OrE72DGM0v7Ikhx1OLEzRSAczbVaQRVsk X-Developer-Key: i=u.kleine-koenig@pengutronix.de; a=openpgp; fpr=0D2511F322BFAB1C1580266BE2DCDD9132669BD6 X-SA-Exim-Connect-IP: 2a0a:edc0:0:c01:1d::a2 X-SA-Exim-Mail-From: ukl@pengutronix.de X-SA-Exim-Scanned: No (on metis.ext.pengutronix.de); SAEximRunCond expanded to false X-PTX-Original-Recipient: linux-wireless@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org platform_get_drvdata() cannot return NULL as the probe function calls platform_set_drvdata() with a non-NULL argument or returns with a failure. In the first case, platform_get_drvdata() returns this non-NULL value and in the second the remove callback isn't called at all. ath10k_ahb_priv() cannot return NULL and ar_ahb is unused after the check anyhow. Signed-off-by: Uwe Kleine-König --- drivers/net/wireless/ath/ath10k/ahb.c | 9 --------- 1 file changed, 9 deletions(-) diff --git a/drivers/net/wireless/ath/ath10k/ahb.c b/drivers/net/wireless/ath/ath10k/ahb.c index 7bb45c66cff7..fffdbad75074 100644 --- a/drivers/net/wireless/ath/ath10k/ahb.c +++ b/drivers/net/wireless/ath/ath10k/ahb.c @@ -823,15 +823,6 @@ static int ath10k_ahb_probe(struct platform_device *pdev) static int ath10k_ahb_remove(struct platform_device *pdev) { struct ath10k *ar = platform_get_drvdata(pdev); - struct ath10k_ahb *ar_ahb; - - if (!ar) - return -EINVAL; - - ar_ahb = ath10k_ahb_priv(ar); - - if (!ar_ahb) - return -EINVAL; ath10k_dbg(ar, ATH10K_DBG_AHB, "ahb remove\n"); From patchwork Thu Jun 1 08:25:55 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Uwe_Kleine-K=C3=B6nig?= X-Patchwork-Id: 688723 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 5835BC7EE2F for ; Thu, 1 Jun 2023 08:26:20 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231151AbjFAI0S (ORCPT ); Thu, 1 Jun 2023 04:26:18 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:38796 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231365AbjFAI0Q (ORCPT ); Thu, 1 Jun 2023 04:26:16 -0400 Received: from metis.ext.pengutronix.de (metis.ext.pengutronix.de [IPv6:2001:67c:670:201:290:27ff:fe1d:cc33]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0B243126 for ; Thu, 1 Jun 2023 01:26:15 -0700 (PDT) Received: from drehscheibe.grey.stw.pengutronix.de ([2a0a:edc0:0:c01:1d::a2]) by metis.ext.pengutronix.de with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1q4ddE-0002u2-GT; Thu, 01 Jun 2023 10:26:04 +0200 Received: from [2a0a:edc0:0:900:1d::77] (helo=ptz.office.stw.pengutronix.de) by drehscheibe.grey.stw.pengutronix.de with esmtp (Exim 4.94.2) (envelope-from ) id 1q4ddC-004JKf-WC; Thu, 01 Jun 2023 10:26:03 +0200 Received: from ukl by ptz.office.stw.pengutronix.de with local (Exim 4.94.2) (envelope-from ) id 1q4ddC-00A5yc-DB; Thu, 01 Jun 2023 10:26:02 +0200 From: =?utf-8?q?Uwe_Kleine-K=C3=B6nig?= To: Kalle Valo , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni Cc: ath10k@lists.infradead.org, linux-wireless@vger.kernel.org, netdev@vger.kernel.org, kernel@pengutronix.de Subject: [PATCH net-next 3/4] ath10k: Convert to platform remove callback returning void Date: Thu, 1 Jun 2023 10:25:55 +0200 Message-Id: <20230601082556.2738446-4-u.kleine-koenig@pengutronix.de> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230601082556.2738446-1-u.kleine-koenig@pengutronix.de> References: <20230601082556.2738446-1-u.kleine-koenig@pengutronix.de> MIME-Version: 1.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=3192; i=u.kleine-koenig@pengutronix.de; h=from:subject; bh=wPyGg8vqpI8ICYVHsb0hUkRVG2HoNMcDpA8BThv+i/s=; b=owGbwMvMwMXY3/A7olbonx/jabUkhpSKMP6rJpo9+xvfsvtVLnt5ZKsPF+vVxqXmyz1XTVZXu rj3wWa9TkZjFgZGLgZZMUUW+8Y1mVZVcpGda/9dhhnEygQyhYGLUwAmknGHg6Epw1nEuX3Ps/YL LCozXG/LN7wQVf7y4s6CeW4VdlOsGc6bGX7+8iD6nktBurDCxxl3TzcoKkU84ksvYvdleRih/8J sxYMSty1dJa23Xj76E+yzQOXIBO88s2+xSkFyNzYwMRyzivZPOmzlvrXLQ6aRXfTWk377dpb7q9 7Jei39drj2n8XUyjiT11PnLOE6bvHc5dS6xYUR7O+Ninx/Hze6I7PezjSZhS3l/ESBbf0uy8KDv ppejPb99vrv7bj4vfcCe7PmaZZPi2AIushxLnqpsBjP2fSUzJU1zY5OmxllzmTsWbqc/0Bwaa// 3DWRAbKbDkVb2sxjnXE8PCFmYq2MarZQkQg7e/72WpliAA== X-Developer-Key: i=u.kleine-koenig@pengutronix.de; a=openpgp; fpr=0D2511F322BFAB1C1580266BE2DCDD9132669BD6 X-SA-Exim-Connect-IP: 2a0a:edc0:0:c01:1d::a2 X-SA-Exim-Mail-From: ukl@pengutronix.de X-SA-Exim-Scanned: No (on metis.ext.pengutronix.de); SAEximRunCond expanded to false X-PTX-Original-Recipient: linux-wireless@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org The .remove() callback for a platform driver returns an int which makes many driver authors wrongly assume it's possible to do error handling by returning an error code. However the value returned is (mostly) ignored and this typically results in resource leaks. To improve here there is a quest to make the remove callback return void. In the first step of this quest all drivers are converted to .remove_new() which already returns void. Both ath10k platform drivers return zero unconditionally in their remove callback, so they can be trivially converted to use .remove_new(). Also fix on of the more offending whitespace issues in the definition of ath10k_snoc_driver. Signed-off-by: Uwe Kleine-König --- drivers/net/wireless/ath/ath10k/ahb.c | 6 ++---- drivers/net/wireless/ath/ath10k/snoc.c | 8 +++----- 2 files changed, 5 insertions(+), 9 deletions(-) diff --git a/drivers/net/wireless/ath/ath10k/ahb.c b/drivers/net/wireless/ath/ath10k/ahb.c index fffdbad75074..632da4c5e5da 100644 --- a/drivers/net/wireless/ath/ath10k/ahb.c +++ b/drivers/net/wireless/ath/ath10k/ahb.c @@ -820,7 +820,7 @@ static int ath10k_ahb_probe(struct platform_device *pdev) return ret; } -static int ath10k_ahb_remove(struct platform_device *pdev) +static void ath10k_ahb_remove(struct platform_device *pdev) { struct ath10k *ar = platform_get_drvdata(pdev); @@ -834,8 +834,6 @@ static int ath10k_ahb_remove(struct platform_device *pdev) ath10k_ahb_clock_disable(ar); ath10k_ahb_resource_deinit(ar); ath10k_core_destroy(ar); - - return 0; } static struct platform_driver ath10k_ahb_driver = { @@ -844,7 +842,7 @@ static struct platform_driver ath10k_ahb_driver = { .of_match_table = ath10k_ahb_of_match, }, .probe = ath10k_ahb_probe, - .remove = ath10k_ahb_remove, + .remove_new = ath10k_ahb_remove, }; int ath10k_ahb_init(void) diff --git a/drivers/net/wireless/ath/ath10k/snoc.c b/drivers/net/wireless/ath/ath10k/snoc.c index 5128a452c65f..26214c00cd0d 100644 --- a/drivers/net/wireless/ath/ath10k/snoc.c +++ b/drivers/net/wireless/ath/ath10k/snoc.c @@ -1848,7 +1848,7 @@ static int ath10k_snoc_free_resources(struct ath10k *ar) return 0; } -static int ath10k_snoc_remove(struct platform_device *pdev) +static void ath10k_snoc_remove(struct platform_device *pdev) { struct ath10k *ar = platform_get_drvdata(pdev); struct ath10k_snoc *ar_snoc = ath10k_snoc_priv(ar); @@ -1861,8 +1861,6 @@ static int ath10k_snoc_remove(struct platform_device *pdev) wait_for_completion_timeout(&ar->driver_recovery, 3 * HZ); ath10k_snoc_free_resources(ar); - - return 0; } static void ath10k_snoc_shutdown(struct platform_device *pdev) @@ -1875,8 +1873,8 @@ static void ath10k_snoc_shutdown(struct platform_device *pdev) static struct platform_driver ath10k_snoc_driver = { .probe = ath10k_snoc_probe, - .remove = ath10k_snoc_remove, - .shutdown = ath10k_snoc_shutdown, + .remove_new = ath10k_snoc_remove, + .shutdown = ath10k_snoc_shutdown, .driver = { .name = "ath10k_snoc", .of_match_table = ath10k_snoc_dt_match, From patchwork Thu Jun 1 08:25:56 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Uwe_Kleine-K=C3=B6nig?= X-Patchwork-Id: 688724 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 1E4D8C77B7E for ; Thu, 1 Jun 2023 08:26:18 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231493AbjFAI0R (ORCPT ); Thu, 1 Jun 2023 04:26:17 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:38796 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229882AbjFAI0P (ORCPT ); Thu, 1 Jun 2023 04:26:15 -0400 Received: from metis.ext.pengutronix.de (metis.ext.pengutronix.de [IPv6:2001:67c:670:201:290:27ff:fe1d:cc33]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id B976D11F for ; Thu, 1 Jun 2023 01:26:14 -0700 (PDT) Received: from drehscheibe.grey.stw.pengutronix.de ([2a0a:edc0:0:c01:1d::a2]) by metis.ext.pengutronix.de with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1q4ddE-0002uE-GT; Thu, 01 Jun 2023 10:26:04 +0200 Received: from [2a0a:edc0:0:900:1d::77] (helo=ptz.office.stw.pengutronix.de) by drehscheibe.grey.stw.pengutronix.de with esmtp (Exim 4.94.2) (envelope-from ) id 1q4ddD-004JKk-Kn; Thu, 01 Jun 2023 10:26:03 +0200 Received: from ukl by ptz.office.stw.pengutronix.de with local (Exim 4.94.2) (envelope-from ) id 1q4ddC-00A5yf-KJ; Thu, 01 Jun 2023 10:26:02 +0200 From: =?utf-8?q?Uwe_Kleine-K=C3=B6nig?= To: Kalle Valo , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni Cc: ath10k@lists.infradead.org, linux-wireless@vger.kernel.org, netdev@vger.kernel.org, kernel@pengutronix.de Subject: [PATCH net-next 4/4] atk10k: Don't opencode ath10k_pci_priv() in ath10k_ahb_priv() Date: Thu, 1 Jun 2023 10:25:56 +0200 Message-Id: <20230601082556.2738446-5-u.kleine-koenig@pengutronix.de> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230601082556.2738446-1-u.kleine-koenig@pengutronix.de> References: <20230601082556.2738446-1-u.kleine-koenig@pengutronix.de> MIME-Version: 1.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=824; i=u.kleine-koenig@pengutronix.de; h=from:subject; bh=mB84wW1K4jc1xLTUjLQHhA/td0xttZYqfcR4I36/mvA=; b=owEBbQGS/pANAwAKAY+A+1h9Ev5OAcsmYgBkeFYQL7s14DdzYELR1Cx2HAvAJ61K34lTqhuXN Yq/CSdxCiOJATMEAAEKAB0WIQQ/gaxpOnoeWYmt/tOPgPtYfRL+TgUCZHhWEAAKCRCPgPtYfRL+ Tio+B/4hk7D3EVxU+bfB+uzq0dJigX32SKnyzzrImpCpKSo5DIu/Cwrm2CPNSpRyoxsJA9EG/Db rqDhS1JCk4QrSgjoYWVMOJ35wLdxVEQYKBxN8QcvtTz5+Ng88zEnXV06eoK7m3X7A6yPfdRiALT 4rpj5oY8Jis7gIyjEXXMi0/1evYR6wVFLcUOSX9mdc3cFwlKWa3u8Kd7Cvr0O/0vdWHbktCOn3G Esc9RYWUxaMLW0aC3c0dYxqV50Bthr17alGpMQvFJxxQUc4pNNShI0J+zDxNrp1NgjO9Mh3jPeR Ryk307k+z6X1zimvOzeOrKgvT3fiMqDI5/pj9O8Cf/4qXfLL X-Developer-Key: i=u.kleine-koenig@pengutronix.de; a=openpgp; fpr=0D2511F322BFAB1C1580266BE2DCDD9132669BD6 X-SA-Exim-Connect-IP: 2a0a:edc0:0:c01:1d::a2 X-SA-Exim-Mail-From: ukl@pengutronix.de X-SA-Exim-Scanned: No (on metis.ext.pengutronix.de); SAEximRunCond expanded to false X-PTX-Original-Recipient: linux-wireless@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org This introduces no changes in the compiled result (tested for an ARCH=arm allmodconfig build). Signed-off-by: Uwe Kleine-König --- drivers/net/wireless/ath/ath10k/ahb.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/wireless/ath/ath10k/ahb.c b/drivers/net/wireless/ath/ath10k/ahb.c index 632da4c5e5da..4a006fb4d424 100644 --- a/drivers/net/wireless/ath/ath10k/ahb.c +++ b/drivers/net/wireless/ath/ath10k/ahb.c @@ -27,7 +27,7 @@ MODULE_DEVICE_TABLE(of, ath10k_ahb_of_match); static inline struct ath10k_ahb *ath10k_ahb_priv(struct ath10k *ar) { - return &((struct ath10k_pci *)ar->drv_priv)->ahb[0]; + return &ath10k_pci_priv(ar)->ahb[0]; } static void ath10k_ahb_write32(struct ath10k *ar, u32 offset, u32 value)