firehose: Remove unnecessary nop request

The nop was added to mitigate the fact that there's a rather long delay
in the response when sending out the first command. Increasing the write
timeout removes this problem and it's possible to just send the
configure as the first command without issues.

Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org>
This commit is contained in:
Bjorn Andersson
2019-01-07 21:00:42 -08:00
parent 5ea1e20c01
commit 59717efcd4
2 changed files with 1 additions and 8 deletions

View File

@@ -593,15 +593,8 @@ int firehose_run(struct qdl_device *qdl, const char *incdir, const char *storage
int bootable;
int ret;
// while (firehose_read(qdl, 100, NULL) != -ETIMEDOUT)
// ;
firehose_read(qdl, 5000, NULL);
ret = firehose_nop(qdl);
if (ret)
return ret;
if(ufs_need_provisioning()) {
ret = firehose_configure(qdl, true, storage);
if (ret)

2
qdl.c
View File

@@ -320,7 +320,7 @@ int qdl_write(struct qdl_device *qdl, const void *buf, size_t len, bool eot)
bulk.ep = qdl->out_ep;
bulk.len = len;
bulk.data = (void *)buf;
bulk.timeout = 1000;
bulk.timeout = 10000;
ret = ioctl(qdl->fd, USBDEVFS_BULK, &bulk);
if (ret < 0)