Skip to content

Commit ff5d40a

Browse files
chandra-gorentlagregkh
authored andcommitted
staging: wilc1000: Remove 'if' statement, which is always false
- 'if' which is always false is removed - variable associated with this 'if' is deleted Signed-off-by: Chandra S Gorentla <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
1 parent cc28e4b commit ff5d40a

File tree

1 file changed

+1
-8
lines changed

1 file changed

+1
-8
lines changed

drivers/staging/wilc1000/wilc_msgqueue.c

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -115,7 +115,6 @@ int wilc_mq_recv(WILC_MsgQueueHandle *pHandle,
115115
u32 *pu32ReceivedLength)
116116
{
117117
Message *pstrMessage;
118-
int result = 0;
119118
unsigned long flags;
120119

121120
if ((!pHandle) || (u32RecvBufferSize == 0)
@@ -135,12 +134,6 @@ int wilc_mq_recv(WILC_MsgQueueHandle *pHandle,
135134

136135
down(&pHandle->hSem);
137136

138-
/* other non-timeout scenarios */
139-
if (result) {
140-
PRINT_ER("Non-timeout\n");
141-
return result;
142-
}
143-
144137
if (pHandle->bExiting) {
145138
PRINT_ER("pHandle fail\n");
146139
return -EFAULT;
@@ -174,5 +167,5 @@ int wilc_mq_recv(WILC_MsgQueueHandle *pHandle,
174167

175168
spin_unlock_irqrestore(&pHandle->strCriticalSection, flags);
176169

177-
return result;
170+
return 0;
178171
}

0 commit comments

Comments
 (0)