libertas: use priv->upld_buf for command responses

If we don't scribble over the command we sent, then we can retry it when
the firmware responds with 0x0004 (which means -EAGAIN).

Signed-off-by: David Woodhouse <dwmw2@infradead.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
This commit is contained in:
David Woodhouse
2007-12-17 15:22:43 -05:00
committed by David S. Miller
parent ac4cced6e8
commit 7003b078c8
4 changed files with 4 additions and 30 deletions

View File

@@ -136,12 +136,6 @@ static int if_sdio_handle_cmd(struct if_sdio_card *card,
spin_lock_irqsave(&card->priv->driver_lock, flags);
if (!card->priv->cur_cmd) {
lbs_deb_sdio("discarding spurious response\n");
ret = 0;
goto out;
}
if (size > LBS_CMD_BUFFER_SIZE) {
lbs_deb_sdio("response packet too large (%d bytes)\n",
(int)size);
@@ -149,7 +143,7 @@ static int if_sdio_handle_cmd(struct if_sdio_card *card,
goto out;
}
memcpy(card->priv->cur_cmd->cmdbuf, buffer, size);
memcpy(card->priv->upld_buf, buffer, size);
card->priv->upld_len = size;
card->int_cause |= MRVDRV_CMD_UPLD_RDY;