aboutsummaryrefslogtreecommitdiff
path: root/drivers/net/wireless/libertas/if_usb.c
diff options
context:
space:
mode:
authorDan Williams <dcbw@redhat.com>2007-08-02 11:14:49 -0400
committerDavid S. Miller <davem@sunset.davemloft.net>2007-10-10 16:49:41 -0700
commit9e22cb67d9a8acde7a5af6ed8cd5e74ebd6551b3 (patch)
treee1a90a7eac6af3fdebdf1ac03fd0d38eedce7059 /drivers/net/wireless/libertas/if_usb.c
parent1e838bf31c3a24596621026c7d1ca69da068af83 (diff)
[PATCH] libertas: remove if_bootcmd.c
Move the only function in it to if_usb.c, which was its only user anyway. Signed-off-by: Dan Williams <dcbw@redhat.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/libertas/if_usb.c')
-rw-r--r--drivers/net/wireless/libertas/if_usb.c24
1 files changed, 24 insertions, 0 deletions
diff --git a/drivers/net/wireless/libertas/if_usb.c b/drivers/net/wireless/libertas/if_usb.c
index 998317571ec..11687b84c59 100644
--- a/drivers/net/wireless/libertas/if_usb.c
+++ b/drivers/net/wireless/libertas/if_usb.c
@@ -803,6 +803,30 @@ static int if_usb_register_dev(wlan_private * priv)
return 0;
}
+/**
+ * @brief This function issues Boot command to the Boot2 code
+ * @param ivalue 1:Boot from FW by USB-Download
+ * 2:Boot from FW in EEPROM
+ * @return 0
+ */
+static int if_usb_issue_boot_command(wlan_private *priv, int ivalue)
+{
+ struct usb_card_rec *cardp = priv->card;
+ struct bootcmdstr sbootcmd;
+ int i;
+
+ /* Prepare command */
+ sbootcmd.u32magicnumber = cpu_to_le32(BOOT_CMD_MAGIC_NUMBER);
+ sbootcmd.u8cmd_tag = ivalue;
+ for (i=0; i<11; i++)
+ sbootcmd.au8dumy[i]=0x00;
+ memcpy(cardp->bulk_out_buffer, &sbootcmd, sizeof(struct bootcmdstr));
+
+ /* Issue command */
+ usb_tx_block(priv, cardp->bulk_out_buffer, sizeof(struct bootcmdstr));
+
+ return 0;
+}
static int if_usb_prog_firmware(wlan_private * priv)