xref: /netbsd-src/external/bsd/zstd/dist/contrib/linux-kernel/README.md (revision 3117ece4fc4a4ca4489ba793710b60b0d26bab6c)
1*3117ece4Schristos# Zstd in the Linux Kernel
2*3117ece4Schristos
3*3117ece4SchristosThis directory contains the scripts needed to transform upstream zstd into the version imported into the kernel. All the transforms are automated and tested by our continuous integration.
4*3117ece4Schristos
5*3117ece4Schristos## Upgrading Zstd in the Linux Kernel
6*3117ece4Schristos
7*3117ece4Schristos1. `cd` into this directory.
8*3117ece4Schristos2. Run `make libzstd` and read the output. Make sure that all the diffs printed and changes made by the script are correct.
9*3117ece4Schristos3. Run `make test` and ensure that it passes.
10*3117ece4Schristos4. Import zstd into the Linux Kernel `make import LINUX=/path/to/linux/repo`
11*3117ece4Schristos5. Inspect the diff for sanity.
12*3117ece4Schristos6. Check the Linux Kernel history for zstd. If any patches were made to the kernel version of zstd, but not to upstream zstd, then port them upstream if necessary.
13*3117ece4Schristos7. Test the diff. Benchmark if necessary. Make sure to test multiple architectures: At least x86, i386, and arm.
14*3117ece4Schristos8. Submit the patch to the LKML.
15