|
@@ -273,7 +273,6 @@ int hdmi_pll_init(struct platform_device *pdev, struct hdmi_pll_data *pll)
|
|
|
{
|
|
|
int r;
|
|
|
struct resource *res;
|
|
|
- struct resource temp_res;
|
|
|
|
|
|
r = hdmi_pll_init_features(pdev);
|
|
|
if (r)
|
|
@@ -281,25 +280,11 @@ int hdmi_pll_init(struct platform_device *pdev, struct hdmi_pll_data *pll)
|
|
|
|
|
|
res = platform_get_resource_byname(pdev, IORESOURCE_MEM, "pll");
|
|
|
if (!res) {
|
|
|
- DSSDBG("can't get PLL mem resource by name\n");
|
|
|
- /*
|
|
|
- * if hwmod/DT doesn't have the memory resource information
|
|
|
- * split into HDMI sub blocks by name, we try again by getting
|
|
|
- * the platform's first resource. this code will be removed when
|
|
|
- * the driver can get the mem resources by name
|
|
|
- */
|
|
|
- res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
|
|
|
- if (!res) {
|
|
|
- DSSERR("can't get PLL mem resource\n");
|
|
|
- return -EINVAL;
|
|
|
- }
|
|
|
-
|
|
|
- temp_res.start = res->start + PLL_OFFSET;
|
|
|
- temp_res.end = temp_res.start + PLL_SIZE - 1;
|
|
|
- res = &temp_res;
|
|
|
+ DSSERR("can't get PLL mem resource\n");
|
|
|
+ return -EINVAL;
|
|
|
}
|
|
|
|
|
|
- pll->base = devm_ioremap(&pdev->dev, res->start, resource_size(res));
|
|
|
+ pll->base = devm_ioremap_resource(&pdev->dev, res);
|
|
|
if (!pll->base) {
|
|
|
DSSERR("can't ioremap PLLCTRL\n");
|
|
|
return -ENOMEM;
|