From: Simon Arlott <simon@fire.lp0.eu>
To: Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
Greg Kroah-Hartman <gregkh@suse.de>
Subject: [PATCH 5/8] cxacru: firmware writes on OHCI are slow, log progress
Date: Sat, 21 Nov 2009 15:12:56 +0000 [thread overview]
Message-ID: <4B080378.20903@simon.arlott.org.uk> (raw)
In-Reply-To: <4B08013B.90403@simon.arlott.org.uk>
Firmware writing takes 256ms per 4KB with OHCI, which
is very slow compared to 7ms per 4KB with UHCI.
Until I have access to a hardware USB analyser it may
not be possible to determine why this happens.
Instead of appearing to do nothing, log progress when
writing firmware and then log the ATM device information
when finished. Remove an unnecessary 4 second delay.
Signed-off-by: Simon Arlott <simon@fire.lp0.eu>
---
drivers/usb/atm/cxacru.c | 8 ++++++--
1 files changed, 6 insertions(+), 2 deletions(-)
diff --git a/drivers/usb/atm/cxacru.c b/drivers/usb/atm/cxacru.c
index 41568b1..c6ec10e 100644
--- a/drivers/usb/atm/cxacru.c
+++ b/drivers/usb/atm/cxacru.c
@@ -724,6 +724,9 @@ static int cxacru_atm_start(struct usbatm_data *usbatm_instance,
mutex_unlock(&instance->poll_state_serialize);
mutex_unlock(&instance->adsl_state_serialize);
+ printk(KERN_INFO "%s%d: %s %pM\n", atm_dev->type, atm_dev->number,
+ usbatm_instance->description, atm_dev->esi);
+
if (start_polling)
cxacru_poll_status(&instance->poll_work.work);
return 0;
@@ -938,6 +941,7 @@ static void cxacru_upload_firmware(struct cxacru_data *instance,
}
/* Firmware */
+ usb_info(usbatm, "loading firmware\n");
ret = cxacru_fw(usb_dev, FW_WRITE_MEM, 0x2, 0x0, FW_ADDR, fw->data, fw->size);
if (ret) {
usb_err(usbatm, "Firmware upload failed: %d\n", ret);
@@ -946,6 +950,7 @@ static void cxacru_upload_firmware(struct cxacru_data *instance,
/* Boot ROM patch */
if (instance->modem_type->boot_rom_patch) {
+ usb_info(usbatm, "loading boot ROM patch\n");
ret = cxacru_fw(usb_dev, FW_WRITE_MEM, 0x2, 0x0, BR_ADDR, bp->data, bp->size);
if (ret) {
usb_err(usbatm, "Boot ROM patching failed: %d\n", ret);
@@ -960,6 +965,7 @@ static void cxacru_upload_firmware(struct cxacru_data *instance,
return;
}
+ usb_info(usbatm, "starting device\n");
if (instance->modem_type->boot_rom_patch) {
val = cpu_to_le32(BR_ADDR);
ret = cxacru_fw(usb_dev, FW_WRITE_MEM, 0x2, 0x0, BR_STACK_ADDR, (u8 *) &val, 4);
@@ -1003,8 +1009,6 @@ static void cxacru_upload_firmware(struct cxacru_data *instance,
return;
}
}
-
- msleep_interruptible(4000);
}
static int cxacru_find_firmware(struct cxacru_data *instance,
--
1.6.3.3
--
Simon Arlott
next prev parent reply other threads:[~2009-11-21 15:26 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-11-21 15:03 [PATCH 1/8] cxacru: return an empty value for modulation if there is no connection Simon Arlott
2009-11-21 15:07 ` [PATCH 2/8] cxacru: check data length is not negative Simon Arlott
2009-11-21 15:12 ` [PATCH 3/8] cxacru: check device isn't being removed during sysfs calls Simon Arlott
2009-11-21 15:24 ` Duncan Sands
2009-11-21 15:29 ` Simon Arlott
2009-11-21 15:33 ` [PATCH 3/8 (v2)] " Simon Arlott
2009-11-21 15:12 ` [PATCH 4/8] cxacru: document how to interact with the flash memory Simon Arlott
2009-11-21 15:12 ` Simon Arlott [this message]
2009-11-21 15:14 ` [PATCH 6/8] cxacru: add write-only sysfs attribute for modem configuration Simon Arlott
2009-11-21 15:15 ` [PATCH 7/8] cxacru: remove cxacru-cf.bin loader Simon Arlott
2009-11-21 15:16 ` [PATCH 8/8] cxacru: increment driver version Simon Arlott
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4B080378.20903@simon.arlott.org.uk \
--to=simon@fire.lp0.eu \
--cc=gregkh@suse.de \
--cc=linux-kernel@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.