mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-30 11:41:38 -04:00
thermal: Convert to devm_ioremap_resource()
Convert all uses of devm_request_and_ioremap() to the newly introduced devm_ioremap_resource() which provides more consistent error handling. devm_ioremap_resource() provides its own error messages so all explicit error messages can be removed from the failure code paths. Signed-off-by: Thierry Reding <[email protected]> Cc: Zhang Rui <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
This commit is contained in:
parent
b0ee560523
commit
ca36b1ba8c
1 changed files with 3 additions and 5 deletions
|
|
@ -866,11 +866,9 @@ static int exynos_tmu_probe(struct platform_device *pdev)
|
|||
return -ENOENT;
|
||||
}
|
||||
|
||||
data->base = devm_request_and_ioremap(&pdev->dev, data->mem);
|
||||
if (!data->base) {
|
||||
dev_err(&pdev->dev, "Failed to ioremap memory\n");
|
||||
return -ENODEV;
|
||||
}
|
||||
data->base = devm_ioremap_resource(&pdev->dev, data->mem);
|
||||
if (IS_ERR(data->base))
|
||||
return PTR_ERR(data->base);
|
||||
|
||||
ret = devm_request_irq(&pdev->dev, data->irq, exynos_tmu_irq,
|
||||
IRQF_TRIGGER_RISING, "exynos-tmu", data);
|
||||
|
|
|
|||
Loading…
Reference in a new issue