Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

staging: agnx, fix bssid compiler warnings

conf->bssid is const. Propagate const to not get compiler warnings:
agnx/pci.c: In function ‘agnx_config_interface’:
agnx/pci.c:319: warning: passing argument 2 of ‘agnx_set_bssid’ discards qualifiers from pointer target type
agnx/pci.c:321: warning: passing argument 2 of ‘hash_write’ discards qualifiers from pointer target type

Signed-off-by: Jiri Slaby <jirislaby@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>

authored by

Jiri Slaby and committed by
Greg Kroah-Hartman
5e436d09 8af6caf5

+5 -5
+2 -2
drivers/staging/agnx/phy.c
··· 118 118 iowrite32(reg, ctl + AGNX_RXM_MACLO); 119 119 } 120 120 121 - static void receiver_bssid_set(struct agnx_priv *priv, u8 *bssid) 121 + static void receiver_bssid_set(struct agnx_priv *priv, const u8 *bssid) 122 122 { 123 123 void __iomem *ctl = priv->ctl; 124 124 u32 reg; ··· 954 954 return 0; 955 955 } 956 956 957 - void agnx_set_bssid(struct agnx_priv *priv, u8 *bssid) 957 + void agnx_set_bssid(struct agnx_priv *priv, const u8 *bssid) 958 958 { 959 959 receiver_bssid_set(priv, bssid); 960 960 }
+1 -1
drivers/staging/agnx/phy.h
··· 401 401 void agnx_hw_init(struct agnx_priv *priv); 402 402 int agnx_hw_reset(struct agnx_priv *priv); 403 403 int agnx_set_ssid(struct agnx_priv *priv, u8 *ssid, size_t ssid_len); 404 - void agnx_set_bssid(struct agnx_priv *priv, u8 *bssid); 404 + void agnx_set_bssid(struct agnx_priv *priv, const u8 *bssid); 405 405 void enable_power_saving(struct agnx_priv *priv); 406 406 void disable_power_saving(struct agnx_priv *priv); 407 407 void calibrate_antenna_period(unsigned long data);
+1 -1
drivers/staging/agnx/sta.c
··· 22 22 printk(PFX "RX hash cmd are : %.8x%.8x\n", reghi, reglo); 23 23 } 24 24 25 - void hash_write(struct agnx_priv *priv, u8 *mac_addr, u8 sta_id) 25 + void hash_write(struct agnx_priv *priv, const u8 *mac_addr, u8 sta_id) 26 26 { 27 27 void __iomem *ctl = priv->ctl; 28 28 u32 reghi, reglo;
+1 -1
drivers/staging/agnx/sta.h
··· 201 201 /* 802.11(abg) beacon */ 202 202 } __attribute__((__packed__)); 203 203 204 - void hash_write(struct agnx_priv *priv, u8 *mac_addr, u8 sta_id); 204 + void hash_write(struct agnx_priv *priv, const u8 *mac_addr, u8 sta_id); 205 205 void hash_dump(struct agnx_priv *priv, u8 sta_id); 206 206 void hash_read(struct agnx_priv *priv, u32 reghi, u32 reglo, u8 sta_id); 207 207 void hash_delete(struct agnx_priv *priv, u32 reghi, u32 reglo, u8 sta_id);