Skip to contentSkip to conversation

staging:rtl8192u: Fix naming clash of exported symbol

PATCH In review John Whitmore 2 participants 4 messages Sep 4, 2018 – Sep 11, 2018 Staging

lore
Share & tools
lore
#0 lore raw

cover staging:rtl8192u: Fix naming clash of exported symbol

Not sure of the procedure having made a mess of the build, (by reusing the name of an exported symbol). I hope that given the obscurity of rtl1892u this doesn't cause people issues. Obviously given the fact that I renamed an exported symbol I should have checked the name. Newbie mistake, I can only apologise for the oversight, sorry.

John Whitmore (1):
staging:rtl8192u: Rename dot11d_init to fix name clash

 drivers/staging/rtl8192u/ieee80211/dot11d.c | 6 +++---
 drivers/staging/rtl8192u/ieee80211/dot11d.h | 2 +-
 drivers/staging/rtl8192u/r8192U_core.c      | 2 +-
 3 files changed, 5 insertions(+), 5 deletions(-)
Signature · 1 line
2.18.0
#1 lore raw

PATCH 1/1 staging:rtl8192u: Rename dot11d_init to fix name clash

The function dot11d_init() was previously renamed to clear a style issue. Unfortunately the new name used, dot11d_init(), clashes with a sybmol which is exported with the same name. To correct this problem the function has been renamed to rtl8192u_dot11d_init().

---
 drivers/staging/rtl8192u/ieee80211/dot11d.c | 6 +++---
 drivers/staging/rtl8192u/ieee80211/dot11d.h | 2 +-
 drivers/staging/rtl8192u/r8192U_core.c      | 2 +-
 3 files changed, 5 insertions(+), 5 deletions(-)
drivers/staging/rtl8192u/ieee80211/dot11d.c +3 -3
index d3b13f0cfc09..3c8e8ba999cf 100644
@@ -3,7 +3,7 @@
 
 #include "dot11d.h"
 
-void dot11d_init(struct ieee80211_device *ieee)
+void rtl8192u_dot11d_init(struct ieee80211_device *ieee)
 {
 	struct rt_dot11d_info *pDot11dInfo = GET_DOT11D_INFO(ieee);
 
@@ -15,9 +15,9 @@ void dot11d_init(struct ieee80211_device *ieee)
 	memset(pDot11dInfo->max_tx_pwr_dbm_list, 0xFF, MAX_CHANNEL_NUMBER+1);
 	RESET_CIE_WATCHDOG(ieee);
 
-	netdev_info(ieee->dev, "dot11d_init()\n");
+	netdev_info(ieee->dev, "rtl8192u_dot11d_init()\n");
 }
-EXPORT_SYMBOL(dot11d_init);
+EXPORT_SYMBOL(rtl8192u_dot11d_init);
 
 /* Reset to the state as we are just entering a regulatory domain. */
 void dot11d_reset(struct ieee80211_device *ieee)
drivers/staging/rtl8192u/ieee80211/dot11d.h +1 -1
index be59f720ae20..d217eb8063c4 100644
@@ -43,7 +43,7 @@ struct rt_dot11d_info {
 #define RESET_CIE_WATCHDOG(ieee_dev) (GET_CIE_WATCHDOG(ieee_dev) = 0)
 #define UPDATE_CIE_WATCHDOG(ieee_dev) (++GET_CIE_WATCHDOG(ieee_dev))
 
-void dot11d_init(struct ieee80211_device *dev);
+void rtl8192u_dot11d_init(struct ieee80211_device *dev);
 void dot11d_reset(struct ieee80211_device *dev);
 void dot11d_update_country_ie(struct ieee80211_device *dev,
 			      u8 *addr,
drivers/staging/rtl8192u/r8192U_core.c +1 -1
index 6b22aaa40ff9..0a21a76dcbc3 100644
@@ -183,7 +183,7 @@ static void rtl819x_set_channel_map(u8 channel_plan, struct r8192_priv *priv)
 	case COUNTRY_CODE_ISRAEL:
 	case COUNTRY_CODE_TELEC:
 	case COUNTRY_CODE_MIC:
-		dot11d_init(ieee);
+		rtl8192u_dot11d_init(ieee);
 		ieee->bGlobalDomain = false;
 		/* actually 8225 & 8256 rf chips only support B,G,24N mode */
 		if ((priv->rf_chip == RF_8225) || (priv->rf_chip == RF_8256)) {
Signature · 1 line
2.18.0
maintainer
#2 lore raw

Re: [PATCH 1/1] staging:rtl8192u: Rename dot11d_init to fix name clash

Quoted 6 lines · John Whitmore

The function dot11d_init() was previously renamed to clear a style issue. Unfortunately the new name used, dot11d_init(), clashes with a sybmol which is exported with the same name. To correct this problem the function has been renamed to rtl8192u_dot11d_init().

You forgot a "Reported-by:" tag here. I'll go add it...

thanks,

greg k-h

#3 lore raw

Re: [PATCH 1/1] staging:rtl8192u: Rename dot11d_init to fix name clash

Quoted 6 lines · Greg KH
Quoted 5 lines · John Whitmore

The function dot11d_init() was previously renamed to clear a style issue. Unfortunately the new name used, dot11d_init(), clashes with a sybmol which is exported with the same name. To correct this problem the function has been renamed to rtl8192u_dot11d_init().

Quoted 7 lines
Quoted 1 line

You forgot a "Reported-by:" tag here. I'll go add it...

thanks,

greg k-h

Sorry and thank you.