Skip to content

Conversation

@lack
Copy link
Contributor

@lack lack commented Nov 21, 2025

This large string of commits:

  1. First introduces deeper unit test coverage of the existing e810 plugin
    • Before: 36.5%
    • After: 77.2%
  2. Consolidates all shared functions between e810/e825/e830
  3. Ensures the e180 plugin functions equivalently throughout the refactoring thanks to the unit tests
  • addons/intel: Enhance plugin unit test coverage
  • addons/intel: Add os.ReadFile mocking
  • addons/intel: Share PCI clock ID detection across plugins
  • addons/intel: Permit more flexible filesystem and clockchain mocking
  • addons/intel: Unit test getClockIDByModule
  • addons/intel: Add more e825 plugin testing
  • addons/intel: Abstract out ublx initialization and add unit tests
  • CNF-20497: addons/intel: Disable UBLX messages on all busses at init
  • addons/intel: Consolidate pin handling into shared function
  • addons/intel: Add unit tests for PhaseOffset pin settings
  • addons/intel: Consolidate AfterRunPTPCommand and PopulateHwConfig across all intel plugins
  • addons/intel: Consolidate OnPTPConfigChange across e810/e825
  • addons/intel: Consolidate OnPTPConfigChange from e830 as well
  • addons/intel: Simplify code layout

lack added 17 commits November 19, 2025 11:24
- Migrates .golangci-lint.yaml to the v2 syntax, preserving current
  configuration.
- Updates the github hook to use the official golangci-lint-action
  runner.

Signed-off-by: Jim Ramsay <[email protected]>
Split the monolithic intel_test.go into smaller, more focused test files:
- e810_test.go: Tests for e810.go
- e825_test.go: Tests for e825.go
- e830_test.go: Tests for e830.go
- clock-chain_test.go: Tests for clock-chain.go
- phaseAdjust_test.go: Tests for phaseAdjust.go
- mock_test.go: Mock filesystem and test helpers

This improves test organization and readability.

Assisted-by: gemini-2.5-pro
Signed-off-by: Jim Ramsay <[email protected]>
@github-actions
Copy link

Thanks for your PR,
Best regards.

@kenyis
Copy link

kenyis commented Nov 21, 2025

Can we put a hold on this until Jim and I have a chance to discuss?

@lack lack marked this pull request as draft November 21, 2025 22:47
@lack
Copy link
Contributor Author

lack commented Nov 21, 2025

On hold until OpenShift 4.22 branch

@josephdrichard
Copy link
Collaborator

Can you split the linter changes into a separate PR?

@josephdrichard josephdrichard added the ok-to-test ok to test label Nov 22, 2025
name string
hwplugins []string
defaultInitScript string
preferredClock string
Copy link
Collaborator

Choose a reason for hiding this comment

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

What is the preferredClock?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Ah, that's a bad name for it. It's the name of the dpll module we'll extract the clock from, if set. If not set (for e810) we fall back to the older PCI-based mechanism of retrieving the clock ID.

@josephdrichard
Copy link
Collaborator

Can you confirm oc -n openshift-ptp get nodeptpdevice -o yaml works still?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants