Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added new Platform APIs and modified APIs for supporting reboot on a SmartSwitch #501

Merged
merged 2 commits into from
Sep 27, 2024

Conversation

vvolam
Copy link
Contributor

@vvolam vvolam commented Sep 24, 2024

Description

Added new APIs and modified reboot API in module_base.py for supporting reboot on a SmartSwitch.

Motivation and Context

These API enhancements are required to support reboot for new SmartSwitch platforms. All the requirements are captured in reboot HLD

How Has This Been Tested?

Modified module_base.py tests. New reboot CLI changes will invoke these APIs.

Additional Information (Optional)

@prgeor prgeor merged commit daeed65 into sonic-net:master Sep 27, 2024
5 checks passed
@@ -258,6 +262,31 @@ def get_state_info(self):
"""
raise NotImplementedError

def get_bus_info(self, module_name):
"""
Retrieves the bus information for the specified by "module_name" on a SmartSwitch.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I guess you intended to say "Retrieves the bus information for the module specified"

"""
Detaches the DPU PCI device specified by "module_name" on a SmartSwitch.

Returns: True once the PCI is successfully detached.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you also call out the negative case? Also, mention how the platform is informed to recover form this.

"""
Rescans and reconnects the DPU PCI device specified by "module_name" on a SmartSwitch.

Returns: True once the PCI is successfully reconnected.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you also call out the negative case? Also, mention how the platform is informed to recover form this

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants