Add BMCWatchdog base class to be used in SONiC BMC#702
Open
chander-nexthop wants to merge 1 commit into
Open
Conversation
BMCWatchdog implements the Linux watchdog API as an IPC client to the hw-watchdog-mgrd daemon (the sole owner of /dev/watchdog0), with a read-only sysfs fallback for is_armed() when the daemon is unreachable. socket and sysfs paths are configurable via the constructor. Includes unit tests. Signed-off-by: Chandrasekaran Swaminathan <chander@nexthop.ai>
Collaborator
|
/azp run |
|
Azure Pipelines successfully started running 1 pipeline(s). |
8 tasks
Collaborator
|
Hi, there are workflow run(s) waiting for approval, you may be first-time contributor. I will notify maintainers to help approve once PR is approved. Thanks! ---Powered by SONiC BuildBot
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
in SONiC BMC, the watchdog service would be modeled along the classic linux watchdog daemon model, where one daemon would be the owner of /dev/watchdog0. However watchdog util expects the watchdog class to implement the SONiC watchdog API's like arm/disarm etc. So create a BMCWatchdog that implements all these API's as IPC calls to the daemon.
Description
BMCWatchdog implements the Linux watchdog API as an IPC client to the hw-watchdog-mgrd daemon (the sole owner of /dev/watchdog0), with a read-only sysfs fallback for is_armed() when the daemon is unreachable. socket and sysfs paths are configurable via the constructor. Includes unit tests.
Motivation and Context
By having the BMCWatchdog, all vendors that have their BMC based on aspeed 2720 SoC will instantiate this class within their Chassis object. The watchdog daemon is already part of the aspeed SONiC image.
How Has This Been Tested?
Unit tests have been added.
Additional Information (Optional)
Refer to sonic-net/sonic-buildimage#27776 for the discussions.