Commit Graph
584 Commits
Author SHA1 Message Date
Gleb Chesnokov 6a3bef807b kunit: Import the public Linux KTAP parser
Vendor the unmodified public Linux master parser and printer with
provenance and checksums. Keep SCST module execution policy outside
these files.

Pin upstream commit 24a19b953e2a3d0ea5a8c4951a0ab8f32720c907.
2026-10-14 15:08:03 +03:00
Gleb Chesnokov c3070172c7 kunit: Add a shared test switch and a core library suite
Integrate optional native KUnit suites with out-of-tree SCST modules.
A single CONFIG_SCST_KUNIT_TEST switch includes all test objects of
each owner. Declare each suite name and label once and discover source
registrations for kunit-list without a build or loaded modules.
Preserve ordinary builds without KUnit.

Start with a fixed-wire LUN regression. Centralize private visibility
and task-scoped static-stub switches, and define retained-fixture
reporting for asynchronous tests. Use current native KUnit APIs
without compatibility shims. Keep optional execution messages behind
CONFIG_SCST_KUNIT_LOG while leaving failure diagnostics unconditional.

Add Makefile/Kbuild regression checks and document the shared switch.

Keep compatibility builds free of KUnit, including inherited test
options and allmodconfig. Generate ordinary in-tree SCST patches with
private declarations but without test suites or KUnit build options.
Check this boundary and preserve kernels without an unwinder option.
2026-10-14 15:08:03 +03:00
Gleb Chesnokov 487b52c2f9 scripts/specialize-patch: Rebuild filtered hunks
The regression became visible after commit 91517609cd
("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.
2026-08-26 16:25:41 +03:00
Gleb Chesnokov 726f91559c .github/workflows: Skip disabled regression analyzers
Do not install sparse or build smatch in jobs that disable both.

Check for each tool only when the corresponding analysis is enabled.
2026-08-25 14:24:22 +03:00
Gleb Chesnokov 06857c81cb .github/workflows: Build Ubuntu 20.04 packages
Build Ubuntu 20.04 and 24.04 DEB artifacts in release-specific job
containers with explicit kernel headers.

Publish one bundle per Ubuntu LTS target and keep the README independent of
matrix versions.
2026-08-25 14:24:22 +03:00
Gleb Chesnokov 934fd4e6d1 scripts: Add kernel versions to RPM bundle names
Use normalized RPM matrix kernel versions in rolling snapshot archive
names. Keep vendor suffixes in package metadata and leave Ubuntu DKMS
independent of the runner kernel.
2026-08-25 14:24:22 +03:00
Gleb Chesnokov b8e386a6bc build: Add warnings-as-errors mode
Add a WERROR=y|n build setting that keeps the local default unchanged
and exports -Werror for user-space and kernel compilation. Honor the same
setting in direct regression kernel builds.
2026-08-25 12:10:06 +03:00
Gleb Chesnokov fb47ab3ef1 .github/workflows: Publish master package snapshot
Publish a rolling prerelease after the complete master package
matrix succeeds. Validate and bundle every downloaded artifact before
replacing the previous master-rpm snapshot.
2026-08-25 12:10:06 +03:00
Gleb Chesnokov 12c599b3c4 build: Add containerized RPM artifact target
Expose verified RPM artifact production through a repository Make
target. Use Docker only as the Rocky Linux and Oracle Linux toolchain,
keep the source worktree read-only and support the selected UEK package
layouts.
2026-08-25 12:10:06 +03:00
Gleb Chesnokov 84fdf96a0a scripts: Generate CI kernel matrices
Keep exact kernel versions only in ABT_KERNELS. Resolve the bounded GitHub
regression and RPM subsets from stable selectors, and reject missing or
ambiguous matches.
2026-08-25 12:10:06 +03:00
Gleb Chesnokov 91591e4749 scripts: Ignore complex macro diagnostics
SCST uses macro fragments for sense tuples, initializer lists and other
contexts where enclosing the expansion in parentheses would change its
meaning. Treat COMPLEX_MACRO as a project-wide checkpatch exception.
2026-08-21 19:58:59 +03:00
Gleb Chesnokov 28b811135d scripts: Add ShellCheck lint target
Add a tracked runner that discovers Bash scripts under scripts/ and
checks them with external source resolution enabled. Expose it through
the top-level Makefile.

Run the same entry point from the patch lint workflow whenever a range
touches Bash lint inputs, and report its result explicitly.
2026-08-21 19:58:59 +03:00
Gleb Chesnokov f788bfd0d6 scripts: Fix ShellCheck diagnostics
Quote scalar arguments and use arrays for command option lists so paths
and options retain their boundaries. Preserve intentional version-field
splitting with narrow documented suppressions.

Also handle GNU getopt output without losing quoted arguments and
remove warnings about masked statuses, unused values and ambiguous test
expressions.
2026-08-21 19:58:59 +03:00
Gleb Chesnokov 1a1a75d9ed scripts: Remove non-Git VCS support
Mercurial branches remain in source-listing and cleanup helpers after
Subversion support was retired. SCST development now uses Git.

Remove Mercurial detection and commands together with stale Subversion
wording. Preserve the existing no-VCS source-list fallback and all Git
behavior.
2026-08-21 19:58:59 +03:00
Gleb Chesnokov 0aa6689c3a scripts: Validate monitor intervals
Reject zero and nonnumeric sampling intervals before entering the
monitor loops, avoiding division errors and repeated failed sleep
calls.
2026-08-21 19:58:59 +03:00
Gleb Chesnokov 7057358960 scripts/test-persistent-reservation: Stop after failures
Abort the dependent reservation sequence when an sg_persist command
fails instead of continuing to change device state. Quote the device
argument so it is passed to every command unchanged.
2026-08-21 19:58:59 +03:00
Gleb Chesnokov 5cc6d87b7b scripts: Fix helper edge cases
Propagate patch and module-list failures, normalize the script
directory, and expand the actual Mercurial subrepository name when
matching paths. Keep the existing no-optional-patches behavior
unchanged.
2026-08-21 19:58:59 +03:00
Gleb Chesnokov c93836ed2d scripts/generate-release-archive: Preserve file arguments
Keep explicitly listed files as separate array elements instead of
joining them into one invalid path. Use pipefail so an input-listing
error cannot be hidden by tar.
2026-08-21 19:58:59 +03:00
Gleb Chesnokov 91517609cd scripts/generate-kernel-patch: Preserve split patches
Write the specialized patch unchanged when diffstat is unavailable,
instead of creating an empty file. Propagate specialization,
output-directory, and generated-header failures to the caller.

Treat status 1 from diff as successful when generating QLogic in-tree
patches, while continuing to propagate actual diff failures.
2026-08-21 19:58:59 +03:00
Gleb Chesnokov 114d44cd51 scripts/run-regression-tests: Fix failure handling
Propagate patch, source-copy, and patch-generation failures instead
of continuing with incomplete regression inputs. Stop immediately
when the output directory cannot be created.

Also correct the documented options and keep Debian package output
in its intended log file.
2026-08-21 19:58:59 +03:00
Gleb Chesnokov 3056c73db8 scripts: Validate kernel downloads
Download kernel archives through a temporary file, validate XZ data,
and only publish complete files. Reject corrupt cached downloads and
propagate XZ pipeline failures during extraction and patching.

Wire the regression runner cache option to the kernel_downloads
variable used by the shared download helpers.
2026-08-21 19:58:59 +03:00
Gleb Chesnokov 2b1dc822e8 scripts: Remove pre-3.10 kernel support
Reject unsupported kernel versions before download or patch generation.
Remove 2.x paths, RHEL 5/6 and Scientific Linux repositories, and
compatibility branches that cannot run with the Linux 3.10 minimum.

Keep the maintained ABT_KERNELS matrix unchanged.
2026-08-21 19:58:59 +03:00
Gleb Chesnokov f6ae51b613 scripts/specialize-patch: Fix GNU Awk compatibility
GNU Awk 5.4 rejects unescaped repetition operators at the start of a
regular expression and C-style comments in the program text. Escape the
literal diff markers and use an Awk comment so patch specialization
works with current GNU Awk.
2026-08-21 19:58:59 +03:00
Gleb Chesnokov 3a6fb66c83 scst: Remove residual procfs code
Procfs support was removed in 2019, but dead configuration guards,
patch specialization logic and unused declarations remained. Remove these
remnants and simplify paths that can no longer receive procfs-only objects.
2026-08-21 19:58:59 +03:00
Gleb Chesnokov 5eb824aea8 scripts/kernel-functions: Handle Rocky kernel rebuild tarballs
Rocky Linux kernel rebuilds can append an extra release suffix to the
source RPM name. For example, kernel-5.14.0-687.10.1.el9_8.0.1.src.rpm can
still contain a linux-5.14.0-687.10.1.el9_8.tar.* source archive.

The exact linux-${kver}*.tar.* match then fails before the source tree
can be extracted.

Look for the archive name again with a trailing .0.N rebuild suffix
removed and keep renaming the extracted tree to the full requested kernel
release, so later paths remain unchanged.
2026-05-28 15:49:14 +03:00
Gleb Chesnokov 86a2ee9dc3 scripts/kernel-functions: Validate downloaded RPMs 2026-05-26 18:27:32 +03:00
Gleb Chesnokov f700584be4 scripts: Add Rocky Linux kernel support 2026-05-26 18:27:32 +03:00
Gleb Chesnokov 59bdb2463c scripts/specialize-patch: treat "#if 0" and "#if 0 && ..." as constant-false
Partial evaluation can yield guards like "+#if 0 && ...". These are false
but bypassed the filter that only matched exact "+#if 0"/"+#elif 0".
Tighten the regex to match the original spacing and catch both forms.

This is the minimal change addressing the bug observed in logs such as:

  (c) +#if 0 && !(1 && defined(FC_PORTSPEED_256GBIT)) ...
  (g2) ... output = 1   <-- wrong

After this change such guards are dropped correctly (output = 0).
2025-10-01 22:11:28 +03:00
Gleb Chesnokov 9543060a2c scripts/generate-kernel-patch: Use krel for qla2xxx patch paths
Fix mismatch where generate-kernel-patch keyed paths by full_kver
(with ‘^’) but in-tree patches were written under krel
(before ‘^’). Derive krel=${full_kver/^*} and use it for qla2xxx path
resolution.
2025-09-30 18:09:11 +03:00
Gleb Chesnokov 90c26fa844 scripts/run-regression-tests: Drop 2.6.x paths and simplify builds
Always include drivers/scsi/qla2xxx in subdirs and extend the local
module build loop to cover both qla2x00t and qla2x00t-32gbit.
2025-09-30 18:09:11 +03:00
Gleb Chesnokov 10740bb400 scst_targ: Fix multiple checkpatch warnings
This patch does not change any functionality.
2025-09-16 14:19:05 +03:00
Gleb Chesnokov 17eb80e049 nightly build: Add RHEL 10 kernel support
Add AlmaLinux 10.0 kernel to nightly build configs and update helper
scripts to handle AlmaLinux 10.0 package sources.
2025-06-06 12:31:21 +03:00
Gleb Chesnokov 15ebdec403 nightly build: Add UEK 8 kernel support
Add Oracle Linux UEK 8 kernel to nightly build configs and update helper
scripts to handle UEK 8 package sources.
2025-05-26 17:37:09 +03:00
Gleb Chesnokov d09f360b93 scripts: Fix shellcheck warnings for checkpatch scripts
- Switching from 'set -e' to 'set -euo pipefail' for better error handling.
- Quoting all variable expansions to prevent word splitting and globbing.
- Replacing legacy unquoted $(...) and $@ with quoted forms.
- Using array-safe idioms where necessary (e.g., "${src_files[@]}").

This patch doesn't change any functionality.
2025-03-25 18:57:32 +03:00
Gleb Chesnokov 9082b4e82a nightly build: Update kernel versions
Another kernel versions update
2024-12-28 14:59:04 +03:00
Gleb Chesnokov ec80741a24 iscsi-scst: Fix multiple checkpatch warnings
This patch does not change any functionality.
2024-11-16 14:33:58 +03:00
Gleb Chesnokov 31eca7eced .github/workflows: Use checkpatch scripts
Inroduce several checkpatch scripts to use in workflows.
2024-11-07 13:21:25 +03:00
Gleb Chesnokov 1925094cb0 .github/workflows, scripts: Improve checkpatch compliance
Use checkpatch --strict to detect more style issues.
2024-10-01 16:17:11 +03:00
Gleb Chesnokov 878bbad8ce nightly build: Update kernel versions
Another kernel versions update
2024-09-16 13:44:01 +03:00
Gleb Chesnokov 376838e898 scripts/run-regression-tests: Improve support for RHEL kernels
Additionally, update kernel versions.
2024-09-04 20:12:26 +03:00
Gleb Chesnokov 7c4e07414a .github/workflows: Add a GitHub action to run regression tests upon push
Introduce a new GitHub action that automatically runs the
scripts/run_regression_tests script upon each push to the master branch.
2024-05-03 17:45:14 +03:00
Gleb Chesnokov d3a2faecff scripts/run-regression-tests: Explicitly set KBUILD_MODPOST_WARN=1
This fixes the run-regression-tests build against kernel versions >= v6.3.

See also commit 5573b4daa26a ("kbuild: do not automatically add -w option
to modpost") # v6.3.
2024-05-02 17:20:01 +03:00
Gleb Chesnokov 56bb6c0fa6 nightly build, scripts: Remove svn support
Remove deprecated svn support.
2024-05-02 17:20:01 +03:00
Gleb Chesnokov 7baf286609 scripts/specialize-patch: Improve RHEL support
Unbreak nightly build for RHEL 8.9 and 9.3
2024-01-10 19:34:49 +03:00
Gleb Chesnokov 04ea811e8d scripts: Revert "scripts: Add support for the UEK_RELEASE macro"
This reverts commit 0d025a2e.

Remove unused UEK_RELEASE macro support.
2024-01-10 19:34:49 +03:00
Gleb Chesnokov cf94272cea scst: Remove scst_module.c file
I haven't been able to find any sign of this file being used since the
initial commit, so remove this dead code.
2023-04-28 15:22:58 +03:00
Gleb Chesnokov 31699069f3 nightly build: Include the AlmaLinux RHEL kernels
Add support for RHEL 8.6 8.7 9.0 9.1 nightly builds.
2022-12-14 10:25:38 +03:00
Gleb Chesnokov 80471ef507 scripts/kernel-functions: Improve gcc 12 support
Fix nightly build with gcc 12 for kernel versions 5.11, 5.12, 5.13,
5.14.
2022-12-14 10:25:38 +03:00
Gleb Chesnokov 3961019e74 ib_srpt: Port to Linux kernel v6.1
Support for the following IB changes in the Linux kernel v6.1:
- 91a3f14ec953 ("IB/cm: Remove the service_mask parameter from ib_cm_listen()")
2022-10-27 12:31:00 +03:00
Gleb Chesnokov 1863f8c5c8 scripts: Remove references to the ibmvstgt, mpt and mvsas_tgt drivers 2022-10-25 10:44:54 +03:00