Commit d16791bf authored by Chaehyun Lim's avatar Chaehyun Lim Committed by Greg Kroah-Hartman

staging: wilc1000: rename struct __Message_struct

This patch renames typedef from struct __Message_struct and renames it
to struct message.
Signed-off-by: default avatarChaehyun Lim <chaehyun.lim@gmail.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent eec82643
...@@ -38,7 +38,7 @@ int wilc_mq_destroy(WILC_MsgQueueHandle *pHandle) ...@@ -38,7 +38,7 @@ int wilc_mq_destroy(WILC_MsgQueueHandle *pHandle)
} }
while (pHandle->pstrMessageList) { while (pHandle->pstrMessageList) {
Message *pstrMessge = pHandle->pstrMessageList->pstrNext; struct message *pstrMessge = pHandle->pstrMessageList->pstrNext;
kfree(pHandle->pstrMessageList); kfree(pHandle->pstrMessageList);
pHandle->pstrMessageList = pstrMessge; pHandle->pstrMessageList = pstrMessge;
...@@ -57,7 +57,7 @@ int wilc_mq_send(WILC_MsgQueueHandle *pHandle, ...@@ -57,7 +57,7 @@ int wilc_mq_send(WILC_MsgQueueHandle *pHandle,
const void *pvSendBuffer, u32 u32SendBufferSize) const void *pvSendBuffer, u32 u32SendBufferSize)
{ {
unsigned long flags; unsigned long flags;
Message *pstrMessage = NULL; struct message *pstrMessage = NULL;
if ((!pHandle) || (u32SendBufferSize == 0) || (!pvSendBuffer)) { if ((!pHandle) || (u32SendBufferSize == 0) || (!pvSendBuffer)) {
PRINT_ER("pHandle or pvSendBuffer is null\n"); PRINT_ER("pHandle or pvSendBuffer is null\n");
...@@ -70,7 +70,7 @@ int wilc_mq_send(WILC_MsgQueueHandle *pHandle, ...@@ -70,7 +70,7 @@ int wilc_mq_send(WILC_MsgQueueHandle *pHandle,
} }
/* construct a new message */ /* construct a new message */
pstrMessage = kmalloc(sizeof(Message), GFP_ATOMIC); pstrMessage = kmalloc(sizeof(struct message), GFP_ATOMIC);
if (!pstrMessage) if (!pstrMessage)
return -ENOMEM; return -ENOMEM;
...@@ -89,7 +89,7 @@ int wilc_mq_send(WILC_MsgQueueHandle *pHandle, ...@@ -89,7 +89,7 @@ int wilc_mq_send(WILC_MsgQueueHandle *pHandle,
if (!pHandle->pstrMessageList) { if (!pHandle->pstrMessageList) {
pHandle->pstrMessageList = pstrMessage; pHandle->pstrMessageList = pstrMessage;
} else { } else {
Message *pstrTailMsg = pHandle->pstrMessageList; struct message *pstrTailMsg = pHandle->pstrMessageList;
while (pstrTailMsg->pstrNext) while (pstrTailMsg->pstrNext)
pstrTailMsg = pstrTailMsg->pstrNext; pstrTailMsg = pstrTailMsg->pstrNext;
...@@ -114,7 +114,7 @@ int wilc_mq_recv(WILC_MsgQueueHandle *pHandle, ...@@ -114,7 +114,7 @@ int wilc_mq_recv(WILC_MsgQueueHandle *pHandle,
void *pvRecvBuffer, u32 u32RecvBufferSize, void *pvRecvBuffer, u32 u32RecvBufferSize,
u32 *pu32ReceivedLength) u32 *pu32ReceivedLength)
{ {
Message *pstrMessage; struct message *pstrMessage;
unsigned long flags; unsigned long flags;
if ((!pHandle) || (u32RecvBufferSize == 0) if ((!pHandle) || (u32RecvBufferSize == 0)
......
...@@ -13,18 +13,18 @@ ...@@ -13,18 +13,18 @@
#include <linux/semaphore.h> #include <linux/semaphore.h>
/* Message Queue type is a structure */ /* Message Queue type is a structure */
typedef struct __Message_struct { struct message {
void *pvBuffer; void *pvBuffer;
u32 u32Length; u32 u32Length;
struct __Message_struct *pstrNext; struct message *pstrNext;
} Message; };
typedef struct __MessageQueue_struct { typedef struct __MessageQueue_struct {
struct semaphore hSem; struct semaphore hSem;
spinlock_t strCriticalSection; spinlock_t strCriticalSection;
bool bExiting; bool bExiting;
u32 u32ReceiversCount; u32 u32ReceiversCount;
Message *pstrMessageList; struct message *pstrMessageList;
} WILC_MsgQueueHandle; } WILC_MsgQueueHandle;
/*! /*!
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment