By implementing a frame counter, print out fewer debug messages (the
firmware may contain hundreds of frames).
Signed-off-by: Nick Dyer <nick.dyer@itdev.co.uk>
Acked-by: Benson Leung <bleung@chromium.org>
Acked-by: Yufeng Shen <miletus@chromium.org>
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
unsigned int frame_size;
unsigned int pos = 0;
unsigned int retry = 0;
unsigned int frame_size;
unsigned int pos = 0;
unsigned int retry = 0;
+ unsigned int frame = 0;
int ret;
ret = request_firmware(&fw, fn, dev);
int ret;
ret = request_firmware(&fw, fn, dev);
} else {
retry = 0;
pos += frame_size;
} else {
retry = 0;
pos += frame_size;
- dev_dbg(dev, "Updated %d bytes / %zd bytes\n", pos, fw->size);
+ if (frame % 50 == 0)
+ dev_dbg(dev, "Sent %d frames, %d/%zd bytes\n",
+ frame, pos, fw->size);
if (ret)
goto disable_irq;
if (ret)
goto disable_irq;
+ dev_dbg(dev, "Sent %d frames, %d bytes\n", frame, pos);
+
/*
* Wait for device to reset. Some bootloader versions do not assert
* the CHG line after bootloading has finished, so ignore potential
/*
* Wait for device to reset. Some bootloader versions do not assert
* the CHG line after bootloading has finished, so ignore potential