Skip to content

Commit 0b6da78

Browse files
Dan Carpenteralexandrebelloni
authored andcommitted
rtc: rzn1: Fix error code in probe
There is a copy and paste error so this code returns the wrong variable. Fixes: deeb4b5 ("rtc: rzn1: Add new RTC driver") Signed-off-by: Dan Carpenter <[email protected]> Reviewed-by: Miquel Raynal <[email protected]> Signed-off-by: Alexandre Belloni <[email protected]> Link: https://lore.kernel.org/r/YoZMg1dmHHSJEfE9@kili
1 parent 64d69b5 commit 0b6da78

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/rtc/rtc-rzn1.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -348,7 +348,7 @@ static int rzn1_rtc_probe(struct platform_device *pdev)
348348

349349
rtc->rtcdev = devm_rtc_allocate_device(&pdev->dev);
350350
if (IS_ERR(rtc->rtcdev))
351-
return PTR_ERR(rtc);
351+
return PTR_ERR(rtc->rtcdev);
352352

353353
rtc->rtcdev->range_min = RTC_TIMESTAMP_BEGIN_2000;
354354
rtc->rtcdev->range_max = RTC_TIMESTAMP_END_2099;

0 commit comments

Comments
 (0)