Skip to content
Snippets Groups Projects
Commit dda48e8e authored by ramneek mehresh's avatar ramneek mehresh Committed by Marek Vasut
Browse files

powerpc/usb: Fix usb device-tree fix-up


Fix USB device-tree fixup to properly handle device-tree fixup and
print appropriate message when wrong/junk "dr_mode" or "phy_type"
are mentioned in hwconfig string

Signed-off-by: default avatarRamneek Mehresh <ramneek.mehresh@freescale.com>
parent ef4e9fc6
No related branches found
No related tags found
No related merge requests found
...@@ -167,6 +167,11 @@ void fdt_fixup_dr_usb(void *blob, bd_t *bd) ...@@ -167,6 +167,11 @@ void fdt_fixup_dr_usb(void *blob, bd_t *bd)
} }
} }
if (mode_idx < 0 || phy_idx < 0) {
puts("ERROR: wrong usb mode/phy defined!!\n");
return;
}
dr_mode_type = modes[mode_idx]; dr_mode_type = modes[mode_idx];
dr_phy_type = phys[phy_idx]; dr_phy_type = phys[phy_idx];
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment