Revert "ACPI: PMIC: Remove unneeded check in tps68470_pmic_opregion_probe()"

This reverts commit d0bcd36ebb.
This commit is contained in:
Ksawlii 2024-11-24 00:23:31 +01:00
parent f45a13db54
commit cbe050461f

View file

@ -376,8 +376,10 @@ static int tps68470_pmic_opregion_probe(struct platform_device *pdev)
struct tps68470_pmic_opregion *opregion;
acpi_status status;
if (!tps68470_regmap)
return dev_err_probe(dev, -EINVAL, "regmap is missing\n");
if (!dev || !tps68470_regmap) {
dev_warn(dev, "dev or regmap is NULL\n");
return -EINVAL;
}
if (!handle) {
dev_warn(dev, "acpi handle is NULL\n");