@@ -784,7 +784,6 @@ static int qcom_swrm_probe(struct platfo
struct sdw_master_prop *prop;
struct sdw_bus_params *params;
struct qcom_swrm_ctrl *ctrl;
- struct resource *res;
int ret;
u32 val;
@@ -801,8 +800,7 @@ static int qcom_swrm_probe(struct platfo
} else {
ctrl->reg_read = qcom_swrm_mmio_reg_read;
ctrl->reg_write = qcom_swrm_mmio_reg_write;
- res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
- ctrl->base = devm_ioremap_resource(dev, res);
+ ctrl->base = devm_platform_ioremap_resource(pdev, 0);
if (IS_ERR(ctrl->base))
return PTR_ERR(ctrl->base);
}