Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 361250
b: refs/heads/master
c: 57ae575
h: refs/heads/master
v: v3
  • Loading branch information
Sachin Kamat authored and Felipe Balbi committed Mar 4, 2013
1 parent bb60b3a commit 707deb7
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 16 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 862421da0d82a3c35aa89e040a533f76d24c62c4
refs/heads/master: 57ae575b8a51fd98c9b0066c6c030d5ccce3d77d
24 changes: 9 additions & 15 deletions trunk/drivers/usb/phy/omap-control-usb.c
Original file line number Diff line number Diff line change
Expand Up @@ -219,32 +219,26 @@ static int omap_control_usb_probe(struct platform_device *pdev)

res = platform_get_resource_byname(pdev, IORESOURCE_MEM,
"control_dev_conf");
control_usb->dev_conf = devm_request_and_ioremap(&pdev->dev, res);
if (!control_usb->dev_conf) {
dev_err(&pdev->dev, "Failed to obtain io memory\n");
return -EADDRNOTAVAIL;
}
control_usb->dev_conf = devm_ioremap_resource(&pdev->dev, res);
if (IS_ERR(control_usb->dev_conf))
return PTR_ERR(control_usb->dev_conf);

if (control_usb->type == OMAP_CTRL_DEV_TYPE1) {
res = platform_get_resource_byname(pdev, IORESOURCE_MEM,
"otghs_control");
control_usb->otghs_control = devm_request_and_ioremap(
control_usb->otghs_control = devm_ioremap_resource(
&pdev->dev, res);
if (!control_usb->otghs_control) {
dev_err(&pdev->dev, "Failed to obtain io memory\n");
return -EADDRNOTAVAIL;
}
if (IS_ERR(control_usb->otghs_control))
return PTR_ERR(control_usb->otghs_control);
}

if (control_usb->type == OMAP_CTRL_DEV_TYPE2) {
res = platform_get_resource_byname(pdev, IORESOURCE_MEM,
"phy_power_usb");
control_usb->phy_power = devm_request_and_ioremap(
control_usb->phy_power = devm_ioremap_resource(
&pdev->dev, res);
if (!control_usb->phy_power) {
dev_dbg(&pdev->dev, "Failed to obtain io memory\n");
return -EADDRNOTAVAIL;
}
if (IS_ERR(control_usb->phy_power))
return PTR_ERR(control_usb->phy_power);

control_usb->sys_clk = devm_clk_get(control_usb->dev,
"sys_clkin");
Expand Down

0 comments on commit 707deb7

Please sign in to comment.