Skip to content

Conversation

@bmastbergen
Copy link
Collaborator

This started as upstream-commit-check.yml from ciqlts9_2 and then the following changes were made:

  • Tweaks to make this 'reusable' from other branches (ie. 'workflow_call')
  • Changed script/job/step names to be more generally about commit validation, not just upstream bugfix checking
  • Added --cve-check functionality from hackathon
  • Added interdiff functionaliy from hackathon (using @kerneltoast work)
  • Added jira pr checker functionality from hackathon (using @PlaidCat work)

The idea with the reusable workflow in main, is that each branch will have a minimal validate-kernel-commits.yml that references the main version. Then, when changes need to be made to the workflow they can be made in one place instead of having to touch every branch. If this works out well, maybe we can move other workflows to this model.

This is an example of what it looks like for a branch workflow to reference this reusable workflow:
bmastbergen@534b3ed

@bmastbergen bmastbergen force-pushed the bmastbergen_main-add-reusable-validate-kernel-commits branch from 45d6630 to 3cc867c Compare October 27, 2025 18:48
@bmastbergen bmastbergen requested a review from PlaidCat October 27, 2025 18:49
PlaidCat
PlaidCat previously approved these changes Oct 27, 2025
Copy link
Collaborator

@PlaidCat PlaidCat left a comment

Choose a reason for hiding this comment

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

:shipit:

I'm looking forward to this, I would like us to use and readdress the comment to make it as readable as possible.

roxanan1996
roxanan1996 previously approved these changes Oct 29, 2025
Copy link

@roxanan1996 roxanan1996 left a comment

Choose a reason for hiding this comment

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

Thanks!

@bmastbergen bmastbergen force-pushed the bmastbergen_main-add-reusable-validate-kernel-commits branch from c5b4313 to 93bdcb5 Compare October 30, 2025 16:44
@bmastbergen bmastbergen force-pushed the bmastbergen_main-add-reusable-validate-kernel-commits branch from 93bdcb5 to dc56b8a Compare October 31, 2025 17:01
@bmastbergen bmastbergen requested a review from PlaidCat October 31, 2025 17:03
PlaidCat
PlaidCat previously approved these changes Oct 31, 2025
Copy link
Collaborator

@PlaidCat PlaidCat left a comment

Choose a reason for hiding this comment

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

Thanks for the changes

:shipit:

Converts the upstream-commit-check workflow (from ciqlts9_2) to a
reusable workflow that can be referenced from branches. This allows
maintaining the workflow definition in one place while using it
across many branches.

The workflow uses workflow_call trigger and accepts all necessary
context from the calling workflow via github context variables.

We are renaming the workflow and some of the labels it uses to be
more general.  In the future, more kernel commit validation will
happen in this workflow besides just the upstream fixes check
This causes check_kernel_commits.py to check the kernel's vulns
database to ensure the CVEs referenced in the commit are correct,
check for missing CVE references, and to add CVE references
to suggested upstream bugfixes
Add steps to look for differences between upsteam commits referenced
in PR commit and the upsteam change they are backporting.  This is
accomplished with a customized version of interdiff with fuzzy
diffing and the run_interdiff.py helper script.  Since the custom
fuzzy diffing changes aren't available in upstream patchutils yet
this workflow pulls down and builds the custom version.
We are using two scripts from that repo and there will be more.  Just
clone the whole thing instead of fetching scripts one by one.
We will be reaching into our JIRA to check the state of each commits
jira.  In this we want to ensure that the target branch matches the
defined branch for that product and validate that the CVE ID is also
correct for the ticket.  It will also check to confirm that the tickets
are in progress and have time logged, if either are untrue then it will
produce a warning.

In the event there are Product or CVE mis matches it will block the PR
and request changes.
s/result.txt/ckc_result.txt/g
This keeps all of our PR interaction consistent
We want the return code of our python scripts, not of tee
@bmastbergen bmastbergen force-pushed the bmastbergen_main-add-reusable-validate-kernel-commits branch from dc56b8a to 6acca96 Compare November 3, 2025 21:17
Copy link
Collaborator

@kerneltoast kerneltoast left a comment

Choose a reason for hiding this comment

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

Thanks for all the iteration on this! 🚢

@bmastbergen bmastbergen requested a review from PlaidCat November 4, 2025 14:14
Copy link
Collaborator

@PlaidCat PlaidCat left a comment

Choose a reason for hiding this comment

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

:shipit:

@bmastbergen bmastbergen merged commit 2db7d10 into main Nov 5, 2025
@bmastbergen bmastbergen deleted the bmastbergen_main-add-reusable-validate-kernel-commits branch November 5, 2025 14:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

6 participants