core/uclass: Print name of device in uclass_find_device_by_seq()
authorAlexandru Gagniuc <alex.g@adaptrum.com>
Tue, 4 Apr 2017 17:46:56 +0000 (10:46 -0700)
committerSimon Glass <sjg@chromium.org>
Thu, 13 Apr 2017 20:44:49 +0000 (14:44 -0600)
uclass_find_device_by_seq() prints seq and req_seq when debugging is
enabled, but this information is not very useful by itself. Add the
name of he driver to this information. This improves debugging as it
shows which devices are being considered.

Signed-off-by: Alexandru Gagniuc <alex.g@adaptrum.com>
Acked-by: Simon Glass <sjg@chromium.org>
drivers/core/uclass.c

index d94d43a98d2f8619d6a803029ee2e162fa1d1b24..04fb45b01a54b4d8f014bc4b15238ea5387eb43c 100644 (file)
@@ -250,7 +250,7 @@ int uclass_find_device_by_seq(enum uclass_id id, int seq_or_req_seq,
                return ret;
 
        list_for_each_entry(dev, &uc->dev_head, uclass_node) {
-               debug("   - %d %d\n", dev->req_seq, dev->seq);
+               debug("   - %d %d '%s'\n", dev->req_seq, dev->seq, dev->name);
                if ((find_req_seq ? dev->req_seq : dev->seq) ==
                                seq_or_req_seq) {
                        *devp = dev;