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

MANA: add driver survey test #2980

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open

MANA: add driver survey test #2980

wants to merge 2 commits into from

Conversation

mcgov
Copy link
Collaborator

@mcgov mcgov commented Sep 26, 2023

mana_en drivers should be present in kernels >= 5.15.
mana_ib drivers should be present in kernels >= 6.2.
Add a test to survey images and check for mana drivers in images.

Test checks kernel config and modprobe to verify the driver is present as either a builtin or module. It checks kernel logs to verify the driver had loaded as expected.

@mcgov mcgov marked this pull request as ready for review September 26, 2023 16:16
mana_en drivers should be present in kernels >= 5.15.
mana_ib drivers should be present in kernels >= 6.2.
Add a test to survey images and check for mana drivers in images.
kconfig = node.tools[KernelConfig]

# Check kconfig for mana
mana_is_builtin = kconfig.is_built_in(mana_driver_name)
Copy link
Collaborator

Choose a reason for hiding this comment

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

we can add a new method for the common code used by these two cases

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

combined, thanks!

)
class ManaDriverCheck(TestSuite):
MANA_DRIVER_MESSAGE_PATTERN = re.compile(r"\[\s*[0-9.]+\s*\]\s+mana\s+.*")
MANA_IB_DRIVER_MESSAGE_PATTERN = re.compile(r"\[\s*[0-9.]+\s*\]\s+mana_ib\s+.*")
Copy link
Collaborator

Choose a reason for hiding this comment

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

add the sample messages

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

updated

Copy link
Collaborator

@LiliDeng LiliDeng Oct 9, 2023

Choose a reason for hiding this comment

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

I don't see the updated with sample messages

mana_driver_name = "mana"
dmesg = node.tools[Dmesg]
modprobe = node.tools[Modprobe]
kconfig = node.tools[KernelConfig]
Copy link
Collaborator

Choose a reason for hiding this comment

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

we can check config even there is no mana devices

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

added a test just kconfig only

@mcgov
Copy link
Collaborator Author

mcgov commented Sep 27, 2023

block merge on testing after refactor...

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.

None yet

3 participants