Commit b595f9b8 authored by Malcolm Priestley's avatar Malcolm Priestley Committed by Greg Kroah-Hartman

staging: vt6656: remove typedef struct tagCMD_ITEM

Since enum vnt_cmd is only member replace with array
enum vnt_cmd cmd_queue with size of CMD_Q_SIZE
Signed-off-by: default avatarMalcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent ad74e91d
...@@ -406,7 +406,7 @@ struct vnt_private { ...@@ -406,7 +406,7 @@ struct vnt_private {
/* 802.11 counter */ /* 802.11 counter */
CMD_ITEM eCmdQueue[CMD_Q_SIZE]; enum vnt_cmd cmd_queue[CMD_Q_SIZE];
u32 uCmdDequeueIdx; u32 uCmdDequeueIdx;
u32 uCmdEnqueueIdx; u32 uCmdEnqueueIdx;
u32 cbFreeCmdQueue; u32 cbFreeCmdQueue;
......
...@@ -146,7 +146,7 @@ static int s_bCommandComplete(struct vnt_private *priv) ...@@ -146,7 +146,7 @@ static int s_bCommandComplete(struct vnt_private *priv)
return true; return true;
} }
priv->command = priv->eCmdQueue[priv->uCmdDequeueIdx].cmd; priv->command = priv->cmd_queue[priv->uCmdDequeueIdx];
ADD_ONE_WITH_WRAP_AROUND(priv->uCmdDequeueIdx, CMD_Q_SIZE); ADD_ONE_WITH_WRAP_AROUND(priv->uCmdDequeueIdx, CMD_Q_SIZE);
priv->cbFreeCmdQueue++; priv->cbFreeCmdQueue++;
...@@ -192,7 +192,7 @@ int bScheduleCommand(struct vnt_private *priv, enum vnt_cmd command, u8 *item0) ...@@ -192,7 +192,7 @@ int bScheduleCommand(struct vnt_private *priv, enum vnt_cmd command, u8 *item0)
if (priv->cbFreeCmdQueue == 0) if (priv->cbFreeCmdQueue == 0)
return false; return false;
priv->eCmdQueue[priv->uCmdEnqueueIdx].cmd = command; priv->cmd_queue[priv->uCmdEnqueueIdx] = command;
ADD_ONE_WITH_WRAP_AROUND(priv->uCmdEnqueueIdx, CMD_Q_SIZE); ADD_ONE_WITH_WRAP_AROUND(priv->uCmdEnqueueIdx, CMD_Q_SIZE);
priv->cbFreeCmdQueue--; priv->cbFreeCmdQueue--;
......
...@@ -56,10 +56,6 @@ typedef enum tagCMD_STATUS { ...@@ -56,10 +56,6 @@ typedef enum tagCMD_STATUS {
} CMD_STATUS, *PCMD_STATUS; } CMD_STATUS, *PCMD_STATUS;
typedef struct tagCMD_ITEM {
enum vnt_cmd cmd;
} CMD_ITEM, *PCMD_ITEM;
/* Command state */ /* Command state */
enum vnt_cmd_state { enum vnt_cmd_state {
WLAN_CMD_INIT_MAC80211_START, WLAN_CMD_INIT_MAC80211_START,
......
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