APPLIED: [SRU][J:linux-bluefield][PATCH 0/1] UBUNTU: SAUCE: mlxbf-bootctl supports RTC battery status read and clear
Bartlomiej Zolnierkiewicz
bartlomiej.zolnierkiewicz at canonical.com
Mon Sep 23 13:44:02 UTC 2024
Applied to jammy:linux-bluefield/master-next. Thanks.
--
Best regards,
Bartlomiej
On Fri, Sep 6, 2024 at 1:31 AM Ron Li <xiangrongl at nvidia.com> wrote:
>
> BugLink: https://bugs.launchpad.net/bugs/2078881
>
> SRU Justification:
>
> [Impact]
>
> The RTC battery status is not directly accessible from the kernel user space. The recent Nvidia UEFI added SMC to report the RTC battery status and clear the status bit if needed.
>
> [Fix]
>
> * Added an rtc_battery entry in the bootctl driver.
> * Read the rtc_battery entry will trigger an SMC call to read the RTC battery status.
>
> [Test Case]
>
> * Check if the bootctl driver is loaded.
> * Check the rtc_battery entry:
> cat /sys/bus/platform/drivers/mlxbf-bootctl/rtc_battery
> A value of 0x0 means RTC battery voltage is good.
> A value of 0x80 means RTC battery voltage is low. The status bit is also cleared after the read.
> An error code will be return if this feature is missing from UEFI.
>
> [Other]
> * This code is likely to change depending on feedback we received from maintainers.
>
>
> Ron Li (1):
> UBUNTU: SAUCE: mlxbf-bootctl supports RTC battery status read and
> clear
>
> drivers/platform/mellanox/mlxbf-bootctl.c | 20 ++++++++++++++++++++
> drivers/platform/mellanox/mlxbf-bootctl.h | 5 +++++
> 2 files changed, 25 insertions(+)
>
More information about the kernel-team
mailing list