Skip to content

scripts/specialize-patch: Rebuild filtered hunks - #388

Merged
lnocturno merged 1 commit into
masterfrom
gleb/codex
Aug 26, 2026
Merged

scripts/specialize-patch: Rebuild filtered hunks#388
lnocturno merged 1 commit into
masterfrom
gleb/codex

Conversation

@lnocturno

Copy link
Copy Markdown
Contributor

The regression became visible after commit 9151760 ("scripts/generate-kernel-patch: Preserve split patches") preserved split output that had previously been empty without diffstat. specialize-patch kept the original hunk coordinates after dropping version-dependent lines, so GNU patch rejected the generated qla.h patch.

Recalculate hunk coordinates and context after specialization removes added lines. This prevents GNU patch from rejecting QLogic qla.h hunks for Linux 7.1 and 7.2.

Add a focused regression test for the normal and matching-line-number specialization modes.

The regression became visible after commit 9151760
("scripts/generate-kernel-patch: Preserve split patches") preserved split
output that had previously been empty without diffstat.
specialize-patch kept the original hunk coordinates after dropping
version-dependent lines, so GNU patch rejected the generated qla.h patch.

Recalculate hunk coordinates and context after specialization removes added
lines. This prevents GNU patch from rejecting QLogic qla.h hunks for Linux
7.1 and 7.2.

Add a focused regression test for the normal and matching-line-number
specialization modes.
@lnocturno
lnocturno merged commit 487b52c into master Aug 26, 2026
66 checks passed
@lnocturno
lnocturno deleted the gleb/codex branch August 26, 2026 13:25
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.

1 participant