diff mbox

[2/8] musb: Get power (mA) from board data

Message ID 1258470596-24321-3-git-send-email-ajay.gupta@ti.com (mailing list archive)
State Changes Requested
Headers show

Commit Message

Ajay Kumar Gupta Nov. 17, 2009, 3:09 p.m. UTC
None
diff mbox

Patch

diff --git a/drivers/usb/musb/musb_core.c b/drivers/usb/musb/musb_core.c
index 3a61ddb..818ccda 100644
--- a/drivers/usb/musb/musb_core.c
+++ b/drivers/usb/musb/musb_core.c
@@ -2033,7 +2033,9 @@  bad_config:
 		if (is_otg_enabled(musb))
 			hcd->self.otg_port = 1;
 		musb->xceiv->host = &hcd->self;
-		hcd->power_budget = 2 * (plat->power ? : 250);
+		if (plat->board_data)
+			hcd->power_budget =
+				2 * (plat->board_data->power ? : 250);
 	}
 
 	/* For the host-only role, we can activate right away.