Re: [PATCH V2] Staging: rtl8192 Clean up function definition

2015-04-01 Thread Dan Carpenter
On Tue, Mar 31, 2015 at 01:25:02PM -0600, Eddie Kovsky wrote:
> On Tue, Mar 31, 2015 at 10:14:54AM +0300, Dan Carpenter wrote:
> > On Mon, Mar 30, 2015 at 05:05:36PM -0600, Eddie Kovsky wrote:
> > > Change function definition to static, move the function further up in
> > > the file, and delete the function prototype.
> > > 
> > > This fixes the following warning generated by sparse:
> > > 
> > > drivers/staging/rtl8192u/r8192U_core.c:1970:6: warning: symbol
> > > 'rtl8192_update_ratr_table' was not declared. Should it be static?
> > > 
> > 
> > Someone already fixed the warning earlier but this this is still a nice
> > patch to have.
> > 
> > regards,
> > dan carpenter
> Dan
> 
> I sent in the patch last week to fix this warning. You had asked me to
> clean up the function by removing the prototype instead. Greg had
> already sent me a message saying he picked up that patch. I waited a few
> cycles, but I still haven't seen my patch show up in yesterday's (or
> today's) next.

Greg has a testing tree where patches sit for a bit before they hit
linux-next.

> 
> I assume my original patch got dropped waiting on this one?

He would have emailed you if your patch was dropped.

But maybe hold off and resend with an updated patch when it hits.

regards,
dan carpenter

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [PATCH V2] Staging: rtl8192 Clean up function definition

2015-04-01 Thread Dan Carpenter
On Tue, Mar 31, 2015 at 01:25:02PM -0600, Eddie Kovsky wrote:
 On Tue, Mar 31, 2015 at 10:14:54AM +0300, Dan Carpenter wrote:
  On Mon, Mar 30, 2015 at 05:05:36PM -0600, Eddie Kovsky wrote:
   Change function definition to static, move the function further up in
   the file, and delete the function prototype.
   
   This fixes the following warning generated by sparse:
   
   drivers/staging/rtl8192u/r8192U_core.c:1970:6: warning: symbol
   'rtl8192_update_ratr_table' was not declared. Should it be static?
   
  
  Someone already fixed the warning earlier but this this is still a nice
  patch to have.
  
  regards,
  dan carpenter
 Dan
 
 I sent in the patch last week to fix this warning. You had asked me to
 clean up the function by removing the prototype instead. Greg had
 already sent me a message saying he picked up that patch. I waited a few
 cycles, but I still haven't seen my patch show up in yesterday's (or
 today's) next.

Greg has a testing tree where patches sit for a bit before they hit
linux-next.

 
 I assume my original patch got dropped waiting on this one?

He would have emailed you if your patch was dropped.

But maybe hold off and resend with an updated patch when it hits.

regards,
dan carpenter

--
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [PATCH V2] Staging: rtl8192 Clean up function definition

2015-03-31 Thread Eddie Kovsky
On Tue, Mar 31, 2015 at 10:14:54AM +0300, Dan Carpenter wrote:
> On Mon, Mar 30, 2015 at 05:05:36PM -0600, Eddie Kovsky wrote:
> > Change function definition to static, move the function further up in
> > the file, and delete the function prototype.
> > 
> > This fixes the following warning generated by sparse:
> > 
> > drivers/staging/rtl8192u/r8192U_core.c:1970:6: warning: symbol
> > 'rtl8192_update_ratr_table' was not declared. Should it be static?
> > 
> 
> Someone already fixed the warning earlier but this this is still a nice
> patch to have.
> 
> regards,
> dan carpenter
Dan

I sent in the patch last week to fix this warning. You had asked me to
clean up the function by removing the prototype instead. Greg had
already sent me a message saying he picked up that patch. I waited a few
cycles, but I still haven't seen my patch show up in yesterday's (or
today's) next.

I assume my original patch got dropped waiting on this one?

Eddie
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [PATCH V2] Staging: rtl8192 Clean up function definition

2015-03-31 Thread Dan Carpenter
On Mon, Mar 30, 2015 at 05:05:36PM -0600, Eddie Kovsky wrote:
> Change function definition to static, move the function further up in
> the file, and delete the function prototype.
> 
> This fixes the following warning generated by sparse:
> 
> drivers/staging/rtl8192u/r8192U_core.c:1970:6: warning: symbol
> 'rtl8192_update_ratr_table' was not declared. Should it be static?
> 

Someone already fixed the warning earlier but this this is still a nice
patch to have.

regards,
dan carpenter
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [PATCH V2] Staging: rtl8192 Clean up function definition

2015-03-31 Thread Dan Carpenter
On Mon, Mar 30, 2015 at 05:05:36PM -0600, Eddie Kovsky wrote:
 Change function definition to static, move the function further up in
 the file, and delete the function prototype.
 
 This fixes the following warning generated by sparse:
 
 drivers/staging/rtl8192u/r8192U_core.c:1970:6: warning: symbol
 'rtl8192_update_ratr_table' was not declared. Should it be static?
 

Someone already fixed the warning earlier but this this is still a nice
patch to have.

regards,
dan carpenter
--
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [PATCH V2] Staging: rtl8192 Clean up function definition

2015-03-31 Thread Eddie Kovsky
On Tue, Mar 31, 2015 at 10:14:54AM +0300, Dan Carpenter wrote:
 On Mon, Mar 30, 2015 at 05:05:36PM -0600, Eddie Kovsky wrote:
  Change function definition to static, move the function further up in
  the file, and delete the function prototype.
  
  This fixes the following warning generated by sparse:
  
  drivers/staging/rtl8192u/r8192U_core.c:1970:6: warning: symbol
  'rtl8192_update_ratr_table' was not declared. Should it be static?
  
 
 Someone already fixed the warning earlier but this this is still a nice
 patch to have.
 
 regards,
 dan carpenter
Dan

I sent in the patch last week to fix this warning. You had asked me to
clean up the function by removing the prototype instead. Greg had
already sent me a message saying he picked up that patch. I waited a few
cycles, but I still haven't seen my patch show up in yesterday's (or
today's) next.

I assume my original patch got dropped waiting on this one?

Eddie
--
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


[PATCH V2] Staging: rtl8192 Clean up function definition

2015-03-30 Thread Eddie Kovsky
Change function definition to static, move the function further up in
the file, and delete the function prototype.

This fixes the following warning generated by sparse:

drivers/staging/rtl8192u/r8192U_core.c:1970:6: warning: symbol
'rtl8192_update_ratr_table' was not declared. Should it be static?

Signed-off-by: Eddie Kovsky 
---
 drivers/staging/rtl8192u/r8192U_core.c | 87 +-
 1 file changed, 44 insertions(+), 43 deletions(-)

diff --git a/drivers/staging/rtl8192u/r8192U_core.c 
b/drivers/staging/rtl8192u/r8192U_core.c
index 8834c23d67fc..f16a0a45611f 100644
--- a/drivers/staging/rtl8192u/r8192U_core.c
+++ b/drivers/staging/rtl8192u/r8192U_core.c
@@ -1762,7 +1762,50 @@ void rtl8192_usb_deleteendpoints(struct net_device *dev)
 }
 #endif
 
-static void rtl8192_update_ratr_table(struct net_device *dev);
+static void rtl8192_update_ratr_table(struct net_device *dev)
+{
+   struct r8192_priv *priv = ieee80211_priv(dev);
+   struct ieee80211_device *ieee = priv->ieee80211;
+   u8 *pMcsRate = ieee->dot11HTOperationalRateSet;
+   u32 ratr_value = 0;
+   u8 rate_index = 0;
+   rtl8192_config_rate(dev, (u16 *)(_value));
+
+   ratr_value |= (*(u16 *)(pMcsRate)) << 12;
+   switch (ieee->mode) {
+   case IEEE_A:
+   ratr_value &= 0x0FF0;
+   break;
+   case IEEE_B:
+   ratr_value &= 0x000F;
+   break;
+   case IEEE_G:
+   ratr_value &= 0x0FF7;
+   break;
+   case IEEE_N_24G:
+   case IEEE_N_5G:
+   if (ieee->pHTInfo->PeerMimoPs == 0) { /* MIMO_PS_STATIC */
+   ratr_value &= 0x0007F007;
+   } else {
+   if (priv->rf_type == RF_1T2R)
+   ratr_value &= 0x000FF007;
+   else
+   ratr_value &= 0x0F81F007;
+   }
+   break;
+   default:
+   break;
+   }
+   ratr_value &= 0x0FFF;
+   if (ieee->pHTInfo->bCurTxBW40MHz && ieee->pHTInfo->bCurShortGI40MHz)
+   ratr_value |= 0x8000;
+   else if (!ieee->pHTInfo->bCurTxBW40MHz && 
ieee->pHTInfo->bCurShortGI20MHz)
+   ratr_value |= 0x8000;
+   write_nic_dword(dev, RATR0+rate_index*4, ratr_value);
+   write_nic_byte(dev, UFWP, 1);
+}
+
+
 static void rtl8192_link_change(struct net_device *dev)
 {
struct r8192_priv *priv = ieee80211_priv(dev);
@@ -1967,48 +2010,6 @@ static int rtl8192_handle_assoc_response(struct 
net_device *dev,
 }
 
 
-void rtl8192_update_ratr_table(struct net_device *dev)
-{
-   struct r8192_priv *priv = ieee80211_priv(dev);
-   struct ieee80211_device *ieee = priv->ieee80211;
-   u8 *pMcsRate = ieee->dot11HTOperationalRateSet;
-   u32 ratr_value = 0;
-   u8 rate_index = 0;
-   rtl8192_config_rate(dev, (u16 *)(_value));
-   ratr_value |= (*(u16 *)(pMcsRate)) << 12;
-   switch (ieee->mode) {
-   case IEEE_A:
-   ratr_value &= 0x0FF0;
-   break;
-   case IEEE_B:
-   ratr_value &= 0x000F;
-   break;
-   case IEEE_G:
-   ratr_value &= 0x0FF7;
-   break;
-   case IEEE_N_24G:
-   case IEEE_N_5G:
-   if (ieee->pHTInfo->PeerMimoPs == 0) { /* MIMO_PS_STATIC */
-   ratr_value &= 0x0007F007;
-   } else {
-   if (priv->rf_type == RF_1T2R)
-   ratr_value &= 0x000FF007;
-   else
-   ratr_value &= 0x0F81F007;
-   }
-   break;
-   default:
-   break;
-   }
-   ratr_value &= 0x0FFF;
-   if (ieee->pHTInfo->bCurTxBW40MHz && ieee->pHTInfo->bCurShortGI40MHz)
-   ratr_value |= 0x8000;
-   else if (!ieee->pHTInfo->bCurTxBW40MHz && 
ieee->pHTInfo->bCurShortGI20MHz)
-   ratr_value |= 0x8000;
-   write_nic_dword(dev, RATR0+rate_index*4, ratr_value);
-   write_nic_byte(dev, UFWP, 1);
-}
-
 static u8 ccmp_ie[4] = {0x00, 0x50, 0xf2, 0x04};
 static u8 ccmp_rsn_ie[4] = {0x00, 0x0f, 0xac, 0x04};
 static bool GetNmodeSupportBySecCfg8192(struct net_device *dev)
-- 
2.3.4

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


[PATCH V2] Staging: rtl8192 Clean up function definition

2015-03-30 Thread Eddie Kovsky
Change function definition to static, move the function further up in
the file, and delete the function prototype.

This fixes the following warning generated by sparse:

drivers/staging/rtl8192u/r8192U_core.c:1970:6: warning: symbol
'rtl8192_update_ratr_table' was not declared. Should it be static?

Signed-off-by: Eddie Kovsky e...@edkovsky.org
---
 drivers/staging/rtl8192u/r8192U_core.c | 87 +-
 1 file changed, 44 insertions(+), 43 deletions(-)

diff --git a/drivers/staging/rtl8192u/r8192U_core.c 
b/drivers/staging/rtl8192u/r8192U_core.c
index 8834c23d67fc..f16a0a45611f 100644
--- a/drivers/staging/rtl8192u/r8192U_core.c
+++ b/drivers/staging/rtl8192u/r8192U_core.c
@@ -1762,7 +1762,50 @@ void rtl8192_usb_deleteendpoints(struct net_device *dev)
 }
 #endif
 
-static void rtl8192_update_ratr_table(struct net_device *dev);
+static void rtl8192_update_ratr_table(struct net_device *dev)
+{
+   struct r8192_priv *priv = ieee80211_priv(dev);
+   struct ieee80211_device *ieee = priv-ieee80211;
+   u8 *pMcsRate = ieee-dot11HTOperationalRateSet;
+   u32 ratr_value = 0;
+   u8 rate_index = 0;
+   rtl8192_config_rate(dev, (u16 *)(ratr_value));
+
+   ratr_value |= (*(u16 *)(pMcsRate))  12;
+   switch (ieee-mode) {
+   case IEEE_A:
+   ratr_value = 0x0FF0;
+   break;
+   case IEEE_B:
+   ratr_value = 0x000F;
+   break;
+   case IEEE_G:
+   ratr_value = 0x0FF7;
+   break;
+   case IEEE_N_24G:
+   case IEEE_N_5G:
+   if (ieee-pHTInfo-PeerMimoPs == 0) { /* MIMO_PS_STATIC */
+   ratr_value = 0x0007F007;
+   } else {
+   if (priv-rf_type == RF_1T2R)
+   ratr_value = 0x000FF007;
+   else
+   ratr_value = 0x0F81F007;
+   }
+   break;
+   default:
+   break;
+   }
+   ratr_value = 0x0FFF;
+   if (ieee-pHTInfo-bCurTxBW40MHz  ieee-pHTInfo-bCurShortGI40MHz)
+   ratr_value |= 0x8000;
+   else if (!ieee-pHTInfo-bCurTxBW40MHz  
ieee-pHTInfo-bCurShortGI20MHz)
+   ratr_value |= 0x8000;
+   write_nic_dword(dev, RATR0+rate_index*4, ratr_value);
+   write_nic_byte(dev, UFWP, 1);
+}
+
+
 static void rtl8192_link_change(struct net_device *dev)
 {
struct r8192_priv *priv = ieee80211_priv(dev);
@@ -1967,48 +2010,6 @@ static int rtl8192_handle_assoc_response(struct 
net_device *dev,
 }
 
 
-void rtl8192_update_ratr_table(struct net_device *dev)
-{
-   struct r8192_priv *priv = ieee80211_priv(dev);
-   struct ieee80211_device *ieee = priv-ieee80211;
-   u8 *pMcsRate = ieee-dot11HTOperationalRateSet;
-   u32 ratr_value = 0;
-   u8 rate_index = 0;
-   rtl8192_config_rate(dev, (u16 *)(ratr_value));
-   ratr_value |= (*(u16 *)(pMcsRate))  12;
-   switch (ieee-mode) {
-   case IEEE_A:
-   ratr_value = 0x0FF0;
-   break;
-   case IEEE_B:
-   ratr_value = 0x000F;
-   break;
-   case IEEE_G:
-   ratr_value = 0x0FF7;
-   break;
-   case IEEE_N_24G:
-   case IEEE_N_5G:
-   if (ieee-pHTInfo-PeerMimoPs == 0) { /* MIMO_PS_STATIC */
-   ratr_value = 0x0007F007;
-   } else {
-   if (priv-rf_type == RF_1T2R)
-   ratr_value = 0x000FF007;
-   else
-   ratr_value = 0x0F81F007;
-   }
-   break;
-   default:
-   break;
-   }
-   ratr_value = 0x0FFF;
-   if (ieee-pHTInfo-bCurTxBW40MHz  ieee-pHTInfo-bCurShortGI40MHz)
-   ratr_value |= 0x8000;
-   else if (!ieee-pHTInfo-bCurTxBW40MHz  
ieee-pHTInfo-bCurShortGI20MHz)
-   ratr_value |= 0x8000;
-   write_nic_dword(dev, RATR0+rate_index*4, ratr_value);
-   write_nic_byte(dev, UFWP, 1);
-}
-
 static u8 ccmp_ie[4] = {0x00, 0x50, 0xf2, 0x04};
 static u8 ccmp_rsn_ie[4] = {0x00, 0x0f, 0xac, 0x04};
 static bool GetNmodeSupportBySecCfg8192(struct net_device *dev)
-- 
2.3.4

--
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/