summaryrefslogtreecommitdiff
path: root/drivers/power
diff options
context:
space:
mode:
authorChris Packham <chris.packham@alliedtelesis.co.nz>2024-10-16 11:59:44 +1300
committerSebastian Reichel <sebastian.reichel@collabora.com>2024-10-16 22:26:20 +0200
commitce38cdc908557953604ffb0a91ef5ae3fbdf1c6b (patch)
treedb4955e26776a370cd46b40d423259d54cec449b /drivers/power
parente7af7d13316dc5e2293c4f777f71bd8331f5d7a5 (diff)
downloadlwn-ce38cdc908557953604ffb0a91ef5ae3fbdf1c6b.tar.gz
lwn-ce38cdc908557953604ffb0a91ef5ae3fbdf1c6b.zip
power: reset: syscon-reboot: Accept reg property
For historical reasons syscon-reboot has used an 'offset' property. As a child on a MMIO bus having a 'reg' property is more appropriate. Accept 'reg' as an alternative to 'offset'. Signed-off-by: Chris Packham <chris.packham@alliedtelesis.co.nz> Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> Link: https://lore.kernel.org/r/20241015225948.3971924-3-chris.packham@alliedtelesis.co.nz Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
Diffstat (limited to 'drivers/power')
-rw-r--r--drivers/power/reset/syscon-reboot.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/power/reset/syscon-reboot.c b/drivers/power/reset/syscon-reboot.c
index 4d622c19bc48..d623d77e657e 100644
--- a/drivers/power/reset/syscon-reboot.c
+++ b/drivers/power/reset/syscon-reboot.c
@@ -61,7 +61,8 @@ static int syscon_reboot_probe(struct platform_device *pdev)
priority = 192;
if (of_property_read_u32(pdev->dev.of_node, "offset", &ctx->offset))
- return -EINVAL;
+ if (of_property_read_u32(pdev->dev.of_node, "reg", &ctx->offset))
+ return -EINVAL;
value_err = of_property_read_u32(pdev->dev.of_node, "value", &ctx->value);
mask_err = of_property_read_u32(pdev->dev.of_node, "mask", &ctx->mask);