Skip to content

Commit

Permalink
drivers: rtc: Change error to ENODATA in get time function
Browse files Browse the repository at this point in the history
- Change the error type from ECANCELED to ENODATA

Signed-off-by: Daniel Kampert <DanielKampert@kampis-elektroecke.de>
  • Loading branch information
Kampi authored and nashif committed Aug 2, 2024
1 parent 791ba98 commit 3bf35ce
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/rtc/rtc_rv8263.c
Original file line number Diff line number Diff line change
Expand Up @@ -264,7 +264,7 @@ static int rv8263c8_time_get(const struct device *dev, struct rtc_time *timeptr)

/* Return an error when the oscillator is stopped. */
if (regs[0] & RV8263_BM_OS) {
return -ECANCELED;
return -ENODATA;
}

timeptr->tm_sec = bcd2bin(regs[0] & SECONDS_BITS);
Expand Down

0 comments on commit 3bf35ce

Please sign in to comment.