mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Philipp Hortmann <philipp.g.hortmann@gmail.com>
To: Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	linux-staging@lists.linux.dev, linux-kernel@vger.kernel.org
Subject: [PATCH 03/11] staging: rtl8192e: Remove entry .initialize_ad.. from struct rtl819x_ops
Date: Sun, 19 Feb 2023 22:15:46 +0100	[thread overview]
Message-ID: <7457e18ea9f3b2415bf41fca8ac2b22349d2edd1.1676840647.git.philipp.g.hortmann@gmail.com> (raw)
In-Reply-To: <cover.1676840647.git.philipp.g.hortmann@gmail.com>

Remove entry .initialize_adapter and replace it with function name
rtl92e_start_adapter. This increases readability of the code.

Signed-off-by: Philipp Hortmann <philipp.g.hortmann@gmail.com>
---
 drivers/staging/rtl8192e/rtl8192e/rtl_core.c | 5 ++---
 drivers/staging/rtl8192e/rtl8192e/rtl_core.h | 1 -
 2 files changed, 2 insertions(+), 4 deletions(-)

diff --git a/drivers/staging/rtl8192e/rtl8192e/rtl_core.c b/drivers/staging/rtl8192e/rtl8192e/rtl_core.c
index 7b8683a9bdb1..3bebc1153572 100644
--- a/drivers/staging/rtl8192e/rtl8192e/rtl_core.c
+++ b/drivers/staging/rtl8192e/rtl8192e/rtl_core.c
@@ -27,7 +27,6 @@ static char *ifname = "wlan%d";
 
 static const struct rtl819x_ops rtl819xp_ops = {
 	.nic_type			= NIC_8192E,
-	.initialize_adapter		= rtl92e_start_adapter,
 	.link_change			= rtl92e_link_change,
 	.tx_fill_descriptor		= rtl92e_fill_tx_desc,
 	.tx_fill_cmd_descriptor		= rtl92e_fill_tx_cmd_desc,
@@ -690,7 +689,7 @@ static int _rtl92e_sta_up(struct net_device *dev, bool is_silent_reset)
 	priv->rtllib->ieee_up = 1;
 
 	priv->up_first_time = 0;
-	init_status = priv->ops->initialize_adapter(dev);
+	init_status = rtl92e_start_adapter(dev);
 	if (!init_status) {
 		netdev_err(dev, "%s(): Initialization failed!\n", __func__);
 		return -1;
@@ -2381,7 +2380,7 @@ bool rtl92e_enable_nic(struct net_device *dev)
 		return false;
 	}
 
-	init_status = priv->ops->initialize_adapter(dev);
+	init_status = rtl92e_start_adapter(dev);
 	if (!init_status) {
 		netdev_warn(dev, "%s(): Initialization failed!\n", __func__);
 		priv->bdisable_nic = false;
diff --git a/drivers/staging/rtl8192e/rtl8192e/rtl_core.h b/drivers/staging/rtl8192e/rtl8192e/rtl_core.h
index 541b7aa366a5..9edadc62faa9 100644
--- a/drivers/staging/rtl8192e/rtl8192e/rtl_core.h
+++ b/drivers/staging/rtl8192e/rtl8192e/rtl_core.h
@@ -206,7 +206,6 @@ struct rtl8192_tx_ring {
 struct rtl819x_ops {
 	enum nic_t nic_type;
 	void (*init_before_adapter_start)(struct net_device *dev);
-	bool (*initialize_adapter)(struct net_device *dev);
 	void (*link_change)(struct net_device *dev);
 	void (*tx_fill_descriptor)(struct net_device *dev,
 				   struct tx_desc *tx_desc,
-- 
2.39.2


  parent reply	other threads:[~2023-02-19 21:16 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-02-19 21:15 [PATCH 00/11] staging: rtl8192e: Remove entries from struct rtl819x_ops start with .get_eeprom_size Philipp Hortmann
2023-02-19 21:15 ` [PATCH 01/11] staging: rtl8192e: Remove entry .get_eeprom_size from struct rtl819x_ops Philipp Hortmann
2023-02-19 21:15 ` [PATCH 02/11] staging: rtl8192e: Remove entry .init_adapter_.. " Philipp Hortmann
2023-02-19 21:15 ` Philipp Hortmann [this message]
2023-02-19 21:15 ` [PATCH 04/11] staging: rtl8192e: Remove entry .tx_fill_descr.. " Philipp Hortmann
2023-02-19 21:16 ` [PATCH 05/11] staging: rtl8192e: Remove entry .tx_fill_cmd_d.. " Philipp Hortmann
2023-02-19 21:16 ` [PATCH 06/11] staging: rtl8192e: Remove entry .rx_query_stat.. " Philipp Hortmann
2023-02-19 21:16 ` [PATCH 07/11] staging: rtl8192e: Remove entry .stop_adapter " Philipp Hortmann
2023-02-19 21:16 ` [PATCH 08/11] staging: rtl8192e: Remove entry .update_ratr_t.. " Philipp Hortmann
2023-02-19 21:16 ` [PATCH 09/11] staging: rtl8192e: Remove entry .irq_enable " Philipp Hortmann
2023-02-19 21:16 ` [PATCH 10/11] staging: rtl8192e: Remove entry .irq_disable " Philipp Hortmann
2023-02-19 21:16 ` [PATCH 11/11] staging: rtl8192e: Remove entry .rx_enable " Philipp Hortmann

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=7457e18ea9f3b2415bf41fca8ac2b22349d2edd1.1676840647.git.philipp.g.hortmann@gmail.com \
    --to=philipp.g.hortmann@gmail.com \
    --cc=gregkh@linuxfoundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-staging@lists.linux.dev \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®