From mboxrd@z Thu Jan 1 00:00:00 1970 From: Neil Bryan Date: 06 Jul 2005 10:27:17 +0200 Subject: [U-Boot-Users] Statuc code format for USB response... Message-ID: <1120638436.6064.32.camel@daroca> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de This is a trivial comment, but helpful for developers not expert in debugging USB-related problems. After issuing the following command: U-Boot> usb reset I obtained the following result: USB device not responding, giving up (status=20) The code responsible for this is in ./common/usb.c and shown below: printf("\n USB device not responding, giving up (status=%lX)\n",dev->status); I _believe_ the status code returned is that defined in ./include/usb_defs.h and that my status code of 20 is the value defined by the macro USB_ST_CRC_ERR. The printf uses a %lX format specifier and it would be improved if it was proceeded with an '0x' to inform the developer (me) that this is indeed a hexadecimal value. My suggested change is In ./common/usb.c -------------- - printf("\n USB device not responding, giving up (status=%lX)\n",dev->status) + printf("\n USB device not responding, giving up (status=0x%lX)\n",dev->status) -------------- As I said, I know this is trivial, but every little bit of extra information helps when debugging something that is unfamiliar. Flames and other comments gratefully received! Regards, Neil Bryan.