diff options
author | Arnd Bergmann <arnd@arndb.de> | 2010-09-30 04:24:11 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2010-10-05 11:50:15 -0400 |
commit | 9f1c75ac2dba752ad3734bd3ffab805a6a3fbeda (patch) | |
tree | 1cc63c6eaf589234d9dfed67163320e263df5e63 /drivers/staging/bcm/LeakyBucket.c | |
parent | 2a953cfd42c00bab00e792422f7c2064c5f0b410 (diff) |
staging/bcm: fix most build warnings
This removes all warnings I get on a 64 bit build except
for those that look unfixable, where we convert a pointer
to a 32 bit integer and change its byte order!
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/staging/bcm/LeakyBucket.c')
-rw-r--r-- | drivers/staging/bcm/LeakyBucket.c | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/drivers/staging/bcm/LeakyBucket.c b/drivers/staging/bcm/LeakyBucket.c index 1875c828901..b4079384c39 100644 --- a/drivers/staging/bcm/LeakyBucket.c +++ b/drivers/staging/bcm/LeakyBucket.c | |||
@@ -80,9 +80,9 @@ static __inline ULONG GetSFTokenCount(PMINI_ADAPTER Adapter, PacketInfo *psSF) | |||
80 | BCM_DEBUG_PRINT(Adapter,DBG_TYPE_TX, TOKEN_COUNTS, DBG_LVL_ALL, "IsPacketAllowedForFlow ===>"); | 80 | BCM_DEBUG_PRINT(Adapter,DBG_TYPE_TX, TOKEN_COUNTS, DBG_LVL_ALL, "IsPacketAllowedForFlow ===>"); |
81 | /* Validate the parameters */ | 81 | /* Validate the parameters */ |
82 | if(NULL == Adapter || (psSF < Adapter->PackInfo && | 82 | if(NULL == Adapter || (psSF < Adapter->PackInfo && |
83 | (UINT)psSF > (UINT) &Adapter->PackInfo[HiPriority])) | 83 | (uintptr_t)psSF > (uintptr_t) &Adapter->PackInfo[HiPriority])) |
84 | { | 84 | { |
85 | BCM_DEBUG_PRINT(Adapter,DBG_TYPE_TX, TOKEN_COUNTS, DBG_LVL_ALL, "IPAFF: Got wrong Parameters:Adapter: %p, QIndex: %d\n", Adapter, (psSF-Adapter->PackInfo)); | 85 | BCM_DEBUG_PRINT(Adapter,DBG_TYPE_TX, TOKEN_COUNTS, DBG_LVL_ALL, "IPAFF: Got wrong Parameters:Adapter: %p, QIndex: %ld\n", Adapter, (psSF-Adapter->PackInfo)); |
86 | return 0; | 86 | return 0; |
87 | } | 87 | } |
88 | 88 | ||
@@ -94,14 +94,14 @@ static __inline ULONG GetSFTokenCount(PMINI_ADAPTER Adapter, PacketInfo *psSF) | |||
94 | } | 94 | } |
95 | else | 95 | else |
96 | { | 96 | { |
97 | BCM_DEBUG_PRINT(Adapter,DBG_TYPE_TX, TOKEN_COUNTS, DBG_LVL_ALL, "Not enough tokens in queue %d Available %u\n", | 97 | BCM_DEBUG_PRINT(Adapter,DBG_TYPE_TX, TOKEN_COUNTS, DBG_LVL_ALL, "Not enough tokens in queue %ld Available %u\n", |
98 | psSF-Adapter->PackInfo, psSF->uiCurrentTokenCount); | 98 | psSF-Adapter->PackInfo, psSF->uiCurrentTokenCount); |
99 | psSF->uiPendedLast = 1; | 99 | psSF->uiPendedLast = 1; |
100 | } | 100 | } |
101 | } | 101 | } |
102 | else | 102 | else |
103 | { | 103 | { |
104 | BCM_DEBUG_PRINT(Adapter,DBG_TYPE_TX, TOKEN_COUNTS, DBG_LVL_ALL, "IPAFF: Queue %d not valid\n", psSF-Adapter->PackInfo); | 104 | BCM_DEBUG_PRINT(Adapter,DBG_TYPE_TX, TOKEN_COUNTS, DBG_LVL_ALL, "IPAFF: Queue %ld not valid\n", psSF-Adapter->PackInfo); |
105 | } | 105 | } |
106 | BCM_DEBUG_PRINT(Adapter,DBG_TYPE_TX, TOKEN_COUNTS, DBG_LVL_ALL, "IsPacketAllowedForFlow <==="); | 106 | BCM_DEBUG_PRINT(Adapter,DBG_TYPE_TX, TOKEN_COUNTS, DBG_LVL_ALL, "IsPacketAllowedForFlow <==="); |
107 | return 0; | 107 | return 0; |
@@ -113,12 +113,12 @@ static __inline void RemovePacketFromQueue(PacketInfo *pPackInfo , struct sk_buf | |||
113 | psQueueCurrent = pPackInfo->FirstTxQueue; | 113 | psQueueCurrent = pPackInfo->FirstTxQueue; |
114 | while(psQueueCurrent) | 114 | while(psQueueCurrent) |
115 | { | 115 | { |
116 | if((UINT)Packet == (UINT)psQueueCurrent) | 116 | if(Packet == psQueueCurrent) |
117 | { | 117 | { |
118 | if((UINT)psQueueCurrent == (UINT)pPackInfo->FirstTxQueue) | 118 | if(psQueueCurrent == pPackInfo->FirstTxQueue) |
119 | { | 119 | { |
120 | pPackInfo->FirstTxQueue=psQueueCurrent->next; | 120 | pPackInfo->FirstTxQueue=psQueueCurrent->next; |
121 | if((UINT)psQueueCurrent==(UINT)pPackInfo->LastTxQueue) | 121 | if(psQueueCurrent==pPackInfo->LastTxQueue) |
122 | pPackInfo->LastTxQueue=NULL; | 122 | pPackInfo->LastTxQueue=NULL; |
123 | } | 123 | } |
124 | else | 124 | else |
@@ -189,8 +189,8 @@ static __inline VOID CheckAndSendPacketFromIndex | |||
189 | int iPacketLen=0; | 189 | int iPacketLen=0; |
190 | 190 | ||
191 | 191 | ||
192 | BCM_DEBUG_PRINT(Adapter,DBG_TYPE_TX, TX_PACKETS, DBG_LVL_ALL, "%d ====>", (psSF-Adapter->PackInfo)); | 192 | BCM_DEBUG_PRINT(Adapter,DBG_TYPE_TX, TX_PACKETS, DBG_LVL_ALL, "%ld ====>", (psSF-Adapter->PackInfo)); |
193 | if(((UINT)psSF != (UINT)&Adapter->PackInfo[HiPriority]) && Adapter->LinkUpStatus && atomic_read(&psSF->uiPerSFTxResourceCount))//Get data packet | 193 | if((psSF != &Adapter->PackInfo[HiPriority]) && Adapter->LinkUpStatus && atomic_read(&psSF->uiPerSFTxResourceCount))//Get data packet |
194 | { | 194 | { |
195 | if(!psSF->ucDirection ) | 195 | if(!psSF->ucDirection ) |
196 | return; | 196 | return; |
@@ -240,7 +240,7 @@ static __inline VOID CheckAndSendPacketFromIndex | |||
240 | } | 240 | } |
241 | else | 241 | else |
242 | { | 242 | { |
243 | BCM_DEBUG_PRINT(Adapter,DBG_TYPE_TX, TX_PACKETS, DBG_LVL_ALL, "For Queue: %d\n", psSF-Adapter->PackInfo); | 243 | BCM_DEBUG_PRINT(Adapter,DBG_TYPE_TX, TX_PACKETS, DBG_LVL_ALL, "For Queue: %ld\n", psSF-Adapter->PackInfo); |
244 | BCM_DEBUG_PRINT(Adapter,DBG_TYPE_TX, TX_PACKETS, DBG_LVL_ALL, "\nAvailable Tokens = %d required = %d\n", | 244 | BCM_DEBUG_PRINT(Adapter,DBG_TYPE_TX, TX_PACKETS, DBG_LVL_ALL, "\nAvailable Tokens = %d required = %d\n", |
245 | psSF->uiCurrentTokenCount, iPacketLen); | 245 | psSF->uiCurrentTokenCount, iPacketLen); |
246 | //this part indicates that becuase of non-availability of the tokens | 246 | //this part indicates that becuase of non-availability of the tokens |