linux-wireless.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Johannes Berg <johannes@sipsolutions.net>
To: pkshih@realtek.com, kvalo@codeaurora.org
Cc: Larry.Finger@lwfinger.net, linux-wireless@vger.kernel.org
Subject: Re: [PATCH 11/17] rtlwifi: halmac: add files to implement halmac ops
Date: Fri, 30 Mar 2018 21:17:11 +0200	[thread overview]
Message-ID: <1522437431.2902.0.camel@sipsolutions.net> (raw)
In-Reply-To: <20180330071916.23360-12-pkshih@realtek.com> (sfid-20180330_092005_131151_0A8F8A2A)

On Fri, 2018-03-30 at 15:19 +0800, pkshih@realtek.com wrote:
> 
> +static struct rtl_halmac_ops rtl_halmac_operation = {

You should make this const, if at all possible (it looks like it should
be).

> +	.halmac_init_adapter = rtl_halmac_init_adapter,
> +	.halmac_deinit_adapter = rtl_halmac_deinit_adapter,
> +	.halmac_init_hal = rtl_halmac_init_hal,
> +	.halmac_deinit_hal = rtl_halmac_deinit_hal,
> +	.halmac_poweron = rtl_halmac_poweron,
> +	.halmac_poweroff = rtl_halmac_poweroff,
> +
> +	.halmac_phy_power_switch = rtl_halmac_phy_power_switch,
> +	.halmac_set_mac_address = rtl_halmac_set_mac_address,
> +	.halmac_set_bssid = rtl_halmac_set_bssid,
> +
> +	.halmac_get_physical_efuse_size = rtl_halmac_get_physical_efuse_size,
> +	.halmac_read_physical_efuse_map = rtl_halmac_read_physical_efuse_map,
> +	.halmac_get_logical_efuse_size = rtl_halmac_get_logical_efuse_size,
> +	.halmac_read_logical_efuse_map = rtl_halmac_read_logical_efuse_map,
> +
> +	.halmac_set_bandwidth = rtl_halmac_set_bandwidth,
> +
> +	.halmac_c2h_handle = rtl_halmac_c2h_handle,
> +
> +	.halmac_chk_txdesc = rtl_halmac_chk_txdesc,
> +	.halmac_iqk = rtl_halmac_iqk,
> +};
> +
> +struct rtl_halmac_ops *rtl_halmac_get_ops_pointer(void)
> +{
> +	return &rtl_halmac_operation;
> +}
> +EXPORT_SYMBOL(rtl_halmac_get_ops_pointer);

This seems like a rather pointless indirection, you can export the
variable.

johannes

  reply	other threads:[~2018-03-30 19:17 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-03-30  7:18 [PATCH 00/17] rtlwifi: halmac: Add new moudle halmac pkshih
2018-03-30  7:19 ` [PATCH 01/17] rtlwifi: add halmac structure to wifi.h pkshih
2018-03-30  7:19 ` [PATCH 02/17] rtlwifi: add debug ID COMP_HALMAC pkshih
2018-03-30  7:19 ` [PATCH 03/17] rtlwifi: add dmdef.h to share with driver and other modules pkshih
2018-03-30  7:19 ` [PATCH 04/17] rtlwifi: halmac: add main definition used by halmac pkshih
2018-03-30  7:19 ` [PATCH 05/17] rtlwifi: halmac: describe number and size of chip functions pkshih
2018-03-30  7:19 ` [PATCH 07/17] rtlwifi: halmac: add definition of TX/RX descriptor pkshih
2018-03-30  7:19 ` [PATCH 08/17] rtlwifi: halmac: add GPIO pin/pinmux definitions pkshih
2018-03-30  7:19 ` [PATCH 09/17] rtlwifi: halmac: add power sequence to turn on/off wifi card pkshih
2018-03-30  7:19 ` [PATCH 10/17] rtlwifi: halmac: access efuse through halmac helper functions pkshih
2018-03-30  7:19 ` [PATCH 11/17] rtlwifi: halmac: add files to implement halmac ops pkshih
2018-03-30 19:17   ` Johannes Berg [this message]
2018-03-31 13:52     ` Pkshih
2018-03-30  7:19 ` [PATCH 12/17] rtlwifi: halmac: add halmac init/deinit functions pkshih
2018-03-30  7:19 ` [PATCH 13/17] rtlwifi: halmac: add firmware related functions and definitions pkshih
2018-03-30  7:19 ` [PATCH 14/17] rtlwifi: halmac: add bus interface commands pkshih
2018-03-30  7:19 ` [PATCH 15/17] rtlwifi: halmac: add to control WiFi mac functions and registers pkshih
2018-03-30  7:19 ` [PATCH 16/17] rtlwifi: halmac: add to support BB and RF functions pkshih
2018-03-30  7:19 ` [PATCH 17/17] rtlwifi: add halmac to Makefile and Kconfig pkshih

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=1522437431.2902.0.camel@sipsolutions.net \
    --to=johannes@sipsolutions.net \
    --cc=Larry.Finger@lwfinger.net \
    --cc=kvalo@codeaurora.org \
    --cc=linux-wireless@vger.kernel.org \
    --cc=pkshih@realtek.com \
    /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;
as well as URLs for NNTP newsgroup(s).