提交 d0cf28f1 编写于 作者: J Jakub Kicinski 提交者: Greg Kroah-Hartman

staging: rtl8712: prepare for const netdev->dev_addr

netdev->dev_addr will be const soon, make sure the qualifier
is respected by drivers.
Signed-off-by: NJakub Kicinski <kuba@kernel.org>
Link: https://lore.kernel.org/r/20211019171243.1412240-6-kuba@kernel.orgSigned-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
上级 e7fd1a5a
...@@ -388,7 +388,8 @@ static int netdev_open(struct net_device *pnetdev) ...@@ -388,7 +388,8 @@ static int netdev_open(struct net_device *pnetdev)
* address. * address.
*/ */
msleep(200); msleep(200);
r8712_setMacAddr_cmd(padapter, (u8 *)pnetdev->dev_addr); r8712_setMacAddr_cmd(padapter,
(const u8 *)pnetdev->dev_addr);
/* /*
* The "myid" function will get the wifi mac address * The "myid" function will get the wifi mac address
* from eeprompriv structure instead of netdev * from eeprompriv structure instead of netdev
......
...@@ -554,7 +554,7 @@ void r8712_setstakey_cmd(struct _adapter *padapter, u8 *psta, u8 unicast_key) ...@@ -554,7 +554,7 @@ void r8712_setstakey_cmd(struct _adapter *padapter, u8 *psta, u8 unicast_key)
r8712_enqueue_cmd(pcmdpriv, ph2c); r8712_enqueue_cmd(pcmdpriv, ph2c);
} }
void r8712_setMacAddr_cmd(struct _adapter *padapter, u8 *mac_addr) void r8712_setMacAddr_cmd(struct _adapter *padapter, const u8 *mac_addr)
{ {
struct cmd_priv *pcmdpriv = &padapter->cmdpriv; struct cmd_priv *pcmdpriv = &padapter->cmdpriv;
struct cmd_obj *ph2c; struct cmd_obj *ph2c;
......
...@@ -718,7 +718,7 @@ struct DisconnectCtrlEx_param { ...@@ -718,7 +718,7 @@ struct DisconnectCtrlEx_param {
#define H2C_CMD_OVERFLOW 0x06 #define H2C_CMD_OVERFLOW 0x06
#define H2C_RESERVED 0x07 #define H2C_RESERVED 0x07
void r8712_setMacAddr_cmd(struct _adapter *padapter, u8 *mac_addr); void r8712_setMacAddr_cmd(struct _adapter *padapter, const u8 *mac_addr);
u8 r8712_sitesurvey_cmd(struct _adapter *padapter, u8 r8712_sitesurvey_cmd(struct _adapter *padapter,
struct ndis_802_11_ssid *pssid); struct ndis_802_11_ssid *pssid);
int r8712_createbss_cmd(struct _adapter *padapter); int r8712_createbss_cmd(struct _adapter *padapter);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册