diff --git a/.dockerignore b/.dockerignore new file mode 100644 index 00000000..d02d740d --- /dev/null +++ b/.dockerignore @@ -0,0 +1,11 @@ +/.git +/.gomodcache +/build/* +!/build/rpms/ +/build/rpms/* +!/build/rpms/*.rpm +/build/rpms/*-debuginfo-*.rpm +/build/rpms/*-debugsource-*.rpm +**/target/* +/sbkeys +/tests diff --git a/.github/ISSUE_TEMPLATE/build.md b/.github/ISSUE_TEMPLATE/build.md new file mode 100644 index 00000000..78d51d32 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/build.md @@ -0,0 +1,28 @@ +--- +name: Bug report - build process +about: Let us know about a problem with the build process +labels: status/needs-triage, type/bug +--- + + + +**Platform I'm building on:** + + + +**What I expected to happen:** + + + +**What actually happened:** + + + +**How to reproduce the problem:** + + diff --git a/.github/ISSUE_TEMPLATE/feature.md b/.github/ISSUE_TEMPLATE/feature.md new file mode 100644 index 00000000..1cc24723 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/feature.md @@ -0,0 +1,19 @@ +--- +name: Feature request +about: Request a change to to the project +labels: status/needs-triage, type/enhancement +--- + + + +**What I'd like:** + + + +**Any alternatives you've considered:** + + diff --git a/.github/ISSUE_TEMPLATE/package.md b/.github/ISSUE_TEMPLATE/package.md new file mode 100644 index 00000000..6da8db36 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/package.md @@ -0,0 +1,28 @@ +--- +name: Bug report - Bottlerocket package +about: Let us know about a problem with Bottlerocket +labels: status/needs-triage, type/bug +--- + + + +**Package I'm using:** + + + +**What I expected to happen:** + + + +**What actually happened:** + + + +**How to reproduce the problem:** + + diff --git a/.github/actions/setup-node/action.yml b/.github/actions/setup-node/action.yml new file mode 100644 index 00000000..501e8721 --- /dev/null +++ b/.github/actions/setup-node/action.yml @@ -0,0 +1,21 @@ +name: "Node setup" +description: "Performs setup for caching and other common needs." +runs: + using: "composite" + steps: + - run: sudo apt -y install build-essential openssl libssl-dev pkg-config liblz4-tool clang + shell: bash + - uses: actions/cache/restore@v4 + # Restore most recent cache if available. + with: + path: | + ~/.cargo + .cargo + .gomodcache + build/external-kits + build/rpms + build/state + target + key: build-cache + - run: cargo install cargo-make + shell: bash diff --git a/.github/dependabot.yaml b/.github/dependabot.yaml new file mode 100644 index 00000000..98b4e6a7 --- /dev/null +++ b/.github/dependabot.yaml @@ -0,0 +1,28 @@ +version: 2 +updates: + + # Maintain dependencies for GitHub Actions + - package-ecosystem: "github-actions" + directory: "/" + schedule: + interval: "weekly" + labels: + - "area/dependencies" + + # We maintain updates for most dependencies. This disables updates other than + # security ones. + - package-ecosystem: "cargo" + directory: "/" + schedule: + interval: "daily" + labels: + - "area/dependencies" + open-pull-requests-limit: 0 + + - package-ecosystem: "gomod" + directory: "/" + schedule: + interval: "daily" + labels: + - "area/dependencies" + open-pull-requests-limit: 0 diff --git a/.github/pull_request_template.md b/.github/pull_request_template.md new file mode 100644 index 00000000..2daff887 --- /dev/null +++ b/.github/pull_request_template.md @@ -0,0 +1,21 @@ + + +**Issue number:** + +Closes # + +**Description of changes:** + + + +**Testing done:** + + + +**Terms of contribution:** + +By submitting this pull request, I agree that this contribution is dual-licensed under the terms of both the Apache License, version 2.0, and the MIT license. diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml new file mode 100644 index 00000000..d9403005 --- /dev/null +++ b/.github/workflows/build.yml @@ -0,0 +1,56 @@ +name: Build +on: + pull_request: + branches: [develop] + # Here we list file types that don't affect the build and don't need to use + # up our Actions runners. + paths-ignore: + # draw.io (diagrams.net) files, the source of png images for docs + - '**.drawio' + # Example configuration files + - '**.example' + # Markdown documentation + - '**.md' + # Images for documentation + - '**.png' + # Templates for README files + - '**.tpl' + # Sample config files and OpenAPI docs + - '**.yaml' + # Bottlerocket Security Advisories + - 'advisories/**' + # VSCode configurations + - '.vscode/**' + +concurrency: + group: ${{ github.ref }} + cancel-in-progress: true + +jobs: + build: + runs-on: + group: bottlerocket + labels: bottlerocket_ubuntu-latest_32-core + continue-on-error: true + strategy: + matrix: + arch: [x86_64, aarch64] + fail-fast: false + name: "Build ${{ matrix.arch }}" + steps: + - name: Random delay + run: | + delay=$((1 + $RANDOM % 32)) + echo "Waiting ${delay} seconds before execution" + sleep $delay + - uses: actions/checkout@v4 + - name: Preflight step to set up the runner + uses: ./.github/actions/setup-node + - run: rustup component add rustfmt + - run: make twoliter check-licenses + - run: make twoliter unit-tests + # Avoid running Go lint check via `cargo make check-lints` since there's a separate golangci-lint workflow + - run: make twoliter check-fmt + - run: make twoliter check-clippy + - run: make twoliter check-shell + - run: make ARCH="${{ matrix.arch }}" diff --git a/.github/workflows/cache.yml b/.github/workflows/cache.yml new file mode 100644 index 00000000..e9674bcc --- /dev/null +++ b/.github/workflows/cache.yml @@ -0,0 +1,61 @@ +# This workflow caches external dependencies, build tools, and the most recent artifacts. +# The cache is only usable by workflows started from pull requests against the develop branch. +name: CacheLatest +on: + push: + branches: [develop] +jobs: + cache: + if: github.repository == 'bottlerocket-os/bottlerocket-kernel-kit' + runs-on: + group: bottlerocket + labels: bottlerocket_ubuntu-latest_32-core + concurrency: + group: cache-${{ github.ref }} + cancel-in-progress: true + env: + cache-key: build-cache + permissions: + actions: write + steps: + - uses: actions/checkout@v4 + # Install dependencies for twoliter and cargo-make. + - run: sudo apt -y install build-essential openssl libssl-dev pkg-config liblz4-tool + shell: bash + # Install cargo-make. + - run: cargo install cargo-make + shell: bash + # This installs twoliter. + - run: make prep + # This fetches any external kit dependencies. + - run: make fetch + # This fetches Rust crate and Go module dependencies. + - run: make twoliter fetch + # This builds the current packages and kits. + - run: make ARCH=x86_64 + - run: make ARCH=aarch64 + # Delete packages that aren't needed for other builds. + - run: | + find build/rpms -name '*debugsource*' -type f -print -delete + find build/rpms -name '*debuginfo*' -type f -print -delete + find build/rpms -name '*kmod*nvidia*' -type f -print -delete + # Remove the previous cache (if it exists). + - run: | + gh extension install actions/gh-actions-cache + gh actions-cache delete "${{ env.cache-key }}" --confirm + env: + GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} + continue-on-error: true + # This caches the reusable artifacts for future CI runs. + - uses: actions/cache/save@v4 + # Save Rust dependencies + with: + path: | + ~/.cargo + .cargo + .gomodcache + build/external-kits + build/rpms + build/state + target + key: ${{ env.cache-key }} diff --git a/.github/workflows/golangci-lint.yaml b/.github/workflows/golangci-lint.yaml new file mode 100644 index 00000000..107d9da9 --- /dev/null +++ b/.github/workflows/golangci-lint.yaml @@ -0,0 +1,30 @@ +name: golangci-lint +on: + pull_request: + branches: [develop] + # Only run this workflow if Go files or this workflow have been modified + paths: + - '**.go' + - '*/go.mod' + - '*/go.sum' + - '.github/workflows/golangci-lint.yaml' + +jobs: + golangci-lint: + name: lint + runs-on: ubuntu-latest + steps: + - uses: actions/setup-go@v5 + with: + go-version: 1.21 + - uses: actions/checkout@v4 + - name: lint-host-ctr + uses: golangci/golangci-lint-action@v6 + with: + version: latest + working-directory: sources/host-ctr + - name: lint-ecs-gpu-init + uses: golangci/golangci-lint-action@v6 + with: + version: latest + working-directory: sources/ecs-gpu-init diff --git a/.gitignore b/.gitignore new file mode 100644 index 00000000..0a418333 --- /dev/null +++ b/.gitignore @@ -0,0 +1,20 @@ +/build +*.tar.* +*.tgz +**/target/ +**/vendor/ +/.cargo +/.gomodcache +/html +/Infra.toml +/Test.toml +/testsys.kubeconfig +/*.pem +/keys +/roles +/sbkeys/**/ +/Licenses.toml +/licenses +*.run +/tests +Twoliter.override diff --git a/.golangci.yaml b/.golangci.yaml new file mode 100644 index 00000000..471707f6 --- /dev/null +++ b/.golangci.yaml @@ -0,0 +1,18 @@ +linters: + enable: + - errcheck + - goimports + - ineffassign + - misspell + - revive + - staticcheck + - unconvert + - unused + - govet + +run: + timeout: 3m +issues: + exclude-dirs: + - vendor + - .gomodcache diff --git a/.mailmap b/.mailmap new file mode 100644 index 00000000..dbe230b0 --- /dev/null +++ b/.mailmap @@ -0,0 +1,34 @@ +Jacob Peddicord +Jacob Vallejo +Jamie Anderson <32437770+jamieand@users.noreply.github.com> +Michael Patraw <52084153+patraw@users.noreply.github.com> +Samuel Mendoza-Jonas <53018225+sam-aws@users.noreply.github.com> +Tom Kirchner +Zac Mrowicki +Zac Mrowicki +Mahdi Chaker M +Arnaldo Garcia Rincon +Arnaldo Garcia Rincon +Ben Cressey +Erikson Tung +Jacob Vallejo +John McBride +Kyle J. Davis +Markus Boehme +Matthew James Briggs +Matthew James Briggs <6260372+webern@users.noreply.github.com> +Matthew James Briggs +Matthew James Briggs Matt Briggs +Matthew Yeazel <67169369+yeazelm@users.noreply.github.com> +Matthias Sterckx +Samuel Karp +Sanika Shah +Sean Kelly +Sean McGinnis +Sean P. Kelly +Shailesh Gothi +Tianhao Geng +Tianhao Geng <45469883+gthao313@users.noreply.github.com> +Ethan Pullen +Ethan Pullen +Shikha Vyaghra <107685805+vyaghras@users.noreply.github.com> diff --git a/BUILDING.md b/BUILDING.md new file mode 100644 index 00000000..7156d8b9 --- /dev/null +++ b/BUILDING.md @@ -0,0 +1,107 @@ +# How to build the Bottlerocket kernel kit + +If you'd like to build your own copy of the kernel kit for local development, follow these steps. + +## Dependencies +#### System Requirements +The build process artifacts and resulting images can consume in excess of 80GB in the local directory. +The build process is also fairly demanding on your CPU, since we build all included software from scratch. This is only done the first time. Package builds are cached, and only changes are built afterward. +The build scales well to 32+ cores. +The first time you build, the fastest machines can take about 20 minutes while slower machines with only a couple cores can take 3-4 hours. +#### Linux +The build system requires certain operating system packages to be installed. +Ensure the following packages are installed: +##### Ubuntu +```shell +apt install build-essential openssl libssl-dev pkg-config liblz4-tool +``` +##### Fedora +```shell +yum install make automake gcc openssl openssl-devel pkg-config lz4 perl-FindBin perl-lib +``` + +#### Rust +The build system is based on the Rust language. +We recommend you install the latest stable Rust using [rustup](https://rustup.rs/), either from the official site or your development host's package manager. +Rust 1.51.0 or higher is required. +To organize build tasks, we use [cargo-make](https://sagiegurari.github.io/cargo-make/). +To get it, run: +```shell +cargo install cargo-make +``` + +### OCI Artifacts + +Building a kit results in building OCI artifacts, there are two ways to build these artifacts: `crane` or `docker` with the `containerd-snapshotter` feature enabled. + +We recommend using `crane` (and `krane`) over `docker` as it has shown better performance in our testing. + +#### Docker +We recommend [Docker](https://docs.docker.com/install/#supported-platforms) 20.10.10 or later. The default seccomp policy of older versions of Docker do not support the `clone3` syscall in recent versions of Fedora or Ubuntu, on which the Bottlerocket SDK is based. +Builds rely on Docker's integrated BuildKit support, which has received many fixes and improvements in newer versions. + +You'll need to have Docker installed and running, with your user account added to the `docker` group. +Docker's [post-installation steps for Linux](https://docs.docker.com/install/linux/linux-postinstall/) will walk you through that. +You'll also need to enable the containerd-snapshotter and buildkit features for your docker daemon. This is required to ensure docker compatibility with OCI Images (which kits are stored in). +The following configuration is needed in your `/etc/docker/daemon.json` +```json +{ + "features": { + "buildkit": true, + "containerd-snapshotter": true + } +} +``` +#### Crane +[Crane](https://github.com/google/go-containerregistry/blob/main/cmd/crane/README.md) is a tool for interacting with remote images and registries.. It does not require a daemon and thus you don't need the above Docker features to use it. Twoliter supports utilizing `crane` (or `krane`) instead of `docker` if it is installed. + +The installation instructions for [crane](https://github.com/google/go-containerregistry/tree/main/cmd/crane) should help you set it up for use with Twoliter. + +## Build the kernel kit + +Building the kernel kit can be done by using the makefile targets. +``` +make ARCH= +``` + +## Publish the Kit +After the kit has been built you can then publish the kit image to your private registry. This will allow you to consume it to build and test a variant. + +### Use a private registry for development +It is recommended that you have some form of protected container registry to use for testing. +For testing purposes you can either utilize mutable tags to allow overriding of multiple versions of a kernel kit as you test, or you can use immutable tags and continuously bump the kernel kit version via the `Twoliter.toml`. + +### Configure Infra.toml +An `Infra.toml` file needs to be created and should have a definition of your vendor (container registry) in order to publish the kits you build. To do so make sure that the `Infra.toml` has the below. +``` +[vendor.] +registry = "####.dkr.ecr.us-west-2.amazonaws.com" +``` +After the kit has been built locally, the kit can be published to the provided vendor in `Infra.toml`. To do this, you will need docker credentials with ECR access. You can do this with, +``` +aws ecr get-login-password --region us-west-2 | docker login --username AWS --password-stdin ####.dkr.ecr.us-west-2.amazonaws.com +``` + +Finally, publishing the kernel kit images can be handled by the makefile target. +``` +make publish VENDOR= +``` +At this point, there should be a kernel kit image in your private registry which can be consumed when building a variant to test and validate. + +## Consuming the published kit image +This section will cover building a variant to test a build of the kernel kit as done above. Please note this section does not cover the complete complexity of testing a change to Bottlerocket. For this see the [BUILDING](https://github.com/bottlerocket-os/bottlerocket/blob/develop/BUILDING.md) section in the [Bottlerocket](https://github.com/bottlerocket-os/bottlerocket/) repository. + +### Configure Twoliter.toml +To consume a private copy of the Bottlerocket kernel kit with your changes built into it, you need to define the vendor that points to your container registry in `Twoliter.toml` and adjust the kernel kit dependency: +``` +[vendor.my-vendor] +registry = "####.dkr.ecr.us-west-2.amazonaws.com" +[[kit]] +name = "bottlerocket-kernel-kit" # Name of your ECR repo +version = "2.x.y" # your version tag you want to test +vendor = "my-vendor" +``` +Any time you change the vendor or version of the kit above you need to run `twoliter update` to update the `Twoliter.lock` +``` +./tools/twoliter/twoliter update +``` diff --git a/CODE_OF_CONDUCT.md b/CODE_OF_CONDUCT.md new file mode 100644 index 00000000..5b627cfa --- /dev/null +++ b/CODE_OF_CONDUCT.md @@ -0,0 +1,4 @@ +## Code of Conduct +This project has adopted the [Amazon Open Source Code of Conduct](https://aws.github.io/code-of-conduct). +For more information see the [Code of Conduct FAQ](https://aws.github.io/code-of-conduct-faq) or contact +opensource-codeofconduct@amazon.com with any additional questions or comments. diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md new file mode 100644 index 00000000..10bb7334 --- /dev/null +++ b/CONTRIBUTING.md @@ -0,0 +1,76 @@ +# Contributing Guidelines + +Thank you for your interest in contributing to our project. +Whether it's a bug report, new feature, correction, or additional documentation, we greatly value feedback and contributions from our community. + +Please read through this document before submitting any issues or pull requests to ensure we have all the necessary information to effectively respond to your bug report or contribution. + + +## Reporting Bugs/Feature Requests + +We welcome you to use the GitHub issue tracker to report bugs or suggest features. + +When filing an issue, please check [existing open](https://github.com/bottlerocket-os/bottlerocket/issues) and [closed](https://github.com/bottlerocket-os/bottlerocket/issues?q=is%3Aissue+is%3Aclosed) issues to make sure somebody else hasn't already reported the issue. +Please try to include as much information as you can. +Details like these are incredibly useful: + +* A reproducible test case or series of steps +* The version of our code being used +* Any modifications you've made relevant to the bug +* Anything unusual about your environment or deployment + + +## Contributing via Pull Requests +Contributions via pull requests are much appreciated. +Before starting a pull request, please ensure that: + +1. You open an issue first to discuss any significant work - we would hate for your time to be wasted. +2. You are working against the latest source on the *develop* branch. +3. You check existing [open](https://github.com/bottlerocket-os/bottlerocket/pulls) and [merged](https://github.com/bottlerocket-os/bottlerocket/pulls?q=is%3Apr+is%3Aclosed) pull requests to make sure someone else hasn't addressed the problem already. + +To send us a pull request, please: + +1. Fork the repository. +2. Modify the source; please focus on the specific change you are contributing. If you also reformat the code, it will be hard for us to focus on your change. +3. Ensure local tests pass. +4. Commit to your fork using clear commit messages. +5. Send us a pull request, answering any default questions in the pull request interface. +6. Pay attention to any automated CI failures reported in the pull request, and stay involved in the conversation. + +GitHub provides additional documentation on [forking a repository](https://help.github.com/articles/fork-a-repo/) and [creating a pull request](https://help.github.com/articles/creating-a-pull-request/). + +## Repo branch and tag structure + +Active development occurs under the `develop` branch. + +Bottlerocket uses both tags and branches for release alignment. Numbered releases are always associated with [tags that mirror the full SemVer 3-digit version number](https://github.com/bottlerocket-os/bottlerocket/tags) (e.g. `1.7.2`). [Branches are for patching only](https://github.com/bottlerocket-os/bottlerocket/branches/all): if a patch is required, a branch will be cut for that minor release line (e.g. `1.7.x`). As a consequence, some previous minor versions may not have a branch if they never required a subsequent patch. + +## Filename case conventions + +Bottlerocket follows a few basic filename case conventions: + +- All extensions are lowercase, +- Build related configuration files always start with a capital letter (e.g. `Infra.toml`, `Release.toml`), +- All caps is used for documents and licenses (e.g. `PUBLISHING.md`, `TRADEMARKS.md`), +- All lower case is used for all other files (e.g. `sample-eksctl.yaml`, `main.rs`). + + +## Finding contributions to work on +Looking at the existing issues is a great way to find something to contribute on. +As this repository uses GitHub issue [labels](https://github.com/bottlerocket-os/bottlerocket/labels), looking through issues labeled ['good first issue'](https://github.com/bottlerocket-os/bottlerocket/labels/good%20first%20issue) or ['help wanted'](https://github.com/bottlerocket-os/bottlerocket/labels/help%20wanted) is a great place to start. + + +## Code of Conduct +This project has adopted the [Amazon Open Source Code of Conduct](https://aws.github.io/code-of-conduct). +For more information see the [Code of Conduct FAQ](https://aws.github.io/code-of-conduct-faq) or contact opensource-codeofconduct@amazon.com with any additional questions or comments. + + +## Security issue notifications +If you discover a potential security issue in this project we ask that you notify AWS/Amazon Security via our [vulnerability reporting page](http://aws.amazon.com/security/vulnerability-reporting/). +Please do **not** create a public GitHub issue. + + +## Licensing + +See the [COPYRIGHT](COPYRIGHT) file for our project's licensing. +We will ask you to confirm the licensing of your contribution. diff --git a/COPYRIGHT b/COPYRIGHT new file mode 100644 index 00000000..522b0c77 --- /dev/null +++ b/COPYRIGHT @@ -0,0 +1,19 @@ +Copyright Amazon.com, Inc., its affiliates, or other contributors. All Rights Reserved. + +Except as otherwise noted (below and/or in individual files), Bottlerocket is dual-licensed under +the Apache License, version 2.0 or the MIT license , at your option. + +Copyrights in Bottlerocket are retained by their contributors. No copyright assignment is required +to contribute to Bottlerocket. Contributions to Bottlerocket are explicitly made under both the +Apache License, version 2.0, and the MIT license. For full authorship information, see the version +control history. + +Bottlerocket operating system images include packages written by third parties, which may carry +their own copyright notices and license terms. These are available in /usr/share/licenses on the +operating system images. + +=^..^= =^..^= =^..^= =^..^= =^..^= =^..^= =^..^= =^..^= =^..^= =^..^= =^..^= + +Contains modified aws-smithy-experimental file(s) [hyper_1_0.rs] from +https://github.com/smithy-lang/smithy-rs/tree/release-2024-10-09. +Licensed under the Apache-2.0 License. diff --git a/Cargo.lock b/Cargo.lock new file mode 100644 index 00000000..567b348b --- /dev/null +++ b/Cargo.lock @@ -0,0 +1,82 @@ +# This file is automatically @generated by Cargo. +# It is not intended for manual editing. +version = 4 + +[[package]] +name = "bottlerocket-kernel-kit" +version = "0.1.0" +dependencies = [ + "grub", + "kernel-5_10", + "kernel-5_15", + "kernel-6_1", + "kmod-5_10-nvidia", + "kmod-5_15-nvidia", + "kmod-6_1-nvidia", + "libkcapi", + "linux-firmware", + "microcode", + "shim", +] + +[[package]] +name = "grub" +version = "0.1.0" + +[[package]] +name = "kernel-5_10" +version = "0.1.0" +dependencies = [ + "microcode", +] + +[[package]] +name = "kernel-5_15" +version = "0.1.0" +dependencies = [ + "microcode", +] + +[[package]] +name = "kernel-6_1" +version = "0.1.0" +dependencies = [ + "microcode", +] + +[[package]] +name = "kmod-5_10-nvidia" +version = "0.1.0" +dependencies = [ + "kernel-5_10", +] + +[[package]] +name = "kmod-5_15-nvidia" +version = "0.1.0" +dependencies = [ + "kernel-5_15", +] + +[[package]] +name = "kmod-6_1-nvidia" +version = "0.1.0" +dependencies = [ + "kernel-6_1", +] + +[[package]] +name = "libkcapi" +version = "0.1.0" + +[[package]] +name = "linux-firmware" +version = "0.1.0" + +[[package]] +name = "microcode" +version = "0.1.0" + +[[package]] +name = "shim" +version = "0.1.0" diff --git a/Cargo.toml b/Cargo.toml new file mode 100644 index 00000000..07aa5f93 --- /dev/null +++ b/Cargo.toml @@ -0,0 +1,16 @@ +[workspace] +resolver = "2" +members = [ + "kits/bottlerocket-kernel-kit", + "packages/grub", + "packages/kernel-5.10", + "packages/kernel-5.15", + "packages/kernel-6.1", + "packages/kmod-5.10-nvidia", + "packages/kmod-5.15-nvidia", + "packages/kmod-6.1-nvidia", + "packages/linux-firmware", + "packages/microcode", + "packages/libkcapi", + "packages/shim", +] diff --git a/GLOSSARY.md b/GLOSSARY.md new file mode 100644 index 00000000..dd08bfca --- /dev/null +++ b/GLOSSARY.md @@ -0,0 +1,47 @@ +## Bottlerocket terms + +* [**block-party**](sources/updater/block-party): A library that helps retrieve information about Linux block devices. +* [**bork**](sources/api/bork): A setting generator called by sundog to generate the random seed for updog, determining where the host falls in the update order. +* [**buildsys**](tools/buildsys): A build tool that runs package and image builds inside containers. + cargo-make starts the build of each package, each of which calls buildsys, which in turn starts a Docker-based build using the SDK image. +* [**corndog**](sources/api/corndog): A program that sets kernel sysctl values based on API settings. +* [**early-boot-config**](sources/api/early-boot-config): A program run at boot to read platform-specific data, such as EC2 user data, and send requested configuration to the API. +* **gptprio:** A structure of bits in GPT partition headers that specifies priority, tries remaining, and whether the partition booted successfully before. + signpost sets these and GRUB uses them to determine which partition set to boot. +* [**ghostdog**](sources/ghostdog): A program used to manage ephemeral disks. +* **host containers**: Containers that run in a separate instance of containerd than "user" containers spawned by an orchestrator (e.g. Kubernetes). + Used for system maintenance and connectivity. +* [**host-ctr**](sources/host-ctr): The program started by `host-containers@.service` for each host container. + Its job is to start the specified host container on the “host” instance of containerd, which is separate from the “user” instance of containerd used for Kubernetes pods. +* [**logdog**](sources/logdog): A program that one can use to collect logs when things go wrong. +* [**metricdog**](sources/metricdog): A program that sends anonymous health pings. +* [**model**](sources/models): The API system has a data model defined for each variant, and this model is used by other programs to serialize and deserialize requests while maintaining safety around data types. +* [**netdog**](sources/api/netdog): A program called by wicked to retrieve and write out network configuration from DHCP. +* [**pluto**](sources/api/pluto): A setting generator called by sundog to find networking settings required by Kubernetes. +* [**schnauzer**](sources/api/schnauzer): A setting generator called by sundog to build setting values that contain template variables referencing other settings. +* **setting generator**: A binary that generates the default value of a setting. +* [**shibaken**](sources/api/shibaken): A setting generator called by sundog to populate the admin container's user-data with public keys from IMDS, when running in AWS. +* [**signpost**](sources/updater/signpost): A program used to manipulate the GPT header of the OS disk; fields in the header are used by GRUB to determine the partition set we should boot from. +* [**storewolf**](sources/api/storewolf): A program that sets up the data store for the API upon boot. +* [**sundog**](sources/api/sundog): A program run during boot that generates any settings that depend on runtime system information. + It finds settings that need generation by way of metadata in the API, and calls helper programs specified by that metadata. +* [**thar-be-settings**](sources/api/thar-be-settings): A program that writes out system configuration files, replacing template variables with settings from the API. +* [**updog**](sources/updater/updog): An update client that interfaces with a specified TUF updates repository to upgrade or downgrade Bottlerocket hosts to different image versions. +* [**prairiedog**](sources/api/prairiedog): A program that handles various boot related operations. +* [**shimpei**](sources/shimpei): An OCI compatible shim wrapper around `oci-add-hooks`. Its sole purpose is to call `oci-add-hooks` with the additional `--hook-config-path` and `--runtime-path` parameters that can't be provided by containerd. + +## Non-Bottlerocket terms + +* **k8s**: [Kubernetes](https://kubernetes.io/), a container orchestration system. +* [**CNI**](https://github.com/containernetworking/cni): Container Network Interface, a standard for writing plugins to configure network interfaces in containers. +* **IMDS**: [Amazon EC2's Instance Metadata Service](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-instance-metadata.html). + Used to retrieve user and platform configuration on an EC2 instance. +* [**sonobuoy**](https://github.com/vmware-tanzu/sonobuoy): A diagnostic tool and runs Kubernetes conformance tests for Kubernetes clusters. +* **SSM**: [AWS Systems Manager](https://aws.amazon.com/systems-manager/). + The [SSM agent](https://docs.aws.amazon.com/systems-manager/latest/userguide/prereqs-ssm-agent.html) can be used for secure remote management. +* [**tough**](https://crates.io/crates/tough): a Rust implementation of The Update Framework (TUF). +* [**tuftool**](https://crates.io/crates/tuftool): a command line program for interacting with a TUF repo. +* **TUF**: [The Update Framework](https://theupdateframework.io/). + A framework that helps developers maintain the security of software update systems. +* [**wicked**](https://github.com/openSUSE/wicked): A network interface framework and management system. +* [**oci-add-hooks**](https://github.com/awslabs/oci-add-hooks): An OCI runtime that injects the OCI `prestart`, `poststart`, and `poststop` hooks into a container `config.json` before passing along to an OCI compatible runtime. diff --git a/LICENSE-APACHE b/LICENSE-APACHE new file mode 100644 index 00000000..d6456956 --- /dev/null +++ b/LICENSE-APACHE @@ -0,0 +1,202 @@ + + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + + END OF TERMS AND CONDITIONS + + APPENDIX: How to apply the Apache License to your work. + + To apply the Apache License to your work, attach the following + boilerplate notice, with the fields enclosed by brackets "[]" + replaced with your own identifying information. (Don't include + the brackets!) The text should be enclosed in the appropriate + comment syntax for the file format. We also recommend that a + file or class name and description of purpose be included on the + same "printed page" as the copyright notice for easier + identification within third-party archives. + + Copyright [yyyy] [name of copyright owner] + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. diff --git a/LICENSE-MIT b/LICENSE-MIT new file mode 100644 index 00000000..df3c0d62 --- /dev/null +++ b/LICENSE-MIT @@ -0,0 +1,8 @@ +MIT License +Copyright Amazon.com, Inc., its affiliates, or other contributors. All Rights Reserved. + +Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. diff --git a/Makefile b/Makefile new file mode 100644 index 00000000..db74ad8e --- /dev/null +++ b/Makefile @@ -0,0 +1,62 @@ +TOP := $(dir $(abspath $(firstword $(MAKEFILE_LIST)))) +TOOLS_DIR := $(TOP)tools +TWOLITER_DIR := $(TOOLS_DIR)/twoliter +TWOLITER := $(TWOLITER_DIR)/twoliter +CARGO_HOME := $(TOP).cargo + +TWOLITER_VERSION ?= "0.6.0" +TWOLITER_SHA256_AARCH64 ?= "73a961ff8b9e829b764a86e096b9c2630b452dadc2099f678d57b2146f6a18f9" +TWOLITER_SHA256_X86_64 ?= "739c5ed0bbd9b0f50ca641964e03b1a92ae9b2c814b1c3463e22f54bc8968e35" +KIT ?= bottlerocket-kernel-kit +UNAME_ARCH = $(shell uname -m) +ARCH ?= $(UNAME_ARCH) +VENDOR ?= bottlerocket + +ifeq ($(UNAME_ARCH), aarch64) + TWOLITER_SHA256=$(TWOLITER_SHA256_AARCH64) +else + TWOLITER_SHA256=$(TWOLITER_SHA256_X86_64) +endif + + +export GO_MODULES = ecs-gpu-init host-ctr + +all: build + +prep: + @mkdir -p $(TWOLITER_DIR) + @mkdir -p $(CARGO_HOME) + @$(TOOLS_DIR)/install-twoliter.sh \ + --repo "https://github.com/bottlerocket-os/twoliter" \ + --version v$(TWOLITER_VERSION) \ + --directory $(TWOLITER_DIR) \ + --reuse-existing-install \ + --allow-binary-install $(TWOLITER_SHA256) \ + --allow-from-source + +update: prep + @$(TWOLITER) update + +fetch: prep + @$(TWOLITER) fetch --arch $(ARCH) + +build: fetch + @$(TWOLITER) build kit $(KIT) --arch $(ARCH) + +publish: prep + @$(TWOLITER) publish kit $(KIT) $(VENDOR) + +TWOLITER_MAKE = $(TWOLITER) make --cargo-home $(CARGO_HOME) --arch $(ARCH) + +# Treat any targets after "make twoliter" as arguments to "twoliter make". +ifeq (twoliter,$(firstword $(MAKECMDGOALS))) + TWOLITER_MAKE_ARGS := $(wordlist 2,$(words $(MAKECMDGOALS)),$(MAKECMDGOALS)) + $(eval $(TWOLITER_MAKE_ARGS):;@:) +endif + +# Transform "make twoliter" into "twoliter make", for access to tasks that are +# only available through the embedded Makefile.toml. +twoliter: prep + @$(TWOLITER_MAKE) $(TWOLITER_MAKE_ARGS) + +.PHONY: prep update fetch build publish twoliter diff --git a/README.md b/README.md new file mode 100644 index 00000000..0f466ed1 --- /dev/null +++ b/README.md @@ -0,0 +1,23 @@ +# Bottlerocket Kernel Kit +This is the kernel kit for [Bottlerocket](https://github.com/bottlerocket-os/bottlerocket). +It includes many common dependencies for downstream package and variant builds. + +## Contents +The kernel kit includes: +* multiple versions of the Linux kernel +* bootloaders +* firmware + +### Availability +The [Bottlerocket kernel kit](https://gallery.ecr.aws/bottlerocket/bottlerocket-kernel-kit) is available through Amazon ECR Public. + +### Development +The kernel kit can be built on either an **x86_64** or an **aarch64** host. To do this you can use the following commands. +```shell +make +``` +OR +```shell +make ARCH= +``` +See the [BUILDING](BUILDING.md) guide for more details. diff --git a/Twoliter.lock b/Twoliter.lock new file mode 100644 index 00000000..5f2ca4e7 --- /dev/null +++ b/Twoliter.lock @@ -0,0 +1,9 @@ +schema-version = 1 +kit = [] + +[sdk] +name = "bottlerocket-sdk" +version = "0.50.0" +vendor = "bottlerocket" +source = "public.ecr.aws/bottlerocket/bottlerocket-sdk:v0.50.0" +digest = "Rjpy/gVgBhU/B696xaK1Y4/drz4pNJu+fyyZSIk9oLE=" diff --git a/Twoliter.toml b/Twoliter.toml new file mode 100644 index 00000000..97a574f3 --- /dev/null +++ b/Twoliter.toml @@ -0,0 +1,10 @@ +schema-version = 1 +release-version = "1.0.0" + +[vendor.bottlerocket] +registry = "public.ecr.aws/bottlerocket" + +[sdk] +name = "bottlerocket-sdk" +version = "0.50.0" +vendor = "bottlerocket" diff --git a/kits/bottlerocket-kernel-kit/Cargo.toml b/kits/bottlerocket-kernel-kit/Cargo.toml new file mode 100644 index 00000000..1c38c8c7 --- /dev/null +++ b/kits/bottlerocket-kernel-kit/Cargo.toml @@ -0,0 +1,26 @@ +[package] +name = "bottlerocket-kernel-kit" +version = "0.1.0" +edition = "2021" +publish = false +build = "../build.rs" + +[package.metadata.build-kit] +vendor = "bottlerocket" + +[lib] +path = "../kit.rs" + +[build-dependencies] +grub = { path = "../../packages/grub" } +kernel-5_10 = { path = "../../packages/kernel-5.10" } +kernel-5_15 = { path = "../../packages/kernel-5.15" } +kernel-6_1 = { path = "../../packages/kernel-6.1" } +kmod-5_10-nvidia = { path = "../../packages/kmod-5.10-nvidia" } +kmod-5_15-nvidia = { path = "../../packages/kmod-5.15-nvidia" } +kmod-6_1-nvidia = { path = "../../packages/kmod-6.1-nvidia" } +linux-firmware = { path = "../../packages/linux-firmware" } +microcode = { path = "../../packages/microcode" } +libkcapi = { path = "../../packages/libkcapi" } +shim = { path = "../../packages/shim" } + diff --git a/kits/build.rs b/kits/build.rs new file mode 100644 index 00000000..669c934e --- /dev/null +++ b/kits/build.rs @@ -0,0 +1,9 @@ +use std::process::{exit, Command}; + +fn main() -> Result<(), std::io::Error> { + let ret = Command::new("buildsys").arg("build-kit").status()?; + if !ret.success() { + exit(1); + } + Ok(()) +} diff --git a/kits/kit.rs b/kits/kit.rs new file mode 100644 index 00000000..6bedb60e --- /dev/null +++ b/kits/kit.rs @@ -0,0 +1,7 @@ +/*! + +This is an intentionally empty file that all of the variant `Cargo.toml` files can point to as their +`lib.rs`. The build system uses `build.rs` to invoke `buildsys` but Cargo needs something to compile +so we give it an empty `lib.rs` file. + +!*/ diff --git a/packages/.gitignore b/packages/.gitignore new file mode 100644 index 00000000..ab0abbf9 --- /dev/null +++ b/packages/.gitignore @@ -0,0 +1,3 @@ +*.patch.bz2 +*.src.rpm +*.zip diff --git a/packages/build.rs b/packages/build.rs new file mode 100644 index 00000000..cad8999a --- /dev/null +++ b/packages/build.rs @@ -0,0 +1,9 @@ +use std::process::{exit, Command}; + +fn main() -> Result<(), std::io::Error> { + let ret = Command::new("buildsys").arg("build-package").status()?; + if !ret.success() { + exit(1); + } + Ok(()) +} diff --git a/packages/grub/0001-setup-Add-root-device-argument-to-grub-setup.patch b/packages/grub/0001-setup-Add-root-device-argument-to-grub-setup.patch new file mode 100644 index 00000000..797be263 --- /dev/null +++ b/packages/grub/0001-setup-Add-root-device-argument-to-grub-setup.patch @@ -0,0 +1,147 @@ +From fa856e9d6cce8cac8f55bb00392725961c264b8f Mon Sep 17 00:00:00 2001 +From: iliana destroyer of worlds +Date: Tue, 6 Aug 2019 17:37:19 +0000 +Subject: [PATCH] setup: Add root device argument to grub-setup + +This patch originates from the OpenWRT tree: +https://github.com/openwrt/openwrt/blob/65c8f2890ca4f41f5b933b5bc1e43de86cc1bd54/package/boot/grub2/patches/100-grub_setup_root.patch +--- + include/grub/util/install.h | 4 ++-- + util/grub-install.c | 4 ++-- + util/grub-setup.c | 12 +++++++++++- + util/setup.c | 10 +++++++--- + 4 files changed, 22 insertions(+), 8 deletions(-) + +[bcressey: updated for grub 2.06] +Signed-off-by: Ben Cressey + +diff --git a/include/grub/util/install.h b/include/grub/util/install.h +index 51f3b13..18cd28f 100644 +--- a/include/grub/util/install.h ++++ b/include/grub/util/install.h +@@ -205,13 +205,13 @@ grub_install_get_image_target (const char *arg); + void + grub_util_bios_setup (const char *dir, + const char *boot_file, const char *core_file, +- const char *dest, int force, ++ const char *root, const char *dest, int force, + int fs_probe, int allow_floppy, + int add_rs_codes, int warn_short_mbr_gap); + void + grub_util_sparc_setup (const char *dir, + const char *boot_file, const char *core_file, +- const char *dest, int force, ++ const char *root, const char *dest, int force, + int fs_probe, int allow_floppy, + int add_rs_codes, int warn_short_mbr_gap); + +diff --git a/util/grub-install.c b/util/grub-install.c +index 5babc7a..4233ac8 100644 +--- a/util/grub-install.c ++++ b/util/grub-install.c +@@ -1770,7 +1770,7 @@ main (int argc, char *argv[]) + if (install_bootsector) + { + grub_util_bios_setup (platdir, "boot.img", "core.img", +- install_drive, force, ++ NULL, install_drive, force, + fs_probe, allow_floppy, add_rs_codes, + !grub_install_is_short_mbrgap_supported ()); + +@@ -1801,7 +1801,7 @@ main (int argc, char *argv[]) + if (install_bootsector) + { + grub_util_sparc_setup (platdir, "boot.img", "core.img", +- install_drive, force, ++ NULL, install_drive, force, + fs_probe, allow_floppy, + 0 /* unused */, 0 /* unused */ ); + +diff --git a/util/grub-setup.c b/util/grub-setup.c +index 1783224..48cde49 100644 +--- a/util/grub-setup.c ++++ b/util/grub-setup.c +@@ -87,6 +87,8 @@ static struct argp_option options[] = { + N_("install even if problems are detected"), 0}, + {"skip-fs-probe",'s',0, 0, + N_("do not probe for filesystems in DEVICE"), 0}, ++ {"root-device", 'r', N_("DEVICE"), 0, ++ N_("use DEVICE as the root device"), 0}, + {"verbose", 'v', 0, 0, N_("print verbose messages."), 0}, + {"allow-floppy", 'a', 0, 0, + /* TRANSLATORS: The potential breakage isn't limited to floppies but it's +@@ -130,6 +132,7 @@ struct arguments + char *core_file; + char *dir; + char *dev_map; ++ char *root_dev; + int force; + int fs_probe; + int allow_floppy; +@@ -178,6 +181,13 @@ argp_parser (int key, char *arg, struct argp_state *state) + arguments->dev_map = xstrdup (arg); + break; + ++ case 'r': ++ if (arguments->root_dev) ++ free (arguments->root_dev); ++ ++ arguments->root_dev = xstrdup (arg); ++ break; ++ + case 'f': + arguments->force = 1; + break; +@@ -313,7 +323,7 @@ main (int argc, char *argv[]) + GRUB_SETUP_FUNC (arguments.dir ? : DEFAULT_DIRECTORY, + arguments.boot_file ? : DEFAULT_BOOT_FILE, + arguments.core_file ? : DEFAULT_CORE_FILE, +- dest_dev, arguments.force, ++ arguments.root_dev, dest_dev, arguments.force, + arguments.fs_probe, arguments.allow_floppy, + arguments.add_rs_codes, 0); + +diff --git a/util/setup.c b/util/setup.c +index 8b22bb8..960aeda 100644 +--- a/util/setup.c ++++ b/util/setup.c +@@ -252,14 +252,13 @@ identify_partmap (grub_disk_t disk __attribute__ ((unused)), + void + SETUP (const char *dir, + const char *boot_file, const char *core_file, +- const char *dest, int force, ++ const char *root, const char *dest, int force, + int fs_probe, int allow_floppy, + int add_rs_codes __attribute__ ((unused)), /* unused on sparc64 */ + int warn_small) + { + char *core_path; + char *boot_img, *core_img, *boot_path; +- char *root = 0; + size_t boot_size, core_size; + grub_uint16_t core_sectors; + grub_device_t root_dev = 0, dest_dev, core_dev; +@@ -311,7 +310,10 @@ SETUP (const char *dir, + + core_dev = dest_dev; + +- { ++ if (root) ++ root_dev = grub_device_open(root); ++ ++ if (!root_dev) { + char **root_devices = grub_guess_root_devices (dir); + char **cur; + int found = 0; +@@ -324,6 +326,8 @@ SETUP (const char *dir, + char *drive; + grub_device_t try_dev; + ++ if (root_dev) ++ break; + drive = grub_util_get_grub_dev (*cur); + if (!drive) + continue; +-- +2.21.3 + diff --git a/packages/grub/0002-gpt-start-new-GPT-module.patch b/packages/grub/0002-gpt-start-new-GPT-module.patch new file mode 100644 index 00000000..d6d32c88 --- /dev/null +++ b/packages/grub/0002-gpt-start-new-GPT-module.patch @@ -0,0 +1,923 @@ +From b0aec16d82a40c58ed47235c8b10612d07645eaa Mon Sep 17 00:00:00 2001 +From: Michael Marineau +Date: Sun, 28 Sep 2014 21:26:21 -0700 +Subject: [PATCH] gpt: start new GPT module + +This module is a new implementation for reading GUID Partition Tables +which is much stricter than the existing part_gpt module and exports GPT +data directly instead of the generic grub_partition structure. It will +be the basis for modules that need to read/write/update GPT data. + +The current code does nothing more than read and verify the table. +--- + Makefile.util.def | 16 ++ + grub-core/Makefile.core.def | 5 + + grub-core/lib/gpt.c | 288 +++++++++++++++++++++ + include/grub/gpt_partition.h | 60 +++++ + tests/gpt_unit_test.c | 467 +++++++++++++++++++++++++++++++++++ + 5 files changed, 836 insertions(+) + create mode 100644 grub-core/lib/gpt.c + create mode 100644 tests/gpt_unit_test.c + +diff --git a/Makefile.util.def b/Makefile.util.def +index 3f191aa..c7efe17 100644 +--- a/Makefile.util.def ++++ b/Makefile.util.def +@@ -1389,6 +1389,22 @@ program = { + ldadd = '$(LIBDEVMAPPER) $(LIBZFS) $(LIBNVPAIR) $(LIBGEOM)'; + }; + ++program = { ++ testcase; ++ name = gpt_unit_test; ++ common = tests/gpt_unit_test.c; ++ common = tests/lib/unit_test.c; ++ common = grub-core/disk/host.c; ++ common = grub-core/kern/emu/hostfs.c; ++ common = grub-core/lib/gpt.c; ++ common = grub-core/tests/lib/test.c; ++ ldadd = libgrubmods.a; ++ ldadd = libgrubgcry.a; ++ ldadd = libgrubkern.a; ++ ldadd = grub-core/gnulib/libgnu.a; ++ ldadd = '$(LIBDEVMAPPER) $(LIBZFS) $(LIBNVPAIR) $(LIBGEOM)'; ++}; ++ + program = { + name = grub-menulst2cfg; + mansection = 1; +diff --git a/grub-core/Makefile.core.def b/grub-core/Makefile.core.def +index 5212faf..e9cce06 100644 +--- a/grub-core/Makefile.core.def ++++ b/grub-core/Makefile.core.def +@@ -942,6 +942,11 @@ module = { + common = commands/gptsync.c; + }; + ++module = { ++ name = gpt; ++ common = lib/gpt.c; ++}; ++ + module = { + name = halt; + nopc = commands/halt.c; +diff --git a/grub-core/lib/gpt.c b/grub-core/lib/gpt.c +new file mode 100644 +index 0000000..a308e85 +--- /dev/null ++++ b/grub-core/lib/gpt.c +@@ -0,0 +1,288 @@ ++/* gpt.c - Read/Verify/Write GUID Partition Tables (GPT). */ ++/* ++ * GRUB -- GRand Unified Bootloader ++ * Copyright (C) 2002,2005,2006,2007,2008 Free Software Foundation, Inc. ++ * Copyright (C) 2014 CoreOS, Inc. ++ * ++ * GRUB is free software: you can redistribute it and/or modify ++ * it under the terms of the GNU General Public License as published by ++ * the Free Software Foundation, either version 3 of the License, or ++ * (at your option) any later version. ++ * ++ * GRUB is distributed in the hope that it will be useful, ++ * but WITHOUT ANY WARRANTY; without even the implied warranty of ++ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++ * GNU General Public License for more details. ++ * ++ * You should have received a copy of the GNU General Public License ++ * along with GRUB. If not, see . ++ */ ++ ++#include ++#include ++#include ++#include ++#include ++#include ++#include ++ ++GRUB_MOD_LICENSE ("GPLv3+"); ++ ++static grub_uint8_t grub_gpt_magic[] = GRUB_GPT_HEADER_MAGIC; ++ ++ ++static grub_err_t ++grub_gpt_header_crc32 (struct grub_gpt_header *gpt, grub_uint32_t *crc) ++{ ++ grub_uint8_t *crc32_context; ++ grub_uint32_t old; ++ ++ crc32_context = grub_zalloc (GRUB_MD_CRC32->contextsize); ++ if (!crc32_context) ++ return grub_errno; ++ ++ /* crc32 must be computed with the field cleared. */ ++ old = gpt->crc32; ++ gpt->crc32 = 0; ++ GRUB_MD_CRC32->init (crc32_context); ++ GRUB_MD_CRC32->write (crc32_context, gpt, sizeof (*gpt)); ++ GRUB_MD_CRC32->final (crc32_context); ++ gpt->crc32 = old; ++ ++ /* GRUB_MD_CRC32 always uses big endian, gpt is always little. */ ++ *crc = grub_swap_bytes32 (*(grub_uint32_t *) ++ GRUB_MD_CRC32->read (crc32_context)); ++ ++ grub_free (crc32_context); ++ ++ return GRUB_ERR_NONE; ++} ++ ++/* Make sure the MBR is a protective MBR and not a normal MBR. */ ++grub_err_t ++grub_gpt_pmbr_check (struct grub_msdos_partition_mbr *mbr) ++{ ++ unsigned int i; ++ ++ if (mbr->signature != ++ grub_cpu_to_le16_compile_time (GRUB_PC_PARTITION_SIGNATURE)) ++ return grub_error (GRUB_ERR_BAD_PART_TABLE, "invalid MBR signature"); ++ ++ for (i = 0; i < sizeof (mbr->entries); i++) ++ if (mbr->entries[i].type == GRUB_PC_PARTITION_TYPE_GPT_DISK) ++ return GRUB_ERR_NONE; ++ ++ return grub_error (GRUB_ERR_BAD_PART_TABLE, "invalid protective MBR"); ++} ++ ++grub_err_t ++grub_gpt_header_check (struct grub_gpt_header *gpt, ++ unsigned int log_sector_size) ++{ ++ grub_uint32_t crc = 0, size; ++ ++ if (grub_memcmp (gpt->magic, grub_gpt_magic, sizeof (grub_gpt_magic)) != 0) ++ return grub_error (GRUB_ERR_BAD_PART_TABLE, "invalid GPT signature"); ++ ++ if (gpt->version != GRUB_GPT_HEADER_VERSION) ++ return grub_error (GRUB_ERR_BAD_PART_TABLE, "unknown GPT version"); ++ ++ if (grub_gpt_header_crc32 (gpt, &crc)) ++ return grub_errno; ++ ++ if (gpt->crc32 != crc) ++ return grub_error (GRUB_ERR_BAD_PART_TABLE, "invalid GPT header crc32"); ++ ++ /* The header size must be between 92 and the sector size. */ ++ size = grub_le_to_cpu32 (gpt->headersize); ++ if (size < 92U || size > (1U << log_sector_size)) ++ return grub_error (GRUB_ERR_BAD_PART_TABLE, "invalid GPT header size"); ++ ++ /* The partition entry size must be a multiple of 128. */ ++ size = grub_le_to_cpu32 (gpt->partentry_size); ++ if (size < 128 || size % 128) ++ return grub_error (GRUB_ERR_BAD_PART_TABLE, "invalid GPT entry size"); ++ ++ return GRUB_ERR_NONE; ++} ++ ++static grub_err_t ++grub_gpt_read_primary (grub_disk_t disk, grub_gpt_t gpt) ++{ ++ grub_disk_addr_t addr; ++ ++ /* TODO: The gpt partmap module searches for the primary header instead ++ * of relying on the disk's sector size. For now trust the disk driver ++ * but eventually this code should match the existing behavior. */ ++ gpt->log_sector_size = disk->log_sector_size; ++ ++ addr = grub_gpt_sector_to_addr (gpt, 1); ++ if (grub_disk_read (disk, addr, 0, sizeof (gpt->primary), &gpt->primary)) ++ return grub_errno; ++ ++ if (grub_gpt_header_check (&gpt->primary, gpt->log_sector_size)) ++ return grub_errno; ++ ++ gpt->status |= GRUB_GPT_PRIMARY_HEADER_VALID; ++ return GRUB_ERR_NONE; ++} ++ ++static grub_err_t ++grub_gpt_read_backup (grub_disk_t disk, grub_gpt_t gpt) ++{ ++ grub_uint64_t sector; ++ grub_disk_addr_t addr; ++ ++ /* Assumes gpt->log_sector_size == disk->log_sector_size */ ++ if (disk->total_sectors != GRUB_DISK_SIZE_UNKNOWN) ++ sector = disk->total_sectors - 1; ++ else if (gpt->status & GRUB_GPT_PRIMARY_HEADER_VALID) ++ sector = grub_le_to_cpu64 (gpt->primary.backup); ++ else ++ return grub_error (GRUB_ERR_NOT_IMPLEMENTED_YET, ++ "Unable to locate backup GPT"); ++ ++ addr = grub_gpt_sector_to_addr (gpt, sector); ++ if (grub_disk_read (disk, addr, 0, sizeof (gpt->backup), &gpt->backup)) ++ return grub_errno; ++ ++ if (grub_gpt_header_check (&gpt->backup, gpt->log_sector_size)) ++ return grub_errno; ++ ++ gpt->status |= GRUB_GPT_BACKUP_HEADER_VALID; ++ return GRUB_ERR_NONE; ++} ++ ++static struct grub_gpt_partentry * ++grub_gpt_read_entries (grub_disk_t disk, grub_gpt_t gpt, ++ struct grub_gpt_header *header) ++{ ++ struct grub_gpt_partentry *entries = NULL; ++ grub_uint8_t *crc32_context = NULL; ++ grub_uint32_t count, size, crc; ++ grub_disk_addr_t addr; ++ grub_size_t entries_size; ++ ++ /* Grub doesn't include calloc, hence the manual overflow check. */ ++ count = grub_le_to_cpu32 (header->maxpart); ++ size = grub_le_to_cpu32 (header->partentry_size); ++ entries_size = count *size; ++ if (size && entries_size / size != count) ++ { ++ grub_error (GRUB_ERR_OUT_OF_MEMORY, N_("out of memory")); ++ goto fail; ++ } ++ ++ entries = grub_malloc (entries_size); ++ if (!entries) ++ goto fail; ++ ++ addr = grub_gpt_sector_to_addr (gpt, grub_le_to_cpu64 (header->partitions)); ++ if (grub_disk_read (disk, addr, 0, entries_size, entries)) ++ goto fail; ++ ++ crc32_context = grub_zalloc (GRUB_MD_CRC32->contextsize); ++ if (!crc32_context) ++ goto fail; ++ ++ GRUB_MD_CRC32->init (crc32_context); ++ GRUB_MD_CRC32->write (crc32_context, entries, entries_size); ++ GRUB_MD_CRC32->final (crc32_context); ++ ++ crc = *(grub_uint32_t *) GRUB_MD_CRC32->read (crc32_context); ++ if (grub_swap_bytes32 (crc) != header->partentry_crc32) ++ { ++ grub_error (GRUB_ERR_BAD_PART_TABLE, "invalid GPT entry crc32"); ++ goto fail; ++ } ++ ++ grub_free (crc32_context); ++ return entries; ++ ++fail: ++ grub_free (entries); ++ grub_free (crc32_context); ++ return NULL; ++} ++ ++grub_gpt_t ++grub_gpt_read (grub_disk_t disk) ++{ ++ grub_gpt_t gpt; ++ struct grub_gpt_partentry *backup_entries; ++ ++ gpt = grub_zalloc (sizeof (*gpt)); ++ if (!gpt) ++ goto fail; ++ ++ if (grub_disk_read (disk, 0, 0, sizeof (gpt->mbr), &gpt->mbr)) ++ goto fail; ++ ++ /* Check the MBR but errors aren't reported beyond the status bit. */ ++ if (grub_gpt_pmbr_check (&gpt->mbr)) ++ grub_errno = GRUB_ERR_NONE; ++ else ++ gpt->status |= GRUB_GPT_PROTECTIVE_MBR; ++ ++ /* If both the primary and backup fail report the primary's error. */ ++ if (grub_gpt_read_primary (disk, gpt)) ++ { ++ grub_error_push (); ++ grub_gpt_read_backup (disk, gpt); ++ grub_error_pop (); ++ } ++ else ++ grub_gpt_read_backup (disk, gpt); ++ ++ /* If either succeeded clear any possible error from the other. */ ++ if (gpt->status & GRUB_GPT_PRIMARY_HEADER_VALID || ++ gpt->status & GRUB_GPT_BACKUP_HEADER_VALID) ++ grub_errno = GRUB_ERR_NONE; ++ else ++ goto fail; ++ ++ /* Same error handling scheme for the entry tables. */ ++ gpt->entries = grub_gpt_read_entries (disk, gpt, &gpt->primary); ++ if (!gpt->entries) ++ { ++ grub_error_push (); ++ backup_entries = grub_gpt_read_entries (disk, gpt, &gpt->backup); ++ grub_error_pop (); ++ } ++ else ++ { ++ gpt->status |= GRUB_GPT_PRIMARY_ENTRIES_VALID; ++ backup_entries = grub_gpt_read_entries (disk, gpt, &gpt->backup); ++ } ++ ++ if (backup_entries) ++ { ++ gpt->status |= GRUB_GPT_BACKUP_ENTRIES_VALID; ++ ++ if (gpt->status & GRUB_GPT_PRIMARY_ENTRIES_VALID) ++ grub_free (backup_entries); ++ else ++ gpt->entries = backup_entries; ++ } ++ ++ if (gpt->status & GRUB_GPT_PRIMARY_ENTRIES_VALID || ++ gpt->status & GRUB_GPT_BACKUP_ENTRIES_VALID) ++ { ++ grub_errno = GRUB_ERR_NONE; ++ return gpt; ++ } ++ ++fail: ++ grub_gpt_free (gpt); ++ return NULL; ++} ++ ++void ++grub_gpt_free (grub_gpt_t gpt) ++{ ++ if (!gpt) ++ return; ++ ++ grub_free (gpt->entries); ++ grub_free (gpt); ++} +diff --git a/include/grub/gpt_partition.h b/include/grub/gpt_partition.h +index 8212697..8cffe16 100644 +--- a/include/grub/gpt_partition.h ++++ b/include/grub/gpt_partition.h +@@ -21,6 +21,7 @@ + + #include + #include ++#include + + struct grub_gpt_part_guid + { +@@ -50,6 +51,12 @@ typedef struct grub_gpt_part_guid grub_gpt_part_guid_t; + { 0x85, 0xD2, 0xE1, 0xE9, 0x04, 0x34, 0xCF, 0xB3 } \ + } + ++#define GRUB_GPT_HEADER_MAGIC \ ++ { 0x45, 0x46, 0x49, 0x20, 0x50, 0x41, 0x52, 0x54 } ++ ++#define GRUB_GPT_HEADER_VERSION \ ++ grub_cpu_to_le32_compile_time (0x00010000U) ++ + struct grub_gpt_header + { + grub_uint8_t magic[8]; +@@ -78,10 +85,63 @@ struct grub_gpt_partentry + char name[72]; + } GRUB_PACKED __attribute__ ((aligned(8))); + ++/* Basic GPT partmap module. */ + grub_err_t + grub_gpt_partition_map_iterate (grub_disk_t disk, + grub_partition_iterate_hook_t hook, + void *hook_data); + ++/* Advanced GPT library. */ ++typedef enum grub_gpt_status ++ { ++ GRUB_GPT_PROTECTIVE_MBR = 0x01, ++ GRUB_GPT_HYBRID_MBR = 0x02, ++ GRUB_GPT_PRIMARY_HEADER_VALID = 0x04, ++ GRUB_GPT_PRIMARY_ENTRIES_VALID = 0x08, ++ GRUB_GPT_BACKUP_HEADER_VALID = 0x10, ++ GRUB_GPT_BACKUP_ENTRIES_VALID = 0x20, ++ } grub_gpt_status_t; ++ ++#define GRUB_GPT_MBR_VALID (GRUB_GPT_PROTECTIVE_MBR|GRUB_GPT_HYBRID_MBR) ++ ++/* UEFI requires the entries table to be at least 16384 bytes for a ++ * total of 128 entries given the standard 128 byte entry size. */ ++#define GRUB_GPT_DEFAULT_ENTRIES_LENGTH 128 ++ ++struct grub_gpt ++{ ++ /* Bit field indicating which structures on disk are valid. */ ++ grub_gpt_status_t status; ++ ++ /* Protective or hybrid MBR. */ ++ struct grub_msdos_partition_mbr mbr; ++ ++ /* Each of the two GPT headers. */ ++ struct grub_gpt_header primary; ++ struct grub_gpt_header backup; ++ ++ /* Only need one entries table, on disk both copies are identical. */ ++ struct grub_gpt_partentry *entries; ++ ++ /* Logarithm of sector size, in case GPT and disk driver disagree. */ ++ unsigned int log_sector_size; ++}; ++typedef struct grub_gpt *grub_gpt_t; ++ ++/* Translate GPT sectors to GRUB's 512 byte block addresses. */ ++static inline grub_disk_addr_t ++grub_gpt_sector_to_addr (grub_gpt_t gpt, grub_uint64_t sector) ++{ ++ return (sector << (gpt->log_sector_size - GRUB_DISK_SECTOR_BITS)); ++} ++ ++/* Allocates and fills new grub_gpt structure, free with grub_gpt_free. */ ++grub_gpt_t grub_gpt_read (grub_disk_t disk); ++ ++void grub_gpt_free (grub_gpt_t gpt); ++ ++grub_err_t grub_gpt_pmbr_check (struct grub_msdos_partition_mbr *mbr); ++grub_err_t grub_gpt_header_check (struct grub_gpt_header *gpt, ++ unsigned int log_sector_size); + + #endif /* ! GRUB_GPT_PARTITION_HEADER */ +diff --git a/tests/gpt_unit_test.c b/tests/gpt_unit_test.c +new file mode 100644 +index 0000000..a824cd9 +--- /dev/null ++++ b/tests/gpt_unit_test.c +@@ -0,0 +1,467 @@ ++/* ++ * GRUB -- GRand Unified Bootloader ++ * Copyright (C) 2014 CoreOS, Inc. ++ * ++ * GRUB is free software: you can redistribute it and/or modify ++ * it under the terms of the GNU General Public License as published by ++ * the Free Software Foundation, either version 3 of the License, or ++ * (at your option) any later version. ++ * ++ * GRUB is distributed in the hope that it will be useful, ++ * but WITHOUT ANY WARRANTY; without even the implied warranty of ++ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++ * GNU General Public License for more details. ++ * ++ * You should have received a copy of the GNU General Public License ++ * along with GRUB. If not, see . ++ */ ++ ++#include ++#include ++#include ++#include ++#include ++#include ++#include ++#include ++#include ++ ++#include ++#include ++#include ++#include ++#include ++#include ++#include ++ ++/* from gnulib */ ++#include ++ ++ ++/* GPT section sizes. */ ++#define HEADER_SIZE (sizeof (struct grub_gpt_header)) ++#define HEADER_PAD (GRUB_DISK_SECTOR_SIZE - HEADER_SIZE) ++#define ENTRY_SIZE (sizeof (struct grub_gpt_partentry)) ++#define TABLE_ENTRIES 0x80 ++#define TABLE_SIZE (TABLE_ENTRIES * ENTRY_SIZE) ++#define TABLE_SECTORS (TABLE_SIZE / GRUB_DISK_SECTOR_SIZE) ++ ++/* Double check that the table size calculation was valid. */ ++verify (TABLE_SECTORS * GRUB_DISK_SECTOR_SIZE == TABLE_SIZE); ++ ++/* GPT section locations for a 1MiB disk. */ ++#define DISK_SECTORS 0x800 ++#define DISK_SIZE (GRUB_DISK_SECTOR_SIZE * DISK_SECTORS) ++#define PRIMARY_HEADER_SECTOR 0x1 ++#define PRIMARY_TABLE_SECTOR 0x2 ++#define BACKUP_HEADER_SECTOR (DISK_SECTORS - 0x1) ++#define BACKUP_TABLE_SECTOR (BACKUP_HEADER_SECTOR - TABLE_SECTORS) ++ ++#define DATA_START_SECTOR (PRIMARY_TABLE_SECTOR + TABLE_SECTORS) ++#define DATA_END_SECTOR (BACKUP_TABLE_SECTOR - 0x1) ++#define DATA_SECTORS (BACKUP_TABLE_SECTOR - DATA_START_SECTOR) ++#define DATA_SIZE (GRUB_DISK_SECTOR_SIZE * DATA_SECTORS) ++ ++struct test_disk ++{ ++ struct grub_msdos_partition_mbr mbr; ++ ++ struct grub_gpt_header primary_header; ++ grub_uint8_t primary_header_pad[HEADER_PAD]; ++ struct grub_gpt_partentry primary_entries[TABLE_ENTRIES]; ++ ++ grub_uint8_t data[DATA_SIZE]; ++ ++ struct grub_gpt_partentry backup_entries[TABLE_ENTRIES]; ++ struct grub_gpt_header backup_header; ++ grub_uint8_t backup_header_pad[HEADER_PAD]; ++} GRUB_PACKED; ++ ++/* Sanity check that all the above ugly math was correct. */ ++verify (sizeof (struct test_disk) == DISK_SIZE); ++ ++struct test_data ++{ ++ int fd; ++ grub_device_t dev; ++ struct test_disk *raw; ++}; ++ ++ ++/* Sample primary GPT header for an empty 1MB disk. */ ++static const struct grub_gpt_header example_primary = { ++ .magic = GRUB_GPT_HEADER_MAGIC, ++ .version = GRUB_GPT_HEADER_VERSION, ++ .headersize = sizeof (struct grub_gpt_header), ++ .crc32 = grub_cpu_to_le32_compile_time (0x7cd8642c), ++ .primary = grub_cpu_to_le64_compile_time (PRIMARY_HEADER_SECTOR), ++ .backup = grub_cpu_to_le64_compile_time (BACKUP_HEADER_SECTOR), ++ .start = grub_cpu_to_le64_compile_time (DATA_START_SECTOR), ++ .end = grub_cpu_to_le64_compile_time (DATA_END_SECTOR), ++ .guid = {0xad, 0x31, 0xc1, 0x69, 0xd6, 0x67, 0xc6, 0x46, ++ 0x93, 0xc4, 0x12, 0x4c, 0x75, 0x52, 0x56, 0xac}, ++ .partitions = grub_cpu_to_le64_compile_time (PRIMARY_TABLE_SECTOR), ++ .maxpart = grub_cpu_to_le32_compile_time (TABLE_ENTRIES), ++ .partentry_size = grub_cpu_to_le32_compile_time (ENTRY_SIZE), ++ .partentry_crc32 = grub_cpu_to_le32_compile_time (0xab54d286), ++}; ++ ++/* And the backup header. */ ++static const struct grub_gpt_header example_backup = { ++ .magic = GRUB_GPT_HEADER_MAGIC, ++ .version = GRUB_GPT_HEADER_VERSION, ++ .headersize = sizeof (struct grub_gpt_header), ++ .crc32 = grub_cpu_to_le32_compile_time (0xcfaa4a27), ++ .primary = grub_cpu_to_le64_compile_time (BACKUP_HEADER_SECTOR), ++ .backup = grub_cpu_to_le64_compile_time (PRIMARY_HEADER_SECTOR), ++ .start = grub_cpu_to_le64_compile_time (DATA_START_SECTOR), ++ .end = grub_cpu_to_le64_compile_time (DATA_END_SECTOR), ++ .guid = {0xad, 0x31, 0xc1, 0x69, 0xd6, 0x67, 0xc6, 0x46, ++ 0x93, 0xc4, 0x12, 0x4c, 0x75, 0x52, 0x56, 0xac}, ++ .partitions = grub_cpu_to_le64_compile_time (BACKUP_TABLE_SECTOR), ++ .maxpart = grub_cpu_to_le32_compile_time (TABLE_ENTRIES), ++ .partentry_size = grub_cpu_to_le32_compile_time (ENTRY_SIZE), ++ .partentry_crc32 = grub_cpu_to_le32_compile_time (0xab54d286), ++}; ++ ++/* Sample protective MBR for the same 1MB disk. Note, this matches ++ * parted and fdisk behavior. The UEFI spec uses different values. */ ++static const struct grub_msdos_partition_mbr example_pmbr = { ++ .entries = {{.flag = 0x00, ++ .start_head = 0x00, ++ .start_sector = 0x01, ++ .start_cylinder = 0x00, ++ .type = 0xee, ++ .end_head = 0xfe, ++ .end_sector = 0xff, ++ .end_cylinder = 0xff, ++ .start = grub_cpu_to_le32_compile_time (0x1), ++ .length = grub_cpu_to_le32_compile_time (DISK_SECTORS - 0x1), ++ }}, ++ .signature = grub_cpu_to_le16_compile_time (GRUB_PC_PARTITION_SIGNATURE), ++}; ++ ++/* If errors are left in grub's error stack things can get confused. */ ++static void ++assert_error_stack_empty (void) ++{ ++ do ++ { ++ grub_test_assert (grub_errno == GRUB_ERR_NONE, ++ "error on stack: %s", grub_errmsg); ++ } ++ while (grub_error_pop ()); ++} ++ ++static grub_err_t ++execute_command2 (const char *name, const char *arg1, const char *arg2) ++{ ++ grub_command_t cmd; ++ grub_err_t err; ++ char *argv[2]; ++ ++ cmd = grub_command_find (name); ++ if (!cmd) ++ grub_fatal ("can't find command %s", name); ++ ++ argv[0] = strdup (arg1); ++ argv[1] = strdup (arg2); ++ err = (cmd->func) (cmd, 2, argv); ++ free (argv[0]); ++ free (argv[1]); ++ ++ return err; ++} ++ ++static void ++sync_disk (struct test_data *data) ++{ ++ if (msync (data->raw, DISK_SIZE, MS_SYNC | MS_INVALIDATE) < 0) ++ grub_fatal ("Syncing disk failed: %s", strerror (errno)); ++ ++ grub_disk_cache_invalidate_all (); ++} ++ ++static void ++reset_disk (struct test_data *data) ++{ ++ memset (data->raw, 0, DISK_SIZE); ++ ++ /* Initialize image with valid example tables. */ ++ memcpy (&data->raw->mbr, &example_pmbr, sizeof (data->raw->mbr)); ++ memcpy (&data->raw->primary_header, &example_primary, ++ sizeof (data->raw->primary_header)); ++ memcpy (&data->raw->backup_header, &example_backup, ++ sizeof (data->raw->backup_header)); ++ ++ sync_disk (data); ++} ++ ++static void ++open_disk (struct test_data *data) ++{ ++ const char *loop = "loop0"; ++ char template[] = "/tmp/grub_gpt_test.XXXXXX"; ++ char host[sizeof ("(host)") + sizeof (template)]; ++ ++ data->fd = mkstemp (template); ++ if (data->fd < 0) ++ grub_fatal ("Creating %s failed: %s", template, strerror (errno)); ++ ++ if (ftruncate (data->fd, DISK_SIZE) < 0) ++ { ++ int err = errno; ++ unlink (template); ++ grub_fatal ("Resizing %s failed: %s", template, strerror (err)); ++ } ++ ++ data->raw = mmap (NULL, DISK_SIZE, PROT_READ | PROT_WRITE, ++ MAP_SHARED, data->fd, 0); ++ if (data->raw == MAP_FAILED) ++ { ++ int err = errno; ++ unlink (template); ++ grub_fatal ("Maping %s failed: %s", template, strerror (err)); ++ } ++ ++ snprintf (host, sizeof (host), "(host)%s", template); ++ if (execute_command2 ("loopback", loop, host) != GRUB_ERR_NONE) ++ { ++ unlink (template); ++ grub_fatal ("loopback %s %s failed: %s", loop, host, grub_errmsg); ++ } ++ ++ if (unlink (template) < 0) ++ grub_fatal ("Unlinking %s failed: %s", template, strerror (errno)); ++ ++ reset_disk (data); ++ ++ data->dev = grub_device_open (loop); ++ if (!data->dev) ++ grub_fatal ("Opening %s failed: %s", loop, grub_errmsg); ++} ++ ++static void ++close_disk (struct test_data *data) ++{ ++ char *loop; ++ ++ assert_error_stack_empty (); ++ ++ if (munmap (data->raw, DISK_SIZE) || close (data->fd)) ++ grub_fatal ("Closing disk image failed: %s", strerror (errno)); ++ ++ loop = strdup (data->dev->disk->name); ++ grub_test_assert (grub_device_close (data->dev) == GRUB_ERR_NONE, ++ "Closing disk device failed: %s", grub_errmsg); ++ ++ grub_test_assert (execute_command2 ("loopback", "-d", loop) == ++ GRUB_ERR_NONE, "loopback -d %s failed: %s", loop, ++ grub_errmsg); ++ ++ free (loop); ++} ++ ++static grub_gpt_t ++read_disk (struct test_data *data) ++{ ++ grub_gpt_t gpt; ++ ++ gpt = grub_gpt_read (data->dev->disk); ++ if (gpt == NULL) ++ { ++ grub_print_error (); ++ grub_fatal ("grub_gpt_read failed"); ++ } ++ ++ ++ return gpt; ++} ++ ++static void ++pmbr_test (void) ++{ ++ struct grub_msdos_partition_mbr mbr; ++ ++ memset (&mbr, 0, sizeof (mbr)); ++ ++ /* Empty is invalid. */ ++ grub_gpt_pmbr_check (&mbr); ++ grub_test_assert (grub_errno == GRUB_ERR_BAD_PART_TABLE, ++ "unexpected error: %s", grub_errmsg); ++ grub_errno = GRUB_ERR_NONE; ++ ++ /* A table without a protective partition is invalid. */ ++ mbr.signature = grub_cpu_to_le16_compile_time (GRUB_PC_PARTITION_SIGNATURE); ++ grub_gpt_pmbr_check (&mbr); ++ grub_test_assert (grub_errno == GRUB_ERR_BAD_PART_TABLE, ++ "unexpected error: %s", grub_errmsg); ++ grub_errno = GRUB_ERR_NONE; ++ ++ /* A table with a protective type is ok. */ ++ memcpy (&mbr, &example_pmbr, sizeof (mbr)); ++ grub_gpt_pmbr_check (&mbr); ++ grub_test_assert (grub_errno == GRUB_ERR_NONE, ++ "unexpected error: %s", grub_errmsg); ++ grub_errno = GRUB_ERR_NONE; ++} ++ ++static void ++header_test (void) ++{ ++ struct grub_gpt_header primary, backup; ++ ++ /* Example headers should be valid. */ ++ memcpy (&primary, &example_primary, sizeof (primary)); ++ grub_gpt_header_check (&primary, GRUB_DISK_SECTOR_BITS); ++ grub_test_assert (grub_errno == GRUB_ERR_NONE, ++ "unexpected error: %s", grub_errmsg); ++ grub_errno = GRUB_ERR_NONE; ++ ++ memcpy (&backup, &example_backup, sizeof (backup)); ++ grub_gpt_header_check (&backup, GRUB_DISK_SECTOR_BITS); ++ grub_test_assert (grub_errno == GRUB_ERR_NONE, ++ "unexpected error: %s", grub_errmsg); ++ grub_errno = GRUB_ERR_NONE; ++ ++ /* Twiddle the GUID to invalidate the CRC. */ ++ primary.guid[0] = 0; ++ grub_gpt_header_check (&primary, GRUB_DISK_SECTOR_BITS); ++ grub_test_assert (grub_errno == GRUB_ERR_BAD_PART_TABLE, ++ "unexpected error: %s", grub_errmsg); ++ grub_errno = GRUB_ERR_NONE; ++ ++ backup.guid[0] = 0; ++ grub_gpt_header_check (&backup, GRUB_DISK_SECTOR_BITS); ++ grub_test_assert (grub_errno == GRUB_ERR_BAD_PART_TABLE, ++ "unexpected error: %s", grub_errmsg); ++ grub_errno = GRUB_ERR_NONE; ++} ++ ++static void ++read_valid_test (void) ++{ ++ struct test_data data; ++ grub_gpt_t gpt; ++ ++ open_disk (&data); ++ gpt = read_disk (&data); ++ grub_test_assert (gpt->status == (GRUB_GPT_PROTECTIVE_MBR | ++ GRUB_GPT_PRIMARY_HEADER_VALID | ++ GRUB_GPT_PRIMARY_ENTRIES_VALID | ++ GRUB_GPT_BACKUP_HEADER_VALID | ++ GRUB_GPT_BACKUP_ENTRIES_VALID), ++ "unexpected status: 0x%02x", gpt->status); ++ grub_gpt_free (gpt); ++ close_disk (&data); ++} ++ ++static void ++read_invalid_entries_test (void) ++{ ++ struct test_data data; ++ grub_gpt_t gpt; ++ ++ open_disk (&data); ++ ++ /* Corrupt the first entry in both tables. */ ++ memset (&data.raw->primary_entries[0], 0x55, ++ sizeof (data.raw->primary_entries[0])); ++ memset (&data.raw->backup_entries[0], 0x55, ++ sizeof (data.raw->backup_entries[0])); ++ sync_disk (&data); ++ ++ gpt = grub_gpt_read (data.dev->disk); ++ grub_test_assert (gpt == NULL, "no error reported for corrupt entries"); ++ grub_test_assert (grub_errno == GRUB_ERR_BAD_PART_TABLE, ++ "unexpected error: %s", grub_errmsg); ++ grub_errno = GRUB_ERR_NONE; ++ ++ close_disk (&data); ++} ++ ++static void ++read_fallback_test (void) ++{ ++ struct test_data data; ++ grub_gpt_t gpt; ++ ++ open_disk (&data); ++ ++ /* Corrupt the primary header. */ ++ memset (&data.raw->primary_header.guid, 0x55, ++ sizeof (data.raw->primary_header.guid)); ++ sync_disk (&data); ++ gpt = read_disk (&data); ++ grub_test_assert ((gpt->status & GRUB_GPT_PRIMARY_HEADER_VALID) == 0, ++ "unreported corrupt primary header"); ++ grub_gpt_free (gpt); ++ reset_disk (&data); ++ ++ /* Corrupt the backup header. */ ++ memset (&data.raw->backup_header.guid, 0x55, ++ sizeof (data.raw->backup_header.guid)); ++ sync_disk (&data); ++ gpt = read_disk (&data); ++ grub_test_assert ((gpt->status & GRUB_GPT_BACKUP_HEADER_VALID) == 0, ++ "unreported corrupt backup header"); ++ grub_gpt_free (gpt); ++ reset_disk (&data); ++ ++ /* Corrupt the primary entry table. */ ++ memset (&data.raw->primary_entries[0], 0x55, ++ sizeof (data.raw->primary_entries[0])); ++ sync_disk (&data); ++ gpt = read_disk (&data); ++ grub_test_assert ((gpt->status & GRUB_GPT_PRIMARY_ENTRIES_VALID) == 0, ++ "unreported corrupt primary entries table"); ++ grub_gpt_free (gpt); ++ reset_disk (&data); ++ ++ /* Corrupt the backup entry table. */ ++ memset (&data.raw->backup_entries[0], 0x55, ++ sizeof (data.raw->backup_entries[0])); ++ sync_disk (&data); ++ gpt = read_disk (&data); ++ grub_test_assert ((gpt->status & GRUB_GPT_BACKUP_ENTRIES_VALID) == 0, ++ "unreported corrupt backup entries table"); ++ grub_gpt_free (gpt); ++ reset_disk (&data); ++ ++ /* If primary is corrupt and disk size is unknown fallback fails. */ ++ memset (&data.raw->primary_header.guid, 0x55, ++ sizeof (data.raw->primary_header.guid)); ++ sync_disk (&data); ++ data.dev->disk->total_sectors = GRUB_DISK_SIZE_UNKNOWN; ++ gpt = grub_gpt_read (data.dev->disk); ++ grub_test_assert (gpt == NULL, "no error reported"); ++ grub_test_assert (grub_errno == GRUB_ERR_BAD_PART_TABLE, ++ "unexpected error: %s", grub_errmsg); ++ grub_errno = GRUB_ERR_NONE; ++ ++ close_disk (&data); ++} ++ ++void ++grub_unit_test_init (void) ++{ ++ grub_init_all (); ++ grub_hostfs_init (); ++ grub_host_init (); ++ grub_test_register ("gpt_pmbr_test", pmbr_test); ++ grub_test_register ("gpt_header_test", header_test); ++ grub_test_register ("gpt_read_valid_test", read_valid_test); ++ grub_test_register ("gpt_read_invalid_test", read_invalid_entries_test); ++ grub_test_register ("gpt_read_fallback_test", read_fallback_test); ++} ++ ++void ++grub_unit_test_fini (void) ++{ ++ grub_test_unregister ("gpt_pmbr_test"); ++ grub_test_unregister ("gpt_header_test"); ++ grub_test_unregister ("gpt_read_valid_test"); ++ grub_test_unregister ("gpt_read_invalid_test"); ++ grub_test_unregister ("gpt_read_fallback_test"); ++ grub_fini_all (); ++} +-- +2.36.1 + diff --git a/packages/grub/0003-gpt-rename-misnamed-header-location-fields.patch b/packages/grub/0003-gpt-rename-misnamed-header-location-fields.patch new file mode 100644 index 00000000..d6351a56 --- /dev/null +++ b/packages/grub/0003-gpt-rename-misnamed-header-location-fields.patch @@ -0,0 +1,71 @@ +From 7bf95046b9123cd7d57df6dee81cbbd75ca722f6 Mon Sep 17 00:00:00 2001 +From: Michael Marineau +Date: Sat, 18 Oct 2014 15:39:13 -0700 +Subject: [PATCH] gpt: rename misnamed header location fields + +The header location fields refer to 'this header' and 'alternate header' +respectively, not 'primary header' and 'backup header'. The previous +field names are backwards for the backup header. +--- + grub-core/lib/gpt.c | 2 +- + include/grub/gpt_partition.h | 4 ++-- + tests/gpt_unit_test.c | 8 ++++---- + 3 files changed, 7 insertions(+), 7 deletions(-) + +diff --git a/grub-core/lib/gpt.c b/grub-core/lib/gpt.c +index a308e85..705bd77 100644 +--- a/grub-core/lib/gpt.c ++++ b/grub-core/lib/gpt.c +@@ -137,7 +137,7 @@ grub_gpt_read_backup (grub_disk_t disk, grub_gpt_t gpt) + if (disk->total_sectors != GRUB_DISK_SIZE_UNKNOWN) + sector = disk->total_sectors - 1; + else if (gpt->status & GRUB_GPT_PRIMARY_HEADER_VALID) +- sector = grub_le_to_cpu64 (gpt->primary.backup); ++ sector = grub_le_to_cpu64 (gpt->primary.alternate_lba); + else + return grub_error (GRUB_ERR_NOT_IMPLEMENTED_YET, + "Unable to locate backup GPT"); +diff --git a/include/grub/gpt_partition.h b/include/grub/gpt_partition.h +index 8cffe16..1101d85 100644 +--- a/include/grub/gpt_partition.h ++++ b/include/grub/gpt_partition.h +@@ -64,8 +64,8 @@ struct grub_gpt_header + grub_uint32_t headersize; + grub_uint32_t crc32; + grub_uint32_t unused1; +- grub_uint64_t primary; +- grub_uint64_t backup; ++ grub_uint64_t header_lba; ++ grub_uint64_t alternate_lba; + grub_uint64_t start; + grub_uint64_t end; + grub_uint8_t guid[16]; +diff --git a/tests/gpt_unit_test.c b/tests/gpt_unit_test.c +index a824cd9..4d70868 100644 +--- a/tests/gpt_unit_test.c ++++ b/tests/gpt_unit_test.c +@@ -94,8 +94,8 @@ static const struct grub_gpt_header example_primary = { + .version = GRUB_GPT_HEADER_VERSION, + .headersize = sizeof (struct grub_gpt_header), + .crc32 = grub_cpu_to_le32_compile_time (0x7cd8642c), +- .primary = grub_cpu_to_le64_compile_time (PRIMARY_HEADER_SECTOR), +- .backup = grub_cpu_to_le64_compile_time (BACKUP_HEADER_SECTOR), ++ .header_lba = grub_cpu_to_le64_compile_time (PRIMARY_HEADER_SECTOR), ++ .alternate_lba = grub_cpu_to_le64_compile_time (BACKUP_HEADER_SECTOR), + .start = grub_cpu_to_le64_compile_time (DATA_START_SECTOR), + .end = grub_cpu_to_le64_compile_time (DATA_END_SECTOR), + .guid = {0xad, 0x31, 0xc1, 0x69, 0xd6, 0x67, 0xc6, 0x46, +@@ -112,8 +112,8 @@ static const struct grub_gpt_header example_backup = { + .version = GRUB_GPT_HEADER_VERSION, + .headersize = sizeof (struct grub_gpt_header), + .crc32 = grub_cpu_to_le32_compile_time (0xcfaa4a27), +- .primary = grub_cpu_to_le64_compile_time (BACKUP_HEADER_SECTOR), +- .backup = grub_cpu_to_le64_compile_time (PRIMARY_HEADER_SECTOR), ++ .header_lba = grub_cpu_to_le64_compile_time (BACKUP_HEADER_SECTOR), ++ .alternate_lba = grub_cpu_to_le64_compile_time (PRIMARY_HEADER_SECTOR), + .start = grub_cpu_to_le64_compile_time (DATA_START_SECTOR), + .end = grub_cpu_to_le64_compile_time (DATA_END_SECTOR), + .guid = {0xad, 0x31, 0xc1, 0x69, 0xd6, 0x67, 0xc6, 0x46, +-- +2.21.3 + diff --git a/packages/grub/0004-gpt-record-size-of-of-the-entries-table.patch b/packages/grub/0004-gpt-record-size-of-of-the-entries-table.patch new file mode 100644 index 00000000..e0c931b8 --- /dev/null +++ b/packages/grub/0004-gpt-record-size-of-of-the-entries-table.patch @@ -0,0 +1,137 @@ +From 42ad151307ad12ca85ae1865f4abc79d25673ae3 Mon Sep 17 00:00:00 2001 +From: Michael Marineau +Date: Sat, 18 Oct 2014 16:46:17 -0700 +Subject: [PATCH] gpt: record size of of the entries table + +The size of the entries table will be needed later when writing it back +to disk. Restructure the entries reading code to flow a little better. +--- + grub-core/lib/gpt.c | 53 ++++++++++++++++-------------------- + include/grub/gpt_partition.h | 5 +++- + 2 files changed, 27 insertions(+), 31 deletions(-) + +diff --git a/grub-core/lib/gpt.c b/grub-core/lib/gpt.c +index 705bd77..01df7f3 100644 +--- a/grub-core/lib/gpt.c ++++ b/grub-core/lib/gpt.c +@@ -153,7 +153,7 @@ grub_gpt_read_backup (grub_disk_t disk, grub_gpt_t gpt) + return GRUB_ERR_NONE; + } + +-static struct grub_gpt_partentry * ++static grub_err_t + grub_gpt_read_entries (grub_disk_t disk, grub_gpt_t gpt, + struct grub_gpt_header *header) + { +@@ -173,6 +173,10 @@ grub_gpt_read_entries (grub_disk_t disk, grub_gpt_t gpt, + goto fail; + } + ++ /* Double check that the header was validated properly. */ ++ if (entries_size < GRUB_GPT_DEFAULT_ENTRIES_SIZE) ++ return grub_error (GRUB_ERR_BUG, "invalid GPT entries table size"); ++ + entries = grub_malloc (entries_size); + if (!entries) + goto fail; +@@ -197,19 +201,21 @@ grub_gpt_read_entries (grub_disk_t disk, grub_gpt_t gpt, + } + + grub_free (crc32_context); +- return entries; ++ grub_free (gpt->entries); ++ gpt->entries = entries; ++ gpt->entries_size = entries_size; ++ return GRUB_ERR_NONE; + + fail: + grub_free (entries); + grub_free (crc32_context); +- return NULL; ++ return grub_errno; + } + + grub_gpt_t + grub_gpt_read (grub_disk_t disk) + { + grub_gpt_t gpt; +- struct grub_gpt_partentry *backup_entries; + + gpt = grub_zalloc (sizeof (*gpt)); + if (!gpt) +@@ -241,36 +247,23 @@ grub_gpt_read (grub_disk_t disk) + else + goto fail; + +- /* Same error handling scheme for the entry tables. */ +- gpt->entries = grub_gpt_read_entries (disk, gpt, &gpt->primary); +- if (!gpt->entries) +- { +- grub_error_push (); +- backup_entries = grub_gpt_read_entries (disk, gpt, &gpt->backup); +- grub_error_pop (); +- } +- else +- { +- gpt->status |= GRUB_GPT_PRIMARY_ENTRIES_VALID; +- backup_entries = grub_gpt_read_entries (disk, gpt, &gpt->backup); +- } ++ /* Similarly, favor the value or error from the primary table. */ ++ if (gpt->status & GRUB_GPT_BACKUP_HEADER_VALID && ++ !grub_gpt_read_entries (disk, gpt, &gpt->backup)) ++ gpt->status |= GRUB_GPT_BACKUP_ENTRIES_VALID; + +- if (backup_entries) +- { +- gpt->status |= GRUB_GPT_BACKUP_ENTRIES_VALID; +- +- if (gpt->status & GRUB_GPT_PRIMARY_ENTRIES_VALID) +- grub_free (backup_entries); +- else +- gpt->entries = backup_entries; +- } ++ grub_errno = GRUB_ERR_NONE; ++ if (gpt->status & GRUB_GPT_PRIMARY_HEADER_VALID && ++ !grub_gpt_read_entries (disk, gpt, &gpt->primary)) ++ gpt->status |= GRUB_GPT_PRIMARY_ENTRIES_VALID; + + if (gpt->status & GRUB_GPT_PRIMARY_ENTRIES_VALID || + gpt->status & GRUB_GPT_BACKUP_ENTRIES_VALID) +- { +- grub_errno = GRUB_ERR_NONE; +- return gpt; +- } ++ grub_errno = GRUB_ERR_NONE; ++ else ++ goto fail; ++ ++ return gpt; + + fail: + grub_gpt_free (gpt); +diff --git a/include/grub/gpt_partition.h b/include/grub/gpt_partition.h +index 1101d85..21ea08d 100644 +--- a/include/grub/gpt_partition.h ++++ b/include/grub/gpt_partition.h +@@ -106,7 +106,9 @@ typedef enum grub_gpt_status + + /* UEFI requires the entries table to be at least 16384 bytes for a + * total of 128 entries given the standard 128 byte entry size. */ +-#define GRUB_GPT_DEFAULT_ENTRIES_LENGTH 128 ++#define GRUB_GPT_DEFAULT_ENTRIES_SIZE 16384 ++#define GRUB_GPT_DEFAULT_ENTRIES_LENGTH \ ++ (GRUB_GPT_DEFAULT_ENTRIES_SIZE / sizeof (struct grub_gpt_partentry)) + + struct grub_gpt + { +@@ -122,6 +124,7 @@ struct grub_gpt + + /* Only need one entries table, on disk both copies are identical. */ + struct grub_gpt_partentry *entries; ++ grub_size_t entries_size; + + /* Logarithm of sector size, in case GPT and disk driver disagree. */ + unsigned int log_sector_size; +-- +2.21.3 + diff --git a/packages/grub/0005-gpt-consolidate-crc32-computation-code.patch b/packages/grub/0005-gpt-consolidate-crc32-computation-code.patch new file mode 100644 index 00000000..9c9918dd --- /dev/null +++ b/packages/grub/0005-gpt-consolidate-crc32-computation-code.patch @@ -0,0 +1,119 @@ +From a0481ec20cd8f99f973385b6dcacff6201aa5661 Mon Sep 17 00:00:00 2001 +From: Michael Marineau +Date: Sat, 18 Oct 2014 18:18:17 -0700 +Subject: [PATCH] gpt: consolidate crc32 computation code + +The gcrypt API is overly verbose, wrap it up in a helper function to +keep this rather common operation easy to use. +--- + grub-core/lib/gpt.c | 43 ++++++++++++++++++++++++------------------- + 1 file changed, 24 insertions(+), 19 deletions(-) + +diff --git a/grub-core/lib/gpt.c b/grub-core/lib/gpt.c +index 01df7f3..43a1509 100644 +--- a/grub-core/lib/gpt.c ++++ b/grub-core/lib/gpt.c +@@ -32,22 +32,17 @@ static grub_uint8_t grub_gpt_magic[] = GRUB_GPT_HEADER_MAGIC; + + + static grub_err_t +-grub_gpt_header_crc32 (struct grub_gpt_header *gpt, grub_uint32_t *crc) ++grub_gpt_lecrc32 (void *data, grub_size_t len, grub_uint32_t *crc) + { + grub_uint8_t *crc32_context; +- grub_uint32_t old; + + crc32_context = grub_zalloc (GRUB_MD_CRC32->contextsize); + if (!crc32_context) + return grub_errno; + +- /* crc32 must be computed with the field cleared. */ +- old = gpt->crc32; +- gpt->crc32 = 0; + GRUB_MD_CRC32->init (crc32_context); +- GRUB_MD_CRC32->write (crc32_context, gpt, sizeof (*gpt)); ++ GRUB_MD_CRC32->write (crc32_context, data, len); + GRUB_MD_CRC32->final (crc32_context); +- gpt->crc32 = old; + + /* GRUB_MD_CRC32 always uses big endian, gpt is always little. */ + *crc = grub_swap_bytes32 (*(grub_uint32_t *) +@@ -58,6 +53,25 @@ grub_gpt_header_crc32 (struct grub_gpt_header *gpt, grub_uint32_t *crc) + return GRUB_ERR_NONE; + } + ++static grub_err_t ++grub_gpt_header_lecrc32 (struct grub_gpt_header *header, grub_uint32_t *crc) ++{ ++ grub_uint32_t old, new; ++ grub_err_t err; ++ ++ /* crc32 must be computed with the field cleared. */ ++ old = header->crc32; ++ header->crc32 = 0; ++ err = grub_gpt_lecrc32 (header, sizeof (*header), &new); ++ header->crc32 = old; ++ ++ if (err) ++ return err; ++ ++ *crc = new; ++ return GRUB_ERR_NONE; ++} ++ + /* Make sure the MBR is a protective MBR and not a normal MBR. */ + grub_err_t + grub_gpt_pmbr_check (struct grub_msdos_partition_mbr *mbr) +@@ -87,7 +101,7 @@ grub_gpt_header_check (struct grub_gpt_header *gpt, + if (gpt->version != GRUB_GPT_HEADER_VERSION) + return grub_error (GRUB_ERR_BAD_PART_TABLE, "unknown GPT version"); + +- if (grub_gpt_header_crc32 (gpt, &crc)) ++ if (grub_gpt_header_lecrc32 (gpt, &crc)) + return grub_errno; + + if (gpt->crc32 != crc) +@@ -158,7 +172,6 @@ grub_gpt_read_entries (grub_disk_t disk, grub_gpt_t gpt, + struct grub_gpt_header *header) + { + struct grub_gpt_partentry *entries = NULL; +- grub_uint8_t *crc32_context = NULL; + grub_uint32_t count, size, crc; + grub_disk_addr_t addr; + grub_size_t entries_size; +@@ -185,22 +198,15 @@ grub_gpt_read_entries (grub_disk_t disk, grub_gpt_t gpt, + if (grub_disk_read (disk, addr, 0, entries_size, entries)) + goto fail; + +- crc32_context = grub_zalloc (GRUB_MD_CRC32->contextsize); +- if (!crc32_context) ++ if (grub_gpt_lecrc32 (entries, entries_size, &crc)) + goto fail; + +- GRUB_MD_CRC32->init (crc32_context); +- GRUB_MD_CRC32->write (crc32_context, entries, entries_size); +- GRUB_MD_CRC32->final (crc32_context); +- +- crc = *(grub_uint32_t *) GRUB_MD_CRC32->read (crc32_context); +- if (grub_swap_bytes32 (crc) != header->partentry_crc32) ++ if (crc != header->partentry_crc32) + { + grub_error (GRUB_ERR_BAD_PART_TABLE, "invalid GPT entry crc32"); + goto fail; + } + +- grub_free (crc32_context); + grub_free (gpt->entries); + gpt->entries = entries; + gpt->entries_size = entries_size; +@@ -208,7 +214,6 @@ grub_gpt_read_entries (grub_disk_t disk, grub_gpt_t gpt, + + fail: + grub_free (entries); +- grub_free (crc32_context); + return grub_errno; + } + +-- +2.21.3 + diff --git a/packages/grub/0006-gpt-add-new-repair-function-to-sync-up-primary-and-b.patch b/packages/grub/0006-gpt-add-new-repair-function-to-sync-up-primary-and-b.patch new file mode 100644 index 00000000..f683671b --- /dev/null +++ b/packages/grub/0006-gpt-add-new-repair-function-to-sync-up-primary-and-b.patch @@ -0,0 +1,217 @@ +From 36fc577048523438ffbf51291a40fe59eb479724 Mon Sep 17 00:00:00 2001 +From: Michael Marineau +Date: Sat, 18 Oct 2014 18:21:07 -0700 +Subject: [PATCH] gpt: add new repair function to sync up primary and backup + tables. + +--- + grub-core/lib/gpt.c | 90 ++++++++++++++++++++++++++++++++++++ + include/grub/gpt_partition.h | 3 ++ + tests/gpt_unit_test.c | 49 ++++++++++++++++++++ + 3 files changed, 142 insertions(+) + +diff --git a/grub-core/lib/gpt.c b/grub-core/lib/gpt.c +index 43a1509..2d61df4 100644 +--- a/grub-core/lib/gpt.c ++++ b/grub-core/lib/gpt.c +@@ -31,6 +31,20 @@ GRUB_MOD_LICENSE ("GPLv3+"); + static grub_uint8_t grub_gpt_magic[] = GRUB_GPT_HEADER_MAGIC; + + ++static grub_uint64_t ++grub_gpt_size_to_sectors (grub_gpt_t gpt, grub_size_t size) ++{ ++ unsigned int sector_size; ++ grub_uint64_t sectors; ++ ++ sector_size = 1U << gpt->log_sector_size; ++ sectors = size / sector_size; ++ if (size % sector_size) ++ sectors++; ++ ++ return sectors; ++} ++ + static grub_err_t + grub_gpt_lecrc32 (void *data, grub_size_t len, grub_uint32_t *crc) + { +@@ -275,6 +289,82 @@ fail: + return NULL; + } + ++grub_err_t ++grub_gpt_repair (grub_disk_t disk, grub_gpt_t gpt) ++{ ++ grub_uint64_t backup_header, backup_entries; ++ grub_uint32_t crc; ++ ++ if (disk->log_sector_size != gpt->log_sector_size) ++ return grub_error (GRUB_ERR_NOT_IMPLEMENTED_YET, ++ "GPT sector size must match disk sector size"); ++ ++ if (!(gpt->status & GRUB_GPT_PRIMARY_ENTRIES_VALID || ++ gpt->status & GRUB_GPT_BACKUP_ENTRIES_VALID)) ++ return grub_error (GRUB_ERR_BUG, "No valid GPT entries"); ++ ++ if (gpt->status & GRUB_GPT_PRIMARY_HEADER_VALID) ++ { ++ backup_header = grub_le_to_cpu64 (gpt->primary.alternate_lba); ++ grub_memcpy (&gpt->backup, &gpt->primary, sizeof (gpt->backup)); ++ } ++ else if (gpt->status & GRUB_GPT_BACKUP_HEADER_VALID) ++ { ++ backup_header = grub_le_to_cpu64 (gpt->backup.header_lba); ++ grub_memcpy (&gpt->primary, &gpt->backup, sizeof (gpt->primary)); ++ } ++ else ++ return grub_error (GRUB_ERR_BUG, "No valid GPT header"); ++ ++ /* Relocate backup to end if disk whenever possible. */ ++ if (disk->total_sectors != GRUB_DISK_SIZE_UNKNOWN) ++ backup_header = disk->total_sectors - 1; ++ ++ backup_entries = backup_header - ++ grub_gpt_size_to_sectors (gpt, gpt->entries_size); ++ ++ /* Update/fixup header and partition table locations. */ ++ gpt->primary.header_lba = grub_cpu_to_le64_compile_time (1); ++ gpt->primary.alternate_lba = grub_cpu_to_le64 (backup_header); ++ gpt->primary.partitions = grub_cpu_to_le64_compile_time (2); ++ gpt->backup.header_lba = gpt->primary.alternate_lba; ++ gpt->backup.alternate_lba = gpt->primary.header_lba; ++ gpt->backup.partitions = grub_cpu_to_le64 (backup_entries); ++ ++ /* Writing headers larger than our header structure are unsupported. */ ++ gpt->primary.headersize = ++ grub_cpu_to_le32_compile_time (sizeof (gpt->primary)); ++ gpt->backup.headersize = ++ grub_cpu_to_le32_compile_time (sizeof (gpt->backup)); ++ ++ /* Recompute checksums. */ ++ if (grub_gpt_lecrc32 (gpt->entries, gpt->entries_size, &crc)) ++ return grub_errno; ++ ++ gpt->primary.partentry_crc32 = crc; ++ gpt->backup.partentry_crc32 = crc; ++ ++ if (grub_gpt_header_lecrc32 (&gpt->primary, &gpt->primary.crc32)) ++ return grub_errno; ++ ++ if (grub_gpt_header_lecrc32 (&gpt->backup, &gpt->backup.crc32)) ++ return grub_errno; ++ ++ /* Sanity check. */ ++ if (grub_gpt_header_check (&gpt->primary, gpt->log_sector_size)) ++ return grub_error (GRUB_ERR_BUG, "Generated invalid GPT primary header"); ++ ++ if (grub_gpt_header_check (&gpt->backup, gpt->log_sector_size)) ++ return grub_error (GRUB_ERR_BUG, "Generated invalid GPT backup header"); ++ ++ gpt->status |= (GRUB_GPT_PRIMARY_HEADER_VALID | ++ GRUB_GPT_PRIMARY_ENTRIES_VALID | ++ GRUB_GPT_BACKUP_HEADER_VALID | ++ GRUB_GPT_BACKUP_ENTRIES_VALID); ++ ++ return GRUB_ERR_NONE; ++} ++ + void + grub_gpt_free (grub_gpt_t gpt) + { +diff --git a/include/grub/gpt_partition.h b/include/grub/gpt_partition.h +index 21ea08d..b45acbd 100644 +--- a/include/grub/gpt_partition.h ++++ b/include/grub/gpt_partition.h +@@ -141,6 +141,9 @@ grub_gpt_sector_to_addr (grub_gpt_t gpt, grub_uint64_t sector) + /* Allocates and fills new grub_gpt structure, free with grub_gpt_free. */ + grub_gpt_t grub_gpt_read (grub_disk_t disk); + ++/* Sync up primary and backup headers, recompute checksums. */ ++grub_err_t grub_gpt_repair (grub_disk_t disk, grub_gpt_t gpt); ++ + void grub_gpt_free (grub_gpt_t gpt); + + grub_err_t grub_gpt_pmbr_check (struct grub_msdos_partition_mbr *mbr); +diff --git a/tests/gpt_unit_test.c b/tests/gpt_unit_test.c +index 4d70868..83198be 100644 +--- a/tests/gpt_unit_test.c ++++ b/tests/gpt_unit_test.c +@@ -24,6 +24,7 @@ + #include + #include + #include ++#include + #include + + #include +@@ -442,6 +443,52 @@ read_fallback_test (void) + close_disk (&data); + } + ++static void ++repair_test (void) ++{ ++ struct test_data data; ++ grub_gpt_t gpt; ++ ++ open_disk (&data); ++ ++ /* Erase/Repair primary. */ ++ memset (&data.raw->primary_header, 0, sizeof (data.raw->primary_header)); ++ sync_disk (&data); ++ gpt = read_disk (&data); ++ grub_gpt_repair (data.dev->disk, gpt); ++ grub_test_assert (grub_errno == GRUB_ERR_NONE, ++ "repair failed: %s", grub_errmsg); ++ if (memcmp (&gpt->primary, &example_primary, sizeof (gpt->primary))) ++ { ++ printf ("Invalid restored primary header:\n"); ++ hexdump (16, (char*)&gpt->primary, sizeof (gpt->primary)); ++ printf ("Expected primary header:\n"); ++ hexdump (16, (char*)&example_primary, sizeof (example_primary)); ++ grub_test_assert (0, "repair did not restore primary header"); ++ } ++ grub_gpt_free (gpt); ++ reset_disk (&data); ++ ++ /* Erase/Repair backup. */ ++ memset (&data.raw->backup_header, 0, sizeof (data.raw->backup_header)); ++ sync_disk (&data); ++ gpt = read_disk (&data); ++ grub_gpt_repair (data.dev->disk, gpt); ++ grub_test_assert (grub_errno == GRUB_ERR_NONE, ++ "repair failed: %s", grub_errmsg); ++ if (memcmp (&gpt->backup, &example_backup, sizeof (gpt->backup))) ++ { ++ printf ("Invalid restored backup header:\n"); ++ hexdump (16, (char*)&gpt->backup, sizeof (gpt->backup)); ++ printf ("Expected backup header:\n"); ++ hexdump (16, (char*)&example_backup, sizeof (example_backup)); ++ grub_test_assert (0, "repair did not restore backup header"); ++ } ++ grub_gpt_free (gpt); ++ reset_disk (&data); ++ ++ close_disk (&data); ++} + void + grub_unit_test_init (void) + { +@@ -453,6 +500,7 @@ grub_unit_test_init (void) + grub_test_register ("gpt_read_valid_test", read_valid_test); + grub_test_register ("gpt_read_invalid_test", read_invalid_entries_test); + grub_test_register ("gpt_read_fallback_test", read_fallback_test); ++ grub_test_register ("gpt_repair_test", repair_test); + } + + void +@@ -463,5 +511,6 @@ grub_unit_test_fini (void) + grub_test_unregister ("gpt_read_valid_test"); + grub_test_unregister ("gpt_read_invalid_test"); + grub_test_unregister ("gpt_read_fallback_test"); ++ grub_test_unregister ("gpt_repair_test"); + grub_fini_all (); + } +-- +2.21.3 + diff --git a/packages/grub/0007-gpt-add-write-function-and-gptrepair-command.patch b/packages/grub/0007-gpt-add-write-function-and-gptrepair-command.patch new file mode 100644 index 00000000..a3fd35e5 --- /dev/null +++ b/packages/grub/0007-gpt-add-write-function-and-gptrepair-command.patch @@ -0,0 +1,367 @@ +From 822c0cb2c9d6cd7b0e4be0362bbc5804417e479f Mon Sep 17 00:00:00 2001 +From: Michael Marineau +Date: Sun, 19 Oct 2014 14:21:29 -0700 +Subject: [PATCH] gpt: add write function and gptrepair command + +The first hint of something practical, a command that can restore any of +the GPT structures from the alternate location. New test case must run +under QEMU because the loopback device used by the other unit tests does +not support writing. +--- + Makefile.util.def | 6 ++ + grub-core/Makefile.core.def | 5 ++ + grub-core/commands/gptrepair.c | 116 +++++++++++++++++++++++++++++++++ + grub-core/lib/gpt.c | 44 +++++++++++-- + include/grub/gpt_partition.h | 8 +++ + tests/gptrepair_test.in | 102 +++++++++++++++++++++++++++++ + 6 files changed, 277 insertions(+), 4 deletions(-) + create mode 100644 grub-core/commands/gptrepair.c + create mode 100644 tests/gptrepair_test.in + +diff --git a/Makefile.util.def b/Makefile.util.def +index c7efe17..a2ca51d 100644 +--- a/Makefile.util.def ++++ b/Makefile.util.def +@@ -1288,6 +1288,12 @@ script = { + common = tests/grub_cmd_tr.in; + }; + ++script = { ++ testcase; ++ name = gptrepair_test; ++ common = tests/gptrepair_test.in; ++}; ++ + script = { + testcase; + name = file_filter_test; +diff --git a/grub-core/Makefile.core.def b/grub-core/Makefile.core.def +index e9cce06..c040652 100644 +--- a/grub-core/Makefile.core.def ++++ b/grub-core/Makefile.core.def +@@ -942,6 +942,11 @@ module = { + common = commands/gptsync.c; + }; + ++module = { ++ name = gptrepair; ++ common = commands/gptrepair.c; ++}; ++ + module = { + name = gpt; + common = lib/gpt.c; +diff --git a/grub-core/commands/gptrepair.c b/grub-core/commands/gptrepair.c +new file mode 100644 +index 0000000..38392fd +--- /dev/null ++++ b/grub-core/commands/gptrepair.c +@@ -0,0 +1,116 @@ ++/* gptrepair.c - verify and restore GPT info from alternate location. */ ++/* ++ * GRUB -- GRand Unified Bootloader ++ * Copyright (C) 2009 Free Software Foundation, Inc. ++ * Copyright (C) 2014 CoreOS, Inc. ++ * ++ * GRUB is free software: you can redistribute it and/or modify ++ * it under the terms of the GNU General Public License as published by ++ * the Free Software Foundation, either version 3 of the License, or ++ * (at your option) any later version. ++ * ++ * GRUB is distributed in the hope that it will be useful, ++ * but WITHOUT ANY WARRANTY; without even the implied warranty of ++ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++ * GNU General Public License for more details. ++ * ++ * You should have received a copy of the GNU General Public License ++ * along with GRUB. If not, see . ++ */ ++ ++#include ++#include ++#include ++#include ++#include ++#include ++ ++GRUB_MOD_LICENSE ("GPLv3+"); ++ ++static char * ++trim_dev_name (char *name) ++{ ++ grub_size_t len = grub_strlen (name); ++ if (len && name[0] == '(' && name[len - 1] == ')') ++ { ++ name[len - 1] = '\0'; ++ name = name + 1; ++ } ++ return name; ++} ++ ++static grub_err_t ++grub_cmd_gptrepair (grub_command_t cmd __attribute__ ((unused)), ++ int argc, char **args) ++{ ++ grub_device_t dev = NULL; ++ grub_gpt_t gpt = NULL; ++ char *dev_name; ++ grub_uint32_t primary_crc, backup_crc; ++ enum grub_gpt_status old_status; ++ ++ if (argc != 1 || !grub_strlen(args[0])) ++ return grub_error (GRUB_ERR_BAD_ARGUMENT, "device name required"); ++ ++ dev_name = trim_dev_name (args[0]); ++ dev = grub_device_open (dev_name); ++ if (!dev) ++ goto done; ++ ++ if (!dev->disk) ++ { ++ grub_error (GRUB_ERR_BAD_ARGUMENT, "not a disk"); ++ goto done; ++ } ++ ++ gpt = grub_gpt_read (dev->disk); ++ if (!gpt) ++ goto done; ++ ++ primary_crc = gpt->primary.crc32; ++ backup_crc = gpt->backup.crc32; ++ old_status = gpt->status; ++ ++ if (grub_gpt_repair (dev->disk, gpt)) ++ goto done; ++ ++ if (primary_crc == gpt->primary.crc32 && ++ backup_crc == gpt->backup.crc32 && ++ old_status && gpt->status) ++ { ++ grub_printf_ (N_("GPT already valid, %s unmodified.\n"), dev_name); ++ goto done; ++ } ++ ++ if (grub_gpt_write (dev->disk, gpt)) ++ goto done; ++ ++ if (!(old_status & GRUB_GPT_PRIMARY_VALID)) ++ grub_printf_ (N_("Primary GPT for %s repaired.\n"), dev_name); ++ ++ if (!(old_status & GRUB_GPT_BACKUP_VALID)) ++ grub_printf_ (N_("Backup GPT for %s repaired.\n"), dev_name); ++ ++done: ++ if (gpt) ++ grub_gpt_free (gpt); ++ ++ if (dev) ++ grub_device_close (dev); ++ ++ return grub_errno; ++} ++ ++static grub_command_t cmd; ++ ++GRUB_MOD_INIT(gptrepair) ++{ ++ cmd = grub_register_command ("gptrepair", grub_cmd_gptrepair, ++ N_("DEVICE"), ++ N_("Verify and repair GPT on drive DEVICE.")); ++} ++ ++GRUB_MOD_FINI(gptrepair) ++{ ++ grub_unregister_command (cmd); ++} +diff --git a/grub-core/lib/gpt.c b/grub-core/lib/gpt.c +index 2d61df4..67ffdf7 100644 +--- a/grub-core/lib/gpt.c ++++ b/grub-core/lib/gpt.c +@@ -357,10 +357,46 @@ grub_gpt_repair (grub_disk_t disk, grub_gpt_t gpt) + if (grub_gpt_header_check (&gpt->backup, gpt->log_sector_size)) + return grub_error (GRUB_ERR_BUG, "Generated invalid GPT backup header"); + +- gpt->status |= (GRUB_GPT_PRIMARY_HEADER_VALID | +- GRUB_GPT_PRIMARY_ENTRIES_VALID | +- GRUB_GPT_BACKUP_HEADER_VALID | +- GRUB_GPT_BACKUP_ENTRIES_VALID); ++ gpt->status |= GRUB_GPT_BOTH_VALID; ++ return GRUB_ERR_NONE; ++} ++ ++static grub_err_t ++grub_gpt_write_table (grub_disk_t disk, grub_gpt_t gpt, ++ struct grub_gpt_header *header) ++{ ++ grub_disk_addr_t addr; ++ ++ if (grub_le_to_cpu32 (header->headersize) != sizeof (*header)) ++ return grub_error (GRUB_ERR_NOT_IMPLEMENTED_YET, ++ "Header size is %u, must be %u", ++ grub_le_to_cpu32 (header->headersize), ++ sizeof (*header)); ++ ++ addr = grub_gpt_sector_to_addr (gpt, grub_le_to_cpu64 (header->header_lba)); ++ if (grub_disk_write (disk, addr, 0, sizeof (*header), header)) ++ return grub_errno; ++ ++ addr = grub_gpt_sector_to_addr (gpt, grub_le_to_cpu64 (header->partitions)); ++ if (grub_disk_write (disk, addr, 0, gpt->entries_size, gpt->entries)) ++ return grub_errno; ++ ++ return GRUB_ERR_NONE; ++} ++ ++grub_err_t ++grub_gpt_write (grub_disk_t disk, grub_gpt_t gpt) ++{ ++ /* TODO: update/repair protective MBRs too. */ ++ ++ if (!(gpt->status & GRUB_GPT_BOTH_VALID)) ++ return grub_error (GRUB_ERR_BAD_PART_TABLE, "Invalid GPT data"); ++ ++ if (grub_gpt_write_table (disk, gpt, &gpt->primary)) ++ return grub_errno; ++ ++ if (grub_gpt_write_table (disk, gpt, &gpt->backup)) ++ return grub_errno; + + return GRUB_ERR_NONE; + } +diff --git a/include/grub/gpt_partition.h b/include/grub/gpt_partition.h +index b45acbd..5c2b535 100644 +--- a/include/grub/gpt_partition.h ++++ b/include/grub/gpt_partition.h +@@ -103,6 +103,11 @@ typedef enum grub_gpt_status + } grub_gpt_status_t; + + #define GRUB_GPT_MBR_VALID (GRUB_GPT_PROTECTIVE_MBR|GRUB_GPT_HYBRID_MBR) ++#define GRUB_GPT_PRIMARY_VALID \ ++ (GRUB_GPT_PRIMARY_HEADER_VALID|GRUB_GPT_PRIMARY_ENTRIES_VALID) ++#define GRUB_GPT_BACKUP_VALID \ ++ (GRUB_GPT_BACKUP_HEADER_VALID|GRUB_GPT_BACKUP_ENTRIES_VALID) ++#define GRUB_GPT_BOTH_VALID (GRUB_GPT_PRIMARY_VALID|GRUB_GPT_BACKUP_VALID) + + /* UEFI requires the entries table to be at least 16384 bytes for a + * total of 128 entries given the standard 128 byte entry size. */ +@@ -144,6 +149,9 @@ grub_gpt_t grub_gpt_read (grub_disk_t disk); + /* Sync up primary and backup headers, recompute checksums. */ + grub_err_t grub_gpt_repair (grub_disk_t disk, grub_gpt_t gpt); + ++/* Write headers and entry tables back to disk. */ ++grub_err_t grub_gpt_write (grub_disk_t disk, grub_gpt_t gpt); ++ + void grub_gpt_free (grub_gpt_t gpt); + + grub_err_t grub_gpt_pmbr_check (struct grub_msdos_partition_mbr *mbr); +diff --git a/tests/gptrepair_test.in b/tests/gptrepair_test.in +new file mode 100644 +index 0000000..80b2de6 +--- /dev/null ++++ b/tests/gptrepair_test.in +@@ -0,0 +1,102 @@ ++#! /bin/sh ++set -e ++ ++# Copyright (C) 2010 Free Software Foundation, Inc. ++# Copyright (C) 2014 CoreOS, Inc. ++# ++# GRUB is free software: you can redistribute it and/or modify ++# it under the terms of the GNU General Public License as published by ++# the Free Software Foundation, either version 3 of the License, or ++# (at your option) any later version. ++# ++# GRUB is distributed in the hope that it will be useful, ++# but WITHOUT ANY WARRANTY; without even the implied warranty of ++# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++# GNU General Public License for more details. ++# ++# You should have received a copy of the GNU General Public License ++# along with GRUB. If not, see . ++ ++parted=parted ++grubshell=@builddir@/grub-shell ++ ++. "@builddir@/grub-core/modinfo.sh" ++ ++case "${grub_modinfo_target_cpu}-${grub_modinfo_platform}" in ++ mips-qemu_mips | mipsel-qemu_mips | i386-qemu | i386-multiboot | i386-coreboot | mipsel-loongson) ++ disk=ata0 ++ ;; ++ powerpc-ieee1275) ++ disk=ieee1275//pci@80000000/mac-io@4/ata-3@20000/disk@0 ++ # FIXME: QEMU firmware has bugs which prevent it from accessing hard disk w/o recognised label. ++ exit 0 ++ ;; ++ sparc64-ieee1275) ++ disk=ieee1275//pci@1fe\,0/pci-ata@5/ide0@500/disk@0 ++ # FIXME: QEMU firmware has bugs which prevent it from accessing hard disk w/o recognised label. ++ exit 0 ++ ;; ++ i386-ieee1275) ++ disk=ieee1275/d ++ # FIXME: QEMU firmware has bugs which prevent it from accessing hard disk w/o recognised label. ++ exit 0 ++ ;; ++ mips-arc) ++ # FIXME: ARC firmware has bugs which prevent it from accessing hard disk w/o dvh disklabel. ++ exit 0 ;; ++ mipsel-arc) ++ disk=arc/scsi0/disk0/rdisk0 ++ ;; ++ *) ++ disk=hd0 ++ ;; ++esac ++img1="`mktemp "${TMPDIR:-/tmp}/tmp.XXXXXXXXXX"`" || exit 1 ++img2="`mktemp "${TMPDIR:-/tmp}/tmp.XXXXXXXXXX"`" || exit 1 ++trap "rm -f '${img1}' '${ing2}'" EXIT ++ ++create_disk_image () { ++ size=$1 ++ rm -f "${img1}" ++ dd if=/dev/zero of="${img1}" bs=512 count=1 seek=$((size - 1)) status=none ++ ${parted} -a none -s "${img1}" mklabel gpt ++ cp "${img1}" "${img2}" ++} ++ ++wipe_disk_area () { ++ sector=$1 ++ size=$2 ++ dd if=/dev/zero of="${img2}" bs=512 count=${size} seek=${sector} conv=notrunc status=none ++} ++ ++do_repair () { ++ output="`echo "gptrepair ($disk)" | "${grubshell}" --disk="${img2}"`" ++ if echo "${output}" | grep ^error; then ++ return 1 ++ fi ++ if echo "${output}" | grep -v GPT; then ++ echo "Unexpected output ${output}" ++ return 1 ++ fi ++ echo "${output}" ++} ++ ++echo "Nothing to repair:" ++create_disk_image 100 ++do_repair ++cmp "${img1}" "${img2}" ++echo ++ ++echo "Repair primary (MBR left intact)" ++create_disk_image 100 ++wipe_disk_area 1 1 ++do_repair ++cmp "${img1}" "${img2}" ++echo ++ ++echo "Repair backup" ++create_disk_image 100 ++wipe_disk_area 99 1 ++do_repair ++cmp "${img1}" "${img2}" ++echo +-- +2.36.1 + diff --git a/packages/grub/0008-gpt-add-a-new-generic-GUID-type.patch b/packages/grub/0008-gpt-add-a-new-generic-GUID-type.patch new file mode 100644 index 00000000..c68642a7 --- /dev/null +++ b/packages/grub/0008-gpt-add-a-new-generic-GUID-type.patch @@ -0,0 +1,125 @@ +From d5520178578153d5b1c79bfba014d388acc6cf75 Mon Sep 17 00:00:00 2001 +From: Michael Marineau +Date: Thu, 30 Oct 2014 20:55:21 -0700 +Subject: [PATCH] gpt: add a new generic GUID type + +In order to do anything with partition GUIDs they need to be stored in a +proper structure like the partition type GUIDs. Additionally add an +initializer macro to simplify defining both GUID types. + +[iweller: use new type name from a16f4a822] +Signed-off-by: iliana destroyer of worlds +--- + include/grub/gpt_partition.h | 34 ++++++++++++++++++---------------- + tests/gpt_unit_test.c | 12 ++++++------ + 2 files changed, 24 insertions(+), 22 deletions(-) + +diff --git a/include/grub/gpt_partition.h b/include/grub/gpt_partition.h +index 5c2b535..d13ea0b 100644 +--- a/include/grub/gpt_partition.h ++++ b/include/grub/gpt_partition.h +@@ -23,33 +23,35 @@ + #include + #include + +-struct grub_gpt_part_guid ++struct grub_gpt_guid + { + grub_uint32_t data1; + grub_uint16_t data2; + grub_uint16_t data3; + grub_uint8_t data4[8]; + } GRUB_PACKED; +-typedef struct grub_gpt_part_guid grub_gpt_part_guid_t; ++typedef struct grub_gpt_guid grub_gpt_guid_t; ++typedef struct grub_gpt_guid grub_gpt_part_guid_t; ++ ++#define GRUB_GPT_GUID_INIT(a, b, c, d1, d2, d3, d4, d5, d6, d7, d8) \ ++ { \ ++ grub_cpu_to_le32_compile_time (a), \ ++ grub_cpu_to_le16_compile_time (b), \ ++ grub_cpu_to_le16_compile_time (c), \ ++ { d1, d2, d3, d4, d5, d6, d7, d8 } \ ++ } + + #define GRUB_GPT_PARTITION_TYPE_EMPTY \ +- { 0x0, 0x0, 0x0, \ +- { 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0 } \ +- } ++ GRUB_GPT_GUID_INIT (0x0, 0x0, 0x0, \ ++ 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0) + + #define GRUB_GPT_PARTITION_TYPE_BIOS_BOOT \ +- { grub_cpu_to_le32_compile_time (0x21686148), \ +- grub_cpu_to_le16_compile_time (0x6449), \ +- grub_cpu_to_le16_compile_time (0x6e6f), \ +- { 0x74, 0x4e, 0x65, 0x65, 0x64, 0x45, 0x46, 0x49 } \ +- } ++ GRUB_GPT_GUID_INIT (0x21686148, 0x6449, 0x6e6f, \ ++ 0x74, 0x4e, 0x65, 0x65, 0x64, 0x45, 0x46, 0x49) + + #define GRUB_GPT_PARTITION_TYPE_LDM \ +- { grub_cpu_to_le32_compile_time (0x5808C8AAU),\ +- grub_cpu_to_le16_compile_time (0x7E8F), \ +- grub_cpu_to_le16_compile_time (0x42E0), \ +- { 0x85, 0xD2, 0xE1, 0xE9, 0x04, 0x34, 0xCF, 0xB3 } \ +- } ++ GRUB_GPT_GUID_INIT (0x5808c8aa, 0x7e8f, 0x42e0, \ ++ 0x85, 0xd2, 0xe1, 0xe9, 0x04, 0x34, 0xcf, 0xb3) + + #define GRUB_GPT_HEADER_MAGIC \ + { 0x45, 0x46, 0x49, 0x20, 0x50, 0x41, 0x52, 0x54 } +@@ -68,7 +70,7 @@ struct grub_gpt_header + grub_uint64_t alternate_lba; + grub_uint64_t start; + grub_uint64_t end; +- grub_uint8_t guid[16]; ++ grub_gpt_guid_t guid; + grub_uint64_t partitions; + grub_uint32_t maxpart; + grub_uint32_t partentry_size; +diff --git a/tests/gpt_unit_test.c b/tests/gpt_unit_test.c +index 83198be..86e4364 100644 +--- a/tests/gpt_unit_test.c ++++ b/tests/gpt_unit_test.c +@@ -99,8 +99,8 @@ static const struct grub_gpt_header example_primary = { + .alternate_lba = grub_cpu_to_le64_compile_time (BACKUP_HEADER_SECTOR), + .start = grub_cpu_to_le64_compile_time (DATA_START_SECTOR), + .end = grub_cpu_to_le64_compile_time (DATA_END_SECTOR), +- .guid = {0xad, 0x31, 0xc1, 0x69, 0xd6, 0x67, 0xc6, 0x46, +- 0x93, 0xc4, 0x12, 0x4c, 0x75, 0x52, 0x56, 0xac}, ++ .guid = GRUB_GPT_GUID_INIT(0x69c131ad, 0x67d6, 0x46c6, ++ 0x93, 0xc4, 0x12, 0x4c, 0x75, 0x52, 0x56, 0xac), + .partitions = grub_cpu_to_le64_compile_time (PRIMARY_TABLE_SECTOR), + .maxpart = grub_cpu_to_le32_compile_time (TABLE_ENTRIES), + .partentry_size = grub_cpu_to_le32_compile_time (ENTRY_SIZE), +@@ -117,8 +117,8 @@ static const struct grub_gpt_header example_backup = { + .alternate_lba = grub_cpu_to_le64_compile_time (PRIMARY_HEADER_SECTOR), + .start = grub_cpu_to_le64_compile_time (DATA_START_SECTOR), + .end = grub_cpu_to_le64_compile_time (DATA_END_SECTOR), +- .guid = {0xad, 0x31, 0xc1, 0x69, 0xd6, 0x67, 0xc6, 0x46, +- 0x93, 0xc4, 0x12, 0x4c, 0x75, 0x52, 0x56, 0xac}, ++ .guid = GRUB_GPT_GUID_INIT(0x69c131ad, 0x67d6, 0x46c6, ++ 0x93, 0xc4, 0x12, 0x4c, 0x75, 0x52, 0x56, 0xac), + .partitions = grub_cpu_to_le64_compile_time (BACKUP_TABLE_SECTOR), + .maxpart = grub_cpu_to_le32_compile_time (TABLE_ENTRIES), + .partentry_size = grub_cpu_to_le32_compile_time (ENTRY_SIZE), +@@ -326,13 +326,13 @@ header_test (void) + grub_errno = GRUB_ERR_NONE; + + /* Twiddle the GUID to invalidate the CRC. */ +- primary.guid[0] = 0; ++ primary.guid.data1 = 0; + grub_gpt_header_check (&primary, GRUB_DISK_SECTOR_BITS); + grub_test_assert (grub_errno == GRUB_ERR_BAD_PART_TABLE, + "unexpected error: %s", grub_errmsg); + grub_errno = GRUB_ERR_NONE; + +- backup.guid[0] = 0; ++ backup.guid.data1 = 0; + grub_gpt_header_check (&backup, GRUB_DISK_SECTOR_BITS); + grub_test_assert (grub_errno == GRUB_ERR_BAD_PART_TABLE, + "unexpected error: %s", grub_errmsg); +-- +2.21.3 + diff --git a/packages/grub/0009-gpt-new-gptprio.next-command-for-selecting-priority-.patch b/packages/grub/0009-gpt-new-gptprio.next-command-for-selecting-priority-.patch new file mode 100644 index 00000000..67b6ca53 --- /dev/null +++ b/packages/grub/0009-gpt-new-gptprio.next-command-for-selecting-priority-.patch @@ -0,0 +1,529 @@ +From 06eff592def149c09fa42fee4e5d98b7abf00717 Mon Sep 17 00:00:00 2001 +From: Michael Marineau +Date: Mon, 3 Nov 2014 17:14:37 -0800 +Subject: [PATCH] gpt: new gptprio.next command for selecting priority based + partitions + +Basic usage would look something like this: + + gptprio.next -d usr_dev -u usr_uuid + linuxefi ($usr_dev)/boot/vmlinuz mount.usr=PARTUUID=$usr_uuid + +After booting the system should set the 'successful' bit on the +partition that was used. + +[iweller: use new type name from a16f4a822] +Signed-off-by: iliana destroyer of worlds +--- + Makefile.util.def | 6 + + grub-core/Makefile.core.def | 5 + + grub-core/commands/gptprio.c | 238 +++++++++++++++++++++++++++++++++++ + include/grub/gpt_partition.h | 49 ++++++++ + tests/gptprio_test.in | 150 ++++++++++++++++++++++ + 5 files changed, 448 insertions(+) + create mode 100644 grub-core/commands/gptprio.c + create mode 100644 tests/gptprio_test.in + +diff --git a/Makefile.util.def b/Makefile.util.def +index a2ca51d..eb4bc90 100644 +--- a/Makefile.util.def ++++ b/Makefile.util.def +@@ -1294,6 +1294,12 @@ script = { + common = tests/gptrepair_test.in; + }; + ++script = { ++ testcase; ++ name = gptprio_test; ++ common = tests/gptprio_test.in; ++}; ++ + script = { + testcase; + name = file_filter_test; +diff --git a/grub-core/Makefile.core.def b/grub-core/Makefile.core.def +index c040652..393aecd 100644 +--- a/grub-core/Makefile.core.def ++++ b/grub-core/Makefile.core.def +@@ -947,6 +947,11 @@ module = { + common = commands/gptrepair.c; + }; + ++module = { ++ name = gptprio; ++ common = commands/gptprio.c; ++}; ++ + module = { + name = gpt; + common = lib/gpt.c; +diff --git a/grub-core/commands/gptprio.c b/grub-core/commands/gptprio.c +new file mode 100644 +index 0000000..1e2e06c +--- /dev/null ++++ b/grub-core/commands/gptprio.c +@@ -0,0 +1,238 @@ ++/* gptprio.c - manage priority based partition selection. */ ++/* ++ * GRUB -- GRand Unified Bootloader ++ * Copyright (C) 2009 Free Software Foundation, Inc. ++ * Copyright (C) 2014 CoreOS, Inc. ++ * ++ * GRUB is free software: you can redistribute it and/or modify ++ * it under the terms of the GNU General Public License as published by ++ * the Free Software Foundation, either version 3 of the License, or ++ * (at your option) any later version. ++ * ++ * GRUB is distributed in the hope that it will be useful, ++ * but WITHOUT ANY WARRANTY; without even the implied warranty of ++ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++ * GNU General Public License for more details. ++ * ++ * You should have received a copy of the GNU General Public License ++ * along with GRUB. If not, see . ++ */ ++ ++#include ++#include ++#include ++#include ++#include ++#include ++#include ++ ++GRUB_MOD_LICENSE ("GPLv3+"); ++ ++static const struct grub_arg_option options_next[] = { ++ {"set-device", 'd', 0, ++ N_("Set a variable to the name of selected partition."), ++ N_("VARNAME"), ARG_TYPE_STRING}, ++ {"set-uuid", 'u', 0, ++ N_("Set a variable to the GPT UUID of selected partition."), ++ N_("VARNAME"), ARG_TYPE_STRING}, ++ {0, 0, 0, 0, 0, 0} ++}; ++ ++enum options_next ++{ ++ NEXT_SET_DEVICE, ++ NEXT_SET_UUID, ++}; ++ ++static unsigned int ++grub_gptprio_priority (struct grub_gpt_partentry *entry) ++{ ++ return (unsigned int) grub_gpt_entry_attribute ++ (entry, GRUB_GPT_PART_ATTR_OFFSET_GPTPRIO_PRIORITY, 4); ++} ++ ++static unsigned int ++grub_gptprio_tries_left (struct grub_gpt_partentry *entry) ++{ ++ return (unsigned int) grub_gpt_entry_attribute ++ (entry, GRUB_GPT_PART_ATTR_OFFSET_GPTPRIO_TRIES_LEFT, 4); ++} ++ ++static void ++grub_gptprio_set_tries_left (struct grub_gpt_partentry *entry, ++ unsigned int tries_left) ++{ ++ grub_gpt_entry_set_attribute ++ (entry, tries_left, GRUB_GPT_PART_ATTR_OFFSET_GPTPRIO_TRIES_LEFT, 4); ++} ++ ++static unsigned int ++grub_gptprio_successful (struct grub_gpt_partentry *entry) ++{ ++ return (unsigned int) grub_gpt_entry_attribute ++ (entry, GRUB_GPT_PART_ATTR_OFFSET_GPTPRIO_SUCCESSFUL, 1); ++} ++ ++static grub_err_t ++grub_find_next (const char *disk_name, ++ const grub_gpt_part_guid_t *part_type, ++ char **part_name, char **part_guid) ++{ ++ struct grub_gpt_partentry *part_found = NULL; ++ grub_device_t dev = NULL; ++ grub_gpt_t gpt = NULL; ++ grub_uint32_t i, part_index; ++ ++ dev = grub_device_open (disk_name); ++ if (!dev) ++ goto done; ++ ++ gpt = grub_gpt_read (dev->disk); ++ if (!gpt) ++ goto done; ++ ++ if (!(gpt->status & GRUB_GPT_BOTH_VALID)) ++ if (grub_gpt_repair (dev->disk, gpt)) ++ goto done; ++ ++ for (i = 0; i < grub_le_to_cpu32 (gpt->primary.maxpart); i++) ++ { ++ struct grub_gpt_partentry *part = &gpt->entries[i]; ++ ++ if (grub_memcmp (part_type, &part->type, sizeof (*part_type)) == 0) ++ { ++ unsigned int priority, tries_left, successful, old_priority = 0; ++ ++ priority = grub_gptprio_priority (part); ++ tries_left = grub_gptprio_tries_left (part); ++ successful = grub_gptprio_successful (part); ++ ++ if (part_found) ++ old_priority = grub_gptprio_priority (part_found); ++ ++ if ((tries_left || successful) && priority > old_priority) ++ { ++ part_index = i; ++ part_found = part; ++ } ++ } ++ } ++ ++ if (!part_found) ++ { ++ grub_error (GRUB_ERR_UNKNOWN_DEVICE, N_("no such partition")); ++ goto done; ++ } ++ ++ if (grub_gptprio_tries_left (part_found)) ++ { ++ unsigned int tries_left = grub_gptprio_tries_left (part_found); ++ ++ grub_gptprio_set_tries_left (part_found, tries_left - 1); ++ ++ if (grub_gpt_update_checksums (gpt)) ++ goto done; ++ ++ if (grub_gpt_write (dev->disk, gpt)) ++ goto done; ++ } ++ ++ *part_name = grub_xasprintf ("%s,gpt%u", disk_name, part_index + 1); ++ if (!*part_name) ++ goto done; ++ ++ *part_guid = ++ grub_xasprintf ("%08x-%04x-%04x-%02x%02x-%02x%02x%02x%02x%02x%02x", ++ grub_le_to_cpu32 (part_found->guid.data1), ++ grub_le_to_cpu16 (part_found->guid.data2), ++ grub_le_to_cpu16 (part_found->guid.data3), ++ part_found->guid.data4[0], ++ part_found->guid.data4[1], ++ part_found->guid.data4[2], ++ part_found->guid.data4[3], ++ part_found->guid.data4[4], ++ part_found->guid.data4[5], ++ part_found->guid.data4[6], ++ part_found->guid.data4[7]); ++ if (!*part_name) ++ goto done; ++ ++ grub_errno = GRUB_ERR_NONE; ++ ++done: ++ grub_gpt_free (gpt); ++ ++ if (dev) ++ grub_device_close (dev); ++ ++ return grub_errno; ++} ++ ++ ++ ++static grub_err_t ++grub_cmd_next (grub_extcmd_context_t ctxt, int argc, char **args) ++{ ++ struct grub_arg_list *state = ctxt->state; ++ char *p, *root = NULL, *part_name = NULL, *part_guid = NULL; ++ ++ /* TODO: Add a uuid parser and a command line flag for providing type. */ ++ grub_gpt_part_guid_t part_type = GRUB_GPT_PARTITION_TYPE_USR_X86_64; ++ ++ if (!state[NEXT_SET_DEVICE].set || !state[NEXT_SET_UUID].set) ++ { ++ grub_error (GRUB_ERR_INVALID_COMMAND, N_("-d and -u are required")); ++ goto done; ++ } ++ ++ if (argc == 0) ++ root = grub_strdup (grub_env_get ("root")); ++ else if (argc == 1) ++ root = grub_strdup (args[0]); ++ else ++ { ++ grub_error (GRUB_ERR_BAD_ARGUMENT, N_("unexpected arguments")); ++ goto done; ++ } ++ ++ if (!root) ++ goto done; ++ ++ /* To make using $root practical strip off the partition name. */ ++ p = grub_strchr (root, ','); ++ if (p) ++ *p = '\0'; ++ ++ if (grub_find_next (root, &part_type, &part_name, &part_guid)) ++ goto done; ++ ++ if (grub_env_set (state[NEXT_SET_DEVICE].arg, part_name)) ++ goto done; ++ ++ if (grub_env_set (state[NEXT_SET_UUID].arg, part_guid)) ++ goto done; ++ ++ grub_errno = GRUB_ERR_NONE; ++ ++done: ++ grub_free (root); ++ grub_free (part_name); ++ grub_free (part_guid); ++ ++ return grub_errno; ++} ++ ++static grub_extcmd_t cmd_next; ++ ++GRUB_MOD_INIT(gptprio) ++{ ++ cmd_next = grub_register_extcmd ("gptprio.next", grub_cmd_next, 0, ++ N_("-d VARNAME -u VARNAME [DEVICE]"), ++ N_("Select next partition to boot."), ++ options_next); ++} ++ ++GRUB_MOD_FINI(gptprio) ++{ ++ grub_unregister_extcmd (cmd_next); ++} +diff --git a/include/grub/gpt_partition.h b/include/grub/gpt_partition.h +index d13ea0b..fc4f0f5 100644 +--- a/include/grub/gpt_partition.h ++++ b/include/grub/gpt_partition.h +@@ -53,6 +53,10 @@ typedef struct grub_gpt_guid grub_gpt_part_guid_t; + GRUB_GPT_GUID_INIT (0x5808c8aa, 0x7e8f, 0x42e0, \ + 0x85, 0xd2, 0xe1, 0xe9, 0x04, 0x34, 0xcf, 0xb3) + ++#define GRUB_GPT_PARTITION_TYPE_USR_X86_64 \ ++ GRUB_GPT_GUID_INIT (0x5dfbf5f4, 0x2848, 0x4bac, \ ++ 0xaa, 0x5e, 0x0d, 0x9a, 0x20, 0xb7, 0x45, 0xa6) ++ + #define GRUB_GPT_HEADER_MAGIC \ + { 0x45, 0x46, 0x49, 0x20, 0x50, 0x41, 0x52, 0x54 } + +@@ -87,6 +91,51 @@ struct grub_gpt_partentry + char name[72]; + } GRUB_PACKED __attribute__ ((aligned(8))); + ++enum grub_gpt_part_attr_offset ++{ ++ /* Standard partition attribute bits defined by UEFI. */ ++ GRUB_GPT_PART_ATTR_OFFSET_REQUIRED = 0, ++ GRUB_GPT_PART_ATTR_OFFSET_NO_BLOCK_IO_PROTOCOL = 1, ++ GRUB_GPT_PART_ATTR_OFFSET_LEGACY_BIOS_BOOTABLE = 2, ++ ++ /* De facto standard attribute bits defined by Microsoft and reused by ++ * http://www.freedesktop.org/wiki/Specifications/DiscoverablePartitionsSpec */ ++ GRUB_GPT_PART_ATTR_OFFSET_READ_ONLY = 60, ++ GRUB_GPT_PART_ATTR_OFFSET_NO_AUTO = 63, ++ ++ /* Partition attributes for priority based selection, ++ * Currently only valid for PARTITION_TYPE_USR_X86_64. ++ * TRIES_LEFT and PRIORITY are 4 bit wide fields. */ ++ GRUB_GPT_PART_ATTR_OFFSET_GPTPRIO_PRIORITY = 48, ++ GRUB_GPT_PART_ATTR_OFFSET_GPTPRIO_TRIES_LEFT = 52, ++ GRUB_GPT_PART_ATTR_OFFSET_GPTPRIO_SUCCESSFUL = 56, ++}; ++ ++/* Helpers for reading/writing partition attributes. */ ++static inline grub_uint64_t ++grub_gpt_entry_attribute (struct grub_gpt_partentry *entry, ++ enum grub_gpt_part_attr_offset offset, ++ unsigned int bits) ++{ ++ grub_uint64_t attrib = grub_le_to_cpu64 (entry->attrib); ++ ++ return (attrib >> offset) & ((1ULL << bits) - 1); ++} ++ ++static inline void ++grub_gpt_entry_set_attribute (struct grub_gpt_partentry *entry, ++ grub_uint64_t value, ++ enum grub_gpt_part_attr_offset offset, ++ unsigned int bits) ++{ ++ grub_uint64_t attrib, mask; ++ ++ mask = (((1ULL << bits) - 1) << offset); ++ attrib = grub_le_to_cpu64 (entry->attrib) & ~mask; ++ attrib |= ((value << offset) & mask); ++ entry->attrib = grub_cpu_to_le64 (attrib); ++} ++ + /* Basic GPT partmap module. */ + grub_err_t + grub_gpt_partition_map_iterate (grub_disk_t disk, +diff --git a/tests/gptprio_test.in b/tests/gptprio_test.in +new file mode 100644 +index 0000000..f4aea0d +--- /dev/null ++++ b/tests/gptprio_test.in +@@ -0,0 +1,150 @@ ++#! /bin/bash ++set -e ++ ++# Copyright (C) 2010 Free Software Foundation, Inc. ++# Copyright (C) 2014 CoreOS, Inc. ++# ++# GRUB is free software: you can redistribute it and/or modify ++# it under the terms of the GNU General Public License as published by ++# the Free Software Foundation, either version 3 of the License, or ++# (at your option) any later version. ++# ++# GRUB is distributed in the hope that it will be useful, ++# but WITHOUT ANY WARRANTY; without even the implied warranty of ++# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++# GNU General Public License for more details. ++# ++# You should have received a copy of the GNU General Public License ++# along with GRUB. If not, see . ++ ++sgdisk=sgdisk ++grubshell=@builddir@/grub-shell ++ ++if ! which "${sgdisk}" >/dev/null 2>&1; then ++ echo "sgdisk not installed; cannot test gptprio." ++ exit 77 ++fi ++ ++. "@builddir@/grub-core/modinfo.sh" ++ ++case "${grub_modinfo_target_cpu}-${grub_modinfo_platform}" in ++ mips-qemu_mips | mipsel-qemu_mips | i386-qemu | i386-multiboot | i386-coreboot | mipsel-loongson) ++ disk=ata0 ++ ;; ++ powerpc-ieee1275) ++ disk=ieee1275//pci@80000000/mac-io@4/ata-3@20000/disk@0 ++ # FIXME: QEMU firmware has bugs which prevent it from accessing hard disk w/o recognised label. ++ exit 0 ++ ;; ++ sparc64-ieee1275) ++ disk=ieee1275//pci@1fe\,0/pci-ata@5/ide0@500/disk@0 ++ # FIXME: QEMU firmware has bugs which prevent it from accessing hard disk w/o recognised label. ++ exit 0 ++ ;; ++ i386-ieee1275) ++ disk=ieee1275/d ++ # FIXME: QEMU firmware has bugs which prevent it from accessing hard disk w/o recognised label. ++ exit 0 ++ ;; ++ mips-arc) ++ # FIXME: ARC firmware has bugs which prevent it from accessing hard disk w/o dvh disklabel. ++ exit 0 ;; ++ mipsel-arc) ++ disk=arc/scsi0/disk0/rdisk0 ++ ;; ++ *) ++ disk=hd0 ++ ;; ++esac ++img1="`mktemp "${TMPDIR:-/tmp}/tmp.XXXXXXXXXX"`" || exit 1 ++trap "rm -f '${img1}'" EXIT ++ ++prio_type="5dfbf5f4-2848-4bac-aa5e-0d9a20b745a6" ++declare -a prio_uuid ++prio_uuid[2]="9b003904-d006-4ab3-97f1-73f547b7af1a" ++prio_uuid[3]="1aa5a658-5b02-414d-9b71-f7e6c151f0cd" ++prio_uuid[4]="8aa0240d-98af-42b0-b32a-ccbe0572d62b" ++ ++create_disk_image () { ++ rm -f "${img1}" ++ dd if=/dev/zero of="${img1}" bs=512 count=1 seek=100 status=none ++ ${sgdisk} \ ++ -n 1:0:+1 -c 1:ESP -t 1:ef00 \ ++ -n 2:0:+1 -c 2:A -t 2:"${prio_type}" -u 2:"${prio_uuid[2]}" \ ++ -n 3:0:+1 -c 3:B -t 3:"${prio_type}" -u 3:"${prio_uuid[3]}" \ ++ -n 4:0:+1 -c 4:C -t 4:"${prio_type}" -u 4:"${prio_uuid[4]}" \ ++ "${img1}" >/dev/null ++} ++ ++ ++fmt_prio () { ++ priority=$(( ( $1 & 15 ) << 48 )) ++ tries=$(( ( $2 & 15 ) << 52 )) ++ success=$(( ( $3 & 1 ) << 56 )) ++ printf %016x $(( priority | tries | success )) ++} ++ ++set_prio () { ++ part="$1" ++ attr=$(fmt_prio $2 $3 $4) ++ ${sgdisk} -A "${part}:=:${attr}" "${img1}" >/dev/null ++} ++ ++check_prio () { ++ part="$1" ++ expect=$(fmt_prio $2 $3 $4) ++ result=$(LANG=C ${sgdisk} -i "${part}" "${img1}" \ ++ | awk '/^Attribute flags: / {print $3}') ++ if [[ "${expect}" != "${result}" ]]; then ++ echo "Partition ${part} has attributes ${result}, not ${expect}" >&2 ++ exit 1 ++ fi ++} ++ ++run_next() { ++ "${grubshell}" --disk="${img1}" --modules=gptprio < +Date: Sat, 15 Nov 2014 13:27:13 -0800 +Subject: [PATCH] gpt: split out checksum recomputation + +For basic data modifications the full repair function is overkill. +--- + grub-core/lib/gpt.c | 30 ++++++++++++++++++++---------- + include/grub/gpt_partition.h | 3 +++ + 2 files changed, 23 insertions(+), 10 deletions(-) + +diff --git a/grub-core/lib/gpt.c b/grub-core/lib/gpt.c +index 67ffdf7..1982340 100644 +--- a/grub-core/lib/gpt.c ++++ b/grub-core/lib/gpt.c +@@ -293,7 +293,6 @@ grub_err_t + grub_gpt_repair (grub_disk_t disk, grub_gpt_t gpt) + { + grub_uint64_t backup_header, backup_entries; +- grub_uint32_t crc; + + if (disk->log_sector_size != gpt->log_sector_size) + return grub_error (GRUB_ERR_NOT_IMPLEMENTED_YET, +@@ -331,13 +330,32 @@ grub_gpt_repair (grub_disk_t disk, grub_gpt_t gpt) + gpt->backup.alternate_lba = gpt->primary.header_lba; + gpt->backup.partitions = grub_cpu_to_le64 (backup_entries); + ++ /* Recompute checksums. */ ++ if (grub_gpt_update_checksums (gpt)) ++ return grub_errno; ++ ++ /* Sanity check. */ ++ if (grub_gpt_header_check (&gpt->primary, gpt->log_sector_size)) ++ return grub_error (GRUB_ERR_BUG, "Generated invalid GPT primary header"); ++ ++ if (grub_gpt_header_check (&gpt->backup, gpt->log_sector_size)) ++ return grub_error (GRUB_ERR_BUG, "Generated invalid GPT backup header"); ++ ++ gpt->status |= GRUB_GPT_BOTH_VALID; ++ return GRUB_ERR_NONE; ++} ++ ++grub_err_t ++grub_gpt_update_checksums (grub_gpt_t gpt) ++{ ++ grub_uint32_t crc; ++ + /* Writing headers larger than our header structure are unsupported. */ + gpt->primary.headersize = + grub_cpu_to_le32_compile_time (sizeof (gpt->primary)); + gpt->backup.headersize = + grub_cpu_to_le32_compile_time (sizeof (gpt->backup)); + +- /* Recompute checksums. */ + if (grub_gpt_lecrc32 (gpt->entries, gpt->entries_size, &crc)) + return grub_errno; + +@@ -350,14 +368,6 @@ grub_gpt_repair (grub_disk_t disk, grub_gpt_t gpt) + if (grub_gpt_header_lecrc32 (&gpt->backup, &gpt->backup.crc32)) + return grub_errno; + +- /* Sanity check. */ +- if (grub_gpt_header_check (&gpt->primary, gpt->log_sector_size)) +- return grub_error (GRUB_ERR_BUG, "Generated invalid GPT primary header"); +- +- if (grub_gpt_header_check (&gpt->backup, gpt->log_sector_size)) +- return grub_error (GRUB_ERR_BUG, "Generated invalid GPT backup header"); +- +- gpt->status |= GRUB_GPT_BOTH_VALID; + return GRUB_ERR_NONE; + } + +diff --git a/include/grub/gpt_partition.h b/include/grub/gpt_partition.h +index fc4f0f5..7fbdf4c 100644 +--- a/include/grub/gpt_partition.h ++++ b/include/grub/gpt_partition.h +@@ -200,6 +200,9 @@ grub_gpt_t grub_gpt_read (grub_disk_t disk); + /* Sync up primary and backup headers, recompute checksums. */ + grub_err_t grub_gpt_repair (grub_disk_t disk, grub_gpt_t gpt); + ++/* Recompute checksums, must be called after modifying GPT data. */ ++grub_err_t grub_gpt_update_checksums (grub_gpt_t gpt); ++ + /* Write headers and entry tables back to disk. */ + grub_err_t grub_gpt_write (grub_disk_t disk, grub_gpt_t gpt); + +-- +2.21.3 + diff --git a/packages/grub/0011-gpt-move-gpt-guid-printing-function-to-common-librar.patch b/packages/grub/0011-gpt-move-gpt-guid-printing-function-to-common-librar.patch new file mode 100644 index 00000000..b91b5ae5 --- /dev/null +++ b/packages/grub/0011-gpt-move-gpt-guid-printing-function-to-common-librar.patch @@ -0,0 +1,80 @@ +From 44c916ad1a8ae8fbd3743f269fd13cc677a932da Mon Sep 17 00:00:00 2001 +From: Michael Marineau +Date: Thu, 27 Nov 2014 12:55:53 -0800 +Subject: [PATCH] gpt: move gpt guid printing function to common library + +--- + grub-core/commands/gptprio.c | 16 ++-------------- + grub-core/lib/gpt.c | 13 +++++++++++++ + include/grub/gpt_partition.h | 4 ++++ + 3 files changed, 19 insertions(+), 14 deletions(-) + +diff --git a/grub-core/commands/gptprio.c b/grub-core/commands/gptprio.c +index 1e2e06c..2415747 100644 +--- a/grub-core/commands/gptprio.c ++++ b/grub-core/commands/gptprio.c +@@ -141,20 +141,8 @@ grub_find_next (const char *disk_name, + if (!*part_name) + goto done; + +- *part_guid = +- grub_xasprintf ("%08x-%04x-%04x-%02x%02x-%02x%02x%02x%02x%02x%02x", +- grub_le_to_cpu32 (part_found->guid.data1), +- grub_le_to_cpu16 (part_found->guid.data2), +- grub_le_to_cpu16 (part_found->guid.data3), +- part_found->guid.data4[0], +- part_found->guid.data4[1], +- part_found->guid.data4[2], +- part_found->guid.data4[3], +- part_found->guid.data4[4], +- part_found->guid.data4[5], +- part_found->guid.data4[6], +- part_found->guid.data4[7]); +- if (!*part_name) ++ *part_guid = grub_gpt_guid_to_str (&part_found->guid); ++ if (!*part_guid) + goto done; + + grub_errno = GRUB_ERR_NONE; +diff --git a/grub-core/lib/gpt.c b/grub-core/lib/gpt.c +index 1982340..9a1835b 100644 +--- a/grub-core/lib/gpt.c ++++ b/grub-core/lib/gpt.c +@@ -31,6 +31,19 @@ GRUB_MOD_LICENSE ("GPLv3+"); + static grub_uint8_t grub_gpt_magic[] = GRUB_GPT_HEADER_MAGIC; + + ++char * ++grub_gpt_guid_to_str (grub_gpt_guid_t *guid) ++{ ++ return grub_xasprintf ("%08x-%04x-%04x-%02x%02x-%02x%02x%02x%02x%02x%02x", ++ grub_le_to_cpu32 (guid->data1), ++ grub_le_to_cpu16 (guid->data2), ++ grub_le_to_cpu16 (guid->data3), ++ guid->data4[0], guid->data4[1], ++ guid->data4[2], guid->data4[3], ++ guid->data4[4], guid->data4[5], ++ guid->data4[6], guid->data4[7]); ++} ++ + static grub_uint64_t + grub_gpt_size_to_sectors (grub_gpt_t gpt, grub_size_t size) + { +diff --git a/include/grub/gpt_partition.h b/include/grub/gpt_partition.h +index 7fbdf4c..dc1bcca 100644 +--- a/include/grub/gpt_partition.h ++++ b/include/grub/gpt_partition.h +@@ -33,6 +33,10 @@ struct grub_gpt_guid + typedef struct grub_gpt_guid grub_gpt_guid_t; + typedef struct grub_gpt_guid grub_gpt_part_guid_t; + ++/* Format the raw little-endian GUID as a newly allocated string. */ ++char * grub_gpt_guid_to_str (grub_gpt_guid_t *guid); ++ ++ + #define GRUB_GPT_GUID_INIT(a, b, c, d1, d2, d3, d4, d5, d6, d7, d8) \ + { \ + grub_cpu_to_le32_compile_time (a), \ +-- +2.21.3 + diff --git a/packages/grub/0012-gpt-switch-partition-names-to-a-16-bit-type.patch b/packages/grub/0012-gpt-switch-partition-names-to-a-16-bit-type.patch new file mode 100644 index 00000000..7383f4f7 --- /dev/null +++ b/packages/grub/0012-gpt-switch-partition-names-to-a-16-bit-type.patch @@ -0,0 +1,27 @@ +From d424d55607bdfbbd0f5f0a220ea582ff88106931 Mon Sep 17 00:00:00 2001 +From: Michael Marineau +Date: Thu, 27 Nov 2014 14:54:27 -0800 +Subject: [PATCH] gpt: switch partition names to a 16 bit type + +In UEFI/GPT strings are UTF-16 so use a uint16 to make dealing with the +string practical. +--- + include/grub/gpt_partition.h | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/include/grub/gpt_partition.h b/include/grub/gpt_partition.h +index dc1bcca..a44c0d5 100644 +--- a/include/grub/gpt_partition.h ++++ b/include/grub/gpt_partition.h +@@ -92,7 +92,7 @@ struct grub_gpt_partentry + grub_uint64_t start; + grub_uint64_t end; + grub_uint64_t attrib; +- char name[72]; ++ grub_uint16_t name[36]; + } GRUB_PACKED __attribute__ ((aligned(8))); + + enum grub_gpt_part_attr_offset +-- +2.21.3 + diff --git a/packages/grub/0013-tests-add-some-partitions-to-the-gpt-unit-test-data.patch b/packages/grub/0013-tests-add-some-partitions-to-the-gpt-unit-test-data.patch new file mode 100644 index 00000000..aefdd71f --- /dev/null +++ b/packages/grub/0013-tests-add-some-partitions-to-the-gpt-unit-test-data.patch @@ -0,0 +1,127 @@ +From 564616c70c7a914f385cfa36e0bb214cf75723a3 Mon Sep 17 00:00:00 2001 +From: Michael Marineau +Date: Thu, 27 Nov 2014 15:49:57 -0800 +Subject: [PATCH] tests: add some partitions to the gpt unit test data + +--- + tests/gpt_unit_test.c | 65 ++++++++++++++++++++++++++++++++++++------- + 1 file changed, 55 insertions(+), 10 deletions(-) + +diff --git a/tests/gpt_unit_test.c b/tests/gpt_unit_test.c +index 86e4364..5692a5a 100644 +--- a/tests/gpt_unit_test.c ++++ b/tests/gpt_unit_test.c +@@ -89,12 +89,12 @@ struct test_data + }; + + +-/* Sample primary GPT header for an empty 1MB disk. */ ++/* Sample primary GPT header for a 1MB disk. */ + static const struct grub_gpt_header example_primary = { + .magic = GRUB_GPT_HEADER_MAGIC, + .version = GRUB_GPT_HEADER_VERSION, + .headersize = sizeof (struct grub_gpt_header), +- .crc32 = grub_cpu_to_le32_compile_time (0x7cd8642c), ++ .crc32 = grub_cpu_to_le32_compile_time (0xb985abe0), + .header_lba = grub_cpu_to_le64_compile_time (PRIMARY_HEADER_SECTOR), + .alternate_lba = grub_cpu_to_le64_compile_time (BACKUP_HEADER_SECTOR), + .start = grub_cpu_to_le64_compile_time (DATA_START_SECTOR), +@@ -104,7 +104,52 @@ static const struct grub_gpt_header example_primary = { + .partitions = grub_cpu_to_le64_compile_time (PRIMARY_TABLE_SECTOR), + .maxpart = grub_cpu_to_le32_compile_time (TABLE_ENTRIES), + .partentry_size = grub_cpu_to_le32_compile_time (ENTRY_SIZE), +- .partentry_crc32 = grub_cpu_to_le32_compile_time (0xab54d286), ++ .partentry_crc32 = grub_cpu_to_le32_compile_time (0x074e052c), ++}; ++ ++static const struct grub_gpt_partentry example_entries[TABLE_ENTRIES] = { ++ { ++ .type = GRUB_GPT_PARTITION_TYPE_EFI_SYSTEM, ++ .guid = GRUB_GPT_GUID_INIT (0xa0f1792e, 0xb4ce, 0x4136, 0xbc, 0xf2, ++ 0x1a, 0xfc, 0x13, 0x3c, 0x28, 0x28), ++ .start = grub_cpu_to_le64_compile_time (DATA_START_SECTOR), ++ .end = grub_cpu_to_le64_compile_time (0x3f), ++ .attrib = 0x0, ++ .name = { ++ grub_cpu_to_le16_compile_time ('E'), ++ grub_cpu_to_le16_compile_time ('F'), ++ grub_cpu_to_le16_compile_time ('I'), ++ grub_cpu_to_le16_compile_time (' '), ++ grub_cpu_to_le16_compile_time ('S'), ++ grub_cpu_to_le16_compile_time ('Y'), ++ grub_cpu_to_le16_compile_time ('S'), ++ grub_cpu_to_le16_compile_time ('T'), ++ grub_cpu_to_le16_compile_time ('E'), ++ grub_cpu_to_le16_compile_time ('M'), ++ 0x0, ++ } ++ }, ++ { ++ .type = GRUB_GPT_PARTITION_TYPE_BIOS_BOOT, ++ .guid = GRUB_GPT_GUID_INIT (0x876c898d, 0x1b40, 0x4727, 0xa1, 0x61, ++ 0xed, 0xf9, 0xb5, 0x48, 0x66, 0x74), ++ .start = grub_cpu_to_le64_compile_time (0x40), ++ .end = grub_cpu_to_le64_compile_time (0x7f), ++ .attrib = grub_cpu_to_le64_compile_time ( ++ 1ULL << GRUB_GPT_PART_ATTR_OFFSET_LEGACY_BIOS_BOOTABLE), ++ .name = { ++ grub_cpu_to_le16_compile_time ('B'), ++ grub_cpu_to_le16_compile_time ('I'), ++ grub_cpu_to_le16_compile_time ('O'), ++ grub_cpu_to_le16_compile_time ('S'), ++ grub_cpu_to_le16_compile_time (' '), ++ grub_cpu_to_le16_compile_time ('B'), ++ grub_cpu_to_le16_compile_time ('O'), ++ grub_cpu_to_le16_compile_time ('O'), ++ grub_cpu_to_le16_compile_time ('T'), ++ 0x0, ++ } ++ }, + }; + + /* And the backup header. */ +@@ -112,7 +157,7 @@ static const struct grub_gpt_header example_backup = { + .magic = GRUB_GPT_HEADER_MAGIC, + .version = GRUB_GPT_HEADER_VERSION, + .headersize = sizeof (struct grub_gpt_header), +- .crc32 = grub_cpu_to_le32_compile_time (0xcfaa4a27), ++ .crc32 = grub_cpu_to_le32_compile_time (0x0af785eb), + .header_lba = grub_cpu_to_le64_compile_time (BACKUP_HEADER_SECTOR), + .alternate_lba = grub_cpu_to_le64_compile_time (PRIMARY_HEADER_SECTOR), + .start = grub_cpu_to_le64_compile_time (DATA_START_SECTOR), +@@ -122,7 +167,7 @@ static const struct grub_gpt_header example_backup = { + .partitions = grub_cpu_to_le64_compile_time (BACKUP_TABLE_SECTOR), + .maxpart = grub_cpu_to_le32_compile_time (TABLE_ENTRIES), + .partentry_size = grub_cpu_to_le32_compile_time (ENTRY_SIZE), +- .partentry_crc32 = grub_cpu_to_le32_compile_time (0xab54d286), ++ .partentry_crc32 = grub_cpu_to_le32_compile_time (0x074e052c), + }; + + /* Sample protective MBR for the same 1MB disk. Note, this matches +@@ -192,6 +237,10 @@ reset_disk (struct test_data *data) + memcpy (&data->raw->mbr, &example_pmbr, sizeof (data->raw->mbr)); + memcpy (&data->raw->primary_header, &example_primary, + sizeof (data->raw->primary_header)); ++ memcpy (&data->raw->primary_entries, &example_entries, ++ sizeof (data->raw->primary_entries)); ++ memcpy (&data->raw->backup_entries, &example_entries, ++ sizeof (data->raw->backup_entries)); + memcpy (&data->raw->backup_header, &example_backup, + sizeof (data->raw->backup_header)); + +@@ -270,11 +319,7 @@ read_disk (struct test_data *data) + + gpt = grub_gpt_read (data->dev->disk); + if (gpt == NULL) +- { +- grub_print_error (); +- grub_fatal ("grub_gpt_read failed"); +- } +- ++ grub_fatal ("grub_gpt_read failed: %s", grub_errmsg); + + return gpt; + } +-- +2.21.3 + diff --git a/packages/grub/0014-gpt-add-search-by-partition-label-and-uuid-commands.patch b/packages/grub/0014-gpt-add-search-by-partition-label-and-uuid-commands.patch new file mode 100644 index 00000000..0e7697c0 --- /dev/null +++ b/packages/grub/0014-gpt-add-search-by-partition-label-and-uuid-commands.patch @@ -0,0 +1,452 @@ +From 334b58a122bad34c7efa1b1ea6d58389477fd255 Mon Sep 17 00:00:00 2001 +From: Michael Marineau +Date: Thu, 27 Nov 2014 16:34:21 -0800 +Subject: [PATCH] gpt: add search by partition label and uuid commands + +Builds on the existing filesystem search code. Only for GPT right now. + +[markubo: Update to grub-2.06-42.amzn2022. Search functions take a more +general search_flags parameter now instead of a no_floppy flag.] + +Signed-off-by: Markus Boehme + +--- + Makefile.util.def | 2 + + grub-core/Makefile.core.def | 10 +++ + grub-core/commands/search.c | 49 +++++++++++++++ + grub-core/commands/search_part_label.c | 5 ++ + grub-core/commands/search_part_uuid.c | 5 ++ + grub-core/commands/search_wrap.c | 10 +++ + grub-core/lib/gpt.c | 64 ++++++++++++++++++++ + include/grub/gpt_partition.h | 16 +++++ + include/grub/search.h | 6 ++ + tests/gpt_unit_test.c | 84 ++++++++++++++++++++++++++ + 10 files changed, 251 insertions(+) + create mode 100644 grub-core/commands/search_part_label.c + create mode 100644 grub-core/commands/search_part_uuid.c + +diff --git a/Makefile.util.def b/Makefile.util.def +index eb4bc90..8f74405 100644 +--- a/Makefile.util.def ++++ b/Makefile.util.def +@@ -1406,6 +1406,8 @@ program = { + name = gpt_unit_test; + common = tests/gpt_unit_test.c; + common = tests/lib/unit_test.c; ++ common = grub-core/commands/search_part_label.c; ++ common = grub-core/commands/search_part_uuid.c; + common = grub-core/disk/host.c; + common = grub-core/kern/emu/hostfs.c; + common = grub-core/lib/gpt.c; +diff --git a/grub-core/Makefile.core.def b/grub-core/Makefile.core.def +index 393aecd..3cde624 100644 +--- a/grub-core/Makefile.core.def ++++ b/grub-core/Makefile.core.def +@@ -1152,6 +1152,16 @@ module = { + common = commands/search_label.c; + }; + ++module = { ++ name = search_part_uuid; ++ common = commands/search_part_uuid.c; ++}; ++ ++module = { ++ name = search_part_label; ++ common = commands/search_part_label.c; ++}; ++ + module = { + name = setpci; + common = commands/setpci.c; +diff --git a/grub-core/commands/search.c b/grub-core/commands/search.c +index 57d26ce..bb0c7cb 100644 +--- a/grub-core/commands/search.c ++++ b/grub-core/commands/search.c +@@ -30,6 +30,9 @@ + #include + #include + #include ++#if defined(DO_SEARCH_PART_UUID) || defined(DO_SEARCH_PART_LABEL) ++#include ++#endif + + GRUB_MOD_LICENSE ("GPLv3+"); + +@@ -109,6 +112,44 @@ iterate_device (const char *name, void *data) + } + grub_free (buf); + } ++#elif defined(DO_SEARCH_PART_UUID) ++ { ++ grub_device_t dev; ++ char *quid; ++ ++ dev = grub_device_open (name); ++ if (dev) ++ { ++ if (grub_gpt_part_uuid (dev, &quid) == GRUB_ERR_NONE) ++ { ++ if (grub_strcasecmp (quid, ctx->key) == 0) ++ found = 1; ++ ++ grub_free (quid); ++ } ++ ++ grub_device_close (dev); ++ } ++ } ++#elif defined(DO_SEARCH_PART_LABEL) ++ { ++ grub_device_t dev; ++ char *quid; ++ ++ dev = grub_device_open (name); ++ if (dev) ++ { ++ if (grub_gpt_part_label (dev, &quid) == GRUB_ERR_NONE) ++ { ++ if (grub_strcmp (quid, ctx->key) == 0) ++ found = 1; ++ ++ grub_free (quid); ++ } ++ ++ grub_device_close (dev); ++ } ++ } + #else + { + /* SEARCH_FS_UUID or SEARCH_LABEL */ +@@ -332,6 +373,10 @@ static grub_command_t cmd; + + #ifdef DO_SEARCH_FILE + GRUB_MOD_INIT(search_fs_file) ++#elif defined(DO_SEARCH_PART_UUID) ++GRUB_MOD_INIT(search_part_uuid) ++#elif defined(DO_SEARCH_PART_LABEL) ++GRUB_MOD_INIT(search_part_label) + #elif defined (DO_SEARCH_FS_UUID) + GRUB_MOD_INIT(search_fs_uuid) + #else +@@ -346,6 +391,10 @@ GRUB_MOD_INIT(search_label) + + #ifdef DO_SEARCH_FILE + GRUB_MOD_FINI(search_fs_file) ++#elif defined(DO_SEARCH_PART_UUID) ++GRUB_MOD_FINI(search_part_uuid) ++#elif defined(DO_SEARCH_PART_LABEL) ++GRUB_MOD_FINI(search_part_label) + #elif defined (DO_SEARCH_FS_UUID) + GRUB_MOD_FINI(search_fs_uuid) + #else +diff --git a/grub-core/commands/search_part_label.c b/grub-core/commands/search_part_label.c +new file mode 100644 +index 0000000..ca906cb +--- /dev/null ++++ b/grub-core/commands/search_part_label.c +@@ -0,0 +1,5 @@ ++#define DO_SEARCH_PART_LABEL 1 ++#define FUNC_NAME grub_search_part_label ++#define COMMAND_NAME "search.part_label" ++#define HELP_MESSAGE N_("Search devices by partition label. If VARIABLE is specified, the first device found is set to a variable.") ++#include "search.c" +diff --git a/grub-core/commands/search_part_uuid.c b/grub-core/commands/search_part_uuid.c +new file mode 100644 +index 0000000..2d1d3d0 +--- /dev/null ++++ b/grub-core/commands/search_part_uuid.c +@@ -0,0 +1,5 @@ ++#define DO_SEARCH_PART_UUID 1 ++#define FUNC_NAME grub_search_part_uuid ++#define COMMAND_NAME "search.part_uuid" ++#define HELP_MESSAGE N_("Search devices by partition UUID. If VARIABLE is specified, the first device found is set to a variable.") ++#include "search.c" +diff --git a/grub-core/commands/search_wrap.c b/grub-core/commands/search_wrap.c +index 0b62acf..82f8e63 100644 +--- a/grub-core/commands/search_wrap.c ++++ b/grub-core/commands/search_wrap.c +@@ -36,6 +36,10 @@ static const struct grub_arg_option options[] = + 0, 0}, + {"fs-uuid", 'u', 0, N_("Search devices by a filesystem UUID."), + 0, 0}, ++ {"part-label", 'L', 0, N_("Search devices by a partition label."), ++ 0, 0}, ++ {"part-uuid", 'U', 0, N_("Search devices by a partition UUID."), ++ 0, 0}, + {"set", 's', GRUB_ARG_OPTION_OPTIONAL, + N_("Set a variable to the first device found."), N_("VARNAME"), + ARG_TYPE_STRING}, +@@ -72,6 +76,8 @@ enum options + SEARCH_FILE, + SEARCH_LABEL, + SEARCH_FS_UUID, ++ SEARCH_PART_LABEL, ++ SEARCH_PART_UUID, + SEARCH_SET, + SEARCH_NO_FLOPPY, + SEARCH_EFIDISK_ONLY, +@@ -193,6 +199,10 @@ grub_cmd_search (grub_extcmd_context_t ctxt, int argc, char **args) + grub_search_label (id, var, flags, hints, nhints); + else if (state[SEARCH_FS_UUID].set) + grub_search_fs_uuid (id, var, flags, hints, nhints); ++ else if (state[SEARCH_PART_LABEL].set) ++ grub_search_part_label (id, var, flags, hints, nhints); ++ else if (state[SEARCH_PART_UUID].set) ++ grub_search_part_uuid (id, var, flags, hints, nhints); + else if (state[SEARCH_FILE].set) + grub_search_fs_file (id, var, flags, hints, nhints); + else +diff --git a/grub-core/lib/gpt.c b/grub-core/lib/gpt.c +index 9a1835b..10a4b85 100644 +--- a/grub-core/lib/gpt.c ++++ b/grub-core/lib/gpt.c +@@ -18,7 +18,9 @@ + * along with GRUB. If not, see . + */ + ++#include + #include ++#include + #include + #include + #include +@@ -44,6 +46,68 @@ grub_gpt_guid_to_str (grub_gpt_guid_t *guid) + guid->data4[6], guid->data4[7]); + } + ++static grub_err_t ++grub_gpt_device_partentry (grub_device_t device, ++ struct grub_gpt_partentry *entry) ++{ ++ grub_disk_t disk = device->disk; ++ grub_partition_t p; ++ grub_err_t err; ++ ++ if (!disk || !disk->partition) ++ return grub_error (GRUB_ERR_BUG, "not a partition"); ++ ++ if (grub_strcmp (disk->partition->partmap->name, "gpt")) ++ return grub_error (GRUB_ERR_BAD_ARGUMENT, "not a GPT partition"); ++ ++ p = disk->partition; ++ disk->partition = p->parent; ++ err = grub_disk_read (disk, p->offset, p->index, sizeof (*entry), entry); ++ disk->partition = p; ++ ++ return err; ++} ++ ++grub_err_t ++grub_gpt_part_label (grub_device_t device, char **label) ++{ ++ struct grub_gpt_partentry entry; ++ const grub_size_t name_len = ARRAY_SIZE (entry.name); ++ const grub_size_t label_len = name_len * GRUB_MAX_UTF8_PER_UTF16 + 1; ++ grub_size_t i; ++ grub_uint8_t *end; ++ ++ if (grub_gpt_device_partentry (device, &entry)) ++ return grub_errno; ++ ++ *label = grub_malloc (label_len); ++ if (!*label) ++ return grub_errno; ++ ++ for (i = 0; i < name_len; i++) ++ entry.name[i] = grub_le_to_cpu16 (entry.name[i]); ++ ++ end = grub_utf16_to_utf8 ((grub_uint8_t *) *label, entry.name, name_len); ++ *end = '\0'; ++ ++ return GRUB_ERR_NONE; ++} ++ ++grub_err_t ++grub_gpt_part_uuid (grub_device_t device, char **uuid) ++{ ++ struct grub_gpt_partentry entry; ++ ++ if (grub_gpt_device_partentry (device, &entry)) ++ return grub_errno; ++ ++ *uuid = grub_gpt_guid_to_str (&entry.guid); ++ if (!*uuid) ++ return grub_errno; ++ ++ return GRUB_ERR_NONE; ++} ++ + static grub_uint64_t + grub_gpt_size_to_sectors (grub_gpt_t gpt, grub_size_t size) + { +diff --git a/include/grub/gpt_partition.h b/include/grub/gpt_partition.h +index a44c0d5..7b04080 100644 +--- a/include/grub/gpt_partition.h ++++ b/include/grub/gpt_partition.h +@@ -49,6 +49,10 @@ char * grub_gpt_guid_to_str (grub_gpt_guid_t *guid); + GRUB_GPT_GUID_INIT (0x0, 0x0, 0x0, \ + 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0) + ++#define GRUB_GPT_PARTITION_TYPE_EFI_SYSTEM \ ++ GRUB_GPT_GUID_INIT (0xc12a7328, 0xf81f, 0x11d2, \ ++ 0xba, 0x4b, 0x00, 0xa0, 0xc9, 0x3e, 0xc9, 0x3b) ++ + #define GRUB_GPT_PARTITION_TYPE_BIOS_BOOT \ + GRUB_GPT_GUID_INIT (0x21686148, 0x6449, 0x6e6f, \ + 0x74, 0x4e, 0x65, 0x65, 0x64, 0x45, 0x46, 0x49) +@@ -216,4 +220,16 @@ grub_err_t grub_gpt_pmbr_check (struct grub_msdos_partition_mbr *mbr); + grub_err_t grub_gpt_header_check (struct grub_gpt_header *gpt, + unsigned int log_sector_size); + ++ ++/* Utilities for simple partition data lookups, usage is intended to ++ * be similar to fs->label and fs->uuid functions. */ ++ ++/* Return the partition label of the device DEVICE in LABEL. ++ * The label is in a new buffer and should be freed by the caller. */ ++grub_err_t grub_gpt_part_label (grub_device_t device, char **label); ++ ++/* Return the partition uuid of the device DEVICE in UUID. ++ * The label is in a new buffer and should be freed by the caller. */ ++grub_err_t grub_gpt_part_uuid (grub_device_t device, char **uuid); ++ + #endif /* ! GRUB_GPT_PARTITION_HEADER */ +diff --git a/include/grub/search.h b/include/grub/search.h +index 4190aeb..66722a6 100644 +--- a/include/grub/search.h ++++ b/include/grub/search.h +@@ -34,5 +34,11 @@ void grub_search_fs_uuid (const char *key, const char *var, + void grub_search_label (const char *key, const char *var, + enum search_flags flags, + char **hints, unsigned nhints); ++void grub_search_part_uuid (const char *key, const char *var, ++ enum search_flags flags, ++ char **hints, unsigned nhints); ++void grub_search_part_label (const char *key, const char *var, ++ enum search_flags flags, ++ char **hints, unsigned nhints); + + #endif +diff --git a/tests/gpt_unit_test.c b/tests/gpt_unit_test.c +index 5692a5a..deb55a9 100644 +--- a/tests/gpt_unit_test.c ++++ b/tests/gpt_unit_test.c +@@ -21,10 +21,12 @@ + #include + #include + #include ++#include + #include + #include + #include + #include ++#include + #include + + #include +@@ -534,6 +536,84 @@ repair_test (void) + + close_disk (&data); + } ++ ++static void ++search_label_test (void) ++{ ++ struct test_data data; ++ const char *test_result; ++ char *expected_result; ++ ++ open_disk (&data); ++ ++ expected_result = grub_xasprintf ("%s,gpt1", data.dev->disk->name); ++ grub_env_unset ("test_result"); ++ grub_search_part_label ("EFI SYSTEM", "test_result", 0, NULL, 0); ++ test_result = grub_env_get ("test_result"); ++ grub_test_assert (test_result && strcmp (test_result, expected_result) == 0, ++ "wrong device: %s (%s)", test_result, expected_result); ++ grub_free (expected_result); ++ ++ expected_result = grub_xasprintf ("%s,gpt2", data.dev->disk->name); ++ grub_env_unset ("test_result"); ++ grub_search_part_label ("BIOS BOOT", "test_result", 0, NULL, 0); ++ test_result = grub_env_get ("test_result"); ++ grub_test_assert (test_result && strcmp (test_result, expected_result) == 0, ++ "wrong device: %s (%s)", test_result, expected_result); ++ grub_free (expected_result); ++ ++ grub_env_unset ("test_result"); ++ grub_search_part_label ("bogus name", "test_result", 0, NULL, 0); ++ test_result = grub_env_get ("test_result"); ++ grub_test_assert (test_result == NULL, ++ "unexpected device: %s", test_result); ++ grub_test_assert (grub_errno == GRUB_ERR_FILE_NOT_FOUND, ++ "unexpected error: %s", grub_errmsg); ++ grub_errno = GRUB_ERR_NONE; ++ ++ close_disk (&data); ++} ++ ++static void ++search_uuid_test (void) ++{ ++ struct test_data data; ++ const char gpt1_uuid[] = "A0F1792E-B4CE-4136-BCF2-1AFC133C2828"; ++ const char gpt2_uuid[] = "876c898d-1b40-4727-a161-edf9b5486674"; ++ const char bogus_uuid[] = "1534c928-c50e-4866-9daf-6a9fd7918a76"; ++ const char *test_result; ++ char *expected_result; ++ ++ open_disk (&data); ++ ++ expected_result = grub_xasprintf ("%s,gpt1", data.dev->disk->name); ++ grub_env_unset ("test_result"); ++ grub_search_part_uuid (gpt1_uuid, "test_result", 0, NULL, 0); ++ test_result = grub_env_get ("test_result"); ++ grub_test_assert (test_result && strcmp (test_result, expected_result) == 0, ++ "wrong device: %s (%s)", test_result, expected_result); ++ grub_free (expected_result); ++ ++ expected_result = grub_xasprintf ("%s,gpt2", data.dev->disk->name); ++ grub_env_unset ("test_result"); ++ grub_search_part_uuid (gpt2_uuid, "test_result", 0, NULL, 0); ++ test_result = grub_env_get ("test_result"); ++ grub_test_assert (test_result && strcmp (test_result, expected_result) == 0, ++ "wrong device: %s (%s)", test_result, expected_result); ++ grub_free (expected_result); ++ ++ grub_env_unset ("test_result"); ++ grub_search_part_uuid (bogus_uuid, "test_result", 0, NULL, 0); ++ test_result = grub_env_get ("test_result"); ++ grub_test_assert (test_result == NULL, ++ "unexpected device: %s", test_result); ++ grub_test_assert (grub_errno == GRUB_ERR_FILE_NOT_FOUND, ++ "unexpected error: %s", grub_errmsg); ++ grub_errno = GRUB_ERR_NONE; ++ ++ close_disk (&data); ++} ++ + void + grub_unit_test_init (void) + { +@@ -546,6 +626,8 @@ grub_unit_test_init (void) + grub_test_register ("gpt_read_invalid_test", read_invalid_entries_test); + grub_test_register ("gpt_read_fallback_test", read_fallback_test); + grub_test_register ("gpt_repair_test", repair_test); ++ grub_test_register ("gpt_search_label_test", search_label_test); ++ grub_test_register ("gpt_search_uuid_test", search_uuid_test); + } + + void +@@ -557,5 +639,7 @@ grub_unit_test_fini (void) + grub_test_unregister ("gpt_read_invalid_test"); + grub_test_unregister ("gpt_read_fallback_test"); + grub_test_unregister ("gpt_repair_test"); ++ grub_test_unregister ("gpt_search_label_test"); ++ grub_test_unregister ("gpt_search_uuid_test"); + grub_fini_all (); + } +-- +2.36.1 + diff --git a/packages/grub/0015-gpt-clean-up-little-endian-crc32-computation.patch b/packages/grub/0015-gpt-clean-up-little-endian-crc32-computation.patch new file mode 100644 index 00000000..82831f0d --- /dev/null +++ b/packages/grub/0015-gpt-clean-up-little-endian-crc32-computation.patch @@ -0,0 +1,116 @@ +From 7ed137907dfccfcd738ec7371ded51af39d48006 Mon Sep 17 00:00:00 2001 +From: Michael Marineau +Date: Fri, 31 Jul 2015 15:03:11 -0700 +Subject: [PATCH] gpt: clean up little-endian crc32 computation + + - Remove problematic cast from *uint8_t to *uint32_t (alignment issue). + - Remove dynamic allocation and associated error handling paths. + - Match parameter ordering to existing grub_crypto_hash function. +--- + grub-core/lib/gpt.c | 51 ++++++++++++--------------------------------- + 1 file changed, 13 insertions(+), 38 deletions(-) + +diff --git a/grub-core/lib/gpt.c b/grub-core/lib/gpt.c +index 10a4b85..aedc4f7 100644 +--- a/grub-core/lib/gpt.c ++++ b/grub-core/lib/gpt.c +@@ -122,45 +122,29 @@ grub_gpt_size_to_sectors (grub_gpt_t gpt, grub_size_t size) + return sectors; + } + +-static grub_err_t +-grub_gpt_lecrc32 (void *data, grub_size_t len, grub_uint32_t *crc) ++static void ++grub_gpt_lecrc32 (grub_uint32_t *crc, const void *data, grub_size_t len) + { +- grub_uint8_t *crc32_context; +- +- crc32_context = grub_zalloc (GRUB_MD_CRC32->contextsize); +- if (!crc32_context) +- return grub_errno; ++ grub_uint32_t crc32_val; + +- GRUB_MD_CRC32->init (crc32_context); +- GRUB_MD_CRC32->write (crc32_context, data, len); +- GRUB_MD_CRC32->final (crc32_context); ++ grub_crypto_hash (GRUB_MD_CRC32, &crc32_val, data, len); + + /* GRUB_MD_CRC32 always uses big endian, gpt is always little. */ +- *crc = grub_swap_bytes32 (*(grub_uint32_t *) +- GRUB_MD_CRC32->read (crc32_context)); +- +- grub_free (crc32_context); +- +- return GRUB_ERR_NONE; ++ *crc = grub_swap_bytes32 (crc32_val); + } + +-static grub_err_t +-grub_gpt_header_lecrc32 (struct grub_gpt_header *header, grub_uint32_t *crc) ++static void ++grub_gpt_header_lecrc32 (grub_uint32_t *crc, struct grub_gpt_header *header) + { + grub_uint32_t old, new; +- grub_err_t err; + + /* crc32 must be computed with the field cleared. */ + old = header->crc32; + header->crc32 = 0; +- err = grub_gpt_lecrc32 (header, sizeof (*header), &new); ++ grub_gpt_lecrc32 (&new, header, sizeof (*header)); + header->crc32 = old; + +- if (err) +- return err; +- + *crc = new; +- return GRUB_ERR_NONE; + } + + /* Make sure the MBR is a protective MBR and not a normal MBR. */ +@@ -192,9 +176,7 @@ grub_gpt_header_check (struct grub_gpt_header *gpt, + if (gpt->version != GRUB_GPT_HEADER_VERSION) + return grub_error (GRUB_ERR_BAD_PART_TABLE, "unknown GPT version"); + +- if (grub_gpt_header_lecrc32 (gpt, &crc)) +- return grub_errno; +- ++ grub_gpt_header_lecrc32 (&crc, gpt); + if (gpt->crc32 != crc) + return grub_error (GRUB_ERR_BAD_PART_TABLE, "invalid GPT header crc32"); + +@@ -289,9 +271,7 @@ grub_gpt_read_entries (grub_disk_t disk, grub_gpt_t gpt, + if (grub_disk_read (disk, addr, 0, entries_size, entries)) + goto fail; + +- if (grub_gpt_lecrc32 (entries, entries_size, &crc)) +- goto fail; +- ++ grub_gpt_lecrc32 (&crc, entries, entries_size); + if (crc != header->partentry_crc32) + { + grub_error (GRUB_ERR_BAD_PART_TABLE, "invalid GPT entry crc32"); +@@ -433,17 +413,12 @@ grub_gpt_update_checksums (grub_gpt_t gpt) + gpt->backup.headersize = + grub_cpu_to_le32_compile_time (sizeof (gpt->backup)); + +- if (grub_gpt_lecrc32 (gpt->entries, gpt->entries_size, &crc)) +- return grub_errno; +- ++ grub_gpt_lecrc32 (&crc, gpt->entries, gpt->entries_size); + gpt->primary.partentry_crc32 = crc; + gpt->backup.partentry_crc32 = crc; + +- if (grub_gpt_header_lecrc32 (&gpt->primary, &gpt->primary.crc32)) +- return grub_errno; +- +- if (grub_gpt_header_lecrc32 (&gpt->backup, &gpt->backup.crc32)) +- return grub_errno; ++ grub_gpt_header_lecrc32 (&gpt->primary.crc32, &gpt->primary); ++ grub_gpt_header_lecrc32 (&gpt->backup.crc32, &gpt->backup); + + return GRUB_ERR_NONE; + } +-- +2.21.3 + diff --git a/packages/grub/0016-gpt-minor-cleanup.patch b/packages/grub/0016-gpt-minor-cleanup.patch new file mode 100644 index 00000000..ca7aec89 --- /dev/null +++ b/packages/grub/0016-gpt-minor-cleanup.patch @@ -0,0 +1,69 @@ +From 6563a1739f3ae9e06002682b4455f78df67fbf32 Mon Sep 17 00:00:00 2001 +From: Alex Crawford +Date: Mon, 31 Aug 2015 15:23:39 -0700 +Subject: [PATCH] gpt: minor cleanup + +--- + include/grub/gpt_partition.h | 2 +- + tests/gpt_unit_test.c | 12 ++++++------ + 2 files changed, 7 insertions(+), 7 deletions(-) + +diff --git a/include/grub/gpt_partition.h b/include/grub/gpt_partition.h +index 7b04080..1eb2f7b 100644 +--- a/include/grub/gpt_partition.h ++++ b/include/grub/gpt_partition.h +@@ -229,7 +229,7 @@ grub_err_t grub_gpt_header_check (struct grub_gpt_header *gpt, + grub_err_t grub_gpt_part_label (grub_device_t device, char **label); + + /* Return the partition uuid of the device DEVICE in UUID. +- * The label is in a new buffer and should be freed by the caller. */ ++ * The uuid is in a new buffer and should be freed by the caller. */ + grub_err_t grub_gpt_part_uuid (grub_device_t device, char **uuid); + + #endif /* ! GRUB_GPT_PARTITION_HEADER */ +diff --git a/tests/gpt_unit_test.c b/tests/gpt_unit_test.c +index deb55a9..7a1af46 100644 +--- a/tests/gpt_unit_test.c ++++ b/tests/gpt_unit_test.c +@@ -538,7 +538,7 @@ repair_test (void) + } + + static void +-search_label_test (void) ++search_part_label_test (void) + { + struct test_data data; + const char *test_result; +@@ -575,7 +575,7 @@ search_label_test (void) + } + + static void +-search_uuid_test (void) ++search_part_uuid_test (void) + { + struct test_data data; + const char gpt1_uuid[] = "A0F1792E-B4CE-4136-BCF2-1AFC133C2828"; +@@ -626,8 +626,8 @@ grub_unit_test_init (void) + grub_test_register ("gpt_read_invalid_test", read_invalid_entries_test); + grub_test_register ("gpt_read_fallback_test", read_fallback_test); + grub_test_register ("gpt_repair_test", repair_test); +- grub_test_register ("gpt_search_label_test", search_label_test); +- grub_test_register ("gpt_search_uuid_test", search_uuid_test); ++ grub_test_register ("gpt_search_part_label_test", search_part_label_test); ++ grub_test_register ("gpt_search_uuid_test", search_part_uuid_test); + } + + void +@@ -639,7 +639,7 @@ grub_unit_test_fini (void) + grub_test_unregister ("gpt_read_invalid_test"); + grub_test_unregister ("gpt_read_fallback_test"); + grub_test_unregister ("gpt_repair_test"); +- grub_test_unregister ("gpt_search_label_test"); +- grub_test_unregister ("gpt_search_uuid_test"); ++ grub_test_unregister ("gpt_search_part_label_test"); ++ grub_test_unregister ("gpt_search_part_uuid_test"); + grub_fini_all (); + } +-- +2.21.3 + diff --git a/packages/grub/0017-gpt-add-search-by-disk-uuid-command.patch b/packages/grub/0017-gpt-add-search-by-disk-uuid-command.patch new file mode 100644 index 00000000..03d860f8 --- /dev/null +++ b/packages/grub/0017-gpt-add-search-by-disk-uuid-command.patch @@ -0,0 +1,277 @@ +From a4ecd2c5ff6cb23af51977a622dca5fc2a9b7cef Mon Sep 17 00:00:00 2001 +From: Alex Crawford +Date: Mon, 31 Aug 2015 15:15:48 -0700 +Subject: [PATCH] gpt: add search by disk uuid command + +[markubo: Update to grub-2.06-42.amzn2022. Search functions take a more +general search_flags parameter now instead of a no_floppy flag.] + +Signed-off-by: Markus Boehme + +--- + Makefile.util.def | 1 + + grub-core/Makefile.core.def | 5 ++++ + grub-core/commands/search.c | 28 +++++++++++++++++++++-- + grub-core/commands/search_disk_uuid.c | 5 ++++ + grub-core/commands/search_wrap.c | 5 ++++ + grub-core/lib/gpt.c | 21 +++++++++++++++++ + include/grub/gpt_partition.h | 4 ++++ + include/grub/search.h | 3 +++ + tests/gpt_unit_test.c | 33 +++++++++++++++++++++++++++ + 9 files changed, 103 insertions(+), 2 deletions(-) + create mode 100644 grub-core/commands/search_disk_uuid.c + +diff --git a/Makefile.util.def b/Makefile.util.def +index 8f74405..33ce60d 100644 +--- a/Makefile.util.def ++++ b/Makefile.util.def +@@ -1408,6 +1408,7 @@ program = { + common = tests/lib/unit_test.c; + common = grub-core/commands/search_part_label.c; + common = grub-core/commands/search_part_uuid.c; ++ common = grub-core/commands/search_disk_uuid.c; + common = grub-core/disk/host.c; + common = grub-core/kern/emu/hostfs.c; + common = grub-core/lib/gpt.c; +diff --git a/grub-core/Makefile.core.def b/grub-core/Makefile.core.def +index 3cde624..3096cd4 100644 +--- a/grub-core/Makefile.core.def ++++ b/grub-core/Makefile.core.def +@@ -1162,6 +1162,11 @@ module = { + common = commands/search_part_label.c; + }; + ++module = { ++ name = search_disk_uuid; ++ common = commands/search_disk_uuid.c; ++}; ++ + module = { + name = setpci; + common = commands/setpci.c; +diff --git a/grub-core/commands/search.c b/grub-core/commands/search.c +index bb0c7cb..ec03c75 100644 +--- a/grub-core/commands/search.c ++++ b/grub-core/commands/search.c +@@ -30,7 +30,8 @@ + #include + #include + #include +-#if defined(DO_SEARCH_PART_UUID) || defined(DO_SEARCH_PART_LABEL) ++#if defined(DO_SEARCH_PART_UUID) || defined(DO_SEARCH_PART_LABEL) || \ ++ defined(DO_SEARCH_DISK_UUID) + #include + #endif + +@@ -88,7 +89,7 @@ iterate_device (const char *name, void *data) + grub_device_close (dev); + } + +-#ifdef DO_SEARCH_FS_UUID ++#if defined(DO_SEARCH_FS_UUID) || defined(DO_SEARCH_DISK_UUID) + #define compare_fn grub_strcasecmp + #else + #define compare_fn grub_strcmp +@@ -128,6 +129,25 @@ iterate_device (const char *name, void *data) + grub_free (quid); + } + ++ grub_device_close (dev); ++ } ++ } ++#elif defined(DO_SEARCH_DISK_UUID) ++ { ++ grub_device_t dev; ++ char *quid; ++ ++ dev = grub_device_open (name); ++ if (dev) ++ { ++ if (grub_gpt_disk_uuid (dev, &quid) == GRUB_ERR_NONE) ++ { ++ if (grub_strcmp (quid, ctx->key) == 0) ++ found = 1; ++ ++ grub_free (quid); ++ } ++ + grub_device_close (dev); + } + } +@@ -379,6 +399,8 @@ GRUB_MOD_INIT(search_part_uuid) + GRUB_MOD_INIT(search_part_label) + #elif defined (DO_SEARCH_FS_UUID) + GRUB_MOD_INIT(search_fs_uuid) ++#elif defined (DO_SEARCH_DISK_UUID) ++GRUB_MOD_INIT(search_disk_uuid) + #else + GRUB_MOD_INIT(search_label) + #endif +@@ -397,6 +419,8 @@ GRUB_MOD_FINI(search_part_uuid) + GRUB_MOD_FINI(search_part_label) + #elif defined (DO_SEARCH_FS_UUID) + GRUB_MOD_FINI(search_fs_uuid) ++#elif defined (DO_SEARCH_DISK_UUID) ++GRUB_MOD_FINI(search_disk_uuid) + #else + GRUB_MOD_FINI(search_label) + #endif +diff --git a/grub-core/commands/search_disk_uuid.c b/grub-core/commands/search_disk_uuid.c +new file mode 100644 +index 0000000..fba96f6 +--- /dev/null ++++ b/grub-core/commands/search_disk_uuid.c +@@ -0,0 +1,5 @@ ++#define DO_SEARCH_DISK_UUID 1 ++#define FUNC_NAME grub_search_disk_uuid ++#define COMMAND_NAME "search.disk_uuid" ++#define HELP_MESSAGE N_("Search devices by disk UUID. If VARIABLE is specified, the first device found is set to a variable.") ++#include "search.c" +diff --git a/grub-core/commands/search_wrap.c b/grub-core/commands/search_wrap.c +index 82f8e63..c8152b1 100644 +--- a/grub-core/commands/search_wrap.c ++++ b/grub-core/commands/search_wrap.c +@@ -40,6 +40,8 @@ static const struct grub_arg_option options[] = + 0, 0}, + {"part-uuid", 'U', 0, N_("Search devices by a partition UUID."), + 0, 0}, ++ {"disk-uuid", 'U', 0, N_("Search devices by a disk UUID."), ++ 0, 0}, + {"set", 's', GRUB_ARG_OPTION_OPTIONAL, + N_("Set a variable to the first device found."), N_("VARNAME"), + ARG_TYPE_STRING}, +@@ -78,6 +80,7 @@ enum options + SEARCH_FS_UUID, + SEARCH_PART_LABEL, + SEARCH_PART_UUID, ++ SEARCH_DISK_UUID, + SEARCH_SET, + SEARCH_NO_FLOPPY, + SEARCH_EFIDISK_ONLY, +@@ -203,6 +206,8 @@ grub_cmd_search (grub_extcmd_context_t ctxt, int argc, char **args) + grub_search_part_label (id, var, flags, hints, nhints); + else if (state[SEARCH_PART_UUID].set) + grub_search_part_uuid (id, var, flags, hints, nhints); ++ else if (state[SEARCH_DISK_UUID].set) ++ grub_search_disk_uuid (id, var, flags, hints, nhints); + else if (state[SEARCH_FILE].set) + grub_search_fs_file (id, var, flags, hints, nhints); + else +diff --git a/grub-core/lib/gpt.c b/grub-core/lib/gpt.c +index aedc4f7..e162baf 100644 +--- a/grub-core/lib/gpt.c ++++ b/grub-core/lib/gpt.c +@@ -108,6 +108,27 @@ grub_gpt_part_uuid (grub_device_t device, char **uuid) + return GRUB_ERR_NONE; + } + ++grub_err_t ++grub_gpt_disk_uuid (grub_device_t device, char **uuid) ++{ ++ grub_gpt_t gpt = grub_gpt_read (device->disk); ++ if (!gpt) ++ goto done; ++ ++ grub_errno = GRUB_ERR_NONE; ++ ++ if (gpt->status & GRUB_GPT_PRIMARY_HEADER_VALID) ++ *uuid = grub_gpt_guid_to_str (&gpt->primary.guid); ++ else if (gpt->status & GRUB_GPT_BACKUP_HEADER_VALID) ++ *uuid = grub_gpt_guid_to_str (&gpt->backup.guid); ++ else ++ grub_errno = grub_error (GRUB_ERR_BUG, "No valid GPT header"); ++ ++done: ++ grub_gpt_free (gpt); ++ return grub_errno; ++} ++ + static grub_uint64_t + grub_gpt_size_to_sectors (grub_gpt_t gpt, grub_size_t size) + { +diff --git a/include/grub/gpt_partition.h b/include/grub/gpt_partition.h +index 1eb2f7b..16fdd7f 100644 +--- a/include/grub/gpt_partition.h ++++ b/include/grub/gpt_partition.h +@@ -232,4 +232,8 @@ grub_err_t grub_gpt_part_label (grub_device_t device, char **label); + * The uuid is in a new buffer and should be freed by the caller. */ + grub_err_t grub_gpt_part_uuid (grub_device_t device, char **uuid); + ++/* Return the disk uuid of the device DEVICE in UUID. ++ * The uuid is in a new buffer and should be freed by the caller. */ ++grub_err_t grub_gpt_disk_uuid (grub_device_t device, char **uuid); ++ + #endif /* ! GRUB_GPT_PARTITION_HEADER */ +diff --git a/include/grub/search.h b/include/grub/search.h +index 66722a6..a5f56b2 100644 +--- a/include/grub/search.h ++++ b/include/grub/search.h +@@ -40,5 +40,8 @@ void grub_search_part_uuid (const char *key, const char *var, + void grub_search_part_label (const char *key, const char *var, + enum search_flags flags, + char **hints, unsigned nhints); ++void grub_search_disk_uuid (const char *key, const char *var, ++ enum search_flags flags, ++ char **hints, unsigned nhints); + + #endif +diff --git a/tests/gpt_unit_test.c b/tests/gpt_unit_test.c +index 7a1af46..60f6017 100644 +--- a/tests/gpt_unit_test.c ++++ b/tests/gpt_unit_test.c +@@ -614,6 +614,37 @@ search_part_uuid_test (void) + close_disk (&data); + } + ++static void ++search_disk_uuid_test (void) ++{ ++ struct test_data data; ++ const char disk_uuid[] = "69c131ad-67d6-46c6-93c4-124c755256ac"; ++ const char bogus_uuid[] = "1534c928-c50e-4866-9daf-6a9fd7918a76"; ++ const char *test_result; ++ char *expected_result; ++ ++ open_disk (&data); ++ ++ expected_result = grub_xasprintf ("%s", data.dev->disk->name); ++ grub_env_unset ("test_result"); ++ grub_search_disk_uuid (disk_uuid, "test_result", 0, NULL, 0); ++ test_result = grub_env_get ("test_result"); ++ grub_test_assert (test_result && strcmp (test_result, expected_result) == 0, ++ "wrong device: %s (%s)", test_result, expected_result); ++ grub_free (expected_result); ++ ++ grub_env_unset ("test_result"); ++ grub_search_disk_uuid (bogus_uuid, "test_result", 0, NULL, 0); ++ test_result = grub_env_get ("test_result"); ++ grub_test_assert (test_result == NULL, ++ "unexpected device: %s", test_result); ++ grub_test_assert (grub_errno == GRUB_ERR_FILE_NOT_FOUND, ++ "unexpected error: %s", grub_errmsg); ++ grub_errno = GRUB_ERR_NONE; ++ ++ close_disk (&data); ++} ++ + void + grub_unit_test_init (void) + { +@@ -628,6 +659,7 @@ grub_unit_test_init (void) + grub_test_register ("gpt_repair_test", repair_test); + grub_test_register ("gpt_search_part_label_test", search_part_label_test); + grub_test_register ("gpt_search_uuid_test", search_part_uuid_test); ++ grub_test_register ("gpt_search_disk_uuid_test", search_disk_uuid_test); + } + + void +@@ -641,5 +673,6 @@ grub_unit_test_fini (void) + grub_test_unregister ("gpt_repair_test"); + grub_test_unregister ("gpt_search_part_label_test"); + grub_test_unregister ("gpt_search_part_uuid_test"); ++ grub_test_unregister ("gpt_search_disk_uuid_test"); + grub_fini_all (); + } +-- +2.36.1 + diff --git a/packages/grub/0018-gpt-do-not-use-disk-sizes-GRUB-will-reject-as-invali.patch b/packages/grub/0018-gpt-do-not-use-disk-sizes-GRUB-will-reject-as-invali.patch new file mode 100644 index 00000000..c8087ee6 --- /dev/null +++ b/packages/grub/0018-gpt-do-not-use-disk-sizes-GRUB-will-reject-as-invali.patch @@ -0,0 +1,67 @@ +From 2d1291ab5c4c814b961c1dc8f3a6541bf9aa8d32 Mon Sep 17 00:00:00 2001 +From: Michael Marineau +Date: Mon, 25 Jul 2016 14:59:29 -0700 +Subject: [PATCH] gpt: do not use disk sizes GRUB will reject as invalid later + on + +GRUB assumes that no disk is ever larger than 1EiB and rejects +reads/writes to such locations. Unfortunately this is not conveyed in +the usual way with the special GRUB_DISK_SIZE_UNKNOWN value. +--- + grub-core/lib/gpt.c | 26 ++++++++++++++++++++++++-- + 1 file changed, 24 insertions(+), 2 deletions(-) + +diff --git a/grub-core/lib/gpt.c b/grub-core/lib/gpt.c +index e162baf..3e17f27 100644 +--- a/grub-core/lib/gpt.c ++++ b/grub-core/lib/gpt.c +@@ -143,6 +143,28 @@ grub_gpt_size_to_sectors (grub_gpt_t gpt, grub_size_t size) + return sectors; + } + ++/* Copied from grub-core/kern/disk_common.c grub_disk_adjust_range so we can ++ * avoid attempting to use disk->total_sectors when GRUB won't let us. ++ * TODO: Why is disk->total_sectors not set to GRUB_DISK_SIZE_UNKNOWN? */ ++static int ++grub_gpt_disk_size_valid (grub_disk_t disk) ++{ ++ grub_disk_addr_t total_sectors; ++ ++ /* Transform total_sectors to number of 512B blocks. */ ++ total_sectors = disk->total_sectors << (disk->log_sector_size - GRUB_DISK_SECTOR_BITS); ++ ++ /* Some drivers have problems with disks above reasonable. ++ Treat unknown as 1EiB disk. While on it, clamp the size to 1EiB. ++ Just one condition is enough since GRUB_DISK_UNKNOWN_SIZE << ls is always ++ above 9EiB. ++ */ ++ if (total_sectors > (1ULL << 51)) ++ return 0; ++ ++ return 1; ++} ++ + static void + grub_gpt_lecrc32 (grub_uint32_t *crc, const void *data, grub_size_t len) + { +@@ -242,7 +264,7 @@ grub_gpt_read_backup (grub_disk_t disk, grub_gpt_t gpt) + grub_disk_addr_t addr; + + /* Assumes gpt->log_sector_size == disk->log_sector_size */ +- if (disk->total_sectors != GRUB_DISK_SIZE_UNKNOWN) ++ if (grub_gpt_disk_size_valid(disk)) + sector = disk->total_sectors - 1; + else if (gpt->status & GRUB_GPT_PRIMARY_HEADER_VALID) + sector = grub_le_to_cpu64 (gpt->primary.alternate_lba); +@@ -394,7 +416,7 @@ grub_gpt_repair (grub_disk_t disk, grub_gpt_t gpt) + return grub_error (GRUB_ERR_BUG, "No valid GPT header"); + + /* Relocate backup to end if disk whenever possible. */ +- if (disk->total_sectors != GRUB_DISK_SIZE_UNKNOWN) ++ if (grub_gpt_disk_size_valid(disk)) + backup_header = disk->total_sectors - 1; + + backup_entries = backup_header - +-- +2.21.3 + diff --git a/packages/grub/0019-gpt-add-verbose-debug-logging.patch b/packages/grub/0019-gpt-add-verbose-debug-logging.patch new file mode 100644 index 00000000..40a24543 --- /dev/null +++ b/packages/grub/0019-gpt-add-verbose-debug-logging.patch @@ -0,0 +1,254 @@ +From acc91512edec9cae77efc51df8418ae9fdba4a0e Mon Sep 17 00:00:00 2001 +From: Michael Marineau +Date: Wed, 10 Aug 2016 18:26:03 -0700 +Subject: [PATCH] gpt: add verbose debug logging + +--- + grub-core/lib/gpt.c | 117 +++++++++++++++++++++++++++++++++++++++++--- + 1 file changed, 109 insertions(+), 8 deletions(-) + +diff --git a/grub-core/lib/gpt.c b/grub-core/lib/gpt.c +index 3e17f27..c2821b5 100644 +--- a/grub-core/lib/gpt.c ++++ b/grub-core/lib/gpt.c +@@ -207,6 +207,18 @@ grub_gpt_pmbr_check (struct grub_msdos_partition_mbr *mbr) + return grub_error (GRUB_ERR_BAD_PART_TABLE, "invalid protective MBR"); + } + ++static grub_uint64_t ++grub_gpt_entries_sectors (struct grub_gpt_header *gpt, ++ unsigned int log_sector_size) ++{ ++ grub_uint64_t sector_bytes, entries_bytes; ++ ++ sector_bytes = 1ULL << log_sector_size; ++ entries_bytes = (grub_uint64_t) grub_le_to_cpu32 (gpt->maxpart) * ++ (grub_uint64_t) grub_le_to_cpu32 (gpt->partentry_size); ++ return grub_divmod64(entries_bytes + sector_bytes - 1, sector_bytes, NULL); ++} ++ + grub_err_t + grub_gpt_header_check (struct grub_gpt_header *gpt, + unsigned int log_sector_size) +@@ -236,6 +248,64 @@ grub_gpt_header_check (struct grub_gpt_header *gpt, + return GRUB_ERR_NONE; + } + ++static grub_err_t ++grub_gpt_check_primary (grub_gpt_t gpt) ++{ ++ grub_uint64_t backup, primary, entries, entries_len, start, end; ++ ++ primary = grub_le_to_cpu64 (gpt->primary.header_lba); ++ backup = grub_le_to_cpu64 (gpt->primary.alternate_lba); ++ entries = grub_le_to_cpu64 (gpt->primary.partitions); ++ entries_len = grub_gpt_entries_sectors(&gpt->primary, gpt->log_sector_size); ++ start = grub_le_to_cpu64 (gpt->primary.start); ++ end = grub_le_to_cpu64 (gpt->primary.end); ++ ++ grub_dprintf ("gpt", "Primary GPT layout:\n" ++ "primary header = 0x%llx backup header = 0x%llx\n" ++ "entries location = 0x%llx length = 0x%llx\n" ++ "first usable = 0x%llx last usable = 0x%llx\n", ++ (unsigned long long) primary, ++ (unsigned long long) backup, ++ (unsigned long long) entries, ++ (unsigned long long) entries_len, ++ (unsigned long long) start, ++ (unsigned long long) end); ++ ++ if (grub_gpt_header_check (&gpt->primary, gpt->log_sector_size)) ++ return grub_errno; ++ ++ return GRUB_ERR_NONE; ++} ++ ++static grub_err_t ++grub_gpt_check_backup (grub_gpt_t gpt) ++{ ++ grub_uint64_t backup, primary, entries, entries_len, start, end; ++ ++ backup = grub_le_to_cpu64 (gpt->backup.header_lba); ++ primary = grub_le_to_cpu64 (gpt->backup.alternate_lba); ++ entries = grub_le_to_cpu64 (gpt->backup.partitions); ++ entries_len = grub_gpt_entries_sectors(&gpt->backup, gpt->log_sector_size); ++ start = grub_le_to_cpu64 (gpt->backup.start); ++ end = grub_le_to_cpu64 (gpt->backup.end); ++ ++ grub_dprintf ("gpt", "Backup GPT layout:\n" ++ "primary header = 0x%llx backup header = 0x%llx\n" ++ "entries location = 0x%llx length = 0x%llx\n" ++ "first usable = 0x%llx last usable = 0x%llx\n", ++ (unsigned long long) primary, ++ (unsigned long long) backup, ++ (unsigned long long) entries, ++ (unsigned long long) entries_len, ++ (unsigned long long) start, ++ (unsigned long long) end); ++ ++ if (grub_gpt_header_check (&gpt->backup, gpt->log_sector_size)) ++ return grub_errno; ++ ++ return GRUB_ERR_NONE; ++} ++ + static grub_err_t + grub_gpt_read_primary (grub_disk_t disk, grub_gpt_t gpt) + { +@@ -246,11 +316,13 @@ grub_gpt_read_primary (grub_disk_t disk, grub_gpt_t gpt) + * but eventually this code should match the existing behavior. */ + gpt->log_sector_size = disk->log_sector_size; + ++ grub_dprintf ("gpt", "reading primary GPT from sector 0x1\n"); ++ + addr = grub_gpt_sector_to_addr (gpt, 1); + if (grub_disk_read (disk, addr, 0, sizeof (gpt->primary), &gpt->primary)) + return grub_errno; + +- if (grub_gpt_header_check (&gpt->primary, gpt->log_sector_size)) ++ if (grub_gpt_check_primary (gpt)) + return grub_errno; + + gpt->status |= GRUB_GPT_PRIMARY_HEADER_VALID; +@@ -272,11 +344,14 @@ grub_gpt_read_backup (grub_disk_t disk, grub_gpt_t gpt) + return grub_error (GRUB_ERR_NOT_IMPLEMENTED_YET, + "Unable to locate backup GPT"); + ++ grub_dprintf ("gpt", "reading backup GPT from sector 0x%llx\n", ++ (unsigned long long) sector); ++ + addr = grub_gpt_sector_to_addr (gpt, sector); + if (grub_disk_read (disk, addr, 0, sizeof (gpt->backup), &gpt->backup)) + return grub_errno; + +- if (grub_gpt_header_check (&gpt->backup, gpt->log_sector_size)) ++ if (grub_gpt_check_backup (gpt)) + return grub_errno; + + gpt->status |= GRUB_GPT_BACKUP_HEADER_VALID; +@@ -289,6 +364,7 @@ grub_gpt_read_entries (grub_disk_t disk, grub_gpt_t gpt, + { + struct grub_gpt_partentry *entries = NULL; + grub_uint32_t count, size, crc; ++ grub_uint64_t sector; + grub_disk_addr_t addr; + grub_size_t entries_size; + +@@ -310,7 +386,12 @@ grub_gpt_read_entries (grub_disk_t disk, grub_gpt_t gpt, + if (!entries) + goto fail; + +- addr = grub_gpt_sector_to_addr (gpt, grub_le_to_cpu64 (header->partitions)); ++ sector = grub_le_to_cpu64 (header->partitions); ++ grub_dprintf ("gpt", "reading GPT %lu entries from sector 0x%llx\n", ++ (unsigned long) count, ++ (unsigned long long) sector); ++ ++ addr = grub_gpt_sector_to_addr (gpt, sector); + if (grub_disk_read (disk, addr, 0, entries_size, entries)) + goto fail; + +@@ -336,6 +417,8 @@ grub_gpt_read (grub_disk_t disk) + { + grub_gpt_t gpt; + ++ grub_dprintf ("gpt", "reading GPT from %s\n", disk->name); ++ + gpt = grub_zalloc (sizeof (*gpt)); + if (!gpt) + goto fail; +@@ -369,12 +452,18 @@ grub_gpt_read (grub_disk_t disk) + /* Similarly, favor the value or error from the primary table. */ + if (gpt->status & GRUB_GPT_BACKUP_HEADER_VALID && + !grub_gpt_read_entries (disk, gpt, &gpt->backup)) +- gpt->status |= GRUB_GPT_BACKUP_ENTRIES_VALID; ++ { ++ grub_dprintf ("gpt", "read valid backup GPT from %s\n", disk->name); ++ gpt->status |= GRUB_GPT_BACKUP_ENTRIES_VALID; ++ } + + grub_errno = GRUB_ERR_NONE; + if (gpt->status & GRUB_GPT_PRIMARY_HEADER_VALID && + !grub_gpt_read_entries (disk, gpt, &gpt->primary)) +- gpt->status |= GRUB_GPT_PRIMARY_ENTRIES_VALID; ++ { ++ grub_dprintf ("gpt", "read valid primary GPT from %s\n", disk->name); ++ gpt->status |= GRUB_GPT_PRIMARY_ENTRIES_VALID; ++ } + + if (gpt->status & GRUB_GPT_PRIMARY_ENTRIES_VALID || + gpt->status & GRUB_GPT_BACKUP_ENTRIES_VALID) +@@ -394,21 +483,25 @@ grub_gpt_repair (grub_disk_t disk, grub_gpt_t gpt) + { + grub_uint64_t backup_header, backup_entries; + ++ grub_dprintf ("gpt", "repairing GPT for %s\n", disk->name); ++ + if (disk->log_sector_size != gpt->log_sector_size) + return grub_error (GRUB_ERR_NOT_IMPLEMENTED_YET, + "GPT sector size must match disk sector size"); + + if (!(gpt->status & GRUB_GPT_PRIMARY_ENTRIES_VALID || +- gpt->status & GRUB_GPT_BACKUP_ENTRIES_VALID)) ++ gpt->status & GRUB_GPT_BACKUP_ENTRIES_VALID)) + return grub_error (GRUB_ERR_BUG, "No valid GPT entries"); + + if (gpt->status & GRUB_GPT_PRIMARY_HEADER_VALID) + { ++ grub_dprintf ("gpt", "primary GPT header is valid\n"); + backup_header = grub_le_to_cpu64 (gpt->primary.alternate_lba); + grub_memcpy (&gpt->backup, &gpt->primary, sizeof (gpt->backup)); + } + else if (gpt->status & GRUB_GPT_BACKUP_HEADER_VALID) + { ++ grub_dprintf ("gpt", "backup GPT header is valid\n"); + backup_header = grub_le_to_cpu64 (gpt->backup.header_lba); + grub_memcpy (&gpt->primary, &gpt->backup, sizeof (gpt->primary)); + } +@@ -418,9 +511,13 @@ grub_gpt_repair (grub_disk_t disk, grub_gpt_t gpt) + /* Relocate backup to end if disk whenever possible. */ + if (grub_gpt_disk_size_valid(disk)) + backup_header = disk->total_sectors - 1; ++ grub_dprintf ("gpt", "backup GPT header will be located at 0x%llx\n", ++ (unsigned long long) backup_header); + + backup_entries = backup_header - + grub_gpt_size_to_sectors (gpt, gpt->entries_size); ++ grub_dprintf ("gpt", "backup GPT entries will be located at 0x%llx\n", ++ (unsigned long long) backup_entries); + + /* Update/fixup header and partition table locations. */ + gpt->primary.header_lba = grub_cpu_to_le64_compile_time (1); +@@ -435,13 +532,15 @@ grub_gpt_repair (grub_disk_t disk, grub_gpt_t gpt) + return grub_errno; + + /* Sanity check. */ +- if (grub_gpt_header_check (&gpt->primary, gpt->log_sector_size)) ++ if (grub_gpt_check_primary (gpt)) + return grub_error (GRUB_ERR_BUG, "Generated invalid GPT primary header"); + +- if (grub_gpt_header_check (&gpt->backup, gpt->log_sector_size)) ++ if (grub_gpt_check_backup (gpt)) + return grub_error (GRUB_ERR_BUG, "Generated invalid GPT backup header"); + + gpt->status |= GRUB_GPT_BOTH_VALID; ++ grub_dprintf ("gpt", "repairing GPT for %s successful\n", disk->name); ++ + return GRUB_ERR_NONE; + } + +@@ -497,9 +596,11 @@ grub_gpt_write (grub_disk_t disk, grub_gpt_t gpt) + if (!(gpt->status & GRUB_GPT_BOTH_VALID)) + return grub_error (GRUB_ERR_BAD_PART_TABLE, "Invalid GPT data"); + ++ grub_dprintf ("gpt", "writing primary GPT to %s\n", disk->name); + if (grub_gpt_write_table (disk, gpt, &gpt->primary)) + return grub_errno; + ++ grub_dprintf ("gpt", "writing backup GPT to %s\n", disk->name); + if (grub_gpt_write_table (disk, gpt, &gpt->backup)) + return grub_errno; + +-- +2.21.3 + diff --git a/packages/grub/0020-gpt-improve-validation-of-GPT-headers.patch b/packages/grub/0020-gpt-improve-validation-of-GPT-headers.patch new file mode 100644 index 00000000..dbc80463 --- /dev/null +++ b/packages/grub/0020-gpt-improve-validation-of-GPT-headers.patch @@ -0,0 +1,104 @@ +From 4a037b26a09886e33f281e968f0be4545a6d2c57 Mon Sep 17 00:00:00 2001 +From: Michael Marineau +Date: Wed, 10 Aug 2016 18:26:03 -0700 +Subject: [PATCH] gpt: improve validation of GPT headers + +Adds basic validation of all the disk locations in the headers, reducing +the chance of corrupting weird locations on disk. +--- + grub-core/lib/gpt.c | 48 +++++++++++++++++++++++++++++++++++++++++++++ + 1 file changed, 48 insertions(+) + +diff --git a/grub-core/lib/gpt.c b/grub-core/lib/gpt.c +index c2821b5..f83fe29 100644 +--- a/grub-core/lib/gpt.c ++++ b/grub-core/lib/gpt.c +@@ -224,6 +224,7 @@ grub_gpt_header_check (struct grub_gpt_header *gpt, + unsigned int log_sector_size) + { + grub_uint32_t crc = 0, size; ++ grub_uint64_t start, end; + + if (grub_memcmp (gpt->magic, grub_gpt_magic, sizeof (grub_gpt_magic)) != 0) + return grub_error (GRUB_ERR_BAD_PART_TABLE, "invalid GPT signature"); +@@ -245,9 +246,35 @@ grub_gpt_header_check (struct grub_gpt_header *gpt, + if (size < 128 || size % 128) + return grub_error (GRUB_ERR_BAD_PART_TABLE, "invalid GPT entry size"); + ++ /* And of course there better be some space for partitions! */ ++ start = grub_le_to_cpu64 (gpt->start); ++ end = grub_le_to_cpu64 (gpt->end); ++ if (start > end) ++ return grub_error (GRUB_ERR_BAD_PART_TABLE, "invalid usable sectors"); ++ + return GRUB_ERR_NONE; + } + ++static int ++grub_gpt_headers_equal (grub_gpt_t gpt) ++{ ++ /* Assume headers passed grub_gpt_header_check so skip magic and version. ++ * Individual fields must be checked instead of just using memcmp because ++ * crc32, header, alternate, and partitions will all normally differ. */ ++ ++ if (gpt->primary.headersize != gpt->backup.headersize || ++ gpt->primary.header_lba != gpt->backup.alternate_lba || ++ gpt->primary.start != gpt->backup.start || ++ gpt->primary.end != gpt->backup.end || ++ gpt->primary.maxpart != gpt->backup.maxpart || ++ gpt->primary.partentry_size != gpt->backup.partentry_size || ++ gpt->primary.partentry_crc32 != gpt->backup.partentry_crc32) ++ return 0; ++ ++ return grub_memcmp(&gpt->primary.guid, &gpt->backup.guid, ++ sizeof(grub_gpt_guid_t)) == 0; ++} ++ + static grub_err_t + grub_gpt_check_primary (grub_gpt_t gpt) + { +@@ -273,6 +300,12 @@ grub_gpt_check_primary (grub_gpt_t gpt) + + if (grub_gpt_header_check (&gpt->primary, gpt->log_sector_size)) + return grub_errno; ++ if (primary != 1) ++ return grub_error (GRUB_ERR_BAD_PART_TABLE, "invalid primary GPT LBA"); ++ if (entries <= 1 || entries+entries_len > start) ++ return grub_error (GRUB_ERR_BAD_PART_TABLE, "invalid entries location"); ++ if (backup <= end) ++ return grub_error (GRUB_ERR_BAD_PART_TABLE, "invalid backup GPT LBA"); + + return GRUB_ERR_NONE; + } +@@ -302,6 +335,12 @@ grub_gpt_check_backup (grub_gpt_t gpt) + + if (grub_gpt_header_check (&gpt->backup, gpt->log_sector_size)) + return grub_errno; ++ if (primary != 1) ++ return grub_error (GRUB_ERR_BAD_PART_TABLE, "invalid primary GPT LBA"); ++ if (entries <= end || entries+entries_len > backup) ++ return grub_error (GRUB_ERR_BAD_PART_TABLE, "invalid entries location"); ++ if (backup <= end) ++ return grub_error (GRUB_ERR_BAD_PART_TABLE, "invalid backup GPT LBA"); + + return GRUB_ERR_NONE; + } +@@ -354,6 +393,15 @@ grub_gpt_read_backup (grub_disk_t disk, grub_gpt_t gpt) + if (grub_gpt_check_backup (gpt)) + return grub_errno; + ++ /* Ensure the backup header thinks it is located where we found it. */ ++ if (grub_le_to_cpu64 (gpt->backup.header_lba) != sector) ++ return grub_error (GRUB_ERR_BAD_PART_TABLE, "invalid backup GPT LBA"); ++ ++ /* If both primary and backup are valid but differ prefer the primary. */ ++ if ((gpt->status & GRUB_GPT_PRIMARY_HEADER_VALID) && ++ !grub_gpt_headers_equal(gpt)) ++ return grub_error (GRUB_ERR_BAD_PART_TABLE, "backup GPT of of sync"); ++ + gpt->status |= GRUB_GPT_BACKUP_HEADER_VALID; + return GRUB_ERR_NONE; + } +-- +2.21.3 + diff --git a/packages/grub/0021-gpt-refuse-to-write-to-sector-0.patch b/packages/grub/0021-gpt-refuse-to-write-to-sector-0.patch new file mode 100644 index 00000000..787d0dbb --- /dev/null +++ b/packages/grub/0021-gpt-refuse-to-write-to-sector-0.patch @@ -0,0 +1,34 @@ +From d81aa092c0eb91ec618a6f0879426e8fcbdae0d4 Mon Sep 17 00:00:00 2001 +From: Michael Marineau +Date: Thu, 11 Aug 2016 15:02:21 -0700 +Subject: [PATCH] gpt: refuse to write to sector 0 + +--- + grub-core/lib/gpt.c | 7 +++++++ + 1 file changed, 7 insertions(+) + +diff --git a/grub-core/lib/gpt.c b/grub-core/lib/gpt.c +index f83fe29..b744991 100644 +--- a/grub-core/lib/gpt.c ++++ b/grub-core/lib/gpt.c +@@ -626,10 +626,17 @@ grub_gpt_write_table (grub_disk_t disk, grub_gpt_t gpt, + sizeof (*header)); + + addr = grub_gpt_sector_to_addr (gpt, grub_le_to_cpu64 (header->header_lba)); ++ if (addr == 0) ++ return grub_error (GRUB_ERR_BUG, ++ "Refusing to write GPT header to address 0x0"); + if (grub_disk_write (disk, addr, 0, sizeof (*header), header)) + return grub_errno; + + addr = grub_gpt_sector_to_addr (gpt, grub_le_to_cpu64 (header->partitions)); ++ if (addr < 2) ++ return grub_error (GRUB_ERR_BUG, ++ "Refusing to write GPT entries to address 0x%llx", ++ (unsigned long long) addr); + if (grub_disk_write (disk, addr, 0, gpt->entries_size, gpt->entries)) + return grub_errno; + +-- +2.21.3 + diff --git a/packages/grub/0022-gpt-properly-detect-and-repair-invalid-tables.patch b/packages/grub/0022-gpt-properly-detect-and-repair-invalid-tables.patch new file mode 100644 index 00000000..fbee57b8 --- /dev/null +++ b/packages/grub/0022-gpt-properly-detect-and-repair-invalid-tables.patch @@ -0,0 +1,42 @@ +From 29d1ef938cc64d87b09955645b46f947bfcf7b60 Mon Sep 17 00:00:00 2001 +From: Michael Marineau +Date: Sat, 20 Aug 2016 17:42:12 -0700 +Subject: [PATCH] gpt: properly detect and repair invalid tables + +GPT_BOTH_VALID is 4 bits so simple a boolean check is not sufficient. +This broken condition allowed gptprio to trust bogus disk locations in +headers that were marked invalid causing arbitrary disk corruption. +--- + grub-core/commands/gptprio.c | 2 +- + grub-core/lib/gpt.c | 2 +- + 2 files changed, 2 insertions(+), 2 deletions(-) + +diff --git a/grub-core/commands/gptprio.c b/grub-core/commands/gptprio.c +index 2415747..2021cb2 100644 +--- a/grub-core/commands/gptprio.c ++++ b/grub-core/commands/gptprio.c +@@ -91,7 +91,7 @@ grub_find_next (const char *disk_name, + if (!gpt) + goto done; + +- if (!(gpt->status & GRUB_GPT_BOTH_VALID)) ++ if ((gpt->status & GRUB_GPT_BOTH_VALID) != GRUB_GPT_BOTH_VALID) + if (grub_gpt_repair (dev->disk, gpt)) + goto done; + +diff --git a/grub-core/lib/gpt.c b/grub-core/lib/gpt.c +index b744991..0daf3f8 100644 +--- a/grub-core/lib/gpt.c ++++ b/grub-core/lib/gpt.c +@@ -648,7 +648,7 @@ grub_gpt_write (grub_disk_t disk, grub_gpt_t gpt) + { + /* TODO: update/repair protective MBRs too. */ + +- if (!(gpt->status & GRUB_GPT_BOTH_VALID)) ++ if ((gpt->status & GRUB_GPT_BOTH_VALID) != GRUB_GPT_BOTH_VALID) + return grub_error (GRUB_ERR_BAD_PART_TABLE, "Invalid GPT data"); + + grub_dprintf ("gpt", "writing primary GPT to %s\n", disk->name); +-- +2.21.3 + diff --git a/packages/grub/0023-gptrepair_test-fix-typo-in-cleanup-trap.patch b/packages/grub/0023-gptrepair_test-fix-typo-in-cleanup-trap.patch new file mode 100644 index 00000000..1fe747da --- /dev/null +++ b/packages/grub/0023-gptrepair_test-fix-typo-in-cleanup-trap.patch @@ -0,0 +1,25 @@ +From 725982e848e600ed6f5028fb2197a5ffe0070806 Mon Sep 17 00:00:00 2001 +From: Michael Marineau +Date: Mon, 22 Aug 2016 16:44:30 -0700 +Subject: [PATCH] gptrepair_test: fix typo in cleanup trap + +--- + tests/gptrepair_test.in | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/tests/gptrepair_test.in b/tests/gptrepair_test.in +index 80b2de6..805dc17 100644 +--- a/tests/gptrepair_test.in ++++ b/tests/gptrepair_test.in +@@ -53,7 +53,7 @@ case "${grub_modinfo_target_cpu}-${grub_modinfo_platform}" in + esac + img1="`mktemp "${TMPDIR:-/tmp}/tmp.XXXXXXXXXX"`" || exit 1 + img2="`mktemp "${TMPDIR:-/tmp}/tmp.XXXXXXXXXX"`" || exit 1 +-trap "rm -f '${img1}' '${ing2}'" EXIT ++trap "rm -f '${img1}' '${img2}'" EXIT + + create_disk_image () { + size=$1 +-- +2.21.3 + diff --git a/packages/grub/0024-gptprio_test-check-GPT-is-repaired-when-appropriate.patch b/packages/grub/0024-gptprio_test-check-GPT-is-repaired-when-appropriate.patch new file mode 100644 index 00000000..b2176e0a --- /dev/null +++ b/packages/grub/0024-gptprio_test-check-GPT-is-repaired-when-appropriate.patch @@ -0,0 +1,110 @@ +From 9b3da48085a4437f6915fee3e0d6b74de4ee714c Mon Sep 17 00:00:00 2001 +From: Michael Marineau +Date: Mon, 22 Aug 2016 16:45:10 -0700 +Subject: [PATCH] gptprio_test: check GPT is repaired when appropriate + +--- + tests/gptprio_test.in | 63 ++++++++++++++++++++++++++++++++++++++++--- + 1 file changed, 60 insertions(+), 3 deletions(-) + +diff --git a/tests/gptprio_test.in b/tests/gptprio_test.in +index f4aea0d..c5cf0f3 100644 +--- a/tests/gptprio_test.in ++++ b/tests/gptprio_test.in +@@ -66,8 +66,9 @@ prio_uuid[3]="1aa5a658-5b02-414d-9b71-f7e6c151f0cd" + prio_uuid[4]="8aa0240d-98af-42b0-b32a-ccbe0572d62b" + + create_disk_image () { ++ size=$1 + rm -f "${img1}" +- dd if=/dev/zero of="${img1}" bs=512 count=1 seek=100 status=none ++ dd if=/dev/zero of="${img1}" bs=512 count=1 seek=$((size - 1)) status=none + ${sgdisk} \ + -n 1:0:+1 -c 1:ESP -t 1:ef00 \ + -n 2:0:+1 -c 2:A -t 2:"${prio_type}" -u 2:"${prio_uuid[2]}" \ +@@ -76,6 +77,35 @@ create_disk_image () { + "${img1}" >/dev/null + } + ++wipe_disk_area () { ++ sector=$1 ++ size=$2 ++ dd if=/dev/zero of="${img1}" bs=512 count=${size} seek=${sector} conv=notrunc status=none ++} ++ ++is_zero () { ++ sector=$1 ++ size=$2 ++ cmp -s -i $((sector * 512)) -n $((size * 512)) /dev/zero "${img1}" ++} ++ ++check_is_zero () { ++ sector=$1 ++ size=$2 ++ if ! is_zero "$@"; then ++ echo "$size sector(s) starting at $sector should be all zero" ++ exit 1 ++ fi ++} ++ ++check_not_zero () { ++ sector=$1 ++ size=$2 ++ if is_zero "$@"; then ++ echo "$size sector(s) starting at $sector should not be all zero" ++ exit 1 ++ fi ++} + + fmt_prio () { + priority=$(( ( $1 & 15 ) << 48 )) +@@ -93,10 +123,10 @@ set_prio () { + check_prio () { + part="$1" + expect=$(fmt_prio $2 $3 $4) +- result=$(LANG=C ${sgdisk} -i "${part}" "${img1}" \ ++ result=$(LANG=C ${sgdisk} -i "${part}" "${img1}" 2>&1 \ + | awk '/^Attribute flags: / {print $3}') + if [[ "${expect}" != "${result}" ]]; then +- echo "Partition ${part} has attributes ${result}, not ${expect}" >&2 ++ echo "Partition ${part} has attributes ${result:-??}, not ${expect}" + exit 1 + fi + } +@@ -133,6 +163,33 @@ create_disk_image 100 + set_prio 2 3 2 1 + check_prio 2 3 2 1 + ++# Check gptprio works without modifying the disk when no update is required. ++# Leaves any existing corruption as is, repairing in the OS is better. ++create_disk_image 100 ++set_prio 2 1 0 1 ++wipe_disk_area 99 1 ++check_next 2 1 0 1 ++check_is_zero 99 1 ++ ++create_disk_image 100 ++set_prio 2 1 0 1 ++wipe_disk_area 1 1 ++check_next 2 1 0 1 ++check_is_zero 1 1 ++ ++# When writes do need to be made go ahead and perform the repair. ++create_disk_image 100 ++set_prio 2 1 1 0 ++wipe_disk_area 99 1 ++check_next 2 1 0 0 ++check_not_zero 99 1 ++ ++create_disk_image 100 ++set_prio 2 1 1 0 ++wipe_disk_area 1 1 ++check_next 2 1 0 0 ++check_not_zero 1 1 ++ + # Try two partitions before falling before falling back to a third + create_disk_image 100 + set_prio 2 3 3 0 +-- +2.21.3 + diff --git a/packages/grub/0025-gpt-fix-partition-table-indexing-and-validation.patch b/packages/grub/0025-gpt-fix-partition-table-indexing-and-validation.patch new file mode 100644 index 00000000..13bbf901 --- /dev/null +++ b/packages/grub/0025-gpt-fix-partition-table-indexing-and-validation.patch @@ -0,0 +1,326 @@ +From f5639101bd80e1246a155b7d1b576efb6fe716f4 Mon Sep 17 00:00:00 2001 +From: Michael Marineau +Date: Wed, 24 Aug 2016 16:14:20 -0700 +Subject: [PATCH] gpt: fix partition table indexing and validation + +Portions of the code attempted to handle the fact that GPT entries on +disk may be larger than the currently defined struct while others +assumed the data could be indexed by the struct size directly. This +never came up because no utility uses a size larger than 128 bytes but +for the sake of safety we need to do this by the spec. +--- + grub-core/commands/gptprio.c | 6 +- + grub-core/lib/gpt.c | 51 +++++++++++++-- + include/grub/gpt_partition.h | 11 +++- + tests/gpt_unit_test.c | 120 +++++++++++++++++++++++++++++++++++ + 4 files changed, 176 insertions(+), 12 deletions(-) + +diff --git a/grub-core/commands/gptprio.c b/grub-core/commands/gptprio.c +index 2021cb2..eebca7a 100644 +--- a/grub-core/commands/gptprio.c ++++ b/grub-core/commands/gptprio.c +@@ -78,7 +78,7 @@ grub_find_next (const char *disk_name, + const grub_gpt_part_guid_t *part_type, + char **part_name, char **part_guid) + { +- struct grub_gpt_partentry *part_found = NULL; ++ struct grub_gpt_partentry *part, *part_found = NULL; + grub_device_t dev = NULL; + grub_gpt_t gpt = NULL; + grub_uint32_t i, part_index; +@@ -95,10 +95,8 @@ grub_find_next (const char *disk_name, + if (grub_gpt_repair (dev->disk, gpt)) + goto done; + +- for (i = 0; i < grub_le_to_cpu32 (gpt->primary.maxpart); i++) ++ for (i = 0; (part = grub_gpt_get_partentry (gpt, i)) != NULL; i++) + { +- struct grub_gpt_partentry *part = &gpt->entries[i]; +- + if (grub_memcmp (part_type, &part->type, sizeof (*part_type)) == 0) + { + unsigned int priority, tries_left, successful, old_priority = 0; +diff --git a/grub-core/lib/gpt.c b/grub-core/lib/gpt.c +index 0daf3f8..2057791 100644 +--- a/grub-core/lib/gpt.c ++++ b/grub-core/lib/gpt.c +@@ -207,6 +207,13 @@ grub_gpt_pmbr_check (struct grub_msdos_partition_mbr *mbr) + return grub_error (GRUB_ERR_BAD_PART_TABLE, "invalid protective MBR"); + } + ++static grub_uint64_t ++grub_gpt_entries_size (struct grub_gpt_header *gpt) ++{ ++ return (grub_uint64_t) grub_le_to_cpu32 (gpt->maxpart) * ++ (grub_uint64_t) grub_le_to_cpu32 (gpt->partentry_size); ++} ++ + static grub_uint64_t + grub_gpt_entries_sectors (struct grub_gpt_header *gpt, + unsigned int log_sector_size) +@@ -214,11 +221,16 @@ grub_gpt_entries_sectors (struct grub_gpt_header *gpt, + grub_uint64_t sector_bytes, entries_bytes; + + sector_bytes = 1ULL << log_sector_size; +- entries_bytes = (grub_uint64_t) grub_le_to_cpu32 (gpt->maxpart) * +- (grub_uint64_t) grub_le_to_cpu32 (gpt->partentry_size); ++ entries_bytes = grub_gpt_entries_size (gpt); + return grub_divmod64(entries_bytes + sector_bytes - 1, sector_bytes, NULL); + } + ++static int ++is_pow2 (grub_uint32_t n) ++{ ++ return (n & (n - 1)) == 0; ++} ++ + grub_err_t + grub_gpt_header_check (struct grub_gpt_header *gpt, + unsigned int log_sector_size) +@@ -236,16 +248,23 @@ grub_gpt_header_check (struct grub_gpt_header *gpt, + if (gpt->crc32 != crc) + return grub_error (GRUB_ERR_BAD_PART_TABLE, "invalid GPT header crc32"); + +- /* The header size must be between 92 and the sector size. */ ++ /* The header size "must be greater than or equal to 92 and must be less ++ * than or equal to the logical block size." */ + size = grub_le_to_cpu32 (gpt->headersize); + if (size < 92U || size > (1U << log_sector_size)) + return grub_error (GRUB_ERR_BAD_PART_TABLE, "invalid GPT header size"); + +- /* The partition entry size must be a multiple of 128. */ ++ /* The partition entry size must be "a value of 128*(2^n) where n is an ++ * integer greater than or equal to zero (e.g., 128, 256, 512, etc.)." */ + size = grub_le_to_cpu32 (gpt->partentry_size); +- if (size < 128 || size % 128) ++ if (size < 128U || size % 128U || !is_pow2 (size / 128U)) + return grub_error (GRUB_ERR_BAD_PART_TABLE, "invalid GPT entry size"); + ++ /* The minimum entries table size is specified in terms of bytes, ++ * regardless of how large the individual entry size is. */ ++ if (grub_gpt_entries_size (gpt) < GRUB_GPT_DEFAULT_ENTRIES_SIZE) ++ return grub_error (GRUB_ERR_BAD_PART_TABLE, "invalid GPT entry table size"); ++ + /* And of course there better be some space for partitions! */ + start = grub_le_to_cpu64 (gpt->start); + end = grub_le_to_cpu64 (gpt->end); +@@ -410,7 +429,7 @@ static grub_err_t + grub_gpt_read_entries (grub_disk_t disk, grub_gpt_t gpt, + struct grub_gpt_header *header) + { +- struct grub_gpt_partentry *entries = NULL; ++ void *entries = NULL; + grub_uint32_t count, size, crc; + grub_uint64_t sector; + grub_disk_addr_t addr; +@@ -526,6 +545,26 @@ fail: + return NULL; + } + ++struct grub_gpt_partentry * ++grub_gpt_get_partentry (grub_gpt_t gpt, grub_uint32_t n) ++{ ++ struct grub_gpt_header *header; ++ grub_size_t offset; ++ ++ if (gpt->status & GRUB_GPT_PRIMARY_HEADER_VALID) ++ header = &gpt->primary; ++ else if (gpt->status & GRUB_GPT_BACKUP_HEADER_VALID) ++ header = &gpt->backup; ++ else ++ return NULL; ++ ++ if (n >= grub_le_to_cpu32 (header->maxpart)) ++ return NULL; ++ ++ offset = (grub_size_t) grub_le_to_cpu32 (header->partentry_size) * n; ++ return (struct grub_gpt_partentry *) ((char *) gpt->entries + offset); ++} ++ + grub_err_t + grub_gpt_repair (grub_disk_t disk, grub_gpt_t gpt) + { +diff --git a/include/grub/gpt_partition.h b/include/grub/gpt_partition.h +index 16fdd7f..1a215f8 100644 +--- a/include/grub/gpt_partition.h ++++ b/include/grub/gpt_partition.h +@@ -186,8 +186,10 @@ struct grub_gpt + struct grub_gpt_header primary; + struct grub_gpt_header backup; + +- /* Only need one entries table, on disk both copies are identical. */ +- struct grub_gpt_partentry *entries; ++ /* Only need one entries table, on disk both copies are identical. ++ * The on disk entry size may be larger than our partentry struct so ++ * the table cannot be indexed directly. */ ++ void *entries; + grub_size_t entries_size; + + /* Logarithm of sector size, in case GPT and disk driver disagree. */ +@@ -205,6 +207,11 @@ grub_gpt_sector_to_addr (grub_gpt_t gpt, grub_uint64_t sector) + /* Allocates and fills new grub_gpt structure, free with grub_gpt_free. */ + grub_gpt_t grub_gpt_read (grub_disk_t disk); + ++/* Helper for indexing into the entries table. ++ * Returns NULL when the end of the table has been reached. */ ++struct grub_gpt_partentry * grub_gpt_get_partentry (grub_gpt_t gpt, ++ grub_uint32_t n); ++ + /* Sync up primary and backup headers, recompute checksums. */ + grub_err_t grub_gpt_repair (grub_disk_t disk, grub_gpt_t gpt); + +diff --git a/tests/gpt_unit_test.c b/tests/gpt_unit_test.c +index 60f6017..9cf3414 100644 +--- a/tests/gpt_unit_test.c ++++ b/tests/gpt_unit_test.c +@@ -40,6 +40,13 @@ + /* from gnulib */ + #include + ++/* Confirm that the GPT structures conform to the sizes in the spec: ++ * The header size "must be greater than or equal to 92 and must be less ++ * than or equal to the logical block size." ++ * The partition entry size must be "a value of 128*(2^n) where n is an ++ * integer greater than or equal to zero (e.g., 128, 256, 512, etc.)." */ ++verify (sizeof (struct grub_gpt_header) == 92); ++verify (sizeof (struct grub_gpt_partentry) == 128); + + /* GPT section sizes. */ + #define HEADER_SIZE (sizeof (struct grub_gpt_header)) +@@ -537,6 +544,113 @@ repair_test (void) + close_disk (&data); + } + ++static void ++iterate_partitions_test (void) ++{ ++ struct test_data data; ++ struct grub_gpt_partentry *p; ++ grub_gpt_t gpt; ++ grub_uint32_t n; ++ ++ open_disk (&data); ++ gpt = read_disk (&data); ++ ++ for (n = 0; (p = grub_gpt_get_partentry (gpt, n)) != NULL; n++) ++ grub_test_assert (memcmp (p, &example_entries[n], sizeof (*p)) == 0, ++ "unexpected partition %d data", n); ++ ++ grub_test_assert (n == TABLE_ENTRIES, "unexpected partition limit: %d", n); ++ ++ grub_gpt_free (gpt); ++ close_disk (&data); ++} ++ ++static void ++large_partitions_test (void) ++{ ++ struct test_data data; ++ struct grub_gpt_partentry *p; ++ grub_gpt_t gpt; ++ grub_uint32_t n; ++ ++ open_disk (&data); ++ ++ /* Double the entry size, cut the number of entries in half. */ ++ data.raw->primary_header.maxpart = ++ data.raw->backup_header.maxpart = ++ grub_cpu_to_le32_compile_time (TABLE_ENTRIES/2); ++ data.raw->primary_header.partentry_size = ++ data.raw->backup_header.partentry_size = ++ grub_cpu_to_le32_compile_time (ENTRY_SIZE*2); ++ data.raw->primary_header.partentry_crc32 = ++ data.raw->backup_header.partentry_crc32 = ++ grub_cpu_to_le32_compile_time (0xf2c45af8); ++ data.raw->primary_header.crc32 = grub_cpu_to_le32_compile_time (0xde00cc8f); ++ data.raw->backup_header.crc32 = grub_cpu_to_le32_compile_time (0x6d72e284); ++ ++ memset (&data.raw->primary_entries, 0, ++ sizeof (data.raw->primary_entries)); ++ for (n = 0; n < TABLE_ENTRIES/2; n++) ++ memcpy (&data.raw->primary_entries[n*2], &example_entries[n], ++ sizeof (data.raw->primary_entries[0])); ++ memcpy (&data.raw->backup_entries, &data.raw->primary_entries, ++ sizeof (data.raw->backup_entries)); ++ ++ sync_disk(&data); ++ gpt = read_disk (&data); ++ ++ for (n = 0; (p = grub_gpt_get_partentry (gpt, n)) != NULL; n++) ++ grub_test_assert (memcmp (p, &example_entries[n], sizeof (*p)) == 0, ++ "unexpected partition %d data", n); ++ ++ grub_test_assert (n == TABLE_ENTRIES/2, "unexpected partition limit: %d", n); ++ ++ grub_gpt_free (gpt); ++ ++ /* Editing memory beyond the entry structure should still change the crc. */ ++ data.raw->primary_entries[1].attrib = 0xff; ++ ++ sync_disk(&data); ++ gpt = read_disk (&data); ++ grub_test_assert (gpt->status == (GRUB_GPT_PROTECTIVE_MBR | ++ GRUB_GPT_PRIMARY_HEADER_VALID | ++ GRUB_GPT_BACKUP_HEADER_VALID | ++ GRUB_GPT_BACKUP_ENTRIES_VALID), ++ "unexpected status: 0x%02x", gpt->status); ++ grub_gpt_free (gpt); ++ ++ close_disk (&data); ++} ++ ++static void ++invalid_partsize_test (void) ++{ ++ struct grub_gpt_header header = { ++ .magic = GRUB_GPT_HEADER_MAGIC, ++ .version = GRUB_GPT_HEADER_VERSION, ++ .headersize = sizeof (struct grub_gpt_header), ++ .crc32 = grub_cpu_to_le32_compile_time (0x1ff2a054), ++ .header_lba = grub_cpu_to_le64_compile_time (PRIMARY_HEADER_SECTOR), ++ .alternate_lba = grub_cpu_to_le64_compile_time (BACKUP_HEADER_SECTOR), ++ .start = grub_cpu_to_le64_compile_time (DATA_START_SECTOR), ++ .end = grub_cpu_to_le64_compile_time (DATA_END_SECTOR), ++ .guid = GRUB_GPT_GUID_INIT(0x69c131ad, 0x67d6, 0x46c6, ++ 0x93, 0xc4, 0x12, 0x4c, 0x75, 0x52, 0x56, 0xac), ++ .partitions = grub_cpu_to_le64_compile_time (PRIMARY_TABLE_SECTOR), ++ .maxpart = grub_cpu_to_le32_compile_time (TABLE_ENTRIES), ++ /* Triple the entry size, which is not valid. */ ++ .partentry_size = grub_cpu_to_le32_compile_time (ENTRY_SIZE*3), ++ .partentry_crc32 = grub_cpu_to_le32_compile_time (0x074e052c), ++ }; ++ ++ grub_gpt_header_check(&header, GRUB_DISK_SECTOR_BITS); ++ grub_test_assert (grub_errno == GRUB_ERR_BAD_PART_TABLE, ++ "unexpected error: %s", grub_errmsg); ++ grub_test_assert (strcmp(grub_errmsg, "invalid GPT entry size") == 0, ++ "unexpected error: %s", grub_errmsg); ++ grub_errno = GRUB_ERR_NONE; ++} ++ + static void + search_part_label_test (void) + { +@@ -657,6 +771,9 @@ grub_unit_test_init (void) + grub_test_register ("gpt_read_invalid_test", read_invalid_entries_test); + grub_test_register ("gpt_read_fallback_test", read_fallback_test); + grub_test_register ("gpt_repair_test", repair_test); ++ grub_test_register ("gpt_iterate_partitions_test", iterate_partitions_test); ++ grub_test_register ("gpt_large_partitions_test", large_partitions_test); ++ grub_test_register ("gpt_invalid_partsize_test", invalid_partsize_test); + grub_test_register ("gpt_search_part_label_test", search_part_label_test); + grub_test_register ("gpt_search_uuid_test", search_part_uuid_test); + grub_test_register ("gpt_search_disk_uuid_test", search_disk_uuid_test); +@@ -671,6 +788,9 @@ grub_unit_test_fini (void) + grub_test_unregister ("gpt_read_invalid_test"); + grub_test_unregister ("gpt_read_fallback_test"); + grub_test_unregister ("gpt_repair_test"); ++ grub_test_unregister ("gpt_iterate_partitions_test"); ++ grub_test_unregister ("gpt_large_partitions_test"); ++ grub_test_unregister ("gpt_invalid_partsize_test"); + grub_test_unregister ("gpt_search_part_label_test"); + grub_test_unregister ("gpt_search_part_uuid_test"); + grub_test_unregister ("gpt_search_disk_uuid_test"); +-- +2.21.3 + diff --git a/packages/grub/0026-gpt-prefer-disk-size-from-header-over-firmware.patch b/packages/grub/0026-gpt-prefer-disk-size-from-header-over-firmware.patch new file mode 100644 index 00000000..2772aad9 --- /dev/null +++ b/packages/grub/0026-gpt-prefer-disk-size-from-header-over-firmware.patch @@ -0,0 +1,117 @@ +From 09b0254a01a4433bd6d58e0c7386e750834b19d5 Mon Sep 17 00:00:00 2001 +From: Michael Marineau +Date: Tue, 23 Aug 2016 13:09:14 -0700 +Subject: [PATCH] gpt: prefer disk size from header over firmware + +The firmware and the OS may disagree on the disk configuration and size. +Although such a setup should be avoided users are unlikely to know about +the problem, assuming everything behaves like the OS. Tolerate this as +best we can and trust the reported on-disk location over the firmware +when looking for the backup GPT. If the location is inaccessible report +the error as best we can and move on. +--- + grub-core/lib/gpt.c | 18 +++++++++++++----- + tests/gpt_unit_test.c | 42 ++++++++++++++++++++++++++++++++++++++++++ + 2 files changed, 55 insertions(+), 5 deletions(-) + +diff --git a/grub-core/lib/gpt.c b/grub-core/lib/gpt.c +index 2057791..f0c71bd 100644 +--- a/grub-core/lib/gpt.c ++++ b/grub-core/lib/gpt.c +@@ -394,13 +394,21 @@ grub_gpt_read_backup (grub_disk_t disk, grub_gpt_t gpt) + grub_disk_addr_t addr; + + /* Assumes gpt->log_sector_size == disk->log_sector_size */ +- if (grub_gpt_disk_size_valid(disk)) ++ if (gpt->status & GRUB_GPT_PRIMARY_HEADER_VALID) ++ { ++ sector = grub_le_to_cpu64 (gpt->primary.alternate_lba); ++ if (grub_gpt_disk_size_valid (disk) && sector >= disk->total_sectors) ++ return grub_error (GRUB_ERR_OUT_OF_RANGE, ++ "backup GPT located at 0x%llx, " ++ "beyond last disk sector at 0x%llx", ++ (unsigned long long) sector, ++ (unsigned long long) disk->total_sectors - 1); ++ } ++ else if (grub_gpt_disk_size_valid (disk)) + sector = disk->total_sectors - 1; +- else if (gpt->status & GRUB_GPT_PRIMARY_HEADER_VALID) +- sector = grub_le_to_cpu64 (gpt->primary.alternate_lba); + else +- return grub_error (GRUB_ERR_NOT_IMPLEMENTED_YET, +- "Unable to locate backup GPT"); ++ return grub_error (GRUB_ERR_OUT_OF_RANGE, ++ "size of disk unknown, cannot locate backup GPT"); + + grub_dprintf ("gpt", "reading backup GPT from sector 0x%llx\n", + (unsigned long long) sector); +diff --git a/tests/gpt_unit_test.c b/tests/gpt_unit_test.c +index 9cf3414..218b186 100644 +--- a/tests/gpt_unit_test.c ++++ b/tests/gpt_unit_test.c +@@ -544,6 +544,46 @@ repair_test (void) + close_disk (&data); + } + ++/* Finding/reading/writing the backup GPT may be difficult if the OS and ++ * BIOS report different sizes for the same disk. We need to gracefully ++ * recognize this and avoid causing trouble for the OS. */ ++static void ++weird_disk_size_test (void) ++{ ++ struct test_data data; ++ grub_gpt_t gpt; ++ ++ open_disk (&data); ++ ++ /* Chop off 65536 bytes (128 512B sectors) which may happen when the ++ * BIOS thinks you are using a software RAID system that reserves that ++ * area for metadata when in fact you are not and using the bare disk. */ ++ grub_test_assert(data.dev->disk->total_sectors == DISK_SECTORS, ++ "unexpected disk size: 0x%llx", ++ (unsigned long long) data.dev->disk->total_sectors); ++ data.dev->disk->total_sectors -= 128; ++ ++ gpt = read_disk (&data); ++ assert_error_stack_empty (); ++ /* Reading the alternate_lba should have been blocked and reading ++ * the (new) end of disk should have found no useful data. */ ++ grub_test_assert ((gpt->status & GRUB_GPT_BACKUP_HEADER_VALID) == 0, ++ "unreported missing backup header"); ++ ++ /* We should be able to reconstruct the backup header and the location ++ * of the backup should remain unchanged, trusting the GPT data over ++ * what the BIOS is telling us. Further changes are left to the OS. */ ++ grub_gpt_repair (data.dev->disk, gpt); ++ grub_test_assert (grub_errno == GRUB_ERR_NONE, ++ "repair failed: %s", grub_errmsg); ++ grub_test_assert (memcmp (&gpt->primary, &example_primary, ++ sizeof (gpt->primary)) == 0, ++ "repair corrupted primary header"); ++ ++ grub_gpt_free (gpt); ++ close_disk (&data); ++} ++ + static void + iterate_partitions_test (void) + { +@@ -774,6 +814,7 @@ grub_unit_test_init (void) + grub_test_register ("gpt_iterate_partitions_test", iterate_partitions_test); + grub_test_register ("gpt_large_partitions_test", large_partitions_test); + grub_test_register ("gpt_invalid_partsize_test", invalid_partsize_test); ++ grub_test_register ("gpt_weird_disk_size_test", weird_disk_size_test); + grub_test_register ("gpt_search_part_label_test", search_part_label_test); + grub_test_register ("gpt_search_uuid_test", search_part_uuid_test); + grub_test_register ("gpt_search_disk_uuid_test", search_disk_uuid_test); +@@ -791,6 +832,7 @@ grub_unit_test_fini (void) + grub_test_unregister ("gpt_iterate_partitions_test"); + grub_test_unregister ("gpt_large_partitions_test"); + grub_test_unregister ("gpt_invalid_partsize_test"); ++ grub_test_unregister ("gpt_weird_disk_size_test"); + grub_test_unregister ("gpt_search_part_label_test"); + grub_test_unregister ("gpt_search_part_uuid_test"); + grub_test_unregister ("gpt_search_disk_uuid_test"); +-- +2.21.3 + diff --git a/packages/grub/0027-gpt-add-helper-for-picking-a-valid-header.patch b/packages/grub/0027-gpt-add-helper-for-picking-a-valid-header.patch new file mode 100644 index 00000000..0d429c4f --- /dev/null +++ b/packages/grub/0027-gpt-add-helper-for-picking-a-valid-header.patch @@ -0,0 +1,71 @@ +From 974f79ff5cfff8b37f6377d55c2e090f9c5c6251 Mon Sep 17 00:00:00 2001 +From: Vito Caputo +Date: Thu, 25 Aug 2016 17:21:18 -0700 +Subject: [PATCH] gpt: add helper for picking a valid header + +Eliminate some repetition in primary vs. backup header acquisition. +--- + grub-core/lib/gpt.c | 32 ++++++++++++++++++++------------ + 1 file changed, 20 insertions(+), 12 deletions(-) + +diff --git a/grub-core/lib/gpt.c b/grub-core/lib/gpt.c +index f0c71bd..2550ed8 100644 +--- a/grub-core/lib/gpt.c ++++ b/grub-core/lib/gpt.c +@@ -108,21 +108,32 @@ grub_gpt_part_uuid (grub_device_t device, char **uuid) + return GRUB_ERR_NONE; + } + ++static struct grub_gpt_header * ++grub_gpt_get_header (grub_gpt_t gpt) ++{ ++ if (gpt->status & GRUB_GPT_PRIMARY_HEADER_VALID) ++ return &gpt->primary; ++ else if (gpt->status & GRUB_GPT_BACKUP_HEADER_VALID) ++ return &gpt->backup; ++ ++ grub_error (GRUB_ERR_BUG, "No valid GPT header"); ++ return NULL; ++} ++ + grub_err_t + grub_gpt_disk_uuid (grub_device_t device, char **uuid) + { ++ struct grub_gpt_header *header; ++ + grub_gpt_t gpt = grub_gpt_read (device->disk); + if (!gpt) + goto done; + +- grub_errno = GRUB_ERR_NONE; ++ header = grub_gpt_get_header (gpt); ++ if (!header) ++ goto done; + +- if (gpt->status & GRUB_GPT_PRIMARY_HEADER_VALID) +- *uuid = grub_gpt_guid_to_str (&gpt->primary.guid); +- else if (gpt->status & GRUB_GPT_BACKUP_HEADER_VALID) +- *uuid = grub_gpt_guid_to_str (&gpt->backup.guid); +- else +- grub_errno = grub_error (GRUB_ERR_BUG, "No valid GPT header"); ++ *uuid = grub_gpt_guid_to_str (&header->guid); + + done: + grub_gpt_free (gpt); +@@ -559,11 +570,8 @@ grub_gpt_get_partentry (grub_gpt_t gpt, grub_uint32_t n) + struct grub_gpt_header *header; + grub_size_t offset; + +- if (gpt->status & GRUB_GPT_PRIMARY_HEADER_VALID) +- header = &gpt->primary; +- else if (gpt->status & GRUB_GPT_BACKUP_HEADER_VALID) +- header = &gpt->backup; +- else ++ header = grub_gpt_get_header (gpt); ++ if (!header) + return NULL; + + if (n >= grub_le_to_cpu32 (header->maxpart)) +-- +2.21.3 + diff --git a/packages/grub/0028-gptrepair-fix-status-checking.patch b/packages/grub/0028-gptrepair-fix-status-checking.patch new file mode 100644 index 00000000..5fe003af --- /dev/null +++ b/packages/grub/0028-gptrepair-fix-status-checking.patch @@ -0,0 +1,67 @@ +From 0969dfbba2274221ece397dc4dedfb9b03f8577b Mon Sep 17 00:00:00 2001 +From: Michael Marineau +Date: Tue, 20 Sep 2016 13:06:05 -0700 +Subject: [PATCH] gptrepair: fix status checking + +None of these status bit checks were correct. Fix and simplify. +--- + grub-core/commands/gptrepair.c | 28 +++++++++++----------------- + 1 file changed, 11 insertions(+), 17 deletions(-) + +diff --git a/grub-core/commands/gptrepair.c b/grub-core/commands/gptrepair.c +index 38392fd..66ac3f7 100644 +--- a/grub-core/commands/gptrepair.c ++++ b/grub-core/commands/gptrepair.c +@@ -46,8 +46,6 @@ grub_cmd_gptrepair (grub_command_t cmd __attribute__ ((unused)), + grub_device_t dev = NULL; + grub_gpt_t gpt = NULL; + char *dev_name; +- grub_uint32_t primary_crc, backup_crc; +- enum grub_gpt_status old_status; + + if (argc != 1 || !grub_strlen(args[0])) + return grub_error (GRUB_ERR_BAD_ARGUMENT, "device name required"); +@@ -67,29 +65,25 @@ grub_cmd_gptrepair (grub_command_t cmd __attribute__ ((unused)), + if (!gpt) + goto done; + +- primary_crc = gpt->primary.crc32; +- backup_crc = gpt->backup.crc32; +- old_status = gpt->status; +- +- if (grub_gpt_repair (dev->disk, gpt)) +- goto done; +- +- if (primary_crc == gpt->primary.crc32 && +- backup_crc == gpt->backup.crc32 && +- old_status && gpt->status) ++ if ((gpt->status & GRUB_GPT_BOTH_VALID) == GRUB_GPT_BOTH_VALID) + { + grub_printf_ (N_("GPT already valid, %s unmodified.\n"), dev_name); + goto done; + } + +- if (grub_gpt_write (dev->disk, gpt)) ++ if ((gpt->status & GRUB_GPT_PRIMARY_VALID) != GRUB_GPT_PRIMARY_VALID) ++ grub_printf_ (N_("Found invalid primary GPT on %s\n"), dev_name); ++ ++ if ((gpt->status & GRUB_GPT_BACKUP_VALID) != GRUB_GPT_BACKUP_VALID) ++ grub_printf_ (N_("Found invalid backup GPT on %s\n"), dev_name); ++ ++ if (grub_gpt_repair (dev->disk, gpt)) + goto done; + +- if (!(old_status & GRUB_GPT_PRIMARY_VALID)) +- grub_printf_ (N_("Primary GPT for %s repaired.\n"), dev_name); ++ if (grub_gpt_write (dev->disk, gpt)) ++ goto done; + +- if (!(old_status & GRUB_GPT_BACKUP_VALID)) +- grub_printf_ (N_("Backup GPT for %s repaired.\n"), dev_name); ++ grub_printf_ (N_("Repaired GPT on %s\n"), dev_name); + + done: + if (gpt) +-- +2.21.3 + diff --git a/packages/grub/0029-gpt-use-inline-functions-for-checking-status-bits.patch b/packages/grub/0029-gpt-use-inline-functions-for-checking-status-bits.patch new file mode 100644 index 00000000..1c2bf9b7 --- /dev/null +++ b/packages/grub/0029-gpt-use-inline-functions-for-checking-status-bits.patch @@ -0,0 +1,136 @@ +From 7f6fb19999b3b825a9c04cee20c8c1dee1590813 Mon Sep 17 00:00:00 2001 +From: Michael Marineau +Date: Tue, 20 Sep 2016 12:43:01 -0700 +Subject: [PATCH] gpt: use inline functions for checking status bits + +This should prevent bugs like 6078f836 and 4268f3da. +--- + grub-core/commands/gptprio.c | 2 +- + grub-core/commands/gptrepair.c | 6 +++--- + grub-core/lib/gpt.c | 9 +++++++-- + include/grub/gpt_partition.h | 35 +++++++++++++++++++++++++++------- + 4 files changed, 39 insertions(+), 13 deletions(-) + +diff --git a/grub-core/commands/gptprio.c b/grub-core/commands/gptprio.c +index eebca7a..59bc4fd 100644 +--- a/grub-core/commands/gptprio.c ++++ b/grub-core/commands/gptprio.c +@@ -91,7 +91,7 @@ grub_find_next (const char *disk_name, + if (!gpt) + goto done; + +- if ((gpt->status & GRUB_GPT_BOTH_VALID) != GRUB_GPT_BOTH_VALID) ++ if (!grub_gpt_both_valid(gpt)) + if (grub_gpt_repair (dev->disk, gpt)) + goto done; + +diff --git a/grub-core/commands/gptrepair.c b/grub-core/commands/gptrepair.c +index 66ac3f7..c17c734 100644 +--- a/grub-core/commands/gptrepair.c ++++ b/grub-core/commands/gptrepair.c +@@ -65,16 +65,16 @@ grub_cmd_gptrepair (grub_command_t cmd __attribute__ ((unused)), + if (!gpt) + goto done; + +- if ((gpt->status & GRUB_GPT_BOTH_VALID) == GRUB_GPT_BOTH_VALID) ++ if (grub_gpt_both_valid (gpt)) + { + grub_printf_ (N_("GPT already valid, %s unmodified.\n"), dev_name); + goto done; + } + +- if ((gpt->status & GRUB_GPT_PRIMARY_VALID) != GRUB_GPT_PRIMARY_VALID) ++ if (!grub_gpt_primary_valid (gpt)) + grub_printf_ (N_("Found invalid primary GPT on %s\n"), dev_name); + +- if ((gpt->status & GRUB_GPT_BACKUP_VALID) != GRUB_GPT_BACKUP_VALID) ++ if (!grub_gpt_backup_valid (gpt)) + grub_printf_ (N_("Found invalid backup GPT on %s\n"), dev_name); + + if (grub_gpt_repair (dev->disk, gpt)) +diff --git a/grub-core/lib/gpt.c b/grub-core/lib/gpt.c +index 2550ed8..3e077c4 100644 +--- a/grub-core/lib/gpt.c ++++ b/grub-core/lib/gpt.c +@@ -638,10 +638,15 @@ grub_gpt_repair (grub_disk_t disk, grub_gpt_t gpt) + if (grub_gpt_check_primary (gpt)) + return grub_error (GRUB_ERR_BUG, "Generated invalid GPT primary header"); + ++ gpt->status |= (GRUB_GPT_PRIMARY_HEADER_VALID | ++ GRUB_GPT_PRIMARY_ENTRIES_VALID); ++ + if (grub_gpt_check_backup (gpt)) + return grub_error (GRUB_ERR_BUG, "Generated invalid GPT backup header"); + +- gpt->status |= GRUB_GPT_BOTH_VALID; ++ gpt->status |= (GRUB_GPT_BACKUP_HEADER_VALID | ++ GRUB_GPT_BACKUP_ENTRIES_VALID); ++ + grub_dprintf ("gpt", "repairing GPT for %s successful\n", disk->name); + + return GRUB_ERR_NONE; +@@ -703,7 +708,7 @@ grub_gpt_write (grub_disk_t disk, grub_gpt_t gpt) + { + /* TODO: update/repair protective MBRs too. */ + +- if ((gpt->status & GRUB_GPT_BOTH_VALID) != GRUB_GPT_BOTH_VALID) ++ if (!grub_gpt_both_valid (gpt)) + return grub_error (GRUB_ERR_BAD_PART_TABLE, "Invalid GPT data"); + + grub_dprintf ("gpt", "writing primary GPT to %s\n", disk->name); +diff --git a/include/grub/gpt_partition.h b/include/grub/gpt_partition.h +index 1a215f8..b7fbb7a 100644 +--- a/include/grub/gpt_partition.h ++++ b/include/grub/gpt_partition.h +@@ -161,13 +161,6 @@ typedef enum grub_gpt_status + GRUB_GPT_BACKUP_ENTRIES_VALID = 0x20, + } grub_gpt_status_t; + +-#define GRUB_GPT_MBR_VALID (GRUB_GPT_PROTECTIVE_MBR|GRUB_GPT_HYBRID_MBR) +-#define GRUB_GPT_PRIMARY_VALID \ +- (GRUB_GPT_PRIMARY_HEADER_VALID|GRUB_GPT_PRIMARY_ENTRIES_VALID) +-#define GRUB_GPT_BACKUP_VALID \ +- (GRUB_GPT_BACKUP_HEADER_VALID|GRUB_GPT_BACKUP_ENTRIES_VALID) +-#define GRUB_GPT_BOTH_VALID (GRUB_GPT_PRIMARY_VALID|GRUB_GPT_BACKUP_VALID) +- + /* UEFI requires the entries table to be at least 16384 bytes for a + * total of 128 entries given the standard 128 byte entry size. */ + #define GRUB_GPT_DEFAULT_ENTRIES_SIZE 16384 +@@ -197,6 +190,34 @@ struct grub_gpt + }; + typedef struct grub_gpt *grub_gpt_t; + ++/* Helpers for checking the gpt status field. */ ++static inline int ++grub_gpt_mbr_valid (grub_gpt_t gpt) ++{ ++ return ((gpt->status & GRUB_GPT_PROTECTIVE_MBR) || ++ (gpt->status & GRUB_GPT_HYBRID_MBR)); ++} ++ ++static inline int ++grub_gpt_primary_valid (grub_gpt_t gpt) ++{ ++ return ((gpt->status & GRUB_GPT_PRIMARY_HEADER_VALID) && ++ (gpt->status & GRUB_GPT_PRIMARY_ENTRIES_VALID)); ++} ++ ++static inline int ++grub_gpt_backup_valid (grub_gpt_t gpt) ++{ ++ return ((gpt->status & GRUB_GPT_BACKUP_HEADER_VALID) && ++ (gpt->status & GRUB_GPT_BACKUP_ENTRIES_VALID)); ++} ++ ++static inline int ++grub_gpt_both_valid (grub_gpt_t gpt) ++{ ++ return grub_gpt_primary_valid (gpt) && grub_gpt_backup_valid (gpt); ++} ++ + /* Translate GPT sectors to GRUB's 512 byte block addresses. */ + static inline grub_disk_addr_t + grub_gpt_sector_to_addr (grub_gpt_t gpt, grub_uint64_t sector) +-- +2.21.3 + diff --git a/packages/grub/0030-gpt-allow-repair-function-to-noop.patch b/packages/grub/0030-gpt-allow-repair-function-to-noop.patch new file mode 100644 index 00000000..5e8c07b7 --- /dev/null +++ b/packages/grub/0030-gpt-allow-repair-function-to-noop.patch @@ -0,0 +1,45 @@ +From 661ed965cb87ede5c83956cc5710dbeeb97e4abf Mon Sep 17 00:00:00 2001 +From: Michael Marineau +Date: Tue, 20 Sep 2016 13:40:11 -0700 +Subject: [PATCH] gpt: allow repair function to noop + +Simplifies usage a little. +--- + grub-core/commands/gptprio.c | 5 ++--- + grub-core/lib/gpt.c | 4 ++++ + 2 files changed, 6 insertions(+), 3 deletions(-) + +diff --git a/grub-core/commands/gptprio.c b/grub-core/commands/gptprio.c +index 59bc4fd..b799faa 100644 +--- a/grub-core/commands/gptprio.c ++++ b/grub-core/commands/gptprio.c +@@ -91,9 +91,8 @@ grub_find_next (const char *disk_name, + if (!gpt) + goto done; + +- if (!grub_gpt_both_valid(gpt)) +- if (grub_gpt_repair (dev->disk, gpt)) +- goto done; ++ if (grub_gpt_repair (dev->disk, gpt)) ++ goto done; + + for (i = 0; (part = grub_gpt_get_partentry (gpt, i)) != NULL; i++) + { +diff --git a/grub-core/lib/gpt.c b/grub-core/lib/gpt.c +index 3e077c4..9bb1967 100644 +--- a/grub-core/lib/gpt.c ++++ b/grub-core/lib/gpt.c +@@ -586,6 +586,10 @@ grub_gpt_repair (grub_disk_t disk, grub_gpt_t gpt) + { + grub_uint64_t backup_header, backup_entries; + ++ /* Skip if there is nothing to do. */ ++ if (grub_gpt_both_valid (gpt)) ++ return GRUB_ERR_NONE; ++ + grub_dprintf ("gpt", "repairing GPT for %s\n", disk->name); + + if (disk->log_sector_size != gpt->log_sector_size) +-- +2.21.3 + diff --git a/packages/grub/0031-gpt-do-not-use-an-enum-for-status-bit-values.patch b/packages/grub/0031-gpt-do-not-use-an-enum-for-status-bit-values.patch new file mode 100644 index 00000000..1d712234 --- /dev/null +++ b/packages/grub/0031-gpt-do-not-use-an-enum-for-status-bit-values.patch @@ -0,0 +1,49 @@ +From 16c295c98aebfe855b7cd169420fa659dfb8d327 Mon Sep 17 00:00:00 2001 +From: Michael Marineau +Date: Wed, 21 Sep 2016 13:22:06 -0700 +Subject: [PATCH] gpt: do not use an enum for status bit values + +--- + include/grub/gpt_partition.h | 19 +++++++++---------- + 1 file changed, 9 insertions(+), 10 deletions(-) + +diff --git a/include/grub/gpt_partition.h b/include/grub/gpt_partition.h +index b7fbb7a..d94b93a 100644 +--- a/include/grub/gpt_partition.h ++++ b/include/grub/gpt_partition.h +@@ -151,15 +151,14 @@ grub_gpt_partition_map_iterate (grub_disk_t disk, + void *hook_data); + + /* Advanced GPT library. */ +-typedef enum grub_gpt_status +- { +- GRUB_GPT_PROTECTIVE_MBR = 0x01, +- GRUB_GPT_HYBRID_MBR = 0x02, +- GRUB_GPT_PRIMARY_HEADER_VALID = 0x04, +- GRUB_GPT_PRIMARY_ENTRIES_VALID = 0x08, +- GRUB_GPT_BACKUP_HEADER_VALID = 0x10, +- GRUB_GPT_BACKUP_ENTRIES_VALID = 0x20, +- } grub_gpt_status_t; ++ ++/* Status bits for the grub_gpt.status field. */ ++#define GRUB_GPT_PROTECTIVE_MBR 0x01 ++#define GRUB_GPT_HYBRID_MBR 0x02 ++#define GRUB_GPT_PRIMARY_HEADER_VALID 0x04 ++#define GRUB_GPT_PRIMARY_ENTRIES_VALID 0x08 ++#define GRUB_GPT_BACKUP_HEADER_VALID 0x10 ++#define GRUB_GPT_BACKUP_ENTRIES_VALID 0x20 + + /* UEFI requires the entries table to be at least 16384 bytes for a + * total of 128 entries given the standard 128 byte entry size. */ +@@ -170,7 +169,7 @@ typedef enum grub_gpt_status + struct grub_gpt + { + /* Bit field indicating which structures on disk are valid. */ +- grub_gpt_status_t status; ++ unsigned status; + + /* Protective or hybrid MBR. */ + struct grub_msdos_partition_mbr mbr; +-- +2.21.3 + diff --git a/packages/grub/0032-gpt-check-header-and-entries-status-bits-together.patch b/packages/grub/0032-gpt-check-header-and-entries-status-bits-together.patch new file mode 100644 index 00000000..f37eaad4 --- /dev/null +++ b/packages/grub/0032-gpt-check-header-and-entries-status-bits-together.patch @@ -0,0 +1,49 @@ +From ac788c40bb54691731a317217c9d5a7e241888ca Mon Sep 17 00:00:00 2001 +From: Michael Marineau +Date: Wed, 21 Sep 2016 13:44:11 -0700 +Subject: [PATCH] gpt: check header and entries status bits together + +Use the new status function which checks *_HEADER_VALID and +*_ENTRIES_VALID bits together. It doesn't make sense for the header and +entries bits to mismatch so don't allow for it. +--- + grub-core/lib/gpt.c | 14 +++++--------- + 1 file changed, 5 insertions(+), 9 deletions(-) + +diff --git a/grub-core/lib/gpt.c b/grub-core/lib/gpt.c +index 9bb1967..3c6ff35 100644 +--- a/grub-core/lib/gpt.c ++++ b/grub-core/lib/gpt.c +@@ -596,24 +596,20 @@ grub_gpt_repair (grub_disk_t disk, grub_gpt_t gpt) + return grub_error (GRUB_ERR_NOT_IMPLEMENTED_YET, + "GPT sector size must match disk sector size"); + +- if (!(gpt->status & GRUB_GPT_PRIMARY_ENTRIES_VALID || +- gpt->status & GRUB_GPT_BACKUP_ENTRIES_VALID)) +- return grub_error (GRUB_ERR_BUG, "No valid GPT entries"); +- +- if (gpt->status & GRUB_GPT_PRIMARY_HEADER_VALID) ++ if (grub_gpt_primary_valid (gpt)) + { +- grub_dprintf ("gpt", "primary GPT header is valid\n"); ++ grub_dprintf ("gpt", "primary GPT is valid\n"); + backup_header = grub_le_to_cpu64 (gpt->primary.alternate_lba); + grub_memcpy (&gpt->backup, &gpt->primary, sizeof (gpt->backup)); + } +- else if (gpt->status & GRUB_GPT_BACKUP_HEADER_VALID) ++ else if (grub_gpt_backup_valid (gpt)) + { +- grub_dprintf ("gpt", "backup GPT header is valid\n"); ++ grub_dprintf ("gpt", "backup GPT is valid\n"); + backup_header = grub_le_to_cpu64 (gpt->backup.header_lba); + grub_memcpy (&gpt->primary, &gpt->backup, sizeof (gpt->primary)); + } + else +- return grub_error (GRUB_ERR_BUG, "No valid GPT header"); ++ return grub_error (GRUB_ERR_BUG, "No valid GPT"); + + /* Relocate backup to end if disk whenever possible. */ + if (grub_gpt_disk_size_valid(disk)) +-- +2.21.3 + diff --git a/packages/grub/0033-gpt-be-more-careful-about-relocating-backup-header.patch b/packages/grub/0033-gpt-be-more-careful-about-relocating-backup-header.patch new file mode 100644 index 00000000..1edb3716 --- /dev/null +++ b/packages/grub/0033-gpt-be-more-careful-about-relocating-backup-header.patch @@ -0,0 +1,54 @@ +From 53e4e887d6ca11fc302bae2c417ecab94ced1252 Mon Sep 17 00:00:00 2001 +From: Michael Marineau +Date: Wed, 21 Sep 2016 13:52:52 -0700 +Subject: [PATCH] gpt: be more careful about relocating backup header + +The header was being relocated without checking the new location is +actually safe. If the BIOS thinks the disk is smaller than the OS then +repair may relocate the header into allocated space, failing the final +validation check. So only move it if the disk has grown. + +Additionally, if the backup is valid then we can assume its current +location is good enough and leave it as-is. +--- + grub-core/lib/gpt.c | 16 ++++++++++------ + 1 file changed, 10 insertions(+), 6 deletions(-) + +diff --git a/grub-core/lib/gpt.c b/grub-core/lib/gpt.c +index 3c6ff35..35e65d8 100644 +--- a/grub-core/lib/gpt.c ++++ b/grub-core/lib/gpt.c +@@ -599,7 +599,17 @@ grub_gpt_repair (grub_disk_t disk, grub_gpt_t gpt) + if (grub_gpt_primary_valid (gpt)) + { + grub_dprintf ("gpt", "primary GPT is valid\n"); ++ ++ /* Relocate backup to end if disk if the disk has grown. */ + backup_header = grub_le_to_cpu64 (gpt->primary.alternate_lba); ++ if (grub_gpt_disk_size_valid (disk) && ++ disk->total_sectors - 1 > backup_header) ++ { ++ backup_header = disk->total_sectors - 1; ++ grub_dprintf ("gpt", "backup GPT header relocated to 0x%llx\n", ++ (unsigned long long) backup_header); ++ } ++ + grub_memcpy (&gpt->backup, &gpt->primary, sizeof (gpt->backup)); + } + else if (grub_gpt_backup_valid (gpt)) +@@ -611,12 +621,6 @@ grub_gpt_repair (grub_disk_t disk, grub_gpt_t gpt) + else + return grub_error (GRUB_ERR_BUG, "No valid GPT"); + +- /* Relocate backup to end if disk whenever possible. */ +- if (grub_gpt_disk_size_valid(disk)) +- backup_header = disk->total_sectors - 1; +- grub_dprintf ("gpt", "backup GPT header will be located at 0x%llx\n", +- (unsigned long long) backup_header); +- + backup_entries = backup_header - + grub_gpt_size_to_sectors (gpt, gpt->entries_size); + grub_dprintf ("gpt", "backup GPT entries will be located at 0x%llx\n", +-- +2.21.3 + diff --git a/packages/grub/0034-gpt-selectively-update-fields-during-repair.patch b/packages/grub/0034-gpt-selectively-update-fields-during-repair.patch new file mode 100644 index 00000000..d6819890 --- /dev/null +++ b/packages/grub/0034-gpt-selectively-update-fields-during-repair.patch @@ -0,0 +1,78 @@ +From d1eb127676eb180eaf211d3a6cd9806a3e30c734 Mon Sep 17 00:00:00 2001 +From: Michael Marineau +Date: Wed, 21 Sep 2016 14:33:48 -0700 +Subject: [PATCH] gpt: selectively update fields during repair + +Just a little cleanup/refactor to skip touching data we don't need to. +--- + grub-core/lib/gpt.c | 28 ++++++++++++---------------- + 1 file changed, 12 insertions(+), 16 deletions(-) + +diff --git a/grub-core/lib/gpt.c b/grub-core/lib/gpt.c +index 35e65d8..03e807b 100644 +--- a/grub-core/lib/gpt.c ++++ b/grub-core/lib/gpt.c +@@ -584,8 +584,6 @@ grub_gpt_get_partentry (grub_gpt_t gpt, grub_uint32_t n) + grub_err_t + grub_gpt_repair (grub_disk_t disk, grub_gpt_t gpt) + { +- grub_uint64_t backup_header, backup_entries; +- + /* Skip if there is nothing to do. */ + if (grub_gpt_both_valid (gpt)) + return GRUB_ERR_NONE; +@@ -598,6 +596,8 @@ grub_gpt_repair (grub_disk_t disk, grub_gpt_t gpt) + + if (grub_gpt_primary_valid (gpt)) + { ++ grub_uint64_t backup_header; ++ + grub_dprintf ("gpt", "primary GPT is valid\n"); + + /* Relocate backup to end if disk if the disk has grown. */ +@@ -608,32 +608,28 @@ grub_gpt_repair (grub_disk_t disk, grub_gpt_t gpt) + backup_header = disk->total_sectors - 1; + grub_dprintf ("gpt", "backup GPT header relocated to 0x%llx\n", + (unsigned long long) backup_header); ++ ++ gpt->primary.alternate_lba = grub_cpu_to_le64 (backup_header); + } + + grub_memcpy (&gpt->backup, &gpt->primary, sizeof (gpt->backup)); ++ gpt->backup.header_lba = gpt->primary.alternate_lba; ++ gpt->backup.alternate_lba = gpt->primary.header_lba; ++ gpt->backup.partitions = grub_cpu_to_le64 (backup_header - ++ grub_gpt_size_to_sectors (gpt, gpt->entries_size)); + } + else if (grub_gpt_backup_valid (gpt)) + { + grub_dprintf ("gpt", "backup GPT is valid\n"); +- backup_header = grub_le_to_cpu64 (gpt->backup.header_lba); ++ + grub_memcpy (&gpt->primary, &gpt->backup, sizeof (gpt->primary)); ++ gpt->primary.header_lba = gpt->backup.alternate_lba; ++ gpt->primary.alternate_lba = gpt->backup.header_lba; ++ gpt->primary.partitions = grub_cpu_to_le64_compile_time (2); + } + else + return grub_error (GRUB_ERR_BUG, "No valid GPT"); + +- backup_entries = backup_header - +- grub_gpt_size_to_sectors (gpt, gpt->entries_size); +- grub_dprintf ("gpt", "backup GPT entries will be located at 0x%llx\n", +- (unsigned long long) backup_entries); +- +- /* Update/fixup header and partition table locations. */ +- gpt->primary.header_lba = grub_cpu_to_le64_compile_time (1); +- gpt->primary.alternate_lba = grub_cpu_to_le64 (backup_header); +- gpt->primary.partitions = grub_cpu_to_le64_compile_time (2); +- gpt->backup.header_lba = gpt->primary.alternate_lba; +- gpt->backup.alternate_lba = gpt->primary.header_lba; +- gpt->backup.partitions = grub_cpu_to_le64 (backup_entries); +- + /* Recompute checksums. */ + if (grub_gpt_update_checksums (gpt)) + return grub_errno; +-- +2.21.3 + diff --git a/packages/grub/0035-gpt-always-revalidate-when-recomputing-checksums.patch b/packages/grub/0035-gpt-always-revalidate-when-recomputing-checksums.patch new file mode 100644 index 00000000..b535efd8 --- /dev/null +++ b/packages/grub/0035-gpt-always-revalidate-when-recomputing-checksums.patch @@ -0,0 +1,75 @@ +From 6065f2a049bfe5f8ef6f90b77d2f8ab738004c50 Mon Sep 17 00:00:00 2001 +From: Michael Marineau +Date: Wed, 21 Sep 2016 14:55:19 -0700 +Subject: [PATCH] gpt: always revalidate when recomputing checksums + +This ensures all code modifying GPT data include the same sanity check +that repair does. If revalidation fails the status flags are left in the +appropriate state. +--- + grub-core/lib/gpt.c | 32 ++++++++++++++++++-------------- + 1 file changed, 18 insertions(+), 14 deletions(-) + +diff --git a/grub-core/lib/gpt.c b/grub-core/lib/gpt.c +index 03e807b..3ac2987 100644 +--- a/grub-core/lib/gpt.c ++++ b/grub-core/lib/gpt.c +@@ -630,23 +630,9 @@ grub_gpt_repair (grub_disk_t disk, grub_gpt_t gpt) + else + return grub_error (GRUB_ERR_BUG, "No valid GPT"); + +- /* Recompute checksums. */ + if (grub_gpt_update_checksums (gpt)) + return grub_errno; + +- /* Sanity check. */ +- if (grub_gpt_check_primary (gpt)) +- return grub_error (GRUB_ERR_BUG, "Generated invalid GPT primary header"); +- +- gpt->status |= (GRUB_GPT_PRIMARY_HEADER_VALID | +- GRUB_GPT_PRIMARY_ENTRIES_VALID); +- +- if (grub_gpt_check_backup (gpt)) +- return grub_error (GRUB_ERR_BUG, "Generated invalid GPT backup header"); +- +- gpt->status |= (GRUB_GPT_BACKUP_HEADER_VALID | +- GRUB_GPT_BACKUP_ENTRIES_VALID); +- + grub_dprintf ("gpt", "repairing GPT for %s successful\n", disk->name); + + return GRUB_ERR_NONE; +@@ -657,6 +643,12 @@ grub_gpt_update_checksums (grub_gpt_t gpt) + { + grub_uint32_t crc; + ++ /* Clear status bits, require revalidation of everything. */ ++ gpt->status &= ~(GRUB_GPT_PRIMARY_HEADER_VALID | ++ GRUB_GPT_PRIMARY_ENTRIES_VALID | ++ GRUB_GPT_BACKUP_HEADER_VALID | ++ GRUB_GPT_BACKUP_ENTRIES_VALID); ++ + /* Writing headers larger than our header structure are unsupported. */ + gpt->primary.headersize = + grub_cpu_to_le32_compile_time (sizeof (gpt->primary)); +@@ -670,6 +662,18 @@ grub_gpt_update_checksums (grub_gpt_t gpt) + grub_gpt_header_lecrc32 (&gpt->primary.crc32, &gpt->primary); + grub_gpt_header_lecrc32 (&gpt->backup.crc32, &gpt->backup); + ++ if (grub_gpt_check_primary (gpt)) ++ return grub_error (GRUB_ERR_BUG, "Generated invalid GPT primary header"); ++ ++ gpt->status |= (GRUB_GPT_PRIMARY_HEADER_VALID | ++ GRUB_GPT_PRIMARY_ENTRIES_VALID); ++ ++ if (grub_gpt_check_backup (gpt)) ++ return grub_error (GRUB_ERR_BUG, "Generated invalid GPT backup header"); ++ ++ gpt->status |= (GRUB_GPT_BACKUP_HEADER_VALID | ++ GRUB_GPT_BACKUP_ENTRIES_VALID); ++ + return GRUB_ERR_NONE; + } + +-- +2.21.3 + diff --git a/packages/grub/0036-gpt-include-backup-in-sync-check-in-revalidation.patch b/packages/grub/0036-gpt-include-backup-in-sync-check-in-revalidation.patch new file mode 100644 index 00000000..86c6ba38 --- /dev/null +++ b/packages/grub/0036-gpt-include-backup-in-sync-check-in-revalidation.patch @@ -0,0 +1,40 @@ +From 23ce2d3a2b0422c725b1cfb0c61fccba595f8b9b Mon Sep 17 00:00:00 2001 +From: Michael Marineau +Date: Wed, 21 Sep 2016 15:01:09 -0700 +Subject: [PATCH] gpt: include backup-in-sync check in revalidation + +--- + grub-core/lib/gpt.c | 10 +++++----- + 1 file changed, 5 insertions(+), 5 deletions(-) + +diff --git a/grub-core/lib/gpt.c b/grub-core/lib/gpt.c +index 3ac2987..c27bcc5 100644 +--- a/grub-core/lib/gpt.c ++++ b/grub-core/lib/gpt.c +@@ -372,6 +372,11 @@ grub_gpt_check_backup (grub_gpt_t gpt) + if (backup <= end) + return grub_error (GRUB_ERR_BAD_PART_TABLE, "invalid backup GPT LBA"); + ++ /* If both primary and backup are valid but differ prefer the primary. */ ++ if ((gpt->status & GRUB_GPT_PRIMARY_HEADER_VALID) && ++ !grub_gpt_headers_equal (gpt)) ++ return grub_error (GRUB_ERR_BAD_PART_TABLE, "backup GPT out of sync"); ++ + return GRUB_ERR_NONE; + } + +@@ -435,11 +440,6 @@ grub_gpt_read_backup (grub_disk_t disk, grub_gpt_t gpt) + if (grub_le_to_cpu64 (gpt->backup.header_lba) != sector) + return grub_error (GRUB_ERR_BAD_PART_TABLE, "invalid backup GPT LBA"); + +- /* If both primary and backup are valid but differ prefer the primary. */ +- if ((gpt->status & GRUB_GPT_PRIMARY_HEADER_VALID) && +- !grub_gpt_headers_equal(gpt)) +- return grub_error (GRUB_ERR_BAD_PART_TABLE, "backup GPT of of sync"); +- + gpt->status |= GRUB_GPT_BACKUP_HEADER_VALID; + return GRUB_ERR_NONE; + } +-- +2.21.3 + diff --git a/packages/grub/0037-gpt-read-entries-table-at-the-same-time-as-the-heade.patch b/packages/grub/0037-gpt-read-entries-table-at-the-same-time-as-the-heade.patch new file mode 100644 index 00000000..ffade3c2 --- /dev/null +++ b/packages/grub/0037-gpt-read-entries-table-at-the-same-time-as-the-heade.patch @@ -0,0 +1,134 @@ +From d9f966bfcdfbe8fe1ccb08c512e26a9deae4f60c Mon Sep 17 00:00:00 2001 +From: Michael Marineau +Date: Wed, 21 Sep 2016 15:29:55 -0700 +Subject: [PATCH] gpt: read entries table at the same time as the header + +I personally think this reads easier. Also has the side effect of +directly comparing the primary and backup tables instead of presuming +they are equal if the crc32 matches. +--- + grub-core/lib/gpt.c | 69 +++++++++++++++++++++++++++------------------ + 1 file changed, 41 insertions(+), 28 deletions(-) + +diff --git a/grub-core/lib/gpt.c b/grub-core/lib/gpt.c +index c27bcc5..b93cede 100644 +--- a/grub-core/lib/gpt.c ++++ b/grub-core/lib/gpt.c +@@ -32,6 +32,11 @@ GRUB_MOD_LICENSE ("GPLv3+"); + + static grub_uint8_t grub_gpt_magic[] = GRUB_GPT_HEADER_MAGIC; + ++static grub_err_t ++grub_gpt_read_entries (grub_disk_t disk, grub_gpt_t gpt, ++ struct grub_gpt_header *header, ++ void **ret_entries, ++ grub_size_t *ret_entries_size); + + char * + grub_gpt_guid_to_str (grub_gpt_guid_t *guid) +@@ -400,12 +405,21 @@ grub_gpt_read_primary (grub_disk_t disk, grub_gpt_t gpt) + return grub_errno; + + gpt->status |= GRUB_GPT_PRIMARY_HEADER_VALID; ++ ++ if (grub_gpt_read_entries (disk, gpt, &gpt->primary, ++ &gpt->entries, &gpt->entries_size)) ++ return grub_errno; ++ ++ gpt->status |= GRUB_GPT_PRIMARY_ENTRIES_VALID; ++ + return GRUB_ERR_NONE; + } + + static grub_err_t + grub_gpt_read_backup (grub_disk_t disk, grub_gpt_t gpt) + { ++ void *entries = NULL; ++ grub_size_t entries_size; + grub_uint64_t sector; + grub_disk_addr_t addr; + +@@ -441,12 +455,35 @@ grub_gpt_read_backup (grub_disk_t disk, grub_gpt_t gpt) + return grub_error (GRUB_ERR_BAD_PART_TABLE, "invalid backup GPT LBA"); + + gpt->status |= GRUB_GPT_BACKUP_HEADER_VALID; ++ ++ if (grub_gpt_read_entries (disk, gpt, &gpt->backup, ++ &entries, &entries_size)) ++ return grub_errno; ++ ++ if (gpt->status & GRUB_GPT_PRIMARY_ENTRIES_VALID) ++ { ++ if (entries_size != gpt->entries_size || ++ grub_memcmp (entries, gpt->entries, entries_size) != 0) ++ return grub_error (GRUB_ERR_BAD_PART_TABLE, "backup GPT out of sync"); ++ ++ grub_free (entries); ++ } ++ else ++ { ++ gpt->entries = entries; ++ gpt->entries_size = entries_size; ++ } ++ ++ gpt->status |= GRUB_GPT_BACKUP_ENTRIES_VALID; ++ + return GRUB_ERR_NONE; + } + + static grub_err_t + grub_gpt_read_entries (grub_disk_t disk, grub_gpt_t gpt, +- struct grub_gpt_header *header) ++ struct grub_gpt_header *header, ++ void **ret_entries, ++ grub_size_t *ret_entries_size) + { + void *entries = NULL; + grub_uint32_t count, size, crc; +@@ -488,9 +525,8 @@ grub_gpt_read_entries (grub_disk_t disk, grub_gpt_t gpt, + goto fail; + } + +- grub_free (gpt->entries); +- gpt->entries = entries; +- gpt->entries_size = entries_size; ++ *ret_entries = entries; ++ *ret_entries_size = entries_size; + return GRUB_ERR_NONE; + + fail: +@@ -529,30 +565,7 @@ grub_gpt_read (grub_disk_t disk) + grub_gpt_read_backup (disk, gpt); + + /* If either succeeded clear any possible error from the other. */ +- if (gpt->status & GRUB_GPT_PRIMARY_HEADER_VALID || +- gpt->status & GRUB_GPT_BACKUP_HEADER_VALID) +- grub_errno = GRUB_ERR_NONE; +- else +- goto fail; +- +- /* Similarly, favor the value or error from the primary table. */ +- if (gpt->status & GRUB_GPT_BACKUP_HEADER_VALID && +- !grub_gpt_read_entries (disk, gpt, &gpt->backup)) +- { +- grub_dprintf ("gpt", "read valid backup GPT from %s\n", disk->name); +- gpt->status |= GRUB_GPT_BACKUP_ENTRIES_VALID; +- } +- +- grub_errno = GRUB_ERR_NONE; +- if (gpt->status & GRUB_GPT_PRIMARY_HEADER_VALID && +- !grub_gpt_read_entries (disk, gpt, &gpt->primary)) +- { +- grub_dprintf ("gpt", "read valid primary GPT from %s\n", disk->name); +- gpt->status |= GRUB_GPT_PRIMARY_ENTRIES_VALID; +- } +- +- if (gpt->status & GRUB_GPT_PRIMARY_ENTRIES_VALID || +- gpt->status & GRUB_GPT_BACKUP_ENTRIES_VALID) ++ if (grub_gpt_primary_valid (gpt) || grub_gpt_backup_valid (gpt)) + grub_errno = GRUB_ERR_NONE; + else + goto fail; +-- +2.21.3 + diff --git a/packages/grub/0038-gpt-report-all-revalidation-errors.patch b/packages/grub/0038-gpt-report-all-revalidation-errors.patch new file mode 100644 index 00000000..d89937e9 --- /dev/null +++ b/packages/grub/0038-gpt-report-all-revalidation-errors.patch @@ -0,0 +1,40 @@ +From 48243011b5cffdbfb49c2b3d377754459a0a46a3 Mon Sep 17 00:00:00 2001 +From: Michael Marineau +Date: Wed, 21 Sep 2016 16:02:53 -0700 +Subject: [PATCH] gpt: report all revalidation errors + +Before returning an error that the primary or backup GPT is invalid push +the existing error onto the stack so the user will be told what is bad. +--- + grub-core/lib/gpt.c | 10 ++++++++-- + 1 file changed, 8 insertions(+), 2 deletions(-) + +diff --git a/grub-core/lib/gpt.c b/grub-core/lib/gpt.c +index b93cede..f6f8533 100644 +--- a/grub-core/lib/gpt.c ++++ b/grub-core/lib/gpt.c +@@ -676,13 +676,19 @@ grub_gpt_update_checksums (grub_gpt_t gpt) + grub_gpt_header_lecrc32 (&gpt->backup.crc32, &gpt->backup); + + if (grub_gpt_check_primary (gpt)) +- return grub_error (GRUB_ERR_BUG, "Generated invalid GPT primary header"); ++ { ++ grub_error_push (); ++ return grub_error (GRUB_ERR_BUG, "Generated invalid GPT primary header"); ++ } + + gpt->status |= (GRUB_GPT_PRIMARY_HEADER_VALID | + GRUB_GPT_PRIMARY_ENTRIES_VALID); + + if (grub_gpt_check_backup (gpt)) +- return grub_error (GRUB_ERR_BUG, "Generated invalid GPT backup header"); ++ { ++ grub_error_push (); ++ return grub_error (GRUB_ERR_BUG, "Generated invalid GPT backup header"); ++ } + + gpt->status |= (GRUB_GPT_BACKUP_HEADER_VALID | + GRUB_GPT_BACKUP_ENTRIES_VALID); +-- +2.21.3 + diff --git a/packages/grub/0039-gpt-rename-and-update-documentation-for-grub_gpt_upd.patch b/packages/grub/0039-gpt-rename-and-update-documentation-for-grub_gpt_upd.patch new file mode 100644 index 00000000..7490f1d5 --- /dev/null +++ b/packages/grub/0039-gpt-rename-and-update-documentation-for-grub_gpt_upd.patch @@ -0,0 +1,71 @@ +From ed3b92445adb3f2b73d22f5c0ca65447944b023f Mon Sep 17 00:00:00 2001 +From: Michael Marineau +Date: Thu, 22 Sep 2016 10:00:27 -0700 +Subject: [PATCH] gpt: rename and update documentation for grub_gpt_update + +The function now does more than just recompute checksums so give it a +more general name to reflect that. +--- + grub-core/commands/gptprio.c | 2 +- + grub-core/lib/gpt.c | 4 ++-- + include/grub/gpt_partition.h | 7 ++++--- + 3 files changed, 7 insertions(+), 6 deletions(-) + +diff --git a/grub-core/commands/gptprio.c b/grub-core/commands/gptprio.c +index b799faa..8908d8b 100644 +--- a/grub-core/commands/gptprio.c ++++ b/grub-core/commands/gptprio.c +@@ -127,7 +127,7 @@ grub_find_next (const char *disk_name, + + grub_gptprio_set_tries_left (part_found, tries_left - 1); + +- if (grub_gpt_update_checksums (gpt)) ++ if (grub_gpt_update (gpt)) + goto done; + + if (grub_gpt_write (dev->disk, gpt)) +diff --git a/grub-core/lib/gpt.c b/grub-core/lib/gpt.c +index f6f8533..4304048 100644 +--- a/grub-core/lib/gpt.c ++++ b/grub-core/lib/gpt.c +@@ -643,7 +643,7 @@ grub_gpt_repair (grub_disk_t disk, grub_gpt_t gpt) + else + return grub_error (GRUB_ERR_BUG, "No valid GPT"); + +- if (grub_gpt_update_checksums (gpt)) ++ if (grub_gpt_update (gpt)) + return grub_errno; + + grub_dprintf ("gpt", "repairing GPT for %s successful\n", disk->name); +@@ -652,7 +652,7 @@ grub_gpt_repair (grub_disk_t disk, grub_gpt_t gpt) + } + + grub_err_t +-grub_gpt_update_checksums (grub_gpt_t gpt) ++grub_gpt_update (grub_gpt_t gpt) + { + grub_uint32_t crc; + +diff --git a/include/grub/gpt_partition.h b/include/grub/gpt_partition.h +index d94b93a..797692c 100644 +--- a/include/grub/gpt_partition.h ++++ b/include/grub/gpt_partition.h +@@ -232,11 +232,12 @@ grub_gpt_t grub_gpt_read (grub_disk_t disk); + struct grub_gpt_partentry * grub_gpt_get_partentry (grub_gpt_t gpt, + grub_uint32_t n); + +-/* Sync up primary and backup headers, recompute checksums. */ ++/* Sync and update primary and backup headers if either are invalid. */ + grub_err_t grub_gpt_repair (grub_disk_t disk, grub_gpt_t gpt); + +-/* Recompute checksums, must be called after modifying GPT data. */ +-grub_err_t grub_gpt_update_checksums (grub_gpt_t gpt); ++/* Recompute checksums and revalidate everything, must be called after ++ * modifying any GPT data. */ ++grub_err_t grub_gpt_update (grub_gpt_t gpt); + + /* Write headers and entry tables back to disk. */ + grub_err_t grub_gpt_write (grub_disk_t disk, grub_gpt_t gpt); +-- +2.21.3 + diff --git a/packages/grub/0040-gpt-write-backup-GPT-first-skip-if-inaccessible.patch b/packages/grub/0040-gpt-write-backup-GPT-first-skip-if-inaccessible.patch new file mode 100644 index 00000000..e723c0eb --- /dev/null +++ b/packages/grub/0040-gpt-write-backup-GPT-first-skip-if-inaccessible.patch @@ -0,0 +1,72 @@ +From 114dc2c20130ebe232fb52f02ddb14d06a6ac890 Mon Sep 17 00:00:00 2001 +From: Michael Marineau +Date: Thu, 22 Sep 2016 11:18:42 -0700 +Subject: [PATCH] gpt: write backup GPT first, skip if inaccessible. + +Writing the primary GPT before the backup may lead to a confusing +situation: booting a freshly updated system could consistently fail and +next boot will fall back to the old system if writing the primary works +but writing the backup fails. If the backup is written first and fails +the primary is left in the old state so the next boot will re-try and +possibly fail in the exact same way. Making that repeatable should make +it easier for users to identify the error. + +Additionally if the firmware and OS disagree on the disk size, making +the backup inaccessible to GRUB, then just skip writing the backup. +When this happens the automatic call to `coreos-setgoodroot` after boot +will take care of repairing the backup. +--- + grub-core/lib/gpt.c | 28 ++++++++++++++++++++++++---- + 1 file changed, 24 insertions(+), 4 deletions(-) + +diff --git a/grub-core/lib/gpt.c b/grub-core/lib/gpt.c +index 4304048..c3e3a25 100644 +--- a/grub-core/lib/gpt.c ++++ b/grub-core/lib/gpt.c +@@ -729,19 +729,39 @@ grub_gpt_write_table (grub_disk_t disk, grub_gpt_t gpt, + grub_err_t + grub_gpt_write (grub_disk_t disk, grub_gpt_t gpt) + { ++ grub_uint64_t backup_header; ++ + /* TODO: update/repair protective MBRs too. */ + + if (!grub_gpt_both_valid (gpt)) + return grub_error (GRUB_ERR_BAD_PART_TABLE, "Invalid GPT data"); + ++ /* Write the backup GPT first so if writing fails the update is aborted ++ * and the primary is left intact. However if the backup location is ++ * inaccessible we have to just skip and hope for the best, the backup ++ * will need to be repaired in the OS. */ ++ backup_header = grub_le_to_cpu64 (gpt->backup.header_lba); ++ if (grub_gpt_disk_size_valid (disk) && ++ backup_header >= disk->total_sectors) ++ { ++ grub_printf ("warning: backup GPT located at 0x%llx, " ++ "beyond last disk sector at 0x%llx\n", ++ (unsigned long long) backup_header, ++ (unsigned long long) disk->total_sectors - 1); ++ grub_printf ("warning: only writing primary GPT, " ++ "the backup GPT must be repaired from the OS\n"); ++ } ++ else ++ { ++ grub_dprintf ("gpt", "writing backup GPT to %s\n", disk->name); ++ if (grub_gpt_write_table (disk, gpt, &gpt->backup)) ++ return grub_errno; ++ } ++ + grub_dprintf ("gpt", "writing primary GPT to %s\n", disk->name); + if (grub_gpt_write_table (disk, gpt, &gpt->primary)) + return grub_errno; + +- grub_dprintf ("gpt", "writing backup GPT to %s\n", disk->name); +- if (grub_gpt_write_table (disk, gpt, &gpt->backup)) +- return grub_errno; +- + return GRUB_ERR_NONE; + } + +-- +2.21.3 + diff --git a/packages/grub/0041-gptprio-Use-Bottlerocket-boot-partition-type-GUID.patch b/packages/grub/0041-gptprio-Use-Bottlerocket-boot-partition-type-GUID.patch new file mode 100644 index 00000000..57f8aeda --- /dev/null +++ b/packages/grub/0041-gptprio-Use-Bottlerocket-boot-partition-type-GUID.patch @@ -0,0 +1,58 @@ +From b6ae405132d795bfbb405dbf15fcb5721428b435 Mon Sep 17 00:00:00 2001 +From: iliana destroyer of worlds +Date: Thu, 28 Mar 2019 16:28:41 -0700 +Subject: [PATCH] gptprio: Use Bottlerocket boot partition type GUID + +Signed-off-by: iliana destroyer of worlds +--- + grub-core/commands/gptprio.c | 2 +- + include/grub/gpt_partition.h | 6 +++--- + tests/gptprio_test.in | 2 +- + 3 files changed, 5 insertions(+), 5 deletions(-) + +diff --git a/grub-core/commands/gptprio.c b/grub-core/commands/gptprio.c +index 8908d8b..761aea4 100644 +--- a/grub-core/commands/gptprio.c ++++ b/grub-core/commands/gptprio.c +@@ -162,7 +162,7 @@ grub_cmd_next (grub_extcmd_context_t ctxt, int argc, char **args) + char *p, *root = NULL, *part_name = NULL, *part_guid = NULL; + + /* TODO: Add a uuid parser and a command line flag for providing type. */ +- grub_gpt_part_guid_t part_type = GRUB_GPT_PARTITION_TYPE_USR_X86_64; ++ grub_gpt_part_guid_t part_type = GRUB_GPT_PARTITION_TYPE_BOTTLEROCKET_BOOT; + + if (!state[NEXT_SET_DEVICE].set || !state[NEXT_SET_UUID].set) + { +diff --git a/include/grub/gpt_partition.h b/include/grub/gpt_partition.h +index 797692c..2bbfd33 100644 +--- a/include/grub/gpt_partition.h ++++ b/include/grub/gpt_partition.h +@@ -61,9 +61,9 @@ char * grub_gpt_guid_to_str (grub_gpt_guid_t *guid); + GRUB_GPT_GUID_INIT (0x5808c8aa, 0x7e8f, 0x42e0, \ + 0x85, 0xd2, 0xe1, 0xe9, 0x04, 0x34, 0xcf, 0xb3) + +-#define GRUB_GPT_PARTITION_TYPE_USR_X86_64 \ +- GRUB_GPT_GUID_INIT (0x5dfbf5f4, 0x2848, 0x4bac, \ +- 0xaa, 0x5e, 0x0d, 0x9a, 0x20, 0xb7, 0x45, 0xa6) ++#define GRUB_GPT_PARTITION_TYPE_BOTTLEROCKET_BOOT \ ++ GRUB_GPT_GUID_INIT (0x6b636168, 0x7420, 0x6568, \ ++ 0x20, 0x70, 0x6c, 0x61, 0x6e, 0x65, 0x74, 0x21) + + #define GRUB_GPT_HEADER_MAGIC \ + { 0x45, 0x46, 0x49, 0x20, 0x50, 0x41, 0x52, 0x54 } +diff --git a/tests/gptprio_test.in b/tests/gptprio_test.in +index c5cf0f3..9df4dd3 100644 +--- a/tests/gptprio_test.in ++++ b/tests/gptprio_test.in +@@ -59,7 +59,7 @@ esac + img1="`mktemp "${TMPDIR:-/tmp}/tmp.XXXXXXXXXX"`" || exit 1 + trap "rm -f '${img1}'" EXIT + +-prio_type="5dfbf5f4-2848-4bac-aa5e-0d9a20b745a6" ++prio_type="6b636168-7420-6568-2070-6c616e657421" + declare -a prio_uuid + prio_uuid[2]="9b003904-d006-4ab3-97f1-73f547b7af1a" + prio_uuid[3]="1aa5a658-5b02-414d-9b71-f7e6c151f0cd" +-- +2.21.3 + diff --git a/packages/grub/0042-util-mkimage-Bump-EFI-PE-header-size-to-accommodate-.patch b/packages/grub/0042-util-mkimage-Bump-EFI-PE-header-size-to-accommodate-.patch new file mode 100644 index 00000000..2a61a130 --- /dev/null +++ b/packages/grub/0042-util-mkimage-Bump-EFI-PE-header-size-to-accommodate-.patch @@ -0,0 +1,46 @@ +From 2dd65e321c9786dbec249e0826c58f530bcb5883 Mon Sep 17 00:00:00 2001 +From: Markus Boehme +Date: Fri, 28 Oct 2022 13:39:03 +0000 +Subject: [PATCH] util/mkimage: Bump EFI PE header size to accommodate .sbat + section + +With the --sbat option mkimage can embed SBAT metadata into a dedicated +.sbat section of the EFI image. However, no space was explicitly +reserved for this section in the section table of the PE header. + +The miss has no adverse effects since there was enough padding in the +header anyway due to alignment constraints. An earlier commit, +a51f953f4ee8 ("mkimage: Align efi sections on 4k boundary"), increased +alignment to 4 KiB, so that the extra section table entry fit +comfortably inside the space reserved for the entire header anyway. + +Fixes: b11547137703 ("util/mkimage: Add an option to import SBAT metadata into a .sbat section") +Signed-off-by: Markus Boehme +--- + util/mkimage.c | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +diff --git a/util/mkimage.c b/util/mkimage.c +index c3d33aa..2db1045 100644 +--- a/util/mkimage.c ++++ b/util/mkimage.c +@@ -65,14 +65,14 @@ + + GRUB_PE32_SIGNATURE_SIZE \ + + sizeof (struct grub_pe32_coff_header) \ + + sizeof (struct grub_pe32_optional_header) \ +- + 4 * sizeof (struct grub_pe32_section_table), \ ++ + 5 * sizeof (struct grub_pe32_section_table), \ + GRUB_PE32_FILE_ALIGNMENT) + + #define EFI64_HEADER_SIZE ALIGN_UP (GRUB_PE32_MSDOS_STUB_SIZE \ + + GRUB_PE32_SIGNATURE_SIZE \ + + sizeof (struct grub_pe32_coff_header) \ + + sizeof (struct grub_pe64_optional_header) \ +- + 4 * sizeof (struct grub_pe32_section_table), \ ++ + 5 * sizeof (struct grub_pe32_section_table), \ + GRUB_PE32_FILE_ALIGNMENT) + + static const struct grub_install_image_target_desc image_targets[] = +-- +2.39.0 + diff --git a/packages/grub/0043-util-mkimage-avoid-adding-section-table-entry-outsid.patch b/packages/grub/0043-util-mkimage-avoid-adding-section-table-entry-outsid.patch new file mode 100644 index 00000000..820313f4 --- /dev/null +++ b/packages/grub/0043-util-mkimage-avoid-adding-section-table-entry-outsid.patch @@ -0,0 +1,98 @@ +From 45468642affc3d641b5d73c5d6e63e1578bf9150 Mon Sep 17 00:00:00 2001 +From: Markus Boehme +Date: Fri, 28 Oct 2022 16:09:05 +0000 +Subject: [PATCH] util/mkimage: avoid adding section table entry outside PE EFI + header + +The number of sections in a PE EFI image can vary depending on the +options passed to mkimage, but their maximum number must be known at +compile time. Potentially adding a new section to a PE EFI image +therefore requires changes in at least two places of the code. + +The prior commit fixed a situation where the maximum number of sections +was not bumped while implementing support for an new section. Catch +these situations at runtime rather than silently relying on sufficient +padding being available for the new section table entry or overwriting +part of the image. + +Signed-off-by: Markus Boehme +--- + util/mkimage.c | 20 +++++++++++++++----- + 1 file changed, 15 insertions(+), 5 deletions(-) + +diff --git a/util/mkimage.c b/util/mkimage.c +index 2db1045..1455c94 100644 +--- a/util/mkimage.c ++++ b/util/mkimage.c +@@ -821,6 +821,7 @@ grub_install_get_image_targets_string (void) + */ + static struct grub_pe32_section_table * + init_pe_section(const struct grub_install_image_target_desc *image_target, ++ const char *pe_img, + struct grub_pe32_section_table *section, + const char * const name, + grub_uint32_t *vma, grub_uint32_t vsz, grub_uint32_t valign, +@@ -828,6 +829,15 @@ init_pe_section(const struct grub_install_image_target_desc *image_target, + grub_uint32_t characteristics) + { + size_t len = strlen (name); ++ const char *pe_header_end; ++ ++ if (image_target->voidp_sizeof == 4) ++ pe_header_end = pe_img + EFI32_HEADER_SIZE; ++ else ++ pe_header_end = pe_img + EFI64_HEADER_SIZE; ++ ++ if ((char *) section >= pe_header_end) ++ grub_util_error (_("section table space exhausted trying to add %s"), name); + + if (len > sizeof (section->name)) + grub_util_error (_("section name %s length is bigger than %lu"), +@@ -1438,7 +1448,7 @@ grub_install_generate_image (const char *dir, const char *prefix, + /* The sections. */ + PE_OHDR (o32, o64, code_base) = grub_host_to_target32 (vma); + PE_OHDR (o32, o64, code_size) = grub_host_to_target32 (layout.exec_size); +- section = init_pe_section (image_target, section, ".text", ++ section = init_pe_section (image_target, pe_img, section, ".text", + &vma, layout.exec_size, + image_target->section_align, + &raw_data, layout.exec_size, +@@ -1452,7 +1462,7 @@ grub_install_generate_image (const char *dir, const char *prefix, + ALIGN_UP (total_module_size, + GRUB_PE32_FILE_ALIGNMENT)); + +- section = init_pe_section (image_target, section, ".data", ++ section = init_pe_section (image_target, pe_img, section, ".data", + &vma, scn_size, image_target->section_align, + &raw_data, scn_size, + GRUB_PE32_SCN_CNT_INITIALIZED_DATA | +@@ -1460,7 +1470,7 @@ grub_install_generate_image (const char *dir, const char *prefix, + GRUB_PE32_SCN_MEM_WRITE); + + scn_size = pe_size - layout.reloc_size - sbat_size - raw_data; +- section = init_pe_section (image_target, section, "mods", ++ section = init_pe_section (image_target, pe_img, section, "mods", + &vma, scn_size, image_target->section_align, + &raw_data, scn_size, + GRUB_PE32_SCN_CNT_INITIALIZED_DATA | +@@ -1472,7 +1482,7 @@ grub_install_generate_image (const char *dir, const char *prefix, + pe_sbat = pe_img + raw_data; + grub_util_load_image (sbat_path, pe_sbat); + +- section = init_pe_section (image_target, section, ".sbat", ++ section = init_pe_section (image_target, pe_img, section, ".sbat", + &vma, sbat_size, + image_target->section_align, + &raw_data, sbat_size, +@@ -1484,7 +1494,7 @@ grub_install_generate_image (const char *dir, const char *prefix, + PE_OHDR (o32, o64, base_relocation_table.rva) = grub_host_to_target32 (vma); + PE_OHDR (o32, o64, base_relocation_table.size) = grub_host_to_target32 (scn_size); + memcpy (pe_img + raw_data, layout.reloc_section, scn_size); +- init_pe_section (image_target, section, ".reloc", ++ init_pe_section (image_target, pe_img, section, ".reloc", + &vma, scn_size, image_target->section_align, + &raw_data, scn_size, + GRUB_PE32_SCN_CNT_INITIALIZED_DATA | +-- +2.39.0 + diff --git a/packages/grub/0044-efi-return-virtual-size-of-section-found-by-grub_efi.patch b/packages/grub/0044-efi-return-virtual-size-of-section-found-by-grub_efi.patch new file mode 100644 index 00000000..404baa3f --- /dev/null +++ b/packages/grub/0044-efi-return-virtual-size-of-section-found-by-grub_efi.patch @@ -0,0 +1,93 @@ +From 076f520ec85198e82ddc0615e596df2a1ce4264b Mon Sep 17 00:00:00 2001 +From: Markus Boehme +Date: Wed, 2 Nov 2022 11:43:32 +0000 +Subject: [PATCH] efi: return virtual size of section found by + grub_efi_section_addr + +Return the virtual size of a section found by grub_efi_section_addr if +the caller asked for it. Modify the few existing callers who don't care +about the section size to fit the extended interface. + +This is close to the point where the implementation could do with a +refactoring, e.g. have a separate grub_efi_find_section that returns the +entire section table entry, and more focused convenience functions to +access those. However, grub_efi_find_section itself is already the +result of a Fedora refactoring, so I'm keeping the changes minimal. + +Signed-off-by: Markus Boehme +--- + grub-core/kern/efi/efi.c | 8 ++++++-- + grub-core/kern/efi/init.c | 6 +++--- + include/grub/efi/efi.h | 2 +- + 3 files changed, 10 insertions(+), 6 deletions(-) + +diff --git a/grub-core/kern/efi/efi.c b/grub-core/kern/efi/efi.c +index 4ac2b27..3a4475c 100644 +--- a/grub-core/kern/efi/efi.c ++++ b/grub-core/kern/efi/efi.c +@@ -310,9 +310,11 @@ grub_efi_get_variable (const char *var, const grub_efi_guid_t *guid, + #pragma GCC diagnostic ignored "-Wcast-align" + + /* Search the mods section from the PE32/PE32+ image. This code uses +- a PE32 header, but should work with PE32+ as well. */ ++ a PE32 header, but should work with PE32+ as well. If vsz is not ++ NULL and the section is found, the virtual size of the section ++ is written to *vsz. */ + grub_addr_t +-grub_efi_section_addr (const char *section_name) ++grub_efi_section_addr (const char *section_name, grub_uint32_t *vsz) + { + grub_efi_loaded_image_t *image; + struct grub_pe32_header *header; +@@ -359,6 +361,8 @@ grub_efi_section_addr (const char *section_name) + + grub_dprintf("sections", "returning section info for section %d: \"%s\"\n", + i, section->name); ++ if (vsz) ++ *vsz = section->virtual_size; + return (grub_addr_t) info; + } + +diff --git a/grub-core/kern/efi/init.c b/grub-core/kern/efi/init.c +index 0574d8d..533de93 100644 +--- a/grub-core/kern/efi/init.c ++++ b/grub-core/kern/efi/init.c +@@ -116,11 +116,11 @@ grub_efi_print_gdb_info (void) + grub_addr_t text; + grub_addr_t data; + +- text = grub_efi_section_addr (".text"); ++ text = grub_efi_section_addr (".text", NULL); + if (!text) + return; + +- data = grub_efi_section_addr (".data"); ++ data = grub_efi_section_addr (".data", NULL); + if (data) + grub_qdprintf ("gdb", + "add-symbol-file /usr/lib/debug/usr/lib/grub/%s-%s/" +@@ -136,7 +136,7 @@ grub_efi_print_gdb_info (void) + void + grub_efi_init (void) + { +- grub_modbase = grub_efi_section_addr ("mods"); ++ grub_modbase = grub_efi_section_addr ("mods", NULL); + /* First of all, initialize the console so that GRUB can display + messages. */ + grub_console_init (); +diff --git a/include/grub/efi/efi.h b/include/grub/efi/efi.h +index 449e552..5841a2e 100644 +--- a/include/grub/efi/efi.h ++++ b/include/grub/efi/efi.h +@@ -152,7 +152,7 @@ grub_err_t grub_arch_efi_linux_boot_image(grub_addr_t addr, grub_size_t size, + char *args, int nx_enabled); + #endif + +-grub_addr_t grub_efi_section_addr (const char *section); ++grub_addr_t grub_efi_section_addr (const char *section, grub_uint32_t *vsz); + + void grub_efi_mm_init (void); + void grub_efi_mm_fini (void); +-- +2.39.0 + diff --git a/packages/grub/0045-mkimage-pgp-move-single-public-key-into-its-own-sect.patch b/packages/grub/0045-mkimage-pgp-move-single-public-key-into-its-own-sect.patch new file mode 100644 index 00000000..537f53bc --- /dev/null +++ b/packages/grub/0045-mkimage-pgp-move-single-public-key-into-its-own-sect.patch @@ -0,0 +1,261 @@ +From eaa371d26be8f76f9d7ce7e9c4b5d30684a48f11 Mon Sep 17 00:00:00 2001 +From: Markus Boehme +Date: Mon, 24 Oct 2022 15:20:23 +0000 +Subject: [PATCH] mkimage, pgp: move single public key into its own section of + EFI image + +If mkimage is asked to embed a single public key for signature checking +into an EFI image, move that key into a new .pubkey section of the PE +file. Moving the key into its dedicated section allows for easily +swapping the public key, e.g. using objcopy, without having to rebuild +the image. + +If more than one key is to be embedded, no new section is created and +all keys are embedded as modules just as before. The PGP signature +verification will check both of these sources for valid keys. + +Signed-off-by: Markus Boehme +--- + grub-core/commands/pgp.c | 28 ++++++++++++++ + include/grub/efi/efi.h | 2 +- + util/mkimage.c | 84 +++++++++++++++++++++++++++------------- + 3 files changed, 87 insertions(+), 27 deletions(-) + +diff --git a/grub-core/commands/pgp.c b/grub-core/commands/pgp.c +index b81ac0a..5fa1e8e 100644 +--- a/grub-core/commands/pgp.c ++++ b/grub-core/commands/pgp.c +@@ -32,6 +32,7 @@ + #include + #include + #include ++#include + + GRUB_MOD_LICENSE ("GPLv3+"); + +@@ -959,6 +960,33 @@ GRUB_MOD_INIT(pgp) + grub_pk_trusted = pk; + } + ++#ifdef GRUB_MACHINE_EFI ++ { ++ grub_addr_t pubkey_section; ++ grub_uint32_t pubkey_vsz; ++ ++ pubkey_section = grub_efi_section_addr (".pubkey", &pubkey_vsz); ++ if (pubkey_section) ++ { ++ struct grub_file pseudo_file; ++ struct grub_public_key *pk; ++ ++ grub_memset (&pseudo_file, 0, sizeof (pseudo_file)); ++ ++ pseudo_file.fs = &pseudo_fs; ++ pseudo_file.size = pubkey_vsz; ++ pseudo_file.data = (char *) pubkey_section; ++ ++ pk = grub_load_public_key (&pseudo_file); ++ if (!pk) ++ grub_fatal ("error loading key from .pubkey section: %s\n", grub_errmsg); ++ ++ pk->next = grub_pk_trusted; ++ grub_pk_trusted = pk; ++ } ++ } ++#endif /* GRUB_MACHINE_EFI */ ++ + if (!val) + grub_env_set ("check_signatures", grub_pk_trusted ? "enforce" : "no"); + +diff --git a/include/grub/efi/efi.h b/include/grub/efi/efi.h +index 5841a2e..d580b6b 100644 +--- a/include/grub/efi/efi.h ++++ b/include/grub/efi/efi.h +@@ -152,7 +152,7 @@ grub_err_t grub_arch_efi_linux_boot_image(grub_addr_t addr, grub_size_t size, + char *args, int nx_enabled); + #endif + +-grub_addr_t grub_efi_section_addr (const char *section, grub_uint32_t *vsz); ++grub_addr_t EXPORT_FUNC(grub_efi_section_addr) (const char *section, grub_uint32_t *vsz); + + void grub_efi_mm_init (void); + void grub_efi_mm_fini (void); +diff --git a/util/mkimage.c b/util/mkimage.c +index 1455c94..01362d1 100644 +--- a/util/mkimage.c ++++ b/util/mkimage.c +@@ -65,14 +65,14 @@ + + GRUB_PE32_SIGNATURE_SIZE \ + + sizeof (struct grub_pe32_coff_header) \ + + sizeof (struct grub_pe32_optional_header) \ +- + 5 * sizeof (struct grub_pe32_section_table), \ ++ + 6 * sizeof (struct grub_pe32_section_table), \ + GRUB_PE32_FILE_ALIGNMENT) + + #define EFI64_HEADER_SIZE ALIGN_UP (GRUB_PE32_MSDOS_STUB_SIZE \ + + GRUB_PE32_SIGNATURE_SIZE \ + + sizeof (struct grub_pe32_coff_header) \ + + sizeof (struct grub_pe64_optional_header) \ +- + 5 * sizeof (struct grub_pe32_section_table), \ ++ + 6 * sizeof (struct grub_pe32_section_table), \ + GRUB_PE32_FILE_ALIGNMENT) + + static const struct grub_install_image_target_desc image_targets[] = +@@ -887,12 +887,13 @@ grub_install_generate_image (const char *dir, const char *prefix, + char *kernel_img, *core_img; + size_t total_module_size, core_size; + size_t memdisk_size = 0, config_size = 0; +- size_t prefix_size = 0, dtb_size = 0, sbat_size = 0; ++ size_t prefix_size = 0, dtb_size = 0, pubkey_size = 0, sbat_size = 0; + char *kernel_path; + size_t offset; + struct grub_util_path_list *path_list, *p; + size_t decompress_size = 0; + struct grub_mkimage_layout layout; ++ int pubkey_section = 0; + + if (comp == GRUB_COMPRESSION_AUTO) + comp = image_target->default_compression; +@@ -911,7 +912,10 @@ grub_install_generate_image (const char *dir, const char *prefix, + else + total_module_size = sizeof (struct grub_module_info32); + +- { ++ if (npubkeys == 1 && image_target->id == IMAGE_EFI) ++ pubkey_section = 1; ++ ++ if (!pubkey_section) { + size_t i; + for (i = 0; i < npubkeys; i++) + { +@@ -1048,24 +1052,25 @@ grub_install_generate_image (const char *dir, const char *prefix, + offset += mod_size; + } + +- { +- size_t i; +- for (i = 0; i < npubkeys; i++) +- { +- size_t curs; +- struct grub_module_header *header; +- +- curs = grub_util_get_image_size (pubkey_paths[i]); +- +- header = (struct grub_module_header *) (kernel_img + offset); +- header->type = grub_host_to_target32 (OBJ_TYPE_GPG_PUBKEY); +- header->size = grub_host_to_target32 (curs + sizeof (*header)); +- offset += sizeof (*header); +- +- grub_util_load_image (pubkey_paths[i], kernel_img + offset); +- offset += ALIGN_ADDR (curs); +- } +- } ++ if (!pubkey_section) ++ { ++ size_t i; ++ for (i = 0; i < npubkeys; i++) ++ { ++ size_t curs; ++ struct grub_module_header *header; ++ ++ curs = grub_util_get_image_size (pubkey_paths[i]); ++ ++ header = (struct grub_module_header *) (kernel_img + offset); ++ header->type = grub_host_to_target32 (OBJ_TYPE_GPG_PUBKEY); ++ header->size = grub_host_to_target32 (curs + sizeof (*header)); ++ offset += sizeof (*header); ++ ++ grub_util_load_image (pubkey_paths[i], kernel_img + offset); ++ offset += ALIGN_ADDR (curs); ++ } ++ } + + { + size_t i; +@@ -1351,7 +1356,7 @@ grub_install_generate_image (const char *dir, const char *prefix, + break; + case IMAGE_EFI: + { +- char *pe_img, *pe_sbat, *header; ++ char *pe_img, *pe_pubkey, *pe_sbat, *header; + struct grub_pe32_section_table *section; + size_t n_sections = 4; + size_t scn_size; +@@ -1369,6 +1374,16 @@ grub_install_generate_image (const char *dir, const char *prefix, + + vma = raw_data = header_size; + ++ if (pubkey_section) ++ { ++ pubkey_size = ALIGN_ADDR (grub_util_get_image_size (pubkey_paths[0])); ++ pubkey_size = ALIGN_UP (pubkey_size, GRUB_PE32_FILE_ALIGNMENT); ++ if (pubkey_size == 0) ++ grub_util_error ( ++ _("embedding public key '%s' would result in invalid empty section"), ++ pubkey_paths[0]); ++ } ++ + if (sbat_path != NULL) + { + sbat_size = ALIGN_ADDR (grub_util_get_image_size (sbat_path)); +@@ -1376,7 +1391,8 @@ grub_install_generate_image (const char *dir, const char *prefix, + } + + pe_size = ALIGN_UP (header_size + core_size, GRUB_PE32_FILE_ALIGNMENT) + +- ALIGN_UP (layout.reloc_size, GRUB_PE32_FILE_ALIGNMENT) + sbat_size; ++ ALIGN_UP (layout.reloc_size, GRUB_PE32_FILE_ALIGNMENT) + ++ pubkey_size + sbat_size; + header = pe_img = xcalloc (1, pe_size); + + memcpy (pe_img + raw_data, core_img, core_size); +@@ -1391,6 +1407,9 @@ grub_install_generate_image (const char *dir, const char *prefix, + + GRUB_PE32_SIGNATURE_SIZE); + c->machine = grub_host_to_target16 (image_target->pe_target); + ++ if (pubkey_section) ++ n_sections++; ++ + if (sbat_path != NULL) + n_sections++; + +@@ -1458,7 +1477,7 @@ grub_install_generate_image (const char *dir, const char *prefix, + + scn_size = ALIGN_UP (layout.kernel_size - layout.exec_size, GRUB_PE32_FILE_ALIGNMENT); + /* ALIGN_UP (sbat_size, GRUB_PE32_FILE_ALIGNMENT) is done earlier. */ +- PE_OHDR (o32, o64, data_size) = grub_host_to_target32 (scn_size + sbat_size + ++ PE_OHDR (o32, o64, data_size) = grub_host_to_target32 (scn_size + pubkey_size + sbat_size + + ALIGN_UP (total_module_size, + GRUB_PE32_FILE_ALIGNMENT)); + +@@ -1469,7 +1488,7 @@ grub_install_generate_image (const char *dir, const char *prefix, + GRUB_PE32_SCN_MEM_READ | + GRUB_PE32_SCN_MEM_WRITE); + +- scn_size = pe_size - layout.reloc_size - sbat_size - raw_data; ++ scn_size = pe_size - layout.reloc_size - pubkey_size - sbat_size - raw_data; + section = init_pe_section (image_target, pe_img, section, "mods", + &vma, scn_size, image_target->section_align, + &raw_data, scn_size, +@@ -1477,6 +1496,19 @@ grub_install_generate_image (const char *dir, const char *prefix, + GRUB_PE32_SCN_MEM_READ | + GRUB_PE32_SCN_MEM_WRITE); + ++ if (pubkey_section) ++ { ++ pe_pubkey = pe_img + raw_data; ++ grub_util_load_image (pubkey_paths[0], pe_pubkey); ++ ++ section = init_pe_section (image_target, pe_img, section, ".pubkey", ++ &vma, pubkey_size, ++ image_target->section_align, ++ &raw_data, pubkey_size, ++ GRUB_PE32_SCN_CNT_INITIALIZED_DATA | ++ GRUB_PE32_SCN_MEM_READ); ++ } ++ + if (sbat_path != NULL) + { + pe_sbat = pe_img + raw_data; +-- +2.39.0 + diff --git a/packages/grub/0046-Revert-sb-Add-fallback-to-EFI-LoadImage-if-shim_lock.patch b/packages/grub/0046-Revert-sb-Add-fallback-to-EFI-LoadImage-if-shim_lock.patch new file mode 100644 index 00000000..217d3895 --- /dev/null +++ b/packages/grub/0046-Revert-sb-Add-fallback-to-EFI-LoadImage-if-shim_lock.patch @@ -0,0 +1,96 @@ +From 2773f01f5d9292c68b08f9392a8ae0bf9c2e3e30 Mon Sep 17 00:00:00 2001 +From: Ben Cressey +Date: Tue, 13 Feb 2024 22:20:16 +0000 +Subject: [PATCH] Revert "sb: Add fallback to EFI LoadImage if shim_lock is + absent" + +For Secure Boot in Bottlerocket, we expect that shim_lock will always +be present, and don't need a fallback. + +Signed-off-by: Ben Cressey +--- + grub-core/Makefile.core.def | 1 - + grub-core/kern/efi/sb.c | 43 +++---------------------------------- + 2 files changed, 3 insertions(+), 41 deletions(-) + +diff --git a/grub-core/Makefile.core.def b/grub-core/Makefile.core.def +index 5b8728e..3096cd4 100644 +--- a/grub-core/Makefile.core.def ++++ b/grub-core/Makefile.core.def +@@ -214,7 +214,6 @@ kernel = { + efi = kern/efi/sb.c; + efi = kern/lockdown.c; + efi = lib/envblk.c; +- efi = lib/crc.c; + i386_coreboot = kern/i386/pc/acpi.c; + i386_multiboot = kern/i386/pc/acpi.c; + i386_coreboot = kern/acpi.c; +diff --git a/grub-core/kern/efi/sb.c b/grub-core/kern/efi/sb.c +index 70f9d9d..db42c25 100644 +--- a/grub-core/kern/efi/sb.c ++++ b/grub-core/kern/efi/sb.c +@@ -29,7 +29,6 @@ + #include + #include + #include +-#include + + static grub_efi_guid_t shim_lock_guid = GRUB_EFI_SHIM_LOCK_GUID; + +@@ -171,50 +170,14 @@ shim_lock_verifier_init (grub_file_t io __attribute__ ((unused)), + } + } + +-static int grub_shim_lock_load_image_fallback(void *data, grub_uint32_t size) +-{ +- grub_efi_memory_mapped_device_path_t *mempath; +- grub_efi_handle_t image_handle = 0; +- grub_efi_boot_services_t *b; +- grub_efi_status_t status; +- int len; +- +- mempath = grub_malloc (2 * sizeof (grub_efi_memory_mapped_device_path_t)); +- if (!mempath) +- return grub_errno; +- +- mempath[0].header.type = GRUB_EFI_HARDWARE_DEVICE_PATH_TYPE; +- mempath[0].header.subtype = GRUB_EFI_MEMORY_MAPPED_DEVICE_PATH_SUBTYPE; +- mempath[0].header.length = grub_cpu_to_le16_compile_time (sizeof (*mempath)); +- mempath[0].memory_type = GRUB_EFI_LOADER_DATA; +- mempath[0].start_address = (grub_addr_t)data; +- mempath[0].end_address = (grub_addr_t)data + size; +- +- mempath[1].header.type = GRUB_EFI_END_DEVICE_PATH_TYPE; +- mempath[1].header.subtype = GRUB_EFI_END_ENTIRE_DEVICE_PATH_SUBTYPE; +- mempath[1].header.length = sizeof (grub_efi_device_path_t); +- +- b = grub_efi_system_table->boot_services; +- status = efi_call_6 (b->load_image, 0, grub_efi_image_handle, +- (grub_efi_device_path_t *) mempath, +- data, size, &image_handle); +- if (status != GRUB_EFI_SUCCESS) { +- return grub_error (GRUB_ERR_ACCESS_DENIED, +- "Cannot verify image, EFI err: %ld", (long)status); +- } +- efi_call_1 (b->unload_image, image_handle); +- return GRUB_ERR_NONE; +-} +- + static grub_err_t + shim_lock_verifier_write (void *context __attribute__ ((unused)), void *buf, grub_size_t size) + { + grub_efi_shim_lock_protocol_t *sl = grub_efi_locate_protocol (&shim_lock_guid, 0); + +- if (!sl) { +- grub_dprintf ("secureboot", "shim not available, trying UEFI validation\n"); +- return grub_shim_lock_load_image_fallback(buf, size); +- } ++ if (!sl) ++ return grub_error (GRUB_ERR_ACCESS_DENIED, N_("shim_lock protocol not found")); ++ + if (sl->verify (buf, size) != GRUB_EFI_SUCCESS) + return grub_error (GRUB_ERR_BAD_SIGNATURE, N_("bad shim signature")); + +-- +2.43.0 + diff --git a/packages/grub/0047-Revert-UBUNTU-Move-verifiers-after-decompressors.patch b/packages/grub/0047-Revert-UBUNTU-Move-verifiers-after-decompressors.patch new file mode 100644 index 00000000..d657801b --- /dev/null +++ b/packages/grub/0047-Revert-UBUNTU-Move-verifiers-after-decompressors.patch @@ -0,0 +1,48 @@ +From 95cafe6cf7dd2a02bd33ddee624bb9b7c3a931ae Mon Sep 17 00:00:00 2001 +From: Ben Cressey +Date: Tue, 13 Feb 2024 22:21:41 +0000 +Subject: [PATCH] Revert "UBUNTU: Move verifiers after decompressors" + +We use the PGP verifier to validate the signature of grub.cfg, and do +not want to expose the decompressors to untrusted input. + +Signed-off-by: Ben Cressey +--- + include/grub/file.h | 4 ++-- + tests/file_filter/test.cfg | 2 +- + 2 files changed, 3 insertions(+), 3 deletions(-) + +diff --git a/include/grub/file.h b/include/grub/file.h +index fa23688..96827a4 100644 +--- a/include/grub/file.h ++++ b/include/grub/file.h +@@ -180,13 +180,13 @@ extern grub_disk_read_hook_t EXPORT_VAR(grub_file_progress_hook); + /* Filters with lower ID are executed first. */ + typedef enum grub_file_filter_id + { ++ GRUB_FILE_FILTER_VERIFY, + GRUB_FILE_FILTER_GZIO, + GRUB_FILE_FILTER_XZIO, + GRUB_FILE_FILTER_LZOPIO, ++ GRUB_FILE_FILTER_MAX, + GRUB_FILE_FILTER_COMPRESSION_FIRST = GRUB_FILE_FILTER_GZIO, + GRUB_FILE_FILTER_COMPRESSION_LAST = GRUB_FILE_FILTER_LZOPIO, +- GRUB_FILE_FILTER_VERIFY, +- GRUB_FILE_FILTER_MAX, + } grub_file_filter_id_t; + + typedef grub_file_t (*grub_file_filter_t) (grub_file_t in, enum grub_file_type type); +diff --git a/tests/file_filter/test.cfg b/tests/file_filter/test.cfg +index 17dc4a8..4308aac 100644 +--- a/tests/file_filter/test.cfg ++++ b/tests/file_filter/test.cfg +@@ -1,5 +1,5 @@ + trust /keys.pub +-set check_signatures= ++set check_signatures=enforce + cat /file.gz + cat /file.xz + cat /file.lzop +-- +2.43.0 + diff --git a/packages/grub/0048-add-flag-to-only-search-root-dev.patch b/packages/grub/0048-add-flag-to-only-search-root-dev.patch new file mode 100644 index 00000000..a92993b5 --- /dev/null +++ b/packages/grub/0048-add-flag-to-only-search-root-dev.patch @@ -0,0 +1,163 @@ +From 115f44e341b8f204bccaf63686579a66507c2ded Mon Sep 17 00:00:00 2001 +From: Marta Lewandowska +Date: Mon, 9 Oct 2023 08:53:18 +0200 +Subject: [PATCH] add flag to only search root dev + +fixes bz#2223437 + +Signed-off-by: Marta Lewandowska +--- + grub-core/commands/search.c | 36 ++++++++++++++++++++++++++++++++ + grub-core/commands/search_wrap.c | 5 +++++ + grub-core/kern/misc.c | 30 ++++++++++++++++++++++++++ + include/grub/misc.h | 1 + + include/grub/search.h | 3 ++- + 5 files changed, 74 insertions(+), 1 deletion(-) + +diff --git a/grub-core/commands/search.c b/grub-core/commands/search.c +index ec03c75..e0a3b22 100644 +--- a/grub-core/commands/search.c ++++ b/grub-core/commands/search.c +@@ -89,6 +89,42 @@ iterate_device (const char *name, void *data) + grub_device_close (dev); + } + ++ /* Skip it if it's not the root device when requested. */ ++ if (ctx->flags & SEARCH_FLAGS_ROOTDEV_ONLY) ++ { ++ const char *root_dev; ++ root_dev = grub_env_get ("root"); ++ if (root_dev != NULL && *root_dev != '\0') ++ { ++ char *root_disk = grub_malloc (grub_strlen(root_dev) + 1); ++ char *name_disk = grub_malloc (grub_strlen(name) + 1); ++ char *rem_1 = grub_malloc(grub_strlen(root_dev) + 1); ++ char *rem_2 = grub_malloc(grub_strlen(name) + 1); ++ ++ if (root_disk != NULL && name_disk != NULL && ++ rem_1 != NULL && rem_2 != NULL) ++ { ++ /* get just the disk name; partitions will be different. */ ++ grub_str_sep (root_dev, root_disk, ',', rem_1); ++ grub_str_sep (name, name_disk, ',', rem_2); ++ if (root_disk != NULL && *root_disk != '\0' && ++ name_disk != NULL && *name_disk != '\0') ++ if (grub_strcmp(root_disk, name_disk) != 0) ++ { ++ grub_free (root_disk); ++ grub_free (name_disk); ++ grub_free (rem_1); ++ grub_free (rem_2); ++ return 0; ++ } ++ } ++ grub_free (root_disk); ++ grub_free (name_disk); ++ grub_free (rem_1); ++ grub_free (rem_2); ++ } ++ } ++ + #if defined(DO_SEARCH_FS_UUID) || defined(DO_SEARCH_DISK_UUID) + #define compare_fn grub_strcasecmp + #else +diff --git a/grub-core/commands/search_wrap.c b/grub-core/commands/search_wrap.c +index c8152b1..fd77b1c 100644 +--- a/grub-core/commands/search_wrap.c ++++ b/grub-core/commands/search_wrap.c +@@ -47,6 +47,7 @@ static const struct grub_arg_option options[] = + ARG_TYPE_STRING}, + {"no-floppy", 'n', 0, N_("Do not probe any floppy drive."), 0, 0}, + {"efidisk-only", 0, 0, N_("Only probe EFI disks."), 0, 0}, ++ {"root-dev-only", 'r', 0, N_("Only probe root device."), 0, 0}, + {"hint", 'h', GRUB_ARG_OPTION_REPEATABLE, + N_("First try the device HINT. If HINT ends in comma, " + "also try subpartitions"), N_("HINT"), ARG_TYPE_STRING}, +@@ -84,6 +85,7 @@ enum options + SEARCH_SET, + SEARCH_NO_FLOPPY, + SEARCH_EFIDISK_ONLY, ++ SEARCH_ROOTDEV_ONLY, + SEARCH_HINT, + SEARCH_HINT_IEEE1275, + SEARCH_HINT_BIOS, +@@ -198,6 +200,9 @@ grub_cmd_search (grub_extcmd_context_t ctxt, int argc, char **args) + if (state[SEARCH_EFIDISK_ONLY].set) + flags |= SEARCH_FLAGS_EFIDISK_ONLY; + ++ if (state[SEARCH_ROOTDEV_ONLY].set) ++ flags |= SEARCH_FLAGS_ROOTDEV_ONLY; ++ + if (state[SEARCH_LABEL].set) + grub_search_label (id, var, flags, hints, nhints); + else if (state[SEARCH_FS_UUID].set) +diff --git a/grub-core/kern/misc.c b/grub-core/kern/misc.c +index 5d2b246..a95d182 100644 +--- a/grub-core/kern/misc.c ++++ b/grub-core/kern/misc.c +@@ -598,6 +598,36 @@ grub_reverse (char *str) + } + } + ++/* Separate string into two parts, broken up by delimiter delim. */ ++void ++grub_str_sep (const char *s, char *p, char delim, char *r) ++{ ++ char* t = grub_strndup(s, grub_strlen(s)); ++ ++ if (t != NULL && *t != '\0') ++ { ++ char* tmp = t; ++ ++ while (((*p = *t) != '\0') && ((*p = *t) != delim)) ++ { ++ p++; ++ t++; ++ } ++ *p = '\0'; ++ ++ if (*t != '\0') ++ { ++ t++; ++ while ((*r++ = *t++) != '\0') ++ ; ++ *r = '\0'; ++ } ++ grub_free (tmp); ++ } ++ else ++ grub_free (t); ++} ++ + /* Divide N by D, return the quotient, and store the remainder in *R. */ + grub_uint64_t + grub_divmod64 (grub_uint64_t n, grub_uint64_t d, grub_uint64_t *r) +diff --git a/include/grub/misc.h b/include/grub/misc.h +index 0a26855..a359b0d 100644 +--- a/include/grub/misc.h ++++ b/include/grub/misc.h +@@ -314,6 +314,7 @@ void *EXPORT_FUNC(grub_memset) (void *s, int c, grub_size_t n); + grub_size_t EXPORT_FUNC(grub_strlen) (const char *s) WARN_UNUSED_RESULT; + int EXPORT_FUNC(grub_printf) (const char *fmt, ...) __attribute__ ((format (GNU_PRINTF, 1, 2))); + int EXPORT_FUNC(grub_printf_) (const char *fmt, ...) __attribute__ ((format (GNU_PRINTF, 1, 2))); ++void EXPORT_FUNC(grub_str_sep) (const char *s, char *p, char delim, char *r); + + /* Replace all `ch' characters of `input' with `with' and copy the + result into `output'; return EOS address of `output'. */ +diff --git a/include/grub/search.h b/include/grub/search.h +index a5f56b2..8727409 100644 +--- a/include/grub/search.h ++++ b/include/grub/search.h +@@ -22,7 +22,8 @@ + enum search_flags + { + SEARCH_FLAGS_NO_FLOPPY = 1, +- SEARCH_FLAGS_EFIDISK_ONLY = 2 ++ SEARCH_FLAGS_EFIDISK_ONLY = 2, ++ SEARCH_FLAGS_ROOTDEV_ONLY = 4 + }; + + void grub_search_fs_file (const char *key, const char *var, +-- +2.43.0 + diff --git a/packages/grub/0049-efi-Add-grub_efi_set_variable_with_attributes.patch b/packages/grub/0049-efi-Add-grub_efi_set_variable_with_attributes.patch new file mode 100644 index 00000000..acf3bd56 --- /dev/null +++ b/packages/grub/0049-efi-Add-grub_efi_set_variable_with_attributes.patch @@ -0,0 +1,88 @@ +From 37cd5dfd522882e1d95c4205635f9b2763256707 Mon Sep 17 00:00:00 2001 +From: Oliver Steffen +Date: Fri, 26 May 2023 13:35:42 +0200 +Subject: [PATCH] efi: Add grub_efi_set_variable_with_attributes() + +Add a function to the EFI module that allows setting EFI variables +with specific attributes. + +This is useful for marking variables as volatile, for example. + +Signed-off-by: Oliver Steffen +Reviewed-by: Daniel Kiper +[bcressey: + - backport to 2.06 + - avoid changes from bb4aa6e0 ("efi: Drop all uses of efi_call_XX() wrappers")] +Signed-off-by: Ben Cressey + +(cherry picked from commit 7e4da6fb2d03ea20f7e11efc496e2e6cf360048b) +--- + grub-core/kern/efi/efi.c | 20 +++++++++++++------- + include/grub/efi/efi.h | 6 ++++++ + 2 files changed, 19 insertions(+), 7 deletions(-) + +diff --git a/grub-core/kern/efi/efi.c b/grub-core/kern/efi/efi.c +index 3a4475c5c..ab9a53966 100644 +--- a/grub-core/kern/efi/efi.c ++++ b/grub-core/kern/efi/efi.c +@@ -211,8 +211,8 @@ grub_efi_set_virtual_address_map (grub_efi_uintn_t memory_map_size, + } + + grub_err_t +-grub_efi_set_variable(const char *var, const grub_efi_guid_t *guid, +- void *data, grub_size_t datasize) ++grub_efi_set_variable_with_attributes (const char *var, const grub_efi_guid_t *guid, ++ void *data, grub_size_t datasize, grub_efi_uint32_t attributes) + { + grub_efi_status_t status; + grub_efi_runtime_services_t *r; +@@ -229,11 +229,7 @@ grub_efi_set_variable(const char *var, const grub_efi_guid_t *guid, + + r = grub_efi_system_table->runtime_services; + +- status = efi_call_5 (r->set_variable, var16, guid, +- (GRUB_EFI_VARIABLE_NON_VOLATILE +- | GRUB_EFI_VARIABLE_BOOTSERVICE_ACCESS +- | GRUB_EFI_VARIABLE_RUNTIME_ACCESS), +- datasize, data); ++ status = efi_call_5 (r->set_variable, var16, guid, attributes, datasize, data); + grub_free (var16); + if (status == GRUB_EFI_SUCCESS) + return GRUB_ERR_NONE; +@@ -244,6 +240,16 @@ grub_efi_set_variable(const char *var, const grub_efi_guid_t *guid, + return grub_error (GRUB_ERR_IO, "could not set EFI variable `%s'", var); + } + ++grub_err_t ++grub_efi_set_variable (const char *var, const grub_efi_guid_t *guid, ++ void *data, grub_size_t datasize) ++{ ++ return grub_efi_set_variable_with_attributes (var, guid, data, datasize, ++ GRUB_EFI_VARIABLE_NON_VOLATILE ++ | GRUB_EFI_VARIABLE_BOOTSERVICE_ACCESS ++ | GRUB_EFI_VARIABLE_RUNTIME_ACCESS); ++} ++ + grub_efi_status_t + grub_efi_get_variable_with_attributes (const char *var, + const grub_efi_guid_t *guid, +diff --git a/include/grub/efi/efi.h b/include/grub/efi/efi.h +index d580b6bd9..a08f9474d 100644 +--- a/include/grub/efi/efi.h ++++ b/include/grub/efi/efi.h +@@ -128,6 +128,12 @@ grub_efi_status_t EXPORT_FUNC (grub_efi_get_variable) (const char *variable, + grub_size_t *datasize_out, + void **data_out); + grub_err_t ++EXPORT_FUNC (grub_efi_set_variable_with_attributes) (const char *var, ++ const grub_efi_guid_t *guid, ++ void *data, ++ grub_size_t datasize, ++ grub_efi_uint32_t attributes); ++grub_err_t + EXPORT_FUNC (grub_efi_set_variable) (const char *var, + const grub_efi_guid_t *guid, + void *data, +-- +2.47.0 + diff --git a/packages/grub/0050-include-grub-types.h-Add-GRUB_SSIZE_MAX.patch b/packages/grub/0050-include-grub-types.h-Add-GRUB_SSIZE_MAX.patch new file mode 100644 index 00000000..5ec27352 --- /dev/null +++ b/packages/grub/0050-include-grub-types.h-Add-GRUB_SSIZE_MAX.patch @@ -0,0 +1,40 @@ +From abacbb46f1a73e33a6b7644a8a8081244c43c28f Mon Sep 17 00:00:00 2001 +From: Oliver Steffen +Date: Fri, 26 May 2023 13:35:46 +0200 +Subject: [PATCH] include/grub/types.h: Add GRUB_SSIZE_MAX + +In the same way as GRUB_SIZE_MAX, add GRUB_SSIZE_MAX. + +Signed-off-by: Oliver Steffen +Reviewed-by: Daniel Kiper +[bcressey: backport to 2.06] +Signed-off-by: Ben Cressey + +(cherry picked from commit 389d3dc835a37c42184d2fab978ccd902a2399f7) +--- + include/grub/types.h | 2 ++ + 1 file changed, 2 insertions(+) + +diff --git a/include/grub/types.h b/include/grub/types.h +index ba446d990..ebf672b46 100644 +--- a/include/grub/types.h ++++ b/include/grub/types.h +@@ -122,6 +122,7 @@ typedef grub_uint64_t grub_size_t; + typedef grub_int64_t grub_ssize_t; + + # define GRUB_SIZE_MAX 18446744073709551615UL ++# define GRUB_SSIZE_MAX 9223372036854775807L + + # if GRUB_CPU_SIZEOF_LONG == 8 + # define PRIxGRUB_SIZE "lx" +@@ -140,6 +141,7 @@ typedef grub_uint32_t grub_size_t; + typedef grub_int32_t grub_ssize_t; + + # define GRUB_SIZE_MAX 4294967295UL ++# define GRUB_SSIZE_MAX 2147483647L + + # define PRIxGRUB_SIZE "x" + # define PRIxGRUB_ADDR "x" +-- +2.47.0 + diff --git a/packages/grub/0051-kern-misc-kern-efi-Extract-UTF-8-to-UTF-16-code.patch b/packages/grub/0051-kern-misc-kern-efi-Extract-UTF-8-to-UTF-16-code.patch new file mode 100644 index 00000000..156695e3 --- /dev/null +++ b/packages/grub/0051-kern-misc-kern-efi-Extract-UTF-8-to-UTF-16-code.patch @@ -0,0 +1,136 @@ +From 55011a89968539f9d54d3425dc7ab73a0812851e Mon Sep 17 00:00:00 2001 +From: Oliver Steffen +Date: Fri, 26 May 2023 13:35:47 +0200 +Subject: [PATCH] kern/misc, kern/efi: Extract UTF-8 to UTF-16 code + +Create a new function for UTF-8 to UTF-16 conversion called +grub_utf8_to_utf16_alloc() in the grub-code/kern/misc.c and replace +charset conversion code used in some places in the EFI code. It is +modeled after the grub_utf8_to_ucs4_alloc() like functions in +include/grub/charset.h. It can't live in include/grub/charset.h, +because it needs to be reachable from the kern/efi code. + +Add a check for integer overflow and remove redundant NUL-termination. + +Signed-off-by: Oliver Steffen +Reviewed-by: Daniel Kiper +[bcressey: backport to 2.06] +Signed-off-by: Ben Cressey + +(cherry picked from commit a0b16564ee2e8eb7f597926bf60c4de2d696cd66) +--- + grub-core/kern/efi/efi.c | 21 ++++++--------------- + grub-core/kern/misc.c | 32 ++++++++++++++++++++++++++++++++ + include/grub/misc.h | 3 +++ + 3 files changed, 41 insertions(+), 15 deletions(-) + +diff --git a/grub-core/kern/efi/efi.c b/grub-core/kern/efi/efi.c +index ab9a53966..354343935 100644 +--- a/grub-core/kern/efi/efi.c ++++ b/grub-core/kern/efi/efi.c +@@ -217,15 +217,11 @@ grub_efi_set_variable_with_attributes (const char *var, const grub_efi_guid_t *g + grub_efi_status_t status; + grub_efi_runtime_services_t *r; + grub_efi_char16_t *var16; +- grub_size_t len, len16; + +- len = grub_strlen (var); +- len16 = len * GRUB_MAX_UTF16_PER_UTF8; +- var16 = grub_calloc (len16 + 1, sizeof (var16[0])); +- if (!var16) ++ grub_utf8_to_utf16_alloc (var, &var16, NULL); ++ ++ if (var16 == NULL) + return grub_errno; +- len16 = grub_utf8_to_utf16 (var16, len16, (grub_uint8_t *) var, len, NULL); +- var16[len16] = 0; + + r = grub_efi_system_table->runtime_services; + +@@ -262,18 +258,13 @@ grub_efi_get_variable_with_attributes (const char *var, + grub_efi_runtime_services_t *r; + grub_efi_char16_t *var16; + void *data; +- grub_size_t len, len16; + + *data_out = NULL; + *datasize_out = 0; + +- len = grub_strlen (var); +- len16 = len * GRUB_MAX_UTF16_PER_UTF8; +- var16 = grub_calloc (len16 + 1, sizeof (var16[0])); +- if (!var16) +- return GRUB_EFI_OUT_OF_RESOURCES; +- len16 = grub_utf8_to_utf16 (var16, len16, (grub_uint8_t *) var, len, NULL); +- var16[len16] = 0; ++ grub_utf8_to_utf16_alloc (var, &var16, NULL); ++ if (var16 == NULL) ++ return grub_errno; + + r = grub_efi_system_table->runtime_services; + +diff --git a/grub-core/kern/misc.c b/grub-core/kern/misc.c +index a95d182ba..f9be124d9 100644 +--- a/grub-core/kern/misc.c ++++ b/grub-core/kern/misc.c +@@ -28,6 +28,8 @@ + #if DEBUG_WITH_TIMESTAMPS + #include + #endif ++#include ++#include + + static void + parse_printf_args (const char *fmt0, struct grub_printf_args *args, +@@ -1280,6 +1282,36 @@ grub_fatal (const char *fmt, ...) + grub_abort (); + } + ++grub_ssize_t ++grub_utf8_to_utf16_alloc (const char *str8, grub_uint16_t **utf16_msg, grub_uint16_t **last_position) ++{ ++ grub_size_t len; ++ grub_size_t len16; ++ ++ len = grub_strlen (str8); ++ ++ /* Check for integer overflow */ ++ if (len > GRUB_SSIZE_MAX / GRUB_MAX_UTF16_PER_UTF8 - 1) ++ { ++ grub_error (GRUB_ERR_BAD_ARGUMENT, N_("string too long")); ++ *utf16_msg = NULL; ++ return -1; ++ } ++ ++ len16 = len * GRUB_MAX_UTF16_PER_UTF8; ++ ++ *utf16_msg = grub_calloc (len16 + 1, sizeof (*utf16_msg[0])); ++ if (*utf16_msg == NULL) ++ return -1; ++ ++ len16 = grub_utf8_to_utf16 (*utf16_msg, len16, (grub_uint8_t *) str8, len, NULL); ++ ++ if (last_position != NULL) ++ *last_position = *utf16_msg + len16; ++ ++ return len16; ++} ++ + #if BOOT_TIME_STATS + + #include +diff --git a/include/grub/misc.h b/include/grub/misc.h +index a359b0dee..8716e486d 100644 +--- a/include/grub/misc.h ++++ b/include/grub/misc.h +@@ -536,4 +536,7 @@ void EXPORT_FUNC(grub_real_boot_time) (const char *file, + + #define grub_log2ull(n) (GRUB_TYPE_BITS (grub_uint64_t) - __builtin_clzll (n) - 1) + ++grub_ssize_t ++EXPORT_FUNC(grub_utf8_to_utf16_alloc) (const char *str8, grub_uint16_t **utf16_msg, grub_uint16_t **last_position); ++ + #endif /* ! GRUB_MISC_HEADER */ +-- +2.47.0 + diff --git a/packages/grub/0052-efi-Add-grub_efi_set_variable_to_string.patch b/packages/grub/0052-efi-Add-grub_efi_set_variable_to_string.patch new file mode 100644 index 00000000..2a6d8cd1 --- /dev/null +++ b/packages/grub/0052-efi-Add-grub_efi_set_variable_to_string.patch @@ -0,0 +1,71 @@ +From 28bf9df5e7146610fd1890ea5856c0c0a86dac1c Mon Sep 17 00:00:00 2001 +From: Oliver Steffen +Date: Fri, 26 May 2023 13:35:48 +0200 +Subject: [PATCH] efi: Add grub_efi_set_variable_to_string() + +Add a function that sets an EFI variable to a string value. +The string is converted from UTF-8 to UTF-16. + +Signed-off-by: Oliver Steffen +Reviewed-by: Daniel Kiper +[bcressey: + - backport to 2.06 + - avoid changes from 06edd40d ("guid: Unify GUID types")] +Signed-off-by: Ben Cressey + +(cherry picked from commit e83a88f6ea7f97d643387681fe044f45dcd732b9) +--- + grub-core/kern/efi/efi.c | 22 ++++++++++++++++++++++ + include/grub/efi/efi.h | 3 +++ + 2 files changed, 25 insertions(+) + +diff --git a/grub-core/kern/efi/efi.c b/grub-core/kern/efi/efi.c +index 354343935..a65ef27bd 100644 +--- a/grub-core/kern/efi/efi.c ++++ b/grub-core/kern/efi/efi.c +@@ -297,6 +297,28 @@ grub_efi_get_variable_with_attributes (const char *var, + return status; + } + ++grub_err_t ++grub_efi_set_variable_to_string (const char *name, const grub_efi_guid_t *guid, ++ const char *value, grub_efi_uint32_t attributes) ++{ ++ grub_efi_char16_t *value_16; ++ grub_ssize_t len16; ++ grub_err_t status; ++ ++ len16 = grub_utf8_to_utf16_alloc (value, &value_16, NULL); ++ ++ if (len16 < 0) ++ return grub_errno; ++ ++ status = grub_efi_set_variable_with_attributes (name, guid, ++ (void *) value_16, (len16 + 1) * sizeof (value_16[0]), ++ attributes); ++ ++ grub_free (value_16); ++ ++ return status; ++} ++ + grub_efi_status_t + grub_efi_get_variable (const char *var, const grub_efi_guid_t *guid, + grub_size_t *datasize_out, void **data_out) +diff --git a/include/grub/efi/efi.h b/include/grub/efi/efi.h +index a08f9474d..a82741ef2 100644 +--- a/include/grub/efi/efi.h ++++ b/include/grub/efi/efi.h +@@ -138,6 +138,9 @@ EXPORT_FUNC (grub_efi_set_variable) (const char *var, + const grub_efi_guid_t *guid, + void *data, + grub_size_t datasize); ++grub_err_t ++EXPORT_FUNC (grub_efi_set_variable_to_string) (const char *name, const grub_efi_guid_t *guid, ++ const char *value, grub_efi_uint32_t attributes); + int + EXPORT_FUNC (grub_efi_compare_device_paths) (const grub_efi_device_path_t *dp1, + const grub_efi_device_path_t *dp2); +-- +2.47.0 + diff --git a/packages/grub/0053-efi-add-vendor-GUID-for-Boot-Loader-Interface.patch b/packages/grub/0053-efi-add-vendor-GUID-for-Boot-Loader-Interface.patch new file mode 100644 index 00000000..9b4f6ef2 --- /dev/null +++ b/packages/grub/0053-efi-add-vendor-GUID-for-Boot-Loader-Interface.patch @@ -0,0 +1,32 @@ +From ec2bbc9d87079cd080feaad6b7512624a52ee555 Mon Sep 17 00:00:00 2001 +From: Ben Cressey +Date: Thu, 14 Nov 2024 19:24:42 +0000 +Subject: [PATCH] efi: add vendor GUID for Boot Loader Interface + +Backports the relevant part of upstream commit e0fa7dc8 ("bli: Add a +module for the Boot Loader Interface"). + +Signed-off-by: Ben Cressey +--- + include/grub/efi/api.h | 5 +++++ + 1 file changed, 5 insertions(+) + +diff --git a/include/grub/efi/api.h b/include/grub/efi/api.h +index 464842ba3..f301913e6 100644 +--- a/include/grub/efi/api.h ++++ b/include/grub/efi/api.h +@@ -368,6 +368,11 @@ + { 0xa1, 0x92, 0xbf, 0x1d, 0x57, 0xd0, 0xb1, 0x89 } \ + } + ++#define GRUB_EFI_VENDOR_BOOT_LOADER_INTERFACE_GUID \ ++ { 0x4a67b082, 0x0a4c, 0x41cf, \ ++ { 0xb6, 0xc7, 0x44, 0x0b, 0x29, 0xbb, 0x8c, 0x4f } \ ++ } ++ + struct grub_efi_sal_system_table + { + grub_uint32_t signature; +-- +2.47.0 + diff --git a/packages/grub/0054-efi-set-LoaderTimeInitUSec-and-LoaderTimeExecUSec.patch b/packages/grub/0054-efi-set-LoaderTimeInitUSec-and-LoaderTimeExecUSec.patch new file mode 100644 index 00000000..0ab6826c --- /dev/null +++ b/packages/grub/0054-efi-set-LoaderTimeInitUSec-and-LoaderTimeExecUSec.patch @@ -0,0 +1,129 @@ +From a76d5d1d5f425eb6128cadee06d9aaeff1b24b83 Mon Sep 17 00:00:00 2001 +From: Ben Cressey +Date: Thu, 14 Nov 2024 20:29:13 +0000 +Subject: [PATCH] efi: set LoaderTimeInitUSec and LoaderTimeExecUSec + +This implements the part of the Boot Loader Interface [0] that's used +by `systemd-analyze` to calculate the time spent in the firmware and +bootloader, prior to kernel execution. + +[0] https://systemd.io/BOOT_LOADER_INTERFACE/ + +Signed-off-by: Ben Cressey +--- + grub-core/kern/arm64/efi/init.c | 23 +++++++++++++++++++++++ + grub-core/kern/i386/efi/init.c | 26 ++++++++++++++++++++++++++ + 2 files changed, 49 insertions(+) + +diff --git a/grub-core/kern/arm64/efi/init.c b/grub-core/kern/arm64/efi/init.c +index 5010caefd..52e87d582 100644 +--- a/grub-core/kern/arm64/efi/init.c ++++ b/grub-core/kern/arm64/efi/init.c +@@ -22,6 +22,7 @@ + #include + #include + #include ++#include + #include + #include + +@@ -36,11 +37,16 @@ grub_efi_get_time_ms (void) + return tmr / timer_frequency_in_khz; + } + ++static const grub_efi_guid_t bli_vendor_guid = GRUB_EFI_VENDOR_BOOT_LOADER_INTERFACE_GUID; ++static const grub_efi_uint32_t bli_efivar_attr = ++ GRUB_EFI_VARIABLE_BOOTSERVICE_ACCESS | GRUB_EFI_VARIABLE_RUNTIME_ACCESS; + + void + grub_machine_init (void) + { + grub_uint64_t timer_frequency; ++ grub_efi_uint64_t init_ms; ++ char *init_usec; + + grub_efi_init (); + +@@ -48,11 +54,28 @@ grub_machine_init (void) + timer_frequency_in_khz = timer_frequency / 1000; + + grub_install_get_time_ms (grub_efi_get_time_ms); ++ ++ init_ms = grub_get_time_ms (); ++ init_usec = grub_xasprintf ("%lu000", init_ms); ++ grub_efi_set_variable_to_string ("LoaderTimeInitUSec", ++ &bli_vendor_guid, ++ init_usec, ++ bli_efivar_attr); + } + + void + grub_machine_fini (int flags) + { ++ grub_efi_uint64_t exec_ms; ++ char *exec_usec; ++ ++ exec_ms = grub_get_time_ms (); ++ exec_usec = grub_xasprintf ("%lu000", exec_ms); ++ grub_efi_set_variable_to_string ("LoaderTimeExecUSec", ++ &bli_vendor_guid, ++ exec_usec, ++ bli_efivar_attr); ++ + if (!(flags & GRUB_LOADER_FLAG_NORETURN)) + return; + +diff --git a/grub-core/kern/i386/efi/init.c b/grub-core/kern/i386/efi/init.c +index 46476e27e..1e237cfcb 100644 +--- a/grub-core/kern/i386/efi/init.c ++++ b/grub-core/kern/i386/efi/init.c +@@ -24,20 +24,46 @@ + #include + #include + #include ++#include + #include + #include + #include ++#include ++ ++static const grub_efi_guid_t bli_vendor_guid = GRUB_EFI_VENDOR_BOOT_LOADER_INTERFACE_GUID; ++static const grub_efi_uint32_t bli_efivar_attr = ++ GRUB_EFI_VARIABLE_BOOTSERVICE_ACCESS | GRUB_EFI_VARIABLE_RUNTIME_ACCESS; + + void + grub_machine_init (void) + { ++ grub_efi_uint64_t init_ms; ++ char *init_usec; ++ + grub_efi_init (); + grub_tsc_init (); ++ ++ init_ms = grub_get_time_ms (); ++ init_usec = grub_xasprintf ("%lu000", init_ms); ++ grub_efi_set_variable_to_string ("LoaderTimeInitUSec", ++ &bli_vendor_guid, ++ init_usec, ++ bli_efivar_attr); + } + + void + grub_machine_fini (int flags) + { ++ grub_efi_uint64_t exec_ms; ++ char *exec_usec; ++ ++ exec_ms = grub_get_time_ms (); ++ exec_usec = grub_xasprintf ("%lu000", exec_ms); ++ grub_efi_set_variable_to_string ("LoaderTimeExecUSec", ++ &bli_vendor_guid, ++ exec_usec, ++ bli_efivar_attr); ++ + if (!(flags & GRUB_LOADER_FLAG_NORETURN)) + return; + +-- +2.47.0 + diff --git a/packages/grub/0055-tsc-drop-tsc_boot_time-offset.patch b/packages/grub/0055-tsc-drop-tsc_boot_time-offset.patch new file mode 100644 index 00000000..a527bcc0 --- /dev/null +++ b/packages/grub/0055-tsc-drop-tsc_boot_time-offset.patch @@ -0,0 +1,66 @@ +From 1a31957af68baeba1065a250382e4744709b80a6 Mon Sep 17 00:00:00 2001 +From: Ben Cressey +Date: Thu, 14 Nov 2024 19:55:38 +0000 +Subject: [PATCH] tsc: drop tsc_boot_time offset + +To implement the Boot Loader Interface, we need to store the time at +which GRUB was started in the `LoaderTimeInitUSec` variable. + +On the i386 architecture, GRUB stores the TSC value at the time that +TSC calibration took place, and subtracts it before returning a value +from grub_tsc_get_time_ms(), which is called by grub_get_time_ms() - +the architecture-independent function for retrieving timestamps. + +Storing the TSC value at the time of initialization, and subtracting +it from subsequent calculations, prevents callers from determining +the system time elapsed before GRUB was loaded. + +The equivalent offset is not done for arm64, and does not appear to +serve a purpose. Callers of grub_get_time_ms() all follow a pattern +where they first record a "start" time and then compute a delta in a +loop, which works the same way whether the "start" time is close to +zero or not. + +Rather than exposing another function to provide the "raw" timestamp +without the offset, just drop `tsc_boot_time` from the calculation. + +Signed-off-by: Ben Cressey +--- + grub-core/kern/i386/tsc.c | 7 +------ + 1 file changed, 1 insertion(+), 6 deletions(-) + +diff --git a/grub-core/kern/i386/tsc.c b/grub-core/kern/i386/tsc.c +index 9293b161d..ec6899812 100644 +--- a/grub-core/kern/i386/tsc.c ++++ b/grub-core/kern/i386/tsc.c +@@ -25,9 +25,6 @@ + #include + #include + +-/* This defines the value TSC had at the epoch (that is, when we calibrated it). */ +-static grub_uint64_t tsc_boot_time; +- + /* Calibrated TSC rate. (In ms per 2^32 ticks) */ + /* We assume that the tick is less than 1 ms and hence this value fits + in 32-bit. */ +@@ -36,7 +33,7 @@ grub_uint32_t grub_tsc_rate; + static grub_uint64_t + grub_tsc_get_time_ms (void) + { +- grub_uint64_t a = grub_get_tsc () - tsc_boot_time; ++ grub_uint64_t a = grub_get_tsc (); + grub_uint64_t ah = a >> 32; + grub_uint64_t al = a & 0xffffffff; + +@@ -63,8 +60,6 @@ grub_tsc_init (void) + return; + } + +- tsc_boot_time = grub_get_tsc (); +- + #if defined (GRUB_MACHINE_XEN) || defined (GRUB_MACHINE_XEN_PVH) + (void) (grub_tsc_calibrate_from_xen () || calibrate_tsc_hardcode()); + #elif defined (GRUB_MACHINE_EFI) +-- +2.47.0 + diff --git a/packages/grub/Cargo.toml b/packages/grub/Cargo.toml new file mode 100644 index 00000000..a4134087 --- /dev/null +++ b/packages/grub/Cargo.toml @@ -0,0 +1,14 @@ +[package] +name = "grub" +version = "0.1.0" +edition = "2021" +publish = false +build = "../build.rs" + +[lib] +path = "../packages.rs" + +[[package.metadata.build-package.external-files]] +url = "https://cdn.amazonlinux.com/al2023/blobstore/f4fa28cb4e1586d622925449b1e24748c6ab09ccebe0fd8ddfa20cf5e7ce182a/grub2-2.06-61.amzn2023.0.9.src.rpm" +sha512 = "57886df0580f166bd741126f19109a0e464bc2408aafca38e68def077a2ab1f64c239d85015c44162b88d787da7ec55a623f4e7d2601942391f0996038393f99" +force-upstream = true diff --git a/packages/grub/bios.cfg b/packages/grub/bios.cfg new file mode 100644 index 00000000..f3b46aa5 --- /dev/null +++ b/packages/grub/bios.cfg @@ -0,0 +1,13 @@ +set no_modules=y +serial +terminal_output serial console +gptprio.next -d boot_dev -u boot_uuid +set root=$boot_dev +set prefix=($root)/grub +export boot_uuid +search --no-floppy --root-dev-only --set private --part-label BOTTLEROCKET-PRIVATE +configfile /grub/grub.cfg +echo "boot failed (device ($boot_dev), uuid $boot_uuid)" +echo "rebooting in 30 seconds..." +sleep 30 +reboot diff --git a/packages/grub/efi.cfg b/packages/grub/efi.cfg new file mode 100644 index 00000000..fa2e5574 --- /dev/null +++ b/packages/grub/efi.cfg @@ -0,0 +1,12 @@ +set no_modules=y +terminal_output console +gptprio.next -d boot_dev -u boot_uuid +set root=$boot_dev +set prefix=($root)/grub +export boot_uuid +search --no-floppy --root-dev-only --set private --part-label BOTTLEROCKET-PRIVATE +configfile /grub/grub.cfg +echo "boot failed (device ($boot_dev), uuid $boot_uuid)" +echo "rebooting in 30 seconds..." +sleep 30 +reboot diff --git a/packages/grub/grub.spec b/packages/grub/grub.spec new file mode 100644 index 00000000..c5b41a3c --- /dev/null +++ b/packages/grub/grub.spec @@ -0,0 +1,287 @@ +%global debug_package %{nil} +%global __strip %{_bindir}/true + +%global efidir /boot/efi/EFI/BOOT +%global efi_image grub%{_cross_efi_arch}.efi +%global biosdir /boot/grub + +# This is specific to the upstream source RPM, and will likely need to be +# updated for each new version. +%global gnulib_version gnulib-9f48fb992a3d7e96610c4ce8be969cff2d61a01b + +Name: %{_cross_os}grub +Version: 2.06 +Release: 1%{?dist} +Epoch: 1 +Summary: Bootloader with support for Linux and more +License: GPL-3.0-or-later AND Unicode-DFS-2015 +URL: https://www.gnu.org/software/grub/ +Source0: https://cdn.amazonlinux.com/al2023/blobstore/f4fa28cb4e1586d622925449b1e24748c6ab09ccebe0fd8ddfa20cf5e7ce182a/grub2-2.06-61.amzn2023.0.9.src.rpm +Source1: bios.cfg +Source2: efi.cfg +Source3: sbat.csv.in +Patch0001: 0001-setup-Add-root-device-argument-to-grub-setup.patch +Patch0002: 0002-gpt-start-new-GPT-module.patch +Patch0003: 0003-gpt-rename-misnamed-header-location-fields.patch +Patch0004: 0004-gpt-record-size-of-of-the-entries-table.patch +Patch0005: 0005-gpt-consolidate-crc32-computation-code.patch +Patch0006: 0006-gpt-add-new-repair-function-to-sync-up-primary-and-b.patch +Patch0007: 0007-gpt-add-write-function-and-gptrepair-command.patch +Patch0008: 0008-gpt-add-a-new-generic-GUID-type.patch +Patch0009: 0009-gpt-new-gptprio.next-command-for-selecting-priority-.patch +Patch0010: 0010-gpt-split-out-checksum-recomputation.patch +Patch0011: 0011-gpt-move-gpt-guid-printing-function-to-common-librar.patch +Patch0012: 0012-gpt-switch-partition-names-to-a-16-bit-type.patch +Patch0013: 0013-tests-add-some-partitions-to-the-gpt-unit-test-data.patch +Patch0014: 0014-gpt-add-search-by-partition-label-and-uuid-commands.patch +Patch0015: 0015-gpt-clean-up-little-endian-crc32-computation.patch +Patch0016: 0016-gpt-minor-cleanup.patch +Patch0017: 0017-gpt-add-search-by-disk-uuid-command.patch +Patch0018: 0018-gpt-do-not-use-disk-sizes-GRUB-will-reject-as-invali.patch +Patch0019: 0019-gpt-add-verbose-debug-logging.patch +Patch0020: 0020-gpt-improve-validation-of-GPT-headers.patch +Patch0021: 0021-gpt-refuse-to-write-to-sector-0.patch +Patch0022: 0022-gpt-properly-detect-and-repair-invalid-tables.patch +Patch0023: 0023-gptrepair_test-fix-typo-in-cleanup-trap.patch +Patch0024: 0024-gptprio_test-check-GPT-is-repaired-when-appropriate.patch +Patch0025: 0025-gpt-fix-partition-table-indexing-and-validation.patch +Patch0026: 0026-gpt-prefer-disk-size-from-header-over-firmware.patch +Patch0027: 0027-gpt-add-helper-for-picking-a-valid-header.patch +Patch0028: 0028-gptrepair-fix-status-checking.patch +Patch0029: 0029-gpt-use-inline-functions-for-checking-status-bits.patch +Patch0030: 0030-gpt-allow-repair-function-to-noop.patch +Patch0031: 0031-gpt-do-not-use-an-enum-for-status-bit-values.patch +Patch0032: 0032-gpt-check-header-and-entries-status-bits-together.patch +Patch0033: 0033-gpt-be-more-careful-about-relocating-backup-header.patch +Patch0034: 0034-gpt-selectively-update-fields-during-repair.patch +Patch0035: 0035-gpt-always-revalidate-when-recomputing-checksums.patch +Patch0036: 0036-gpt-include-backup-in-sync-check-in-revalidation.patch +Patch0037: 0037-gpt-read-entries-table-at-the-same-time-as-the-heade.patch +Patch0038: 0038-gpt-report-all-revalidation-errors.patch +Patch0039: 0039-gpt-rename-and-update-documentation-for-grub_gpt_upd.patch +Patch0040: 0040-gpt-write-backup-GPT-first-skip-if-inaccessible.patch +Patch0041: 0041-gptprio-Use-Bottlerocket-boot-partition-type-GUID.patch +Patch0042: 0042-util-mkimage-Bump-EFI-PE-header-size-to-accommodate-.patch +Patch0043: 0043-util-mkimage-avoid-adding-section-table-entry-outsid.patch +Patch0044: 0044-efi-return-virtual-size-of-section-found-by-grub_efi.patch +Patch0045: 0045-mkimage-pgp-move-single-public-key-into-its-own-sect.patch +Patch0046: 0046-Revert-sb-Add-fallback-to-EFI-LoadImage-if-shim_lock.patch +Patch0047: 0047-Revert-UBUNTU-Move-verifiers-after-decompressors.patch +Patch0048: 0048-add-flag-to-only-search-root-dev.patch +Patch0049: 0049-efi-Add-grub_efi_set_variable_with_attributes.patch +Patch0050: 0050-include-grub-types.h-Add-GRUB_SSIZE_MAX.patch +Patch0051: 0051-kern-misc-kern-efi-Extract-UTF-8-to-UTF-16-code.patch +Patch0052: 0052-efi-Add-grub_efi_set_variable_to_string.patch +Patch0053: 0053-efi-add-vendor-GUID-for-Boot-Loader-Interface.patch +Patch0054: 0054-efi-set-LoaderTimeInitUSec-and-LoaderTimeExecUSec.patch +Patch0055: 0055-tsc-drop-tsc_boot_time-offset.patch + +BuildRequires: automake +BuildRequires: bison +BuildRequires: flex +BuildRequires: gettext-devel + +%description +%{summary}. + +%package modules +Summary: Modules for the bootloader with support for Linux and more + +%description modules +%{summary}. + +%package tools +Summary: Tools for the bootloader with support for Linux and more + +%description tools +%{summary}. + +%prep +rpm2cpio %{S:0} | cpio -iu grub-%{version}.tar.xz \ + bootstrap bootstrap.conf \ + gitignore %{gnulib_version}.tar.gz \ + "*.patch" + +# Mimic prep from upstream spec to prepare for patching. +tar -xof grub-%{version}.tar.xz; rm grub-%{version}.tar.xz +%setup -TDn grub-%{version} +mv ../bootstrap{,.conf} . +mv ../gitignore .gitignore +tar -xof ../%{gnulib_version}.tar.gz; rm ../%{gnulib_version}.tar.gz +mv %{gnulib_version} gnulib +cp unicode/COPYING COPYING.unicode +rm -f configure + +# Apply upstream and local patches. +git init +git config user.email 'user@localhost' +git config user.name 'user' +git add . +git commit -a -q -m "base" +git am --whitespace=nowarn ../*.patch %{patches} + +# Let bootstrap start from a clean slate and freshly copy in the relevant +# parts from gnulib. In particular remove the configure macros that aren't +# compatible with the copied in version of gnulib. +rm -r build-aux m4 + +./bootstrap + +%global grub_cflags -pipe -fno-stack-protector -fno-strict-aliasing +%global grub_ldflags -static +%global _configure ../configure + +%build +export \ + TARGET_CPP="%{_cross_target}-gcc -E" \ + TARGET_CC="%{_cross_target}-gcc" \ + TARGET_CFLAGS="%{grub_cflags}" \ + TARGET_CPPFLAGS="%{grub_cflags}" \ + TARGET_LDFLAGS="%{grub_ldflags}" \ + TARGET_NM="%{_cross_target}-nm" \ + TARGET_OBJCOPY="%{_cross_target}-objcopy" \ + TARGET_STRIP="%{_cross_target}-strip" \ + PYTHON="python3" \ + +%if "%{_cross_arch}" == "x86_64" +mkdir bios-build +pushd bios-build + +%cross_configure \ + CFLAGS="" \ + LDFLAGS="" \ + --host="%{_build}" \ + --target="i386" \ + --with-platform="pc" \ + --with-utils=host \ + --disable-grub-mkfont \ + --disable-rpm-sort \ + --disable-werror \ + --enable-efiemu=no \ + --enable-device-mapper=no \ + --enable-libzfs=no \ + +%make_build +popd +%endif + +mkdir efi-build +pushd efi-build + +sed -e "s,__VERSION__,%{version},g" %{S:3} > sbat.csv + +%cross_configure \ + CFLAGS="" \ + LDFLAGS="" \ + --host="%{_build}" \ + --target="%{_cross_arch}" \ + --with-platform="efi" \ + --with-utils=host \ + --disable-grub-mkfont \ + --disable-rpm-sort \ + --disable-werror \ + --enable-efiemu=no \ + --enable-device-mapper=no \ + --enable-libzfs=no \ + +%make_build +popd + +%install +MODS=(configfile echo ext2 gptprio linux normal part_gpt reboot sleep zstd search) + +# These modules are needed for signature verification, which is currently only +# done for the EFI build of GRUB. +VERIFY_MODS=(pgp crypto gcry_sha256 gcry_sha512 gcry_dsa gcry_rsa) + +%if "%{_cross_arch}" == "x86_64" +pushd bios-build +%make_install +mkdir -p %{buildroot}%{biosdir} +%{buildroot}%{_cross_bindir}/grub-mkimage \ + -c %{S:1} \ + -d ./grub-core/ \ + -O "i386-pc" \ + -o "%{buildroot}%{biosdir}/core.img" \ + -p "(hd0,gpt2)/boot/grub" \ + biosdisk serial ${MODS[@]} +install -m 0644 ./grub-core/boot.img \ + %{buildroot}%{biosdir}/boot.img +popd +%endif + +pushd efi-build +%make_install +mkdir -p %{buildroot}%{efidir} + +# Make sure the `.pubkey` section is large enough to cover a replacement +# certificate, or `objcopy` may silently retain the existing section. +truncate -s 4096 empty.pubkey + +%{buildroot}%{_cross_bindir}/grub-mkimage \ + -c %{S:2} \ + -d ./grub-core/ \ + -O "%{_cross_grub_efi_format}" \ + -o "%{buildroot}%{efidir}/%{efi_image}" \ + -p "/EFI/BOOT" \ + --pubkey empty.pubkey \ + --sbat sbat.csv \ + efi_gop ${MODS[@]} ${VERIFY_MODS[@]} +popd + +%files +%license COPYING COPYING.unicode +%{_cross_attribution_file} +%if "%{_cross_arch}" == "x86_64" +%dir %{biosdir} +%{biosdir}/boot.img +%{biosdir}/core.img +%endif +%dir %{efidir} +%{efidir}/%{efi_image} +%{_cross_sbindir}/grub-bios-setup +%exclude %{_cross_bashdir} +%exclude %{_cross_infodir} +%exclude %{_cross_libexecdir} +%exclude %{_cross_localedir} +%exclude %{_cross_sysconfdir} +%exclude %{_cross_unitdir} + +%files modules +%dir %{_cross_libdir}/grub +%{_cross_libdir}/grub/* + +%files tools +%{_cross_bindir}/grub-editenv +%{_cross_bindir}/grub-file +%{_cross_bindir}/grub-fstest +%{_cross_bindir}/grub-glue-efi +%{_cross_bindir}/grub-kbdcomp +%{_cross_bindir}/grub-menulst2cfg +%{_cross_bindir}/grub-mkimage +%{_cross_bindir}/grub-mklayout +%{_cross_bindir}/grub-mknetdir +%{_cross_bindir}/grub-mkpasswd-pbkdf2 +%{_cross_bindir}/grub-mkrelpath +%{_cross_bindir}/grub-mkrescue +%{_cross_bindir}/grub-mkstandalone +%{_cross_bindir}/grub-render-label +%{_cross_bindir}/grub-script-check +%{_cross_bindir}/grub-syslinux2cfg +%{_cross_sbindir}/grub-get-kernel-settings +%{_cross_sbindir}/grub-install +%{_cross_sbindir}/grub-macbless +%{_cross_sbindir}/grub-mkconfig +%{_cross_sbindir}/grub-ofpathname +%{_cross_sbindir}/grub-probe +%{_cross_sbindir}/grub-reboot +%{_cross_sbindir}/grub-set-bootflag +%{_cross_sbindir}/grub-set-default +%{_cross_sbindir}/grub-set-password +%{_cross_sbindir}/grub-sparc64-setup +%{_cross_sbindir}/grub-switch-to-blscfg + +%dir %{_cross_datadir}/grub +%{_cross_datadir}/grub/grub-mkconfig_lib + +%changelog diff --git a/packages/grub/latest-srpm-url.sh b/packages/grub/latest-srpm-url.sh new file mode 100755 index 00000000..2c5e313e --- /dev/null +++ b/packages/grub/latest-srpm-url.sh @@ -0,0 +1,6 @@ +#!/bin/sh +cmd='dnf install -q -y --releasever=latest yum-utils && yumdownloader -q --releasever=latest --source --urls grub2' +docker run --rm amazonlinux:2023 sh -c "${cmd}" \ + | grep '^http' \ + | xargs --max-args=1 --no-run-if-empty realpath --canonicalize-missing --relative-to=. \ + | sed 's_:/_://_' diff --git a/packages/grub/replace-grub-pubkey b/packages/grub/replace-grub-pubkey new file mode 100755 index 00000000..7d8a69b5 --- /dev/null +++ b/packages/grub/replace-grub-pubkey @@ -0,0 +1,45 @@ +#!/usr/bin/env bash + +set -e + +readonly grub_image="${1:?expecting GRUB image as first argument}" +readonly public_key="${2:?expecting GPG public key file as second argument}" +readonly local_keys="${3:?expecting directory containing local signing keys as third argument}" + + +# +# Create unsigned image with embedded key replaced +# + +rm -f "${grub_image}.unsigned" +pesign -r -u 0 -i "${grub_image}" -o "${grub_image}.unsigned" +objcopy --update-section .pubkey="${public_key}" "${grub_image}.unsigned" + + +# +# Re-sign resulting image (steps copied from rpm2img) +# + +# Generate the PKCS12 archive for import. +openssl pkcs12 \ + -export \ + -passout pass: \ + -inkey "${local_keys}/code-sign.key" \ + -in "${local_keys}/code-sign.crt" \ + -certfile "${local_keys}/CA.crt" \ + -out "${local_keys}/code-sign.p12" + +# Import certificates and private key archive. +PEDB="/etc/pki/pesign" +certutil -d "${PEDB}" -A -n CA -i "${local_keys}/CA.crt" -t "CT,C,C" +certutil -d "${PEDB}" -A -n code-sign-key -i "${local_keys}/code-sign.crt" -t ",,P" +pk12util -d "${PEDB}" -i "${local_keys}/code-sign.p12" -W "" +certutil -d "${PEDB}" -L +PESIGN_KEY="-c code-sign-key" + +openssl x509 \ + -inform PEM -in "${local_keys}/CA.crt" \ + -outform DER -out "${local_keys}/CA.der" + +pesign -i "${grub_image}.unsigned" -o "${grub_image}" -f -s ${PESIGN_KEY} +pesigcheck -i "${grub_image}" -n 0 -c "${local_keys}/CA.der" diff --git a/packages/grub/sbat.csv.in b/packages/grub/sbat.csv.in new file mode 100644 index 00000000..dabc2612 --- /dev/null +++ b/packages/grub/sbat.csv.in @@ -0,0 +1,3 @@ +sbat,1,SBAT Version,sbat,1,https://github.com/rhboot/shim/blob/main/SBAT.md +grub,4,Free Software Foundation,grub,__VERSION__,https://www.gnu.org/software/grub/ +grub.bottlerocket,1,Bottlerocket,grub,__VERSION__,https://github.com/bottlerocket-os/bottlerocket/blob/develop/SECURITY.md diff --git a/packages/kernel-5.10/.gitignore b/packages/kernel-5.10/.gitignore new file mode 100644 index 00000000..e7a9c134 --- /dev/null +++ b/packages/kernel-5.10/.gitignore @@ -0,0 +1 @@ +*.rpm diff --git a/packages/kernel-5.10/1001-Makefile-add-prepare-target-for-external-modules.patch b/packages/kernel-5.10/1001-Makefile-add-prepare-target-for-external-modules.patch new file mode 100644 index 00000000..474a7aec --- /dev/null +++ b/packages/kernel-5.10/1001-Makefile-add-prepare-target-for-external-modules.patch @@ -0,0 +1,50 @@ +From b6d859b7089dd68d3186f2a088823c322ad4852e Mon Sep 17 00:00:00 2001 +From: Ben Cressey +Date: Mon, 19 Apr 2021 18:46:04 +0000 +Subject: [PATCH] Makefile: add prepare target for external modules + +We need to ensure that native versions of programs like `objtool` are +built before trying to build out-of-tree modules, or else the build +will fail. + +Unlike other distributions, we cannot include these programs in our +kernel-devel archive, because we rely on cross-compilation: these are +"host" programs and may not match the architecture of the target. + +Ideally, out-of-tree builds would run `make prepare` first, so that +these programs could be compiled in the normal fashion. We ship all +the files needed for this to work. However, this requirement is +specific to our use case, and DKMS does not support it. + +Adding a minimal prepare target to the dependency graph causes the +programs to be built automatically and improves compatibility with +existing solutions. + +Signed-off-by: Ben Cressey +--- + Makefile | 9 +++++++++ + 1 file changed, 9 insertions(+) + +diff --git a/Makefile b/Makefile +index aba2651d0..6f0cb64df 100644 +--- a/Makefile ++++ b/Makefile +@@ -1706,6 +1706,15 @@ else # KBUILD_EXTMOD + KBUILD_BUILTIN := + KBUILD_MODULES := 1 + ++PHONY += modules_prepare ++modules_prepare: $(objtool_target) ++ $(Q)$(MAKE) $(build)=scripts/basic ++ $(Q)$(MAKE) $(build)=scripts/dtc ++ $(Q)$(MAKE) $(build)=scripts/mod ++ $(Q)$(MAKE) $(build)=scripts ++ ++prepare: modules_prepare ++ + build-dirs := $(KBUILD_EXTMOD) + $(MODORDER): descend + @: +-- +2.39.1 + diff --git a/packages/kernel-5.10/1002-initramfs-unlink-INITRAMFS_FORCE-from-CMDLINE_-EXTEN.patch b/packages/kernel-5.10/1002-initramfs-unlink-INITRAMFS_FORCE-from-CMDLINE_-EXTEN.patch new file mode 100644 index 00000000..d1745357 --- /dev/null +++ b/packages/kernel-5.10/1002-initramfs-unlink-INITRAMFS_FORCE-from-CMDLINE_-EXTEN.patch @@ -0,0 +1,50 @@ +From 4e00f4850eaf84e1e638c467f444b8f4fb8c67f8 Mon Sep 17 00:00:00 2001 +From: Ben Cressey +Date: Tue, 18 Oct 2022 22:24:52 +0000 +Subject: [PATCH] initramfs: unlink INITRAMFS_FORCE from CMDLINE_{EXTEND,FORCE} + +The motivation given in cff75e0b6fe83 for tying INITRAMFS_FORCE to +either of CMDLINE_{EXTEND,FORCE} was that these options imply an +inflexible bootloader, and that overriding the initramfs image would +also only be necessary for inflexible bootloaders. + +However, with the advent of Boot Config support, distributions that do +not normally use an initramfs may still want to allow an "initrd" to be +passed by the bootloader in order to accept boot configuration data. In +such cases, the CMDLINE_{EXTEND,FORCE} options are not desired because +the bootloader is actually expected to control the kernel command line. + +Unlinking the INITRAMFS_FORCE config option allows Boot Config data to +be passed by the bootloader while still preventing an unexpected +initramfs from overriding the built-in initramfs (if any). + +Signed-off-by: Ben Cressey +--- + usr/Kconfig | 4 +++- + 1 file changed, 3 insertions(+), 1 deletion(-) + +diff --git a/usr/Kconfig b/usr/Kconfig +index 8bbcf699fe3b..06aac19063ee 100644 +--- a/usr/Kconfig ++++ b/usr/Kconfig +@@ -24,7 +24,7 @@ config INITRAMFS_SOURCE + + config INITRAMFS_FORCE + bool "Ignore the initramfs passed by the bootloader" +- depends on CMDLINE_EXTEND || CMDLINE_FORCE ++ default n + help + This option causes the kernel to ignore the initramfs image + (or initrd image) passed to it by the bootloader. This is +@@ -32,6 +32,8 @@ config INITRAMFS_FORCE + and is useful if you cannot or don't want to change the image + your bootloader passes to the kernel. + ++ If unsure, say N. ++ + config INITRAMFS_ROOT_UID + int "User ID to map to 0 (user root)" + depends on INITRAMFS_SOURCE!="" +-- +2.37.2 + diff --git a/packages/kernel-5.10/1003-af_unix-increase-default-max_dgram_qlen-to-512.patch b/packages/kernel-5.10/1003-af_unix-increase-default-max_dgram_qlen-to-512.patch new file mode 100644 index 00000000..9363ddad --- /dev/null +++ b/packages/kernel-5.10/1003-af_unix-increase-default-max_dgram_qlen-to-512.patch @@ -0,0 +1,47 @@ +From b3983ebbfa2dc231a2b61092b0a936bd25294239 Mon Sep 17 00:00:00 2001 +From: Markus Boehme +Date: Tue, 23 May 2023 21:24:38 +0000 +Subject: [PATCH] af_unix: increase default max_dgram_qlen to 512 + +The net.unix.max_dgram_qlen sysctl has been defined with a default value of +10 since before the current Git history started in 2005. Systems have more +resources these days, and while the default values for other sysctls like +net.core.somaxconn have been adapted, max_dgram_qlen never was. + +Increase the default value for max_dgram_qlen to 512. A large number of +hosts effectively already run with this or a larger value, since systemd +has been making sure it is set to at least 512 since 2015. + +Signed-off-by: Markus Boehme +--- + Documentation/networking/ip-sysctl.rst | 2 +- + net/unix/af_unix.c | 2 +- + 2 files changed, 2 insertions(+), 2 deletions(-) + +diff --git a/Documentation/networking/ip-sysctl.rst b/Documentation/networking/ip-sysctl.rst +index 252212998..164a65667 100644 +--- a/Documentation/networking/ip-sysctl.rst ++++ b/Documentation/networking/ip-sysctl.rst +@@ -2688,5 +2688,5 @@ addr_scope_policy - INTEGER + max_dgram_qlen - INTEGER + The maximum length of dgram socket receive queue + +- Default: 10 ++ Default: 512 + +diff --git a/net/unix/af_unix.c b/net/unix/af_unix.c +index 28721e957..a5f081ad8 100644 +--- a/net/unix/af_unix.c ++++ b/net/unix/af_unix.c +@@ -2948,7 +2948,7 @@ static int __net_init unix_net_init(struct net *net) + { + int error = -ENOMEM; + +- net->unx.sysctl_max_dgram_qlen = 10; ++ net->unx.sysctl_max_dgram_qlen = 512; + if (unix_sysctl_register(net)) + goto out; + +-- +2.39.2 + diff --git a/packages/kernel-5.10/2000-kbuild-move-module-strip-compression-code-into-scrip.patch b/packages/kernel-5.10/2000-kbuild-move-module-strip-compression-code-into-scrip.patch new file mode 100644 index 00000000..7e0050bd --- /dev/null +++ b/packages/kernel-5.10/2000-kbuild-move-module-strip-compression-code-into-scrip.patch @@ -0,0 +1,184 @@ +From 4fc601b61092b4a7608a3d79d32663d9d167caf4 Mon Sep 17 00:00:00 2001 +From: Masahiro Yamada +Date: Wed, 31 Mar 2021 22:38:08 +0900 +Subject: [PATCH 2000/2001] kbuild: move module strip/compression code into + scripts/Makefile.modinst + +Both mod_strip_cmd and mod_compress_cmd are only used in +scripts/Makefile.modinst, hence there is no good reason to define them +in the top Makefile. Move the relevant code to scripts/Makefile.modinst. + +Also, show separate log messages for each of install, strip, sign, and +compress. + +Signed-off-by: Masahiro Yamada +(cherry picked from commit 65ce9c38326e2588fcd1a3a4817c14b4660f430b) +[fixed a merge conflict in Makefile and script/Makefile.modinst while cherry-picking] +Signed-off-by: Arnaldo Garcia Rincon +--- + Makefile | 32 ------------- + scripts/Makefile.modinst | 98 +++++++++++++++++++++++++++++++++------- + 2 files changed, 81 insertions(+), 49 deletions(-) + +diff --git a/Makefile b/Makefile +index 2931104182e7..bf6f6e3074da 100644 +--- a/Makefile ++++ b/Makefile +@@ -1028,38 +1028,6 @@ export INSTALL_DTBS_PATH ?= $(INSTALL_PATH)/dtbs/$(KERNELRELEASE) + MODLIB = $(INSTALL_MOD_PATH)/lib/modules/$(KERNELRELEASE) + export MODLIB + +-# +-# INSTALL_MOD_STRIP, if defined, will cause modules to be +-# stripped after they are installed. If INSTALL_MOD_STRIP is '1', then +-# the default option --strip-debug will be used. Otherwise, +-# INSTALL_MOD_STRIP value will be used as the options to the strip command. +- +-ifdef INSTALL_MOD_STRIP +-ifeq ($(INSTALL_MOD_STRIP),1) +-mod_strip_cmd = $(STRIP) --strip-debug +-else +-mod_strip_cmd = $(STRIP) $(INSTALL_MOD_STRIP) +-endif # INSTALL_MOD_STRIP=1 +-else +-mod_strip_cmd = true +-endif # INSTALL_MOD_STRIP +-export mod_strip_cmd +- +-# CONFIG_MODULE_COMPRESS, if defined, will cause module to be compressed +-# after they are installed in agreement with CONFIG_MODULE_COMPRESS_GZIP +-# or CONFIG_MODULE_COMPRESS_XZ. +- +-mod_compress_cmd = true +-ifdef CONFIG_MODULE_COMPRESS +- ifdef CONFIG_MODULE_COMPRESS_GZIP +- mod_compress_cmd = $(KGZIP) -n -f +- endif # CONFIG_MODULE_COMPRESS_GZIP +- ifdef CONFIG_MODULE_COMPRESS_XZ +- mod_compress_cmd = $(XZ) -f +- endif # CONFIG_MODULE_COMPRESS_XZ +-endif # CONFIG_MODULE_COMPRESS +-export mod_compress_cmd +- + ifdef CONFIG_MODULE_SIG_ALL + $(eval $(call config_filename,MODULE_SIG_KEY)) + +diff --git a/scripts/Makefile.modinst b/scripts/Makefile.modinst +index 5a4579e76485..84696ef99df7 100644 +--- a/scripts/Makefile.modinst ++++ b/scripts/Makefile.modinst +@@ -6,30 +6,94 @@ + PHONY := __modinst + __modinst: + +-include scripts/Kbuild.include ++include include/config/auto.conf ++include $(srctree)/scripts/Kbuild.include + +-modules := $(sort $(shell cat $(if $(KBUILD_EXTMOD),$(KBUILD_EXTMOD)/)modules.order)) ++modules := $(sort $(shell cat $(MODORDER))) ++ ++ifeq ($(KBUILD_EXTMOD),) ++dst := $(MODLIB)/kernel ++else ++INSTALL_MOD_DIR ?= extra ++dst := $(MODLIB)/$(INSTALL_MOD_DIR) ++endif ++ ++suffix-y := ++suffix-$(CONFIG_MODULE_COMPRESS_GZIP) := .gz ++suffix-$(CONFIG_MODULE_COMPRESS_XZ) := .xz ++ ++modules := $(patsubst $(extmod_prefix)%, $(dst)/%$(suffix-y), $(modules)) + +-PHONY += $(modules) + __modinst: $(modules) + @: + +-# Don't stop modules_install if we can't sign external modules. +-quiet_cmd_modules_install = INSTALL $@ +- cmd_modules_install = \ +- mkdir -p $(2) ; \ +- cp $@ $(2) ; \ +- $(mod_strip_cmd) $(2)/$(notdir $@) ; \ +- $(mod_sign_cmd) $(2)/$(notdir $@) $(patsubst %,|| true,$(KBUILD_EXTMOD)) ; \ +- $(mod_compress_cmd) $(2)/$(notdir $@) ++quiet_cmd_none = ++ cmd_none = : + +-# Modules built outside the kernel source tree go into extra by default +-INSTALL_MOD_DIR ?= extra +-ext-mod-dir = $(INSTALL_MOD_DIR)$(subst $(patsubst %/,%,$(KBUILD_EXTMOD)),,$(@D)) ++# ++# Installation ++# ++quiet_cmd_install = INSTALL $@ ++ cmd_install = mkdir -p $(dir $@); cp $< $@ ++ ++# Strip ++# ++# INSTALL_MOD_STRIP, if defined, will cause modules to be stripped after they ++# are installed. If INSTALL_MOD_STRIP is '1', then the default option ++# --strip-debug will be used. Otherwise, INSTALL_MOD_STRIP value will be used ++# as the options to the strip command. ++ifdef INSTALL_MOD_STRIP ++ ++ifeq ($(INSTALL_MOD_STRIP),1) ++strip-option := --strip-debug ++else ++strip-option := $(INSTALL_MOD_STRIP) ++endif ++ ++quiet_cmd_strip = STRIP $@ ++ cmd_strip = $(STRIP) $(strip-option) $@ ++ ++else ++ ++quiet_cmd_strip = ++ cmd_strip = : ++ ++endif ++ ++# ++# Signing ++# Don't stop modules_install even if we can't sign external modules. ++# ++ifeq ($(CONFIG_MODULE_SIG_ALL),y) ++quiet_cmd_sign = SIGN $@ ++$(eval $(call config_filename,MODULE_SIG_KEY)) ++ cmd_sign = scripts/sign-file $(CONFIG_MODULE_SIG_HASH) $(MODULE_SIG_KEY_SRCPREFIX)$(CONFIG_MODULE_SIG_KEY) certs/signing_key.x509 $@ \ ++ $(if $(KBUILD_EXTMOD),|| true) ++else ++quiet_cmd_sign := ++ cmd_sign := : ++endif ++ ++$(dst)/%.ko: $(extmod_prefix)%.ko FORCE ++ $(call cmd,install) ++ $(call cmd,strip) ++ $(call cmd,sign) ++ ++# ++# Compression ++# ++quiet_cmd_gzip = GZIP $@ ++ cmd_gzip = $(KGZIP) -n -f $< ++quiet_cmd_xz = XZ $@ ++ cmd_xz = $(XZ) --lzma2=dict=2MiB -f $< ++ ++$(dst)/%.ko.gz: $(dst)/%.ko FORCE ++ $(call cmd,gzip) + +-modinst_dir = $(if $(KBUILD_EXTMOD),$(ext-mod-dir),kernel/$(@D)) ++$(dst)/%.ko.xz: $(dst)/%.ko FORCE ++ $(call cmd,xz) + +-$(modules): +- $(call cmd,modules_install,$(MODLIB)/$(modinst_dir)) ++PHONY += FORCE ++FORCE: + + .PHONY: $(PHONY) +-- +2.30.2 + diff --git a/packages/kernel-5.10/2001-kbuild-add-support-for-zstd-compressed-modules.patch b/packages/kernel-5.10/2001-kbuild-add-support-for-zstd-compressed-modules.patch new file mode 100644 index 00000000..9cd6a36b --- /dev/null +++ b/packages/kernel-5.10/2001-kbuild-add-support-for-zstd-compressed-modules.patch @@ -0,0 +1,82 @@ +From 35822be50c3068a660331b82a6d37db42bc78126 Mon Sep 17 00:00:00 2001 +From: Piotr Gorski +Date: Wed, 7 Apr 2021 18:09:27 +0200 +Subject: [PATCH 2001/2001] kbuild: add support for zstd compressed modules + +kmod 28 supports modules compressed in zstd format so let's add this +possibility to kernel. + +Signed-off-by: Piotr Gorski +Reviewed-by: Oleksandr Natalenko +Signed-off-by: Masahiro Yamada +(cherry picked from commit c3d7ef377eb2564b165b1e8fdb4646952c90ac17) +[fixed a merge conflict in init/Kconfig] +Signed-off-by: Arnaldo Garcia Rincon +--- + init/Kconfig | 11 +++++++++-- + scripts/Makefile.modinst | 6 ++++++ + 2 files changed, 15 insertions(+), 2 deletions(-) + +diff --git a/init/Kconfig b/init/Kconfig +index fc4c9f416fad..113481826737 100644 +--- a/init/Kconfig ++++ b/init/Kconfig +@@ -2234,8 +2234,9 @@ config MODULE_COMPRESS + Out-of-tree kernel modules installed using Kbuild will also be + compressed upon installation. + +- Note: for modules inside an initrd or initramfs, it's more efficient +- to compress the whole initrd or initramfs instead. ++ Please note that the tool used to load modules needs to support the ++ corresponding algorithm. module-init-tools MAY support gzip, and kmod ++ MAY support gzip, xz and zstd. + + Note: This is fully compatible with signed modules. + +@@ -2257,6 +2258,12 @@ config MODULE_COMPRESS_GZIP + config MODULE_COMPRESS_XZ + bool "XZ" + ++config MODULE_COMPRESS_ZSTD ++ bool "ZSTD" ++ help ++ Compress modules with ZSTD. The installed modules are suffixed ++ with .ko.zst. ++ + endchoice + + config MODULE_ALLOW_MISSING_NAMESPACE_IMPORTS +diff --git a/scripts/Makefile.modinst b/scripts/Makefile.modinst +index 84696ef99df7..59f613aa08b4 100644 +--- a/scripts/Makefile.modinst ++++ b/scripts/Makefile.modinst +@@ -21,6 +21,7 @@ endif + suffix-y := + suffix-$(CONFIG_MODULE_COMPRESS_GZIP) := .gz + suffix-$(CONFIG_MODULE_COMPRESS_XZ) := .xz ++suffix-$(CONFIG_MODULE_COMPRESS_ZSTD) := .zst + + modules := $(patsubst $(extmod_prefix)%, $(dst)/%$(suffix-y), $(modules)) + +@@ -86,6 +87,8 @@ quiet_cmd_gzip = GZIP $@ + cmd_gzip = $(KGZIP) -n -f $< + quiet_cmd_xz = XZ $@ + cmd_xz = $(XZ) --lzma2=dict=2MiB -f $< ++quiet_cmd_zstd = ZSTD $@ ++ cmd_zstd = $(ZSTD) -T0 --rm -f -q $< + + $(dst)/%.ko.gz: $(dst)/%.ko FORCE + $(call cmd,gzip) +@@ -93,6 +96,9 @@ $(dst)/%.ko.gz: $(dst)/%.ko FORCE + $(dst)/%.ko.xz: $(dst)/%.ko FORCE + $(call cmd,xz) + ++$(dst)/%.ko.zst: $(dst)/%.ko FORCE ++ $(call cmd,zstd) ++ + PHONY += FORCE + FORCE: + +-- +2.30.2 + diff --git a/packages/kernel-5.10/5001-Revert-netfilter-nf_tables-drop-map-element-referenc.patch b/packages/kernel-5.10/5001-Revert-netfilter-nf_tables-drop-map-element-referenc.patch new file mode 100644 index 00000000..1768d2d5 --- /dev/null +++ b/packages/kernel-5.10/5001-Revert-netfilter-nf_tables-drop-map-element-referenc.patch @@ -0,0 +1,75 @@ +From e499042e36f6b00fcf68452c2d7bfdcf124203c5 Mon Sep 17 00:00:00 2001 +From: Leonard Foerster +Date: Mon, 11 Sep 2023 11:17:18 +0000 +Subject: [PATCH] Revert "netfilter: nf_tables: drop map element references + from preparation phase" + +This reverts commit 9ff6253cea9cf567bc899164405f437212eb59f2. + +This reverts an AL downstream patch that is not adding any value and is +cluttering the patch queue unnecessarily. This seems to have started as +a downstream backport of the original commit 628bd3e49cba1 introduced +upstream in v6.4.13, but ended picking up an extra function +`nft_setelem_validate` which was introduced in d46fc894147cf in v6.3.20. +That additional patch has not been backported to the 5.10 series as it +fixes a bug introduced only in 5.13. + +When the original patch was introduced in upstream stable 5.10 series as +a136b7942ad2a in 5.10.188 that single additional function stayed around +in AL as this patch I am reverting here. The function it adds is never +referenced in the assembled linux tree, so remove it in an attempy to +improve our code hygiene. + +Letting it stay in would also confuse here, as before this revert we +have two patches with the same name and same commit message, but +completely disjunct diffs claiming to be a backport of 628bd3e49cba1. + +Signed-off-by: Leonard Foerster +--- + net/netfilter/nf_tables_api.c | 30 ------------------------------ + 1 file changed, 30 deletions(-) + +diff --git a/net/netfilter/nf_tables_api.c b/net/netfilter/nf_tables_api.c +index 96fd4e68973b..2669999d1bc9 100644 +--- a/net/netfilter/nf_tables_api.c ++++ b/net/netfilter/nf_tables_api.c +@@ -3311,36 +3311,6 @@ static int nft_table_validate(struct net *net, const struct nft_table *table) + return 0; + } + +-int nft_setelem_validate(const struct nft_ctx *ctx, struct nft_set *set, +- const struct nft_set_iter *iter, +- struct nft_set_elem *elem) +-{ +- const struct nft_set_ext *ext = nft_set_elem_ext(set, elem->priv); +- struct nft_ctx *pctx = (struct nft_ctx *)ctx; +- const struct nft_data *data; +- int err; +- +- if (nft_set_ext_exists(ext, NFT_SET_EXT_FLAGS) && +- *nft_set_ext_flags(ext) & NFT_SET_ELEM_INTERVAL_END) +- return 0; +- +- data = nft_set_ext_data(ext); +- switch (data->verdict.code) { +- case NFT_JUMP: +- case NFT_GOTO: +- pctx->level++; +- err = nft_chain_validate(ctx, data->verdict.chain); +- if (err < 0) +- return err; +- pctx->level--; +- break; +- default: +- break; +- } +- +- return 0; +-} +- + static struct nft_rule *nft_rule_lookup_byid(const struct net *net, + const struct nft_chain *chain, + const struct nlattr *nla); +-- +2.40.1 + diff --git a/packages/kernel-5.10/Cargo.toml b/packages/kernel-5.10/Cargo.toml new file mode 100644 index 00000000..9cca3978 --- /dev/null +++ b/packages/kernel-5.10/Cargo.toml @@ -0,0 +1,27 @@ +[package] +name = "kernel-5_10" +version = "0.1.0" +edition = "2021" +publish = false +build = "../build.rs" + +[package.metadata.build-package] +package-name = "kernel-5.10" + +[lib] +path = "../packages.rs" + +[[package.metadata.build-package.external-files]] +# Use latest-kernel-srpm-url.sh to get this. +url = "https://cdn.amazonlinux.com/blobstore/0af5f80d00a3d5a867d4959d74751bc7d24b1bcb0ab8a5de558ae301ae0fa52e/kernel-5.10.228-219.884.amzn2.src.rpm" +sha512 = "124c6d662c48dc4cb8caf035e9ee44c9c47bc5e19141c319b94abc441dce4e2afa24e30b9c0196665aa267b6ef85004153b3f5cddfe9191c2c8927ddb4175fbd" +force-upstream = true + +[[package.metadata.build-package.external-files]] +# Use latest-neuron-srpm-url.sh to get this. +url = "https://yum.repos.neuron.amazonaws.com/aws-neuronx-dkms-2.18.12.0.noarch.rpm" +sha512 = "4ed92e661d0ba368eaf8f60e1a68c202062a26819231fcfd42a5ff05d20ad2f34b82b23359a88e80eea22ee5d0056ad769b6febd5d7e7b161da0e36434ba2579" +force-upstream = true + +[build-dependencies] +microcode = { path = "../microcode" } diff --git a/packages/kernel-5.10/README.md b/packages/kernel-5.10/README.md new file mode 100644 index 00000000..6d05729e --- /dev/null +++ b/packages/kernel-5.10/README.md @@ -0,0 +1,16 @@ +# kernel-5.10 + +This package contains the Bottlerocket Linux kernel of the 5.10 series. + + +## Testing of Configuration Changes + +Bottlerocket kernels are built in multiple flavors (e.g. cloud, bare metal) and for multiple architectures (e.g. aarch64, x86_64). +The kernel configuration for any of those combinations might change independently of the others. +Please use `tools/diff-kernel-config` from the main Bottlerocket repository to ensure the configuration for any of the combinations does not change inadvertently. +Changes that can have an effect on the resulting kernel configuration include: + +* explicit kernel configuration changes +* package updates/kernel rebases + +Reviewers on a pull request potentially changing the kernel configuration will appreciate having the report produced by `diff-kernel-config` included in the PR description. diff --git a/packages/kernel-5.10/config-bottlerocket b/packages/kernel-5.10/config-bottlerocket new file mode 100644 index 00000000..09baaab0 --- /dev/null +++ b/packages/kernel-5.10/config-bottlerocket @@ -0,0 +1,198 @@ +# Because Bottlerocket does not have an initramfs, modules required to mount +# the root filesystem must be set to y. + +# The root filesystem is ext4 +CONFIG_EXT4_FS=y + +# NVMe support +CONFIG_BLK_DEV_NVME=y +CONFIG_NVME_CORE=y + +# Xen blkfront for Xen-based EC2 platforms +CONFIG_XEN_BLKDEV_FRONTEND=y + +# virtio for local testing with QEMU +CONFIG_VIRTIO=y +CONFIG_VIRTIO_BLK=y +CONFIG_VIRTIO_PCI=y + +# dm-verity and enabling it on the kernel command line +CONFIG_BLK_DEV_DM=y +CONFIG_DAX=y +CONFIG_DM_INIT=y +CONFIG_DM_VERITY=y + +# TCMU/LIO +CONFIG_TCM_USER2=m + +# EFI +CONFIG_EFI=y +CONFIG_EFI_STUB=y +CONFIG_EFI_MIXED=y + +# EFI video +CONFIG_FB=y +CONFIG_FB_EFI=y +CONFIG_FRAMEBUFFER_CONSOLE_DEFERRED_TAKEOVER=y + +# yama LSM for ptrace restrictions +CONFIG_SECURITY_YAMA=y + +# Do not allow SELinux to be disabled at boot. +# CONFIG_SECURITY_SELINUX_BOOTPARAM is not set + +# Do not allow SELinux to be disabled at runtime. +# CONFIG_SECURITY_SELINUX_DISABLE is not set + +# Do not allow SELinux to use `enforcing=0` behavior. +# CONFIG_SECURITY_SELINUX_DEVELOP is not set + +# Check the protection applied by the kernel for mmap and mprotect, +# rather than the protection requested by userspace. +CONFIG_SECURITY_SELINUX_CHECKREQPROT_VALUE=0 + +# Enable support for the kernel lockdown security module. +CONFIG_SECURITY_LOCKDOWN_LSM=y + +# Enable lockdown early so that if the option is present on the +# kernel command line, it can be enforced. +CONFIG_SECURITY_LOCKDOWN_LSM_EARLY=y + +# Enable zstd compression for squashfs. +CONFIG_SQUASHFS_ZSTD=y + +# enable /proc/config.gz +CONFIG_IKCONFIG=y +CONFIG_IKCONFIG_PROC=y + +# kernel headers at /sys/kernel/kheaders.tar.xz +CONFIG_IKHEADERS=y + +# BTF debug info at /sys/kernel/btf/vmlinux +CONFIG_DEBUG_INFO_BTF=y + +# We don't want to extend the kernel command line with any upstream defaults; +# Bottlerocket uses a fairly custom setup that needs tight control over it. +# CONFIG_CMDLINE_EXTEND is not set + +# We don't want to unpack the initramfs passed by the bootloader. The intent of +# this option is to ensure that the built-in initramfs is used. Since we do not +# have a built-in initramfs, in practice this means we will never unpack any +# initramfs. +# +# We rely on `CONFIG_BLK_DEV_INITRD` for boot config support, so we can't just +# disable the functionality altogether. +CONFIG_INITRAMFS_FORCE=y + +# Enable ZSTD kernel image compression +CONFIG_HAVE_KERNEL_ZSTD=y +CONFIG_KERNEL_ZSTD=y +CONFIG_ZSTD_COMPRESS=y +CONFIG_ZSTD_DECOMPRESS=y +CONFIG_DECOMPRESS_ZSTD=y + +# Enable gz modules compression +CONFIG_MODULE_COMPRESS=y +CONFIG_MODULE_COMPRESS_GZIP=y + +# Load i8042 controller, keyboard, and mouse as modules, to avoid waiting for +# them before mounting the root device. +CONFIG_SERIO_I8042=m +CONFIG_KEYBOARD_ATKBD=m +CONFIG_MOUSE_PS2=m + +# Add support for the basic IPMI handler. While Bottlerocket does not ship with +# any specific IPMI interfaces, the basic IPMI handler interface is used by the +# nvidia drivers, which makes this necessary. +CONFIG_IPMI_HANDLER=m +# Disable more specialized IPMI drivers that are not relevant for our use-cases +# CONFIG_IPMI_DEVICE_INTERFACE is not set +# CONFIG_IPMI_PANIC_EVENT is not set +# CONFIG_IPMI_POWEROFF is not set +# CONFIG_IPMI_SI is not set +# CONFIG_IPMI_WATCHDOG is not set +# CONFIG_ACPI_IPMI is not set + +# Add support for bootconfig +CONFIG_BOOT_CONFIG=y + +# Enables support for checkpoint/restore +CONFIG_CHECKPOINT_RESTORE=y + +# Disable user-mode helpers for BPF preload and bpfilter, since they rely on a +# more complete set of userspace libraries for the target than we want to +# depend on at kernel build time. +# CONFIG_BPF_PRELOAD_UMD is not set +# CONFIG_BPFILTER_UMH is not set + +# Disable unused filesystems. +# CONFIG_AFS_FS is not set +# CONFIG_CRAMFS is not set +# CONFIG_ECRYPT_FS is not set +# CONFIG_EXT2_FS is not set +# CONFIG_EXT3_FS is not set +CONFIG_EXT4_USE_FOR_EXT2=y +# CONFIG_GFS2_FS is not set +# CONFIG_HFS_FS is not set +# CONFIG_HFSPLUS_FS is not set +# CONFIG_JFS_FS is not set +# CONFIG_JFFS2_FS is not set +# CONFIG_NFS_V2 is not set +# CONFIG_NILFS2_FS is not set +# CONFIG_NTFS_FS is not set +# CONFIG_ROMFS_FS is not set +# CONFIG_UFS_FS is not set +# CONFIG_ZONEFS_FS is not set + +# Disable unused network protocols. +# CONFIG_AF_RXRPC is not set +# CONFIG_ATM is not set +# CONFIG_CAN is not set +# CONFIG_HSR is not set +# CONFIG_IP_DCCP is not set +# CONFIG_L2TP is not set +# CONFIG_RDS is not set +# CONFIG_RFKILL is not set +# CONFIG_TIPC is not set + +# Disable USB-attached network interfaces, unused in the cloud and on server-grade hardware. +# CONFIG_USB_NET_DRIVERS is not set + +# Disable obsolete NIC drivers +# CONFIG_QLGE is not set +# CONFIG_MLX4_CORE is not set +# CONFIG_MLX4_EN is not set +# CONFIG_MLX4_INFINIBAND is not set +# CONFIG_MLXSW_CORE is not set +# CONFIG_MLXFW is not set + +# Disable unused qdiscs +# - sch_cake targets home routers and residential links +# CONFIG_NET_SCH_CAKE is not set + +# Disable unused MPI3MR driver AL carries as a backport +# CONFIG_SCSI_MPI3MR is not set + +# Work with the previously used in-tree version of SMARTPQI instead of AL backport +# CONFIG_AMAZON_SCSI_SMARTPQI is not set +CONFIG_SCSI_SMARTPQI=m + +# Disable edac driver for intel 10nm memory controllers +# CONFIG_EDAC_I10NM is not set + +# Disable AL port of BBR2 congestion algorithm +# CONFIG_TCP_CONG_BBR2 is not set + +# Support boot from IDE disks +CONFIG_ATA=y +CONFIG_ATA_PIIX=y +CONFIG_SCSI=y +CONFIG_BLK_DEV_SD=y + +# Mellanox network support +CONFIG_NET_SWITCHDEV=y +CONFIG_NET_VENDOR_MELLANOX=y +CONFIG_MLX5_CORE=m +CONFIG_MLX5_CORE_EN=y +CONFIG_MLX5_INFINIBAND=m +CONFIG_MLXFW=m diff --git a/packages/kernel-5.10/kernel-5.10.spec b/packages/kernel-5.10/kernel-5.10.spec new file mode 100644 index 00000000..88d5ab8f --- /dev/null +++ b/packages/kernel-5.10/kernel-5.10.spec @@ -0,0 +1,343 @@ +%global debug_package %{nil} + +Name: %{_cross_os}kernel-5.10 +Version: 5.10.228 +Release: 1%{?dist} +Summary: The Linux kernel +License: GPL-2.0 WITH Linux-syscall-note +URL: https://www.kernel.org/ +# Use latest-kernel-srpm-url.sh to get this. +Source0: https://cdn.amazonlinux.com/blobstore/0af5f80d00a3d5a867d4959d74751bc7d24b1bcb0ab8a5de558ae301ae0fa52e/kernel-5.10.228-219.884.amzn2.src.rpm +# Use latest-neuron-srpm-url.sh to get this. +Source1: https://yum.repos.neuron.amazonaws.com/aws-neuronx-dkms-2.18.12.0.noarch.rpm +Source100: config-bottlerocket + +# Neuron-related drop-ins. +Source220: neuron-sysinit.target.drop-in.conf +Source221: modprobe@neuron.service.drop-in.conf + +# Help out-of-tree module builds run `make prepare` automatically. +Patch1001: 1001-Makefile-add-prepare-target-for-external-modules.patch +# Enable INITRAMFS_FORCE config option for our use case. +Patch1002: 1002-initramfs-unlink-INITRAMFS_FORCE-from-CMDLINE_-EXTEN.patch +# Increase default of sysctl net.unix.max_dgram_qlen to 512. +Patch1003: 1003-af_unix-increase-default-max_dgram_qlen-to-512.patch + +# Add zstd support for compressed kernel modules +Patch2000: 2000-kbuild-move-module-strip-compression-code-into-scrip.patch +Patch2001: 2001-kbuild-add-support-for-zstd-compressed-modules.patch + +# Fixup unused code inherited from AL +Patch5001: 5001-Revert-netfilter-nf_tables-drop-map-element-referenc.patch + +BuildRequires: bc +BuildRequires: elfutils-devel +BuildRequires: hostname +BuildRequires: kmod +BuildRequires: openssl-devel + +# CPU microcode updates are included as "extra firmware" so the files don't +# need to be installed on the root filesystem. However, we want the license and +# attribution files to be available in the usual place. +%if "%{_cross_arch}" == "x86_64" +BuildRequires: %{_cross_os}microcode +Requires: %{_cross_os}microcode-licenses +%endif + +# Pull in expected modules and development files. +Requires: %{name}-modules = %{version}-%{release} +Requires: %{name}-devel = %{version}-%{release} + +# Pull in platform-dependent modules. +%if "%{_cross_arch}" == "x86_64" +Requires: (%{name}-modules-neuron if (%{_cross_os}variant-platform(aws) without %{_cross_os}variant-flavor(nvidia))) +%endif + +# The 5.10 kernel is not FIPS certified. +Conflicts: %{_cross_os}image-feature(fips) + +# Using EROFS for the root partition requires a 6.1+ kernel. +Conflicts: %{_cross_os}image-feature(erofs-root-partition) + +%global kernel_sourcedir %{_cross_usrsrc}/kernels +%global kernel_libdir %{_cross_libdir}/modules/%{version} + +%description +%{summary}. + +%package devel +Summary: Configured Linux kernel source for module building + +%description devel +%{summary}. + +%package archive +Summary: Archived Linux kernel source for module building + +%description archive +%{summary}. + +%package modules +Summary: Modules for the Linux kernel + +%description modules +%{summary}. + +%if "%{_cross_arch}" == "x86_64" +%package modules-neuron +Summary: Modules for the Linux kernel with Neuron hardware +Requires: %{name} +Requires: %{_cross_os}ghostdog +Requires: %{_cross_os}variant-platform(aws) +Conflicts: %{_cross_os}variant-flavor(nvidia) + +%description modules-neuron +%{summary}. +%endif + +%package headers +Summary: Header files for the Linux kernel for use by glibc + +%description headers +%{summary}. + +%prep +rpm2cpio %{SOURCE0} | cpio -iu linux-%{version}.tar config-%{_cross_arch} "*.patch" +tar -xof linux-%{version}.tar; rm linux-%{version}.tar +%setup -TDn linux-%{version} +# Patches from the Source0 SRPM +for patch in ../*.patch; do + patch -p1 <"$patch" +done +# Patches listed in this spec (Patch0001...) +%autopatch -p1 + +%if "%{_cross_arch}" == "x86_64" +microcode="$(find %{_cross_libdir}/firmware -type f -path '*/*-ucode/*' -printf '%%P ')" +cat < ../config-microcode +CONFIG_EXTRA_FIRMWARE="${microcode}" +CONFIG_EXTRA_FIRMWARE_DIR="%{_cross_libdir}/firmware" +EOF +%endif + +export ARCH="%{_cross_karch}" +export CROSS_COMPILE="%{_cross_target}-" + +KCONFIG_CONFIG="arch/%{_cross_karch}/configs/%{_cross_vendor}_defconfig" \ +scripts/kconfig/merge_config.sh \ + ../config-%{_cross_arch} \ +%if "%{_cross_arch}" == "x86_64" + ../config-microcode \ +%endif + %{SOURCE100} + +rm -f ../config-* ../*.patch + +%if "%{_cross_arch}" == "x86_64" +cd %{_builddir} +rpm2cpio %{SOURCE1} | cpio -idmu './usr/src/aws-neuronx-*' +find usr/src/ -mindepth 1 -maxdepth 1 -type d -exec mv {} neuron \; +rm -r usr +%endif + +%global kmake \ +make -s\\\ + ARCH="%{_cross_karch}"\\\ + CROSS_COMPILE="%{_cross_target}-"\\\ + INSTALL_HDR_PATH="%{buildroot}%{_cross_prefix}"\\\ + INSTALL_MOD_PATH="%{buildroot}%{_cross_prefix}"\\\ + INSTALL_MOD_STRIP=1\\\ +%{nil} + +%build +%kmake mrproper +%kmake %{_cross_vendor}_defconfig +%kmake %{?_smp_mflags} %{_cross_kimage} +%kmake %{?_smp_mflags} modules + +%if "%{_cross_arch}" == "x86_64" +%kmake %{?_smp_mflags} M=%{_builddir}/neuron +%endif + +%install +%kmake %{?_smp_mflags} headers_install +%kmake %{?_smp_mflags} modules_install + +%if "%{_cross_arch}" == "x86_64" +%kmake %{?_smp_mflags} M=%{_builddir}/neuron modules_install V=1 +mv \ + %{buildroot}%{kernel_libdir}/extra/%{_builddir}/neuron/neuron.ko* \ + %{buildroot}%{kernel_libdir}/extra +rm -rf %{buildroot}%{kernel_libdir}/extra/%{_builddir} +%endif + +install -d %{buildroot}/boot +install -T -m 0755 arch/%{_cross_karch}/boot/%{_cross_kimage} %{buildroot}/boot/vmlinuz +install -m 0644 .config %{buildroot}/boot/config + +find %{buildroot}%{_cross_prefix} \ + \( -name .install -o -name .check -o \ + -name ..install.cmd -o -name ..check.cmd \) -delete + +# For out-of-tree kmod builds, we need to support the following targets: +# make scripts -> make prepare -> make modules +# +# This requires enough of the kernel tree to build host programs under the +# "scripts" and "tools" directories. + +# Any existing ELF objects will not work properly if we're cross-compiling for +# a different architecture, so get rid of them to avoid confusing errors. +find arch scripts tools -type f -executable \ + -exec sh -c "head -c4 {} | grep -q ELF && rm {}" \; + +# We don't need to include these files. +find -type f \( -name \*.cmd -o -name \*.gitignore \) -delete + +# Avoid an OpenSSL dependency by stubbing out options for module signing and +# trusted keyrings, so `sign-file` and `extract-cert` won't be built. External +# kernel modules do not have access to the keys they would need to make use of +# these tools. +sed -i \ + -e 's,$(CONFIG_MODULE_SIG_FORMAT),n,g' \ + -e 's,$(CONFIG_SYSTEM_TRUSTED_KEYRING),n,g' \ + scripts/Makefile + +# Restrict permissions on System.map. +chmod 600 System.map + +( + find * \ + -type f \ + \( -name Build\* -o -name Kbuild\* -o -name Kconfig\* -o -name Makefile\* \) \ + -print + + find arch/%{_cross_karch}/ \ + -type f \ + \( -name module.lds -o -name vmlinux.lds.S -o -name Platform -o -name \*.tbl \) \ + -print + + find arch/%{_cross_karch}/{include,lib}/ -type f ! -name \*.o ! -name \*.o.d -print + echo arch/%{_cross_karch}/kernel/asm-offsets.s + echo lib/vdso/gettimeofday.c + + for d in \ + arch/%{_cross_karch}/tools \ + arch/%{_cross_karch}/kernel/vdso ; do + [ -d "${d}" ] && find "${d}/" -type f -print + done + + find include -type f -print + find scripts -type f ! -name \*.l ! -name \*.y ! -name \*.o -print + + find tools/{arch/%{_cross_karch},include,objtool,scripts}/ -type f ! -name \*.o -print + echo tools/build/fixdep.c + find tools/lib/subcmd -type f -print + find tools/lib/{ctype,hweight,rbtree,string,str_error_r}.c + + echo kernel/bounds.c + echo kernel/time/timeconst.bc + echo security/selinux/include/classmap.h + echo security/selinux/include/initial_sid_to_string.h + echo security/selinux/include/policycap.h + echo security/selinux/include/policycap_names.h + + echo .config + echo Module.symvers + echo System.map +) | sort -u > kernel_devel_files + +# Create squashfs of kernel-devel files (ie. /usr/src/kernels/). +# +# -no-exports: +# The filesystem does not need to be exported via NFS. +# +# -all-root: +# Make all files owned by root rather than the build user. +# +# -comp zstd: +# zstd offers compression ratios like xz and decompression speeds like lz4. +SQUASHFS_OPTS="-no-exports -all-root -comp zstd" +mkdir -p src_squashfs/%{version} +tar c -T kernel_devel_files | tar x -C src_squashfs/%{version} +mksquashfs src_squashfs kernel-devel.squashfs ${SQUASHFS_OPTS} + +# Create a tarball of the same files, for use outside the running system. +# In theory we could extract these files with `unsquashfs`, but we do not want +# to require it to be installed on the build host, and it errors out when run +# inside Docker unless the limit for open files is lowered. +tar cf kernel-devel.tar src_squashfs/%{version} --transform='s|src_squashfs/%{version}|kernel-devel|' +xz -T0 kernel-devel.tar + +install -D kernel-devel.squashfs %{buildroot}%{_cross_datadir}/bottlerocket/kernel-devel.squashfs +install -D kernel-devel.tar.xz %{buildroot}%{_cross_datadir}/bottlerocket/kernel-devel.tar.xz +install -d %{buildroot}%{kernel_sourcedir} + +# Replace the incorrect links from modules_install. These will be bound +# into a host container (and unused in the host) so they must not point +# to %{_cross_usrsrc} (eg. /x86_64-bottlerocket-linux-gnu/sys-root/...) +rm -f %{buildroot}%{kernel_libdir}/build %{buildroot}%{kernel_libdir}/source +ln -sf %{_usrsrc}/kernels/%{version} %{buildroot}%{kernel_libdir}/build +ln -sf %{_usrsrc}/kernels/%{version} %{buildroot}%{kernel_libdir}/source + +# Install a copy of System.map so that module dependencies can be regenerated. +install -p -m 0600 System.map %{buildroot}%{kernel_libdir} + +%if "%{_cross_arch}" == "x86_64" +# Add Neuron-related drop-ins to load the module when the hardware is present. +mkdir -p %{buildroot}%{_cross_unitdir}/sysinit.target.d +install -p -m 0644 %{S:220} %{buildroot}%{_cross_unitdir}/sysinit.target.d/neuron.conf + +mkdir -p %{buildroot}%{_cross_unitdir}/modprobe@neuron.service.d +install -p -m 0644 %{S:221} %{buildroot}%{_cross_unitdir}/modprobe@neuron.service.d/neuron.conf +%endif + +%files +%license COPYING LICENSES/preferred/GPL-2.0 LICENSES/exceptions/Linux-syscall-note +%{_cross_attribution_file} +/boot/vmlinuz +/boot/config + +%files modules +%dir %{_cross_libdir}/modules +%{_cross_libdir}/modules/* +%exclude %{kernel_libdir}/extra/neuron.ko.gz + +%if "%{_cross_arch}" == "x86_64" +%files modules-neuron +%{kernel_libdir}/extra/neuron.ko.gz +%{_cross_unitdir}/sysinit.target.d/neuron.conf +%{_cross_unitdir}/modprobe@neuron.service.d/neuron.conf +%endif + +%files headers +%dir %{_cross_includedir}/asm +%dir %{_cross_includedir}/asm-generic +%dir %{_cross_includedir}/drm +%dir %{_cross_includedir}/linux +%dir %{_cross_includedir}/misc +%dir %{_cross_includedir}/mtd +%dir %{_cross_includedir}/rdma +%dir %{_cross_includedir}/scsi +%dir %{_cross_includedir}/sound +%dir %{_cross_includedir}/video +%dir %{_cross_includedir}/xen +%{_cross_includedir}/asm/* +%{_cross_includedir}/asm-generic/* +%{_cross_includedir}/drm/* +%{_cross_includedir}/linux/* +%{_cross_includedir}/misc/* +%{_cross_includedir}/mtd/* +%{_cross_includedir}/rdma/* +%{_cross_includedir}/scsi/* +%{_cross_includedir}/sound/* +%{_cross_includedir}/video/* +%{_cross_includedir}/xen/* + +%files devel +%dir %{kernel_sourcedir} +%{_cross_datadir}/bottlerocket/kernel-devel.squashfs + +%files archive +%{_cross_datadir}/bottlerocket/kernel-devel.tar.xz + +%changelog diff --git a/packages/kernel-5.10/latest-kernel-srpm-url.sh b/packages/kernel-5.10/latest-kernel-srpm-url.sh new file mode 100755 index 00000000..46001c33 --- /dev/null +++ b/packages/kernel-5.10/latest-kernel-srpm-url.sh @@ -0,0 +1,2 @@ +#!/bin/sh +docker run --rm amazonlinux:2 sh -c 'amazon-linux-extras enable kernel-5.10 >/dev/null && yum install -q -y yum-utils && yumdownloader -q --source --urls kernel | grep ^http' diff --git a/packages/kernel-5.10/latest-neuron-srpm-url.sh b/packages/kernel-5.10/latest-neuron-srpm-url.sh new file mode 100755 index 00000000..5bb6c85e --- /dev/null +++ b/packages/kernel-5.10/latest-neuron-srpm-url.sh @@ -0,0 +1,9 @@ +#!/bin/sh +cmd=" +dnf install -q -y --releasever=latest yum-utils && +dnf download -q --repofrompath neuron,https://yum.repos.neuron.amazonaws.com --repo=neuron --urls aws-neuronx-dkms +" +docker run --rm amazonlinux:2023 bash -c "${cmd}" \ + | grep '^http' \ + | xargs --max-args=1 --no-run-if-empty realpath --canonicalize-missing --relative-to=. \ + | sed 's_:/_://_' diff --git a/packages/kernel-5.10/modprobe@neuron.service.drop-in.conf b/packages/kernel-5.10/modprobe@neuron.service.drop-in.conf new file mode 100644 index 00000000..e9174355 --- /dev/null +++ b/packages/kernel-5.10/modprobe@neuron.service.drop-in.conf @@ -0,0 +1,7 @@ +[Unit] +ConditionPathExists=!/etc/.neuron-modprobe-done + +[Service] +ExecCondition=/usr/bin/touch /etc/.neuron-modprobe-done +ExecCondition=/usr/bin/ghostdog neuron-present +RemainAfterExit=true diff --git a/packages/kernel-5.10/neuron-sysinit.target.drop-in.conf b/packages/kernel-5.10/neuron-sysinit.target.drop-in.conf new file mode 100644 index 00000000..11c78234 --- /dev/null +++ b/packages/kernel-5.10/neuron-sysinit.target.drop-in.conf @@ -0,0 +1,2 @@ +[Unit] +Wants=modprobe@neuron.service diff --git a/packages/kernel-5.15/.gitignore b/packages/kernel-5.15/.gitignore new file mode 100644 index 00000000..e7a9c134 --- /dev/null +++ b/packages/kernel-5.15/.gitignore @@ -0,0 +1 @@ +*.rpm diff --git a/packages/kernel-5.15/1001-Makefile-add-prepare-target-for-external-modules.patch b/packages/kernel-5.15/1001-Makefile-add-prepare-target-for-external-modules.patch new file mode 100644 index 00000000..3134803b --- /dev/null +++ b/packages/kernel-5.15/1001-Makefile-add-prepare-target-for-external-modules.patch @@ -0,0 +1,51 @@ +From fe8de462eb7edaccae54c31766dc5a2ffd254ab9 Mon Sep 17 00:00:00 2001 +From: Ben Cressey +Date: Mon, 19 Apr 2021 18:46:04 +0000 +Subject: [PATCH] Makefile: add prepare target for external modules + +We need to ensure that native versions of programs like `objtool` are +built before trying to build out-of-tree modules, or else the build +will fail. + +Unlike other distributions, we cannot include these programs in our +kernel-devel archive, because we rely on cross-compilation: these are +"host" programs and may not match the architecture of the target. + +Ideally, out-of-tree builds would run `make prepare` first, so that +these programs could be compiled in the normal fashion. We ship all +the files needed for this to work. However, this requirement is +specific to our use case, and DKMS does not support it. + +Adding a minimal prepare target to the dependency graph causes the +programs to be built automatically and improves compatibility with +existing solutions. + +Signed-off-by: Ben Cressey +Signed-off-by: Arnaldo Garcia Rincon +--- + Makefile | 9 +++++++++ + 1 file changed, 9 insertions(+) + +diff --git a/Makefile b/Makefile +index 86b6ca862e39..fbe9b66f4f27 100644 +--- a/Makefile ++++ b/Makefile +@@ -1766,6 +1766,15 @@ else # KBUILD_EXTMOD + KBUILD_BUILTIN := + KBUILD_MODULES := 1 + ++PHONY += modules_prepare ++modules_prepare: tools/objtool ++ $(Q)$(MAKE) $(build)=scripts/basic ++ $(Q)$(MAKE) $(build)=scripts/dtc ++ $(Q)$(MAKE) $(build)=scripts/mod ++ $(Q)$(MAKE) $(build)=scripts ++ ++prepare: modules_prepare ++ + build-dirs := $(KBUILD_EXTMOD) + $(MODORDER): descend + @: +-- +2.37.2 + diff --git a/packages/kernel-5.15/1002-Revert-kbuild-hide-tools-build-targets-from-external.patch b/packages/kernel-5.15/1002-Revert-kbuild-hide-tools-build-targets-from-external.patch new file mode 100644 index 00000000..c27b3a9f --- /dev/null +++ b/packages/kernel-5.15/1002-Revert-kbuild-hide-tools-build-targets-from-external.patch @@ -0,0 +1,64 @@ +From 33d06503d0b131ca4475d77383d28f1569002ce0 Mon Sep 17 00:00:00 2001 +From: Arnaldo Garcia Rincon +Date: Wed, 22 Jun 2022 19:26:43 +0000 +Subject: [PATCH] Revert "kbuild: hide tools/ build targets from external + module builds" + +This reverts commit 1bb0b18a06dceee1fdc32161a72e28eab6f011c4 in which +the targets to build "tools/*" were hidden for external modules, but +they are required by the kmod kit since the 'tools/*' binaries are not +distributed as part of the archive. + +Signed-off-by: Arnaldo Garcia Rincon +--- + Makefile | 27 ++++++++++++++------------- + 1 file changed, 14 insertions(+), 13 deletions(-) + +diff --git a/Makefile b/Makefile +index fbe9b66f4f27..81191e5bffcb 100644 +--- a/Makefile ++++ b/Makefile +@@ -1387,19 +1387,6 @@ ifneq ($(wildcard $(resolve_btfids_O)),) + $(Q)$(MAKE) -sC $(srctree)/tools/bpf/resolve_btfids O=$(resolve_btfids_O) clean + endif + +-# Clear a bunch of variables before executing the submake +-ifeq ($(quiet),silent_) +-tools_silent=s +-endif +- +-tools/: FORCE +- $(Q)mkdir -p $(objtree)/tools +- $(Q)$(MAKE) LDFLAGS= MAKEFLAGS="$(tools_silent) $(filter --j% -j,$(MAKEFLAGS))" O=$(abspath $(objtree)) subdir=tools -C $(srctree)/tools/ +- +-tools/%: FORCE +- $(Q)mkdir -p $(objtree)/tools +- $(Q)$(MAKE) LDFLAGS= MAKEFLAGS="$(tools_silent) $(filter --j% -j,$(MAKEFLAGS))" O=$(abspath $(objtree)) subdir=tools -C $(srctree)/tools/ $* +- + # --------------------------------------------------------------------------- + # Kernel selftest + +@@ -2019,6 +2006,20 @@ kernelversion: + image_name: + @echo $(KBUILD_IMAGE) + ++# Clear a bunch of variables before executing the submake ++ ++ifeq ($(quiet),silent_) ++tools_silent=s ++endif ++ ++tools/: FORCE ++ $(Q)mkdir -p $(objtree)/tools ++ $(Q)$(MAKE) LDFLAGS= MAKEFLAGS="$(tools_silent) $(filter --j% -j,$(MAKEFLAGS))" O=$(abspath $(objtree)) subdir=tools -C $(srctree)/tools/ ++ ++tools/%: FORCE ++ $(Q)mkdir -p $(objtree)/tools ++ $(Q)$(MAKE) LDFLAGS= MAKEFLAGS="$(tools_silent) $(filter --j% -j,$(MAKEFLAGS))" O=$(abspath $(objtree)) subdir=tools -C $(srctree)/tools/ $* ++ + quiet_cmd_rmfiles = $(if $(wildcard $(rm-files)),CLEAN $(wildcard $(rm-files))) + cmd_rmfiles = rm -rf $(rm-files) + +-- +2.37.2 + diff --git a/packages/kernel-5.15/1003-initramfs-unlink-INITRAMFS_FORCE-from-CMDLINE_-EXTEN.patch b/packages/kernel-5.15/1003-initramfs-unlink-INITRAMFS_FORCE-from-CMDLINE_-EXTEN.patch new file mode 100644 index 00000000..d1745357 --- /dev/null +++ b/packages/kernel-5.15/1003-initramfs-unlink-INITRAMFS_FORCE-from-CMDLINE_-EXTEN.patch @@ -0,0 +1,50 @@ +From 4e00f4850eaf84e1e638c467f444b8f4fb8c67f8 Mon Sep 17 00:00:00 2001 +From: Ben Cressey +Date: Tue, 18 Oct 2022 22:24:52 +0000 +Subject: [PATCH] initramfs: unlink INITRAMFS_FORCE from CMDLINE_{EXTEND,FORCE} + +The motivation given in cff75e0b6fe83 for tying INITRAMFS_FORCE to +either of CMDLINE_{EXTEND,FORCE} was that these options imply an +inflexible bootloader, and that overriding the initramfs image would +also only be necessary for inflexible bootloaders. + +However, with the advent of Boot Config support, distributions that do +not normally use an initramfs may still want to allow an "initrd" to be +passed by the bootloader in order to accept boot configuration data. In +such cases, the CMDLINE_{EXTEND,FORCE} options are not desired because +the bootloader is actually expected to control the kernel command line. + +Unlinking the INITRAMFS_FORCE config option allows Boot Config data to +be passed by the bootloader while still preventing an unexpected +initramfs from overriding the built-in initramfs (if any). + +Signed-off-by: Ben Cressey +--- + usr/Kconfig | 4 +++- + 1 file changed, 3 insertions(+), 1 deletion(-) + +diff --git a/usr/Kconfig b/usr/Kconfig +index 8bbcf699fe3b..06aac19063ee 100644 +--- a/usr/Kconfig ++++ b/usr/Kconfig +@@ -24,7 +24,7 @@ config INITRAMFS_SOURCE + + config INITRAMFS_FORCE + bool "Ignore the initramfs passed by the bootloader" +- depends on CMDLINE_EXTEND || CMDLINE_FORCE ++ default n + help + This option causes the kernel to ignore the initramfs image + (or initrd image) passed to it by the bootloader. This is +@@ -32,6 +32,8 @@ config INITRAMFS_FORCE + and is useful if you cannot or don't want to change the image + your bootloader passes to the kernel. + ++ If unsure, say N. ++ + config INITRAMFS_ROOT_UID + int "User ID to map to 0 (user root)" + depends on INITRAMFS_SOURCE!="" +-- +2.37.2 + diff --git a/packages/kernel-5.15/1004-af_unix-increase-default-max_dgram_qlen-to-512.patch b/packages/kernel-5.15/1004-af_unix-increase-default-max_dgram_qlen-to-512.patch new file mode 100644 index 00000000..888ebbd3 --- /dev/null +++ b/packages/kernel-5.15/1004-af_unix-increase-default-max_dgram_qlen-to-512.patch @@ -0,0 +1,47 @@ +From e36140bfb2795377360bb92c343b10c717567c62 Mon Sep 17 00:00:00 2001 +From: Markus Boehme +Date: Tue, 23 May 2023 17:16:44 +0000 +Subject: [PATCH] af_unix: increase default max_dgram_qlen to 512 + +The net.unix.max_dgram_qlen sysctl has been defined with a default value of +10 since before the current Git history started in 2005. Systems have more +resources these days, and while the default values for other sysctls like +net.core.somaxconn have been adapted, max_dgram_qlen never was. + +Increase the default value for max_dgram_qlen to 512. A large number of +hosts effectively already run with this or a larger value, since systemd +has been making sure it is set to at least 512 since 2015. + +Signed-off-by: Markus Boehme +--- + Documentation/networking/ip-sysctl.rst | 2 +- + net/unix/af_unix.c | 2 +- + 2 files changed, 2 insertions(+), 2 deletions(-) + +diff --git a/Documentation/networking/ip-sysctl.rst b/Documentation/networking/ip-sysctl.rst +index 7890b395e..54a0be396 100644 +--- a/Documentation/networking/ip-sysctl.rst ++++ b/Documentation/networking/ip-sysctl.rst +@@ -2885,5 +2885,5 @@ plpmtud_probe_interval - INTEGER + max_dgram_qlen - INTEGER + The maximum length of dgram socket receive queue + +- Default: 10 ++ Default: 512 + +diff --git a/net/unix/af_unix.c b/net/unix/af_unix.c +index a96026dbd..267ee6d29 100644 +--- a/net/unix/af_unix.c ++++ b/net/unix/af_unix.c +@@ -3343,7 +3343,7 @@ static int __net_init unix_net_init(struct net *net) + { + int error = -ENOMEM; + +- net->unx.sysctl_max_dgram_qlen = 10; ++ net->unx.sysctl_max_dgram_qlen = 512; + if (unix_sysctl_register(net)) + goto out; + +-- +2.39.2 + diff --git a/packages/kernel-5.15/1100-netfilter-xtables-fix-typo-causing-some-targets-not-.patch b/packages/kernel-5.15/1100-netfilter-xtables-fix-typo-causing-some-targets-not-.patch new file mode 100644 index 00000000..273bd93d --- /dev/null +++ b/packages/kernel-5.15/1100-netfilter-xtables-fix-typo-causing-some-targets-not-.patch @@ -0,0 +1,79 @@ +From 02d6d4a741619b0bc8f29705d0f59aac596a9bf6 Mon Sep 17 00:00:00 2001 +From: Greg Kroah-Hartman +Date: Mon, 28 Oct 2024 07:25:38 +0100 +Subject: [PATCH 49/79] netfilter: xtables: fix typo causing some targets not + to load on IPv6 +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +5.15-stable review patch. If anyone has any objections, please let me know. + +------------------ + +From: Pablo Neira Ayuso + +[ Upstream commit 306ed1728e8438caed30332e1ab46b28c25fe3d8 ] + +- There is no NFPROTO_IPV6 family for mark and NFLOG. +- TRACE is also missing module autoload with NFPROTO_IPV6. + +This results in ip6tables failing to restore a ruleset. This issue has been +reported by several users providing incomplete patches. + +Very similar to Ilya Katsnelson's patch including a missing chunk in the +TRACE extension. + +Fixes: 0bfcb7b71e73 ("netfilter: xtables: avoid NFPROTO_UNSPEC where needed") +Reported-by: Ignat Korchagin +Reported-by: Ilya Katsnelson +Reported-by: Krzysztof Olędzki +Signed-off-by: Pablo Neira Ayuso +Signed-off-by: Sasha Levin +--- + net/netfilter/xt_NFLOG.c | 2 +- + net/netfilter/xt_TRACE.c | 1 + + net/netfilter/xt_mark.c | 2 +- + 3 files changed, 3 insertions(+), 2 deletions(-) + +diff --git a/net/netfilter/xt_NFLOG.c b/net/netfilter/xt_NFLOG.c +index d80abd6cc..6dcf4bc7e 100644 +--- a/net/netfilter/xt_NFLOG.c ++++ b/net/netfilter/xt_NFLOG.c +@@ -79,7 +79,7 @@ static struct xt_target nflog_tg_reg[] __read_mostly = { + { + .name = "NFLOG", + .revision = 0, +- .family = NFPROTO_IPV4, ++ .family = NFPROTO_IPV6, + .checkentry = nflog_tg_check, + .destroy = nflog_tg_destroy, + .target = nflog_tg, +diff --git a/net/netfilter/xt_TRACE.c b/net/netfilter/xt_TRACE.c +index f3fa4f113..a642ff09f 100644 +--- a/net/netfilter/xt_TRACE.c ++++ b/net/netfilter/xt_TRACE.c +@@ -49,6 +49,7 @@ static struct xt_target trace_tg_reg[] __read_mostly = { + .target = trace_tg, + .checkentry = trace_tg_check, + .destroy = trace_tg_destroy, ++ .me = THIS_MODULE, + }, + #endif + }; +diff --git a/net/netfilter/xt_mark.c b/net/netfilter/xt_mark.c +index f76fe04fc..65b965ca4 100644 +--- a/net/netfilter/xt_mark.c ++++ b/net/netfilter/xt_mark.c +@@ -62,7 +62,7 @@ static struct xt_target mark_tg_reg[] __read_mostly = { + { + .name = "MARK", + .revision = 2, +- .family = NFPROTO_IPV4, ++ .family = NFPROTO_IPV6, + .target = mark_tg, + .targetsize = sizeof(struct xt_mark_tginfo2), + .me = THIS_MODULE, +-- +2.45.0 + diff --git a/packages/kernel-5.15/Cargo.toml b/packages/kernel-5.15/Cargo.toml new file mode 100644 index 00000000..3a217744 --- /dev/null +++ b/packages/kernel-5.15/Cargo.toml @@ -0,0 +1,27 @@ +[package] +name = "kernel-5_15" +version = "0.1.0" +edition = "2021" +publish = false +build = "../build.rs" + +[package.metadata.build-package] +package-name = "kernel-5.15" + +[lib] +path = "../packages.rs" + +[[package.metadata.build-package.external-files]] +# Use latest-kernel-srpm-url.sh to get this. +url = "https://cdn.amazonlinux.com/blobstore/9cea3dae03703f3c4c78fcb1302eeee5fe4c07ebf53d783cf3aaf7e4f30a6d39/kernel-5.15.168-114.166.amzn2.src.rpm" +sha512 = "5b0b0e2640bb04d4868b8820781029d8148c7939802c1b4edcf580533848afe70f7c6372e6e2306dfc017d2b32120a446ada15b105f7b2fe766b9382f83937d3" +force-upstream = true + +[[package.metadata.build-package.external-files]] +# Use latest-neuron-srpm-url.sh to get this. +url = "https://yum.repos.neuron.amazonaws.com/aws-neuronx-dkms-2.18.12.0.noarch.rpm" +sha512 = "4ed92e661d0ba368eaf8f60e1a68c202062a26819231fcfd42a5ff05d20ad2f34b82b23359a88e80eea22ee5d0056ad769b6febd5d7e7b161da0e36434ba2579" +force-upstream = true + +[build-dependencies] +microcode = { path = "../microcode" } diff --git a/packages/kernel-5.15/README.md b/packages/kernel-5.15/README.md new file mode 100644 index 00000000..4cd4f58d --- /dev/null +++ b/packages/kernel-5.15/README.md @@ -0,0 +1,16 @@ +# kernel-5.15 + +This package contains the Bottlerocket Linux kernel of the 5.15 series. + + +## Testing of Configuration Changes + +Bottlerocket kernels are built in multiple flavors (e.g. cloud, bare metal) and for multiple architectures (e.g. aarch64, x86_64). +The kernel configuration for any of those combinations might change independently of the others. +Please use `tools/diff-kernel-config` from the main Bottlerocket repository to ensure the configuration for any of the combinations does not change inadvertently. +Changes that can have an effect on the resulting kernel configuration include: + +* explicit kernel configuration changes +* package updates/kernel rebases + +Reviewers on a pull request potentially changing the kernel configuration will appreciate having the report produced by `diff-kernel-config` included in the PR description. diff --git a/packages/kernel-5.15/config-bottlerocket b/packages/kernel-5.15/config-bottlerocket new file mode 100644 index 00000000..ad582803 --- /dev/null +++ b/packages/kernel-5.15/config-bottlerocket @@ -0,0 +1,216 @@ +# Because Bottlerocket does not have an initramfs, modules required to mount +# the root filesystem must be set to y. + +# The root filesystem is ext4 +CONFIG_EXT4_FS=y + +# btrfs support for compatibility +CONFIG_BTRFS_FS=m +CONFIG_BTRFS_FS_POSIX_ACL=y + +# Support for squashfs used to provide kernel headers with zstd compression +CONFIG_SQUASHFS=m +CONFIG_SQUASHFS_FILE_CACHE=y +# CONFIG_SQUASHFS_FILE_DIRECT is not set +CONFIG_SQUASHFS_DECOMP_SINGLE=y +# CONFIG_SQUASHFS_DECOMP_MULTI is not set +# CONFIG_SQUASHFS_DECOMP_MULTI_PERCPU is not set +CONFIG_SQUASHFS_XATTR=y +CONFIG_SQUASHFS_ZLIB=y +CONFIG_SQUASHFS_LZ4=y +CONFIG_SQUASHFS_LZO=y +CONFIG_SQUASHFS_XZ=y +CONFIG_SQUASHFS_ZSTD=y +# CONFIG_SQUASHFS_4K_DEVBLK_SIZE is not set +# CONFIG_SQUASHFS_EMBEDDED is not set +CONFIG_SQUASHFS_FRAGMENT_CACHE_SIZE=3 + +# NVMe support +CONFIG_BLK_DEV_NVME=y +CONFIG_NVME_CORE=y + +# Xen blkfront for Xen-based EC2 platforms +CONFIG_XEN_BLKDEV_FRONTEND=y + +# virtio for local testing with QEMU +CONFIG_VIRTIO=y +CONFIG_VIRTIO_BLK=y +CONFIG_VIRTIO_PCI=y + +# dm-verity and enabling it on the kernel command line +CONFIG_BLK_DEV_DM=y +CONFIG_DAX=y +CONFIG_DM_INIT=y +CONFIG_DM_VERITY=y + +# TCMU/LIO +CONFIG_TCM_USER2=m + +# EFI +CONFIG_EFI=y +CONFIG_EFI_STUB=y +CONFIG_EFI_MIXED=y + +# EFI video +CONFIG_FB=y +CONFIG_FB_EFI=y +CONFIG_FRAMEBUFFER_CONSOLE_DEFERRED_TAKEOVER=y + +# yama LSM for ptrace restrictions +CONFIG_SECURITY_YAMA=y + +# Do not allow SELinux to be disabled at boot. +# CONFIG_SECURITY_SELINUX_BOOTPARAM is not set + +# Do not allow SELinux to be disabled at runtime. +# CONFIG_SECURITY_SELINUX_DISABLE is not set + +# Do not allow SELinux to use `enforcing=0` behavior. +# CONFIG_SECURITY_SELINUX_DEVELOP is not set + +# Check the protection applied by the kernel for mmap and mprotect, +# rather than the protection requested by userspace. +CONFIG_SECURITY_SELINUX_CHECKREQPROT_VALUE=0 + +# Enable support for the kernel lockdown security module. +CONFIG_SECURITY_LOCKDOWN_LSM=y + +# Enable lockdown early so that if the option is present on the +# kernel command line, it can be enforced. +CONFIG_SECURITY_LOCKDOWN_LSM_EARLY=y + +# disable integrity measurement architecture +# CONFIG_IMA is not set + +# Disable SafeSetID LSM +# CONFIG_SECURITY_SAFESETID is not set + +# enable /proc/config.gz +CONFIG_IKCONFIG=y +CONFIG_IKCONFIG_PROC=y + +# kernel headers at /sys/kernel/kheaders.tar.xz +CONFIG_IKHEADERS=y + +# BTF debug info at /sys/kernel/btf/vmlinux +CONFIG_DEBUG_INFO_BTF=y + +# We don't want to extend the kernel command line with any upstream defaults; +# Bottlerocket uses a fairly custom setup that needs tight control over it. +# CONFIG_CMDLINE_EXTEND is not set + +# We don't want to unpack the initramfs passed by the bootloader. The intent of +# this option is to ensure that the built-in initramfs is used. Since we do not +# have a built-in initramfs, in practice this means we will never unpack any +# initramfs. +# +# We rely on `CONFIG_BLK_DEV_INITRD` for boot config support, so we can't just +# disable the functionality altogether. +CONFIG_INITRAMFS_FORCE=y + +# Enable ZSTD kernel image compression +CONFIG_HAVE_KERNEL_ZSTD=y +CONFIG_KERNEL_ZSTD=y +CONFIG_ZSTD_COMPRESS=y +CONFIG_ZSTD_DECOMPRESS=y +CONFIG_DECOMPRESS_ZSTD=y + +# Enable gz modules compression +# CONFIG_MODULE_COMPRESS_NONE is not set +CONFIG_MODULE_COMPRESS_GZIP=y + +# Add virtio drivers for development setups running as guests in qemu +CONFIG_VIRTIO_CONSOLE=m +CONFIG_HW_RANDOM_VIRTIO=m + +# Add support for IPMI drivers +CONFIG_IPMI_HANDLER=m + +# Add support for bootconfig +CONFIG_BOOT_CONFIG=y + +# Enables support for checkpoint/restore +CONFIG_CHECKPOINT_RESTORE=y + +# Disable user-mode helpers for BPF preload and bpfilter, since they rely on a +# more complete set of userspace libraries for the target than we want to +# depend on at kernel build time. +# CONFIG_BPF_PRELOAD_UMD is not set +# CONFIG_BPFILTER_UMH is not set + +# Disable unused filesystems. +# CONFIG_AFS_FS is not set +# CONFIG_CRAMFS is not set +# CONFIG_ECRYPT_FS is not set +# CONFIG_EXT2_FS is not set +# CONFIG_EXT3_FS is not set +CONFIG_EXT4_USE_FOR_EXT2=y +# CONFIG_GFS2_FS is not set +# CONFIG_HFS_FS is not set +# CONFIG_HFSPLUS_FS is not set +# CONFIG_JFS_FS is not set +# CONFIG_JFFS2_FS is not set +# CONFIG_NFS_V2 is not set +# CONFIG_NILFS2_FS is not set +# CONFIG_NTFS_FS is not set +# CONFIG_ROMFS_FS is not set +# CONFIG_UFS_FS is not set +# CONFIG_ZONEFS_FS is not set +# CONFIG_NTFS3_FS is not set + +# Disable unused network protocols. +# CONFIG_AF_RXRPC is not set +# CONFIG_ATM is not set +# CONFIG_CAN is not set +# CONFIG_HSR is not set +# CONFIG_IP_DCCP is not set +# CONFIG_L2TP is not set +# CONFIG_RDS is not set +# CONFIG_RFKILL is not set +# CONFIG_TIPC is not set + +# Disable USB-attached network interfaces, unused in the cloud and on server-grade hardware. +# CONFIG_USB_NET_DRIVERS is not set + +# Disable unused qdiscs +# - sch_cake targets home routers and residential links +# CONFIG_NET_SCH_CAKE is not set + +# Provide minimal iSCSI via TCP support for initiator and target mode +# initiator side +CONFIG_ISCSI_TCP=m +CONFIG_ISCSI_BOOT_SYSFS=m +CONFIG_SCSI_ISCSI_ATTRS=m +# target side +CONFIG_ISCSI_TARGET=m +# CONFIG_INFINIBAND_ISERT is not set + +# Disable panic on hung and lockup conditions by default +# CONFIG_BOOTPARAM_SOFTLOCKUP_PANIC is not set +# CONFIG_BOOTPARAM_HARDLOCKUP_PANIC is not set +# CONFIG_BOOTPARAM_HUNG_TASK_PANIC is not set + +# Disable edac driver for intel 10nm memory controllers +# CONFIG_EDAC_I10NM is not set + +# Support boot from IDE disks +CONFIG_ATA=y +CONFIG_ATA_PIIX=y +CONFIG_SCSI=y +CONFIG_BLK_DEV_SD=y + +# Mellanox network support +CONFIG_NET_SWITCHDEV=y +CONFIG_NET_VENDOR_MELLANOX=y +CONFIG_MLX5_CORE=m +CONFIG_MLX5_CORE_EN=y +CONFIG_MLX5_INFINIBAND=m +CONFIG_MLXFW=m +# CONFIG_MLX5_FPGA is not set +# CONFIG_MLX5_IPSEC is not set +# CONFIG_MLX5_CORE_IPOIB is not set +# CONFIG_MLX5_SF is not set + +# Support filesystem encryption for ext4 +CONFIG_FS_ENCRYPTION=y +CONFIG_FS_ENCRYPTION_INLINE_CRYPT=y diff --git a/packages/kernel-5.15/kernel-5.15.spec b/packages/kernel-5.15/kernel-5.15.spec new file mode 100644 index 00000000..90751b59 --- /dev/null +++ b/packages/kernel-5.15/kernel-5.15.spec @@ -0,0 +1,337 @@ +%global debug_package %{nil} + +Name: %{_cross_os}kernel-5.15 +Version: 5.15.168 +Release: 1%{?dist} +Summary: The Linux kernel +License: GPL-2.0 WITH Linux-syscall-note +URL: https://www.kernel.org/ +# Use latest-kernel-srpm-url.sh to get this. +Source0: https://cdn.amazonlinux.com/blobstore/9cea3dae03703f3c4c78fcb1302eeee5fe4c07ebf53d783cf3aaf7e4f30a6d39/kernel-5.15.168-114.166.amzn2.src.rpm +# Use latest-neuron-srpm-url.sh to get this. +Source1: https://yum.repos.neuron.amazonaws.com/aws-neuronx-dkms-2.18.12.0.noarch.rpm +Source100: config-bottlerocket + +# Neuron-related drop-ins. +Source220: neuron-sysinit.target.drop-in.conf +Source221: modprobe@neuron.service.drop-in.conf + +# Help out-of-tree module builds run `make prepare` automatically. +Patch1001: 1001-Makefile-add-prepare-target-for-external-modules.patch +# Expose tools/* targets for out-of-tree module builds. +Patch1002: 1002-Revert-kbuild-hide-tools-build-targets-from-external.patch +# Enable INITRAMFS_FORCE config option for our use case. +Patch1003: 1003-initramfs-unlink-INITRAMFS_FORCE-from-CMDLINE_-EXTEN.patch +# Increase default of sysctl net.unix.max_dgram_qlen to 512. +Patch1004: 1004-af_unix-increase-default-max_dgram_qlen-to-512.patch + +# Fix typo that breaks IPv6 via ip6tables commands +Patch1100: 1100-netfilter-xtables-fix-typo-causing-some-targets-not-.patch + +BuildRequires: bc +BuildRequires: elfutils-devel +BuildRequires: hostname +BuildRequires: kmod +BuildRequires: openssl-devel + +# CPU microcode updates are included as "extra firmware" so the files don't +# need to be installed on the root filesystem. However, we want the license and +# attribution files to be available in the usual place. +%if "%{_cross_arch}" == "x86_64" +BuildRequires: %{_cross_os}microcode +Requires: %{_cross_os}microcode-licenses +%endif + +# Pull in expected modules and development files. +Requires: %{name}-modules = %{version}-%{release} +Requires: %{name}-devel = %{version}-%{release} + +# Pull in platform-dependent modules. +%if "%{_cross_arch}" == "x86_64" +Requires: (%{name}-modules-neuron if (%{_cross_os}variant-platform(aws) without %{_cross_os}variant-flavor(nvidia))) +%endif + +# The 5.15 kernel is not FIPS certified. +Conflicts: %{_cross_os}image-feature(fips) + +# Using EROFS for the root partition requires a 6.1+ kernel. +Conflicts: %{_cross_os}image-feature(erofs-root-partition) + +%global kernel_sourcedir %{_cross_usrsrc}/kernels +%global kernel_libdir %{_cross_libdir}/modules/%{version} + +%description +%{summary}. + +%package devel +Summary: Configured Linux kernel source for module building + +%description devel +%{summary}. + +%package archive +Summary: Archived Linux kernel source for module building + +%description archive +%{summary}. + +%package modules +Summary: Modules for the Linux kernel + +%description modules +%{summary}. + +%if "%{_cross_arch}" == "x86_64" +%package modules-neuron +Summary: Modules for the Linux kernel with Neuron hardware +Requires: %{name} +Requires: %{_cross_os}ghostdog +Requires: %{_cross_os}variant-platform(aws) +Conflicts: %{_cross_os}variant-flavor(nvidia) + +%description modules-neuron +%{summary}. +%endif + +%package headers +Summary: Header files for the Linux kernel for use by glibc + +%description headers +%{summary}. + +%prep +rpm2cpio %{SOURCE0} | cpio -iu linux-%{version}.tar config-%{_cross_arch} "*.patch" +tar -xof linux-%{version}.tar; rm linux-%{version}.tar +%setup -TDn linux-%{version} +# Patches from the Source0 SRPM +for patch in ../*.patch; do + patch -p1 <"$patch" +done +# Patches listed in this spec (Patch0001...) +%autopatch -p1 + +%if "%{_cross_arch}" == "x86_64" +microcode="$(find %{_cross_libdir}/firmware -type f -path '*/*-ucode/*' -printf '%%P ')" +cat < ../config-microcode +CONFIG_EXTRA_FIRMWARE="${microcode}" +CONFIG_EXTRA_FIRMWARE_DIR="%{_cross_libdir}/firmware" +EOF +%endif + +export ARCH="%{_cross_karch}" +export CROSS_COMPILE="%{_cross_target}-" + +KCONFIG_CONFIG="arch/%{_cross_karch}/configs/%{_cross_vendor}_defconfig" \ +scripts/kconfig/merge_config.sh \ + ../config-%{_cross_arch} \ +%if "%{_cross_arch}" == "x86_64" + ../config-microcode \ +%endif + %{SOURCE100} + +rm -f ../config-* ../*.patch + +%if "%{_cross_arch}" == "x86_64" +cd %{_builddir} +rpm2cpio %{SOURCE1} | cpio -idmu './usr/src/aws-neuronx-*' +find usr/src/ -mindepth 1 -maxdepth 1 -type d -exec mv {} neuron \; +rm -r usr +%endif + +%global kmake \ +make -s\\\ + ARCH="%{_cross_karch}"\\\ + CROSS_COMPILE="%{_cross_target}-"\\\ + INSTALL_HDR_PATH="%{buildroot}%{_cross_prefix}"\\\ + INSTALL_MOD_PATH="%{buildroot}%{_cross_prefix}"\\\ + INSTALL_MOD_STRIP=1\\\ +%{nil} + +%build +%kmake mrproper +%kmake %{_cross_vendor}_defconfig +%kmake %{?_smp_mflags} %{_cross_kimage} +%kmake %{?_smp_mflags} modules + +%if "%{_cross_arch}" == "x86_64" +%kmake %{?_smp_mflags} M=%{_builddir}/neuron +%endif + +%install +%kmake %{?_smp_mflags} headers_install +%kmake %{?_smp_mflags} modules_install + +%if "%{_cross_arch}" == "x86_64" +%kmake %{?_smp_mflags} M=%{_builddir}/neuron modules_install +%endif + +install -d %{buildroot}/boot +install -T -m 0755 arch/%{_cross_karch}/boot/%{_cross_kimage} %{buildroot}/boot/vmlinuz +install -m 0644 .config %{buildroot}/boot/config + +find %{buildroot}%{_cross_prefix} \ + \( -name .install -o -name .check -o \ + -name ..install.cmd -o -name ..check.cmd \) -delete + +# For out-of-tree kmod builds, we need to support the following targets: +# make scripts -> make prepare -> make modules +# +# This requires enough of the kernel tree to build host programs under the +# "scripts" and "tools" directories. + +# Any existing ELF objects will not work properly if we're cross-compiling for +# a different architecture, so get rid of them to avoid confusing errors. +find arch scripts tools -type f -executable \ + -exec sh -c "head -c4 {} | grep -q ELF && rm {}" \; + +# We don't need to include these files. +find -type f \( -name \*.cmd -o -name \*.gitignore \) -delete + +# Avoid an OpenSSL dependency by stubbing out options for module signing and +# trusted keyrings, so `sign-file` and `extract-cert` won't be built. External +# kernel modules do not have access to the keys they would need to make use of +# these tools. +sed -i \ + -e 's,$(CONFIG_MODULE_SIG_FORMAT),n,g' \ + -e 's,$(CONFIG_SYSTEM_TRUSTED_KEYRING),n,g' \ + scripts/Makefile + +# Restrict permissions on System.map. +chmod 600 System.map + +( + find * \ + -type f \ + \( -name Build\* -o -name Kbuild\* -o -name Kconfig\* -o -name Makefile\* \) \ + -print + + find arch/%{_cross_karch}/ \ + -type f \ + \( -name module.lds -o -name vmlinux.lds.S -o -name Platform -o -name \*.tbl \) \ + -print + + find arch/%{_cross_karch}/{include,lib}/ -type f ! -name \*.o ! -name \*.o.d -print + echo arch/%{_cross_karch}/kernel/asm-offsets.s + echo lib/vdso/gettimeofday.c + + for d in \ + arch/%{_cross_karch}/tools \ + arch/%{_cross_karch}/kernel/vdso ; do + [ -d "${d}" ] && find "${d}/" -type f -print + done + + find include -type f -print + find scripts -type f ! -name \*.l ! -name \*.y ! -name \*.o -print + + find tools/{arch/%{_cross_karch},include,objtool,scripts}/ -type f ! -name \*.o -print + echo tools/build/fixdep.c + find tools/lib/subcmd -type f -print + find tools/lib/{ctype,hweight,rbtree,string,str_error_r}.c + + echo kernel/bounds.c + echo kernel/time/timeconst.bc + echo security/selinux/include/classmap.h + echo security/selinux/include/initial_sid_to_string.h + echo security/selinux/include/policycap.h + echo security/selinux/include/policycap_names.h + + echo .config + echo Module.symvers + echo System.map +) | sort -u > kernel_devel_files + +# Create squashfs of kernel-devel files (ie. /usr/src/kernels/). +# +# -no-exports: +# The filesystem does not need to be exported via NFS. +# +# -all-root: +# Make all files owned by root rather than the build user. +# +# -comp zstd: +# zstd offers compression ratios like xz and decompression speeds like lz4. +SQUASHFS_OPTS="-no-exports -all-root -comp zstd" +mkdir -p src_squashfs/%{version} +tar c -T kernel_devel_files | tar x -C src_squashfs/%{version} +mksquashfs src_squashfs kernel-devel.squashfs ${SQUASHFS_OPTS} + +# Create a tarball of the same files, for use outside the running system. +# In theory we could extract these files with `unsquashfs`, but we do not want +# to require it to be installed on the build host, and it errors out when run +# inside Docker unless the limit for open files is lowered. +tar cf kernel-devel.tar src_squashfs/%{version} --transform='s|src_squashfs/%{version}|kernel-devel|' +xz -T0 kernel-devel.tar + +install -D kernel-devel.squashfs %{buildroot}%{_cross_datadir}/bottlerocket/kernel-devel.squashfs +install -D kernel-devel.tar.xz %{buildroot}%{_cross_datadir}/bottlerocket/kernel-devel.tar.xz +install -d %{buildroot}%{kernel_sourcedir} + +# Replace the incorrect links from modules_install. These will be bound +# into a host container (and unused in the host) so they must not point +# to %{_cross_usrsrc} (eg. /x86_64-bottlerocket-linux-gnu/sys-root/...) +rm -f %{buildroot}%{kernel_libdir}/build %{buildroot}%{kernel_libdir}/source +ln -sf %{_usrsrc}/kernels/%{version} %{buildroot}%{kernel_libdir}/build +ln -sf %{_usrsrc}/kernels/%{version} %{buildroot}%{kernel_libdir}/source + +# Install a copy of System.map so that module dependencies can be regenerated. +install -p -m 0600 System.map %{buildroot}%{kernel_libdir} + +%if "%{_cross_arch}" == "x86_64" +# Add Neuron-related drop-ins to load the module when the hardware is present. +mkdir -p %{buildroot}%{_cross_unitdir}/sysinit.target.d +install -p -m 0644 %{S:220} %{buildroot}%{_cross_unitdir}/sysinit.target.d/neuron.conf + +mkdir -p %{buildroot}%{_cross_unitdir}/modprobe@neuron.service.d +install -p -m 0644 %{S:221} %{buildroot}%{_cross_unitdir}/modprobe@neuron.service.d/neuron.conf +%endif + +%files +%license COPYING LICENSES/preferred/GPL-2.0 LICENSES/exceptions/Linux-syscall-note +%{_cross_attribution_file} +/boot/vmlinuz +/boot/config + +%files modules +%dir %{_cross_libdir}/modules +%{_cross_libdir}/modules/* +%exclude %{kernel_libdir}/extra/neuron.ko.gz + +%if "%{_cross_arch}" == "x86_64" +%files modules-neuron +%{kernel_libdir}/extra/neuron.ko.gz +%{_cross_unitdir}/sysinit.target.d/neuron.conf +%{_cross_unitdir}/modprobe@neuron.service.d/neuron.conf +%endif + +%files headers +%dir %{_cross_includedir}/asm +%dir %{_cross_includedir}/asm-generic +%dir %{_cross_includedir}/drm +%dir %{_cross_includedir}/linux +%dir %{_cross_includedir}/misc +%dir %{_cross_includedir}/mtd +%dir %{_cross_includedir}/rdma +%dir %{_cross_includedir}/scsi +%dir %{_cross_includedir}/sound +%dir %{_cross_includedir}/video +%dir %{_cross_includedir}/xen +%{_cross_includedir}/asm/* +%{_cross_includedir}/asm-generic/* +%{_cross_includedir}/drm/* +%{_cross_includedir}/linux/* +%{_cross_includedir}/misc/* +%{_cross_includedir}/mtd/* +%{_cross_includedir}/rdma/* +%{_cross_includedir}/scsi/* +%{_cross_includedir}/sound/* +%{_cross_includedir}/video/* +%{_cross_includedir}/xen/* + +%files devel +%dir %{kernel_sourcedir} +%{_cross_datadir}/bottlerocket/kernel-devel.squashfs + +%files archive +%{_cross_datadir}/bottlerocket/kernel-devel.tar.xz + +%changelog diff --git a/packages/kernel-5.15/latest-kernel-srpm-url.sh b/packages/kernel-5.15/latest-kernel-srpm-url.sh new file mode 100755 index 00000000..91ba10e6 --- /dev/null +++ b/packages/kernel-5.15/latest-kernel-srpm-url.sh @@ -0,0 +1,2 @@ +#!/bin/sh +docker run --rm amazonlinux:2 sh -c 'amazon-linux-extras enable kernel-5.15 >/dev/null && yum install -q -y yum-utils && yumdownloader -q --source --urls kernel | grep ^http' diff --git a/packages/kernel-5.15/latest-neuron-srpm-url.sh b/packages/kernel-5.15/latest-neuron-srpm-url.sh new file mode 100755 index 00000000..5bb6c85e --- /dev/null +++ b/packages/kernel-5.15/latest-neuron-srpm-url.sh @@ -0,0 +1,9 @@ +#!/bin/sh +cmd=" +dnf install -q -y --releasever=latest yum-utils && +dnf download -q --repofrompath neuron,https://yum.repos.neuron.amazonaws.com --repo=neuron --urls aws-neuronx-dkms +" +docker run --rm amazonlinux:2023 bash -c "${cmd}" \ + | grep '^http' \ + | xargs --max-args=1 --no-run-if-empty realpath --canonicalize-missing --relative-to=. \ + | sed 's_:/_://_' diff --git a/packages/kernel-5.15/modprobe@neuron.service.drop-in.conf b/packages/kernel-5.15/modprobe@neuron.service.drop-in.conf new file mode 100644 index 00000000..e9174355 --- /dev/null +++ b/packages/kernel-5.15/modprobe@neuron.service.drop-in.conf @@ -0,0 +1,7 @@ +[Unit] +ConditionPathExists=!/etc/.neuron-modprobe-done + +[Service] +ExecCondition=/usr/bin/touch /etc/.neuron-modprobe-done +ExecCondition=/usr/bin/ghostdog neuron-present +RemainAfterExit=true diff --git a/packages/kernel-5.15/neuron-sysinit.target.drop-in.conf b/packages/kernel-5.15/neuron-sysinit.target.drop-in.conf new file mode 100644 index 00000000..11c78234 --- /dev/null +++ b/packages/kernel-5.15/neuron-sysinit.target.drop-in.conf @@ -0,0 +1,2 @@ +[Unit] +Wants=modprobe@neuron.service diff --git a/packages/kernel-6.1/.gitignore b/packages/kernel-6.1/.gitignore new file mode 100644 index 00000000..e7a9c134 --- /dev/null +++ b/packages/kernel-6.1/.gitignore @@ -0,0 +1 @@ +*.rpm diff --git a/packages/kernel-6.1/1001-Makefile-add-prepare-target-for-external-modules.patch b/packages/kernel-6.1/1001-Makefile-add-prepare-target-for-external-modules.patch new file mode 100644 index 00000000..84f46d63 --- /dev/null +++ b/packages/kernel-6.1/1001-Makefile-add-prepare-target-for-external-modules.patch @@ -0,0 +1,55 @@ +From e6e9b5adc830c0924d81c348c8d5b12e3dc4242e Mon Sep 17 00:00:00 2001 +From: Ben Cressey +Date: Mon, 19 Apr 2021 18:46:04 +0000 +Subject: [PATCH] Makefile: add prepare target for external modules + +We need to ensure that native versions of programs like `objtool` are +built before trying to build out-of-tree modules, or else the build +will fail. + +Unlike other distributions, we cannot include these programs in our +kernel-devel archive, because we rely on cross-compilation: these are +"host" programs and may not match the architecture of the target. + +Ideally, out-of-tree builds would run `make prepare` first, so that +these programs could be compiled in the normal fashion. We ship all +the files needed for this to work. However, this requirement is +specific to our use case, and DKMS does not support it. + +Adding a minimal prepare target to the dependency graph causes the +programs to be built automatically and improves compatibility with +existing solutions. + +Signed-off-by: Ben Cressey +Signed-off-by: Arnaldo Garcia Rincon +--- + Makefile | 13 +++++++++++++ + 1 file changed, 13 insertions(+) + +diff --git a/Makefile b/Makefile +index 23390805e..2f78ac123 100644 +--- a/Makefile ++++ b/Makefile +@@ -1874,6 +1874,19 @@ else # KBUILD_EXTMOD + KBUILD_BUILTIN := + KBUILD_MODULES := 1 + ++PHONY += modules_prepare ++modules_prepare: ++ $(Q)$(MAKE) $(build)=scripts/basic ++ $(Q)$(MAKE) $(build)=scripts/dtc ++ $(Q)$(MAKE) $(build)=scripts/mod ++ $(Q)$(MAKE) $(build)=scripts ++ ++ifdef CONFIG_OBJTOOL ++prepare: tools/objtool ++endif ++ ++prepare: modules_prepare ++ + build-dir := $(KBUILD_EXTMOD) + + compile_commands.json: $(extmod_prefix)compile_commands.json +-- +2.40.0 + diff --git a/packages/kernel-6.1/1002-Revert-kbuild-hide-tools-build-targets-from-external.patch b/packages/kernel-6.1/1002-Revert-kbuild-hide-tools-build-targets-from-external.patch new file mode 100644 index 00000000..ef333085 --- /dev/null +++ b/packages/kernel-6.1/1002-Revert-kbuild-hide-tools-build-targets-from-external.patch @@ -0,0 +1,64 @@ +From 05a7163507930b56804896818c80e92a2454ef4d Mon Sep 17 00:00:00 2001 +From: Arnaldo Garcia Rincon +Date: Wed, 22 Jun 2022 19:26:43 +0000 +Subject: [PATCH] Revert "kbuild: hide tools/ build targets from external + module builds" + +This reverts commit 1bb0b18a06dceee1fdc32161a72e28eab6f011c4 in which +the targets to build "tools/*" were hidden for external modules, but +they are required by the kmod kit since the 'tools/*' binaries are not +distributed as part of the archive. + +Signed-off-by: Arnaldo Garcia Rincon +--- + Makefile | 27 ++++++++++++++------------- + 1 file changed, 14 insertions(+), 13 deletions(-) + +diff --git a/Makefile b/Makefile +index 346b898eb..e3d39f7c3 100644 +--- a/Makefile ++++ b/Makefile +@@ -1421,19 +1421,6 @@ ifneq ($(wildcard $(resolve_btfids_O)),) + $(Q)$(MAKE) -sC $(srctree)/tools/bpf/resolve_btfids O=$(resolve_btfids_O) clean + endif + +-# Clear a bunch of variables before executing the submake +-ifeq ($(quiet),silent_) +-tools_silent=s +-endif +- +-tools/: FORCE +- $(Q)mkdir -p $(objtree)/tools +- $(Q)$(MAKE) LDFLAGS= MAKEFLAGS="$(tools_silent) $(filter --j% -j,$(MAKEFLAGS))" O=$(abspath $(objtree)) subdir=tools -C $(srctree)/tools/ +- +-tools/%: FORCE +- $(Q)mkdir -p $(objtree)/tools +- $(Q)$(MAKE) LDFLAGS= MAKEFLAGS="$(tools_silent) $(filter --j% -j,$(MAKEFLAGS))" O=$(abspath $(objtree)) subdir=tools -C $(srctree)/tools/ $* +- + # --------------------------------------------------------------------------- + # Kernel selftest + +@@ -2124,6 +2111,20 @@ kernelversion: + image_name: + @echo $(KBUILD_IMAGE) + ++# Clear a bunch of variables before executing the submake ++ ++ifeq ($(quiet),silent_) ++tools_silent=s ++endif ++ ++tools/: FORCE ++ $(Q)mkdir -p $(objtree)/tools ++ $(Q)$(MAKE) LDFLAGS= MAKEFLAGS="$(tools_silent) $(filter --j% -j,$(MAKEFLAGS))" O=$(abspath $(objtree)) subdir=tools -C $(srctree)/tools/ ++ ++tools/%: FORCE ++ $(Q)mkdir -p $(objtree)/tools ++ $(Q)$(MAKE) LDFLAGS= MAKEFLAGS="$(tools_silent) $(filter --j% -j,$(MAKEFLAGS))" O=$(abspath $(objtree)) subdir=tools -C $(srctree)/tools/ $* ++ + quiet_cmd_rmfiles = $(if $(wildcard $(rm-files)),CLEAN $(wildcard $(rm-files))) + cmd_rmfiles = rm -rf $(rm-files) + +-- +2.39.1 + diff --git a/packages/kernel-6.1/1003-initramfs-unlink-INITRAMFS_FORCE-from-CMDLINE_-EXTEN.patch b/packages/kernel-6.1/1003-initramfs-unlink-INITRAMFS_FORCE-from-CMDLINE_-EXTEN.patch new file mode 100644 index 00000000..ce4578b7 --- /dev/null +++ b/packages/kernel-6.1/1003-initramfs-unlink-INITRAMFS_FORCE-from-CMDLINE_-EXTEN.patch @@ -0,0 +1,50 @@ +From 002d1909e18b7ca876edd4680ffcf8b59dea6c1b Mon Sep 17 00:00:00 2001 +From: Ben Cressey +Date: Tue, 18 Oct 2022 22:24:52 +0000 +Subject: [PATCH] initramfs: unlink INITRAMFS_FORCE from CMDLINE_{EXTEND,FORCE} + +The motivation given in cff75e0b6fe83 for tying INITRAMFS_FORCE to +either of CMDLINE_{EXTEND,FORCE} was that these options imply an +inflexible bootloader, and that overriding the initramfs image would +also only be necessary for inflexible bootloaders. + +However, with the advent of Boot Config support, distributions that do +not normally use an initramfs may still want to allow an "initrd" to be +passed by the bootloader in order to accept boot configuration data. In +such cases, the CMDLINE_{EXTEND,FORCE} options are not desired because +the bootloader is actually expected to control the kernel command line. + +Unlinking the INITRAMFS_FORCE config option allows Boot Config data to +be passed by the bootloader while still preventing an unexpected +initramfs from overriding the built-in initramfs (if any). + +Signed-off-by: Ben Cressey +--- + usr/Kconfig | 4 +++- + 1 file changed, 3 insertions(+), 1 deletion(-) + +diff --git a/usr/Kconfig b/usr/Kconfig +index 8bbcf699f..06aac1906 100644 +--- a/usr/Kconfig ++++ b/usr/Kconfig +@@ -24,7 +24,7 @@ config INITRAMFS_SOURCE + + config INITRAMFS_FORCE + bool "Ignore the initramfs passed by the bootloader" +- depends on CMDLINE_EXTEND || CMDLINE_FORCE ++ default n + help + This option causes the kernel to ignore the initramfs image + (or initrd image) passed to it by the bootloader. This is +@@ -32,6 +32,8 @@ config INITRAMFS_FORCE + and is useful if you cannot or don't want to change the image + your bootloader passes to the kernel. + ++ If unsure, say N. ++ + config INITRAMFS_ROOT_UID + int "User ID to map to 0 (user root)" + depends on INITRAMFS_SOURCE!="" +-- +2.39.1 + diff --git a/packages/kernel-6.1/1004-af_unix-increase-default-max_dgram_qlen-to-512.patch b/packages/kernel-6.1/1004-af_unix-increase-default-max_dgram_qlen-to-512.patch new file mode 100644 index 00000000..57eb6758 --- /dev/null +++ b/packages/kernel-6.1/1004-af_unix-increase-default-max_dgram_qlen-to-512.patch @@ -0,0 +1,47 @@ +From 1faecf19a86dbb29b62607b1740ef59a5c35acb2 Mon Sep 17 00:00:00 2001 +From: Markus Boehme +Date: Tue, 23 May 2023 17:16:44 +0000 +Subject: [PATCH] af_unix: increase default max_dgram_qlen to 512 + +The net.unix.max_dgram_qlen sysctl has been defined with a default value of +10 since before the current Git history started in 2005. Systems have more +resources these days, and while the default values for other sysctls like +net.core.somaxconn have been adapted, max_dgram_qlen never was. + +Increase the default value for max_dgram_qlen to 512. A large number of +hosts effectively already run with this or a larger value, since systemd +has been making sure it is set to at least 512 since 2015. + +Signed-off-by: Markus Boehme +--- + Documentation/networking/ip-sysctl.rst | 2 +- + net/unix/af_unix.c | 2 +- + 2 files changed, 2 insertions(+), 2 deletions(-) + +diff --git a/Documentation/networking/ip-sysctl.rst b/Documentation/networking/ip-sysctl.rst +index e7b3fa7bb..f20837a92 100644 +--- a/Documentation/networking/ip-sysctl.rst ++++ b/Documentation/networking/ip-sysctl.rst +@@ -3038,5 +3038,5 @@ ecn_enable - BOOLEAN + max_dgram_qlen - INTEGER + The maximum length of dgram socket receive queue + +- Default: 10 ++ Default: 512 + +diff --git a/net/unix/af_unix.c b/net/unix/af_unix.c +index f0c2293f1..3962a66c5 100644 +--- a/net/unix/af_unix.c ++++ b/net/unix/af_unix.c +@@ -3600,7 +3600,7 @@ static int __net_init unix_net_init(struct net *net) + { + int i; + +- net->unx.sysctl_max_dgram_qlen = 10; ++ net->unx.sysctl_max_dgram_qlen = 512; + if (unix_sysctl_register(net)) + goto out; + +-- +2.40.0 + diff --git a/packages/kernel-6.1/1005-Revert-Revert-drm-fb_helper-improve-CONFIG_FB-depend.patch b/packages/kernel-6.1/1005-Revert-Revert-drm-fb_helper-improve-CONFIG_FB-depend.patch new file mode 100644 index 00000000..01a3d1b8 --- /dev/null +++ b/packages/kernel-6.1/1005-Revert-Revert-drm-fb_helper-improve-CONFIG_FB-depend.patch @@ -0,0 +1,36 @@ +From 97942a7563e670dbc481a322b34f29010a1ed9ec Mon Sep 17 00:00:00 2001 +From: Leonard Foerster +Date: Fri, 11 Aug 2023 06:41:44 +0000 +Subject: [PATCH] Revert "Revert "drm: fb_helper: improve CONFIG_FB + dependency"" + +This reverts commit 9200a3864170e49e8d076870ee18fad6de4fd356. + +Amazon Linux has reverted this upstream commit in order to have +certain DRM options set to allow building nvidia DKMS. Instead +of reverting an upstream commit, we added DRM_SIMPLEDRM with +Bottlerocket commit fd73bff24a78 in order to supply the necessary +dependecies for nvidia drivers. +--- + drivers/gpu/drm/Kconfig | 5 ++--- + 1 file changed, 2 insertions(+), 3 deletions(-) + +diff --git a/drivers/gpu/drm/Kconfig b/drivers/gpu/drm/Kconfig +index e0264211ca84..f30f99166531 100644 +--- a/drivers/gpu/drm/Kconfig ++++ b/drivers/gpu/drm/Kconfig +@@ -124,9 +124,8 @@ config DRM_DEBUG_MODESET_LOCK + + config DRM_FBDEV_EMULATION + bool "Enable legacy fbdev support for your modesetting driver" +- depends on DRM +- depends on FB=y || FB=DRM +- select DRM_KMS_HELPER ++ depends on DRM_KMS_HELPER ++ depends on FB=y || FB=DRM_KMS_HELPER + select FB_CFB_FILLRECT + select FB_CFB_COPYAREA + select FB_CFB_IMAGEBLIT +-- +2.40.1 + diff --git a/packages/kernel-6.1/Cargo.toml b/packages/kernel-6.1/Cargo.toml new file mode 100644 index 00000000..140c0a31 --- /dev/null +++ b/packages/kernel-6.1/Cargo.toml @@ -0,0 +1,27 @@ +[package] +name = "kernel-6_1" +version = "0.1.0" +edition = "2021" +publish = false +build = "../build.rs" + +[package.metadata.build-package] +package-name = "kernel-6.1" + +[lib] +path = "../packages.rs" + +[[package.metadata.build-package.external-files]] +# Use latest-kernel-srpm-url.sh to get this. +url = "https://cdn.amazonlinux.com/al2023/blobstore/c5625ba4f37a38809773fa50b769735602f1e4e50d60cb7127ed6231d0695e95/kernel-6.1.119-129.201.amzn2023.src.rpm" +sha512 = "258a96b9216c187352405f856d69d0fd7edb2e9c89066ad098c9e50bbdfc0c13c666d74fe8b919fa5ffa03dc9f802bff454b03e7f455cf2d3d92a4a66c7d4987" +force-upstream = true + +[[package.metadata.build-package.external-files]] +# Use latest-neuron-srpm-url.sh to get this. +url = "https://yum.repos.neuron.amazonaws.com/aws-neuronx-dkms-2.18.12.0.noarch.rpm" +sha512 = "4ed92e661d0ba368eaf8f60e1a68c202062a26819231fcfd42a5ff05d20ad2f34b82b23359a88e80eea22ee5d0056ad769b6febd5d7e7b161da0e36434ba2579" +force-upstream = true + +[build-dependencies] +microcode = { path = "../microcode" } diff --git a/packages/kernel-6.1/README.md b/packages/kernel-6.1/README.md new file mode 100644 index 00000000..a999af73 --- /dev/null +++ b/packages/kernel-6.1/README.md @@ -0,0 +1,16 @@ +# kernel-6.1 + +This package contains the Bottlerocket Linux kernel of the 6.1 series. + + +## Testing of Configuration Changes + +Bottlerocket kernels are built in multiple flavors (e.g. cloud, bare metal) and for multiple architectures (e.g. aarch64, x86_64). +The kernel configuration for any of those combinations might change independently of the others. +Please use `tools/diff-kernel-config` from the main Bottlerocket repository to ensure the configuration for any of the combinations does not change inadvertently. +Changes that can have an effect on the resulting kernel configuration include: + +* explicit kernel configuration changes +* package updates/kernel rebases + +Reviewers on a pull request potentially changing the kernel configuration will appreciate having the report produced by `diff-kernel-config` included in the PR description. diff --git a/packages/kernel-6.1/bootconfig-aws.conf b/packages/kernel-6.1/bootconfig-aws.conf new file mode 100644 index 00000000..90bd5c25 --- /dev/null +++ b/packages/kernel-6.1/bootconfig-aws.conf @@ -0,0 +1,2 @@ +kernel.initcall_blacklist = vmd_drv_init, megasas_init, mpt3sas_init, pqi_init +kernel.module_blacklist = i8042 diff --git a/packages/kernel-6.1/bootconfig-metal.conf b/packages/kernel-6.1/bootconfig-metal.conf new file mode 100644 index 00000000..e69de29b diff --git a/packages/kernel-6.1/bootconfig-vmware.conf b/packages/kernel-6.1/bootconfig-vmware.conf new file mode 100644 index 00000000..8d7ae016 --- /dev/null +++ b/packages/kernel-6.1/bootconfig-vmware.conf @@ -0,0 +1 @@ +kernel.initcall_blacklist = vmd_drv_init, megasas_init, mpt3sas_init, pqi_init diff --git a/packages/kernel-6.1/check-fips-modules.drop-in.conf.in b/packages/kernel-6.1/check-fips-modules.drop-in.conf.in new file mode 100644 index 00000000..c5585479 --- /dev/null +++ b/packages/kernel-6.1/check-fips-modules.drop-in.conf.in @@ -0,0 +1,3 @@ +[Unit] +Requires=fips-modprobe@__FIPS_MODULE__.service +After=fips-modprobe@__FIPS_MODULE__.service diff --git a/packages/kernel-6.1/config-bottlerocket b/packages/kernel-6.1/config-bottlerocket new file mode 100644 index 00000000..260d6abe --- /dev/null +++ b/packages/kernel-6.1/config-bottlerocket @@ -0,0 +1,365 @@ +# Because Bottlerocket does not have an initramfs, modules required to mount +# the root filesystem must be set to y. + +# The root filesystem is ext4 or erofs +CONFIG_EXT4_FS=y +CONFIG_EROFS_FS=y + +# btrfs support for compatibility +CONFIG_BTRFS_FS=m +CONFIG_BTRFS_FS_POSIX_ACL=y + +# Support for squashfs used to provide kernel headers with zstd compression +CONFIG_SQUASHFS=m +CONFIG_SQUASHFS_FILE_CACHE=y +# CONFIG_SQUASHFS_FILE_DIRECT is not set +CONFIG_SQUASHFS_DECOMP_SINGLE=y +# CONFIG_SQUASHFS_DECOMP_MULTI is not set +# CONFIG_SQUASHFS_DECOMP_MULTI_PERCPU is not set +CONFIG_SQUASHFS_XATTR=y +CONFIG_SQUASHFS_ZLIB=y +CONFIG_SQUASHFS_LZ4=y +CONFIG_SQUASHFS_LZO=y +CONFIG_SQUASHFS_XZ=y +CONFIG_SQUASHFS_ZSTD=y +# CONFIG_SQUASHFS_4K_DEVBLK_SIZE is not set +# CONFIG_SQUASHFS_EMBEDDED is not set +CONFIG_SQUASHFS_FRAGMENT_CACHE_SIZE=3 + +# NVMe support +CONFIG_BLK_DEV_NVME=y +CONFIG_NVME_CORE=y + +# Xen blkfront for Xen-based EC2 platforms +CONFIG_XEN_BLKDEV_FRONTEND=y + +# virtio for local testing with QEMU +CONFIG_VIRTIO=y +CONFIG_VIRTIO_BLK=y +CONFIG_VIRTIO_PCI=y + +# Support for virtio scsi boot devices for other cloud providers +CONFIG_SCSI_VIRTIO=y + +# IDE, SCSI, and SATA disks +CONFIG_ATA=y +CONFIG_ATA_PIIX=y +CONFIG_SCSI=y +CONFIG_BLK_DEV_SD=y +CONFIG_SATA_AHCI=y + +# Disable specific SCSI drivers. +# CONFIG_SCSI_MPI3MR is not set + +# LSI Logic's SAS based RAID controllers +CONFIG_SCSI_MPT3SAS=y +CONFIG_MEGARAID_SAS=y + +# Microsemi PQI controllers +CONFIG_SCSI_SMARTPQI=y + +# Intel Volume Management Device driver, to support boot disks in a separate +# PCI domain. +CONFIG_VMD=y + +# dm-verity and enabling it on the kernel command line +CONFIG_BLK_DEV_DM=y +CONFIG_DAX=y +CONFIG_DM_INIT=y +CONFIG_DM_VERITY=y + +# TCMU/LIO +CONFIG_TCM_USER2=m + +# EFI +CONFIG_EFI=y +CONFIG_EFI_STUB=y +CONFIG_EFI_MIXED=y + +# EFI video +CONFIG_FB=y +CONFIG_FB_EFI=y +CONFIG_FRAMEBUFFER_CONSOLE_DEFERRED_TAKEOVER=y + +# yama LSM for ptrace restrictions +CONFIG_SECURITY_YAMA=y + +# Do not allow SELinux to be disabled at boot. +# CONFIG_SECURITY_SELINUX_BOOTPARAM is not set + +# Do not allow SELinux to be disabled at runtime. +# CONFIG_SECURITY_SELINUX_DISABLE is not set + +# Do not allow SELinux to use `enforcing=0` behavior. +# CONFIG_SECURITY_SELINUX_DEVELOP is not set + +# Check the protection applied by the kernel for mmap and mprotect, +# rather than the protection requested by userspace. +CONFIG_SECURITY_SELINUX_CHECKREQPROT_VALUE=0 + +# Enable support for the kernel lockdown security module. +CONFIG_SECURITY_LOCKDOWN_LSM=y + +# Enable lockdown early so that if the option is present on the +# kernel command line, it can be enforced. +CONFIG_SECURITY_LOCKDOWN_LSM_EARLY=y + +# disable integrity measurement architecture +# CONFIG_IMA is not set + +# Disable SafeSetID LSM +# CONFIG_SECURITY_SAFESETID is not set + +# enable /proc/config.gz +CONFIG_IKCONFIG=y +CONFIG_IKCONFIG_PROC=y + +# kernel headers at /sys/kernel/kheaders.tar.xz +CONFIG_IKHEADERS=y + +# BTF debug info at /sys/kernel/btf/vmlinux +CONFIG_DEBUG_INFO_BTF=y + +# We don't want to extend the kernel command line with any upstream defaults; +# Bottlerocket uses a fairly custom setup that needs tight control over it. +# CONFIG_CMDLINE_EXTEND is not set + +# We don't want to unpack the initramfs passed by the bootloader. The intent of +# this option is to ensure that the built-in initramfs is used. Since we do not +# have a built-in initramfs, in practice this means we will never unpack any +# initramfs. +# +# We rely on `CONFIG_BLK_DEV_INITRD` for boot config support, so we can't just +# disable the functionality altogether. +CONFIG_INITRAMFS_FORCE=y + +# Enable ZSTD kernel image compression +CONFIG_HAVE_KERNEL_ZSTD=y +CONFIG_KERNEL_ZSTD=y +CONFIG_ZSTD_COMPRESS=y +CONFIG_ZSTD_DECOMPRESS=y +CONFIG_DECOMPRESS_ZSTD=y + +# Enable gz modules compression +# CONFIG_MODULE_COMPRESS_NONE is not set +CONFIG_MODULE_COMPRESS_GZIP=y + +# Support handling of compressed firmware +CONFIG_FW_LOADER_COMPRESS=y +# CONFIG_FW_LOADER_COMPRESS_XZ is not set +CONFIG_FW_LOADER_COMPRESS_ZSTD=y + +# Add virtio drivers for development setups running as guests in qemu +CONFIG_VIRTIO_CONSOLE=m +CONFIG_HW_RANDOM_VIRTIO=m + +# Add support for IPMI drivers +CONFIG_IPMI_HANDLER=m + +# Add support for bootconfig +CONFIG_BOOT_CONFIG=y + +# Enables support for checkpoint/restore +CONFIG_CHECKPOINT_RESTORE=y + +# Disable user-mode helper for bpfilter, since it relies on a more complete set +# of userspace libraries for the target than we want to depend on at kernel +# build time. +# CONFIG_BPFILTER_UMH is not set + +# Disable unused filesystems. +# CONFIG_AFS_FS is not set +# CONFIG_CRAMFS is not set +# CONFIG_ECRYPT_FS is not set +# CONFIG_EXT2_FS is not set +# CONFIG_EXT3_FS is not set +CONFIG_EXT4_USE_FOR_EXT2=y +# CONFIG_GFS2_FS is not set +# CONFIG_HFS_FS is not set +# CONFIG_HFSPLUS_FS is not set +# CONFIG_JFS_FS is not set +# CONFIG_JFFS2_FS is not set +# CONFIG_NFS_V2 is not set +# CONFIG_NILFS2_FS is not set +# CONFIG_NTFS_FS is not set +# CONFIG_ROMFS_FS is not set +# CONFIG_UFS_FS is not set +# CONFIG_ZONEFS_FS is not set +# CONFIG_NTFS3_FS is not set + +# Disable unused network protocols. +# CONFIG_AF_RXRPC is not set +# CONFIG_ATM is not set +# CONFIG_CAN is not set +# CONFIG_HSR is not set +# CONFIG_IP_DCCP is not set +# CONFIG_L2TP is not set +# CONFIG_RDS is not set +# CONFIG_RFKILL is not set +# CONFIG_TIPC is not set + +# Disable USB-attached network interfaces, unused in the cloud and on server-grade hardware. +# CONFIG_USB_NET_DRIVERS is not set + +# Disable unused qdiscs +# - sch_cake targets home routers and residential links +# CONFIG_NET_SCH_CAKE is not set + +# Provide minimal iSCSI via TCP support for initiator and target mode +# initiator side +CONFIG_ISCSI_TCP=m +CONFIG_ISCSI_BOOT_SYSFS=m +CONFIG_SCSI_ISCSI_ATTRS=m +# target side +CONFIG_ISCSI_TARGET=m +# CONFIG_INFINIBAND_ISERT is not set + +# Disable DAMON subsystem. We currently do not have a good use-case for DAMON. +# CONFIG_DAMON is not set + +# Load i8042 controller, keyboard, and mouse as modules, to avoid waiting for +# them before mounting the root device. +CONFIG_SERIO_I8042=m +CONFIG_KEYBOARD_ATKBD=m +CONFIG_MOUSE_PS2=m +# CONFIG_MOUSE_PS2_ALPS is not set +# CONFIG_MOUSE_PS2_BYD is not set +# CONFIG_MOUSE_PS2_CYPRESS is not set +# CONFIG_MOUSE_PS2_ELANTECH is not set +# CONFIG_MOUSE_PS2_FOCALTECH is not set +# CONFIG_MOUSE_PS2_LIFEBOOK is not set +# CONFIG_MOUSE_PS2_LOGIPS2PP is not set +# CONFIG_MOUSE_PS2_SENTELIC is not set +# CONFIG_MOUSE_PS2_SYNAPTICS is not set +# CONFIG_MOUSE_PS2_SYNAPTICS_SMBUS is not set +# CONFIG_MOUSE_PS2_TOUCHKIT is not set +# CONFIG_MOUSE_PS2_TRACKPOINT is not set +# CONFIG_MOUSE_PS2_VMMOUSE is not set + +# Disable unnecessary framebuffer/drm drivers +# CONFIG_DRM_BOCHS is not set +# CONFIG_SYSFB_SIMPLEFB is not set + +# With 6.1 some of the functionalities used by the nvidia driver have moved behind +# some extra config options CONFIG_DRM_KMS_HELPER and CONFIG_DRM_DISPLAY_HELPER. +# These config options can not be selected individually, but are selected by certain +# drivers. Enable the SIMPLEDRM driver, which is a minimal drm driver enabling +# those helpers for platform provided framebuffers. +CONFIG_DRM_SIMPLEDRM=m + +# =^..^= =^..^= =^..^= =^..^= =^..^= =^..^= =^..^= =^..^= =^..^= + +# Enable various network vendors for bare metal usage. + +# Mellanox network support +CONFIG_NET_SWITCHDEV=y +CONFIG_NET_VENDOR_MELLANOX=y +CONFIG_MLX5_CORE=m +CONFIG_MLX5_CORE_EN=y +CONFIG_MLX5_INFINIBAND=m +CONFIG_MLXFW=m + +# AMD network support +CONFIG_NET_VENDOR_AMD=y +CONFIG_AMD_XGBE=m +# CONFIG_AMD_XGBE_DCB is not set + +# Broadcom network support +CONFIG_NET_VENDOR_BROADCOM=y +CONFIG_TIGON3_HWMON=y +CONFIG_TIGON3=m +CONFIG_BNX2X=m +CONFIG_BNX2X_SRIOV=y +CONFIG_BNXT=m + +# Chelsio network support +CONFIG_NET_VENDOR_CHELSIO=y +CONFIG_CHELSIO_T4=m +CONFIG_CHELSIO_T4VF=m +# CONFIG_CHELSIO_T4_DCB is not set +# CONFIG_CHELSIO_INLINE_CRYPTO is not set +# CONFIG_INFINIBAND_CXGB4 is not set +# CONFIG_ISCSI_TARGET_CXGB4 is not set + +# Cisco UCS network support +CONFIG_NET_VENDOR_CISCO=y +CONFIG_ENIC=m +CONFIG_INFINIBAND_USNIC=m + +# Emulex network support +CONFIG_NET_VENDOR_EMULEX=y +CONFIG_BE2NET=m +CONFIG_BE2NET_BE2=y +CONFIG_BE2NET_BE3=y +CONFIG_BE2NET_LANCER=y +CONFIG_BE2NET_SKYHAWK=y +CONFIG_BE2NET_HWMON=y + +# Huawei network support +CONFIG_NET_VENDOR_HUAWEI=y +CONFIG_HINIC=m + +# Intel network support +CONFIG_NET_VENDOR_INTEL=y +CONFIG_E1000=m +CONFIG_E1000E=m +CONFIG_E1000E_HWTS=y +CONFIG_IGB=m +CONFIG_IGB_HWMON=y +CONFIG_IGBVF=m + +# Intel 10G network support +CONFIG_I40E=m +# CONFIG_I40E_DCB is not set +CONFIG_ICE=m +# CONFIG_ICE_HWTS is not set +# CONFIG_ICE_SWITCHDEV is not set +# CONFIG_INFINIBAND_IRDMA is not set +CONFIG_PLDMFW=y +CONFIG_IXGB=m +CONFIG_IXGBE=m +CONFIG_IXGBE_HWMON=y +CONFIG_IXGBE_DCB=y +CONFIG_IXGBEVF=m +CONFIG_FM10K=m + +# Myricom network support +CONFIG_NET_VENDOR_MYRI=y +CONFIG_MYRI10GE=m +CONFIG_MYRI10GE_DCA=y + +# Pensando network support +CONFIG_NET_VENDOR_PENSANDO=y +CONFIG_IONIC=m + +# Solarflare network support +CONFIG_NET_VENDOR_SOLARFLARE=y +CONFIG_SFC=m +CONFIG_SFC_SRIOV=y +# CONFIG_SFC_MCDI_LOGGING is not set +CONFIG_SFC_MCDI_MON=y +CONFIG_SFC_FALCON=m + +# QLogic network support +CONFIG_NET_VENDOR_QLOGIC=y +CONFIG_QED=m +CONFIG_QED_SRIOV=y +CONFIG_QEDE=m +# CONFIG_INFINIBAND_QEDR is not set +# CONFIG_QEDF is not set +# CONFIG_QEDI is not set +# CONFIG_QLA3XXX is not set +CONFIG_QLCNIC=m +CONFIG_QLCNIC_SRIOV=y +# CONFIG_QLCNIC_DCB is not set +# CONFIG_QLCNIC_HWMON is not set +# CONFIG_NETXEN_NIC is not set + +# Cisco UCS HBA support +CONFIG_FCOE_FNIC=m +CONFIG_SCSI_SNIC=m + +# Disable virtio drivers unused in Bottlerocket +# CONFIG_DRM_VIRTIO_GPU is not set +# CONFIG_VIRTIO_DMA_SHARED_BUFFER is not set + diff --git a/packages/kernel-6.1/fipsmodules-aarch64 b/packages/kernel-6.1/fipsmodules-aarch64 new file mode 100644 index 00000000..16831394 --- /dev/null +++ b/packages/kernel-6.1/fipsmodules-aarch64 @@ -0,0 +1,52 @@ +sha1 +sha224 +sha256 +sha384 +sha512 +sha3-224 +sha3-256 +sha3-384 +sha3-512 +crc32c +crct10dif +ghash +xxhash64 +ghash-ce +sha1-ce +sha2-ce +sha256-arm64 +sha3-ce +sha512-arm64 +sha512-ce +cipher_null +des3_ede +aes +cfb +dh +ecdh +aes-arm64 +aes-ce-blk +aes-ce-ccm +aes-ce-cipher +aes-neon-blk +aes-neon-bs +ecb +cbc +ctr +xts +gcm +ccm +authenc +hmac +cmac +ofb +cts +lzo +essiv +seqiv +drbg +aead +cryptomgr +tcrypt +crypto_user +rsa diff --git a/packages/kernel-6.1/fipsmodules-x86_64 b/packages/kernel-6.1/fipsmodules-x86_64 new file mode 100644 index 00000000..a674fe57 --- /dev/null +++ b/packages/kernel-6.1/fipsmodules-x86_64 @@ -0,0 +1,44 @@ +sha1 +sha224 +sha256 +sha384 +sha512 +sha3-224 +sha3-256 +sha3-384 +sha3-512 +crc32c +crct10dif +ghash +xxhash64 +ghash_clmulni_intel +sha1-ssse3 +sha256-ssse3 +sha512-ssse3 +cipher_null +des3_ede +aes +cfb +dh +ecdh +aesni-intel +ecb +cbc +ctr +xts +gcm +ccm +authenc +hmac +cmac +ofb +cts +lzo +essiv +seqiv +drbg +aead +cryptomgr +tcrypt +crypto_user +rsa diff --git a/packages/kernel-6.1/kernel-6.1.spec b/packages/kernel-6.1/kernel-6.1.spec new file mode 100644 index 00000000..7e083776 --- /dev/null +++ b/packages/kernel-6.1/kernel-6.1.spec @@ -0,0 +1,1433 @@ +%global debug_package %{nil} + +Name: %{_cross_os}kernel-6.1 +Version: 6.1.119 +Release: 1%{?dist} +Summary: The Linux kernel +License: GPL-2.0 WITH Linux-syscall-note +URL: https://www.kernel.org/ +# Use latest-kernel-srpm-url.sh to get this. +Source0: https://cdn.amazonlinux.com/al2023/blobstore/c5625ba4f37a38809773fa50b769735602f1e4e50d60cb7127ed6231d0695e95/kernel-6.1.119-129.201.amzn2023.src.rpm +# Use latest-neuron-srpm-url.sh to get this. +Source1: https://yum.repos.neuron.amazonaws.com/aws-neuronx-dkms-2.18.12.0.noarch.rpm + +Source100: config-bottlerocket + +# This list of FIPS modules is extracted from /etc/fipsmodules in the initramfs +# after placing AL2023 in FIPS mode. +Source200: check-fips-modules.drop-in.conf.in +Source201: fipsmodules-x86_64 +Source202: fipsmodules-aarch64 + +# Adjust kernel-devel mount behavior if not squashfs. +Source210: var-lib-kernel-devel-lower.mount.drop-in.conf.in + +# Neuron-related drop-ins. +Source220: neuron-sysinit.target.drop-in.conf +Source221: modprobe@neuron.service.drop-in.conf + +# Bootconfig snippets to adjust the default kernel command line for the platform. +Source300: bootconfig-aws.conf +Source301: bootconfig-vmware.conf +Source302: bootconfig-metal.conf + +# Help out-of-tree module builds run `make prepare` automatically. +Patch1001: 1001-Makefile-add-prepare-target-for-external-modules.patch +# Expose tools/* targets for out-of-tree module builds. +Patch1002: 1002-Revert-kbuild-hide-tools-build-targets-from-external.patch +# Enable INITRAMFS_FORCE config option for our use case. +Patch1003: 1003-initramfs-unlink-INITRAMFS_FORCE-from-CMDLINE_-EXTEN.patch +# Increase default of sysctl net.unix.max_dgram_qlen to 512. +Patch1004: 1004-af_unix-increase-default-max_dgram_qlen-to-512.patch +# Drop AL revert of upstream patch to minimize delta. The necessary dependency +# options for nvidia are instead included through DRM_SIMPLE +Patch1005: 1005-Revert-Revert-drm-fb_helper-improve-CONFIG_FB-depend.patch + +BuildRequires: bc +BuildRequires: elfutils-devel +BuildRequires: hostname +BuildRequires: kmod +BuildRequires: openssl-devel + +# CPU microcode updates are included as "extra firmware" so the files don't +# need to be installed on the root filesystem. However, we want the license and +# attribution files to be available in the usual place. +%if "%{_cross_arch}" == "x86_64" +BuildRequires: %{_cross_os}microcode +Requires: %{_cross_os}microcode-licenses +%endif + +# Pull in expected modules and development files. +Requires: %{name}-modules = %{version}-%{release} +Requires: %{name}-devel = %{version}-%{release} + +# Pull in platform-dependent boot config snippets. +Requires: (%{name}-bootconfig-aws if %{_cross_os}variant-platform(aws)) +Requires: (%{name}-bootconfig-vmware if %{_cross_os}variant-platform(vmware)) +Requires: (%{name}-bootconfig-metal if %{_cross_os}variant-platform(metal)) + +# Pull in platform-dependent modules. +Requires: (%{name}-modules-metal if %{_cross_os}variant-platform(metal)) +%if "%{_cross_arch}" == "x86_64" +Requires: (%{name}-modules-neuron if (%{_cross_os}variant-platform(aws) without %{_cross_os}variant-flavor(nvidia))) +%endif + +# Pull in FIPS-related files if needed. +Requires: (%{name}-fips if %{_cross_os}image-feature(fips)) + +%global _cross_ksrcdir %{_cross_usrsrc}/kernels +%global _cross_kmoddir %{_cross_libdir}/modules/%{version} + +%description +%{summary}. + +%package devel +Summary: Configured Linux kernel source for module building +Requires: (%{name}-devel-unpacked if %{_cross_os}image-feature(erofs-root-partition) else %{name}-devel-squashed) + +%description devel +%{summary}. + +%package devel-squashed +Summary: Configured Linux kernel source for module building (squashed) + +%description devel-squashed +%{summary}. + +%package devel-unpacked +Summary: Configured Linux kernel source for module building (unpacked) + +%description devel-unpacked +%{summary}. + +%package archive +Summary: Archived Linux kernel source for module building + +%description archive +%{summary}. + +%package bootconfig-aws +Summary: Boot config snippet for the Linux kernel on AWS + +%description bootconfig-aws +%{summary}. + +%package bootconfig-vmware +Summary: Boot config snippet for the Linux kernel on VMware + +%description bootconfig-vmware +%{summary}. + +%package bootconfig-metal +Summary: Boot config snippet for the Linux kernel on bare metal + +%description bootconfig-metal +%{summary}. + +%package modules +Summary: Modules for the Linux kernel + +%description modules +%{summary}. + +%package modules-metal +Summary: Modules for the Linux kernel on bare metal + +%description modules-metal +%{summary}. + +%if "%{_cross_arch}" == "x86_64" +%package modules-neuron +Summary: Modules for the Linux kernel with Neuron hardware +Requires: %{name} +Requires: %{_cross_os}ghostdog +Requires: %{_cross_os}variant-platform(aws) +Conflicts: %{_cross_os}variant-flavor(nvidia) + +# Previously the neuron kmod was in a separate package, so provide that +# name for backwards compatibility. +Provides: %{_cross_os}kmod-6.1-neuron + +%description modules-neuron +%{summary}. +%endif + +%package headers +Summary: Header files for the Linux kernel for use by glibc + +%description headers +%{summary}. + +%package fips +Summary: FIPS related configuration for the Linux kernel +Requires: (%{_cross_os}image-feature(fips) and %{name}) +Conflicts: %{_cross_os}image-feature(no-fips) + +%description fips +%{summary}. + +%prep +rpm2cpio %{SOURCE0} | cpio -iu linux-%{version}.tar config-%{_cross_arch} "*.patch" +tar -xof linux-%{version}.tar; rm linux-%{version}.tar +%setup -TDn linux-%{version} +# Patches from the Source0 SRPM +for patch in ../*.patch; do + patch -p1 <"$patch" +done +# Patches listed in this spec (Patch0001...) +%autopatch -p1 + +%if "%{_cross_arch}" == "x86_64" +microcode="$(find %{_cross_libdir}/firmware -type f -path '*/*-ucode/*' -printf '%%P ')" +cat < ../config-microcode +CONFIG_EXTRA_FIRMWARE="${microcode}" +CONFIG_EXTRA_FIRMWARE_DIR="%{_cross_libdir}/firmware" +EOF +%endif + +export ARCH="%{_cross_karch}" +export CROSS_COMPILE="%{_cross_target}-" + +KCONFIG_CONFIG="arch/%{_cross_karch}/configs/%{_cross_vendor}_defconfig" \ +scripts/kconfig/merge_config.sh \ + ../config-%{_cross_arch} \ +%if "%{_cross_arch}" == "x86_64" + ../config-microcode \ +%endif + %{SOURCE100} + +rm -f ../config-* ../*.patch + +%if "%{_cross_arch}" == "x86_64" +cd %{_builddir} +rpm2cpio %{SOURCE1} | cpio -idmu './usr/src/aws-neuronx-*' +find usr/src/ -mindepth 1 -maxdepth 1 -type d -exec mv {} neuron \; +rm -r usr +%endif + +%global kmake \ +make -s\\\ + ARCH="%{_cross_karch}"\\\ + CROSS_COMPILE="%{_cross_target}-"\\\ + INSTALL_HDR_PATH="%{buildroot}%{_cross_prefix}"\\\ + INSTALL_MOD_PATH="%{buildroot}%{_cross_prefix}"\\\ + INSTALL_MOD_STRIP=1\\\ +%{nil} + +%build +%kmake mrproper +%kmake %{_cross_vendor}_defconfig +%kmake %{?_smp_mflags} %{_cross_kimage} +%kmake %{?_smp_mflags} modules + +%if "%{_cross_arch}" == "x86_64" +%kmake %{?_smp_mflags} M=%{_builddir}/neuron +%endif + +%install +%kmake %{?_smp_mflags} headers_install +%kmake %{?_smp_mflags} modules_install + +%if "%{_cross_arch}" == "x86_64" +%kmake %{?_smp_mflags} M=%{_builddir}/neuron modules_install +%endif + +install -d %{buildroot}/boot +install -T -m 0755 arch/%{_cross_karch}/boot/%{_cross_kimage} %{buildroot}/boot/vmlinuz +install -m 0644 .config %{buildroot}/boot/config + +find %{buildroot}%{_cross_prefix} \ + \( -name .install -o -name .check -o \ + -name ..install.cmd -o -name ..check.cmd \) -delete + +# For out-of-tree kmod builds, we need to support the following targets: +# make scripts -> make prepare -> make modules +# +# This requires enough of the kernel tree to build host programs under the +# "scripts" and "tools" directories. + +# Any existing ELF objects will not work properly if we're cross-compiling for +# a different architecture, so get rid of them to avoid confusing errors. +find arch scripts tools -type f -executable \ + -exec sh -c "head -c4 {} | grep -q ELF && rm {}" \; + +# We don't need to include these files. +find -type f \( -name \*.cmd -o -name \*.gitignore \) -delete + +# Avoid an OpenSSL dependency by stubbing out options for module signing and +# trusted keyrings, so `sign-file` and `extract-cert` won't be built. External +# kernel modules do not have access to the keys they would need to make use of +# these tools. +sed -i \ + -e 's,$(CONFIG_MODULE_SIG_FORMAT),n,g' \ + -e 's,$(CONFIG_SYSTEM_TRUSTED_KEYRING),n,g' \ + scripts/Makefile + +# Restrict permissions on System.map. +chmod 600 System.map + +( + find * \ + -type f \ + \( -name Build\* -o -name Kbuild\* -o -name Kconfig\* -o -name Makefile\* \) \ + -print + + find arch/%{_cross_karch}/ \ + -type f \ + \( -name module.lds -o -name vmlinux.lds.S -o -name Platform -o -name \*.tbl \) \ + -print + + find arch/%{_cross_karch}/{include,lib}/ -type f ! -name \*.o ! -name \*.o.d ! -name \*.a -print + echo arch/%{_cross_karch}/kernel/asm-offsets.s + echo lib/vdso/gettimeofday.c + + for d in \ + arch/%{_cross_karch}/tools \ + arch/%{_cross_karch}/kernel/vdso ; do + [ -d "${d}" ] && find "${d}/" -type f ! -name \*.o -print + done + + find include -type f -print + find scripts -type f ! -name \*.l ! -name \*.y ! -name \*.o -print + + find tools/{arch/%{_cross_karch},include,objtool,scripts}/ -type f ! -name \*.o ! -name \*.a -print + echo tools/build/fixdep.c + find tools/lib/subcmd -type f -print + find tools/lib/{ctype,hweight,rbtree,string,str_error_r}.c + + echo kernel/bounds.c + echo kernel/time/timeconst.bc + echo security/selinux/include/classmap.h + echo security/selinux/include/initial_sid_to_string.h + echo security/selinux/include/policycap.h + echo security/selinux/include/policycap_names.h + + echo .config + echo Module.symvers + echo System.map +) | sort -u > kernel_devel_files + +# Create squashfs of kernel-devel files (ie. /usr/src/kernels/). +# +# -no-exports: +# The filesystem does not need to be exported via NFS. +# +# -all-root: +# Make all files owned by root rather than the build user. +# +# -comp zstd: +# zstd offers compression ratios like xz and decompression speeds like lz4. +SQUASHFS_OPTS="-no-exports -all-root -comp zstd" +mkdir -p src_squashfs/%{version} +tar c -T kernel_devel_files | tar x -C src_squashfs/%{version} +mksquashfs src_squashfs kernel-devel.squashfs ${SQUASHFS_OPTS} + +# Create an uncompressed set of kernel-devel files in the standard location. +install -d %{buildroot}%{_cross_datadir}/bottlerocket/kernel-devel/%{version} +tar c -T kernel_devel_files | tar x -C %{buildroot}%{_cross_datadir}/bottlerocket/kernel-devel/%{version} + +# Create a tarball of the same files, for use outside the running system. +# In theory we could extract these files with `unsquashfs`, but we do not want +# to require it to be installed on the build host, and it errors out when run +# inside Docker unless the limit for open files is lowered. +tar cf kernel-devel.tar src_squashfs/%{version} --transform='s|src_squashfs/%{version}|kernel-devel|' +xz -T0 kernel-devel.tar + +install -D kernel-devel.squashfs %{buildroot}%{_cross_datadir}/bottlerocket/kernel-devel.squashfs +install -D kernel-devel.tar.xz %{buildroot}%{_cross_datadir}/bottlerocket/kernel-devel.tar.xz +install -d %{buildroot}%{_cross_ksrcdir} + +# Replace the incorrect links from modules_install. These will be bound +# into a host container (and unused in the host) so they must not point +# to %{_cross_usrsrc} (eg. /x86_64-bottlerocket-linux-gnu/sys-root/...) +rm -f %{buildroot}%{_cross_kmoddir}/build %{buildroot}%{_cross_kmoddir}/source +ln -sf %{_usrsrc}/kernels/%{version} %{buildroot}%{_cross_kmoddir}/build +ln -sf %{_usrsrc}/kernels/%{version} %{buildroot}%{_cross_kmoddir}/source + +# Install a copy of System.map so that module dependencies can be regenerated. +install -p -m 0600 System.map %{buildroot}%{_cross_kmoddir} + +# Ensure that each required FIPS module is loaded as a dependency of the +# check-fips-module.service. The list of FIPS modules is different across +# kernels but the check is consistent: it loads the "tcrypt" module after +# the other modules are loaded. +mkdir -p %{buildroot}%{_cross_unitdir}/check-fips-modules.service.d +i=0 +for fipsmod in $(cat %{_sourcedir}/fipsmodules-%{_cross_arch}) ; do + [ "${fipsmod}" == "tcrypt" ] && continue + drop_in="$(printf "%03d\n" "${i}")-${fipsmod}.conf" + sed -e "s|__FIPS_MODULE__|${fipsmod}|g" %{S:200} \ + > %{buildroot}%{_cross_unitdir}/check-fips-modules.service.d/"${drop_in}" + (( i+=1 )) +done + +LOWERPATH=$(systemd-escape --path %{_cross_sharedstatedir}/kernel-devel/.overlay/lower) +mkdir -p %{buildroot}%{_cross_unitdir}/"${LOWERPATH}.mount.d" +sed -e 's|PREFIX|%{_cross_prefix}|g' %{S:210} \ + > %{buildroot}%{_cross_unitdir}/"${LOWERPATH}.mount.d"/no-squashfs.conf + +%if "%{_cross_arch}" == "x86_64" +# Add Neuron-related drop-ins to load the module when the hardware is present. +mkdir -p %{buildroot}%{_cross_unitdir}/sysinit.target.d +install -p -m 0644 %{S:220} %{buildroot}%{_cross_unitdir}/sysinit.target.d/neuron.conf + +mkdir -p %{buildroot}%{_cross_unitdir}/modprobe@neuron.service.d +install -p -m 0644 %{S:221} %{buildroot}%{_cross_unitdir}/modprobe@neuron.service.d/neuron.conf +%endif + +# Install platform-specific bootconfig snippets. +install -d %{buildroot}%{_cross_bootconfigdir} +install -p -m 0644 %{S:300} %{buildroot}%{_cross_bootconfigdir}/05-aws.conf +install -p -m 0644 %{S:301} %{buildroot}%{_cross_bootconfigdir}/05-vmware.conf +install -p -m 0644 %{S:302} %{buildroot}%{_cross_bootconfigdir}/05-metal.conf + +%files +%license COPYING LICENSES/preferred/GPL-2.0 LICENSES/exceptions/Linux-syscall-note +%{_cross_attribution_file} +/boot/vmlinuz +/boot/config + +%files headers +%dir %{_cross_includedir}/asm +%dir %{_cross_includedir}/asm-generic +%dir %{_cross_includedir}/drm +%dir %{_cross_includedir}/linux +%dir %{_cross_includedir}/misc +%dir %{_cross_includedir}/mtd +%dir %{_cross_includedir}/rdma +%dir %{_cross_includedir}/scsi +%dir %{_cross_includedir}/sound +%dir %{_cross_includedir}/video +%dir %{_cross_includedir}/xen +%{_cross_includedir}/asm/* +%{_cross_includedir}/asm-generic/* +%{_cross_includedir}/drm/* +%{_cross_includedir}/linux/* +%{_cross_includedir}/misc/* +%{_cross_includedir}/mtd/* +%{_cross_includedir}/rdma/* +%{_cross_includedir}/scsi/* +%{_cross_includedir}/sound/* +%{_cross_includedir}/video/* +%{_cross_includedir}/xen/* + +%files devel +%dir %{_cross_ksrcdir} +%{_cross_kmoddir}/source +%{_cross_kmoddir}/build + +%files devel-squashed +%{_cross_datadir}/bottlerocket/kernel-devel.squashfs + +%files devel-unpacked +%{_cross_datadir}/bottlerocket/kernel-devel +%{_cross_unitdir}/*kernel*devel*.mount.d/no-squashfs.conf + +%files archive +%{_cross_datadir}/bottlerocket/kernel-devel.tar.xz + +%files fips +%{_cross_unitdir}/check-fips-modules.service.d/*.conf + +%files bootconfig-aws +%{_cross_bootconfigdir}/05-aws.conf + +%files bootconfig-vmware +%{_cross_bootconfigdir}/05-vmware.conf + +%files bootconfig-metal +%{_cross_bootconfigdir}/05-metal.conf + +%files modules +%dir %{_cross_libdir}/modules +%dir %{_cross_kmoddir} +%{_cross_kmoddir}/modules.alias +%{_cross_kmoddir}/modules.alias.bin +%{_cross_kmoddir}/modules.builtin +%{_cross_kmoddir}/modules.builtin.alias.bin +%{_cross_kmoddir}/modules.builtin.bin +%{_cross_kmoddir}/modules.builtin.modinfo +%{_cross_kmoddir}/modules.dep +%{_cross_kmoddir}/modules.dep.bin +%{_cross_kmoddir}/modules.devname +%{_cross_kmoddir}/modules.order +%{_cross_kmoddir}/modules.softdep +%{_cross_kmoddir}/modules.symbols +%{_cross_kmoddir}/modules.symbols.bin +%{_cross_kmoddir}/System.map + +%if "%{_cross_arch}" == "x86_64" +%{_cross_kmoddir}/kernel/arch/x86/crypto/blowfish-x86_64.ko.* +%{_cross_kmoddir}/kernel/arch/x86/crypto/camellia-aesni-avx2.ko.* +%{_cross_kmoddir}/kernel/arch/x86/crypto/camellia-aesni-avx-x86_64.ko.* +%{_cross_kmoddir}/kernel/arch/x86/crypto/camellia-x86_64.ko.* +%{_cross_kmoddir}/kernel/arch/x86/crypto/cast5-avx-x86_64.ko.* +%{_cross_kmoddir}/kernel/arch/x86/crypto/cast6-avx-x86_64.ko.* +%{_cross_kmoddir}/kernel/arch/x86/crypto/chacha-x86_64.ko.* +%{_cross_kmoddir}/kernel/arch/x86/crypto/crc32c-intel.ko.* +%{_cross_kmoddir}/kernel/arch/x86/crypto/crc32-pclmul.ko.* +%{_cross_kmoddir}/kernel/arch/x86/crypto/curve25519-x86_64.ko.* +%{_cross_kmoddir}/kernel/arch/x86/crypto/des3_ede-x86_64.ko.* +%{_cross_kmoddir}/kernel/arch/x86/crypto/ghash-clmulni-intel.ko.* +%{_cross_kmoddir}/kernel/arch/x86/crypto/poly1305-x86_64.ko.* +%{_cross_kmoddir}/kernel/arch/x86/crypto/serpent-avx2.ko.* +%{_cross_kmoddir}/kernel/arch/x86/crypto/serpent-avx-x86_64.ko.* +%{_cross_kmoddir}/kernel/arch/x86/crypto/serpent-sse2-x86_64.ko.* +%{_cross_kmoddir}/kernel/arch/x86/crypto/twofish-avx-x86_64.ko.* +%{_cross_kmoddir}/kernel/arch/x86/crypto/twofish-x86_64-3way.ko.* +%{_cross_kmoddir}/kernel/arch/x86/crypto/twofish-x86_64.ko.* +%{_cross_kmoddir}/kernel/arch/x86/kvm/kvm-amd.ko.* +%{_cross_kmoddir}/kernel/arch/x86/kvm/kvm-intel.ko.* +%{_cross_kmoddir}/kernel/arch/x86/kvm/kvm.ko.* +%{_cross_kmoddir}/kernel/arch/x86/platform/intel/iosf_mbi.ko.* +%endif +%if "%{_cross_arch}" == "aarch64" +%{_cross_kmoddir}/kernel/arch/arm64/crypto/aes-arm64.ko.* +%{_cross_kmoddir}/kernel/arch/arm64/crypto/aes-ce-blk.ko.* +%{_cross_kmoddir}/kernel/arch/arm64/crypto/aes-ce-ccm.ko.* +%{_cross_kmoddir}/kernel/arch/arm64/crypto/aes-ce-cipher.ko.* +%{_cross_kmoddir}/kernel/arch/arm64/crypto/aes-neon-blk.ko.* +%{_cross_kmoddir}/kernel/arch/arm64/crypto/aes-neon-bs.ko.* +%{_cross_kmoddir}/kernel/arch/arm64/crypto/chacha-neon.ko.* +%{_cross_kmoddir}/kernel/arch/arm64/crypto/ghash-ce.ko.* +%{_cross_kmoddir}/kernel/arch/arm64/crypto/poly1305-neon.ko.* +%{_cross_kmoddir}/kernel/arch/arm64/crypto/sha1-ce.ko.* +%{_cross_kmoddir}/kernel/arch/arm64/crypto/sha256-arm64.ko.* +%{_cross_kmoddir}/kernel/arch/arm64/crypto/sha2-ce.ko.* +%{_cross_kmoddir}/kernel/arch/arm64/crypto/sha3-ce.ko.* +%{_cross_kmoddir}/kernel/arch/arm64/crypto/sha512-arm64.ko.* +%{_cross_kmoddir}/kernel/arch/arm64/crypto/sha512-ce.ko.* +%{_cross_kmoddir}/kernel/arch/arm64/crypto/sm3-ce.ko.* +%{_cross_kmoddir}/kernel/arch/arm64/crypto/sm4-ce-cipher.ko.* +%{_cross_kmoddir}/kernel/arch/arm64/lib/xor-neon.ko.* +%endif +%{_cross_kmoddir}/kernel/crypto/af_alg.ko.* +%{_cross_kmoddir}/kernel/crypto/algif_aead.ko.* +%{_cross_kmoddir}/kernel/crypto/algif_hash.ko.* +%{_cross_kmoddir}/kernel/crypto/algif_rng.ko.* +%{_cross_kmoddir}/kernel/crypto/algif_skcipher.ko.* +%{_cross_kmoddir}/kernel/crypto/ansi_cprng.ko.* +%{_cross_kmoddir}/kernel/crypto/anubis.ko.* +%{_cross_kmoddir}/kernel/crypto/arc4.ko.* +%{_cross_kmoddir}/kernel/crypto/asymmetric_keys/pkcs7_test_key.ko.* +%{_cross_kmoddir}/kernel/crypto/async_tx/async_memcpy.ko.* +%{_cross_kmoddir}/kernel/crypto/async_tx/async_pq.ko.* +%{_cross_kmoddir}/kernel/crypto/async_tx/async_raid6_recov.ko.* +%{_cross_kmoddir}/kernel/crypto/async_tx/async_tx.ko.* +%{_cross_kmoddir}/kernel/crypto/async_tx/async_xor.ko.* +%{_cross_kmoddir}/kernel/crypto/authencesn.ko.* +%{_cross_kmoddir}/kernel/crypto/authenc.ko.* +%{_cross_kmoddir}/kernel/crypto/blake2b_generic.ko.* +%{_cross_kmoddir}/kernel/crypto/blowfish_common.ko.* +%{_cross_kmoddir}/kernel/crypto/blowfish_generic.ko.* +%{_cross_kmoddir}/kernel/crypto/camellia_generic.ko.* +%{_cross_kmoddir}/kernel/crypto/cast5_generic.ko.* +%{_cross_kmoddir}/kernel/crypto/cast6_generic.ko.* +%{_cross_kmoddir}/kernel/crypto/cast_common.ko.* +%{_cross_kmoddir}/kernel/crypto/cbc.ko.* +%{_cross_kmoddir}/kernel/crypto/ccm.ko.* +%{_cross_kmoddir}/kernel/crypto/cfb.ko.* +%{_cross_kmoddir}/kernel/crypto/chacha20poly1305.ko.* +%{_cross_kmoddir}/kernel/crypto/chacha_generic.ko.* +%{_cross_kmoddir}/kernel/crypto/cmac.ko.* +%{_cross_kmoddir}/kernel/crypto/crc32_generic.ko.* +%{_cross_kmoddir}/kernel/crypto/crypto_user.ko.* +%{_cross_kmoddir}/kernel/crypto/cts.ko.* +%{_cross_kmoddir}/kernel/crypto/des_generic.ko.* +%{_cross_kmoddir}/kernel/crypto/ecb.ko.* +%{_cross_kmoddir}/kernel/crypto/echainiv.ko.* +%{_cross_kmoddir}/kernel/crypto/essiv.ko.* +%{_cross_kmoddir}/kernel/crypto/fcrypt.ko.* +%{_cross_kmoddir}/kernel/crypto/gcm.ko.* +%{_cross_kmoddir}/kernel/crypto/keywrap.ko.* +%{_cross_kmoddir}/kernel/crypto/khazad.ko.* +%{_cross_kmoddir}/kernel/crypto/lrw.ko.* +%{_cross_kmoddir}/kernel/crypto/lz4hc.ko.* +%{_cross_kmoddir}/kernel/crypto/lz4.ko.* +%{_cross_kmoddir}/kernel/crypto/md4.ko.* +%{_cross_kmoddir}/kernel/crypto/michael_mic.ko.* +%{_cross_kmoddir}/kernel/crypto/ofb.ko.* +%{_cross_kmoddir}/kernel/crypto/pcbc.ko.* +%{_cross_kmoddir}/kernel/crypto/pcrypt.ko.* +%{_cross_kmoddir}/kernel/crypto/poly1305_generic.ko.* +%{_cross_kmoddir}/kernel/crypto/rmd160.ko.* +%{_cross_kmoddir}/kernel/crypto/seed.ko.* +%{_cross_kmoddir}/kernel/crypto/serpent_generic.ko.* +%{_cross_kmoddir}/kernel/crypto/tcrypt.ko.* +%{_cross_kmoddir}/kernel/crypto/tea.ko.* +%{_cross_kmoddir}/kernel/crypto/twofish_common.ko.* +%{_cross_kmoddir}/kernel/crypto/twofish_generic.ko.* +%{_cross_kmoddir}/kernel/crypto/vmac.ko.* +%{_cross_kmoddir}/kernel/crypto/wp512.ko.* +%{_cross_kmoddir}/kernel/crypto/xcbc.ko.* +%{_cross_kmoddir}/kernel/crypto/xor.ko.* +%{_cross_kmoddir}/kernel/crypto/xts.ko.* +%{_cross_kmoddir}/kernel/crypto/xxhash_generic.ko.* +%{_cross_kmoddir}/kernel/crypto/zstd.ko.* +%if "%{_cross_arch}" == "aarch64" +%{_cross_kmoddir}/kernel/crypto/sm3.ko.* +%{_cross_kmoddir}/kernel/crypto/sm4.ko.* +%{_cross_kmoddir}/kernel/crypto/cryptd.ko.* +%endif +%{_cross_kmoddir}/kernel/drivers/acpi/ac.ko.* +%{_cross_kmoddir}/kernel/drivers/acpi/button.ko.* +%{_cross_kmoddir}/kernel/drivers/acpi/thermal.ko.* +%if "%{_cross_arch}" == "x86_64" +%{_cross_kmoddir}/kernel/drivers/acpi/acpi_extlog.ko.* +%{_cross_kmoddir}/kernel/drivers/acpi/acpi_pad.ko.* +%{_cross_kmoddir}/kernel/drivers/acpi/video.ko.* +%endif +%{_cross_kmoddir}/kernel/drivers/amazon/net/efa/efa.ko.* +%{_cross_kmoddir}/kernel/drivers/amazon/net/ena/ena.ko.* +%{_cross_kmoddir}/kernel/drivers/amazon/scsi/mpi3mr/mpi3mr.ko.gz +%if "%{_cross_arch}" == "aarch64" +%{_cross_kmoddir}/kernel/drivers/ata/ahci_platform.ko.* +%{_cross_kmoddir}/kernel/drivers/ata/libahci_platform.ko.* +%endif +%{_cross_kmoddir}/kernel/drivers/block/brd.ko.* +%{_cross_kmoddir}/kernel/drivers/block/drbd/drbd.ko.* +%{_cross_kmoddir}/kernel/drivers/block/loop.ko.* +%{_cross_kmoddir}/kernel/drivers/block/nbd.ko.* +%{_cross_kmoddir}/kernel/drivers/block/null_blk/null_blk.ko.* +%{_cross_kmoddir}/kernel/drivers/block/pktcdvd.ko.* +%{_cross_kmoddir}/kernel/drivers/block/rbd.ko.* +%{_cross_kmoddir}/kernel/drivers/block/zram/zram.ko.* +%{_cross_kmoddir}/kernel/drivers/cdrom/cdrom.ko.* +%{_cross_kmoddir}/kernel/drivers/char/ipmi/ipmi_msghandler.ko.* +%{_cross_kmoddir}/kernel/drivers/char/virtio_console.ko.* +%if "%{_cross_arch}" == "x86_64" +%{_cross_kmoddir}/kernel/drivers/char/agp/intel-gtt.ko.* +%{_cross_kmoddir}/kernel/drivers/char/hangcheck-timer.ko.* +%{_cross_kmoddir}/kernel/drivers/char/nvram.ko.* +%endif +%{_cross_kmoddir}/kernel/drivers/char/hw_random/rng-core.ko.* +%{_cross_kmoddir}/kernel/drivers/char/hw_random/virtio-rng.ko.* +%if "%{_cross_arch}" == "x86_64" +%{_cross_kmoddir}/kernel/drivers/char/hw_random/amd-rng.ko.* +%{_cross_kmoddir}/kernel/drivers/char/hw_random/intel-rng.ko.* +%endif +%if "%{_cross_arch}" == "aarch64" +%{_cross_kmoddir}/kernel/drivers/char/hw_random/arm_smccc_trng.ko.* +%{_cross_kmoddir}/kernel/drivers/char/hw_random/cn10k-rng.ko.* +%{_cross_kmoddir}/kernel/drivers/char/hw_random/graviton-rng.ko.* +%endif +%{_cross_kmoddir}/kernel/drivers/cpufreq/cpufreq_conservative.ko.* +%{_cross_kmoddir}/kernel/drivers/cpufreq/cpufreq_ondemand.ko.* +%{_cross_kmoddir}/kernel/drivers/cpufreq/cpufreq_powersave.ko.* +%{_cross_kmoddir}/kernel/drivers/cpufreq/cpufreq_userspace.ko.* +%if "%{_cross_arch}" == "x86_64" +%{_cross_kmoddir}/kernel/drivers/cpufreq/acpi-cpufreq.ko.* +%{_cross_kmoddir}/kernel/drivers/cpufreq/pcc-cpufreq.ko.* +%{_cross_kmoddir}/kernel/drivers/dca/dca.ko.* +%{_cross_kmoddir}/kernel/drivers/dma/ioat/ioatdma.ko.* +%{_cross_kmoddir}/kernel/drivers/edac/amd64_edac.ko.* +%{_cross_kmoddir}/kernel/drivers/edac/e752x_edac.ko.* +%{_cross_kmoddir}/kernel/drivers/edac/i3000_edac.ko.* +%{_cross_kmoddir}/kernel/drivers/edac/i3200_edac.ko.* +%{_cross_kmoddir}/kernel/drivers/edac/i5000_edac.ko.* +%{_cross_kmoddir}/kernel/drivers/edac/i5100_edac.ko.* +%{_cross_kmoddir}/kernel/drivers/edac/i5400_edac.ko.* +%{_cross_kmoddir}/kernel/drivers/edac/i7300_edac.ko.* +%{_cross_kmoddir}/kernel/drivers/edac/i7core_edac.ko.* +%{_cross_kmoddir}/kernel/drivers/edac/i82975x_edac.ko.* +%{_cross_kmoddir}/kernel/drivers/edac/ie31200_edac.ko.* +%{_cross_kmoddir}/kernel/drivers/edac/pnd2_edac.ko.* +%{_cross_kmoddir}/kernel/drivers/edac/sb_edac.ko.* +%{_cross_kmoddir}/kernel/drivers/edac/skx_edac.ko.* +%{_cross_kmoddir}/kernel/drivers/edac/skx_edac_common.ko.gz +%{_cross_kmoddir}/kernel/drivers/edac/x38_edac.ko.* +%endif +%{_cross_kmoddir}/kernel/drivers/firmware/dmi-sysfs.ko.* +%if "%{_cross_arch}" == "aarch64" +%{_cross_kmoddir}/kernel/drivers/firmware/arm_scpi.ko.* +%{_cross_kmoddir}/kernel/drivers/firmware/scpi_pm_domain.ko.* +%endif +%{_cross_kmoddir}/kernel/drivers/gpu/drm/drm_kms_helper.ko.* +%{_cross_kmoddir}/kernel/drivers/gpu/drm/drm.ko.* +%{_cross_kmoddir}/kernel/drivers/gpu/drm/drm_shmem_helper.ko.* +%{_cross_kmoddir}/kernel/drivers/gpu/drm/tiny/simpledrm.ko.* +%if "%{_cross_arch}" == "x86_64" +%{_cross_kmoddir}/kernel/drivers/gpu/drm/drm_buddy.ko.* +%{_cross_kmoddir}/kernel/drivers/gpu/drm/display/drm_display_helper.ko.* +%{_cross_kmoddir}/kernel/drivers/gpu/drm/i915/i915.ko.* +%{_cross_kmoddir}/kernel/drivers/gpu/drm/ttm/ttm.ko.* +%endif +%{_cross_kmoddir}/kernel/drivers/hid/hid-generic.ko.* +%{_cross_kmoddir}/kernel/drivers/hid/hid-multitouch.ko.* +%{_cross_kmoddir}/kernel/drivers/hid/uhid.ko.* +%{_cross_kmoddir}/kernel/drivers/hid/usbhid/usbhid.ko.* +%if "%{_cross_arch}" == "x86_64" +%{_cross_kmoddir}/kernel/drivers/hid/hid-hyperv.ko.* +%{_cross_kmoddir}/kernel/drivers/hv/hv_balloon.ko.* +%{_cross_kmoddir}/kernel/drivers/hv/hv_utils.ko.* +%{_cross_kmoddir}/kernel/drivers/hv/hv_vmbus.ko.* +%endif +%{_cross_kmoddir}/kernel/drivers/hwmon/acpi_power_meter.ko.* +%{_cross_kmoddir}/kernel/drivers/hwmon/hwmon.ko.* +%{_cross_kmoddir}/kernel/drivers/i2c/algos/i2c-algo-bit.ko.* +%{_cross_kmoddir}/kernel/drivers/i2c/i2c-core.ko.* +%{_cross_kmoddir}/kernel/drivers/infiniband/core/ib_cm.ko.* +%{_cross_kmoddir}/kernel/drivers/infiniband/core/ib_core.ko.* +%{_cross_kmoddir}/kernel/drivers/infiniband/core/ib_uverbs.ko.* +%{_cross_kmoddir}/kernel/drivers/infiniband/core/iw_cm.ko.* +%{_cross_kmoddir}/kernel/drivers/infiniband/core/rdma_cm.ko.* +%{_cross_kmoddir}/kernel/drivers/infiniband/core/rdma_ucm.ko.* +%{_cross_kmoddir}/kernel/drivers/infiniband/hw/mlx5/mlx5_ib.ko.* +%{_cross_kmoddir}/kernel/drivers/input/misc/uinput.ko.* +%{_cross_kmoddir}/kernel/drivers/input/mousedev.ko.* +%{_cross_kmoddir}/kernel/drivers/input/keyboard/atkbd.ko.* +%{_cross_kmoddir}/kernel/drivers/input/mouse/psmouse.ko.* +%{_cross_kmoddir}/kernel/drivers/input/serio/libps2.ko.* +%{_cross_kmoddir}/kernel/drivers/input/serio/serio.ko.* +%{_cross_kmoddir}/kernel/drivers/input/serio/serport.ko.* +%{_cross_kmoddir}/kernel/drivers/input/sparse-keymap.ko.* +%{_cross_kmoddir}/kernel/drivers/input/vivaldi-fmap.ko.* +%if "%{_cross_arch}" == "x86_64" +%{_cross_kmoddir}/kernel/drivers/input/serio/hyperv-keyboard.ko.* +%{_cross_kmoddir}/kernel/drivers/input/serio/i8042.ko.* +%endif +%{_cross_kmoddir}/kernel/drivers/iommu/virtio-iommu.ko.* +%if "%{_cross_arch}" == "aarch64" +%{_cross_kmoddir}/kernel/drivers/mailbox/arm_mhu_db.ko.* +%{_cross_kmoddir}/kernel/drivers/mailbox/arm_mhu.ko.* +%endif +%{_cross_kmoddir}/kernel/drivers/md/bcache/bcache.ko.* +%{_cross_kmoddir}/kernel/drivers/md/dm-bio-prison.ko.* +%{_cross_kmoddir}/kernel/drivers/md/dm-cache.ko.* +%{_cross_kmoddir}/kernel/drivers/md/dm-cache-smq.ko.* +%{_cross_kmoddir}/kernel/drivers/md/dm-crypt.ko.* +%{_cross_kmoddir}/kernel/drivers/md/dm-delay.ko.* +%{_cross_kmoddir}/kernel/drivers/md/dm-dust.ko.* +%{_cross_kmoddir}/kernel/drivers/md/dm-flakey.ko.* +%{_cross_kmoddir}/kernel/drivers/md/dm-integrity.ko.* +%{_cross_kmoddir}/kernel/drivers/md/dm-log.ko.* +%{_cross_kmoddir}/kernel/drivers/md/dm-log-userspace.ko.* +%{_cross_kmoddir}/kernel/drivers/md/dm-log-writes.ko.* +%{_cross_kmoddir}/kernel/drivers/md/dm-mirror.ko.* +%{_cross_kmoddir}/kernel/drivers/md/dm-multipath.ko.* +%{_cross_kmoddir}/kernel/drivers/md/dm-queue-length.ko.* +%{_cross_kmoddir}/kernel/drivers/md/dm-raid.ko.* +%{_cross_kmoddir}/kernel/drivers/md/dm-region-hash.ko.* +%{_cross_kmoddir}/kernel/drivers/md/dm-round-robin.ko.* +%{_cross_kmoddir}/kernel/drivers/md/dm-service-time.ko.* +%{_cross_kmoddir}/kernel/drivers/md/dm-snapshot.ko.* +%{_cross_kmoddir}/kernel/drivers/md/dm-thin-pool.ko.* +%{_cross_kmoddir}/kernel/drivers/md/dm-zero.ko.* +%{_cross_kmoddir}/kernel/drivers/md/faulty.ko.* +%{_cross_kmoddir}/kernel/drivers/md/linear.ko.* +%{_cross_kmoddir}/kernel/drivers/md/persistent-data/dm-persistent-data.ko.* +%{_cross_kmoddir}/kernel/drivers/md/raid0.ko.* +%{_cross_kmoddir}/kernel/drivers/md/raid10.ko.* +%{_cross_kmoddir}/kernel/drivers/md/raid1.ko.* +%{_cross_kmoddir}/kernel/drivers/md/raid456.ko.* +%{_cross_kmoddir}/kernel/drivers/mfd/lpc_ich.ko.* +%{_cross_kmoddir}/kernel/drivers/mfd/lpc_sch.ko.* +%if "%{_cross_arch}" == "x86_64" +%{_cross_kmoddir}/kernel/drivers/mfd/mfd-core.ko.* +%{_cross_kmoddir}/kernel/drivers/misc/vmw_balloon.ko.* +%{_cross_kmoddir}/kernel/drivers/misc/vmw_vmci/vmw_vmci.ko.* +%endif +%{_cross_kmoddir}/kernel/drivers/net/bonding/bonding.ko.* +%{_cross_kmoddir}/kernel/drivers/net/dummy.ko.* +%{_cross_kmoddir}/kernel/drivers/net/ethernet/intel/e1000/e1000.ko.* +%{_cross_kmoddir}/kernel/drivers/net/ethernet/intel/e1000e/e1000e.ko.* +%{_cross_kmoddir}/kernel/drivers/net/ethernet/intel/igb/igb.ko.* +%{_cross_kmoddir}/kernel/drivers/net/ethernet/intel/igc/igc.ko.* +%{_cross_kmoddir}/kernel/drivers/net/ethernet/intel/ixgbevf/ixgbevf.ko.* +%{_cross_kmoddir}/kernel/drivers/net/ethernet/mellanox/mlx5/core/mlx5_core.ko.* +%{_cross_kmoddir}/kernel/drivers/net/ethernet/mellanox/mlxfw/mlxfw.ko.* +%{_cross_kmoddir}/kernel/drivers/net/ethernet/realtek/r8169.ko.gz +%{_cross_kmoddir}/kernel/drivers/net/phy/realtek.ko.gz +%{_cross_kmoddir}/kernel/drivers/net/geneve.ko.* +%if "%{_cross_arch}" == "x86_64" +%{_cross_kmoddir}/kernel/drivers/net/hyperv/hv_netvsc.ko.* +%endif +%{_cross_kmoddir}/kernel/drivers/net/ifb.ko.* +%{_cross_kmoddir}/kernel/drivers/net/ipvlan/ipvlan.ko.* +%{_cross_kmoddir}/kernel/drivers/net/ipvlan/ipvtap.ko.* +%{_cross_kmoddir}/kernel/drivers/net/macvlan.ko.* +%{_cross_kmoddir}/kernel/drivers/net/macvtap.ko.* +%{_cross_kmoddir}/kernel/drivers/net/mdio/acpi_mdio.ko.* +%{_cross_kmoddir}/kernel/drivers/net/mdio/fwnode_mdio.ko.* +%{_cross_kmoddir}/kernel/drivers/net/netdevsim/netdevsim.ko.* +%{_cross_kmoddir}/kernel/drivers/net/net_failover.ko.* +%{_cross_kmoddir}/kernel/drivers/net/nlmon.ko.* +%{_cross_kmoddir}/kernel/drivers/net/phy/fixed_phy.ko.* +%{_cross_kmoddir}/kernel/drivers/net/phy/libphy.ko.* +%{_cross_kmoddir}/kernel/drivers/net/phy/mdio_devres.ko.* +%{_cross_kmoddir}/kernel/drivers/net/tap.ko.* +%{_cross_kmoddir}/kernel/drivers/net/team/team.ko.* +%{_cross_kmoddir}/kernel/drivers/net/team/team_mode_activebackup.ko.* +%{_cross_kmoddir}/kernel/drivers/net/team/team_mode_broadcast.ko.* +%{_cross_kmoddir}/kernel/drivers/net/team/team_mode_loadbalance.ko.* +%{_cross_kmoddir}/kernel/drivers/net/team/team_mode_roundrobin.ko.* +%{_cross_kmoddir}/kernel/drivers/net/tun.ko.* +%{_cross_kmoddir}/kernel/drivers/net/veth.ko.* +%{_cross_kmoddir}/kernel/drivers/net/virtio_net.ko.* +%{_cross_kmoddir}/kernel/drivers/net/vmxnet3/vmxnet3.ko.* +%{_cross_kmoddir}/kernel/drivers/net/vrf.ko.* +%{_cross_kmoddir}/kernel/drivers/net/vxlan/vxlan.ko.* +%{_cross_kmoddir}/kernel/drivers/net/wireguard/wireguard.ko.* +%if "%{_cross_arch}" == "x86_64" +%{_cross_kmoddir}/kernel/drivers/net/xen-netback/xen-netback.ko.* +%endif +%if "%{_cross_arch}" == "aarch64" +%{_cross_kmoddir}/kernel/drivers/net/mdio/of_mdio.ko.* +%endif +%{_cross_kmoddir}/kernel/drivers/nvme/host/nvme-fabrics.ko.* +%{_cross_kmoddir}/kernel/drivers/nvme/host/nvme-tcp.ko.* +%{_cross_kmoddir}/kernel/drivers/pci/hotplug/acpiphp_ibm.ko.* +%{_cross_kmoddir}/kernel/drivers/pci/pci-stub.ko.* +%if "%{_cross_arch}" == "x86_64" +%{_cross_kmoddir}/kernel/drivers/pci/controller/pci-hyperv-intf.ko.* +%{_cross_kmoddir}/kernel/drivers/pci/hotplug/cpcihp_generic.ko.* +%{_cross_kmoddir}/kernel/drivers/platform/x86/wmi-bmof.ko.* +%{_cross_kmoddir}/kernel/drivers/platform/x86/wmi.ko.* +%endif +%if "%{_cross_arch}" == "aarch64" +%{_cross_kmoddir}/kernel/drivers/perf/arm-cmn.ko.* +%endif +%{_cross_kmoddir}/kernel/drivers/pps/clients/pps-gpio.ko.* +%{_cross_kmoddir}/kernel/drivers/pps/clients/pps-ldisc.ko.* +%{_cross_kmoddir}/kernel/drivers/ptp/ptp_kvm.ko.* +%{_cross_kmoddir}/kernel/drivers/scsi/ch.ko.* +%if "%{_cross_arch}" == "x86_64" +%{_cross_kmoddir}/kernel/drivers/scsi/hv_storvsc.ko.* +%endif +%{_cross_kmoddir}/kernel/drivers/scsi/iscsi_boot_sysfs.ko.* +%{_cross_kmoddir}/kernel/drivers/scsi/iscsi_tcp.ko.* +%{_cross_kmoddir}/kernel/drivers/scsi/libiscsi.ko.* +%{_cross_kmoddir}/kernel/drivers/scsi/libiscsi_tcp.ko.* +%{_cross_kmoddir}/kernel/drivers/scsi/scsi_transport_iscsi.ko.* +%{_cross_kmoddir}/kernel/drivers/scsi/sg.ko.* +%{_cross_kmoddir}/kernel/drivers/scsi/sr_mod.ko.* +%{_cross_kmoddir}/kernel/drivers/scsi/st.ko.* +%if "%{_cross_arch}" == "x86_64" +%{_cross_kmoddir}/kernel/drivers/scsi/vmw_pvscsi.ko.* +%{_cross_kmoddir}/kernel/drivers/scsi/xen-scsifront.ko.* +%endif +%{_cross_kmoddir}/kernel/drivers/staging/lustrefsx/libcfs/libcfs/libcfs.ko.* +%{_cross_kmoddir}/kernel/drivers/staging/lustrefsx/lnet/klnds/o2iblnd/ko2iblnd.ko.* +%{_cross_kmoddir}/kernel/drivers/staging/lustrefsx/lnet/klnds/socklnd/ksocklnd.ko.* +%{_cross_kmoddir}/kernel/drivers/staging/lustrefsx/lnet/lnet/lnet.ko.* +%{_cross_kmoddir}/kernel/drivers/staging/lustrefsx/lnet/selftest/lnet_selftest.ko.* +%{_cross_kmoddir}/kernel/drivers/staging/lustrefsx/lustre/fid/fid.ko.* +%{_cross_kmoddir}/kernel/drivers/staging/lustrefsx/lustre/fld/fld.ko.* +%{_cross_kmoddir}/kernel/drivers/staging/lustrefsx/lustre/llite/lustre.ko.* +%{_cross_kmoddir}/kernel/drivers/staging/lustrefsx/lustre/lmv/lmv.ko.* +%{_cross_kmoddir}/kernel/drivers/staging/lustrefsx/lustre/lov/lov.ko.* +%{_cross_kmoddir}/kernel/drivers/staging/lustrefsx/lustre/mdc/mdc.ko.* +%{_cross_kmoddir}/kernel/drivers/staging/lustrefsx/lustre/mgc/mgc.ko.* +%{_cross_kmoddir}/kernel/drivers/staging/lustrefsx/lustre/obdclass/obdclass.ko.* +%{_cross_kmoddir}/kernel/drivers/staging/lustrefsx/lustre/obdecho/obdecho.ko.* +%{_cross_kmoddir}/kernel/drivers/staging/lustrefsx/lustre/osc/osc.ko.* +%{_cross_kmoddir}/kernel/drivers/staging/lustrefsx/lustre/ptlrpc/ptlrpc.ko.* +%{_cross_kmoddir}/kernel/drivers/target/iscsi/iscsi_target_mod.ko.* +%{_cross_kmoddir}/kernel/drivers/target/loopback/tcm_loop.ko.* +%{_cross_kmoddir}/kernel/drivers/target/target_core_file.ko.* +%{_cross_kmoddir}/kernel/drivers/target/target_core_iblock.ko.* +%{_cross_kmoddir}/kernel/drivers/target/target_core_mod.ko.* +%{_cross_kmoddir}/kernel/drivers/target/target_core_user.ko.* +%if "%{_cross_arch}" == "x86_64" +%{_cross_kmoddir}/kernel/drivers/thermal/intel/x86_pkg_temp_thermal.ko.* +%endif +%{_cross_kmoddir}/kernel/drivers/tty/serial/8250/8250_exar.ko.* +%{_cross_kmoddir}/kernel/drivers/uio/uio_dmem_genirq.ko.* +%{_cross_kmoddir}/kernel/drivers/uio/uio.ko.* +%{_cross_kmoddir}/kernel/drivers/uio/uio_pci_generic.ko.* +%{_cross_kmoddir}/kernel/drivers/uio/uio_pdrv_genirq.ko.* +%if "%{_cross_arch}" == "x86_64" +%{_cross_kmoddir}/kernel/drivers/uio/uio_hv_generic.ko.* +%endif +%{_cross_kmoddir}/kernel/drivers/usb/class/cdc-acm.ko.* +%{_cross_kmoddir}/kernel/drivers/usb/common/usb-common.ko.* +%{_cross_kmoddir}/kernel/drivers/usb/core/usbcore.ko.* +%{_cross_kmoddir}/kernel/drivers/usb/host/ehci-hcd.ko.* +%{_cross_kmoddir}/kernel/drivers/usb/host/ehci-pci.ko.* +%{_cross_kmoddir}/kernel/drivers/usb/host/ehci-platform.ko.* +%{_cross_kmoddir}/kernel/drivers/usb/host/ohci-hcd.ko.* +%{_cross_kmoddir}/kernel/drivers/usb/host/ohci-pci.ko.* +%{_cross_kmoddir}/kernel/drivers/usb/host/ohci-platform.ko.* +%{_cross_kmoddir}/kernel/drivers/usb/host/uhci-hcd.ko.* +%{_cross_kmoddir}/kernel/drivers/usb/host/xhci-hcd.ko.* +%{_cross_kmoddir}/kernel/drivers/usb/host/xhci-pci.ko.* +%{_cross_kmoddir}/kernel/drivers/usb/host/xhci-plat-hcd.ko.* +%{_cross_kmoddir}/kernel/drivers/usb/mon/usbmon.ko.* +%{_cross_kmoddir}/kernel/drivers/usb/serial/cp210x.ko.* +%{_cross_kmoddir}/kernel/drivers/usb/serial/ftdi_sio.ko.* +%{_cross_kmoddir}/kernel/drivers/usb/serial/usbserial.ko.* +%{_cross_kmoddir}/kernel/drivers/usb/storage/uas.ko.* +%{_cross_kmoddir}/kernel/drivers/usb/storage/usb-storage.ko.* +%{_cross_kmoddir}/kernel/drivers/usb/usbip/usbip-core.ko.* +%{_cross_kmoddir}/kernel/drivers/usb/usbip/usbip-host.ko.* +%{_cross_kmoddir}/kernel/drivers/usb/usbip/vhci-hcd.ko.* +%{_cross_kmoddir}/kernel/drivers/vfio/pci/mlx5/mlx5-vfio-pci.ko.* +%{_cross_kmoddir}/kernel/drivers/vfio/pci/vfio-pci-core.ko.* +%{_cross_kmoddir}/kernel/drivers/vfio/pci/vfio-pci.ko.* +%{_cross_kmoddir}/kernel/drivers/vfio/vfio_iommu_type1.ko.* +%{_cross_kmoddir}/kernel/drivers/vfio/vfio.ko.* +%{_cross_kmoddir}/kernel/drivers/vfio/vfio_virqfd.ko.* +%{_cross_kmoddir}/kernel/drivers/vhost/vhost_iotlb.ko.* +%{_cross_kmoddir}/kernel/drivers/vhost/vhost.ko.* +%{_cross_kmoddir}/kernel/drivers/vhost/vhost_net.ko.* +%{_cross_kmoddir}/kernel/drivers/vhost/vhost_vsock.ko.* +%{_cross_kmoddir}/kernel/drivers/video/backlight/backlight.ko.* +%{_cross_kmoddir}/kernel/drivers/video/backlight/lcd.ko.* +%{_cross_kmoddir}/kernel/drivers/video/fbdev/core/fb_sys_fops.ko.* +%{_cross_kmoddir}/kernel/drivers/video/fbdev/core/syscopyarea.ko.* +%{_cross_kmoddir}/kernel/drivers/video/fbdev/core/sysfillrect.ko.* +%{_cross_kmoddir}/kernel/drivers/video/fbdev/core/sysimgblt.ko.* +%if "%{_cross_arch}" == "x86_64" +%{_cross_kmoddir}/kernel/drivers/virt/coco/sev-guest/sev-guest.ko.* +%{_cross_kmoddir}/kernel/drivers/virt/vboxguest/vboxguest.ko.* +%endif +%if "%{_cross_arch}" == "aarch64" +%{_cross_kmoddir}/kernel/drivers/virt/nitro_enclaves/nitro_enclaves.ko.* +%endif +%{_cross_kmoddir}/kernel/drivers/virtio/virtio_balloon.ko.* +%{_cross_kmoddir}/kernel/drivers/virtio/virtio_mmio.ko.* +%if "%{_cross_arch}" == "x86_64" +%{_cross_kmoddir}/kernel/drivers/virtio/virtio_mem.ko.* +%endif +%{_cross_kmoddir}/kernel/drivers/watchdog/softdog.ko.* +%if "%{_cross_arch}" == "aarch64" +%{_cross_kmoddir}/kernel/drivers/watchdog/gpio_wdt.ko.* +%{_cross_kmoddir}/kernel/drivers/watchdog/sbsa_gwdt.ko.* +%{_cross_kmoddir}/kernel/drivers/watchdog/sp805_wdt.ko.* +%endif +%if "%{_cross_arch}" == "x86_64" +%{_cross_kmoddir}/kernel/drivers/xen/xen-evtchn.ko.* +%{_cross_kmoddir}/kernel/drivers/xen/xenfs/xenfs.ko.* +%{_cross_kmoddir}/kernel/drivers/xen/xen-gntalloc.ko.* +%{_cross_kmoddir}/kernel/drivers/xen/xen-gntdev.ko.* +%{_cross_kmoddir}/kernel/drivers/xen/xen-pciback/xen-pciback.ko.* +%{_cross_kmoddir}/kernel/drivers/xen/xen-privcmd.ko.* +%endif +%{_cross_kmoddir}/kernel/fs/binfmt_misc.ko.* +%{_cross_kmoddir}/kernel/fs/btrfs/btrfs.ko.* +%{_cross_kmoddir}/kernel/fs/cachefiles/cachefiles.ko.* +%{_cross_kmoddir}/kernel/fs/ceph/ceph.ko.* +%{_cross_kmoddir}/kernel/fs/configfs/configfs.ko.* +%{_cross_kmoddir}/kernel/fs/efivarfs/efivarfs.ko.* +%{_cross_kmoddir}/kernel/fs/exfat/exfat.ko.* +%{_cross_kmoddir}/kernel/fs/fat/fat.ko.* +%{_cross_kmoddir}/kernel/fs/fat/msdos.ko.* +%{_cross_kmoddir}/kernel/fs/fat/vfat.ko.* +%{_cross_kmoddir}/kernel/fs/fscache/fscache.ko.* +%{_cross_kmoddir}/kernel/fs/fuse/cuse.ko.* +%{_cross_kmoddir}/kernel/fs/fuse/fuse.ko.* +%{_cross_kmoddir}/kernel/fs/fuse/virtiofs.ko.* +%{_cross_kmoddir}/kernel/fs/isofs/isofs.ko.* +%{_cross_kmoddir}/kernel/fs/lockd/lockd.ko.* +%{_cross_kmoddir}/kernel/fs/netfs/netfs.ko.* +%{_cross_kmoddir}/kernel/fs/nfs/blocklayout/blocklayoutdriver.ko.* +%{_cross_kmoddir}/kernel/fs/nfs_common/grace.ko.* +%{_cross_kmoddir}/kernel/fs/nfs_common/nfs_acl.ko.* +%{_cross_kmoddir}/kernel/fs/nfsd/nfsd.ko.* +%{_cross_kmoddir}/kernel/fs/nfs/filelayout/nfs_layout_nfsv41_files.ko.* +%{_cross_kmoddir}/kernel/fs/nfs/flexfilelayout/nfs_layout_flexfiles.ko.* +%{_cross_kmoddir}/kernel/fs/nfs/nfs.ko.* +%{_cross_kmoddir}/kernel/fs/nfs/nfsv3.ko.* +%{_cross_kmoddir}/kernel/fs/nfs/nfsv4.ko.* +%{_cross_kmoddir}/kernel/fs/nls/mac-celtic.ko.* +%{_cross_kmoddir}/kernel/fs/nls/mac-centeuro.ko.* +%{_cross_kmoddir}/kernel/fs/nls/mac-croatian.ko.* +%{_cross_kmoddir}/kernel/fs/nls/mac-cyrillic.ko.* +%{_cross_kmoddir}/kernel/fs/nls/mac-gaelic.ko.* +%{_cross_kmoddir}/kernel/fs/nls/mac-greek.ko.* +%{_cross_kmoddir}/kernel/fs/nls/mac-iceland.ko.* +%{_cross_kmoddir}/kernel/fs/nls/mac-inuit.ko.* +%{_cross_kmoddir}/kernel/fs/nls/mac-romanian.ko.* +%{_cross_kmoddir}/kernel/fs/nls/mac-roman.ko.* +%{_cross_kmoddir}/kernel/fs/nls/mac-turkish.ko.* +%{_cross_kmoddir}/kernel/fs/nls/nls_ascii.ko.* +%{_cross_kmoddir}/kernel/fs/nls/nls_cp1250.ko.* +%{_cross_kmoddir}/kernel/fs/nls/nls_cp1251.ko.* +%{_cross_kmoddir}/kernel/fs/nls/nls_cp1255.ko.* +%{_cross_kmoddir}/kernel/fs/nls/nls_cp437.ko.* +%{_cross_kmoddir}/kernel/fs/nls/nls_cp737.ko.* +%{_cross_kmoddir}/kernel/fs/nls/nls_cp775.ko.* +%{_cross_kmoddir}/kernel/fs/nls/nls_cp850.ko.* +%{_cross_kmoddir}/kernel/fs/nls/nls_cp852.ko.* +%{_cross_kmoddir}/kernel/fs/nls/nls_cp855.ko.* +%{_cross_kmoddir}/kernel/fs/nls/nls_cp857.ko.* +%{_cross_kmoddir}/kernel/fs/nls/nls_cp860.ko.* +%{_cross_kmoddir}/kernel/fs/nls/nls_cp861.ko.* +%{_cross_kmoddir}/kernel/fs/nls/nls_cp862.ko.* +%{_cross_kmoddir}/kernel/fs/nls/nls_cp863.ko.* +%{_cross_kmoddir}/kernel/fs/nls/nls_cp864.ko.* +%{_cross_kmoddir}/kernel/fs/nls/nls_cp865.ko.* +%{_cross_kmoddir}/kernel/fs/nls/nls_cp866.ko.* +%{_cross_kmoddir}/kernel/fs/nls/nls_cp869.ko.* +%{_cross_kmoddir}/kernel/fs/nls/nls_cp874.ko.* +%{_cross_kmoddir}/kernel/fs/nls/nls_cp932.ko.* +%{_cross_kmoddir}/kernel/fs/nls/nls_cp936.ko.* +%{_cross_kmoddir}/kernel/fs/nls/nls_cp949.ko.* +%{_cross_kmoddir}/kernel/fs/nls/nls_cp950.ko.* +%{_cross_kmoddir}/kernel/fs/nls/nls_euc-jp.ko.* +%{_cross_kmoddir}/kernel/fs/nls/nls_iso8859-13.ko.* +%{_cross_kmoddir}/kernel/fs/nls/nls_iso8859-14.ko.* +%{_cross_kmoddir}/kernel/fs/nls/nls_iso8859-15.ko.* +%{_cross_kmoddir}/kernel/fs/nls/nls_iso8859-1.ko.* +%{_cross_kmoddir}/kernel/fs/nls/nls_iso8859-2.ko.* +%{_cross_kmoddir}/kernel/fs/nls/nls_iso8859-3.ko.* +%{_cross_kmoddir}/kernel/fs/nls/nls_iso8859-4.ko.* +%{_cross_kmoddir}/kernel/fs/nls/nls_iso8859-5.ko.* +%{_cross_kmoddir}/kernel/fs/nls/nls_iso8859-6.ko.* +%{_cross_kmoddir}/kernel/fs/nls/nls_iso8859-7.ko.* +%{_cross_kmoddir}/kernel/fs/nls/nls_iso8859-9.ko.* +%{_cross_kmoddir}/kernel/fs/nls/nls_koi8-r.ko.* +%{_cross_kmoddir}/kernel/fs/nls/nls_koi8-ru.ko.* +%{_cross_kmoddir}/kernel/fs/nls/nls_koi8-u.ko.* +%{_cross_kmoddir}/kernel/fs/nls/nls_utf8.ko.* +%{_cross_kmoddir}/kernel/fs/overlayfs/overlay.ko.* +%{_cross_kmoddir}/kernel/fs/pstore/ramoops.ko.* +%{_cross_kmoddir}/kernel/fs/quota/quota_tree.ko.* +%{_cross_kmoddir}/kernel/fs/quota/quota_v2.ko.* +%{_cross_kmoddir}/kernel/fs/smb/client/cifs.ko.* +%{_cross_kmoddir}/kernel/fs/smb/common/cifs_arc4.ko.* +%{_cross_kmoddir}/kernel/fs/smb/common/cifs_md4.ko.* +%{_cross_kmoddir}/kernel/fs/squashfs/squashfs.ko.* +%{_cross_kmoddir}/kernel/fs/udf/udf.ko.* +%{_cross_kmoddir}/kernel/kernel/bpf/preload/bpf_preload.ko.* +%{_cross_kmoddir}/kernel/lib/asn1_encoder.ko.* +%{_cross_kmoddir}/kernel/lib/crc4.ko.* +%{_cross_kmoddir}/kernel/lib/crc7.ko.* +%{_cross_kmoddir}/kernel/lib/crc8.ko.* +%{_cross_kmoddir}/kernel/lib/crc-itu-t.ko.* +%{_cross_kmoddir}/kernel/lib/crypto/libarc4.ko.* +%{_cross_kmoddir}/kernel/lib/crypto/libchacha20poly1305.ko.* +%{_cross_kmoddir}/kernel/lib/crypto/libchacha.ko.* +%{_cross_kmoddir}/kernel/lib/crypto/libcurve25519-generic.ko.* +%{_cross_kmoddir}/kernel/lib/crypto/libcurve25519.ko.* +%{_cross_kmoddir}/kernel/lib/crypto/libdes.ko.* +%{_cross_kmoddir}/kernel/lib/crypto/libpoly1305.ko.* +%{_cross_kmoddir}/kernel/lib/lru_cache.ko.* +%{_cross_kmoddir}/kernel/lib/lz4/lz4_compress.ko.* +%{_cross_kmoddir}/kernel/lib/lz4/lz4hc_compress.ko.* +%{_cross_kmoddir}/kernel/lib/raid6/raid6_pq.ko.* +%{_cross_kmoddir}/kernel/lib/reed_solomon/reed_solomon.ko.* +%{_cross_kmoddir}/kernel/lib/test_lockup.ko.* +%{_cross_kmoddir}/kernel/lib/ts_bm.ko.* +%{_cross_kmoddir}/kernel/lib/ts_fsm.ko.* +%{_cross_kmoddir}/kernel/lib/ts_kmp.ko.* +%{_cross_kmoddir}/kernel/lib/zstd/zstd_compress.ko.* +%{_cross_kmoddir}/kernel/mm/z3fold.ko.* +%{_cross_kmoddir}/kernel/mm/zsmalloc.ko.* +%{_cross_kmoddir}/kernel/net/8021q/8021q.ko.* +%{_cross_kmoddir}/kernel/net/802/garp.ko.* +%{_cross_kmoddir}/kernel/net/802/mrp.ko.* +%{_cross_kmoddir}/kernel/net/802/p8022.ko.* +%{_cross_kmoddir}/kernel/net/802/psnap.ko.* +%{_cross_kmoddir}/kernel/net/802/stp.ko.* +%{_cross_kmoddir}/kernel/net/bridge/bridge.ko.* +%{_cross_kmoddir}/kernel/net/bridge/br_netfilter.ko.* +%{_cross_kmoddir}/kernel/net/bridge/netfilter/ebt_802_3.ko.* +%{_cross_kmoddir}/kernel/net/bridge/netfilter/ebtable_broute.ko.* +%{_cross_kmoddir}/kernel/net/bridge/netfilter/ebtable_filter.ko.* +%{_cross_kmoddir}/kernel/net/bridge/netfilter/ebtable_nat.ko.* +%{_cross_kmoddir}/kernel/net/bridge/netfilter/ebtables.ko.* +%{_cross_kmoddir}/kernel/net/bridge/netfilter/ebt_among.ko.* +%{_cross_kmoddir}/kernel/net/bridge/netfilter/ebt_arp.ko.* +%{_cross_kmoddir}/kernel/net/bridge/netfilter/ebt_arpreply.ko.* +%{_cross_kmoddir}/kernel/net/bridge/netfilter/ebt_dnat.ko.* +%{_cross_kmoddir}/kernel/net/bridge/netfilter/ebt_ip6.ko.* +%{_cross_kmoddir}/kernel/net/bridge/netfilter/ebt_ip.ko.* +%{_cross_kmoddir}/kernel/net/bridge/netfilter/ebt_limit.ko.* +%{_cross_kmoddir}/kernel/net/bridge/netfilter/ebt_log.ko.* +%{_cross_kmoddir}/kernel/net/bridge/netfilter/ebt_mark.ko.* +%{_cross_kmoddir}/kernel/net/bridge/netfilter/ebt_mark_m.ko.* +%{_cross_kmoddir}/kernel/net/bridge/netfilter/ebt_nflog.ko.* +%{_cross_kmoddir}/kernel/net/bridge/netfilter/ebt_pkttype.ko.* +%{_cross_kmoddir}/kernel/net/bridge/netfilter/ebt_redirect.ko.* +%{_cross_kmoddir}/kernel/net/bridge/netfilter/ebt_snat.ko.* +%{_cross_kmoddir}/kernel/net/bridge/netfilter/ebt_stp.ko.* +%{_cross_kmoddir}/kernel/net/bridge/netfilter/ebt_vlan.ko.* +%{_cross_kmoddir}/kernel/net/bridge/netfilter/nft_reject_bridge.ko.* +%{_cross_kmoddir}/kernel/net/ceph/libceph.ko.* +%{_cross_kmoddir}/kernel/net/core/failover.ko.* +%{_cross_kmoddir}/kernel/net/core/selftests.ko.* +%{_cross_kmoddir}/kernel/net/dns_resolver/dns_resolver.ko.* +%{_cross_kmoddir}/kernel/net/ife/ife.ko.* +%{_cross_kmoddir}/kernel/net/ipv4/ah4.ko.* +%{_cross_kmoddir}/kernel/net/ipv4/esp4.ko.* +%{_cross_kmoddir}/kernel/net/ipv4/esp4_offload.ko.* +%{_cross_kmoddir}/kernel/net/ipv4/fou.ko.* +%{_cross_kmoddir}/kernel/net/ipv4/gre.ko.* +%{_cross_kmoddir}/kernel/net/ipv4/inet_diag.ko.* +%{_cross_kmoddir}/kernel/net/ipv4/ipcomp.ko.* +%{_cross_kmoddir}/kernel/net/ipv4/ip_gre.ko.* +%{_cross_kmoddir}/kernel/net/ipv4/ipip.ko.* +%{_cross_kmoddir}/kernel/net/ipv4/ip_tunnel.ko.* +%{_cross_kmoddir}/kernel/net/ipv4/ip_vti.ko.* +%{_cross_kmoddir}/kernel/net/ipv4/netfilter/arptable_filter.ko.* +%{_cross_kmoddir}/kernel/net/ipv4/netfilter/arp_tables.ko.* +%{_cross_kmoddir}/kernel/net/ipv4/netfilter/arpt_mangle.ko.* +%{_cross_kmoddir}/kernel/net/ipv4/netfilter/iptable_filter.ko.* +%{_cross_kmoddir}/kernel/net/ipv4/netfilter/iptable_mangle.ko.* +%{_cross_kmoddir}/kernel/net/ipv4/netfilter/iptable_nat.ko.* +%{_cross_kmoddir}/kernel/net/ipv4/netfilter/iptable_raw.ko.* +%{_cross_kmoddir}/kernel/net/ipv4/netfilter/iptable_security.ko.* +%{_cross_kmoddir}/kernel/net/ipv4/netfilter/ipt_ah.ko.* +%{_cross_kmoddir}/kernel/net/ipv4/netfilter/ipt_CLUSTERIP.ko.* +%{_cross_kmoddir}/kernel/net/ipv4/netfilter/ipt_ECN.ko.* +%{_cross_kmoddir}/kernel/net/ipv4/netfilter/ipt_REJECT.ko.* +%{_cross_kmoddir}/kernel/net/ipv4/netfilter/ipt_rpfilter.ko.* +%{_cross_kmoddir}/kernel/net/ipv4/netfilter/ipt_SYNPROXY.ko.* +%{_cross_kmoddir}/kernel/net/ipv4/netfilter/nf_defrag_ipv4.ko.* +%{_cross_kmoddir}/kernel/net/ipv4/netfilter/nf_dup_ipv4.ko.* +%{_cross_kmoddir}/kernel/net/ipv4/netfilter/nf_nat_h323.ko.* +%{_cross_kmoddir}/kernel/net/ipv4/netfilter/nf_nat_pptp.ko.* +%{_cross_kmoddir}/kernel/net/ipv4/netfilter/nf_nat_snmp_basic.ko.* +%{_cross_kmoddir}/kernel/net/ipv4/netfilter/nf_reject_ipv4.ko.* +%{_cross_kmoddir}/kernel/net/ipv4/netfilter/nf_socket_ipv4.ko.* +%{_cross_kmoddir}/kernel/net/ipv4/netfilter/nft_dup_ipv4.ko.* +%{_cross_kmoddir}/kernel/net/ipv4/netfilter/nft_fib_ipv4.ko.* +%{_cross_kmoddir}/kernel/net/ipv4/netfilter/nf_tproxy_ipv4.ko.* +%{_cross_kmoddir}/kernel/net/ipv4/netfilter/nft_reject_ipv4.ko.* +%{_cross_kmoddir}/kernel/net/ipv4/raw_diag.ko.* +%{_cross_kmoddir}/kernel/net/ipv4/tcp_bbr.ko.* +%{_cross_kmoddir}/kernel/net/ipv4/tcp_bic.ko.* +%{_cross_kmoddir}/kernel/net/ipv4/tcp_dctcp.ko.* +%{_cross_kmoddir}/kernel/net/ipv4/tcp_diag.ko.* +%{_cross_kmoddir}/kernel/net/ipv4/tcp_highspeed.ko.* +%{_cross_kmoddir}/kernel/net/ipv4/tcp_htcp.ko.* +%{_cross_kmoddir}/kernel/net/ipv4/tcp_hybla.ko.* +%{_cross_kmoddir}/kernel/net/ipv4/tcp_illinois.ko.* +%{_cross_kmoddir}/kernel/net/ipv4/tcp_lp.ko.* +%{_cross_kmoddir}/kernel/net/ipv4/tcp_scalable.ko.* +%{_cross_kmoddir}/kernel/net/ipv4/tcp_vegas.ko.* +%{_cross_kmoddir}/kernel/net/ipv4/tcp_veno.ko.* +%{_cross_kmoddir}/kernel/net/ipv4/tcp_westwood.ko.* +%{_cross_kmoddir}/kernel/net/ipv4/tcp_yeah.ko.* +%{_cross_kmoddir}/kernel/net/ipv4/tunnel4.ko.* +%{_cross_kmoddir}/kernel/net/ipv4/udp_diag.ko.* +%{_cross_kmoddir}/kernel/net/ipv4/udp_tunnel.ko.* +%{_cross_kmoddir}/kernel/net/ipv4/xfrm4_tunnel.ko.* +%{_cross_kmoddir}/kernel/net/ipv6/ah6.ko.* +%{_cross_kmoddir}/kernel/net/ipv6/esp6.ko.* +%{_cross_kmoddir}/kernel/net/ipv6/esp6_offload.ko.* +%{_cross_kmoddir}/kernel/net/ipv6/fou6.ko.* +%{_cross_kmoddir}/kernel/net/ipv6/ila/ila.ko.* +%{_cross_kmoddir}/kernel/net/ipv6/ip6_gre.ko.* +%{_cross_kmoddir}/kernel/net/ipv6/ip6_tunnel.ko.* +%{_cross_kmoddir}/kernel/net/ipv6/ip6_udp_tunnel.ko.* +%{_cross_kmoddir}/kernel/net/ipv6/ip6_vti.ko.* +%{_cross_kmoddir}/kernel/net/ipv6/ipcomp6.ko.* +%{_cross_kmoddir}/kernel/net/ipv6/mip6.ko.* +%{_cross_kmoddir}/kernel/net/ipv6/netfilter/ip6table_filter.ko.* +%{_cross_kmoddir}/kernel/net/ipv6/netfilter/ip6table_mangle.ko.* +%{_cross_kmoddir}/kernel/net/ipv6/netfilter/ip6table_nat.ko.* +%{_cross_kmoddir}/kernel/net/ipv6/netfilter/ip6table_raw.ko.* +%{_cross_kmoddir}/kernel/net/ipv6/netfilter/ip6table_security.ko.* +%{_cross_kmoddir}/kernel/net/ipv6/netfilter/ip6t_ah.ko.* +%{_cross_kmoddir}/kernel/net/ipv6/netfilter/ip6t_eui64.ko.* +%{_cross_kmoddir}/kernel/net/ipv6/netfilter/ip6t_frag.ko.* +%{_cross_kmoddir}/kernel/net/ipv6/netfilter/ip6t_hbh.ko.* +%{_cross_kmoddir}/kernel/net/ipv6/netfilter/ip6t_ipv6header.ko.* +%{_cross_kmoddir}/kernel/net/ipv6/netfilter/ip6t_mh.ko.* +%{_cross_kmoddir}/kernel/net/ipv6/netfilter/ip6t_REJECT.ko.* +%{_cross_kmoddir}/kernel/net/ipv6/netfilter/ip6t_rpfilter.ko.* +%{_cross_kmoddir}/kernel/net/ipv6/netfilter/ip6t_rt.ko.* +%{_cross_kmoddir}/kernel/net/ipv6/netfilter/ip6t_srh.ko.* +%{_cross_kmoddir}/kernel/net/ipv6/netfilter/ip6t_SYNPROXY.ko.* +%{_cross_kmoddir}/kernel/net/ipv6/netfilter/nf_defrag_ipv6.ko.* +%{_cross_kmoddir}/kernel/net/ipv6/netfilter/nf_dup_ipv6.ko.* +%{_cross_kmoddir}/kernel/net/ipv6/netfilter/nf_reject_ipv6.ko.* +%{_cross_kmoddir}/kernel/net/ipv6/netfilter/nf_socket_ipv6.ko.* +%{_cross_kmoddir}/kernel/net/ipv6/netfilter/nft_dup_ipv6.ko.* +%{_cross_kmoddir}/kernel/net/ipv6/netfilter/nft_fib_ipv6.ko.* +%{_cross_kmoddir}/kernel/net/ipv6/netfilter/nf_tproxy_ipv6.ko.* +%{_cross_kmoddir}/kernel/net/ipv6/netfilter/nft_reject_ipv6.ko.* +%{_cross_kmoddir}/kernel/net/ipv6/sit.ko.* +%{_cross_kmoddir}/kernel/net/ipv6/tunnel6.ko.* +%{_cross_kmoddir}/kernel/net/ipv6/xfrm6_tunnel.ko.* +%{_cross_kmoddir}/kernel/net/key/af_key.ko.* +%{_cross_kmoddir}/kernel/net/llc/llc.ko.* +%{_cross_kmoddir}/kernel/net/mpls/mpls_gso.ko.* +%{_cross_kmoddir}/kernel/net/mpls/mpls_iptunnel.ko.* +%{_cross_kmoddir}/kernel/net/mpls/mpls_router.ko.* +%{_cross_kmoddir}/kernel/net/mptcp/mptcp_diag.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/ipset/ip_set_bitmap_ip.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/ipset/ip_set_bitmap_ipmac.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/ipset/ip_set_bitmap_port.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/ipset/ip_set_hash_ip.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/ipset/ip_set_hash_ipmac.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/ipset/ip_set_hash_ipmark.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/ipset/ip_set_hash_ipportip.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/ipset/ip_set_hash_ipport.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/ipset/ip_set_hash_ipportnet.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/ipset/ip_set_hash_mac.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/ipset/ip_set_hash_netiface.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/ipset/ip_set_hash_net.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/ipset/ip_set_hash_netnet.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/ipset/ip_set_hash_netport.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/ipset/ip_set_hash_netportnet.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/ipset/ip_set.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/ipset/ip_set_list_set.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/ipvs/ip_vs_dh.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/ipvs/ip_vs_fo.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/ipvs/ip_vs_ftp.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/ipvs/ip_vs.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/ipvs/ip_vs_lblc.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/ipvs/ip_vs_lblcr.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/ipvs/ip_vs_lc.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/ipvs/ip_vs_mh.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/ipvs/ip_vs_nq.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/ipvs/ip_vs_ovf.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/ipvs/ip_vs_pe_sip.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/ipvs/ip_vs_rr.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/ipvs/ip_vs_sed.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/ipvs/ip_vs_sh.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/ipvs/ip_vs_wlc.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/ipvs/ip_vs_wrr.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/nf_conncount.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/nf_conntrack_amanda.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/nf_conntrack_broadcast.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/nf_conntrack_ftp.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/nf_conntrack_h323.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/nf_conntrack_irc.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/nf_conntrack.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/nf_conntrack_netbios_ns.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/nf_conntrack_netlink.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/nf_conntrack_pptp.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/nf_conntrack_sane.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/nf_conntrack_sip.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/nf_conntrack_snmp.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/nf_conntrack_tftp.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/nf_dup_netdev.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/nf_flow_table_inet.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/nf_flow_table.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/nf_log_syslog.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/nf_nat_amanda.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/nf_nat_ftp.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/nf_nat_irc.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/nf_nat.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/nf_nat_sip.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/nf_nat_tftp.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/nfnetlink_acct.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/nfnetlink_cthelper.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/nfnetlink_cttimeout.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/nfnetlink.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/nfnetlink_log.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/nfnetlink_osf.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/nfnetlink_queue.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/nf_synproxy_core.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/nf_tables.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/nft_chain_nat.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/nft_compat.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/nft_connlimit.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/nft_ct.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/nft_dup_netdev.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/nft_fib_inet.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/nft_fib.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/nft_fib_netdev.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/nft_flow_offload.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/nft_fwd_netdev.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/nft_hash.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/nft_limit.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/nft_log.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/nft_masq.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/nft_nat.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/nft_numgen.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/nft_objref.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/nft_osf.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/nft_queue.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/nft_quota.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/nft_redir.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/nft_reject_inet.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/nft_reject.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/nft_socket.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/nft_synproxy.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/nft_tproxy.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/nft_tunnel.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/nft_xfrm.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_addrtype.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_AUDIT.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_bpf.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_cgroup.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_CHECKSUM.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_CLASSIFY.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_cluster.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_comment.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_connbytes.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_connlabel.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_connlimit.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_connmark.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_CONNSECMARK.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_conntrack.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_cpu.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_CT.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_devgroup.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_dscp.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_DSCP.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_ecn.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_esp.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_hashlimit.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_helper.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_hl.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_HL.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_HMARK.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_IDLETIMER.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_ipcomp.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_iprange.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_ipvs.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_l2tp.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_length.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_limit.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_LOG.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_mac.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_mark.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_MASQUERADE.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_multiport.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_nat.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_NETMAP.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_nfacct.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_NFLOG.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_NFQUEUE.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_osf.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_owner.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_physdev.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_pkttype.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_policy.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_quota.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_rateest.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_RATEEST.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_realm.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_recent.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_REDIRECT.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_sctp.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_SECMARK.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_set.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_socket.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_state.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_statistic.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_string.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_tcpmss.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_TCPMSS.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_TCPOPTSTRIP.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_TEE.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_time.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_TPROXY.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_TRACE.ko.* +%{_cross_kmoddir}/kernel/net/netfilter/xt_u32.ko.* +%{_cross_kmoddir}/kernel/net/nsh/nsh.ko.* +%{_cross_kmoddir}/kernel/net/openvswitch/openvswitch.ko.* +%{_cross_kmoddir}/kernel/net/openvswitch/vport-geneve.ko.* +%{_cross_kmoddir}/kernel/net/openvswitch/vport-gre.ko.* +%{_cross_kmoddir}/kernel/net/openvswitch/vport-vxlan.ko.* +%{_cross_kmoddir}/kernel/net/packet/af_packet_diag.ko.* +%{_cross_kmoddir}/kernel/net/psample/psample.ko.* +%{_cross_kmoddir}/kernel/net/sched/act_bpf.ko.* +%{_cross_kmoddir}/kernel/net/sched/act_connmark.ko.* +%{_cross_kmoddir}/kernel/net/sched/act_csum.ko.* +%{_cross_kmoddir}/kernel/net/sched/act_gact.ko.* +%{_cross_kmoddir}/kernel/net/sched/act_ipt.ko.* +%{_cross_kmoddir}/kernel/net/sched/act_mirred.ko.* +%{_cross_kmoddir}/kernel/net/sched/act_nat.ko.* +%{_cross_kmoddir}/kernel/net/sched/act_pedit.ko.* +%{_cross_kmoddir}/kernel/net/sched/act_police.ko.* +%{_cross_kmoddir}/kernel/net/sched/act_sample.ko.* +%{_cross_kmoddir}/kernel/net/sched/act_simple.ko.* +%{_cross_kmoddir}/kernel/net/sched/act_skbedit.ko.* +%{_cross_kmoddir}/kernel/net/sched/act_vlan.ko.* +%{_cross_kmoddir}/kernel/net/sched/cls_basic.ko.* +%{_cross_kmoddir}/kernel/net/sched/cls_bpf.ko.* +%{_cross_kmoddir}/kernel/net/sched/cls_cgroup.ko.* +%{_cross_kmoddir}/kernel/net/sched/cls_flower.ko.* +%{_cross_kmoddir}/kernel/net/sched/cls_flow.ko.* +%{_cross_kmoddir}/kernel/net/sched/cls_fw.ko.* +%{_cross_kmoddir}/kernel/net/sched/cls_route.ko.* +%{_cross_kmoddir}/kernel/net/sched/cls_u32.ko.* +%{_cross_kmoddir}/kernel/net/sched/em_cmp.ko.* +%{_cross_kmoddir}/kernel/net/sched/em_ipset.ko.* +%{_cross_kmoddir}/kernel/net/sched/em_ipt.ko.* +%{_cross_kmoddir}/kernel/net/sched/em_meta.ko.* +%{_cross_kmoddir}/kernel/net/sched/em_nbyte.ko.* +%{_cross_kmoddir}/kernel/net/sched/em_text.ko.* +%{_cross_kmoddir}/kernel/net/sched/em_u32.ko.* +%{_cross_kmoddir}/kernel/net/sched/sch_cbs.ko.* +%{_cross_kmoddir}/kernel/net/sched/sch_choke.ko.* +%{_cross_kmoddir}/kernel/net/sched/sch_codel.ko.* +%{_cross_kmoddir}/kernel/net/sched/sch_drr.ko.* +%{_cross_kmoddir}/kernel/net/sched/sch_fq_codel.ko.* +%{_cross_kmoddir}/kernel/net/sched/sch_fq.ko.* +%{_cross_kmoddir}/kernel/net/sched/sch_gred.ko.* +%{_cross_kmoddir}/kernel/net/sched/sch_hfsc.ko.* +%{_cross_kmoddir}/kernel/net/sched/sch_hhf.ko.* +%{_cross_kmoddir}/kernel/net/sched/sch_htb.ko.* +%{_cross_kmoddir}/kernel/net/sched/sch_ingress.ko.* +%{_cross_kmoddir}/kernel/net/sched/sch_mqprio.ko.* +%{_cross_kmoddir}/kernel/net/sched/sch_multiq.ko.* +%{_cross_kmoddir}/kernel/net/sched/sch_netem.ko.* +%{_cross_kmoddir}/kernel/net/sched/sch_pie.ko.* +%{_cross_kmoddir}/kernel/net/sched/sch_plug.ko.* +%{_cross_kmoddir}/kernel/net/sched/sch_prio.ko.* +%{_cross_kmoddir}/kernel/net/sched/sch_qfq.ko.* +%{_cross_kmoddir}/kernel/net/sched/sch_red.ko.* +%{_cross_kmoddir}/kernel/net/sched/sch_sfb.ko.* +%{_cross_kmoddir}/kernel/net/sched/sch_sfq.ko.* +%{_cross_kmoddir}/kernel/net/sched/sch_tbf.ko.* +%{_cross_kmoddir}/kernel/net/sched/sch_teql.ko.* +%{_cross_kmoddir}/kernel/net/sctp/sctp_diag.ko.* +%{_cross_kmoddir}/kernel/net/sctp/sctp.ko.* +%{_cross_kmoddir}/kernel/net/sunrpc/auth_gss/auth_rpcgss.ko.* +%{_cross_kmoddir}/kernel/net/sunrpc/auth_gss/rpcsec_gss_krb5.ko.* +%{_cross_kmoddir}/kernel/net/sunrpc/sunrpc.ko.* +%{_cross_kmoddir}/kernel/net/tls/tls.ko.* +%{_cross_kmoddir}/kernel/net/unix/unix_diag.ko.* +%{_cross_kmoddir}/kernel/net/vmw_vsock/vmw_vsock_virtio_transport_common.ko.* +%{_cross_kmoddir}/kernel/net/vmw_vsock/vmw_vsock_virtio_transport.ko.* +%{_cross_kmoddir}/kernel/net/vmw_vsock/vsock_diag.ko.* +%{_cross_kmoddir}/kernel/net/vmw_vsock/vsock.ko.* +%{_cross_kmoddir}/kernel/net/vmw_vsock/vsock_loopback.ko.* +%if "%{_cross_arch}" == "x86_64" +%{_cross_kmoddir}/kernel/net/vmw_vsock/hv_sock.ko.* +%{_cross_kmoddir}/kernel/net/vmw_vsock/vmw_vsock_vmci_transport.ko.* +%endif +%{_cross_kmoddir}/kernel/net/xfrm/xfrm_algo.ko.* +%{_cross_kmoddir}/kernel/net/xfrm/xfrm_ipcomp.ko.* +%{_cross_kmoddir}/kernel/net/xfrm/xfrm_user.ko.* +%{_cross_kmoddir}/kernel/security/keys/encrypted-keys/encrypted-keys.ko.* +%{_cross_kmoddir}/kernel/security/keys/trusted-keys/trusted.ko.* +%if "%{_cross_arch}" == "x86_64" +%{_cross_kmoddir}/kernel/virt/lib/irqbypass.ko.* +%endif + +%files modules-metal +%if "%{_cross_arch}" == "x86_64" +%{_cross_kmoddir}/kernel/drivers/infiniband/hw/usnic/usnic_verbs.ko.gz +%endif +%{_cross_kmoddir}/kernel/drivers/net/ethernet/amd/xgbe/amd-xgbe.ko.gz +%{_cross_kmoddir}/kernel/drivers/net/ethernet/broadcom/bnx2x/bnx2x.ko.gz +%{_cross_kmoddir}/kernel/drivers/net/ethernet/broadcom/bnxt/bnxt_en.ko.gz +%{_cross_kmoddir}/kernel/drivers/net/ethernet/broadcom/tg3.ko.gz +%{_cross_kmoddir}/kernel/drivers/net/ethernet/chelsio/cxgb4/cxgb4.ko.gz +%{_cross_kmoddir}/kernel/drivers/net/ethernet/chelsio/cxgb4vf/cxgb4vf.ko.gz +%{_cross_kmoddir}/kernel/drivers/net/ethernet/cisco/enic/enic.ko.gz +%{_cross_kmoddir}/kernel/drivers/net/ethernet/emulex/benet/be2net.ko.gz +%{_cross_kmoddir}/kernel/drivers/net/ethernet/huawei/hinic/hinic.ko.gz +%{_cross_kmoddir}/kernel/drivers/net/ethernet/intel/fm10k/fm10k.ko.gz +%{_cross_kmoddir}/kernel/drivers/net/ethernet/intel/i40e/i40e.ko.gz +%{_cross_kmoddir}/kernel/drivers/net/ethernet/intel/ice/ice.ko.gz +%{_cross_kmoddir}/kernel/drivers/net/ethernet/intel/igbvf/igbvf.ko.gz +%{_cross_kmoddir}/kernel/drivers/net/ethernet/intel/ixgb/ixgb.ko.gz +%{_cross_kmoddir}/kernel/drivers/net/ethernet/intel/ixgbe/ixgbe.ko.gz +%{_cross_kmoddir}/kernel/drivers/net/ethernet/myricom/myri10ge/myri10ge.ko.gz +%{_cross_kmoddir}/kernel/drivers/net/ethernet/pensando/ionic/ionic.ko.gz +%{_cross_kmoddir}/kernel/drivers/net/ethernet/qlogic/qed/qed.ko.gz +%{_cross_kmoddir}/kernel/drivers/net/ethernet/qlogic/qede/qede.ko.gz +%{_cross_kmoddir}/kernel/drivers/net/ethernet/qlogic/qlcnic/qlcnic.ko.gz +%{_cross_kmoddir}/kernel/drivers/net/ethernet/sfc/falcon/sfc-falcon.ko.gz +%{_cross_kmoddir}/kernel/drivers/net/ethernet/sfc/sfc.ko.gz +%{_cross_kmoddir}/kernel/drivers/net/mdio.ko.gz +%{_cross_kmoddir}/kernel/drivers/scsi/snic/snic.ko.gz + +%if "%{_cross_arch}" == "x86_64" +%files modules-neuron +%{_cross_kmoddir}/extra/neuron.ko.gz +%{_cross_unitdir}/sysinit.target.d/neuron.conf +%{_cross_unitdir}/modprobe@neuron.service.d/neuron.conf +%endif + +%changelog diff --git a/packages/kernel-6.1/latest-kernel-srpm-url.sh b/packages/kernel-6.1/latest-kernel-srpm-url.sh new file mode 100755 index 00000000..b13fcbf9 --- /dev/null +++ b/packages/kernel-6.1/latest-kernel-srpm-url.sh @@ -0,0 +1,6 @@ +#!/bin/sh +cmd='dnf install -q -y --releasever=latest yum-utils && yumdownloader -q --releasever=latest --source --urls kernel' +docker run --rm amazonlinux:2023 sh -c "${cmd}" \ + | grep '^http' \ + | xargs --max-args=1 --no-run-if-empty realpath --canonicalize-missing --relative-to=. \ + | sed 's_:/_://_' diff --git a/packages/kernel-6.1/latest-neuron-srpm-url.sh b/packages/kernel-6.1/latest-neuron-srpm-url.sh new file mode 100755 index 00000000..5bb6c85e --- /dev/null +++ b/packages/kernel-6.1/latest-neuron-srpm-url.sh @@ -0,0 +1,9 @@ +#!/bin/sh +cmd=" +dnf install -q -y --releasever=latest yum-utils && +dnf download -q --repofrompath neuron,https://yum.repos.neuron.amazonaws.com --repo=neuron --urls aws-neuronx-dkms +" +docker run --rm amazonlinux:2023 bash -c "${cmd}" \ + | grep '^http' \ + | xargs --max-args=1 --no-run-if-empty realpath --canonicalize-missing --relative-to=. \ + | sed 's_:/_://_' diff --git a/packages/kernel-6.1/modprobe@neuron.service.drop-in.conf b/packages/kernel-6.1/modprobe@neuron.service.drop-in.conf new file mode 100644 index 00000000..e9174355 --- /dev/null +++ b/packages/kernel-6.1/modprobe@neuron.service.drop-in.conf @@ -0,0 +1,7 @@ +[Unit] +ConditionPathExists=!/etc/.neuron-modprobe-done + +[Service] +ExecCondition=/usr/bin/touch /etc/.neuron-modprobe-done +ExecCondition=/usr/bin/ghostdog neuron-present +RemainAfterExit=true diff --git a/packages/kernel-6.1/neuron-sysinit.target.drop-in.conf b/packages/kernel-6.1/neuron-sysinit.target.drop-in.conf new file mode 100644 index 00000000..11c78234 --- /dev/null +++ b/packages/kernel-6.1/neuron-sysinit.target.drop-in.conf @@ -0,0 +1,2 @@ +[Unit] +Wants=modprobe@neuron.service diff --git a/packages/kernel-6.1/var-lib-kernel-devel-lower.mount.drop-in.conf.in b/packages/kernel-6.1/var-lib-kernel-devel-lower.mount.drop-in.conf.in new file mode 100644 index 00000000..a56abe6c --- /dev/null +++ b/packages/kernel-6.1/var-lib-kernel-devel-lower.mount.drop-in.conf.in @@ -0,0 +1,4 @@ +[Mount] +What=PREFIX/share/bottlerocket/kernel-devel +Type=none +Options=rbind,rshared diff --git a/packages/kmod-5.10-nvidia/.gitignore b/packages/kmod-5.10-nvidia/.gitignore new file mode 100644 index 00000000..db8b415b --- /dev/null +++ b/packages/kmod-5.10-nvidia/.gitignore @@ -0,0 +1,3 @@ +NVidiaEULAforAWS.pdf +COPYING +*.rpm diff --git a/packages/kmod-5.10-nvidia/Cargo.toml b/packages/kmod-5.10-nvidia/Cargo.toml new file mode 100644 index 00000000..9aef3c63 --- /dev/null +++ b/packages/kmod-5.10-nvidia/Cargo.toml @@ -0,0 +1,45 @@ +[package] +name = "kmod-5_10-nvidia" +version = "0.1.0" +edition = "2021" +publish = false +build = "../build.rs" + +[lib] +path = "../packages.rs" + +[package.metadata.build-package] +package-name = "kmod-5.10-nvidia" +releases-url = "https://docs.nvidia.com/datacenter/tesla/" + +[[package.metadata.build-package.external-files]] +url = "https://s3.amazonaws.com/EULA/NVidiaEULAforAWS.pdf" +sha512 = "e1926fe99afc3ab5b2f2744fcd53b4046465aefb2793e2e06c4a19455a3fde895e00af1415ff1a5804c32e6a2ed0657e475de63da6c23a0e9c59feeef52f3f58" + +[[package.metadata.build-package.external-files]] +url = "https://us.download.nvidia.com/tesla/535.216.01/NVIDIA-Linux-x86_64-535.216.01.run" +sha512 = "3b4ae3584368fcc5f81a680dd8588d8b9e48f43dafe2490f5414ed258fa8c9799ebd40d2fd115e20bd02648eeb3e5c6dff39562d89353580fa679d011cebf6f8" +force-upstream = true + +[[package.metadata.build-package.external-files]] +url = "https://us.download.nvidia.com/tesla/535.216.01/NVIDIA-Linux-aarch64-535.216.01.run" +sha512 = "f68794249bf18ba626c6a665880721c8cc0dada6c7c1d8b15bf17174a4cac35ca2ab534fff2410c8bc0326c48f6ab913b6d9a92630505eeb768e02610a7772d9" +force-upstream = true + +[[package.metadata.build-package.external-files]] +url = "https://developer.download.nvidia.com/compute/cuda/repos/rhel9/x86_64/nvidia-fabric-manager-535.216.01-1.x86_64.rpm" +sha512 = "9208004779a57418cef4e0eacfad549e01fc3e193cda24a4f809325fee3a74910350c7752372d5dba7b74e9d5bf9da5807bc8de2bedade6dbe23b270c3047dfe" +force-upstream = true + +[[package.metadata.build-package.external-files]] +url = "https://developer.download.nvidia.com/compute/cuda/repos/rhel9/sbsa/nvidia-fabric-manager-535.216.01-1.aarch64.rpm" +sha512 = "1f553e4627953cceef8f630d2be907829f8b78b789ffee7691ace541f759bdb07016e364c20e1d5779ce463f0b48448cea292f58a9899523ec840bb5a0c37b0e" +force-upstream = true + +[[package.metadata.build-package.external-files]] +url = "https://raw.githubusercontent.com/NVIDIA/open-gpu-kernel-modules/535/COPYING" +sha512 = "f9cee68cbb12095af4b4e92d01c210461789ef41c70b64efefd6719d0b88468b7a67a3629c432d4d9304c730b5d1a942228a5bcc74a03ab1c411c77c758cd938" +force-upstream = true + +[build-dependencies] +kernel-5_10 = { path = "../kernel-5.10" } diff --git a/packages/kmod-5.10-nvidia/copy-open-gpu-kernel-modules.service.in b/packages/kmod-5.10-nvidia/copy-open-gpu-kernel-modules.service.in new file mode 100644 index 00000000..2c3420b6 --- /dev/null +++ b/packages/kmod-5.10-nvidia/copy-open-gpu-kernel-modules.service.in @@ -0,0 +1,20 @@ +[Unit] +Description=Copy open GPU kernel modules +RequiresMountsFor=PREFIX/lib/modules PREFIX/src/kernels +# Rerunning this service after the system is fully loaded will override +# the already linked kernel modules. This doesn't affect the running system, +# since kernel modules are linked early in the boot sequence, but we still +# disable manual restarts to prevent unnecessary kernel modules rewrites. +RefuseManualStart=true +RefuseManualStop=true + +[Service] +Type=oneshot +ExecCondition=/usr/bin/ghostdog match-nvidia-driver open-gpu +ExecStart=/usr/bin/driverdog --modules-set nvidia-open-gpu link-modules +ExecStart=/usr/bin/driverdog --modules-set nvidia-open-gpu-copy-only link-modules +RemainAfterExit=true +StandardError=journal+console + +[Install] +RequiredBy=preconfigured.target diff --git a/packages/kmod-5.10-nvidia/kmod-5.10-nvidia.spec b/packages/kmod-5.10-nvidia/kmod-5.10-nvidia.spec new file mode 100644 index 00000000..7e051afb --- /dev/null +++ b/packages/kmod-5.10-nvidia/kmod-5.10-nvidia.spec @@ -0,0 +1,540 @@ +%global tesla_major 535 +%global tesla_minor 216 +%global tesla_patch 01 +%global tesla_ver %{tesla_major}.%{tesla_minor}.%{tesla_patch} +%if "%{?_cross_arch}" == "aarch64" +%global fm_arch sbsa +%else +%global fm_arch %{_cross_arch} +%endif + +# With the split of the firmware binary from firmware/gsp.bin to firmware/gsp_ga10x.bin +# and firmware/gsp_tu10x.bin the file format changed from executable to relocatable. +# The __spec_install_post macro will by default try to strip all binary files. +# Unfortunately the strip used is not compatible with the new file format. +# Redefine strip, so that these firmware binaries do not derail the build. +%global __strip /usr/bin/true + +Name: %{_cross_os}kmod-5.10-nvidia +Version: 1.0.0 +Release: 1%{?dist} +Epoch: 1 +Summary: NVIDIA drivers for the 5.10 kernel +# We use these licences because we only ship our own software in the main package, +# each subpackage includes the LICENSE file provided by the Licenses.toml file +License: Apache-2.0 OR MIT +URL: http://www.nvidia.com/ + +# NVIDIA archives from 0 to 199 +# NVIDIA .run scripts for kernel and userspace drivers +Source0: https://us.download.nvidia.com/tesla/%{tesla_ver}/NVIDIA-Linux-x86_64-%{tesla_ver}.run +Source1: https://us.download.nvidia.com/tesla/%{tesla_ver}/NVIDIA-Linux-aarch64-%{tesla_ver}.run +Source2: NVidiaEULAforAWS.pdf +Source3: COPYING + +# fabricmanager for NVSwitch +Source10: https://developer.download.nvidia.com/compute/cuda/repos/rhel9/x86_64/nvidia-fabric-manager-%{tesla_ver}-1.x86_64.rpm +Source11: https://developer.download.nvidia.com/compute/cuda/repos/rhel9/sbsa/nvidia-fabric-manager-%{tesla_ver}-1.aarch64.rpm + +# Common NVIDIA conf files from 200 to 299 +Source200: nvidia-tmpfiles.conf.in +Source202: nvidia-dependencies-modules-load.conf +Source203: nvidia-fabricmanager.service +Source204: nvidia-fabricmanager.cfg +Source205: nvidia-sysusers.conf +Source206: nvidia-persistenced.service + +# NVIDIA tesla conf files from 300 to 399 +Source300: nvidia-tesla-tmpfiles.conf +Source301: nvidia-tesla-build-config.toml.in +Source302: nvidia-open-gpu-config.toml.in +Source303: nvidia-open-gpu-copy-only-config.toml.in +Source304: nvidia-tesla-path.env.in +Source305: nvidia-ld.so.conf.in +Source306: link-tesla-kernel-modules.service.in +Source307: load-tesla-kernel-modules.service.in +Source308: copy-open-gpu-kernel-modules.service.in +Source309: load-open-gpu-kernel-modules.service.in + +BuildRequires: %{_cross_os}kernel-5.10-archive + +%description +%{summary}. + +%package fabricmanager +Summary: NVIDIA fabricmanager config and service files +Requires: %{name}-tesla(fabricmanager) + +%description fabricmanager +%{summary}. + +%package open-gpu-%{tesla_major} +Summary: NVIDIA %{tesla_major} Open GPU driver +Version: %{tesla_ver} +License: MIT AND GPL-2.0-only +Requires: %{_cross_os}variant-platform(aws) + +%description open-gpu-%{tesla_major} +%{summary}. + +%package tesla-%{tesla_major} +Summary: NVIDIA %{tesla_major} Tesla driver +Version: %{tesla_ver} +License: LicenseRef-NVIDIA-AWS-EULA +Requires: %{_cross_os}variant-platform(aws) +Requires: %{name} +Requires: %{name}-fabricmanager +Provides: %{name}-tesla(fabricmanager) +Requires: %{name}-open-gpu-%{tesla_major} + +%description tesla-%{tesla_major} +%{summary} + +%prep +# Extract nvidia sources with `-x`, otherwise the script will try to install +# the driver in the current run +sh %{_sourcedir}/NVIDIA-Linux-%{_cross_arch}-%{tesla_ver}.run -x + +# Extract fabricmanager from the rpm via cpio rather than `%%setup` since the +# correct source is architecture-dependent. +mkdir fabricmanager-linux-%{fm_arch}-%{tesla_ver}-archive +rpm2cpio %{_sourcedir}/nvidia-fabric-manager-%{tesla_ver}-1.%{_cross_arch}.rpm | cpio -idmV -D fabricmanager-linux-%{fm_arch}-%{tesla_ver}-archive + +# Add the license. +install -p -m 0644 %{S:2} . +install -p -m 0644 %{S:3} . + +%global kernel_sources %{_builddir}/kernel-devel +tar -xf %{_cross_datadir}/bottlerocket/kernel-devel.tar.xz + +%define _kernel_version %(ls %{kernel_sources}/include/config/kernel.release) +%global _cross_kmoddir %{_cross_libdir}/modules/%{_kernel_version} + +# This recipe was based in the NVIDIA yum/dnf specs: +# https://github.com/NVIDIA/yum-packaging-precompiled-kmod + +# Begin open driver build +pushd NVIDIA-Linux-%{_cross_arch}-%{tesla_ver}/kernel-open + +# We set IGNORE_CC_MISMATCH even though we are using the same compiler used to compile the kernel, if +# we don't set this flag the compilation fails +make %{?_smp_mflags} ARCH=%{_cross_karch} IGNORE_CC_MISMATCH=1 SYSSRC=%{kernel_sources} CC=%{_cross_target}-gcc LD=%{_cross_target}-ld + +# end open driver build +popd + +# Begin proprietary driver build +pushd NVIDIA-Linux-%{_cross_arch}-%{tesla_ver}/kernel + +# We set IGNORE_CC_MISMATCH even though we are using the same compiler used to compile the kernel, if +# we don't set this flag the compilation fails +make %{?_smp_mflags} ARCH=%{_cross_karch} IGNORE_CC_MISMATCH=1 SYSSRC=%{kernel_sources} CC=%{_cross_target}-gcc LD=%{_cross_target}-ld + +%{_cross_target}-strip -g --strip-unneeded nvidia/nv-interface.o +%{_cross_target}-strip -g --strip-unneeded nvidia-uvm.o +%{_cross_target}-strip -g --strip-unneeded nvidia-drm.o +%{_cross_target}-strip -g --strip-unneeded nvidia-peermem/nvidia-peermem.o +%{_cross_target}-strip -g --strip-unneeded nvidia-modeset/nv-modeset-interface.o + +# We delete these files since we just stripped the input .o files above, and +# will be build at runtime in the host +rm nvidia{,-modeset,-peermem}.o + +# Delete the .ko files created in make command, just to be safe that we +# don't include any linked module in the base image +rm nvidia{,-modeset,-peermem,-drm}.ko + +# End proprietary driver build +popd + +# Grab the list of supported devices +pushd NVIDIA-Linux-%{_cross_arch}-%{tesla_ver}/supported-gpus +# We want to grab all the `kernelopen` enabled chips except for this list that is best held back to the proprietary driver +# 10de:1db1 is V100-16G (P3dn) +# 10de:1db5 is V100-32G (P3dn) +# 10de:1eb8 is T4 (G4dn) +# 10de:1eb4 is T4G (G5g) +# 10de:2237 is A10G (G5) +# 10de:27b8 is L4 (G6) +# 10de:26b9 is L40S (G6e) +jq -r '.chips[] | select(.features[] | contains("kernelopen")) | +select(.devid != "0x1DB1" +and .devid != "0x1DB5" +and .devid != "0x1DEB8" +and .devid != "0x1EB4" +and .devid != "0x2237" +and .devid != "0x27B8" +and .devid != "0x26B9")' supported-gpus.json | jq -s '{"open-gpu": .}' > open-gpu-supported-devices.json +# confirm "NVIDIA H100" is in the resulting file to catch shape changes +jq -e '."open-gpu"[] | select(."devid" == "0x2330") | ."features"| index("kernelopen")' open-gpu-supported-devices.json +popd + +%install +install -d %{buildroot}%{_cross_libexecdir} +install -d %{buildroot}%{_cross_libdir} +install -d %{buildroot}%{_cross_tmpfilesdir} +install -d %{buildroot}%{_cross_unitdir} +install -d %{buildroot}%{_cross_factorydir}%{_cross_sysconfdir}/{drivers,ld.so.conf.d} +install -d %{buildroot}%{_cross_sysusersdir} +install -d %{buildroot}%{_cross_bindir} + +KERNEL_VERSION=$(cat %{kernel_sources}/include/config/kernel.release) +sed \ + -e "s|__KERNEL_VERSION__|${KERNEL_VERSION}|" \ + -e "s|__PREFIX__|%{_cross_prefix}|" %{S:200} > nvidia.conf +install -p -m 0644 nvidia.conf %{buildroot}%{_cross_tmpfilesdir} + +# Install modules-load.d drop-in to autoload required kernel modules +install -d %{buildroot}%{_cross_libdir}/modules-load.d +install -p -m 0644 %{S:202} %{buildroot}%{_cross_libdir}/modules-load.d/nvidia-dependencies.conf + +# NVIDIA fabric manager service unit and config +install -p -m 0644 %{S:203} %{buildroot}%{_cross_unitdir} +install -d %{buildroot}%{_cross_factorydir}%{_cross_sysconfdir}/nvidia +install -p -m 0644 %{S:204} %{buildroot}%{_cross_factorydir}%{_cross_sysconfdir}/nvidia/fabricmanager.cfg + +# Begin NVIDIA tesla driver +pushd NVIDIA-Linux-%{_cross_arch}-%{tesla_ver} +# Proprietary driver +install -d %{buildroot}%{_cross_libexecdir}/nvidia/tesla/bin +install -d %{buildroot}%{_cross_libdir}/nvidia/tesla +install -d %{buildroot}%{_cross_datadir}/nvidia/tesla/module-objects.d +install -d %{buildroot}%{_cross_factorydir}/nvidia/tesla +install -d %{buildroot}%{_cross_factorydir}/nvidia/open-gpu +install -d %{buildroot}%{_cross_datadir}/nvidia/open-gpu/drivers + +install -m 0644 %{S:300} %{buildroot}%{_cross_tmpfilesdir}/nvidia-tesla.conf +sed -e 's|__NVIDIA_MODULES__|%{_cross_datadir}/nvidia/tesla/module-objects.d/|' %{S:301} > \ + nvidia-tesla.toml +install -m 0644 nvidia-tesla.toml %{buildroot}%{_cross_factorydir}%{_cross_sysconfdir}/drivers +sed -e 's|__NVIDIA_MODULES__|%{_cross_datadir}/nvidia/open-gpu/drivers/|' %{S:302} > \ + nvidia-open-gpu.toml +install -m 0644 nvidia-open-gpu.toml %{buildroot}%{_cross_factorydir}%{_cross_sysconfdir}/drivers +sed -e 's|__NVIDIA_MODULES__|%{_cross_datadir}/nvidia/open-gpu/drivers/|' %{S:303} > \ + nvidia-open-gpu-copy-only.toml +install -m 0644 nvidia-open-gpu-copy-only.toml %{buildroot}%{_cross_factorydir}%{_cross_sysconfdir}/drivers +# Install nvidia-path environment file, will be used as a drop-in for containerd.service since +# libnvidia-container locates and mounts helper binaries into the containers from either +# `PATH` or `NVIDIA_PATH` +sed -e 's|__NVIDIA_BINDIR__|%{_cross_libexecdir}/nvidia/tesla/bin|' %{S:304} > nvidia-path.env +install -m 0644 nvidia-path.env %{buildroot}%{_cross_factorydir}/nvidia/tesla +# We need to add `_cross_libdir` to the paths loaded by the ldconfig service +# because libnvidia-container uses the `ldcache` file created by the service, to locate and mount the +# libraries into the containers +sed -e 's|__LIBDIR__|%{_cross_libdir}|' %{S:305} > nvidia-tesla.conf +install -m 0644 nvidia-tesla.conf %{buildroot}%{_cross_factorydir}%{_cross_sysconfdir}/ld.so.conf.d/ + +# Services to link/copy/load modules +sed -e 's|PREFIX|%{_cross_prefix}|g' %{S:306} > link-tesla-kernel-modules.service +sed -e 's|PREFIX|%{_cross_prefix}|g' %{S:307} > load-tesla-kernel-modules.service +install -p -m 0644 \ + link-tesla-kernel-modules.service \ + load-tesla-kernel-modules.service \ + %{buildroot}%{_cross_unitdir} + +sed -e 's|PREFIX|%{_cross_prefix}|g' %{S:308} > copy-open-gpu-kernel-modules.service +sed -e 's|PREFIX|%{_cross_prefix}|g' %{S:309} > load-open-gpu-kernel-modules.service +install -p -m 0644 \ + copy-open-gpu-kernel-modules.service \ + load-open-gpu-kernel-modules.service \ + %{buildroot}%{_cross_unitdir} + +# proprietary driver +install kernel/nvidia.mod.o %{buildroot}%{_cross_datadir}/nvidia/tesla/module-objects.d +install kernel/nvidia/nv-interface.o %{buildroot}%{_cross_datadir}/nvidia/tesla/module-objects.d +install kernel/nvidia/nv-kernel.o_binary %{buildroot}%{_cross_datadir}/nvidia/tesla/module-objects.d/nv-kernel.o + +# uvm +install kernel/nvidia-uvm.mod.o %{buildroot}%{_cross_datadir}/nvidia/tesla/module-objects.d +install kernel/nvidia-uvm.o %{buildroot}%{_cross_datadir}/nvidia/tesla/module-objects.d + +# modeset +install kernel/nvidia-modeset.mod.o %{buildroot}%{_cross_datadir}/nvidia/tesla/module-objects.d +install kernel/nvidia-modeset/nv-modeset-interface.o %{buildroot}%{_cross_datadir}/nvidia/tesla/module-objects.d +install kernel/nvidia-modeset/nv-modeset-kernel.o %{buildroot}%{_cross_datadir}/nvidia/tesla/module-objects.d + +# peermem +install kernel/nvidia-peermem.mod.o %{buildroot}%{_cross_datadir}/nvidia/tesla/module-objects.d +install kernel/nvidia-peermem/nvidia-peermem.o %{buildroot}%{_cross_datadir}/nvidia/tesla/module-objects.d + +# drm +install kernel/nvidia-drm.mod.o %{buildroot}/%{_cross_datadir}/nvidia/tesla/module-objects.d +install kernel/nvidia-drm.o %{buildroot}/%{_cross_datadir}/nvidia/tesla/module-objects.d + +# open driver +install -d %{buildroot}%{_cross_datadir}/nvidia/open-gpu/drivers/ +install kernel-open/nvidia.ko %{buildroot}%{_cross_datadir}/nvidia/open-gpu/drivers/ + +# uvm +install kernel-open/nvidia-uvm.ko %{buildroot}%{_cross_datadir}/nvidia/open-gpu/drivers/ + +# modeset +install kernel-open/nvidia-modeset.ko %{buildroot}%{_cross_datadir}/nvidia/open-gpu/drivers/ + +# peermem +install kernel-open/nvidia-peermem.ko %{buildroot}%{_cross_datadir}/nvidia/open-gpu/drivers/ + +# drm +install kernel-open/nvidia-drm.ko %{buildroot}%{_cross_datadir}/nvidia/open-gpu/drivers/ +# end open driver + +# Binaries +install -m 755 nvidia-smi %{buildroot}%{_cross_libexecdir}/nvidia/tesla/bin +install -m 755 nvidia-debugdump %{buildroot}%{_cross_libexecdir}/nvidia/tesla/bin +install -m 755 nvidia-cuda-mps-control %{buildroot}%{_cross_libexecdir}/nvidia/tesla/bin +install -m 755 nvidia-cuda-mps-server %{buildroot}%{_cross_libexecdir}/nvidia/tesla/bin +install -m 755 nvidia-persistenced %{buildroot}%{_cross_libexecdir}/nvidia/tesla/bin/ +install -m 4755 nvidia-modprobe %{buildroot}%{_cross_bindir} +%if "%{_cross_arch}" == "x86_64" +install -m 755 nvidia-ngx-updater %{buildroot}%{_cross_libexecdir}/nvidia/tesla/bin +%endif + +# Users +install -m 0644 %{S:205} %{buildroot}%{_cross_sysusersdir}/nvidia.conf + +# Systemd units +install -m 0644 %{S:206} %{buildroot}%{_cross_unitdir} + +# We install all the libraries, and filter them out in the 'files' section, so we can catch +# when new libraries are added +install -m 755 *.so* %{buildroot}/%{_cross_libdir}/nvidia/tesla/ + +# This library has the same SONAME as libEGL.so.1.1.0, this will cause collisions while +# the symlinks are created. For now, we only symlink libEGL.so.1.1.0. +EXCLUDED_LIBS="libEGL.so.%{tesla_ver}" + +for lib in $(find . -maxdepth 1 -type f -name 'lib*.so.*' -printf '%%P\n'); do + [[ "${EXCLUDED_LIBS}" =~ "${lib}" ]] && continue + soname="$(%{_cross_target}-readelf -d "${lib}" | awk '/SONAME/{print $5}' | tr -d '[]')" + [ -n "${soname}" ] || continue + [ "${lib}" == "${soname}" ] && continue + ln -s "${lib}" %{buildroot}/%{_cross_libdir}/nvidia/tesla/"${soname}" +done + +# Include the firmware file for GSP support +install -d %{buildroot}%{_cross_libdir}/firmware/nvidia/%{tesla_ver} +install -p -m 0644 firmware/gsp_ga10x.bin %{buildroot}%{_cross_libdir}/firmware/nvidia/%{tesla_ver} +install -p -m 0644 firmware/gsp_tu10x.bin %{buildroot}%{_cross_libdir}/firmware/nvidia/%{tesla_ver} + +# Include the open driver supported devices file for runtime matching of the driver. This is consumed by ghostdog to match the driver to this list +install -p -m 0644 supported-gpus/open-gpu-supported-devices.json %{buildroot}%{_cross_datadir}/nvidia/open-gpu-supported-devices.json + +popd + +# Begin NVIDIA fabric manager binaries and topologies +pushd fabricmanager-linux-%{fm_arch}-%{tesla_ver}-archive +install -p -m 0755 usr/bin/nv-fabricmanager %{buildroot}%{_cross_libexecdir}/nvidia/tesla/bin +install -p -m 0755 usr/bin/nvswitch-audit %{buildroot}%{_cross_libexecdir}/nvidia/tesla/bin + +install -d %{buildroot}%{_cross_datadir}/nvidia/tesla/nvswitch +for t in usr/share/nvidia/nvswitch/*_topology ; do + install -p -m 0644 "${t}" %{buildroot}%{_cross_datadir}/nvidia/tesla/nvswitch +done + +popd + +%files +%{_cross_attribution_file} +%dir %{_cross_libexecdir}/nvidia +%dir %{_cross_libdir}/nvidia +%dir %{_cross_datadir}/nvidia +%dir %{_cross_libdir}/modules-load.d +%dir %{_cross_factorydir}%{_cross_sysconfdir}/drivers +%dir %{_cross_factorydir}%{_cross_sysconfdir}/nvidia +%{_cross_tmpfilesdir}/nvidia.conf +%{_cross_libdir}/modules-load.d/nvidia-dependencies.conf + +%files tesla-%{tesla_major} +%license NVidiaEULAforAWS.pdf +%license fabricmanager-linux-%{fm_arch}-%{tesla_ver}-archive/usr/share/doc/nvidia-fabricmanager/third-party-notices.txt +%dir %{_cross_datadir}/nvidia/tesla +%dir %{_cross_libexecdir}/nvidia/tesla/bin +%dir %{_cross_libdir}/nvidia/tesla +%dir %{_cross_libdir}/firmware/nvidia/%{tesla_ver} +%dir %{_cross_datadir}/nvidia/tesla/module-objects.d +%dir %{_cross_factorydir}/nvidia/tesla + +# Service files for link/copy/loading drivers +%{_cross_unitdir}/link-tesla-kernel-modules.service +%{_cross_unitdir}/load-tesla-kernel-modules.service +%{_cross_unitdir}/copy-open-gpu-kernel-modules.service +%{_cross_unitdir}/load-open-gpu-kernel-modules.service + +# Binaries +%{_cross_libexecdir}/nvidia/tesla/bin/nvidia-debugdump +%{_cross_libexecdir}/nvidia/tesla/bin/nvidia-smi +%{_cross_libexecdir}/nvidia/tesla/bin/nv-fabricmanager +%{_cross_libexecdir}/nvidia/tesla/bin/nvswitch-audit +%{_cross_libexecdir}/nvidia/tesla/bin/nvidia-persistenced +%{_cross_bindir}/nvidia-modprobe + +# nvswitch topologies +%dir %{_cross_datadir}/nvidia/tesla/nvswitch +%{_cross_datadir}/nvidia/tesla/nvswitch/dgxa100_hgxa100_topology +%{_cross_datadir}/nvidia/tesla/nvswitch/dgx2_hgx2_topology +%{_cross_datadir}/nvidia/tesla/nvswitch/dgxh100_hgxh100_topology +%{_cross_datadir}/nvidia/tesla/nvswitch/dgxh800_hgxh800_topology + +# Configuration files +%{_cross_factorydir}%{_cross_sysconfdir}/drivers/nvidia-tesla.toml +%{_cross_factorydir}%{_cross_sysconfdir}/drivers/nvidia-open-gpu.toml +%{_cross_factorydir}%{_cross_sysconfdir}/drivers/nvidia-open-gpu-copy-only.toml +%{_cross_factorydir}%{_cross_sysconfdir}/ld.so.conf.d/nvidia-tesla.conf +%{_cross_factorydir}/nvidia/tesla/nvidia-path.env +%{_cross_datadir}/nvidia/open-gpu-supported-devices.json + +# driver +%{_cross_datadir}/nvidia/tesla/module-objects.d/nvidia.mod.o +%{_cross_datadir}/nvidia/tesla/module-objects.d/nv-interface.o +%{_cross_datadir}/nvidia/tesla/module-objects.d/nv-kernel.o + +# uvm +%{_cross_datadir}/nvidia/tesla/module-objects.d/nvidia-uvm.mod.o +%{_cross_datadir}/nvidia/tesla/module-objects.d/nvidia-uvm.o + +# modeset +%{_cross_datadir}/nvidia/tesla/module-objects.d/nv-modeset-interface.o +%{_cross_datadir}/nvidia/tesla/module-objects.d/nv-modeset-kernel.o +%{_cross_datadir}/nvidia/tesla/module-objects.d/nvidia-modeset.mod.o + +# tmpfiles +%{_cross_tmpfilesdir}/nvidia-tesla.conf + +# sysuser files +%{_cross_sysusersdir}/nvidia.conf + +# systemd units +%{_cross_unitdir}/nvidia-persistenced.service + +# We only install the libraries required by all the DRIVER_CAPABILITIES, described here: +# https://docs.nvidia.com/datacenter/cloud-native/container-toolkit/user-guide.html#driver-capabilities + +# Utility libs +%{_cross_libdir}/nvidia/tesla/libnvidia-api.so.1 +%{_cross_libdir}/nvidia/tesla/libnvidia-ml.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libnvidia-ml.so.1 +%{_cross_libdir}/nvidia/tesla/libnvidia-cfg.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libnvidia-cfg.so.1 +%{_cross_libdir}/nvidia/tesla/libnvidia-nvvm.so.4 +%{_cross_libdir}/nvidia/tesla/libnvidia-nvvm.so.%{tesla_ver} + +# Compute libs +%{_cross_libdir}/nvidia/tesla/libcuda.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libcuda.so.1 +%{_cross_libdir}/nvidia/tesla/libcudadebugger.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libcudadebugger.so.1 +%{_cross_libdir}/nvidia/tesla/libnvidia-opencl.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libnvidia-opencl.so.1 +%{_cross_libdir}/nvidia/tesla/libnvidia-ptxjitcompiler.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libnvidia-ptxjitcompiler.so.1 +%{_cross_libdir}/nvidia/tesla/libnvidia-allocator.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libnvidia-allocator.so.1 +%{_cross_libdir}/nvidia/tesla/libOpenCL.so.1.0.0 +%{_cross_libdir}/nvidia/tesla/libOpenCL.so.1 +%if "%{_cross_arch}" == "x86_64" +%{_cross_libdir}/nvidia/tesla/libnvidia-pkcs11.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libnvidia-pkcs11-openssl3.so.%{tesla_ver} +%endif + +# Video libs +%{_cross_libdir}/nvidia/tesla/libvdpau_nvidia.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libvdpau_nvidia.so.1 +%{_cross_libdir}/nvidia/tesla/libnvidia-encode.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libnvidia-encode.so.1 +%{_cross_libdir}/nvidia/tesla/libnvidia-opticalflow.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libnvidia-opticalflow.so.1 +%{_cross_libdir}/nvidia/tesla/libnvcuvid.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libnvcuvid.so.1 + +# Graphics libs +%{_cross_libdir}/nvidia/tesla/libnvidia-eglcore.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libnvidia-glcore.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libnvidia-tls.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libnvidia-glsi.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libnvidia-rtcore.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libnvidia-fbc.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libnvidia-fbc.so.1 +%{_cross_libdir}/nvidia/tesla/libnvoptix.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libnvoptix.so.1 +%{_cross_libdir}/nvidia/tesla/libnvidia-vulkan-producer.so.%{tesla_ver} + +# Graphics GLVND libs +%{_cross_libdir}/nvidia/tesla/libnvidia-glvkspirv.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libGLX_nvidia.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libGLX_nvidia.so.0 +%{_cross_libdir}/nvidia/tesla/libEGL_nvidia.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libEGL_nvidia.so.0 +%{_cross_libdir}/nvidia/tesla/libGLESv2_nvidia.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libGLESv2_nvidia.so.2 +%{_cross_libdir}/nvidia/tesla/libGLESv1_CM_nvidia.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libGLESv1_CM_nvidia.so.1 + +# Graphics compat +%{_cross_libdir}/nvidia/tesla/libEGL.so.1.1.0 +%{_cross_libdir}/nvidia/tesla/libEGL.so.1 +%{_cross_libdir}/nvidia/tesla/libEGL.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libGL.so.1.7.0 +%{_cross_libdir}/nvidia/tesla/libGL.so.1 +%{_cross_libdir}/nvidia/tesla/libGLESv1_CM.so.1.2.0 +%{_cross_libdir}/nvidia/tesla/libGLESv1_CM.so.1 +%{_cross_libdir}/nvidia/tesla/libGLESv2.so.2.1.0 +%{_cross_libdir}/nvidia/tesla/libGLESv2.so.2 + +# NGX +%{_cross_libdir}/nvidia/tesla/libnvidia-ngx.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libnvidia-ngx.so.1 + +# Firmware +%{_cross_libdir}/firmware/nvidia/%{tesla_ver}/gsp_ga10x.bin +%{_cross_libdir}/firmware/nvidia/%{tesla_ver}/gsp_tu10x.bin + +# Neither nvidia-peermem nor nvidia-drm are included in driver container images, we exclude them +# for now, and we will add them if requested +%exclude %{_cross_datadir}/nvidia/tesla/module-objects.d/nvidia-peermem.mod.o +%exclude %{_cross_datadir}/nvidia/tesla/module-objects.d/nvidia-peermem.o +%exclude %{_cross_datadir}/nvidia/tesla/module-objects.d/nvidia-drm.mod.o +%exclude %{_cross_datadir}/nvidia/tesla/module-objects.d/nvidia-drm.o +%exclude %{_cross_libexecdir}/nvidia/tesla/bin/nvidia-cuda-mps-control +%exclude %{_cross_libexecdir}/nvidia/tesla/bin/nvidia-cuda-mps-server +%if "%{_cross_arch}" == "x86_64" +%exclude %{_cross_libexecdir}/nvidia/tesla/bin/nvidia-ngx-updater +%endif + +# None of these libraries are required by libnvidia-container, so they +# won't be used by a containerized workload +%exclude %{_cross_libdir}/nvidia/tesla/libGLX.so.0 +%exclude %{_cross_libdir}/nvidia/tesla/libGLdispatch.so.0 +%exclude %{_cross_libdir}/nvidia/tesla/libOpenGL.so.0 +%exclude %{_cross_libdir}/nvidia/tesla/libglxserver_nvidia.so.%{tesla_ver} +%exclude %{_cross_libdir}/nvidia/tesla/libnvidia-gtk2.so.%{tesla_ver} +%exclude %{_cross_libdir}/nvidia/tesla/libnvidia-gtk3.so.%{tesla_ver} +%exclude %{_cross_libdir}/nvidia/tesla/nvidia_drv.so +%exclude %{_cross_libdir}/nvidia/tesla/libnvidia-egl-wayland.so.1 +%exclude %{_cross_libdir}/nvidia/tesla/libnvidia-egl-gbm.so.1 +%exclude %{_cross_libdir}/nvidia/tesla/libnvidia-egl-gbm.so.1.1.0 +%exclude %{_cross_libdir}/nvidia/tesla/libnvidia-egl-wayland.so.1.1.11 +%exclude %{_cross_libdir}/nvidia/tesla/libnvidia-wayland-client.so.%{tesla_ver} + +%files open-gpu-%{tesla_major} +%license COPYING +%dir %{_cross_datadir}/nvidia/open-gpu/drivers +%dir %{_cross_factorydir}/nvidia/open-gpu + +# driver +%{_cross_datadir}/nvidia/open-gpu/drivers/nvidia.ko + +# uvm +%{_cross_datadir}/nvidia/open-gpu/drivers/nvidia-uvm.ko + +# modeset +%{_cross_datadir}/nvidia/open-gpu/drivers/nvidia-modeset.ko + +# drm +%{_cross_datadir}/nvidia/open-gpu/drivers/nvidia-drm.ko + +# peermem +%{_cross_datadir}/nvidia/open-gpu/drivers/nvidia-peermem.ko + +%files fabricmanager +%{_cross_factorydir}%{_cross_sysconfdir}/nvidia/fabricmanager.cfg +%{_cross_unitdir}/nvidia-fabricmanager.service diff --git a/packages/kmod-5.10-nvidia/link-tesla-kernel-modules.service.in b/packages/kmod-5.10-nvidia/link-tesla-kernel-modules.service.in new file mode 100644 index 00000000..8fc77921 --- /dev/null +++ b/packages/kmod-5.10-nvidia/link-tesla-kernel-modules.service.in @@ -0,0 +1,19 @@ +[Unit] +Description=Link Tesla kernel modules +RequiresMountsFor=PREFIX/lib/modules PREFIX/src/kernels +# Rerunning this service after the system is fully loaded will override +# the already linked kernel modules. This doesn't affect the running system, +# since kernel modules are linked early in the boot sequence, but we still +# disable manual restarts to prevent unnecessary kernel modules rewrites. +RefuseManualStart=true +RefuseManualStop=true + +[Service] +Type=oneshot +ExecCondition=/usr/bin/ghostdog match-nvidia-driver tesla +ExecStart=/usr/bin/driverdog --modules-set nvidia-tesla link-modules +RemainAfterExit=true +StandardError=journal+console + +[Install] +RequiredBy=preconfigured.target diff --git a/packages/kmod-5.10-nvidia/load-open-gpu-kernel-modules.service.in b/packages/kmod-5.10-nvidia/load-open-gpu-kernel-modules.service.in new file mode 100644 index 00000000..3862b3e7 --- /dev/null +++ b/packages/kmod-5.10-nvidia/load-open-gpu-kernel-modules.service.in @@ -0,0 +1,19 @@ +[Unit] +Description=Load open GPU kernel modules +RequiresMountsFor=PREFIX/lib/modules PREFIX/src/kernels +After=copy-open-gpu-kernel-modules.service +Requires=copy-open-gpu-kernel-modules.service +# Disable manual restarts to prevent loading kernel modules +# that weren't linked by the running system +RefuseManualStart=true +RefuseManualStop=true + +[Service] +Type=oneshot +ExecCondition=/usr/bin/ghostdog match-nvidia-driver open-gpu +ExecStart=/usr/bin/driverdog --modules-set nvidia-open-gpu load-modules +RemainAfterExit=true +StandardError=journal+console + +[Install] +RequiredBy=preconfigured.target diff --git a/packages/kmod-5.10-nvidia/load-tesla-kernel-modules.service.in b/packages/kmod-5.10-nvidia/load-tesla-kernel-modules.service.in new file mode 100644 index 00000000..60024004 --- /dev/null +++ b/packages/kmod-5.10-nvidia/load-tesla-kernel-modules.service.in @@ -0,0 +1,19 @@ +[Unit] +Description=Load Tesla kernel modules +RequiresMountsFor=PREFIX/lib/modules PREFIX/src/kernels +After=link-tesla-kernel-modules.service +Requires=link-tesla-kernel-modules.service +# Disable manual restarts to prevent loading kernel modules +# that weren't linked by the running system +RefuseManualStart=true +RefuseManualStop=true + +[Service] +Type=oneshot +ExecCondition=/usr/bin/ghostdog match-nvidia-driver tesla +ExecStart=/usr/bin/driverdog --modules-set nvidia-tesla load-modules +RemainAfterExit=true +StandardError=journal+console + +[Install] +RequiredBy=preconfigured.target diff --git a/packages/kmod-5.10-nvidia/nvidia-dependencies-modules-load.conf b/packages/kmod-5.10-nvidia/nvidia-dependencies-modules-load.conf new file mode 100644 index 00000000..86f884a6 --- /dev/null +++ b/packages/kmod-5.10-nvidia/nvidia-dependencies-modules-load.conf @@ -0,0 +1,2 @@ +i2c_core +ipmi_msghandler diff --git a/packages/kmod-5.10-nvidia/nvidia-fabricmanager.cfg b/packages/kmod-5.10-nvidia/nvidia-fabricmanager.cfg new file mode 100644 index 00000000..f8dc08ea --- /dev/null +++ b/packages/kmod-5.10-nvidia/nvidia-fabricmanager.cfg @@ -0,0 +1,34 @@ +# Modern, systemd-aware settings: +# - Log to journal via stderr +# - Keep running in the foreground +LOG_LEVEL=4 +LOG_FILE_NAME= +DAEMONIZE=0 + +# Use Unix domain sockets instead of localhost ports. +UNIX_SOCKET_PATH=/run/nvidia/fabricmanager.sock +FM_CMD_UNIX_SOCKET_PATH=/run/nvidia/fabricmanager-cmd.sock + +# Start Fabric Manager in bare metal or full pass through virtualization mode. +FABRIC_MODE=0 +FABRIC_MODE_RESTART=0 + +# Terminate on NVSwitch and GPU config failure. +FM_STAY_RESIDENT_ON_FAILURES=0 + +# When there is a GPU to NVSwitch NVLink failure, remove the GPU with the failure +# from NVLink P2P capability. +ACCESS_LINK_FAILURE_MODE=0 + +# When there is an NVSwitch to NVSwitch NVLink failure, exit Fabric Manager. +TRUNK_LINK_FAILURE_MODE=0 + +# When there is an NVSwitch failure or an NVSwitch is excluded, abort Fabric Manager. +NVSWITCH_FAILURE_MODE=0 + +# When Fabric Manager service is stopped or terminated, abort all running CUDA jobs. +ABORT_CUDA_JOBS_ON_FM_EXIT=1 + +# Path to topology and database files. +TOPOLOGY_FILE_PATH=/usr/share/nvidia/tesla/nvswitch +DATABASE_PATH=/usr/share/nvidia/tesla/nvswitch diff --git a/packages/kmod-5.10-nvidia/nvidia-fabricmanager.service b/packages/kmod-5.10-nvidia/nvidia-fabricmanager.service new file mode 100644 index 00000000..62ae1368 --- /dev/null +++ b/packages/kmod-5.10-nvidia/nvidia-fabricmanager.service @@ -0,0 +1,16 @@ +[Unit] +Description=NVIDIA fabric manager service + +[Service] +ExecStart=/usr/libexec/nvidia/tesla/bin/nv-fabricmanager -c /etc/nvidia/fabricmanager.cfg +Type=simple +TimeoutSec=0 +RestartSec=5 +Restart=always +RemainAfterExit=true +StandardError=journal+console +SuccessExitStatus=255 +LimitCORE=infinity + +[Install] +WantedBy=multi-user.target diff --git a/packages/kmod-5.10-nvidia/nvidia-ld.so.conf.in b/packages/kmod-5.10-nvidia/nvidia-ld.so.conf.in new file mode 100644 index 00000000..f992bf22 --- /dev/null +++ b/packages/kmod-5.10-nvidia/nvidia-ld.so.conf.in @@ -0,0 +1 @@ +__LIBDIR__/nvidia/tesla/ diff --git a/packages/kmod-5.10-nvidia/nvidia-open-gpu-config.toml.in b/packages/kmod-5.10-nvidia/nvidia-open-gpu-config.toml.in new file mode 100644 index 00000000..5ae81b71 --- /dev/null +++ b/packages/kmod-5.10-nvidia/nvidia-open-gpu-config.toml.in @@ -0,0 +1,11 @@ +[nvidia-open-gpu] +lib-modules-path = "kernel/drivers/extra/video/nvidia/open-gpu" + +[nvidia-open-gpu.kernel-modules."nvidia.ko"] +copy-source = "__NVIDIA_MODULES__" + +[nvidia-open-gpu.kernel-modules."nvidia-modeset.ko"] +copy-source = "__NVIDIA_MODULES__" + +[nvidia-open-gpu.kernel-modules."nvidia-uvm.ko"] +copy-source = "__NVIDIA_MODULES__" diff --git a/packages/kmod-5.10-nvidia/nvidia-open-gpu-copy-only-config.toml.in b/packages/kmod-5.10-nvidia/nvidia-open-gpu-copy-only-config.toml.in new file mode 100644 index 00000000..774867d4 --- /dev/null +++ b/packages/kmod-5.10-nvidia/nvidia-open-gpu-copy-only-config.toml.in @@ -0,0 +1,8 @@ +[nvidia-open-gpu-copy-only] +lib-modules-path = "kernel/drivers/extra/video/nvidia/open-gpu" + +[nvidia-open-gpu-copy-only.kernel-modules."nvidia-drm.ko"] +copy-source = "__NVIDIA_MODULES__" + +[nvidia-open-gpu-copy-only.kernel-modules."nvidia-peermem.ko"] +copy-source = "__NVIDIA_MODULES__" diff --git a/packages/kmod-5.10-nvidia/nvidia-persistenced.service b/packages/kmod-5.10-nvidia/nvidia-persistenced.service new file mode 100644 index 00000000..f245599c --- /dev/null +++ b/packages/kmod-5.10-nvidia/nvidia-persistenced.service @@ -0,0 +1,10 @@ +[Unit] +Description=NVIDIA Persistence Daemon +After=load-tesla-kernel-modules.service load-open-gpu-kernel-modules.service + +[Service] +Type=forking +ExecStart=/usr/libexec/nvidia/tesla/bin/nvidia-persistenced --user nvidia --verbose + +[Install] +RequiredBy=preconfigured.target diff --git a/packages/kmod-5.10-nvidia/nvidia-sysusers.conf b/packages/kmod-5.10-nvidia/nvidia-sysusers.conf new file mode 100644 index 00000000..43ceba0e --- /dev/null +++ b/packages/kmod-5.10-nvidia/nvidia-sysusers.conf @@ -0,0 +1 @@ +u nvidia - "nvidia-persistenced user" \ No newline at end of file diff --git a/packages/kmod-5.10-nvidia/nvidia-tesla-build-config.toml.in b/packages/kmod-5.10-nvidia/nvidia-tesla-build-config.toml.in new file mode 100644 index 00000000..fb74dc51 --- /dev/null +++ b/packages/kmod-5.10-nvidia/nvidia-tesla-build-config.toml.in @@ -0,0 +1,18 @@ +[nvidia-tesla] +lib-modules-path = "kernel/drivers/extra/video/nvidia/tesla" +objects-source = "__NVIDIA_MODULES__" + +[nvidia-tesla.object-files."nvidia.o"] +link-objects = ["nv-interface.o", "nv-kernel.o"] + +[nvidia-tesla.kernel-modules."nvidia.ko"] +link-objects = ["nvidia.o", "nvidia.mod.o"] + +[nvidia-tesla.object-files."nvidia-modeset.o"] +link-objects = ["nv-modeset-interface.o", "nv-modeset-kernel.o"] + +[nvidia-tesla.kernel-modules."nvidia-modeset.ko"] +link-objects = ["nvidia-modeset.o", "nvidia-modeset.mod.o"] + +[nvidia-tesla.kernel-modules."nvidia-uvm.ko"] +link-objects = ["nvidia-uvm.o", "nvidia-uvm.mod.o"] diff --git a/packages/kmod-5.10-nvidia/nvidia-tesla-path.env.in b/packages/kmod-5.10-nvidia/nvidia-tesla-path.env.in new file mode 100644 index 00000000..28f74deb --- /dev/null +++ b/packages/kmod-5.10-nvidia/nvidia-tesla-path.env.in @@ -0,0 +1 @@ +NVIDIA_PATH=__NVIDIA_BINDIR__ diff --git a/packages/kmod-5.10-nvidia/nvidia-tesla-tmpfiles.conf b/packages/kmod-5.10-nvidia/nvidia-tesla-tmpfiles.conf new file mode 100644 index 00000000..fd0f4486 --- /dev/null +++ b/packages/kmod-5.10-nvidia/nvidia-tesla-tmpfiles.conf @@ -0,0 +1,5 @@ +C /etc/drivers/nvidia-tesla.toml +C /etc/drivers/nvidia-open-gpu.toml +C /etc/drivers/nvidia-open-gpu-copy-only.toml +C /etc/containerd/nvidia.env - - - - /usr/share/factory/nvidia/tesla/nvidia-path.env +C /etc/ld.so.conf.d/nvidia-tesla.conf diff --git a/packages/kmod-5.10-nvidia/nvidia-tmpfiles.conf.in b/packages/kmod-5.10-nvidia/nvidia-tmpfiles.conf.in new file mode 100644 index 00000000..e58fe143 --- /dev/null +++ b/packages/kmod-5.10-nvidia/nvidia-tmpfiles.conf.in @@ -0,0 +1,7 @@ +R __PREFIX__/lib/modules/__KERNEL_VERSION__/kernel/drivers/extra/video/nvidia/tesla - - - - - +d __PREFIX__/lib/modules/__KERNEL_VERSION__/kernel/drivers/extra/video/nvidia/tesla 0755 root root - - +R __PREFIX__/lib/modules/__KERNEL_VERSION__/kernel/drivers/extra/video/nvidia/open-gpu - - - - - +d __PREFIX__/lib/modules/__KERNEL_VERSION__/kernel/drivers/extra/video/nvidia/open-gpu 0755 root root - - +C /etc/nvidia/fabricmanager.cfg - - - - +d /run/nvidia 0700 root root - +D /var/run/nvidia-persistenced 0755 nvidia nvidia - - diff --git a/packages/kmod-5.15-nvidia/.gitignore b/packages/kmod-5.15-nvidia/.gitignore new file mode 100644 index 00000000..db8b415b --- /dev/null +++ b/packages/kmod-5.15-nvidia/.gitignore @@ -0,0 +1,3 @@ +NVidiaEULAforAWS.pdf +COPYING +*.rpm diff --git a/packages/kmod-5.15-nvidia/Cargo.toml b/packages/kmod-5.15-nvidia/Cargo.toml new file mode 100644 index 00000000..21574524 --- /dev/null +++ b/packages/kmod-5.15-nvidia/Cargo.toml @@ -0,0 +1,45 @@ +[package] +name = "kmod-5_15-nvidia" +version = "0.1.0" +edition = "2021" +publish = false +build = "../build.rs" + +[lib] +path = "../packages.rs" + +[package.metadata.build-package] +package-name = "kmod-5.15-nvidia" +releases-url = "https://docs.nvidia.com/datacenter/tesla/" + +[[package.metadata.build-package.external-files]] +url = "https://s3.amazonaws.com/EULA/NVidiaEULAforAWS.pdf" +sha512 = "e1926fe99afc3ab5b2f2744fcd53b4046465aefb2793e2e06c4a19455a3fde895e00af1415ff1a5804c32e6a2ed0657e475de63da6c23a0e9c59feeef52f3f58" + +[[package.metadata.build-package.external-files]] +url = "https://us.download.nvidia.com/tesla/535.216.01/NVIDIA-Linux-x86_64-535.216.01.run" +sha512 = "3b4ae3584368fcc5f81a680dd8588d8b9e48f43dafe2490f5414ed258fa8c9799ebd40d2fd115e20bd02648eeb3e5c6dff39562d89353580fa679d011cebf6f8" +force-upstream = true + +[[package.metadata.build-package.external-files]] +url = "https://us.download.nvidia.com/tesla/535.216.01/NVIDIA-Linux-aarch64-535.216.01.run" +sha512 = "f68794249bf18ba626c6a665880721c8cc0dada6c7c1d8b15bf17174a4cac35ca2ab534fff2410c8bc0326c48f6ab913b6d9a92630505eeb768e02610a7772d9" +force-upstream = true + +[[package.metadata.build-package.external-files]] +url = "https://developer.download.nvidia.com/compute/cuda/repos/rhel9/x86_64/nvidia-fabric-manager-535.216.01-1.x86_64.rpm" +sha512 = "9208004779a57418cef4e0eacfad549e01fc3e193cda24a4f809325fee3a74910350c7752372d5dba7b74e9d5bf9da5807bc8de2bedade6dbe23b270c3047dfe" +force-upstream = true + +[[package.metadata.build-package.external-files]] +url = "https://developer.download.nvidia.com/compute/cuda/repos/rhel9/sbsa/nvidia-fabric-manager-535.216.01-1.aarch64.rpm" +sha512 = "1f553e4627953cceef8f630d2be907829f8b78b789ffee7691ace541f759bdb07016e364c20e1d5779ce463f0b48448cea292f58a9899523ec840bb5a0c37b0e" +force-upstream = true + +[[package.metadata.build-package.external-files]] +url = "https://raw.githubusercontent.com/NVIDIA/open-gpu-kernel-modules/535/COPYING" +sha512 = "f9cee68cbb12095af4b4e92d01c210461789ef41c70b64efefd6719d0b88468b7a67a3629c432d4d9304c730b5d1a942228a5bcc74a03ab1c411c77c758cd938" +force-upstream = true + +[build-dependencies] +kernel-5_15 = { path = "../kernel-5.15" } diff --git a/packages/kmod-5.15-nvidia/copy-open-gpu-kernel-modules.service.in b/packages/kmod-5.15-nvidia/copy-open-gpu-kernel-modules.service.in new file mode 100644 index 00000000..2c3420b6 --- /dev/null +++ b/packages/kmod-5.15-nvidia/copy-open-gpu-kernel-modules.service.in @@ -0,0 +1,20 @@ +[Unit] +Description=Copy open GPU kernel modules +RequiresMountsFor=PREFIX/lib/modules PREFIX/src/kernels +# Rerunning this service after the system is fully loaded will override +# the already linked kernel modules. This doesn't affect the running system, +# since kernel modules are linked early in the boot sequence, but we still +# disable manual restarts to prevent unnecessary kernel modules rewrites. +RefuseManualStart=true +RefuseManualStop=true + +[Service] +Type=oneshot +ExecCondition=/usr/bin/ghostdog match-nvidia-driver open-gpu +ExecStart=/usr/bin/driverdog --modules-set nvidia-open-gpu link-modules +ExecStart=/usr/bin/driverdog --modules-set nvidia-open-gpu-copy-only link-modules +RemainAfterExit=true +StandardError=journal+console + +[Install] +RequiredBy=preconfigured.target diff --git a/packages/kmod-5.15-nvidia/kmod-5.15-nvidia.spec b/packages/kmod-5.15-nvidia/kmod-5.15-nvidia.spec new file mode 100644 index 00000000..5da7a238 --- /dev/null +++ b/packages/kmod-5.15-nvidia/kmod-5.15-nvidia.spec @@ -0,0 +1,540 @@ +%global tesla_major 535 +%global tesla_minor 216 +%global tesla_patch 01 +%global tesla_ver %{tesla_major}.%{tesla_minor}.%{tesla_patch} +%if "%{?_cross_arch}" == "aarch64" +%global fm_arch sbsa +%else +%global fm_arch %{_cross_arch} +%endif + +# With the split of the firmware binary from firmware/gsp.bin to firmware/gsp_ga10x.bin +# and firmware/gsp_tu10x.bin the file format changed from executable to relocatable. +# The __spec_install_post macro will by default try to strip all binary files. +# Unfortunately the strip used is not compatible with the new file format. +# Redefine strip, so that these firmware binaries do not derail the build. +%global __strip /usr/bin/true + +Name: %{_cross_os}kmod-5.15-nvidia +Version: 1.0.0 +Release: 1%{?dist} +Epoch: 1 +Summary: NVIDIA drivers for the 5.15 kernel +# We use these licences because we only ship our own software in the main package, +# each subpackage includes the LICENSE file provided by the Licenses.toml file +License: Apache-2.0 OR MIT +URL: http://www.nvidia.com/ + +# NVIDIA archives from 0 to 199 +# NVIDIA .run scripts for kernel and userspace drivers +Source0: https://us.download.nvidia.com/tesla/%{tesla_ver}/NVIDIA-Linux-x86_64-%{tesla_ver}.run +Source1: https://us.download.nvidia.com/tesla/%{tesla_ver}/NVIDIA-Linux-aarch64-%{tesla_ver}.run +Source2: NVidiaEULAforAWS.pdf +Source3: COPYING + +# fabricmanager for NVSwitch +Source10: https://developer.download.nvidia.com/compute/cuda/repos/rhel9/x86_64/nvidia-fabric-manager-%{tesla_ver}-1.x86_64.rpm +Source11: https://developer.download.nvidia.com/compute/cuda/repos/rhel9/sbsa/nvidia-fabric-manager-%{tesla_ver}-1.aarch64.rpm + +# Common NVIDIA conf files from 200 to 299 +Source200: nvidia-tmpfiles.conf.in +Source202: nvidia-dependencies-modules-load.conf +Source203: nvidia-fabricmanager.service +Source204: nvidia-fabricmanager.cfg +Source205: nvidia-sysusers.conf +Source206: nvidia-persistenced.service + +# NVIDIA tesla conf files from 300 to 399 +Source300: nvidia-tesla-tmpfiles.conf +Source301: nvidia-tesla-build-config.toml.in +Source302: nvidia-open-gpu-config.toml.in +Source303: nvidia-open-gpu-copy-only-config.toml.in +Source304: nvidia-tesla-path.env.in +Source305: nvidia-ld.so.conf.in +Source306: link-tesla-kernel-modules.service.in +Source307: load-tesla-kernel-modules.service.in +Source308: copy-open-gpu-kernel-modules.service.in +Source309: load-open-gpu-kernel-modules.service.in + +BuildRequires: %{_cross_os}kernel-5.15-archive + +%description +%{summary}. + +%package fabricmanager +Summary: NVIDIA fabricmanager config and service files +Requires: %{name}-tesla(fabricmanager) + +%description fabricmanager +%{summary}. + +%package open-gpu-%{tesla_major} +Summary: NVIDIA %{tesla_major} Open GPU driver +Version: %{tesla_ver} +License: MIT AND GPL-2.0-only +Requires: %{_cross_os}variant-platform(aws) + +%description open-gpu-%{tesla_major} +%{summary}. + +%package tesla-%{tesla_major} +Summary: NVIDIA %{tesla_major} Tesla driver +Version: %{tesla_ver} +License: LicenseRef-NVIDIA-AWS-EULA +Requires: %{_cross_os}variant-platform(aws) +Requires: %{name} +Requires: %{name}-fabricmanager +Provides: %{name}-tesla(fabricmanager) +Requires: %{name}-open-gpu-%{tesla_major} + +%description tesla-%{tesla_major} +%{summary} + +%prep +# Extract nvidia sources with `-x`, otherwise the script will try to install +# the driver in the current run +sh %{_sourcedir}/NVIDIA-Linux-%{_cross_arch}-%{tesla_ver}.run -x + +# Extract fabricmanager from the rpm via cpio rather than `%%setup` since the +# correct source is architecture-dependent. +mkdir fabricmanager-linux-%{fm_arch}-%{tesla_ver}-archive +rpm2cpio %{_sourcedir}/nvidia-fabric-manager-%{tesla_ver}-1.%{_cross_arch}.rpm | cpio -idmV -D fabricmanager-linux-%{fm_arch}-%{tesla_ver}-archive + +# Add the license. +install -p -m 0644 %{S:2} . +install -p -m 0644 %{S:3} . + +%global kernel_sources %{_builddir}/kernel-devel +tar -xf %{_cross_datadir}/bottlerocket/kernel-devel.tar.xz + +%define _kernel_version %(ls %{kernel_sources}/include/config/kernel.release) +%global _cross_kmoddir %{_cross_libdir}/modules/%{_kernel_version} + +# This recipe was based in the NVIDIA yum/dnf specs: +# https://github.com/NVIDIA/yum-packaging-precompiled-kmod + +# Begin open driver build +pushd NVIDIA-Linux-%{_cross_arch}-%{tesla_ver}/kernel-open + +# We set IGNORE_CC_MISMATCH even though we are using the same compiler used to compile the kernel, if +# we don't set this flag the compilation fails +make %{?_smp_mflags} ARCH=%{_cross_karch} IGNORE_CC_MISMATCH=1 SYSSRC=%{kernel_sources} CC=%{_cross_target}-gcc LD=%{_cross_target}-ld + +# end open driver build +popd + +# Begin proprietary driver build +pushd NVIDIA-Linux-%{_cross_arch}-%{tesla_ver}/kernel + +# We set IGNORE_CC_MISMATCH even though we are using the same compiler used to compile the kernel, if +# we don't set this flag the compilation fails +make %{?_smp_mflags} ARCH=%{_cross_karch} IGNORE_CC_MISMATCH=1 SYSSRC=%{kernel_sources} CC=%{_cross_target}-gcc LD=%{_cross_target}-ld + +%{_cross_target}-strip -g --strip-unneeded nvidia/nv-interface.o +%{_cross_target}-strip -g --strip-unneeded nvidia-uvm.o +%{_cross_target}-strip -g --strip-unneeded nvidia-drm.o +%{_cross_target}-strip -g --strip-unneeded nvidia-peermem/nvidia-peermem.o +%{_cross_target}-strip -g --strip-unneeded nvidia-modeset/nv-modeset-interface.o + +# We delete these files since we just stripped the input .o files above, and +# will be build at runtime in the host +rm nvidia{,-modeset,-peermem}.o + +# Delete the .ko files created in make command, just to be safe that we +# don't include any linked module in the base image +rm nvidia{,-modeset,-peermem,-drm}.ko + +# End proprietary driver build +popd + +# Grab the list of supported devices +pushd NVIDIA-Linux-%{_cross_arch}-%{tesla_ver}/supported-gpus +# We want to grab all the `kernelopen` enabled chips except for this list that is best held back to the proprietary driver +# 10de:1db1 is V100-16G (P3dn) +# 10de:1db5 is V100-32G (P3dn) +# 10de:1eb8 is T4 (G4dn) +# 10de:1eb4 is T4G (G5g) +# 10de:2237 is A10G (G5) +# 10de:27b8 is L4 (G6) +# 10de:26b9 is L40S (G6e) +jq -r '.chips[] | select(.features[] | contains("kernelopen")) | +select(.devid != "0x1DB1" +and .devid != "0x1DB5" +and .devid != "0x1DEB8" +and .devid != "0x1EB4" +and .devid != "0x2237" +and .devid != "0x27B8" +and .devid != "0x26B9")' supported-gpus.json | jq -s '{"open-gpu": .}' > open-gpu-supported-devices.json +# confirm "NVIDIA H100" is in the resulting file to catch shape changes +jq -e '."open-gpu"[] | select(."devid" == "0x2330") | ."features"| index("kernelopen")' open-gpu-supported-devices.json +popd + +%install +install -d %{buildroot}%{_cross_libexecdir} +install -d %{buildroot}%{_cross_libdir} +install -d %{buildroot}%{_cross_tmpfilesdir} +install -d %{buildroot}%{_cross_unitdir} +install -d %{buildroot}%{_cross_factorydir}%{_cross_sysconfdir}/{drivers,ld.so.conf.d} +install -d %{buildroot}%{_cross_sysusersdir} +install -d %{buildroot}%{_cross_bindir} + +KERNEL_VERSION=$(cat %{kernel_sources}/include/config/kernel.release) +sed \ + -e "s|__KERNEL_VERSION__|${KERNEL_VERSION}|" \ + -e "s|__PREFIX__|%{_cross_prefix}|" %{S:200} > nvidia.conf +install -p -m 0644 nvidia.conf %{buildroot}%{_cross_tmpfilesdir} + +# Install modules-load.d drop-in to autoload required kernel modules +install -d %{buildroot}%{_cross_libdir}/modules-load.d +install -p -m 0644 %{S:202} %{buildroot}%{_cross_libdir}/modules-load.d/nvidia-dependencies.conf + +# NVIDIA fabric manager service unit and config +install -p -m 0644 %{S:203} %{buildroot}%{_cross_unitdir} +install -d %{buildroot}%{_cross_factorydir}%{_cross_sysconfdir}/nvidia +install -p -m 0644 %{S:204} %{buildroot}%{_cross_factorydir}%{_cross_sysconfdir}/nvidia/fabricmanager.cfg + +# Begin NVIDIA tesla driver +pushd NVIDIA-Linux-%{_cross_arch}-%{tesla_ver} +# Proprietary driver +install -d %{buildroot}%{_cross_libexecdir}/nvidia/tesla/bin +install -d %{buildroot}%{_cross_libdir}/nvidia/tesla +install -d %{buildroot}%{_cross_datadir}/nvidia/tesla/module-objects.d +install -d %{buildroot}%{_cross_factorydir}/nvidia/tesla +install -d %{buildroot}%{_cross_factorydir}/nvidia/open-gpu +install -d %{buildroot}%{_cross_datadir}/nvidia/open-gpu/drivers + +install -m 0644 %{S:300} %{buildroot}%{_cross_tmpfilesdir}/nvidia-tesla.conf +sed -e 's|__NVIDIA_MODULES__|%{_cross_datadir}/nvidia/tesla/module-objects.d/|' %{S:301} > \ + nvidia-tesla.toml +install -m 0644 nvidia-tesla.toml %{buildroot}%{_cross_factorydir}%{_cross_sysconfdir}/drivers +sed -e 's|__NVIDIA_MODULES__|%{_cross_datadir}/nvidia/open-gpu/drivers/|' %{S:302} > \ + nvidia-open-gpu.toml +install -m 0644 nvidia-open-gpu.toml %{buildroot}%{_cross_factorydir}%{_cross_sysconfdir}/drivers +sed -e 's|__NVIDIA_MODULES__|%{_cross_datadir}/nvidia/open-gpu/drivers/|' %{S:303} > \ + nvidia-open-gpu-copy-only.toml +install -m 0644 nvidia-open-gpu-copy-only.toml %{buildroot}%{_cross_factorydir}%{_cross_sysconfdir}/drivers +# Install nvidia-path environment file, will be used as a drop-in for containerd.service since +# libnvidia-container locates and mounts helper binaries into the containers from either +# `PATH` or `NVIDIA_PATH` +sed -e 's|__NVIDIA_BINDIR__|%{_cross_libexecdir}/nvidia/tesla/bin|' %{S:304} > nvidia-path.env +install -m 0644 nvidia-path.env %{buildroot}%{_cross_factorydir}/nvidia/tesla +# We need to add `_cross_libdir` to the paths loaded by the ldconfig service +# because libnvidia-container uses the `ldcache` file created by the service, to locate and mount the +# libraries into the containers +sed -e 's|__LIBDIR__|%{_cross_libdir}|' %{S:305} > nvidia-tesla.conf +install -m 0644 nvidia-tesla.conf %{buildroot}%{_cross_factorydir}%{_cross_sysconfdir}/ld.so.conf.d/ + +# Services to link/copy/load modules +sed -e 's|PREFIX|%{_cross_prefix}|g' %{S:306} > link-tesla-kernel-modules.service +sed -e 's|PREFIX|%{_cross_prefix}|g' %{S:307} > load-tesla-kernel-modules.service +install -p -m 0644 \ + link-tesla-kernel-modules.service \ + load-tesla-kernel-modules.service \ + %{buildroot}%{_cross_unitdir} + +sed -e 's|PREFIX|%{_cross_prefix}|g' %{S:308} > copy-open-gpu-kernel-modules.service +sed -e 's|PREFIX|%{_cross_prefix}|g' %{S:309} > load-open-gpu-kernel-modules.service +install -p -m 0644 \ + copy-open-gpu-kernel-modules.service \ + load-open-gpu-kernel-modules.service \ + %{buildroot}%{_cross_unitdir} + +# proprietary driver +install kernel/nvidia.mod.o %{buildroot}%{_cross_datadir}/nvidia/tesla/module-objects.d +install kernel/nvidia/nv-interface.o %{buildroot}%{_cross_datadir}/nvidia/tesla/module-objects.d +install kernel/nvidia/nv-kernel.o_binary %{buildroot}%{_cross_datadir}/nvidia/tesla/module-objects.d/nv-kernel.o + +# uvm +install kernel/nvidia-uvm.mod.o %{buildroot}%{_cross_datadir}/nvidia/tesla/module-objects.d +install kernel/nvidia-uvm.o %{buildroot}%{_cross_datadir}/nvidia/tesla/module-objects.d + +# modeset +install kernel/nvidia-modeset.mod.o %{buildroot}%{_cross_datadir}/nvidia/tesla/module-objects.d +install kernel/nvidia-modeset/nv-modeset-interface.o %{buildroot}%{_cross_datadir}/nvidia/tesla/module-objects.d +install kernel/nvidia-modeset/nv-modeset-kernel.o %{buildroot}%{_cross_datadir}/nvidia/tesla/module-objects.d + +# peermem +install kernel/nvidia-peermem.mod.o %{buildroot}%{_cross_datadir}/nvidia/tesla/module-objects.d +install kernel/nvidia-peermem/nvidia-peermem.o %{buildroot}%{_cross_datadir}/nvidia/tesla/module-objects.d + +# drm +install kernel/nvidia-drm.mod.o %{buildroot}/%{_cross_datadir}/nvidia/tesla/module-objects.d +install kernel/nvidia-drm.o %{buildroot}/%{_cross_datadir}/nvidia/tesla/module-objects.d + +# open driver +install -d %{buildroot}%{_cross_datadir}/nvidia/open-gpu/drivers/ +install kernel-open/nvidia.ko %{buildroot}%{_cross_datadir}/nvidia/open-gpu/drivers/ + +# uvm +install kernel-open/nvidia-uvm.ko %{buildroot}%{_cross_datadir}/nvidia/open-gpu/drivers/ + +# modeset +install kernel-open/nvidia-modeset.ko %{buildroot}%{_cross_datadir}/nvidia/open-gpu/drivers/ + +# peermem +install kernel-open/nvidia-peermem.ko %{buildroot}%{_cross_datadir}/nvidia/open-gpu/drivers/ + +# drm +install kernel-open/nvidia-drm.ko %{buildroot}%{_cross_datadir}/nvidia/open-gpu/drivers/ +# end open driver + +# Binaries +install -m 755 nvidia-smi %{buildroot}%{_cross_libexecdir}/nvidia/tesla/bin +install -m 755 nvidia-debugdump %{buildroot}%{_cross_libexecdir}/nvidia/tesla/bin +install -m 755 nvidia-cuda-mps-control %{buildroot}%{_cross_libexecdir}/nvidia/tesla/bin +install -m 755 nvidia-cuda-mps-server %{buildroot}%{_cross_libexecdir}/nvidia/tesla/bin +install -m 755 nvidia-persistenced %{buildroot}%{_cross_libexecdir}/nvidia/tesla/bin/ +install -m 4755 nvidia-modprobe %{buildroot}%{_cross_bindir} +%if "%{_cross_arch}" == "x86_64" +install -m 755 nvidia-ngx-updater %{buildroot}%{_cross_libexecdir}/nvidia/tesla/bin +%endif + +# Users +install -m 0644 %{S:205} %{buildroot}%{_cross_sysusersdir}/nvidia.conf + +# Systemd units +install -m 0644 %{S:206} %{buildroot}%{_cross_unitdir} + +# We install all the libraries, and filter them out in the 'files' section, so we can catch +# when new libraries are added +install -m 755 *.so* %{buildroot}/%{_cross_libdir}/nvidia/tesla/ + +# This library has the same SONAME as libEGL.so.1.1.0, this will cause collisions while +# the symlinks are created. For now, we only symlink libEGL.so.1.1.0. +EXCLUDED_LIBS="libEGL.so.%{tesla_ver}" + +for lib in $(find . -maxdepth 1 -type f -name 'lib*.so.*' -printf '%%P\n'); do + [[ "${EXCLUDED_LIBS}" =~ "${lib}" ]] && continue + soname="$(%{_cross_target}-readelf -d "${lib}" | awk '/SONAME/{print $5}' | tr -d '[]')" + [ -n "${soname}" ] || continue + [ "${lib}" == "${soname}" ] && continue + ln -s "${lib}" %{buildroot}/%{_cross_libdir}/nvidia/tesla/"${soname}" +done + +# Include the firmware file for GSP support +install -d %{buildroot}%{_cross_libdir}/firmware/nvidia/%{tesla_ver} +install -p -m 0644 firmware/gsp_ga10x.bin %{buildroot}%{_cross_libdir}/firmware/nvidia/%{tesla_ver} +install -p -m 0644 firmware/gsp_tu10x.bin %{buildroot}%{_cross_libdir}/firmware/nvidia/%{tesla_ver} + +# Include the open driver supported devices file for runtime matching of the driver. This is consumed by ghostdog to match the driver to this list +install -p -m 0644 supported-gpus/open-gpu-supported-devices.json %{buildroot}%{_cross_datadir}/nvidia/open-gpu-supported-devices.json + +popd + +# Begin NVIDIA fabric manager binaries and topologies +pushd fabricmanager-linux-%{fm_arch}-%{tesla_ver}-archive +install -p -m 0755 usr/bin/nv-fabricmanager %{buildroot}%{_cross_libexecdir}/nvidia/tesla/bin +install -p -m 0755 usr/bin/nvswitch-audit %{buildroot}%{_cross_libexecdir}/nvidia/tesla/bin + +install -d %{buildroot}%{_cross_datadir}/nvidia/tesla/nvswitch +for t in usr/share/nvidia/nvswitch/*_topology ; do + install -p -m 0644 "${t}" %{buildroot}%{_cross_datadir}/nvidia/tesla/nvswitch +done + +popd + +%files +%{_cross_attribution_file} +%dir %{_cross_libexecdir}/nvidia +%dir %{_cross_libdir}/nvidia +%dir %{_cross_datadir}/nvidia +%dir %{_cross_libdir}/modules-load.d +%dir %{_cross_factorydir}%{_cross_sysconfdir}/drivers +%dir %{_cross_factorydir}%{_cross_sysconfdir}/nvidia +%{_cross_tmpfilesdir}/nvidia.conf +%{_cross_libdir}/modules-load.d/nvidia-dependencies.conf + +%files tesla-%{tesla_major} +%license NVidiaEULAforAWS.pdf +%license fabricmanager-linux-%{fm_arch}-%{tesla_ver}-archive/usr/share/doc/nvidia-fabricmanager/third-party-notices.txt +%dir %{_cross_datadir}/nvidia/tesla +%dir %{_cross_libexecdir}/nvidia/tesla/bin +%dir %{_cross_libdir}/nvidia/tesla +%dir %{_cross_libdir}/firmware/nvidia/%{tesla_ver} +%dir %{_cross_datadir}/nvidia/tesla/module-objects.d +%dir %{_cross_factorydir}/nvidia/tesla + +# Service files for link/copy/loading drivers +%{_cross_unitdir}/link-tesla-kernel-modules.service +%{_cross_unitdir}/load-tesla-kernel-modules.service +%{_cross_unitdir}/copy-open-gpu-kernel-modules.service +%{_cross_unitdir}/load-open-gpu-kernel-modules.service + +# Binaries +%{_cross_libexecdir}/nvidia/tesla/bin/nvidia-debugdump +%{_cross_libexecdir}/nvidia/tesla/bin/nvidia-smi +%{_cross_libexecdir}/nvidia/tesla/bin/nv-fabricmanager +%{_cross_libexecdir}/nvidia/tesla/bin/nvswitch-audit +%{_cross_libexecdir}/nvidia/tesla/bin/nvidia-persistenced +%{_cross_bindir}/nvidia-modprobe + +# nvswitch topologies +%dir %{_cross_datadir}/nvidia/tesla/nvswitch +%{_cross_datadir}/nvidia/tesla/nvswitch/dgxa100_hgxa100_topology +%{_cross_datadir}/nvidia/tesla/nvswitch/dgx2_hgx2_topology +%{_cross_datadir}/nvidia/tesla/nvswitch/dgxh100_hgxh100_topology +%{_cross_datadir}/nvidia/tesla/nvswitch/dgxh800_hgxh800_topology + +# Configuration files +%{_cross_factorydir}%{_cross_sysconfdir}/drivers/nvidia-tesla.toml +%{_cross_factorydir}%{_cross_sysconfdir}/drivers/nvidia-open-gpu.toml +%{_cross_factorydir}%{_cross_sysconfdir}/drivers/nvidia-open-gpu-copy-only.toml +%{_cross_factorydir}%{_cross_sysconfdir}/ld.so.conf.d/nvidia-tesla.conf +%{_cross_factorydir}/nvidia/tesla/nvidia-path.env +%{_cross_datadir}/nvidia/open-gpu-supported-devices.json + +# driver +%{_cross_datadir}/nvidia/tesla/module-objects.d/nvidia.mod.o +%{_cross_datadir}/nvidia/tesla/module-objects.d/nv-interface.o +%{_cross_datadir}/nvidia/tesla/module-objects.d/nv-kernel.o + +# uvm +%{_cross_datadir}/nvidia/tesla/module-objects.d/nvidia-uvm.mod.o +%{_cross_datadir}/nvidia/tesla/module-objects.d/nvidia-uvm.o + +# modeset +%{_cross_datadir}/nvidia/tesla/module-objects.d/nv-modeset-interface.o +%{_cross_datadir}/nvidia/tesla/module-objects.d/nv-modeset-kernel.o +%{_cross_datadir}/nvidia/tesla/module-objects.d/nvidia-modeset.mod.o + +# tmpfiles +%{_cross_tmpfilesdir}/nvidia-tesla.conf + +# sysuser files +%{_cross_sysusersdir}/nvidia.conf + +# systemd units +%{_cross_unitdir}/nvidia-persistenced.service + +# We only install the libraries required by all the DRIVER_CAPABILITIES, described here: +# https://docs.nvidia.com/datacenter/cloud-native/container-toolkit/user-guide.html#driver-capabilities + +# Utility libs +%{_cross_libdir}/nvidia/tesla/libnvidia-api.so.1 +%{_cross_libdir}/nvidia/tesla/libnvidia-ml.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libnvidia-ml.so.1 +%{_cross_libdir}/nvidia/tesla/libnvidia-cfg.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libnvidia-cfg.so.1 +%{_cross_libdir}/nvidia/tesla/libnvidia-nvvm.so.4 +%{_cross_libdir}/nvidia/tesla/libnvidia-nvvm.so.%{tesla_ver} + +# Compute libs +%{_cross_libdir}/nvidia/tesla/libcuda.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libcuda.so.1 +%{_cross_libdir}/nvidia/tesla/libcudadebugger.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libcudadebugger.so.1 +%{_cross_libdir}/nvidia/tesla/libnvidia-opencl.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libnvidia-opencl.so.1 +%{_cross_libdir}/nvidia/tesla/libnvidia-ptxjitcompiler.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libnvidia-ptxjitcompiler.so.1 +%{_cross_libdir}/nvidia/tesla/libnvidia-allocator.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libnvidia-allocator.so.1 +%{_cross_libdir}/nvidia/tesla/libOpenCL.so.1.0.0 +%{_cross_libdir}/nvidia/tesla/libOpenCL.so.1 +%if "%{_cross_arch}" == "x86_64" +%{_cross_libdir}/nvidia/tesla/libnvidia-pkcs11.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libnvidia-pkcs11-openssl3.so.%{tesla_ver} +%endif + +# Video libs +%{_cross_libdir}/nvidia/tesla/libvdpau_nvidia.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libvdpau_nvidia.so.1 +%{_cross_libdir}/nvidia/tesla/libnvidia-encode.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libnvidia-encode.so.1 +%{_cross_libdir}/nvidia/tesla/libnvidia-opticalflow.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libnvidia-opticalflow.so.1 +%{_cross_libdir}/nvidia/tesla/libnvcuvid.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libnvcuvid.so.1 + +# Graphics libs +%{_cross_libdir}/nvidia/tesla/libnvidia-eglcore.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libnvidia-glcore.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libnvidia-tls.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libnvidia-glsi.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libnvidia-rtcore.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libnvidia-fbc.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libnvidia-fbc.so.1 +%{_cross_libdir}/nvidia/tesla/libnvoptix.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libnvoptix.so.1 +%{_cross_libdir}/nvidia/tesla/libnvidia-vulkan-producer.so.%{tesla_ver} + +# Graphics GLVND libs +%{_cross_libdir}/nvidia/tesla/libnvidia-glvkspirv.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libGLX_nvidia.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libGLX_nvidia.so.0 +%{_cross_libdir}/nvidia/tesla/libEGL_nvidia.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libEGL_nvidia.so.0 +%{_cross_libdir}/nvidia/tesla/libGLESv2_nvidia.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libGLESv2_nvidia.so.2 +%{_cross_libdir}/nvidia/tesla/libGLESv1_CM_nvidia.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libGLESv1_CM_nvidia.so.1 + +# Graphics compat +%{_cross_libdir}/nvidia/tesla/libEGL.so.1.1.0 +%{_cross_libdir}/nvidia/tesla/libEGL.so.1 +%{_cross_libdir}/nvidia/tesla/libEGL.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libGL.so.1.7.0 +%{_cross_libdir}/nvidia/tesla/libGL.so.1 +%{_cross_libdir}/nvidia/tesla/libGLESv1_CM.so.1.2.0 +%{_cross_libdir}/nvidia/tesla/libGLESv1_CM.so.1 +%{_cross_libdir}/nvidia/tesla/libGLESv2.so.2.1.0 +%{_cross_libdir}/nvidia/tesla/libGLESv2.so.2 + +# NGX +%{_cross_libdir}/nvidia/tesla/libnvidia-ngx.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libnvidia-ngx.so.1 + +# Firmware +%{_cross_libdir}/firmware/nvidia/%{tesla_ver}/gsp_ga10x.bin +%{_cross_libdir}/firmware/nvidia/%{tesla_ver}/gsp_tu10x.bin + +# Neither nvidia-peermem nor nvidia-drm are included in driver container images, we exclude them +# for now, and we will add them if requested +%exclude %{_cross_datadir}/nvidia/tesla/module-objects.d/nvidia-peermem.mod.o +%exclude %{_cross_datadir}/nvidia/tesla/module-objects.d/nvidia-peermem.o +%exclude %{_cross_datadir}/nvidia/tesla/module-objects.d/nvidia-drm.mod.o +%exclude %{_cross_datadir}/nvidia/tesla/module-objects.d/nvidia-drm.o +%exclude %{_cross_libexecdir}/nvidia/tesla/bin/nvidia-cuda-mps-control +%exclude %{_cross_libexecdir}/nvidia/tesla/bin/nvidia-cuda-mps-server +%if "%{_cross_arch}" == "x86_64" +%exclude %{_cross_libexecdir}/nvidia/tesla/bin/nvidia-ngx-updater +%endif + +# None of these libraries are required by libnvidia-container, so they +# won't be used by a containerized workload +%exclude %{_cross_libdir}/nvidia/tesla/libGLX.so.0 +%exclude %{_cross_libdir}/nvidia/tesla/libGLdispatch.so.0 +%exclude %{_cross_libdir}/nvidia/tesla/libOpenGL.so.0 +%exclude %{_cross_libdir}/nvidia/tesla/libglxserver_nvidia.so.%{tesla_ver} +%exclude %{_cross_libdir}/nvidia/tesla/libnvidia-gtk2.so.%{tesla_ver} +%exclude %{_cross_libdir}/nvidia/tesla/libnvidia-gtk3.so.%{tesla_ver} +%exclude %{_cross_libdir}/nvidia/tesla/nvidia_drv.so +%exclude %{_cross_libdir}/nvidia/tesla/libnvidia-egl-wayland.so.1 +%exclude %{_cross_libdir}/nvidia/tesla/libnvidia-egl-gbm.so.1 +%exclude %{_cross_libdir}/nvidia/tesla/libnvidia-egl-gbm.so.1.1.0 +%exclude %{_cross_libdir}/nvidia/tesla/libnvidia-egl-wayland.so.1.1.11 +%exclude %{_cross_libdir}/nvidia/tesla/libnvidia-wayland-client.so.%{tesla_ver} + +%files open-gpu-%{tesla_major} +%license COPYING +%dir %{_cross_datadir}/nvidia/open-gpu/drivers +%dir %{_cross_factorydir}/nvidia/open-gpu + +# driver +%{_cross_datadir}/nvidia/open-gpu/drivers/nvidia.ko + +# uvm +%{_cross_datadir}/nvidia/open-gpu/drivers/nvidia-uvm.ko + +# modeset +%{_cross_datadir}/nvidia/open-gpu/drivers/nvidia-modeset.ko + +# drm +%{_cross_datadir}/nvidia/open-gpu/drivers/nvidia-drm.ko + +# peermem +%{_cross_datadir}/nvidia/open-gpu/drivers/nvidia-peermem.ko + +%files fabricmanager +%{_cross_factorydir}%{_cross_sysconfdir}/nvidia/fabricmanager.cfg +%{_cross_unitdir}/nvidia-fabricmanager.service diff --git a/packages/kmod-5.15-nvidia/link-tesla-kernel-modules.service.in b/packages/kmod-5.15-nvidia/link-tesla-kernel-modules.service.in new file mode 100644 index 00000000..8fc77921 --- /dev/null +++ b/packages/kmod-5.15-nvidia/link-tesla-kernel-modules.service.in @@ -0,0 +1,19 @@ +[Unit] +Description=Link Tesla kernel modules +RequiresMountsFor=PREFIX/lib/modules PREFIX/src/kernels +# Rerunning this service after the system is fully loaded will override +# the already linked kernel modules. This doesn't affect the running system, +# since kernel modules are linked early in the boot sequence, but we still +# disable manual restarts to prevent unnecessary kernel modules rewrites. +RefuseManualStart=true +RefuseManualStop=true + +[Service] +Type=oneshot +ExecCondition=/usr/bin/ghostdog match-nvidia-driver tesla +ExecStart=/usr/bin/driverdog --modules-set nvidia-tesla link-modules +RemainAfterExit=true +StandardError=journal+console + +[Install] +RequiredBy=preconfigured.target diff --git a/packages/kmod-5.15-nvidia/load-open-gpu-kernel-modules.service.in b/packages/kmod-5.15-nvidia/load-open-gpu-kernel-modules.service.in new file mode 100644 index 00000000..3862b3e7 --- /dev/null +++ b/packages/kmod-5.15-nvidia/load-open-gpu-kernel-modules.service.in @@ -0,0 +1,19 @@ +[Unit] +Description=Load open GPU kernel modules +RequiresMountsFor=PREFIX/lib/modules PREFIX/src/kernels +After=copy-open-gpu-kernel-modules.service +Requires=copy-open-gpu-kernel-modules.service +# Disable manual restarts to prevent loading kernel modules +# that weren't linked by the running system +RefuseManualStart=true +RefuseManualStop=true + +[Service] +Type=oneshot +ExecCondition=/usr/bin/ghostdog match-nvidia-driver open-gpu +ExecStart=/usr/bin/driverdog --modules-set nvidia-open-gpu load-modules +RemainAfterExit=true +StandardError=journal+console + +[Install] +RequiredBy=preconfigured.target diff --git a/packages/kmod-5.15-nvidia/load-tesla-kernel-modules.service.in b/packages/kmod-5.15-nvidia/load-tesla-kernel-modules.service.in new file mode 100644 index 00000000..60024004 --- /dev/null +++ b/packages/kmod-5.15-nvidia/load-tesla-kernel-modules.service.in @@ -0,0 +1,19 @@ +[Unit] +Description=Load Tesla kernel modules +RequiresMountsFor=PREFIX/lib/modules PREFIX/src/kernels +After=link-tesla-kernel-modules.service +Requires=link-tesla-kernel-modules.service +# Disable manual restarts to prevent loading kernel modules +# that weren't linked by the running system +RefuseManualStart=true +RefuseManualStop=true + +[Service] +Type=oneshot +ExecCondition=/usr/bin/ghostdog match-nvidia-driver tesla +ExecStart=/usr/bin/driverdog --modules-set nvidia-tesla load-modules +RemainAfterExit=true +StandardError=journal+console + +[Install] +RequiredBy=preconfigured.target diff --git a/packages/kmod-5.15-nvidia/nvidia-dependencies-modules-load.conf b/packages/kmod-5.15-nvidia/nvidia-dependencies-modules-load.conf new file mode 100644 index 00000000..86f884a6 --- /dev/null +++ b/packages/kmod-5.15-nvidia/nvidia-dependencies-modules-load.conf @@ -0,0 +1,2 @@ +i2c_core +ipmi_msghandler diff --git a/packages/kmod-5.15-nvidia/nvidia-fabricmanager.cfg b/packages/kmod-5.15-nvidia/nvidia-fabricmanager.cfg new file mode 100644 index 00000000..f8dc08ea --- /dev/null +++ b/packages/kmod-5.15-nvidia/nvidia-fabricmanager.cfg @@ -0,0 +1,34 @@ +# Modern, systemd-aware settings: +# - Log to journal via stderr +# - Keep running in the foreground +LOG_LEVEL=4 +LOG_FILE_NAME= +DAEMONIZE=0 + +# Use Unix domain sockets instead of localhost ports. +UNIX_SOCKET_PATH=/run/nvidia/fabricmanager.sock +FM_CMD_UNIX_SOCKET_PATH=/run/nvidia/fabricmanager-cmd.sock + +# Start Fabric Manager in bare metal or full pass through virtualization mode. +FABRIC_MODE=0 +FABRIC_MODE_RESTART=0 + +# Terminate on NVSwitch and GPU config failure. +FM_STAY_RESIDENT_ON_FAILURES=0 + +# When there is a GPU to NVSwitch NVLink failure, remove the GPU with the failure +# from NVLink P2P capability. +ACCESS_LINK_FAILURE_MODE=0 + +# When there is an NVSwitch to NVSwitch NVLink failure, exit Fabric Manager. +TRUNK_LINK_FAILURE_MODE=0 + +# When there is an NVSwitch failure or an NVSwitch is excluded, abort Fabric Manager. +NVSWITCH_FAILURE_MODE=0 + +# When Fabric Manager service is stopped or terminated, abort all running CUDA jobs. +ABORT_CUDA_JOBS_ON_FM_EXIT=1 + +# Path to topology and database files. +TOPOLOGY_FILE_PATH=/usr/share/nvidia/tesla/nvswitch +DATABASE_PATH=/usr/share/nvidia/tesla/nvswitch diff --git a/packages/kmod-5.15-nvidia/nvidia-fabricmanager.service b/packages/kmod-5.15-nvidia/nvidia-fabricmanager.service new file mode 100644 index 00000000..62ae1368 --- /dev/null +++ b/packages/kmod-5.15-nvidia/nvidia-fabricmanager.service @@ -0,0 +1,16 @@ +[Unit] +Description=NVIDIA fabric manager service + +[Service] +ExecStart=/usr/libexec/nvidia/tesla/bin/nv-fabricmanager -c /etc/nvidia/fabricmanager.cfg +Type=simple +TimeoutSec=0 +RestartSec=5 +Restart=always +RemainAfterExit=true +StandardError=journal+console +SuccessExitStatus=255 +LimitCORE=infinity + +[Install] +WantedBy=multi-user.target diff --git a/packages/kmod-5.15-nvidia/nvidia-ld.so.conf.in b/packages/kmod-5.15-nvidia/nvidia-ld.so.conf.in new file mode 100644 index 00000000..f992bf22 --- /dev/null +++ b/packages/kmod-5.15-nvidia/nvidia-ld.so.conf.in @@ -0,0 +1 @@ +__LIBDIR__/nvidia/tesla/ diff --git a/packages/kmod-5.15-nvidia/nvidia-open-gpu-config.toml.in b/packages/kmod-5.15-nvidia/nvidia-open-gpu-config.toml.in new file mode 100644 index 00000000..5ae81b71 --- /dev/null +++ b/packages/kmod-5.15-nvidia/nvidia-open-gpu-config.toml.in @@ -0,0 +1,11 @@ +[nvidia-open-gpu] +lib-modules-path = "kernel/drivers/extra/video/nvidia/open-gpu" + +[nvidia-open-gpu.kernel-modules."nvidia.ko"] +copy-source = "__NVIDIA_MODULES__" + +[nvidia-open-gpu.kernel-modules."nvidia-modeset.ko"] +copy-source = "__NVIDIA_MODULES__" + +[nvidia-open-gpu.kernel-modules."nvidia-uvm.ko"] +copy-source = "__NVIDIA_MODULES__" diff --git a/packages/kmod-5.15-nvidia/nvidia-open-gpu-copy-only-config.toml.in b/packages/kmod-5.15-nvidia/nvidia-open-gpu-copy-only-config.toml.in new file mode 100644 index 00000000..774867d4 --- /dev/null +++ b/packages/kmod-5.15-nvidia/nvidia-open-gpu-copy-only-config.toml.in @@ -0,0 +1,8 @@ +[nvidia-open-gpu-copy-only] +lib-modules-path = "kernel/drivers/extra/video/nvidia/open-gpu" + +[nvidia-open-gpu-copy-only.kernel-modules."nvidia-drm.ko"] +copy-source = "__NVIDIA_MODULES__" + +[nvidia-open-gpu-copy-only.kernel-modules."nvidia-peermem.ko"] +copy-source = "__NVIDIA_MODULES__" diff --git a/packages/kmod-5.15-nvidia/nvidia-persistenced.service b/packages/kmod-5.15-nvidia/nvidia-persistenced.service new file mode 100644 index 00000000..f245599c --- /dev/null +++ b/packages/kmod-5.15-nvidia/nvidia-persistenced.service @@ -0,0 +1,10 @@ +[Unit] +Description=NVIDIA Persistence Daemon +After=load-tesla-kernel-modules.service load-open-gpu-kernel-modules.service + +[Service] +Type=forking +ExecStart=/usr/libexec/nvidia/tesla/bin/nvidia-persistenced --user nvidia --verbose + +[Install] +RequiredBy=preconfigured.target diff --git a/packages/kmod-5.15-nvidia/nvidia-sysusers.conf b/packages/kmod-5.15-nvidia/nvidia-sysusers.conf new file mode 100644 index 00000000..43ceba0e --- /dev/null +++ b/packages/kmod-5.15-nvidia/nvidia-sysusers.conf @@ -0,0 +1 @@ +u nvidia - "nvidia-persistenced user" \ No newline at end of file diff --git a/packages/kmod-5.15-nvidia/nvidia-tesla-build-config.toml.in b/packages/kmod-5.15-nvidia/nvidia-tesla-build-config.toml.in new file mode 100644 index 00000000..fb74dc51 --- /dev/null +++ b/packages/kmod-5.15-nvidia/nvidia-tesla-build-config.toml.in @@ -0,0 +1,18 @@ +[nvidia-tesla] +lib-modules-path = "kernel/drivers/extra/video/nvidia/tesla" +objects-source = "__NVIDIA_MODULES__" + +[nvidia-tesla.object-files."nvidia.o"] +link-objects = ["nv-interface.o", "nv-kernel.o"] + +[nvidia-tesla.kernel-modules."nvidia.ko"] +link-objects = ["nvidia.o", "nvidia.mod.o"] + +[nvidia-tesla.object-files."nvidia-modeset.o"] +link-objects = ["nv-modeset-interface.o", "nv-modeset-kernel.o"] + +[nvidia-tesla.kernel-modules."nvidia-modeset.ko"] +link-objects = ["nvidia-modeset.o", "nvidia-modeset.mod.o"] + +[nvidia-tesla.kernel-modules."nvidia-uvm.ko"] +link-objects = ["nvidia-uvm.o", "nvidia-uvm.mod.o"] diff --git a/packages/kmod-5.15-nvidia/nvidia-tesla-path.env.in b/packages/kmod-5.15-nvidia/nvidia-tesla-path.env.in new file mode 100644 index 00000000..28f74deb --- /dev/null +++ b/packages/kmod-5.15-nvidia/nvidia-tesla-path.env.in @@ -0,0 +1 @@ +NVIDIA_PATH=__NVIDIA_BINDIR__ diff --git a/packages/kmod-5.15-nvidia/nvidia-tesla-tmpfiles.conf b/packages/kmod-5.15-nvidia/nvidia-tesla-tmpfiles.conf new file mode 100644 index 00000000..fd0f4486 --- /dev/null +++ b/packages/kmod-5.15-nvidia/nvidia-tesla-tmpfiles.conf @@ -0,0 +1,5 @@ +C /etc/drivers/nvidia-tesla.toml +C /etc/drivers/nvidia-open-gpu.toml +C /etc/drivers/nvidia-open-gpu-copy-only.toml +C /etc/containerd/nvidia.env - - - - /usr/share/factory/nvidia/tesla/nvidia-path.env +C /etc/ld.so.conf.d/nvidia-tesla.conf diff --git a/packages/kmod-5.15-nvidia/nvidia-tmpfiles.conf.in b/packages/kmod-5.15-nvidia/nvidia-tmpfiles.conf.in new file mode 100644 index 00000000..37d0fb79 --- /dev/null +++ b/packages/kmod-5.15-nvidia/nvidia-tmpfiles.conf.in @@ -0,0 +1,7 @@ +R __PREFIX__/lib/modules/__KERNEL_VERSION__/kernel/drivers/extra/video/nvidia/tesla - - - - - +d __PREFIX__/lib/modules/__KERNEL_VERSION__/kernel/drivers/extra/video/nvidia/tesla 0755 root root - - +R __PREFIX__/lib/modules/__KERNEL_VERSION__/kernel/drivers/extra/video/nvidia/open-gpu - - - - - +d __PREFIX__/lib/modules/__KERNEL_VERSION__/kernel/drivers/extra/video/nvidia/open-gpu 0755 root root - - +C /etc/nvidia/fabricmanager.cfg - - - - +d /run/nvidia 0700 root root - +D /var/run/nvidia-persistenced 0755 nvidia nvidia - - \ No newline at end of file diff --git a/packages/kmod-6.1-nvidia/.gitignore b/packages/kmod-6.1-nvidia/.gitignore new file mode 100644 index 00000000..db8b415b --- /dev/null +++ b/packages/kmod-6.1-nvidia/.gitignore @@ -0,0 +1,3 @@ +NVidiaEULAforAWS.pdf +COPYING +*.rpm diff --git a/packages/kmod-6.1-nvidia/Cargo.toml b/packages/kmod-6.1-nvidia/Cargo.toml new file mode 100644 index 00000000..a3fc0f1d --- /dev/null +++ b/packages/kmod-6.1-nvidia/Cargo.toml @@ -0,0 +1,45 @@ +[package] +name = "kmod-6_1-nvidia" +version = "0.1.0" +edition = "2021" +publish = false +build = "../build.rs" + +[lib] +path = "../packages.rs" + +[package.metadata.build-package] +package-name = "kmod-6.1-nvidia" +releases-url = "https://docs.nvidia.com/datacenter/tesla/" + +[[package.metadata.build-package.external-files]] +url = "https://s3.amazonaws.com/EULA/NVidiaEULAforAWS.pdf" +sha512 = "e1926fe99afc3ab5b2f2744fcd53b4046465aefb2793e2e06c4a19455a3fde895e00af1415ff1a5804c32e6a2ed0657e475de63da6c23a0e9c59feeef52f3f58" + +[[package.metadata.build-package.external-files]] +url = "https://us.download.nvidia.com/tesla/535.216.01/NVIDIA-Linux-x86_64-535.216.01.run" +sha512 = "3b4ae3584368fcc5f81a680dd8588d8b9e48f43dafe2490f5414ed258fa8c9799ebd40d2fd115e20bd02648eeb3e5c6dff39562d89353580fa679d011cebf6f8" +force-upstream = true + +[[package.metadata.build-package.external-files]] +url = "https://us.download.nvidia.com/tesla/535.216.01/NVIDIA-Linux-aarch64-535.216.01.run" +sha512 = "f68794249bf18ba626c6a665880721c8cc0dada6c7c1d8b15bf17174a4cac35ca2ab534fff2410c8bc0326c48f6ab913b6d9a92630505eeb768e02610a7772d9" +force-upstream = true + +[[package.metadata.build-package.external-files]] +url = "https://developer.download.nvidia.com/compute/cuda/repos/rhel9/x86_64/nvidia-fabric-manager-535.216.01-1.x86_64.rpm" +sha512 = "9208004779a57418cef4e0eacfad549e01fc3e193cda24a4f809325fee3a74910350c7752372d5dba7b74e9d5bf9da5807bc8de2bedade6dbe23b270c3047dfe" +force-upstream = true + +[[package.metadata.build-package.external-files]] +url = "https://developer.download.nvidia.com/compute/cuda/repos/rhel9/sbsa/nvidia-fabric-manager-535.216.01-1.aarch64.rpm" +sha512 = "1f553e4627953cceef8f630d2be907829f8b78b789ffee7691ace541f759bdb07016e364c20e1d5779ce463f0b48448cea292f58a9899523ec840bb5a0c37b0e" +force-upstream = true + +[[package.metadata.build-package.external-files]] +url = "https://raw.githubusercontent.com/NVIDIA/open-gpu-kernel-modules/535/COPYING" +sha512 = "f9cee68cbb12095af4b4e92d01c210461789ef41c70b64efefd6719d0b88468b7a67a3629c432d4d9304c730b5d1a942228a5bcc74a03ab1c411c77c758cd938" +force-upstream = true + +[build-dependencies] +kernel-6_1 = { path = "../kernel-6.1" } diff --git a/packages/kmod-6.1-nvidia/copy-open-gpu-kernel-modules.service.in b/packages/kmod-6.1-nvidia/copy-open-gpu-kernel-modules.service.in new file mode 100644 index 00000000..2c3420b6 --- /dev/null +++ b/packages/kmod-6.1-nvidia/copy-open-gpu-kernel-modules.service.in @@ -0,0 +1,20 @@ +[Unit] +Description=Copy open GPU kernel modules +RequiresMountsFor=PREFIX/lib/modules PREFIX/src/kernels +# Rerunning this service after the system is fully loaded will override +# the already linked kernel modules. This doesn't affect the running system, +# since kernel modules are linked early in the boot sequence, but we still +# disable manual restarts to prevent unnecessary kernel modules rewrites. +RefuseManualStart=true +RefuseManualStop=true + +[Service] +Type=oneshot +ExecCondition=/usr/bin/ghostdog match-nvidia-driver open-gpu +ExecStart=/usr/bin/driverdog --modules-set nvidia-open-gpu link-modules +ExecStart=/usr/bin/driverdog --modules-set nvidia-open-gpu-copy-only link-modules +RemainAfterExit=true +StandardError=journal+console + +[Install] +RequiredBy=preconfigured.target diff --git a/packages/kmod-6.1-nvidia/kmod-6.1-nvidia.spec b/packages/kmod-6.1-nvidia/kmod-6.1-nvidia.spec new file mode 100644 index 00000000..b3b447f8 --- /dev/null +++ b/packages/kmod-6.1-nvidia/kmod-6.1-nvidia.spec @@ -0,0 +1,540 @@ +%global tesla_major 535 +%global tesla_minor 216 +%global tesla_patch 01 +%global tesla_ver %{tesla_major}.%{tesla_minor}.%{tesla_patch} +%if "%{?_cross_arch}" == "aarch64" +%global fm_arch sbsa +%else +%global fm_arch %{_cross_arch} +%endif + +# With the split of the firmware binary from firmware/gsp.bin to firmware/gsp_ga10x.bin +# and firmware/gsp_tu10x.bin the file format changed from executable to relocatable. +# The __spec_install_post macro will by default try to strip all binary files. +# Unfortunately the strip used is not compatible with the new file format. +# Redefine strip, so that these firmware binaries do not derail the build. +%global __strip /usr/bin/true + +Name: %{_cross_os}kmod-6.1-nvidia +Version: 1.0.0 +Release: 1%{?dist} +Epoch: 1 +Summary: NVIDIA drivers for the 6.1 kernel +# We use these licences because we only ship our own software in the main package, +# each subpackage includes the LICENSE file provided by the Licenses.toml file +License: Apache-2.0 OR MIT +URL: http://www.nvidia.com/ + +# NVIDIA archives from 0 to 199 +# NVIDIA .run scripts for kernel and userspace drivers +Source0: https://us.download.nvidia.com/tesla/%{tesla_ver}/NVIDIA-Linux-x86_64-%{tesla_ver}.run +Source1: https://us.download.nvidia.com/tesla/%{tesla_ver}/NVIDIA-Linux-aarch64-%{tesla_ver}.run +Source2: NVidiaEULAforAWS.pdf +Source3: COPYING + +# fabricmanager for NVSwitch +Source10: https://developer.download.nvidia.com/compute/cuda/repos/rhel9/x86_64/nvidia-fabric-manager-%{tesla_ver}-1.x86_64.rpm +Source11: https://developer.download.nvidia.com/compute/cuda/repos/rhel9/sbsa/nvidia-fabric-manager-%{tesla_ver}-1.aarch64.rpm + +# Common NVIDIA conf files from 200 to 299 +Source200: nvidia-tmpfiles.conf.in +Source202: nvidia-dependencies-modules-load.conf +Source203: nvidia-fabricmanager.service +Source204: nvidia-fabricmanager.cfg +Source205: nvidia-sysusers.conf +Source206: nvidia-persistenced.service + +# NVIDIA tesla conf files from 300 to 399 +Source300: nvidia-tesla-tmpfiles.conf +Source301: nvidia-tesla-build-config.toml.in +Source302: nvidia-open-gpu-config.toml.in +Source303: nvidia-open-gpu-copy-only-config.toml.in +Source304: nvidia-tesla-path.env.in +Source305: nvidia-ld.so.conf.in +Source306: link-tesla-kernel-modules.service.in +Source307: load-tesla-kernel-modules.service.in +Source308: copy-open-gpu-kernel-modules.service.in +Source309: load-open-gpu-kernel-modules.service.in + +BuildRequires: %{_cross_os}kernel-6.1-archive + +%description +%{summary}. + +%package fabricmanager +Summary: NVIDIA fabricmanager config and service files +Requires: %{name}-tesla(fabricmanager) + +%description fabricmanager +%{summary}. + +%package open-gpu-%{tesla_major} +Summary: NVIDIA %{tesla_major} Open GPU driver +Version: %{tesla_ver} +License: MIT AND GPL-2.0-only +Requires: %{_cross_os}variant-platform(aws) + +%description open-gpu-%{tesla_major} +%{summary}. + +%package tesla-%{tesla_major} +Summary: NVIDIA %{tesla_major} Tesla driver +Version: %{tesla_ver} +License: LicenseRef-NVIDIA-AWS-EULA +Requires: %{_cross_os}variant-platform(aws) +Requires: %{name} +Requires: %{name}-fabricmanager +Provides: %{name}-tesla(fabricmanager) +Requires: %{name}-open-gpu-%{tesla_major} + +%description tesla-%{tesla_major} +%{summary} + +%prep +# Extract nvidia sources with `-x`, otherwise the script will try to install +# the driver in the current run +sh %{_sourcedir}/NVIDIA-Linux-%{_cross_arch}-%{tesla_ver}.run -x + +# Extract fabricmanager from the rpm via cpio rather than `%%setup` since the +# correct source is architecture-dependent. +mkdir fabricmanager-linux-%{fm_arch}-%{tesla_ver}-archive +rpm2cpio %{_sourcedir}/nvidia-fabric-manager-%{tesla_ver}-1.%{_cross_arch}.rpm | cpio -idmV -D fabricmanager-linux-%{fm_arch}-%{tesla_ver}-archive + +# Add the license. +install -p -m 0644 %{S:2} . +install -p -m 0644 %{S:3} . + +%global kernel_sources %{_builddir}/kernel-devel +tar -xf %{_cross_datadir}/bottlerocket/kernel-devel.tar.xz + +%define _kernel_version %(ls %{kernel_sources}/include/config/kernel.release) +%global _cross_kmoddir %{_cross_libdir}/modules/%{_kernel_version} + +# This recipe was based in the NVIDIA yum/dnf specs: +# https://github.com/NVIDIA/yum-packaging-precompiled-kmod + +# Begin open driver build +pushd NVIDIA-Linux-%{_cross_arch}-%{tesla_ver}/kernel-open + +# We set IGNORE_CC_MISMATCH even though we are using the same compiler used to compile the kernel, if +# we don't set this flag the compilation fails +make %{?_smp_mflags} ARCH=%{_cross_karch} IGNORE_CC_MISMATCH=1 SYSSRC=%{kernel_sources} CC=%{_cross_target}-gcc LD=%{_cross_target}-ld + +# end open driver build +popd + +# Begin proprietary driver build +pushd NVIDIA-Linux-%{_cross_arch}-%{tesla_ver}/kernel + +# We set IGNORE_CC_MISMATCH even though we are using the same compiler used to compile the kernel, if +# we don't set this flag the compilation fails +make %{?_smp_mflags} ARCH=%{_cross_karch} IGNORE_CC_MISMATCH=1 SYSSRC=%{kernel_sources} CC=%{_cross_target}-gcc LD=%{_cross_target}-ld + +%{_cross_target}-strip -g --strip-unneeded nvidia/nv-interface.o +%{_cross_target}-strip -g --strip-unneeded nvidia-uvm.o +%{_cross_target}-strip -g --strip-unneeded nvidia-drm.o +%{_cross_target}-strip -g --strip-unneeded nvidia-peermem/nvidia-peermem.o +%{_cross_target}-strip -g --strip-unneeded nvidia-modeset/nv-modeset-interface.o + +# We delete these files since we just stripped the input .o files above, and +# will be build at runtime in the host +rm nvidia{,-modeset,-peermem}.o + +# Delete the .ko files created in make command, just to be safe that we +# don't include any linked module in the base image +rm nvidia{,-modeset,-peermem,-drm}.ko + +# End proprietary driver build +popd + +# Grab the list of supported devices +pushd NVIDIA-Linux-%{_cross_arch}-%{tesla_ver}/supported-gpus +# We want to grab all the `kernelopen` enabled chips except for this list that is best held back to the proprietary driver +# 10de:1db1 is V100-16G (P3dn) +# 10de:1db5 is V100-32G (P3dn) +# 10de:1eb8 is T4 (G4dn) +# 10de:1eb4 is T4G (G5g) +# 10de:2237 is A10G (G5) +# 10de:27b8 is L4 (G6) +# 10de:26b9 is L40S (G6e) +jq -r '.chips[] | select(.features[] | contains("kernelopen")) | +select(.devid != "0x1DB1" +and .devid != "0x1DB5" +and .devid != "0x1DEB8" +and .devid != "0x1EB4" +and .devid != "0x2237" +and .devid != "0x27B8" +and .devid != "0x26B9")' supported-gpus.json | jq -s '{"open-gpu": .}' > open-gpu-supported-devices.json +# confirm "NVIDIA H100" is in the resulting file to catch shape changes +jq -e '."open-gpu"[] | select(."devid" == "0x2330") | ."features"| index("kernelopen")' open-gpu-supported-devices.json +popd + +%install +install -d %{buildroot}%{_cross_libexecdir} +install -d %{buildroot}%{_cross_libdir} +install -d %{buildroot}%{_cross_tmpfilesdir} +install -d %{buildroot}%{_cross_unitdir} +install -d %{buildroot}%{_cross_factorydir}%{_cross_sysconfdir}/{drivers,ld.so.conf.d} +install -d %{buildroot}%{_cross_sysusersdir} +install -d %{buildroot}%{_cross_bindir} + +KERNEL_VERSION=$(cat %{kernel_sources}/include/config/kernel.release) +sed \ + -e "s|__KERNEL_VERSION__|${KERNEL_VERSION}|" \ + -e "s|__PREFIX__|%{_cross_prefix}|" %{S:200} > nvidia.conf +install -p -m 0644 nvidia.conf %{buildroot}%{_cross_tmpfilesdir} + +# Install modules-load.d drop-in to autoload required kernel modules +install -d %{buildroot}%{_cross_libdir}/modules-load.d +install -p -m 0644 %{S:202} %{buildroot}%{_cross_libdir}/modules-load.d/nvidia-dependencies.conf + +# NVIDIA fabric manager service unit and config +install -p -m 0644 %{S:203} %{buildroot}%{_cross_unitdir} +install -d %{buildroot}%{_cross_factorydir}%{_cross_sysconfdir}/nvidia +install -p -m 0644 %{S:204} %{buildroot}%{_cross_factorydir}%{_cross_sysconfdir}/nvidia/fabricmanager.cfg + +# Begin NVIDIA tesla driver +pushd NVIDIA-Linux-%{_cross_arch}-%{tesla_ver} +# Proprietary driver +install -d %{buildroot}%{_cross_libexecdir}/nvidia/tesla/bin +install -d %{buildroot}%{_cross_libdir}/nvidia/tesla +install -d %{buildroot}%{_cross_datadir}/nvidia/tesla/module-objects.d +install -d %{buildroot}%{_cross_factorydir}/nvidia/tesla +install -d %{buildroot}%{_cross_factorydir}/nvidia/open-gpu +install -d %{buildroot}%{_cross_datadir}/nvidia/open-gpu/drivers + +install -m 0644 %{S:300} %{buildroot}%{_cross_tmpfilesdir}/nvidia-tesla.conf +sed -e 's|__NVIDIA_MODULES__|%{_cross_datadir}/nvidia/tesla/module-objects.d/|' %{S:301} > \ + nvidia-tesla.toml +install -m 0644 nvidia-tesla.toml %{buildroot}%{_cross_factorydir}%{_cross_sysconfdir}/drivers +sed -e 's|__NVIDIA_MODULES__|%{_cross_datadir}/nvidia/open-gpu/drivers/|' %{S:302} > \ + nvidia-open-gpu.toml +install -m 0644 nvidia-open-gpu.toml %{buildroot}%{_cross_factorydir}%{_cross_sysconfdir}/drivers +sed -e 's|__NVIDIA_MODULES__|%{_cross_datadir}/nvidia/open-gpu/drivers/|' %{S:303} > \ + nvidia-open-gpu-copy-only.toml +install -m 0644 nvidia-open-gpu-copy-only.toml %{buildroot}%{_cross_factorydir}%{_cross_sysconfdir}/drivers +# Install nvidia-path environment file, will be used as a drop-in for containerd.service since +# libnvidia-container locates and mounts helper binaries into the containers from either +# `PATH` or `NVIDIA_PATH` +sed -e 's|__NVIDIA_BINDIR__|%{_cross_libexecdir}/nvidia/tesla/bin|' %{S:304} > nvidia-path.env +install -m 0644 nvidia-path.env %{buildroot}%{_cross_factorydir}/nvidia/tesla +# We need to add `_cross_libdir` to the paths loaded by the ldconfig service +# because libnvidia-container uses the `ldcache` file created by the service, to locate and mount the +# libraries into the containers +sed -e 's|__LIBDIR__|%{_cross_libdir}|' %{S:305} > nvidia-tesla.conf +install -m 0644 nvidia-tesla.conf %{buildroot}%{_cross_factorydir}%{_cross_sysconfdir}/ld.so.conf.d/ + +# Services to link/copy/load modules +sed -e 's|PREFIX|%{_cross_prefix}|g' %{S:306} > link-tesla-kernel-modules.service +sed -e 's|PREFIX|%{_cross_prefix}|g' %{S:307} > load-tesla-kernel-modules.service +install -p -m 0644 \ + link-tesla-kernel-modules.service \ + load-tesla-kernel-modules.service \ + %{buildroot}%{_cross_unitdir} + +sed -e 's|PREFIX|%{_cross_prefix}|g' %{S:308} > copy-open-gpu-kernel-modules.service +sed -e 's|PREFIX|%{_cross_prefix}|g' %{S:309} > load-open-gpu-kernel-modules.service +install -p -m 0644 \ + copy-open-gpu-kernel-modules.service \ + load-open-gpu-kernel-modules.service \ + %{buildroot}%{_cross_unitdir} + +# proprietary driver +install kernel/nvidia.mod.o %{buildroot}%{_cross_datadir}/nvidia/tesla/module-objects.d +install kernel/nvidia/nv-interface.o %{buildroot}%{_cross_datadir}/nvidia/tesla/module-objects.d +install kernel/nvidia/nv-kernel.o_binary %{buildroot}%{_cross_datadir}/nvidia/tesla/module-objects.d/nv-kernel.o + +# uvm +install kernel/nvidia-uvm.mod.o %{buildroot}%{_cross_datadir}/nvidia/tesla/module-objects.d +install kernel/nvidia-uvm.o %{buildroot}%{_cross_datadir}/nvidia/tesla/module-objects.d + +# modeset +install kernel/nvidia-modeset.mod.o %{buildroot}%{_cross_datadir}/nvidia/tesla/module-objects.d +install kernel/nvidia-modeset/nv-modeset-interface.o %{buildroot}%{_cross_datadir}/nvidia/tesla/module-objects.d +install kernel/nvidia-modeset/nv-modeset-kernel.o %{buildroot}%{_cross_datadir}/nvidia/tesla/module-objects.d + +# peermem +install kernel/nvidia-peermem.mod.o %{buildroot}%{_cross_datadir}/nvidia/tesla/module-objects.d +install kernel/nvidia-peermem/nvidia-peermem.o %{buildroot}%{_cross_datadir}/nvidia/tesla/module-objects.d + +# drm +install kernel/nvidia-drm.mod.o %{buildroot}/%{_cross_datadir}/nvidia/tesla/module-objects.d +install kernel/nvidia-drm.o %{buildroot}/%{_cross_datadir}/nvidia/tesla/module-objects.d + +# open driver +install -d %{buildroot}%{_cross_datadir}/nvidia/open-gpu/drivers/ +install kernel-open/nvidia.ko %{buildroot}%{_cross_datadir}/nvidia/open-gpu/drivers/ + +# uvm +install kernel-open/nvidia-uvm.ko %{buildroot}%{_cross_datadir}/nvidia/open-gpu/drivers/ + +# modeset +install kernel-open/nvidia-modeset.ko %{buildroot}%{_cross_datadir}/nvidia/open-gpu/drivers/ + +# peermem +install kernel-open/nvidia-peermem.ko %{buildroot}%{_cross_datadir}/nvidia/open-gpu/drivers/ + +# drm +install kernel-open/nvidia-drm.ko %{buildroot}%{_cross_datadir}/nvidia/open-gpu/drivers/ +# end open driver + +# Binaries +install -m 755 nvidia-smi %{buildroot}%{_cross_libexecdir}/nvidia/tesla/bin +install -m 755 nvidia-debugdump %{buildroot}%{_cross_libexecdir}/nvidia/tesla/bin +install -m 755 nvidia-cuda-mps-control %{buildroot}%{_cross_libexecdir}/nvidia/tesla/bin +install -m 755 nvidia-cuda-mps-server %{buildroot}%{_cross_libexecdir}/nvidia/tesla/bin +install -m 755 nvidia-persistenced %{buildroot}%{_cross_libexecdir}/nvidia/tesla/bin/ +install -m 4755 nvidia-modprobe %{buildroot}%{_cross_bindir} +%if "%{_cross_arch}" == "x86_64" +install -m 755 nvidia-ngx-updater %{buildroot}%{_cross_libexecdir}/nvidia/tesla/bin +%endif + +# Users +install -m 0644 %{S:205} %{buildroot}%{_cross_sysusersdir}/nvidia.conf + +# Systemd units +install -m 0644 %{S:206} %{buildroot}%{_cross_unitdir} + +# We install all the libraries, and filter them out in the 'files' section, so we can catch +# when new libraries are added +install -m 755 *.so* %{buildroot}/%{_cross_libdir}/nvidia/tesla/ + +# This library has the same SONAME as libEGL.so.1.1.0, this will cause collisions while +# the symlinks are created. For now, we only symlink libEGL.so.1.1.0. +EXCLUDED_LIBS="libEGL.so.%{tesla_ver}" + +for lib in $(find . -maxdepth 1 -type f -name 'lib*.so.*' -printf '%%P\n'); do + [[ "${EXCLUDED_LIBS}" =~ "${lib}" ]] && continue + soname="$(%{_cross_target}-readelf -d "${lib}" | awk '/SONAME/{print $5}' | tr -d '[]')" + [ -n "${soname}" ] || continue + [ "${lib}" == "${soname}" ] && continue + ln -s "${lib}" %{buildroot}/%{_cross_libdir}/nvidia/tesla/"${soname}" +done + +# Include the firmware file for GSP support +install -d %{buildroot}%{_cross_libdir}/firmware/nvidia/%{tesla_ver} +install -p -m 0644 firmware/gsp_ga10x.bin %{buildroot}%{_cross_libdir}/firmware/nvidia/%{tesla_ver} +install -p -m 0644 firmware/gsp_tu10x.bin %{buildroot}%{_cross_libdir}/firmware/nvidia/%{tesla_ver} + +# Include the open driver supported devices file for runtime matching of the driver. This is consumed by ghostdog to match the driver to this list +install -p -m 0644 supported-gpus/open-gpu-supported-devices.json %{buildroot}%{_cross_datadir}/nvidia/open-gpu-supported-devices.json + +popd + +# Begin NVIDIA fabric manager binaries and topologies +pushd fabricmanager-linux-%{fm_arch}-%{tesla_ver}-archive +install -p -m 0755 usr/bin/nv-fabricmanager %{buildroot}%{_cross_libexecdir}/nvidia/tesla/bin +install -p -m 0755 usr/bin/nvswitch-audit %{buildroot}%{_cross_libexecdir}/nvidia/tesla/bin + +install -d %{buildroot}%{_cross_datadir}/nvidia/tesla/nvswitch +for t in usr/share/nvidia/nvswitch/*_topology ; do + install -p -m 0644 "${t}" %{buildroot}%{_cross_datadir}/nvidia/tesla/nvswitch +done + +popd + +%files +%{_cross_attribution_file} +%dir %{_cross_libexecdir}/nvidia +%dir %{_cross_libdir}/nvidia +%dir %{_cross_datadir}/nvidia +%dir %{_cross_libdir}/modules-load.d +%dir %{_cross_factorydir}%{_cross_sysconfdir}/drivers +%dir %{_cross_factorydir}%{_cross_sysconfdir}/nvidia +%{_cross_tmpfilesdir}/nvidia.conf +%{_cross_libdir}/modules-load.d/nvidia-dependencies.conf + +%files tesla-%{tesla_major} +%license NVidiaEULAforAWS.pdf +%license fabricmanager-linux-%{fm_arch}-%{tesla_ver}-archive/usr/share/doc/nvidia-fabricmanager/third-party-notices.txt +%dir %{_cross_datadir}/nvidia/tesla +%dir %{_cross_libexecdir}/nvidia/tesla/bin +%dir %{_cross_libdir}/nvidia/tesla +%dir %{_cross_libdir}/firmware/nvidia/%{tesla_ver} +%dir %{_cross_datadir}/nvidia/tesla/module-objects.d +%dir %{_cross_factorydir}/nvidia/tesla + +# Service files for link/copy/loading drivers +%{_cross_unitdir}/link-tesla-kernel-modules.service +%{_cross_unitdir}/load-tesla-kernel-modules.service +%{_cross_unitdir}/copy-open-gpu-kernel-modules.service +%{_cross_unitdir}/load-open-gpu-kernel-modules.service + +# Binaries +%{_cross_libexecdir}/nvidia/tesla/bin/nvidia-debugdump +%{_cross_libexecdir}/nvidia/tesla/bin/nvidia-smi +%{_cross_libexecdir}/nvidia/tesla/bin/nv-fabricmanager +%{_cross_libexecdir}/nvidia/tesla/bin/nvswitch-audit +%{_cross_libexecdir}/nvidia/tesla/bin/nvidia-persistenced +%{_cross_bindir}/nvidia-modprobe + +# nvswitch topologies +%dir %{_cross_datadir}/nvidia/tesla/nvswitch +%{_cross_datadir}/nvidia/tesla/nvswitch/dgxa100_hgxa100_topology +%{_cross_datadir}/nvidia/tesla/nvswitch/dgx2_hgx2_topology +%{_cross_datadir}/nvidia/tesla/nvswitch/dgxh100_hgxh100_topology +%{_cross_datadir}/nvidia/tesla/nvswitch/dgxh800_hgxh800_topology + +# Configuration files +%{_cross_factorydir}%{_cross_sysconfdir}/drivers/nvidia-tesla.toml +%{_cross_factorydir}%{_cross_sysconfdir}/drivers/nvidia-open-gpu.toml +%{_cross_factorydir}%{_cross_sysconfdir}/drivers/nvidia-open-gpu-copy-only.toml +%{_cross_factorydir}%{_cross_sysconfdir}/ld.so.conf.d/nvidia-tesla.conf +%{_cross_factorydir}/nvidia/tesla/nvidia-path.env +%{_cross_datadir}/nvidia/open-gpu-supported-devices.json + +# driver +%{_cross_datadir}/nvidia/tesla/module-objects.d/nvidia.mod.o +%{_cross_datadir}/nvidia/tesla/module-objects.d/nv-interface.o +%{_cross_datadir}/nvidia/tesla/module-objects.d/nv-kernel.o + +# uvm +%{_cross_datadir}/nvidia/tesla/module-objects.d/nvidia-uvm.mod.o +%{_cross_datadir}/nvidia/tesla/module-objects.d/nvidia-uvm.o + +# modeset +%{_cross_datadir}/nvidia/tesla/module-objects.d/nv-modeset-interface.o +%{_cross_datadir}/nvidia/tesla/module-objects.d/nv-modeset-kernel.o +%{_cross_datadir}/nvidia/tesla/module-objects.d/nvidia-modeset.mod.o + +# tmpfiles +%{_cross_tmpfilesdir}/nvidia-tesla.conf + +# sysuser files +%{_cross_sysusersdir}/nvidia.conf + +# systemd units +%{_cross_unitdir}/nvidia-persistenced.service + +# We only install the libraries required by all the DRIVER_CAPABILITIES, described here: +# https://docs.nvidia.com/datacenter/cloud-native/container-toolkit/user-guide.html#driver-capabilities + +# Utility libs +%{_cross_libdir}/nvidia/tesla/libnvidia-api.so.1 +%{_cross_libdir}/nvidia/tesla/libnvidia-ml.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libnvidia-ml.so.1 +%{_cross_libdir}/nvidia/tesla/libnvidia-cfg.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libnvidia-cfg.so.1 +%{_cross_libdir}/nvidia/tesla/libnvidia-nvvm.so.4 +%{_cross_libdir}/nvidia/tesla/libnvidia-nvvm.so.%{tesla_ver} + +# Compute libs +%{_cross_libdir}/nvidia/tesla/libcuda.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libcuda.so.1 +%{_cross_libdir}/nvidia/tesla/libcudadebugger.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libcudadebugger.so.1 +%{_cross_libdir}/nvidia/tesla/libnvidia-opencl.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libnvidia-opencl.so.1 +%{_cross_libdir}/nvidia/tesla/libnvidia-ptxjitcompiler.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libnvidia-ptxjitcompiler.so.1 +%{_cross_libdir}/nvidia/tesla/libnvidia-allocator.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libnvidia-allocator.so.1 +%{_cross_libdir}/nvidia/tesla/libOpenCL.so.1.0.0 +%{_cross_libdir}/nvidia/tesla/libOpenCL.so.1 +%if "%{_cross_arch}" == "x86_64" +%{_cross_libdir}/nvidia/tesla/libnvidia-pkcs11.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libnvidia-pkcs11-openssl3.so.%{tesla_ver} +%endif + +# Video libs +%{_cross_libdir}/nvidia/tesla/libvdpau_nvidia.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libvdpau_nvidia.so.1 +%{_cross_libdir}/nvidia/tesla/libnvidia-encode.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libnvidia-encode.so.1 +%{_cross_libdir}/nvidia/tesla/libnvidia-opticalflow.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libnvidia-opticalflow.so.1 +%{_cross_libdir}/nvidia/tesla/libnvcuvid.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libnvcuvid.so.1 + +# Graphics libs +%{_cross_libdir}/nvidia/tesla/libnvidia-eglcore.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libnvidia-glcore.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libnvidia-tls.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libnvidia-glsi.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libnvidia-rtcore.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libnvidia-fbc.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libnvidia-fbc.so.1 +%{_cross_libdir}/nvidia/tesla/libnvoptix.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libnvoptix.so.1 +%{_cross_libdir}/nvidia/tesla/libnvidia-vulkan-producer.so.%{tesla_ver} + +# Graphics GLVND libs +%{_cross_libdir}/nvidia/tesla/libnvidia-glvkspirv.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libGLX_nvidia.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libGLX_nvidia.so.0 +%{_cross_libdir}/nvidia/tesla/libEGL_nvidia.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libEGL_nvidia.so.0 +%{_cross_libdir}/nvidia/tesla/libGLESv2_nvidia.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libGLESv2_nvidia.so.2 +%{_cross_libdir}/nvidia/tesla/libGLESv1_CM_nvidia.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libGLESv1_CM_nvidia.so.1 + +# Graphics compat +%{_cross_libdir}/nvidia/tesla/libEGL.so.1.1.0 +%{_cross_libdir}/nvidia/tesla/libEGL.so.1 +%{_cross_libdir}/nvidia/tesla/libEGL.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libGL.so.1.7.0 +%{_cross_libdir}/nvidia/tesla/libGL.so.1 +%{_cross_libdir}/nvidia/tesla/libGLESv1_CM.so.1.2.0 +%{_cross_libdir}/nvidia/tesla/libGLESv1_CM.so.1 +%{_cross_libdir}/nvidia/tesla/libGLESv2.so.2.1.0 +%{_cross_libdir}/nvidia/tesla/libGLESv2.so.2 + +# NGX +%{_cross_libdir}/nvidia/tesla/libnvidia-ngx.so.%{tesla_ver} +%{_cross_libdir}/nvidia/tesla/libnvidia-ngx.so.1 + +# Firmware +%{_cross_libdir}/firmware/nvidia/%{tesla_ver}/gsp_ga10x.bin +%{_cross_libdir}/firmware/nvidia/%{tesla_ver}/gsp_tu10x.bin + +# Neither nvidia-peermem nor nvidia-drm are included in driver container images, we exclude them +# for now, and we will add them if requested +%exclude %{_cross_datadir}/nvidia/tesla/module-objects.d/nvidia-peermem.mod.o +%exclude %{_cross_datadir}/nvidia/tesla/module-objects.d/nvidia-peermem.o +%exclude %{_cross_datadir}/nvidia/tesla/module-objects.d/nvidia-drm.mod.o +%exclude %{_cross_datadir}/nvidia/tesla/module-objects.d/nvidia-drm.o +%exclude %{_cross_libexecdir}/nvidia/tesla/bin/nvidia-cuda-mps-control +%exclude %{_cross_libexecdir}/nvidia/tesla/bin/nvidia-cuda-mps-server +%if "%{_cross_arch}" == "x86_64" +%exclude %{_cross_libexecdir}/nvidia/tesla/bin/nvidia-ngx-updater +%endif + +# None of these libraries are required by libnvidia-container, so they +# won't be used by a containerized workload +%exclude %{_cross_libdir}/nvidia/tesla/libGLX.so.0 +%exclude %{_cross_libdir}/nvidia/tesla/libGLdispatch.so.0 +%exclude %{_cross_libdir}/nvidia/tesla/libOpenGL.so.0 +%exclude %{_cross_libdir}/nvidia/tesla/libglxserver_nvidia.so.%{tesla_ver} +%exclude %{_cross_libdir}/nvidia/tesla/libnvidia-gtk2.so.%{tesla_ver} +%exclude %{_cross_libdir}/nvidia/tesla/libnvidia-gtk3.so.%{tesla_ver} +%exclude %{_cross_libdir}/nvidia/tesla/nvidia_drv.so +%exclude %{_cross_libdir}/nvidia/tesla/libnvidia-egl-wayland.so.1 +%exclude %{_cross_libdir}/nvidia/tesla/libnvidia-egl-gbm.so.1 +%exclude %{_cross_libdir}/nvidia/tesla/libnvidia-egl-gbm.so.1.1.0 +%exclude %{_cross_libdir}/nvidia/tesla/libnvidia-egl-wayland.so.1.1.11 +%exclude %{_cross_libdir}/nvidia/tesla/libnvidia-wayland-client.so.%{tesla_ver} + +%files open-gpu-%{tesla_major} +%license COPYING +%dir %{_cross_datadir}/nvidia/open-gpu/drivers +%dir %{_cross_factorydir}/nvidia/open-gpu + +# driver +%{_cross_datadir}/nvidia/open-gpu/drivers/nvidia.ko + +# uvm +%{_cross_datadir}/nvidia/open-gpu/drivers/nvidia-uvm.ko + +# modeset +%{_cross_datadir}/nvidia/open-gpu/drivers/nvidia-modeset.ko + +# drm +%{_cross_datadir}/nvidia/open-gpu/drivers/nvidia-drm.ko + +# peermem +%{_cross_datadir}/nvidia/open-gpu/drivers/nvidia-peermem.ko + +%files fabricmanager +%{_cross_factorydir}%{_cross_sysconfdir}/nvidia/fabricmanager.cfg +%{_cross_unitdir}/nvidia-fabricmanager.service diff --git a/packages/kmod-6.1-nvidia/link-tesla-kernel-modules.service.in b/packages/kmod-6.1-nvidia/link-tesla-kernel-modules.service.in new file mode 100644 index 00000000..8fc77921 --- /dev/null +++ b/packages/kmod-6.1-nvidia/link-tesla-kernel-modules.service.in @@ -0,0 +1,19 @@ +[Unit] +Description=Link Tesla kernel modules +RequiresMountsFor=PREFIX/lib/modules PREFIX/src/kernels +# Rerunning this service after the system is fully loaded will override +# the already linked kernel modules. This doesn't affect the running system, +# since kernel modules are linked early in the boot sequence, but we still +# disable manual restarts to prevent unnecessary kernel modules rewrites. +RefuseManualStart=true +RefuseManualStop=true + +[Service] +Type=oneshot +ExecCondition=/usr/bin/ghostdog match-nvidia-driver tesla +ExecStart=/usr/bin/driverdog --modules-set nvidia-tesla link-modules +RemainAfterExit=true +StandardError=journal+console + +[Install] +RequiredBy=preconfigured.target diff --git a/packages/kmod-6.1-nvidia/load-open-gpu-kernel-modules.service.in b/packages/kmod-6.1-nvidia/load-open-gpu-kernel-modules.service.in new file mode 100644 index 00000000..3862b3e7 --- /dev/null +++ b/packages/kmod-6.1-nvidia/load-open-gpu-kernel-modules.service.in @@ -0,0 +1,19 @@ +[Unit] +Description=Load open GPU kernel modules +RequiresMountsFor=PREFIX/lib/modules PREFIX/src/kernels +After=copy-open-gpu-kernel-modules.service +Requires=copy-open-gpu-kernel-modules.service +# Disable manual restarts to prevent loading kernel modules +# that weren't linked by the running system +RefuseManualStart=true +RefuseManualStop=true + +[Service] +Type=oneshot +ExecCondition=/usr/bin/ghostdog match-nvidia-driver open-gpu +ExecStart=/usr/bin/driverdog --modules-set nvidia-open-gpu load-modules +RemainAfterExit=true +StandardError=journal+console + +[Install] +RequiredBy=preconfigured.target diff --git a/packages/kmod-6.1-nvidia/load-tesla-kernel-modules.service.in b/packages/kmod-6.1-nvidia/load-tesla-kernel-modules.service.in new file mode 100644 index 00000000..60024004 --- /dev/null +++ b/packages/kmod-6.1-nvidia/load-tesla-kernel-modules.service.in @@ -0,0 +1,19 @@ +[Unit] +Description=Load Tesla kernel modules +RequiresMountsFor=PREFIX/lib/modules PREFIX/src/kernels +After=link-tesla-kernel-modules.service +Requires=link-tesla-kernel-modules.service +# Disable manual restarts to prevent loading kernel modules +# that weren't linked by the running system +RefuseManualStart=true +RefuseManualStop=true + +[Service] +Type=oneshot +ExecCondition=/usr/bin/ghostdog match-nvidia-driver tesla +ExecStart=/usr/bin/driverdog --modules-set nvidia-tesla load-modules +RemainAfterExit=true +StandardError=journal+console + +[Install] +RequiredBy=preconfigured.target diff --git a/packages/kmod-6.1-nvidia/nvidia-dependencies-modules-load.conf b/packages/kmod-6.1-nvidia/nvidia-dependencies-modules-load.conf new file mode 100644 index 00000000..86f884a6 --- /dev/null +++ b/packages/kmod-6.1-nvidia/nvidia-dependencies-modules-load.conf @@ -0,0 +1,2 @@ +i2c_core +ipmi_msghandler diff --git a/packages/kmod-6.1-nvidia/nvidia-fabricmanager.cfg b/packages/kmod-6.1-nvidia/nvidia-fabricmanager.cfg new file mode 100644 index 00000000..f8dc08ea --- /dev/null +++ b/packages/kmod-6.1-nvidia/nvidia-fabricmanager.cfg @@ -0,0 +1,34 @@ +# Modern, systemd-aware settings: +# - Log to journal via stderr +# - Keep running in the foreground +LOG_LEVEL=4 +LOG_FILE_NAME= +DAEMONIZE=0 + +# Use Unix domain sockets instead of localhost ports. +UNIX_SOCKET_PATH=/run/nvidia/fabricmanager.sock +FM_CMD_UNIX_SOCKET_PATH=/run/nvidia/fabricmanager-cmd.sock + +# Start Fabric Manager in bare metal or full pass through virtualization mode. +FABRIC_MODE=0 +FABRIC_MODE_RESTART=0 + +# Terminate on NVSwitch and GPU config failure. +FM_STAY_RESIDENT_ON_FAILURES=0 + +# When there is a GPU to NVSwitch NVLink failure, remove the GPU with the failure +# from NVLink P2P capability. +ACCESS_LINK_FAILURE_MODE=0 + +# When there is an NVSwitch to NVSwitch NVLink failure, exit Fabric Manager. +TRUNK_LINK_FAILURE_MODE=0 + +# When there is an NVSwitch failure or an NVSwitch is excluded, abort Fabric Manager. +NVSWITCH_FAILURE_MODE=0 + +# When Fabric Manager service is stopped or terminated, abort all running CUDA jobs. +ABORT_CUDA_JOBS_ON_FM_EXIT=1 + +# Path to topology and database files. +TOPOLOGY_FILE_PATH=/usr/share/nvidia/tesla/nvswitch +DATABASE_PATH=/usr/share/nvidia/tesla/nvswitch diff --git a/packages/kmod-6.1-nvidia/nvidia-fabricmanager.service b/packages/kmod-6.1-nvidia/nvidia-fabricmanager.service new file mode 100644 index 00000000..62ae1368 --- /dev/null +++ b/packages/kmod-6.1-nvidia/nvidia-fabricmanager.service @@ -0,0 +1,16 @@ +[Unit] +Description=NVIDIA fabric manager service + +[Service] +ExecStart=/usr/libexec/nvidia/tesla/bin/nv-fabricmanager -c /etc/nvidia/fabricmanager.cfg +Type=simple +TimeoutSec=0 +RestartSec=5 +Restart=always +RemainAfterExit=true +StandardError=journal+console +SuccessExitStatus=255 +LimitCORE=infinity + +[Install] +WantedBy=multi-user.target diff --git a/packages/kmod-6.1-nvidia/nvidia-ld.so.conf.in b/packages/kmod-6.1-nvidia/nvidia-ld.so.conf.in new file mode 100644 index 00000000..f992bf22 --- /dev/null +++ b/packages/kmod-6.1-nvidia/nvidia-ld.so.conf.in @@ -0,0 +1 @@ +__LIBDIR__/nvidia/tesla/ diff --git a/packages/kmod-6.1-nvidia/nvidia-open-gpu-config.toml.in b/packages/kmod-6.1-nvidia/nvidia-open-gpu-config.toml.in new file mode 100644 index 00000000..5ae81b71 --- /dev/null +++ b/packages/kmod-6.1-nvidia/nvidia-open-gpu-config.toml.in @@ -0,0 +1,11 @@ +[nvidia-open-gpu] +lib-modules-path = "kernel/drivers/extra/video/nvidia/open-gpu" + +[nvidia-open-gpu.kernel-modules."nvidia.ko"] +copy-source = "__NVIDIA_MODULES__" + +[nvidia-open-gpu.kernel-modules."nvidia-modeset.ko"] +copy-source = "__NVIDIA_MODULES__" + +[nvidia-open-gpu.kernel-modules."nvidia-uvm.ko"] +copy-source = "__NVIDIA_MODULES__" diff --git a/packages/kmod-6.1-nvidia/nvidia-open-gpu-copy-only-config.toml.in b/packages/kmod-6.1-nvidia/nvidia-open-gpu-copy-only-config.toml.in new file mode 100644 index 00000000..774867d4 --- /dev/null +++ b/packages/kmod-6.1-nvidia/nvidia-open-gpu-copy-only-config.toml.in @@ -0,0 +1,8 @@ +[nvidia-open-gpu-copy-only] +lib-modules-path = "kernel/drivers/extra/video/nvidia/open-gpu" + +[nvidia-open-gpu-copy-only.kernel-modules."nvidia-drm.ko"] +copy-source = "__NVIDIA_MODULES__" + +[nvidia-open-gpu-copy-only.kernel-modules."nvidia-peermem.ko"] +copy-source = "__NVIDIA_MODULES__" diff --git a/packages/kmod-6.1-nvidia/nvidia-persistenced.service b/packages/kmod-6.1-nvidia/nvidia-persistenced.service new file mode 100644 index 00000000..f245599c --- /dev/null +++ b/packages/kmod-6.1-nvidia/nvidia-persistenced.service @@ -0,0 +1,10 @@ +[Unit] +Description=NVIDIA Persistence Daemon +After=load-tesla-kernel-modules.service load-open-gpu-kernel-modules.service + +[Service] +Type=forking +ExecStart=/usr/libexec/nvidia/tesla/bin/nvidia-persistenced --user nvidia --verbose + +[Install] +RequiredBy=preconfigured.target diff --git a/packages/kmod-6.1-nvidia/nvidia-sysusers.conf b/packages/kmod-6.1-nvidia/nvidia-sysusers.conf new file mode 100644 index 00000000..43ceba0e --- /dev/null +++ b/packages/kmod-6.1-nvidia/nvidia-sysusers.conf @@ -0,0 +1 @@ +u nvidia - "nvidia-persistenced user" \ No newline at end of file diff --git a/packages/kmod-6.1-nvidia/nvidia-tesla-build-config.toml.in b/packages/kmod-6.1-nvidia/nvidia-tesla-build-config.toml.in new file mode 100644 index 00000000..fb74dc51 --- /dev/null +++ b/packages/kmod-6.1-nvidia/nvidia-tesla-build-config.toml.in @@ -0,0 +1,18 @@ +[nvidia-tesla] +lib-modules-path = "kernel/drivers/extra/video/nvidia/tesla" +objects-source = "__NVIDIA_MODULES__" + +[nvidia-tesla.object-files."nvidia.o"] +link-objects = ["nv-interface.o", "nv-kernel.o"] + +[nvidia-tesla.kernel-modules."nvidia.ko"] +link-objects = ["nvidia.o", "nvidia.mod.o"] + +[nvidia-tesla.object-files."nvidia-modeset.o"] +link-objects = ["nv-modeset-interface.o", "nv-modeset-kernel.o"] + +[nvidia-tesla.kernel-modules."nvidia-modeset.ko"] +link-objects = ["nvidia-modeset.o", "nvidia-modeset.mod.o"] + +[nvidia-tesla.kernel-modules."nvidia-uvm.ko"] +link-objects = ["nvidia-uvm.o", "nvidia-uvm.mod.o"] diff --git a/packages/kmod-6.1-nvidia/nvidia-tesla-path.env.in b/packages/kmod-6.1-nvidia/nvidia-tesla-path.env.in new file mode 100644 index 00000000..28f74deb --- /dev/null +++ b/packages/kmod-6.1-nvidia/nvidia-tesla-path.env.in @@ -0,0 +1 @@ +NVIDIA_PATH=__NVIDIA_BINDIR__ diff --git a/packages/kmod-6.1-nvidia/nvidia-tesla-tmpfiles.conf b/packages/kmod-6.1-nvidia/nvidia-tesla-tmpfiles.conf new file mode 100644 index 00000000..fd0f4486 --- /dev/null +++ b/packages/kmod-6.1-nvidia/nvidia-tesla-tmpfiles.conf @@ -0,0 +1,5 @@ +C /etc/drivers/nvidia-tesla.toml +C /etc/drivers/nvidia-open-gpu.toml +C /etc/drivers/nvidia-open-gpu-copy-only.toml +C /etc/containerd/nvidia.env - - - - /usr/share/factory/nvidia/tesla/nvidia-path.env +C /etc/ld.so.conf.d/nvidia-tesla.conf diff --git a/packages/kmod-6.1-nvidia/nvidia-tmpfiles.conf.in b/packages/kmod-6.1-nvidia/nvidia-tmpfiles.conf.in new file mode 100644 index 00000000..37d0fb79 --- /dev/null +++ b/packages/kmod-6.1-nvidia/nvidia-tmpfiles.conf.in @@ -0,0 +1,7 @@ +R __PREFIX__/lib/modules/__KERNEL_VERSION__/kernel/drivers/extra/video/nvidia/tesla - - - - - +d __PREFIX__/lib/modules/__KERNEL_VERSION__/kernel/drivers/extra/video/nvidia/tesla 0755 root root - - +R __PREFIX__/lib/modules/__KERNEL_VERSION__/kernel/drivers/extra/video/nvidia/open-gpu - - - - - +d __PREFIX__/lib/modules/__KERNEL_VERSION__/kernel/drivers/extra/video/nvidia/open-gpu 0755 root root - - +C /etc/nvidia/fabricmanager.cfg - - - - +d /run/nvidia 0700 root root - +D /var/run/nvidia-persistenced 0755 nvidia nvidia - - \ No newline at end of file diff --git a/packages/libkcapi/Cargo.toml b/packages/libkcapi/Cargo.toml new file mode 100644 index 00000000..5f287ce3 --- /dev/null +++ b/packages/libkcapi/Cargo.toml @@ -0,0 +1,16 @@ +[package] +name = "libkcapi" +version = "0.1.0" +edition = "2021" +publish = false +build = "../build.rs" + +[lib] +path = "../packages.rs" + +[[package.metadata.build-package.external-files]] +url = "https://cdn.amazonlinux.com/al2023/blobstore/0eef74b3b4eb1ec321bab80f867aee89b94dc9fc95571da58ea5bba7a70e6224/libkcapi-1.4.0-105.amzn2023.0.1.src.rpm" +sha512 = "6498147434059343f1ccdd7efadcd425ad7074e41b4e019fc995129d5df326b781e0a61a4324e1ce8d6771162d1612b754ce24625fb3b1458811f6bde8f638c9" +force-upstream = true + +[build-dependencies] diff --git a/packages/libkcapi/libkcapi.spec b/packages/libkcapi/libkcapi.spec new file mode 100644 index 00000000..eb07d200 --- /dev/null +++ b/packages/libkcapi/libkcapi.spec @@ -0,0 +1,76 @@ +# Helper functions that use OpenSSL to compute an HMAC with specified keys. +%global openssl_sha512_hmac openssl sha512 -hmac FIPS-FTW-RHT2009 -hex +%global openssl_sha256_hmac openssl sha256 -hmac orboDeJITITejsirpADONivirpUkvarP -hex + +# We need to compute the HMAC after the binaries have been stripped. +%define __spec_install_post\ +%{?__debug_package:%{__debug_install_post}}\ +%{__arch_install_post}\ +%{__os_install_post}\ +cd %{buildroot}/%{_cross_bindir}\ +%openssl_sha512_hmac sha512hmac\\\ + | awk '{ print $2 }' > .sha512hmac.hmac\ +cd %{buildroot}/%{_cross_libdir}\ +%openssl_sha256_hmac libkcapi.so.%{version}\\\ + | awk '{ print $2 }' > .libkcapi.so.%{version}.hmac\ +ln -s .libkcapi.so.%{version}.hmac .libkcapi.so.1.hmac\ +%{nil} + +Name: %{_cross_os}libkcapi +Version: 1.4.0 +Release: 1%{?dist} +Epoch: 2 +Summary: Library for kernel crypto API +License: BSD-3-Clause OR GPL-2.0-only +URL: https://www.chronox.de/libkcapi/html/index.html +Source0: https://cdn.amazonlinux.com/al2023/blobstore/0eef74b3b4eb1ec321bab80f867aee89b94dc9fc95571da58ea5bba7a70e6224/libkcapi-1.4.0-105.amzn2023.0.1.src.rpm + +%description +%{summary}. + +%package devel +Summary: Files for development using the library for kernel crypto API +Requires: %{name} + +%description devel +%{summary}. + +%prep +rpm2cpio %{SOURCE0} | cpio -iu libkcapi-%{version}.tar.xz +tar -xof libkcapi-%{version}.tar.xz; rm libkcapi-%{version}.tar.xz +%setup -TDn libkcapi-%{version} + +%build +autoreconf -fi +%cross_configure \ + --disable-static \ + --enable-shared \ + --enable-kcapi-hasher \ + +%force_disable_rpath + +%make_build + +%install +%make_install + +# Remove all binaries except `sha512hmac`. +find %{buildroot}%{_cross_bindir} -type f ! -name 'sha512hmac' -delete + +# Clean up HMAC signatures, which will be regenerated. +find %{buildroot} -type f -name '*.hmac' -delete + +%files +%license COPYING COPYING.bsd COPYING.gplv2 +%{_cross_attribution_file} +%{_cross_libdir}/*.so.* +%{_cross_libdir}/.*.so.*.hmac +%{_cross_bindir}/sha512hmac +%{_cross_bindir}/.sha512hmac.hmac + +%files devel +%{_cross_libdir}/*.so +%{_cross_includedir}/kcapi.h +%{_cross_pkgconfigdir}/*.pc + +%changelog diff --git a/packages/linux-firmware/0001-linux-firmware-snd-remove-firmware-for-snd-audio-dev.patch b/packages/linux-firmware/0001-linux-firmware-snd-remove-firmware-for-snd-audio-dev.patch new file mode 100644 index 00000000..f0f6abf7 --- /dev/null +++ b/packages/linux-firmware/0001-linux-firmware-snd-remove-firmware-for-snd-audio-dev.patch @@ -0,0 +1,1979 @@ +From c5e85907233a5ddc7df414744561f0fd848e907f Mon Sep 17 00:00:00 2001 +From: Leonard Foerster +Date: Tue, 25 Jul 2023 09:22:51 +0000 +Subject: [PATCH] linux-firmware: snd: remove firmware for snd/audio devices + +Bottlerocket does not configure drivers for audio devices for any of its +kernels. Hence, we do not need to ship firmware for these devices. The +following list maps the drivers as they are named in WHENCE to the +kernel config option for reference and easy searchability should we need +to find the right firmware to add when adding a driver to our kernel +configuation: + +* snd-korg1212 - CONFIG_SND_KORG1212 +* snd-maestro3 - CONFIG_SND_MAESTRO3 +* snd-ymfpci - CONFIG_SND_YMFPCI +* snd-sb16_csp - CONFIG_SND_SB16_CSP +* snd-wavefront - CONFIG_SND_WAVEFRONT +* mtk-sof - CONFIG_SND_SOC_SOF_MTK_TOPLEVEL +* snd-hda-codex-ca0132 - CONFIG_SND_HDA_INTEL && CONFIG_SND_HDA_CODEC_CA0132 +* snd_soc_sst_acpi - CONFIG_SND_SOC_INTEL_SST_ACPI +* snd_intel_sst_core - CONFIG_SND_SOC_INTEL_SST +* snd_soc_catpt - CONFIG_SND_SOC_INTEL_CATPT +* snd_soc_avs - CONFIG_SND_SOC_INTEL_AVS +* snd_soc_skl - CONFIG_SND_SOC_INTEL_SKL +* cs35l41_hda - CONFIG_SND_SOC_C35L41* && SND_HDA_SCODEC_CS35L41* + +Signed-off-by: Leonard Foerster +--- + LICENCE.IntcSST2 | 39 -- + LICENCE.adsp_sst | 999 -------------------------------------------- + LICENCE.ca0132 | 47 --- + LICENCE.fw_sst_0f28 | 40 -- + LICENSE.cirrus | 182 -------- + WHENCE | 545 ------------------------ + 6 files changed, 1852 deletions(-) + delete mode 100644 LICENCE.IntcSST2 + delete mode 100644 LICENCE.adsp_sst + delete mode 100644 LICENCE.ca0132 + delete mode 100644 LICENCE.fw_sst_0f28 + delete mode 100644 LICENSE.cirrus + +diff --git a/LICENCE.IntcSST2 b/LICENCE.IntcSST2 +deleted file mode 100644 +index d4f1609..0000000 +--- a/LICENCE.IntcSST2 ++++ /dev/null +@@ -1,39 +0,0 @@ +-Copyright (c) 2014, Intel Corporation. +-All rights reserved. +- +-Redistribution. Redistribution and use in binary form, without +-modification, are permitted provided that the following conditions are +-met: +- +-* Redistributions must reproduce the above copyright notice and the +- following disclaimer in the documentation and/or other materials +- provided with the distribution. +-* Neither the name of Intel Corporation nor the names of its suppliers +- may be used to endorse or promote products derived from this software +- without specific prior written permission. +-* No reverse engineering, decompilation, or disassembly of this software +- is permitted. +- +-Limited patent license. Intel Corporation grants a world-wide, +-royalty-free, non-exclusive license under patents it now or hereafter +-owns or controls to make, have made, use, import, offer to sell and +-sell ("Utilize") this software, but solely to the extent that any +-such patent is necessary to Utilize the software alone, or in +-combination with an operating system licensed under an approved Open +-Source license as listed by the Open Source Initiative at +-http://opensource.org/licenses. The patent license shall not apply to +-any other combinations which include this software. No hardware per +-se is licensed hereunder. +- +-DISCLAIMER. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND +-CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, +-BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND +-FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE +-COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, +-INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, +-BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS +-OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +-ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR +-TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE +-USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH +-DAMAGE. +diff --git a/LICENCE.adsp_sst b/LICENCE.adsp_sst +deleted file mode 100644 +index c66b1b2..0000000 +--- a/LICENCE.adsp_sst ++++ /dev/null +@@ -1,999 +0,0 @@ +-***** INTEL BINARY FIRMWARE RELEASE LICENCE ******************************** +- +-Copyright (c) 2014-15 Intel Corporation. +-All rights reserved. +- +-Redistribution. +- +-Redistribution and use in binary form, without modification, are permitted +-provided that the following conditions are met: +-* Redistributions must reproduce the above copyright notice and the +- following disclaimer in the documentation and/or other materials provided +- with the distribution. +-* Neither the name of Intel Corporation nor the names of its suppliers may +- be used to endorse or promote products derived from this software without +- specific prior written permission. +-* No reverse engineering, decompilation, or disassembly of this software is +- permitted. +- +- +-Limited patent license. +- +-Intel Corporation grants a world-wide, royalty-free, non-exclusive license +-under patents it now or hereafter owns or controls to make, have made, use, +-import, offer to sell and sell ("Utilize") this software, but solely to the +-extent that any such patent is necessary to Utilize the software alone. The +-patent license shall not apply to any combinations which include this software. +-No hardware per se is licensed hereunder. +- +- +-DISCLAIMER. +- +-THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +-AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +-IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +-ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE +-LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR +-CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF +-SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +-INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN +-CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) +-ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE +-POSSIBILITY OF SUCH DAMAGE. +- +- +-***** NEW LIBC LICENCE******************************** +- +-The newlib subdirectory is a collection of software from several sources. +- +-Each file may have its own copyright/license that is embedded in the source +-file. Unless otherwise noted in the body of the source file(s), the following copyright +-notices will apply to the contents of the newlib subdirectory: +- +-(1) Red Hat Incorporated +- +-Copyright (c) 1994-2009 Red Hat, Inc. All rights reserved. +- +-This copyrighted material is made available to anyone wishing to use, +-modify, copy, or redistribute it subject to the terms and conditions +-of the BSD License. This program is distributed in the hope that +-it will be useful, but WITHOUT ANY WARRANTY expressed or implied, +-including the implied warranties of MERCHANTABILITY or FITNESS FOR +-A PARTICULAR PURPOSE. A copy of this license is available at +-http://www.opensource.org/licenses. Any Red Hat trademarks that are +-incorporated in the source code or documentation are not subject to +-the BSD License and may only be used or replicated with the express +-permission of Red Hat, Inc. +- +-(2) University of California, Berkeley +- +-Copyright (c) 1981-2000 The Regents of the University of California. +-All rights reserved. +- +-Redistribution and use in source and binary forms, with or without modification, +-are permitted provided that the following conditions are met: +- +- * Redistributions of source code must retain the above copyright notice, +- this list of conditions and the following disclaimer. +- * Redistributions in binary form must reproduce the above copyright notice, +- this list of conditions and the following disclaimer in the documentation +- and/or other materials provided with the distribution. +- * Neither the name of the University nor the names of its contributors +- may be used to endorse or promote products derived from this software +- without specific prior written permission. +- +-THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +-AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED +-WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. +-IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, +-INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT +-NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR +-PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, +-WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) +-ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY +-OF SUCH DAMAGE. +- +-(3) David M. Gay (AT&T 1991, Lucent 1998) +- +-The author of this software is David M. Gay. +- +-Copyright (c) 1991 by AT&T. +- +-Permission to use, copy, modify, and distribute this software for any +-purpose without fee is hereby granted, provided that this entire notice +-is included in all copies of any software which is or includes a copy +-or modification of this software and in all copies of the supporting +-documentation for such software. +- +-THIS SOFTWARE IS BEING PROVIDED "AS IS", WITHOUT ANY EXPRESS OR IMPLIED +-WARRANTY. IN PARTICULAR, NEITHER THE AUTHOR NOR AT&T MAKES ANY +-REPRESENTATION OR WARRANTY OF ANY KIND CONCERNING THE MERCHANTABILITY +-OF THIS SOFTWARE OR ITS FITNESS FOR ANY PARTICULAR PURPOSE. +- +-------------------------------------------------------------------- +- +-The author of this software is David M. Gay. +- +-Copyright (C) 1998-2001 by Lucent Technologies +-All Rights Reserved +- +-Permission to use, copy, modify, and distribute this software and +-its documentation for any purpose and without fee is hereby +-granted, provided that the above copyright notice appear in all +-copies and that both that the copyright notice and this +-permission notice and warranty disclaimer appear in supporting +-documentation, and that the name of Lucent or any of its entities +-not be used in advertising or publicity pertaining to +-distribution of the software without specific, written prior +-permission. +- +-LUCENT DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, +-INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. +-IN NO EVENT SHALL LUCENT OR ANY OF ITS ENTITIES BE LIABLE FOR ANY +-SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +-WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER +-IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, +-ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF +-THIS SOFTWARE. +- +- +-(4) Advanced Micro Devices +- +-Copyright 1989, 1990 Advanced Micro Devices, Inc. +- +-This software is the property of Advanced Micro Devices, Inc (AMD) which +-specifically grants the user the right to modify, use and distribute this +-software provided this notice is not removed or altered. All other rights +-are reserved by AMD. +- +-AMD MAKES NO WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, WITH REGARD TO THIS +-SOFTWARE. IN NO EVENT SHALL AMD BE LIABLE FOR INCIDENTAL OR CONSEQUENTIAL +-DAMAGES IN CONNECTION WITH OR ARISING FROM THE FURNISHING, PERFORMANCE, OR +-USE OF THIS SOFTWARE. +- +-So that all may benefit from your experience, please report any problems +-or suggestions about this software to the 29K Technical Support Center at +-800-29-29-AMD (800-292-9263) in the USA, or 0800-89-1131 in the UK, or +-0031-11-1129 in Japan, toll free. The direct dial number is 512-462-4118. +- +-Advanced Micro Devices, Inc. +-29K Support Products +-Mail Stop 573 +-5900 E. Ben White Blvd. +-Austin, TX 78741 +-800-292-9263 +- +-(5) +- +-(6) +- +-(7) Sun Microsystems +- +-Copyright (C) 1993 by Sun Microsystems, Inc. All rights reserved. +- +-Developed at SunPro, a Sun Microsystems, Inc. business. +-Permission to use, copy, modify, and distribute this +-software is freely granted, provided that this notice is preserved. +- +-(8) Hewlett Packard +- +-(c) Copyright 1986 HEWLETT-PACKARD COMPANY +- +-To anyone who acknowledges that this file is provided "AS IS" +-without any express or implied warranty: +- permission to use, copy, modify, and distribute this file +-for any purpose is hereby granted without fee, provided that +-the above copyright notice and this notice appears in all +-copies, and that the name of Hewlett-Packard Company not be +-used in advertising or publicity pertaining to distribution +-of the software without specific, written prior permission. +-Hewlett-Packard Company makes no representations about the +-suitability of this software for any purpose. +- +-(9) Hans-Peter Nilsson +- +-Copyright (C) 2001 Hans-Peter Nilsson +- +-Permission to use, copy, modify, and distribute this software is +-freely granted, provided that the above copyright notice, this notice +-and the following disclaimer are preserved with no changes. +- +-THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR +-IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED +-WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR +-PURPOSE. +- +-(10) Stephane Carrez (m68hc11-elf/m68hc12-elf targets only) +- +-Copyright (C) 1999, 2000, 2001, 2002 Stephane Carrez (stcarrez@nerim.fr) +- +-The authors hereby grant permission to use, copy, modify, distribute, +-and license this software and its documentation for any purpose, provided +-that existing copyright notices are retained in all copies and that this +-notice is included verbatim in any distributions. No written agreement, +-license, or royalty fee is required for any of the authorized uses. +-Modifications to this software may be copyrighted by their authors +-and need not follow the licensing terms described here, provided that +-the new terms are clearly indicated on the first page of each file where +-they apply. +- +-(11) Christopher G. Demetriou +- +-Copyright (c) 2001 Christopher G. Demetriou +-All rights reserved. +- +-Redistribution and use in source and binary forms, with or without +-modification, are permitted provided that the following conditions +-are met: +-1. Redistributions of source code must retain the above copyright +- notice, this list of conditions and the following disclaimer. +-2. Redistributions in binary form must reproduce the above copyright +- notice, this list of conditions and the following disclaimer in the +- documentation and/or other materials provided with the distribution. +-3. The name of the author may not be used to endorse or promote products +- derived from this software without specific prior written permission. +- +-THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR +-IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES +-OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. +-IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, +-INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT +-NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +-DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY +-THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +-(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF +-THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +- +-(12) SuperH, Inc. +- +-Copyright 2002 SuperH, Inc. All rights reserved +- +-This software is the property of SuperH, Inc (SuperH) which specifically +-grants the user the right to modify, use and distribute this software +-provided this notice is not removed or altered. All other rights are +-reserved by SuperH. +- +-SUPERH MAKES NO WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, WITH REGARD TO +-THIS SOFTWARE. IN NO EVENT SHALL SUPERH BE LIABLE FOR INDIRECT, SPECIAL, +-INCIDENTAL OR CONSEQUENTIAL DAMAGES IN CONNECTION WITH OR ARISING FROM +-THE FURNISHING, PERFORMANCE, OR USE OF THIS SOFTWARE. +- +-So that all may benefit from your experience, please report any problems +-or suggestions about this software to the SuperH Support Center via +-e-mail at softwaresupport@superh.com . +- +-SuperH, Inc. +-405 River Oaks Parkway +-San Jose +-CA 95134 +-USA +- +-(13) Royal Institute of Technology +- +-Copyright (c) 1999 Kungliga Tekniska Högskolan +-(Royal Institute of Technology, Stockholm, Sweden). +-All rights reserved. +- +-Redistribution and use in source and binary forms, with or without +-modification, are permitted provided that the following conditions +-are met: +- +-1. Redistributions of source code must retain the above copyright +- notice, this list of conditions and the following disclaimer. +- +-2. Redistributions in binary form must reproduce the above copyright +- notice, this list of conditions and the following disclaimer in the +- documentation and/or other materials provided with the distribution. +- +-3. Neither the name of KTH nor the names of its contributors may be +- used to endorse or promote products derived from this software without +- specific prior written permission. +- +-THIS SOFTWARE IS PROVIDED BY KTH AND ITS CONTRIBUTORS ``AS IS'' AND ANY +-EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +-IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR +-PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL KTH OR ITS CONTRIBUTORS BE +-LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR +-CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF +-SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR +-BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, +-WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR +-OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF +-ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +- +-(14) Alexey Zelkin +- +-Copyright (c) 2000, 2001 Alexey Zelkin +-All rights reserved. +- +-Redistribution and use in source and binary forms, with or without +-modification, are permitted provided that the following conditions +-are met: +-1. Redistributions of source code must retain the above copyright +- notice, this list of conditions and the following disclaimer. +-2. Redistributions in binary form must reproduce the above copyright +- notice, this list of conditions and the following disclaimer in the +- documentation and/or other materials provided with the distribution. +- +-THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND +-ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +-IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +-ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE +-FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +-DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS +-OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) +-HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +-LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +-OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +-SUCH DAMAGE. +- +-(15) Andrey A. Chernov +- +-Copyright (C) 1997 by Andrey A. Chernov, Moscow, Russia. +-All rights reserved. +- +-Redistribution and use in source and binary forms, with or without +-modification, are permitted provided that the following conditions +-are met: +-1. Redistributions of source code must retain the above copyright +- notice, this list of conditions and the following disclaimer. +-2. Redistributions in binary form must reproduce the above copyright +- notice, this list of conditions and the following disclaimer in the +- documentation and/or other materials provided with the distribution. +- +-THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND +-ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +-IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +-ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE +-FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +-DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS +-OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) +-HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +-LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +-OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +-SUCH DAMAGE. +- +-(16) FreeBSD +- +-Copyright (c) 1997-2002 FreeBSD Project. +-All rights reserved. +- +-Redistribution and use in source and binary forms, with or without +-modification, are permitted provided that the following conditions +-are met: +-1. Redistributions of source code must retain the above copyright +- notice, this list of conditions and the following disclaimer. +-2. Redistributions in binary form must reproduce the above copyright +- notice, this list of conditions and the following disclaimer in the +- documentation and/or other materials provided with the distribution. +- +-THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND +-ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +-IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +-ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE +-FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +-DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS +-OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) +-HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +-LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +-OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +-SUCH DAMAGE. +- +-(17) S. L. Moshier +- +-Author: S. L. Moshier. +- +-Copyright (c) 1984,2000 S.L. Moshier +- +-Permission to use, copy, modify, and distribute this software for any +-purpose without fee is hereby granted, provided that this entire notice +-is included in all copies of any software which is or includes a copy +-or modification of this software and in all copies of the supporting +-documentation for such software. +- +-THIS SOFTWARE IS BEING PROVIDED "AS IS", WITHOUT ANY EXPRESS OR IMPLIED +-WARRANTY. IN PARTICULAR, THE AUTHOR MAKES NO REPRESENTATION +-OR WARRANTY OF ANY KIND CONCERNING THE MERCHANTABILITY OF THIS +-SOFTWARE OR ITS FITNESS FOR ANY PARTICULAR PURPOSE. +- +-(18) Citrus Project +- +-Copyright (c)1999 Citrus Project, +-All rights reserved. +- +-Redistribution and use in source and binary forms, with or without +-modification, are permitted provided that the following conditions +-are met: +-1. Redistributions of source code must retain the above copyright +- notice, this list of conditions and the following disclaimer. +-2. Redistributions in binary form must reproduce the above copyright +- notice, this list of conditions and the following disclaimer in the +- documentation and/or other materials provided with the distribution. +- +-THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND +-ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +-IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +-ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE +-FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +-DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS +-OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) +-HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +-LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +-OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +-SUCH DAMAGE. +- +-(19) Todd C. Miller +- +-Copyright (c) 1998 Todd C. Miller +-All rights reserved. +- +-Redistribution and use in source and binary forms, with or without +-modification, are permitted provided that the following conditions +-are met: +-1. Redistributions of source code must retain the above copyright +- notice, this list of conditions and the following disclaimer. +-2. Redistributions in binary form must reproduce the above copyright +- notice, this list of conditions and the following disclaimer in the +- documentation and/or other materials provided with the distribution. +-3. The name of the author may not be used to endorse or promote products +- derived from this software without specific prior written permission. +- +-THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, +-INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY +-AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL +-THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, +-EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, +-PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; +-OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, +-WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR +-OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF +-ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +- +-(20) DJ Delorie (i386) +-Copyright (C) 1991 DJ Delorie +-All rights reserved. +- +-Redistribution, modification, and use in source and binary forms is permitted +-provided that the above copyright notice and following paragraph are +-duplicated in all such forms. +- +-This file is distributed WITHOUT ANY WARRANTY; without even the implied +-warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. +- +-(21) Free Software Foundation LGPL License (*-linux* targets only) +- +- Copyright (C) 1990-1999, 2000, 2001 Free Software Foundation, Inc. +- This file is part of the GNU C Library. +- Contributed by Mark Kettenis , 1997. +- +- The GNU C Library is free software; you can redistribute it and/or +- modify it under the terms of the GNU Lesser General Public +- License as published by the Free Software Foundation; either +- version 2.1 of the License, or (at your option) any later version. +- +- The GNU C Library is distributed in the hope that it will be useful, +- but WITHOUT ANY WARRANTY; without even the implied warranty of +- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +- Lesser General Public License for more details. +- +- You should have received a copy of the GNU Lesser General Public +- License along with the GNU C Library; if not, write to the Free +- Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA +- 02110-1301 USA. +- +-(22) Xavier Leroy LGPL License (i[3456]86-*-linux* targets only) +- +-Copyright (C) 1996 Xavier Leroy (Xavier.Leroy@inria.fr) +- +-This program is free software; you can redistribute it and/or +-modify it under the terms of the GNU Library General Public License +-as published by the Free Software Foundation; either version 2 +-of the License, or (at your option) any later version. +- +-This program is distributed in the hope that it will be useful, +-but WITHOUT ANY WARRANTY; without even the implied warranty of +-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +-GNU Library General Public License for more details. +- +-(23) Intel (i960) +- +-Copyright (c) 1993 Intel Corporation +- +-Intel hereby grants you permission to copy, modify, and distribute this +-software and its documentation. Intel grants this permission provided +-that the above copyright notice appears in all copies and that both the +-copyright notice and this permission notice appear in supporting +-documentation. In addition, Intel grants this permission provided that +-you prominently mark as "not part of the original" any modifications +-made to this software or documentation, and that the name of Intel +-Corporation not be used in advertising or publicity pertaining to +-distribution of the software or the documentation without specific, +-written prior permission. +- +-Intel Corporation provides this AS IS, WITHOUT ANY WARRANTY, EXPRESS OR +-IMPLIED, INCLUDING, WITHOUT LIMITATION, ANY WARRANTY OF MERCHANTABILITY +-OR FITNESS FOR A PARTICULAR PURPOSE. Intel makes no guarantee or +-representations regarding the use of, or the results of the use of, +-the software and documentation in terms of correctness, accuracy, +-reliability, currentness, or otherwise; and you rely on the software, +-documentation and results solely at your own risk. +- +-IN NO EVENT SHALL INTEL BE LIABLE FOR ANY LOSS OF USE, LOSS OF BUSINESS, +-LOSS OF PROFITS, INDIRECT, INCIDENTAL, SPECIAL OR CONSEQUENTIAL DAMAGES +-OF ANY KIND. IN NO EVENT SHALL INTEL'S TOTAL LIABILITY EXCEED THE SUM +-PAID TO INTEL FOR THE PRODUCT LICENSED HEREUNDER. +- +-(24) Hewlett-Packard (hppa targets only) +- +-(c) Copyright 1986 HEWLETT-PACKARD COMPANY +- +-To anyone who acknowledges that this file is provided "AS IS" +-without any express or implied warranty: +- permission to use, copy, modify, and distribute this file +-for any purpose is hereby granted without fee, provided that +-the above copyright notice and this notice appears in all +-copies, and that the name of Hewlett-Packard Company not be +-used in advertising or publicity pertaining to distribution +-of the software without specific, written prior permission. +-Hewlett-Packard Company makes no representations about the +-suitability of this software for any purpose. +- +-(25) Henry Spencer (only *-linux targets) +- +-Copyright 1992, 1993, 1994 Henry Spencer. All rights reserved. +-This software is not subject to any license of the American Telephone +-and Telegraph Company or of the Regents of the University of California. +- +-Permission is granted to anyone to use this software for any purpose on +-any computer system, and to alter it and redistribute it, subject +-to the following restrictions: +- +-1. The author is not responsible for the consequences of use of this +- software, no matter how awful, even if they arise from flaws in it. +- +-2. The origin of this software must not be misrepresented, either by +- explicit claim or by omission. Since few users ever read sources, +- credits must appear in the documentation. +- +-3. Altered versions must be plainly marked as such, and must not be +- misrepresented as being the original software. Since few users +- ever read sources, credits must appear in the documentation. +- +-4. This notice may not be removed or altered. +- +-(26) Mike Barcroft +- +-Copyright (c) 2001 Mike Barcroft +-All rights reserved. +- +-Redistribution and use in source and binary forms, with or without +-modification, are permitted provided that the following conditions +-are met: +-1. Redistributions of source code must retain the above copyright +- notice, this list of conditions and the following disclaimer. +-2. Redistributions in binary form must reproduce the above copyright +- notice, this list of conditions and the following disclaimer in the +- documentation and/or other materials provided with the distribution. +- +-THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND +-ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +-IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +-ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE +-FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +-DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS +-OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) +-HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +-LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +-OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +-SUCH DAMAGE. +- +-(27) Konstantin Chuguev (--enable-newlib-iconv) +- +-Copyright (c) 1999, 2000 +- Konstantin Chuguev. All rights reserved. +- +-Redistribution and use in source and binary forms, with or without +-modification, are permitted provided that the following conditions +-are met: +-1. Redistributions of source code must retain the above copyright +- notice, this list of conditions and the following disclaimer. +-2. Redistributions in binary form must reproduce the above copyright +- notice, this list of conditions and the following disclaimer in the +- documentation and/or other materials provided with the distribution. +- +-THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND +-ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +-IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +-ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE +-FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +-DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS +-OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) +-HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +-LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +-OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +-SUCH DAMAGE. +- +- iconv (Charset Conversion Library) v2.0 +- +-(28) Artem Bityuckiy (--enable-newlib-iconv) +- +-Copyright (c) 2003, Artem B. Bityuckiy, SoftMine Corporation. +-Rights transferred to Franklin Electronic Publishers. +- +-Redistribution and use in source and binary forms, with or without +-modification, are permitted provided that the following conditions +-are met: +-1. Redistributions of source code must retain the above copyright +- notice, this list of conditions and the following disclaimer. +-2. Redistributions in binary form must reproduce the above copyright +- notice, this list of conditions and the following disclaimer in the +- documentation and/or other materials provided with the distribution. +- +-THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND +-ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +-IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +-ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE +-FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +-DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS +-OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) +-HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +-LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +-OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +-SUCH DAMAGE. +- +-(29) IBM, Sony, Toshiba (only spu-* targets) +- +- (C) Copyright 2001,2006, +- International Business Machines Corporation, +- Sony Computer Entertainment, Incorporated, +- Toshiba Corporation, +- +- All rights reserved. +- +- Redistribution and use in source and binary forms, with or without +- modification, are permitted provided that the following conditions are met: +- +- * Redistributions of source code must retain the above copyright notice, +- this list of conditions and the following disclaimer. +- * Redistributions in binary form must reproduce the above copyright +- notice, this list of conditions and the following disclaimer in the +- documentation and/or other materials provided with the distribution. +- * Neither the names of the copyright holders nor the names of their +- contributors may be used to endorse or promote products derived from this +- software without specific prior written permission. +- +- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +- AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +- IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +- ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE +- LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR +- CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF +- SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +- INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN +- CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) +- ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE +- POSSIBILITY OF SUCH DAMAGE. +- +-(30) - Alex Tatmanjants (targets using libc/posix) +- +- Copyright (c) 1995 Alex Tatmanjants +- at Electronni Visti IA, Kiev, Ukraine. +- All rights reserved. +- +- Redistribution and use in source and binary forms, with or without +- modification, are permitted provided that the following conditions +- are met: +- 1. Redistributions of source code must retain the above copyright +- notice, this list of conditions and the following disclaimer. +- 2. Redistributions in binary form must reproduce the above copyright +- notice, this list of conditions and the following disclaimer in the +- documentation and/or other materials provided with the distribution. +- +- THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND +- ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +- IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +- ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR BE LIABLE +- FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +- DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS +- OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) +- HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +- LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +- OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +- SUCH DAMAGE. +- +-(31) - M. Warner Losh (targets using libc/posix) +- +- Copyright (c) 1998, M. Warner Losh +- All rights reserved. +- +- Redistribution and use in source and binary forms, with or without +- modification, are permitted provided that the following conditions +- are met: +- 1. Redistributions of source code must retain the above copyright +- notice, this list of conditions and the following disclaimer. +- 2. Redistributions in binary form must reproduce the above copyright +- notice, this list of conditions and the following disclaimer in the +- documentation and/or other materials provided with the distribution. +- +- THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND +- ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +- IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +- ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE +- FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +- DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS +- OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) +- HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +- LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +- OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +- SUCH DAMAGE. +- +-(32) - Andrey A. Chernov (targets using libc/posix) +- +- Copyright (C) 1996 by Andrey A. Chernov, Moscow, Russia. +- All rights reserved. +- +- Redistribution and use in source and binary forms, with or without +- modification, are permitted provided that the following conditions +- are met: +- 1. Redistributions of source code must retain the above copyright +- notice, this list of conditions and the following disclaimer. +- 2. Redistributions in binary form must reproduce the above copyright +- notice, this list of conditions and the following disclaimer in the +- documentation and/or other materials provided with the distribution. +- +- THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND +- ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +- IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +- ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE +- FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +- DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS +- OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) +- HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +- LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +- OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +- SUCH DAMAGE. +- +-(33) - Daniel Eischen (targets using libc/posix) +- +- Copyright (c) 2001 Daniel Eischen . +- All rights reserved. +- +- Redistribution and use in source and binary forms, with or without +- modification, are permitted provided that the following conditions +- are met: +- 1. Redistributions of source code must retain the above copyright +- notice, this list of conditions and the following disclaimer. +- 2. Redistributions in binary form must reproduce the above copyright +- notice, this list of conditions and the following disclaimer in the +- documentation and/or other materials provided with the distribution. +- +- THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND +- ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +- IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +- ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE +- FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +- DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS +- OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) +- HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +- LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +- OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +- SUCH DAMAGE. +- +- +-(34) - Jon Beniston (only lm32-* targets) +- +- Contributed by Jon Beniston +- +- Redistribution and use in source and binary forms, with or without +- modification, are permitted provided that the following conditions +- are met: +- 1. Redistributions of source code must retain the above copyright +- notice, this list of conditions and the following disclaimer. +- 2. Redistributions in binary form must reproduce the above copyright +- notice, this list of conditions and the following disclaimer in the +- documentation and/or other materials provided with the distribution. +- +- THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND +- ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +- IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +- ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE +- FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +- DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS +- OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) +- HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +- LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +- OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +- SUCH DAMAGE. +- +- +-(35) - ARM Ltd (arm and thumb variant targets only) +- +- Copyright (c) 2009 ARM Ltd +- All rights reserved. +- +- Redistribution and use in source and binary forms, with or without +- modification, are permitted provided that the following conditions +- are met: +- 1. Redistributions of source code must retain the above copyright +- notice, this list of conditions and the following disclaimer. +- 2. Redistributions in binary form must reproduce the above copyright +- notice, this list of conditions and the following disclaimer in the +- documentation and/or other materials provided with the distribution. +- 3. The name of the company may not be used to endorse or promote +- products derived from this software without specific prior written +- permission. +- +- THIS SOFTWARE IS PROVIDED BY ARM LTD ``AS IS'' AND ANY EXPRESS OR IMPLIED +- WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +- MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. +- IN NO EVENT SHALL ARM LTD BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +- SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED +- TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR +- PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF +- LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING +- NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS +- SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +- +-(36) - Xilinx, Inc. (microblaze-* and powerpc-* targets) +- +-Copyright (c) 2004, 2009 Xilinx, Inc. All rights reserved. +- +-Redistribution and use in source and binary forms, with or without +-modification, are permitted provided that the following conditions are +-met: +- +-1. Redistributions source code must retain the above copyright notice, +-this list of conditions and the following disclaimer. +- +-2. Redistributions in binary form must reproduce the above copyright +-notice, this list of conditions and the following disclaimer in the +-documentation and/or other materials provided with the distribution. +- +-3. Neither the name of Xilinx nor the names of its contributors may be +-used to endorse or promote products derived from this software without +-specific prior written permission. +- +-THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDER AND CONTRIBUTORS "AS +-IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED +-TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A +-PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT +-HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +-SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED +-TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR +-PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF +-LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING +-NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS +-SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +- +- +-(37) Texas Instruments Incorporated (tic6x-*, *-tirtos targets) +- +-Copyright (c) 1996-2010,2014 Texas Instruments Incorporated +-http://www.ti.com/ +- +- Redistribution and use in source and binary forms, with or without +- modification, are permitted provided that the following conditions +- are met: +- +- Redistributions of source code must retain the above copyright +- notice, this list of conditions and the following disclaimer. +- +- Redistributions in binary form must reproduce the above copyright +- notice, this list of conditions and the following disclaimer in +- the documentation and/or other materials provided with the +- distribution. +- +- Neither the name of Texas Instruments Incorporated nor the names +- of its contributors may be used to endorse or promote products +- derived from this software without specific prior written +- permission. +- +- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +- "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +- LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR +- A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT +- OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +- SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +- LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +- DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY +- THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +- (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +- OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +- +-(38) National Semiconductor (cr16-* and crx-* targets) +- +-Copyright (c) 2004 National Semiconductor Corporation +- +-The authors hereby grant permission to use, copy, modify, distribute, +-and license this software and its documentation for any purpose, provided +-that existing copyright notices are retained in all copies and that this +-notice is included verbatim in any distributions. No written agreement, +-license, or royalty fee is required for any of the authorized uses. +-Modifications to this software may be copyrighted by their authors +-and need not follow the licensing terms described here, provided that +-the new terms are clearly indicated on the first page of each file where +-they apply. +- +-(39) - Adapteva, Inc. (epiphany-* targets) +- +-Copyright (c) 2011, Adapteva, Inc. +-All rights reserved. +- +-Redistribution and use in source and binary forms, with or without +-modification, are permitted provided that the following conditions are met: +- * Redistributions of source code must retain the above copyright notice, this +- list of conditions and the following disclaimer. +- * Redistributions in binary form must reproduce the above copyright notice, +- this list of conditions and the following disclaimer in the documentation +- and/or other materials provided with the distribution. +- * Neither the name of Adapteva nor the names of its contributors may be used +- to endorse or promote products derived from this software without specific +- prior written permission. +- +-THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND +-ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED +-WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +-DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE +-FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +-DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +-SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +-CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +-OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +-OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +- +-(40) - Altera Corportion (nios2-* targets) +- +-Copyright (c) 2003 Altera Corporation +-All rights reserved. +- +-Redistribution and use in source and binary forms, with or without +-modification, are permitted provided that the following conditions +-are met: +- +- o Redistributions of source code must retain the above copyright +- notice, this list of conditions and the following disclaimer. +- o Redistributions in binary form must reproduce the above copyright +- notice, this list of conditions and the following disclaimer in the +- documentation and/or other materials provided with the distribution. +- o Neither the name of Altera Corporation nor the names of its +- contributors may be used to endorse or promote products derived from +- this software without specific prior written permission. +- +-THIS SOFTWARE IS PROVIDED BY ALTERA CORPORATION, THE COPYRIGHT HOLDER, +-AND ITS CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, +-INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY +-AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL +-THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, +-INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, +-BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS +-OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +-ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR +-TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE +-USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +- +-(41) Ed Schouten - Free BSD +- +-Copyright (c) 2008 Ed Schouten +-All rights reserved. +- +-Redistribution and use in source and binary forms, with or without +-modification, are permitted provided that the following conditions +-are met: +-1. Redistributions of source code must retain the above copyright +- notice, this list of conditions and the following disclaimer. +-2. Redistributions in binary form must reproduce the above copyright +- notice, this list of conditions and the following disclaimer in the +- documentation and/or other materials provided with the distribution. +- +-THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND +-ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +-IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +-ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE +-FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +-DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS +-OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) +-HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +-LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +-OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +-SUCH DAMAGE. +- +diff --git a/LICENCE.ca0132 b/LICENCE.ca0132 +deleted file mode 100644 +index 411750a..0000000 +--- a/LICENCE.ca0132 ++++ /dev/null +@@ -1,47 +0,0 @@ +-Copyright (c) 2012, Creative Technology Ltd +-All rights reserved. +- +-Redistribution. Redistribution and use in binary form, without +-modification, are permitted provided that the following conditions are +-met: +- +-* Redistributions must reproduce the above copyright notice and the +- following disclaimer in the documentation and/or other materials +- provided with the distribution. +-* Neither the name of Creative Technology Ltd or its affiliates ("CTL") +- nor the names of its suppliers may be used to endorse or promote +- products derived from this software without specific prior written +- permission. +-* No reverse engineering, decompilation, or disassembly of this software +- (or any part thereof) is permitted. +- +-Limited patent license. CTL grants a limited, world-wide, +-royalty-free, non-exclusive license under patents it now or hereafter +-owns or controls to make, have made, use, import, offer to sell and +-sell ("Utilize") this software, but strictly only to the extent that any +-such patent is necessary to Utilize the software alone, or in +-combination with an operating system licensed under an approved Open +-Source license as listed by the Open Source Initiative at +-http://opensource.org/licenses. The patent license shall not be +-applicable, to any other combinations which include this software. +-No hardware per se is licensed hereunder. +- +-DISCLAIMER. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND +-CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, +-BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND +-FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE +-COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, +-INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, +-BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS +-OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +-ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR +-TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE +-USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH +-DAMAGE. +- +-NO OTHER RIGHTS GRANTED. USER HEREBY ACKNOWLEDGES AND AGREES THAT USE OF +-THIS SOFTWARE SHALL NOT CREATE OR GIVE GROUNDS FOR A LICENSE BY +-IMPLICATION, ESTOPPEL, OR OTHERWISE TO ANY INTELLECTUAL PROPERTY RIGHTS +-(PATENT, COPYRIGHT, TRADE SECRET, MASK WORK, OR OTHER PROPRIETARY RIGHT) +-EMBODIED IN ANY OTHER CTL HARDWARE OR SOFTWARE WHETHER SOLELY OR IN +-COMBINATION WITH THIS SOFTWARE. +diff --git a/LICENCE.fw_sst_0f28 b/LICENCE.fw_sst_0f28 +deleted file mode 100644 +index 247e35f..0000000 +--- a/LICENCE.fw_sst_0f28 ++++ /dev/null +@@ -1,40 +0,0 @@ +-Copyright (c) 2014 Intel Corporation. +-All rights reserved. +- +-Redistribution. +- +-Redistribution and use in binary form, without modification, are permitted +-provided that the following conditions are met: +-* Redistributions must reproduce the above copyright notice and the +- following disclaimer in the documentation and/or other materials provided +- with the distribution. +-* Neither the name of Intel Corporation nor the names of its suppliers may +- be used to endorse or promote products derived from this software without +- specific prior written permission. +-* No reverse engineering, decompilation, or disassembly of this software is +- permitted. +- +- +-Limited patent license. +- +-Intel Corporation grants a world-wide, royalty-free, non-exclusive license +-under patents it now or hereafter owns or controls to make, have made, use, +-import, offer to sell and sell ("Utilize") this software, but solely to the +-extent that any such patent is necessary to Utilize the software alone. The +-patent license shall not apply to any combinations which include this software. +-No hardware per se is licensed hereunder. +- +- +-DISCLAIMER. +- +-THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +-AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +-IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +-ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE +-LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR +-CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF +-SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +-INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN +-CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) +-ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE +-POSSIBILITY OF SUCH DAMAGE. +diff --git a/LICENSE.cirrus b/LICENSE.cirrus +deleted file mode 100644 +index c9d7c22..0000000 +--- a/LICENSE.cirrus ++++ /dev/null +@@ -1,182 +0,0 @@ +-Use, distribution, or reproduction of this CIRRUS LOGIC software is governed by +-the terms of this Agreement. Any use, distribution or reproduction of this +-CIRRUS LOGIC software constitutes your acceptance of the following terms and +-conditions. +- +-1. DEFINED TERMS +- +-“CIRRUS LOGIC” means either Cirrus Logic, Inc., a Delaware Corporation (for +-licensees based in the United States), or Cirrus Logic International (UK) Ltd, a +-company registered in Scotland (for licensees based outside the United States). +- +-“Licensee” means the party which has accepted these terms, including by +-distributing, reproducing and/or using the Software. +-“Software” means software provided to Licensee in binary code form, that runs or +-is intended to run on a processor embedded in an end product (and related files +-and documentation) (“Software”). +- +-2. GRANT OF LICENSE +- +-a. Subject to the terms, conditions, and limitations of this Agreement, CIRRUS +-LOGIC grants to Licensee a non-exclusive , non-transferable license (the +-“License”) to (i) use and integrate the Software with other software, and (ii) +-reproduce and distribute the Software in its complete and unmodified form, +-provided all use of the Software is in connection with CIRRUS LOGIC +-semiconductor devices. These license rights do not automatically extend to any +-third-party software within the Software for which a separate license is +-required to enable use by the Licensee. Licensee must agree applicable license +-terms with the relevant third-party licensors to use such software. +-b. Licensee (i) shall not remove or obscure any copyright and/or trademark +-notices from the Software, and (ii) shall maintain and reproduce all copyright +-and other proprietary notices on any copy in the same form and manner that such +-notices are included on the Software (except if the Software is embedded such +-that it is not readily accessible to an end user). +-c. Licensee may not make any modifications to the Software and may only +-distribute the Software under the terms of this Agreement. Recipients of the +-Software must be provided with a copy of this Agreement. +- +-3. TERMINATION +- +-a. This Agreement will automatically terminate if Licensee does not comply with +-its terms. +-b. In the event of termination: +-i. Licensee must destroy all copies of the Software (and parts thereof), and all +-Proprietary Information (as defined below), including any original, backup, or +-archival copy that Licensee may have installed, downloaded, or recorded on any +-medium. Upon written request from CIRRUS LOGIC, Licensee will certify in +-writing that it has complied with this provision and has not retained any copies +-of the Software or any Proprietary Information; +-ii. the rights and licenses granted to Licensee under this Agreement will +-immediately terminate; +-iii. all rights and obligations under this Agreement which by their nature +-should survive termination, will remain in full force and effect. +- +-4. OWNERSHIP, RIGHTS, USE LIMITATIONS, AND DUTIES +- +-a. CIRRUS LOGIC and/or its licensors own all proprietary rights in the Software. +- Whilst this Agreement is in effect, Licensee hereby covenants that it will not +-assert any claim that the Software infringes any intellectual property rights +-owned or controlled by Licensee. +-b. Other than as expressly set forth in this Agreement, CIRRUS LOGIC does not +-grant, and Licensee does not receive, any ownership right, title or interest in +-any intellectual property rights relating to the Software, nor in any copy of +-any part of the foregoing. No license is granted to Licensee in any human +-readable code of the Software (source code). +-c. Licensee shall not (i) use, license, sell or otherwise distribute the +-Software except as provided in this Agreement, (ii) attempt to modify in any +-way, reverse engineer, decompile or disassemble any portion of the Software; or +-(iii) use the Software or other material in violation of any applicable law or +-regulation. +-d. The Software is not intended or authorized for use in or with products for +-which CIRRUS LOGIC semiconductor devices are not designed, tested or intended, +-as detailed in the CIRRUS LOGIC Terms and Conditions of Sale, available at +-www.cirrus.com/legal (as the same may be updated from time to time), which shall +-apply to Licensee’s use of Software, insofar as relevant thereto. +-e. CIRRUS LOGIC may require Licensee to cease using a version of the Software, +-and may require use of an updated version, where (a) a third-party has claimed +-that the Software infringes its intellectual property rights, and/or (b) for +-technical reasons CIRRUS LOGIC is no longer able to permit ongoing use of the +-version of the Software being used by Licensee. +-f. If Licensee requests support, CIRRUS LOGIC has no obligation to provide any +-such support but if it agrees to do so any such support will be on a reasonable +-efforts basis. +-g. Licensee shall keep complete and accurate records of its use of the Software +-and shall, on request, promptly provide to CIRRUS LOGIC a certificate evidencing +-the extent of such use. +- +-5. CONFIDENTIALITY +- +-a. Licensee may obtain or be provided with information relating to the Software, +-including in documentation provided to it (“Proprietary Information”). Such +-Proprietary Information shall belong solely to CIRRUS LOGIC and/or its +-affiliates (or, as the case may be, relevant third parties). +-b. During and after the term of this Agreement, Licensee agrees to maintain all +-such Proprietary Information in strict confidence and to not use (except as +-expressly authorized in this Agreement), disclose, or provide any third-party +-with access to any Proprietary Information except under a written agreement with +-terms at least as protective as the terms of this Agreement. Licensee also +-agrees to exercise the same degree of care and diligence as it uses in respect +-of its own confidential and proprietary information when dealing with CIRRUS +-LOGIC Proprietary Information, and in any event no less than reasonable care and +-diligence. +-c. Information will not be considered Proprietary Information if (i) it becomes +-public knowledge other than through any act or omission constituting a breach of +-the Licensee’s obligations under this Agreement; (ii) the Licensee can prove it +-was already in the Licensee’s possession and at its free disposal before the +-disclosure hereunder; and (iii) it was received in good faith from a third party +-having no obligation of confidentiality and which is free to disclose such +-Confidential Information +- +-6. NO WARRANTIES OR LIABILITIES +- +-LICENSEE EXPRESSLY ACKNOWLEDGES AND AGREES THAT THE SOFTWARE IS PROVIDED BY +-CIRRUS LOGIC “AS IS” WITHOUT ANY WARRANTIES WHATSOEVER AND THAT THE +-INSTALLATION, OPERATION AND USE OF THE SOFTWARE IS AT LICENSEE’S OWN RISK. +-CIRRUS LOGIC MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AND EXPRESSLY +-DISCLAIMS ANY IMPLIED WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR +-PURPOSE, GOOD TITLE, NON-INFRINGEMENT, SATISFACTORY QUALITY OR PERFORMANCE OR +-WHICH MAY ARISE FROM A COURSE OF DEALING, USAGE OR TRADE PRACTICE. CIRRUS LOGIC +-PROVIDES NO WARRANTY THAT THE SOFTWARE IS FREE FROM DEFECTS OR CHARACTERISTICS +-THAT COULD CAUSE VULNERABILITY TO CYBER-ATTACK, DATA BREACH OR PRIVACY +-VIOLATIONS. CIRRUS LOGIC SHALL IN NO EVENT BE LIABLE TO LICENSEE OR ANYONE ELSE +-FOR ANY LOSS, INJURY OR DAMAGE CAUSED IN WHOLE OR PART BY THE INSTALLATION, +-OPERATION OR USE OF THE SOFTWARE, LICENSEE’S INCORRECT USE OF THE SOFTWARE +-INCLUDING ANY FAILURE TO PROPERLY INSTALL ANY UPDATES TO THE SOFTWARE OR OTHER +-SOFTWARE WITH WHICH THE SOFTWARE OPERATES OR WHICH IT UPDATES, OR IS INTENDED TO +-OPERATE WITH OR UPDATE, OR THE RESULTS PRODUCED BY, OR FAILURES, DELAYS, OR +-INTERRUPTIONS OF THE SOFTWARE. WITHOUT LIMITING THE FOREGOING GENERALITY, +-CIRRUS LOGIC SHALL IN NO EVENT BE LIABLE WITH RESPECT TO ANY INTELLECTUAL +-PROPERTY INFRINGEMENT CLAIMS WHICH ARISE FROM, OR IN ANY WAY RELATE TO, USE OF +-THE SOFTWARE, INCLUDING, WITHOUT LIMITATION, ANY CLAIMS RELATING TO HAPTICS ON A +-COMPONENT OR SYSTEM LEVEL. CIRRUS LOGIC AND ITS LICENSORS SHALL IN NO EVENT BE +-LIABLE TO LICENSEE OR ANYONE ELSE FOR ANY DIRECT, CONSEQUENTIAL, INCIDENTAL OR +-SPECIAL DAMAGES, INCLUDING BUT NOT LIMITED TO ANY LOST PROFITS ARISING OUT OF OR +-RELATING TO THE INSTALLATION, OPERATION OR USE OF THE SOFTWARE. BECAUSE SOME +-JURISDICTIONS DO NOT ALLOW THE EXCLUSION OR LIMITATION OF CERTAIN WARRANTIES OR +-TYPES OF CLAIM OR LOSS THEN IN SUCH INSTANCES THE ABOVE EXCLUSIONS SHALL BE +-INTERPRETED TO APPLY TO THE EXTENT PERMITTED BY LOCAL LAW. SUBJECT TO THE +-FOREGOING, THE TOTAL LIABILITY OF CIRRUS LOGIC AND ITS LICENSORS TO LICENSEE +-UNDER THIS AGREEMENT, AND/OR ARISING FROM, OR IN CONNECTION WITH, THE USE OF (OR +-INABILITY TO USE) THE SOFTWARE, WHETHER ARISING IN CONTRACT, TORT (INCLUDING +-NEGLIGENCE), QUASI TORT, OR OTHERWISE SHALL NOT EXCEED THE LICENSE FEES (IF ANY) +-PAID BY LICENSEE FOR THE SOFTWARE THAT GAVE RISE TO THE CLAIM, OR TEN THOUSAND +-U.S. DOLLARS (U.S. $10,000), WHICHEVER IS GREATER. +- +-7. EXPORT AND END USE RESTRICTIONS +- +-Licensee acknowledges that the Software is subject to United States and other +-applicable export related laws and regulations (“Export Laws”). Licensee +-agrees that it may not export, re-export or transfer the Software or any direct +-product of the Software other than in accordance with those Export Laws. +-Licensee further agrees to be bound by, and to act in accordance with, +-provisions of the CIRRUS LOGIC Terms and Conditions of Sale available at +-www.cirrus.com/legal (as updated from time to time), including insofar as they +-relate to export/end use restrictions. +- +-8. GENERAL PROVISIONS +- +-This Agreement is not assignable or sub-licensable by Licensee without the prior +-written consent of CIRRUS LOGIC. CIRRUS LOGIC may sub-license or assign any or +-all of its rights and obligations under this Agreement without Licensee’s +-consent. The waiver by either party of a breach of this Agreement shall not +-constitute a waiver of any subsequent breach of this Agreement; nor shall any +-delay to exercise any right under this Agreement operate as a waiver of such +-right. This Agreement shall be deemed to have been made in, and shall be +-construed pursuant to the laws of, the State of Texas without regard to +-conflicts of laws provisions thereof. Both parties hereby consent to the +-exclusive jurisdiction of the State of Texas and the locale of Austin therein. +-The prevailing party in any action to enforce this Agreement shall be entitled +-to recover costs and expenses including, without limitation, attorneys' fees. +-The parties agree that CIRRUS LOGIC and its licensors shall be entitled to +-equitable relief in addition to any remedies it may have hereunder or at law. +- +-9. ENTIRE AGREEMENT +- +-This Agreement and any terms referenced or incorporated herein, constitutes the +-entire agreement between Licensee and CIRRUS LOGIC with respect to the Software +-provided pursuant to this Agreement and supersedes any other agreement between +-Licensee and CIRRUS LOGIC with respect thereto (including terms presented and/or +-accepted as part of an installation process), but does not otherwise replace, +-modify or cancel any other written agreement between Licensee and CIRRUS LOGIC. +-If there is any inconsistency between these terms and those presented as part of +-the process to install the Software, these terms will prevail. +diff --git a/WHENCE b/WHENCE +index e6309eb..116d04d 100644 +--- a/WHENCE ++++ b/WHENCE +@@ -17,43 +17,6 @@ Licence: Redistributable. See LICENCE.cypress for details. + + -------------------------------------------------------------------------- + +-Driver: snd-korg1212 -- Korg 1212 IO audio device +- +-File: korg/k1212.dsp +- +-Licence: Unknown +- +-Found in alsa-firmware package in hex form; no licensing information. +- +--------------------------------------------------------------------------- +- +-Driver: snd-maestro3 -- ESS Allegro Maestro3 audio device +- +-File: ess/maestro3_assp_kernel.fw +-File: ess/maestro3_assp_minisrc.fw +- +-Licence: Unknown +- +-Found in alsa-firmware package in hex form with a comment claiming to +-be GPLv2+, but without source -- and with another comment saying "ESS +-drops binary dsp code images on our heads, but we don't get to see +-specs on the dsp." +- +--------------------------------------------------------------------------- +- +-Driver: snd-ymfpci -- Yamaha YMF724/740/744/754 audio devices +- +-File: yamaha/ds1_ctrl.fw +-File: yamaha/ds1_dsp.fw +-File: yamaha/ds1e_ctrl.fw +- +-Licence: Unknown +- +-Found alsa-firmware package in hex form, with the following comment: +- Copyright (c) 1997-1999 Yamaha Corporation. All Rights Reserved. +- +--------------------------------------------------------------------------- +- + Driver: advansys - AdvanSys SCSI + + File: advansys/mcode.bin +@@ -360,24 +323,6 @@ http://www.zdomain.com/a56.html + + -------------------------------------------------------------------------- + +-Driver: snd-sb16-csp - Sound Blaster 16/AWE CSP support +- +-File: sb16/mulaw_main.csp +-File: sb16/alaw_main.csp +-File: sb16/ima_adpcm_init.csp +-File: sb16/ima_adpcm_playback.csp +-File: sb16/ima_adpcm_capture.csp +- +-Licence: Allegedly GPLv2+, but no source visible. Marked: +-/* +- * Copyright (c) 1994 Creative Technology Ltd. +- * Microcode files for SB16 Advanced Signal Processor +- */ +- +-Found in hex form in kernel source. +- +--------------------------------------------------------------------------- +- + Driver: qla2xxx - QLogic QLA2XXX Fibre Channel + + File: ql2100_fw.bin +@@ -1383,17 +1328,6 @@ ARM assembly source code from https://linuxtv.org/downloads/firmware/Boot.S + + -------------------------------------------------------------------------- + +-Driver: snd-wavefront - ISA WaveFront sound card +- +-File: yamaha/yss225_registers.bin +- +-Licence: Allegedly GPLv2+, but no source visible. +- +-Found in hex form in kernel source, with the following comment: +- Copyright (c) 1998-2002 by Paul Davis +- +--------------------------------------------------------------------------- +- + Driver: rt61pci - Ralink RT2561, RT2561S, RT2661 wireless MACs + + File: rt2561.bin +@@ -3605,17 +3539,6 @@ Licence: GPLv2. Some build scripts use the New BSD (3-clause) licence.. See GPL- + + -------------------------------------------------------------------------- + +-Driver: snd-hda-codec-ca0132 - Creative Sound Core3D codec +- +-File: ctefx.bin +-File: ctspeq.bin +- +-Licence: Redistributable. See LICENCE.ca0132 for details +- +-Found also in alsa-firmware package. +- +--------------------------------------------------------------------------- +- + Driver: btusb - Bluetooth USB driver + + File: intel/ibt-hw-37.7.bseq +@@ -4044,14 +3967,6 @@ Licence: Redistributable. See LICENCE.r8a779x_usb3 for details. + + -------------------------------------------------------------------------- + +-Driver: snd_soc_sst_acpi +- +-File: intel/fw_sst_0f28.bin-48kHz_i2s_master +- +-License: Redistributable. See LICENCE.fw_sst_0f28 for details +- +--------------------------------------------------------------------------- +- + Driver: as102 - Abilis Systems Single DVB-T Receiver + + File: as102_data1_st.hex +@@ -4070,104 +3985,6 @@ Licence: Redistributable. See LICENCE.it913x for details + + -------------------------------------------------------------------------- + +-Driver: snd_soc_catpt -- Intel AudioDSP driver for HSW/BDW platforms +- +-File: intel/catpt/bdw/dsp_basefw.bin +-Version: 44b81c4d5397a63108356f58f036953d9b288c4e +-Link: intel/IntcSST2.bin -> catpt/bdw/dsp_basefw.bin +- +-License: Redistributable. See LICENCE.IntcSST2 for details +- +--------------------------------------------------------------------------- +- +-Driver: snd_soc_avs -- Intel AudioDSP driver for cAVS platforms +- +-File: intel/avs/skl/dsp_basefw.bin +-File: intel/avs/skl/dsp_mod_7CAD0808-AB10-CD23-EF45-12AB34CD56EF.bin +-Version: 9.21.00.4899 +-Link: intel/dsp_fw_release.bin -> avs/skl/dsp_basefw.bin +-Link: intel/dsp_fw_kbl.bin -> avs/skl/dsp_basefw.bin +-File: intel/avs/apl/dsp_basefw.bin +-Version: 9.22.01.4908 +-Link: intel/dsp_fw_bxtn.bin -> avs/apl/dsp_basefw.bin +-Link: intel/dsp_fw_glk.bin -> avs/apl/dsp_basefw.bin +-File: intel/avs/cnl/dsp_basefw.bin +-Version: 10.23.00.8551 +-Link: intel/dsp_fw_cnl.bin -> avs/cnl/dsp_basefw.bin +- +-License: Redistributable. See LICENCE.adsp_sst for details +- +--------------------------------------------------------------------------- +- +-Driver: snd_intel_sst_core +- +-File: intel/fw_sst_0f28.bin +-File: intel/fw_sst_0f28_ssp0.bin +- +-License: Redistributable. See LICENCE.fw_sst_0f28 for details +- +--------------------------------------------------------------------------- +- +-Driver: snd_intel_sst_core +- +-File: intel/fw_sst_22a8.bin +-Version: 01.0B.02.02 +- +-License: Redistributable. See LICENCE.fw_sst_0f28 for details +- +--------------------------------------------------------------------------- +- +-Driver: snd-soc-skl +- +-File: intel/dsp_fw_release_v969.bin +-Version: 8.20.00.969 +-File: intel/dsp_fw_release_v3402.bin +-Version: 9.21.00.3402_161 +- +-License: Redistributable. See LICENCE.adsp_sst for details +- +-File: intel/dsp_fw_bxtn_v2219.bin +-Version: 9.22.01.2219_64 +-File: intel/dsp_fw_bxtn_v3366.bin +-Version: 9.22.01.3366_157 +- +-License: Redistributable. See LICENCE.adsp_sst for details +- +-File: intel/dsp_fw_kbl_v701.bin +-Version: 9.21.00.701 +-File: intel/dsp_fw_kbl_v1037.bin +-Version: 09.21.00.1037 +-File: intel/dsp_fw_kbl_v2042.bin +-Version: 9.21.00.2042_46 +-File: intel/dsp_fw_kbl_v2630.bin +-Version: 9.21.00.2630_97 +-File: intel/dsp_fw_kbl_v3266.bin +-Version: 9.21.00.3266_144 +-File: intel/dsp_fw_kbl_v3420.bin +-Version: 9.21.00.3420_163 +-File: intel/dsp_fw_kbl_v3402.bin +-Version: 9.21.00.3402_161 +- +-License: Redistributable. See LICENCE.adsp_sst for details +- +-File: intel/dsp_fw_glk_v1814.bin +-Version: 9.92.01.1814 +-File: intel/dsp_fw_glk_v2880.bin +-Version: 9.22.00.2880 +-File: intel/dsp_fw_glk_v2768.bin +-Version: 9.22.01.2768 +-File: intel/dsp_fw_glk_v3366.bin +-Version: 9.22.01.3366_157 +- +-File: intel/dsp_fw_cnl_v1191.bin +-Version: 10.00.00.1191 +-File: intel/dsp_fw_cnl_v1858.bin +-Version: 10.23.00.1858 +- +-License: Redistributable. See LICENCE.adsp_sst for details +- +--------------------------------------------------------------------------- +- + Driver: smsmdtv - Siano MDTV Core module + + File: cmmb_vega_12mhz.inp +@@ -5935,368 +5752,6 @@ Licence: Redistributable. See LICENSE.amphion_vpu for details + + --------------------------------------------------------------------------- + +-Driver: cs35l41_hda - CS35l41 ALSA HDA audio driver +- +-File: cirrus/cs35l41-dsp1-spk-prot.wmfw +-File: cirrus/cs35l41-dsp1-spk-prot.bin +-File: cirrus/cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-prot-103c8971.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-cali-103c8971.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-prot-103c8972.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-cali-103c8972.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-prot-103c8973.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-cali-103c8973.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-prot-103c8974.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-cali-103c8974.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-prot-103c8975.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-cali-103c8975.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-prot-103c896e.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-cali-103c896e.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-prot-103c89c3.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-cali-103c89c3.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-prot-103c8981.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-cali-103c8981.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-prot-103c898e.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-cali-103c898e.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-prot-103c898f.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-cali-103c898f.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-prot-103c8991.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-cali-103c8991.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-prot-103c8992.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-cali-103c8992.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-prot-103c8994.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-cali-103c8994.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-prot-103c8995.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-cali-103c8995.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-prot-103c89c6.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-cali-103c89c6.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-File: cirrus/cs35l41-dsp1-spk-prot-103c8971.bin +-File: cirrus/cs35l41-dsp1-spk-cali-103c8971.bin +-File: cirrus/cs35l41-dsp1-spk-prot-103c8972.bin +-File: cirrus/cs35l41-dsp1-spk-cali-103c8972.bin +-File: cirrus/cs35l41-dsp1-spk-prot-103c8973.bin +-File: cirrus/cs35l41-dsp1-spk-cali-103c8973.bin +-Link: cirrus/cs35l41-dsp1-spk-prot-103c8974.bin -> cs35l41-dsp1-spk-prot-103c8972.bin +-Link: cirrus/cs35l41-dsp1-spk-cali-103c8974.bin -> cs35l41-dsp1-spk-cali-103c8972.bin +-File: cirrus/cs35l41-dsp1-spk-prot-103c8975-r0.bin +-File: cirrus/cs35l41-dsp1-spk-cali-103c8975-r0.bin +-File: cirrus/cs35l41-dsp1-spk-prot-103c8975-l0.bin +-File: cirrus/cs35l41-dsp1-spk-cali-103c8975-l0.bin +-File: cirrus/cs35l41-dsp1-spk-prot-103c896e-r0.bin +-File: cirrus/cs35l41-dsp1-spk-cali-103c896e-r0.bin +-File: cirrus/cs35l41-dsp1-spk-prot-103c896e-l0.bin +-File: cirrus/cs35l41-dsp1-spk-cali-103c896e-l0.bin +-Link: cirrus/cs35l41-dsp1-spk-prot-103c898e.bin -> cs35l41-dsp1-spk-prot-103c8971.bin +-Link: cirrus/cs35l41-dsp1-spk-cali-103c898e.bin -> cs35l41-dsp1-spk-cali-103c8971.bin +-Link: cirrus/cs35l41-dsp1-spk-prot-103c898f.bin -> cs35l41-dsp1-spk-prot-103c8971.bin +-Link: cirrus/cs35l41-dsp1-spk-cali-103c898f.bin -> cs35l41-dsp1-spk-cali-103c8971.bin +-Link: cirrus/cs35l41-dsp1-spk-prot-103c8991.bin -> cs35l41-dsp1-spk-prot-103c8972.bin +-Link: cirrus/cs35l41-dsp1-spk-cali-103c8991.bin -> cs35l41-dsp1-spk-cali-103c8972.bin +-Link: cirrus/cs35l41-dsp1-spk-prot-103c8992.bin -> cs35l41-dsp1-spk-prot-103c8972.bin +-Link: cirrus/cs35l41-dsp1-spk-cali-103c8992.bin -> cs35l41-dsp1-spk-cali-103c8972.bin +-Link: cirrus/cs35l41-dsp1-spk-prot-103c8994.bin -> cs35l41-dsp1-spk-prot-103c8973.bin +-Link: cirrus/cs35l41-dsp1-spk-cali-103c8994.bin -> cs35l41-dsp1-spk-cali-103c8973.bin +-Link: cirrus/cs35l41-dsp1-spk-prot-103c8995.bin -> cs35l41-dsp1-spk-prot-103c8973.bin +-Link: cirrus/cs35l41-dsp1-spk-cali-103c8995.bin -> cs35l41-dsp1-spk-cali-103c8973.bin +-File: cirrus/cs35l41-dsp1-spk-prot-103c89c6-r0.bin +-File: cirrus/cs35l41-dsp1-spk-cali-103c89c6-r0.bin +-File: cirrus/cs35l41-dsp1-spk-prot-103c89c6-l0.bin +-File: cirrus/cs35l41-dsp1-spk-cali-103c89c6-l0.bin +-File: cirrus/cs35l41-dsp1-spk-prot-103c89c3-r0.bin +-File: cirrus/cs35l41-dsp1-spk-cali-103c89c3-r0.bin +-File: cirrus/cs35l41-dsp1-spk-prot-103c89c3-r1.bin +-File: cirrus/cs35l41-dsp1-spk-cali-103c89c3-r1.bin +-Link: cirrus/cs35l41-dsp1-spk-prot-103c89c3-l0.bin -> cs35l41-dsp1-spk-prot-103c89c3-r0.bin +-Link: cirrus/cs35l41-dsp1-spk-cali-103c89c3-l0.bin -> cs35l41-dsp1-spk-cali-103c89c3-r0.bin +-Link: cirrus/cs35l41-dsp1-spk-prot-103c89c3-l1.bin -> cs35l41-dsp1-spk-prot-103c89c3-r1.bin +-Link: cirrus/cs35l41-dsp1-spk-cali-103c89c3-l1.bin -> cs35l41-dsp1-spk-cali-103c89c3-r1.bin +-File: cirrus/cs35l41-dsp1-spk-prot-103c8981-r0.bin +-File: cirrus/cs35l41-dsp1-spk-prot-103c8981-r1.bin +-File: cirrus/cs35l41-dsp1-spk-prot-103c8981-l0.bin +-File: cirrus/cs35l41-dsp1-spk-prot-103c8981-l1.bin +-File: cirrus/cs35l41-dsp1-spk-cali-103c8981-r0.bin +-File: cirrus/cs35l41-dsp1-spk-cali-103c8981-r1.bin +-File: cirrus/cs35l41-dsp1-spk-cali-103c8981-l0.bin +-File: cirrus/cs35l41-dsp1-spk-cali-103c8981-l1.bin +-File: cirrus/cs35l41/v6.39.0/halo_cspl_RAM_revB2_29.41.0.wmfw +-Link: cirrus/cs35l41-dsp1-spk-prot-17aa3847.wmfw -> cs35l41/v6.39.0/halo_cspl_RAM_revB2_29.41.0.wmfw +-Link: cirrus/cs35l41-dsp1-spk-cali-17aa3847.wmfw -> cs35l41/v6.39.0/halo_cspl_RAM_revB2_29.41.0.wmfw +-File: cirrus/cs35l41-dsp1-spk-prot-17aa3847-spkid0-l0.bin +-File: cirrus/cs35l41-dsp1-spk-prot-17aa3847-spkid0-r0.bin +-File: cirrus/cs35l41-dsp1-spk-cali-17aa3847-spkid0.bin +-File: cirrus/cs35l41-dsp1-spk-prot-17aa3847-spkid1-l0.bin +-File: cirrus/cs35l41-dsp1-spk-prot-17aa3847-spkid1-r0.bin +-File: cirrus/cs35l41-dsp1-spk-cali-17aa3847-spkid1.bin +-File: cirrus/cs35l41/v6.47.0/halo_cspl_RAM_revB2_29.49.0.wmfw +-Link: cirrus/cs35l41-dsp1-spk-prot-17aa3855.wmfw -> cs35l41/v6.47.0/halo_cspl_RAM_revB2_29.49.0.wmfw +-Link: cirrus/cs35l41-dsp1-spk-cali-17aa3855.wmfw -> cs35l41/v6.47.0/halo_cspl_RAM_revB2_29.49.0.wmfw +-File: cirrus/cs35l41-dsp1-spk-prot-17aa3855-spkid0-l0.bin +-File: cirrus/cs35l41-dsp1-spk-prot-17aa3855-spkid0-r0.bin +-File: cirrus/cs35l41-dsp1-spk-cali-17aa3855-spkid0.bin +-File: cirrus/cs35l41-dsp1-spk-prot-17aa3855-spkid1-l0.bin +-File: cirrus/cs35l41-dsp1-spk-prot-17aa3855-spkid1-r0.bin +-File: cirrus/cs35l41-dsp1-spk-cali-17aa3855-spkid1.bin +-Link: cirrus/cs35l41-dsp1-spk-prot-17aa22f1.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-cali-17aa22f1.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-prot-17aa22f2.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-cali-17aa22f2.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-prot-17aa22f3.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-cali-17aa22f3.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-File: cirrus/cs35l41-dsp1-spk-prot-17aa22f1-l0.bin +-File: cirrus/cs35l41-dsp1-spk-prot-17aa22f1-r0.bin +-File: cirrus/cs35l41-dsp1-spk-cali-17aa22f1-l0.bin +-File: cirrus/cs35l41-dsp1-spk-cali-17aa22f1-r0.bin +-File: cirrus/cs35l41-dsp1-spk-prot-17aa22f2-l0.bin +-File: cirrus/cs35l41-dsp1-spk-prot-17aa22f2-r0.bin +-File: cirrus/cs35l41-dsp1-spk-cali-17aa22f2-l0.bin +-File: cirrus/cs35l41-dsp1-spk-cali-17aa22f2-r0.bin +-Link: cirrus/cs35l41-dsp1-spk-prot-17aa22f3-l0.bin -> cs35l41-dsp1-spk-prot-17aa22f2-l0.bin +-Link: cirrus/cs35l41-dsp1-spk-prot-17aa22f3-r0.bin -> cs35l41-dsp1-spk-prot-17aa22f2-r0.bin +-Link: cirrus/cs35l41-dsp1-spk-cali-17aa22f3-l0.bin -> cs35l41-dsp1-spk-cali-17aa22f2-l0.bin +-Link: cirrus/cs35l41-dsp1-spk-cali-17aa22f3-r0.bin -> cs35l41-dsp1-spk-cali-17aa22f2-r0.bin +-File: cirrus/cs35l41/v6.63.0/halo_cspl_RAM_revB2_29.65.0.wmfw +-Link: cirrus/cs35l41-dsp1-spk-prot-104312af.wmfw -> cs35l41/v6.63.0/halo_cspl_RAM_revB2_29.65.0.wmfw +-Link: cirrus/cs35l41-dsp1-spk-cali-104312af.wmfw -> cs35l41/v6.63.0/halo_cspl_RAM_revB2_29.65.0.wmfw +-File: cirrus/cs35l41-dsp1-spk-prot-104312af-spkid0-l0.bin +-File: cirrus/cs35l41-dsp1-spk-prot-104312af-spkid0-r0.bin +-File: cirrus/cs35l41-dsp1-spk-prot-104312af-spkid1-l0.bin +-File: cirrus/cs35l41-dsp1-spk-prot-104312af-spkid1-r0.bin +-File: cirrus/cs35l41-dsp1-spk-cali-104312af-spkid0-l0.bin +-File: cirrus/cs35l41-dsp1-spk-cali-104312af-spkid0-r0.bin +-File: cirrus/cs35l41-dsp1-spk-cali-104312af-spkid1-l0.bin +-File: cirrus/cs35l41-dsp1-spk-cali-104312af-spkid1-r0.bin +-Link: cirrus/cs35l41-dsp1-spk-prot-10431a8f.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-cali-10431a8f.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-File: cirrus/cs35l41-dsp1-spk-prot-10431a8f-spkid0-l0.bin +-File: cirrus/cs35l41-dsp1-spk-prot-10431a8f-spkid0-r0.bin +-File: cirrus/cs35l41-dsp1-spk-prot-10431a8f-spkid1-l0.bin +-File: cirrus/cs35l41-dsp1-spk-prot-10431a8f-spkid1-r0.bin +-File: cirrus/cs35l41-dsp1-spk-cali-10431a8f-spkid0-l0.bin +-File: cirrus/cs35l41-dsp1-spk-cali-10431a8f-spkid0-r0.bin +-File: cirrus/cs35l41-dsp1-spk-cali-10431a8f-spkid1-l0.bin +-File: cirrus/cs35l41-dsp1-spk-cali-10431a8f-spkid1-r0.bin +-Link: cirrus/cs35l41-dsp1-spk-prot-10431e02.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-cali-10431e02.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-File: cirrus/cs35l41-dsp1-spk-prot-10431e02-spkid0-l0.bin +-File: cirrus/cs35l41-dsp1-spk-prot-10431e02-spkid0-r0.bin +-File: cirrus/cs35l41-dsp1-spk-cali-10431e02-spkid0-l0.bin +-File: cirrus/cs35l41-dsp1-spk-cali-10431e02-spkid0-r0.bin +-File: cirrus/cs35l41-dsp1-spk-prot-10431e02-spkid1-l0.bin +-File: cirrus/cs35l41-dsp1-spk-prot-10431e02-spkid1-r0.bin +-File: cirrus/cs35l41-dsp1-spk-cali-10431e02-spkid1-l0.bin +-File: cirrus/cs35l41-dsp1-spk-cali-10431e02-spkid1-r0.bin +-Link: cirrus/cs35l41-dsp1-spk-prot-10431f12.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-cali-10431f12.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-File: cirrus/cs35l41-dsp1-spk-cali-10431f12-spkid0-l0.bin +-File: cirrus/cs35l41-dsp1-spk-cali-10431f12-spkid0-r0.bin +-File: cirrus/cs35l41-dsp1-spk-cali-10431f12-spkid1-l0.bin +-File: cirrus/cs35l41-dsp1-spk-cali-10431f12-spkid1-r0.bin +-File: cirrus/cs35l41-dsp1-spk-prot-10431f12-spkid0-l0.bin +-File: cirrus/cs35l41-dsp1-spk-prot-10431f12-spkid0-r0.bin +-File: cirrus/cs35l41-dsp1-spk-prot-10431f12-spkid1-l0.bin +-File: cirrus/cs35l41-dsp1-spk-prot-10431f12-spkid1-r0.bin +-Link: cirrus/cs35l41-dsp1-spk-prot-10431e12.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-cali-10431e12.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-File: cirrus/cs35l41-dsp1-spk-cali-10431e12-spkid0-l0.bin +-File: cirrus/cs35l41-dsp1-spk-cali-10431e12-spkid0-r0.bin +-File: cirrus/cs35l41-dsp1-spk-cali-10431e12-spkid1-l0.bin +-File: cirrus/cs35l41-dsp1-spk-cali-10431e12-spkid1-r0.bin +-File: cirrus/cs35l41-dsp1-spk-prot-10431e12-spkid0-l0.bin +-File: cirrus/cs35l41-dsp1-spk-prot-10431e12-spkid0-r0.bin +-File: cirrus/cs35l41-dsp1-spk-prot-10431e12-spkid1-l0.bin +-File: cirrus/cs35l41-dsp1-spk-prot-10431e12-spkid1-r0.bin +-Link: cirrus/cs35l41-dsp1-spk-prot-10431b93.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-cali-10431b93.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-prot-10431a20.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-cali-10431a20.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-prot-10431a30.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-cali-10431a30.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-prot-10431a40.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-cali-10431a40.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-prot-10431a50.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-cali-10431a50.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-prot-10431a60.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-cali-10431a60.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-File: cirrus/cs35l41-dsp1-spk-prot-10431b93-spkid0-l0.bin +-File: cirrus/cs35l41-dsp1-spk-prot-10431b93-spkid0-r0.bin +-File: cirrus/cs35l41-dsp1-spk-prot-10431b93-spkid1-l0.bin +-File: cirrus/cs35l41-dsp1-spk-prot-10431b93-spkid1-r0.bin +-File: cirrus/cs35l41-dsp1-spk-cali-10431b93-spkid0-l0.bin +-File: cirrus/cs35l41-dsp1-spk-cali-10431b93-spkid0-r0.bin +-File: cirrus/cs35l41-dsp1-spk-cali-10431b93-spkid1-l0.bin +-File: cirrus/cs35l41-dsp1-spk-cali-10431b93-spkid1-r0.bin +-Link: cirrus/cs35l41-dsp1-spk-prot-10433a20-spkid0-l0.bin -> cs35l41-dsp1-spk-prot-10431b93-spkid0-l0.bin +-Link: cirrus/cs35l41-dsp1-spk-prot-10433a20-spkid0-r0.bin -> cs35l41-dsp1-spk-prot-10431b93-spkid0-r0.bin +-Link: cirrus/cs35l41-dsp1-spk-prot-10433a20-spkid1-l0.bin -> cs35l41-dsp1-spk-prot-10431b93-spkid1-l0.bin +-Link: cirrus/cs35l41-dsp1-spk-prot-10433a20-spkid1-r0.bin -> cs35l41-dsp1-spk-prot-10431b93-spkid1-r0.bin +-Link: cirrus/cs35l41-dsp1-spk-cali-10433a20-spkid0-l0.bin -> cs35l41-dsp1-spk-cali-10431b93-spkid0-l0.bin +-Link: cirrus/cs35l41-dsp1-spk-cali-10433a20-spkid0-r0.bin -> cs35l41-dsp1-spk-cali-10431b93-spkid0-r0.bin +-Link: cirrus/cs35l41-dsp1-spk-cali-10433a20-spkid1-l0.bin -> cs35l41-dsp1-spk-cali-10431b93-spkid1-l0.bin +-Link: cirrus/cs35l41-dsp1-spk-cali-10433a20-spkid1-r0.bin -> cs35l41-dsp1-spk-cali-10431b93-spkid1-r0.bin +-File: cirrus/cs35l41-dsp1-spk-prot-10433a30-spkid1-l0.bin +-File: cirrus/cs35l41-dsp1-spk-cali-10433a30-spkid1-l0.bin +-File: cirrus/cs35l41-dsp1-spk-prot-10433a30-spkid1-r0.bin +-File: cirrus/cs35l41-dsp1-spk-cali-10433a30-spkid1-r0.bin +-File: cirrus/cs35l41-dsp1-spk-prot-10433a30-spkid0-l0.bin +-File: cirrus/cs35l41-dsp1-spk-cali-10433a30-spkid0-l0.bin +-File: cirrus/cs35l41-dsp1-spk-prot-10433a30-spkid0-r0.bin +-File: cirrus/cs35l41-dsp1-spk-cali-10433a30-spkid0-r0.bin +-Link: cirrus/cs35l41-dsp1-spk-prot-10433a40-spkid0-l0.bin -> cs35l41-dsp1-spk-prot-10433a30-spkid0-l0.bin +-Link: cirrus/cs35l41-dsp1-spk-prot-10433a40-spkid0-r0.bin -> cs35l41-dsp1-spk-prot-10433a30-spkid0-r0.bin +-Link: cirrus/cs35l41-dsp1-spk-prot-10433a40-spkid1-l0.bin -> cs35l41-dsp1-spk-prot-10433a30-spkid1-l0.bin +-Link: cirrus/cs35l41-dsp1-spk-prot-10433a40-spkid1-r0.bin -> cs35l41-dsp1-spk-prot-10433a30-spkid1-r0.bin +-Link: cirrus/cs35l41-dsp1-spk-cali-10433a40-spkid0-l0.bin -> cs35l41-dsp1-spk-cali-10433a30-spkid0-l0.bin +-Link: cirrus/cs35l41-dsp1-spk-cali-10433a40-spkid0-r0.bin -> cs35l41-dsp1-spk-cali-10433a30-spkid0-r0.bin +-Link: cirrus/cs35l41-dsp1-spk-cali-10433a40-spkid1-l0.bin -> cs35l41-dsp1-spk-cali-10433a30-spkid1-l0.bin +-Link: cirrus/cs35l41-dsp1-spk-cali-10433a40-spkid1-r0.bin -> cs35l41-dsp1-spk-cali-10433a30-spkid1-r0.bin +-File: cirrus/cs35l41-dsp1-spk-prot-10433a50-spkid1-l0.bin +-File: cirrus/cs35l41-dsp1-spk-cali-10433a50-spkid1-l0.bin +-File: cirrus/cs35l41-dsp1-spk-prot-10433a50-spkid1-r0.bin +-File: cirrus/cs35l41-dsp1-spk-cali-10433a50-spkid1-r0.bin +-File: cirrus/cs35l41-dsp1-spk-prot-10433a50-spkid0-l0.bin +-File: cirrus/cs35l41-dsp1-spk-cali-10433a50-spkid0-l0.bin +-File: cirrus/cs35l41-dsp1-spk-prot-10433a50-spkid0-r0.bin +-File: cirrus/cs35l41-dsp1-spk-cali-10433a50-spkid0-r0.bin +-File: cirrus/cs35l41-dsp1-spk-prot-10433a60-spkid1-l0.bin +-File: cirrus/cs35l41-dsp1-spk-cali-10433a60-spkid1-l0.bin +-File: cirrus/cs35l41-dsp1-spk-prot-10433a60-spkid1-r0.bin +-File: cirrus/cs35l41-dsp1-spk-cali-10433a60-spkid1-r0.bin +-File: cirrus/cs35l41-dsp1-spk-prot-10433a60-spkid0-l0.bin +-File: cirrus/cs35l41-dsp1-spk-cali-10433a60-spkid0-l0.bin +-File: cirrus/cs35l41-dsp1-spk-prot-10433a60-spkid0-r0.bin +-File: cirrus/cs35l41-dsp1-spk-cali-10433a60-spkid0-r0.bin +-Link: cirrus/cs35l41-dsp1-spk-prot-17aa2316.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-cali-17aa2316.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-prot-17aa2317.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-cali-17aa2317.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-File: cirrus/cs35l41-dsp1-spk-prot-17aa2316-spkid0-l0.bin +-File: cirrus/cs35l41-dsp1-spk-prot-17aa2316-spkid0-r0.bin +-File: cirrus/cs35l41-dsp1-spk-prot-17aa2316-spkid1-l0.bin +-File: cirrus/cs35l41-dsp1-spk-prot-17aa2316-spkid1-r0.bin +-File: cirrus/cs35l41-dsp1-spk-cali-17aa2316-spkid0-l0.bin +-File: cirrus/cs35l41-dsp1-spk-cali-17aa2316-spkid0-r0.bin +-File: cirrus/cs35l41-dsp1-spk-cali-17aa2316-spkid1-l0.bin +-File: cirrus/cs35l41-dsp1-spk-cali-17aa2316-spkid1-r0.bin +-Link: cirrus/cs35l41-dsp1-spk-prot-17aa2317-spkid0-l0.bin -> cs35l41-dsp1-spk-prot-17aa2316-spkid0-l0.bin +-Link: cirrus/cs35l41-dsp1-spk-prot-17aa2317-spkid0-r0.bin -> cs35l41-dsp1-spk-prot-17aa2316-spkid0-r0.bin +-Link: cirrus/cs35l41-dsp1-spk-prot-17aa2317-spkid1-l0.bin -> cs35l41-dsp1-spk-prot-17aa2316-spkid1-l0.bin +-Link: cirrus/cs35l41-dsp1-spk-prot-17aa2317-spkid1-r0.bin -> cs35l41-dsp1-spk-prot-17aa2316-spkid1-r0.bin +-Link: cirrus/cs35l41-dsp1-spk-cali-17aa2317-spkid0-l0.bin -> cs35l41-dsp1-spk-cali-17aa2316-spkid0-l0.bin +-Link: cirrus/cs35l41-dsp1-spk-cali-17aa2317-spkid0-r0.bin -> cs35l41-dsp1-spk-cali-17aa2316-spkid0-r0.bin +-Link: cirrus/cs35l41-dsp1-spk-cali-17aa2317-spkid1-l0.bin -> cs35l41-dsp1-spk-cali-17aa2316-spkid1-l0.bin +-Link: cirrus/cs35l41-dsp1-spk-cali-17aa2317-spkid1-r0.bin -> cs35l41-dsp1-spk-cali-17aa2316-spkid1-r0.bin +-Link: cirrus/cs35l41-dsp1-spk-prot-17aa2318.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-cali-17aa2318.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-prot-17aa2319.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-cali-17aa2319.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-prot-17aa231a.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-cali-17aa231a.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-prot-17aa2318-l0.bin -> cs35l41-dsp1-spk-prot-17aa22f1-l0.bin +-Link: cirrus/cs35l41-dsp1-spk-prot-17aa2318-r0.bin -> cs35l41-dsp1-spk-prot-17aa22f1-r0.bin +-Link: cirrus/cs35l41-dsp1-spk-cali-17aa2318-l0.bin -> cs35l41-dsp1-spk-cali-17aa22f1-l0.bin +-Link: cirrus/cs35l41-dsp1-spk-cali-17aa2318-r0.bin -> cs35l41-dsp1-spk-cali-17aa22f1-r0.bin +-Link: cirrus/cs35l41-dsp1-spk-prot-17aa2319-l0.bin -> cs35l41-dsp1-spk-prot-17aa22f2-l0.bin +-Link: cirrus/cs35l41-dsp1-spk-prot-17aa2319-r0.bin -> cs35l41-dsp1-spk-prot-17aa22f2-r0.bin +-Link: cirrus/cs35l41-dsp1-spk-cali-17aa2319-l0.bin -> cs35l41-dsp1-spk-cali-17aa22f2-l0.bin +-Link: cirrus/cs35l41-dsp1-spk-cali-17aa2319-r0.bin -> cs35l41-dsp1-spk-cali-17aa22f2-r0.bin +-Link: cirrus/cs35l41-dsp1-spk-prot-17aa231a-l0.bin -> cs35l41-dsp1-spk-prot-17aa22f2-l0.bin +-Link: cirrus/cs35l41-dsp1-spk-prot-17aa231a-r0.bin -> cs35l41-dsp1-spk-prot-17aa22f2-r0.bin +-Link: cirrus/cs35l41-dsp1-spk-cali-17aa231a-l0.bin -> cs35l41-dsp1-spk-cali-17aa22f2-l0.bin +-Link: cirrus/cs35l41-dsp1-spk-cali-17aa231a-r0.bin -> cs35l41-dsp1-spk-cali-17aa22f2-r0.bin +-Link: cirrus/cs35l41-dsp1-spk-prot-103c8c26.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-cali-103c8c26.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-prot-103c8b42.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-cali-103c8b42.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-prot-103c8b43.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-cali-103c8b43.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-prot-103c8b44.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-cali-103c8b44.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-prot-103c8b45.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-cali-103c8b45.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-prot-103c8b46.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-cali-103c8b46.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-prot-103c8b47.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-cali-103c8b47.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-prot-103c8b63.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-cali-103c8b63.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-prot-103c8b70.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-cali-103c8b70.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-prot-103c8b72.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-cali-103c8b72.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-prot-103c8b74.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-cali-103c8b74.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-prot-103c8b77.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-cali-103c8b77.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-prot-103c8b8f.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-Link: cirrus/cs35l41-dsp1-spk-prot-103c8b92.wmfw -> cs35l41/v6.61.1/halo_cspl_RAM_revB2_29.63.1.wmfw +-File: cirrus/cs35l41-dsp1-spk-prot-103c8b42.bin +-File: cirrus/cs35l41-dsp1-spk-cali-103c8b42.bin +-File: cirrus/cs35l41-dsp1-spk-prot-103c8b43.bin +-File: cirrus/cs35l41-dsp1-spk-cali-103c8b43.bin +-File: cirrus/cs35l41-dsp1-spk-prot-103c8b44.bin +-File: cirrus/cs35l41-dsp1-spk-cali-103c8b44.bin +-File: cirrus/cs35l41-dsp1-spk-prot-103c8b45.bin +-File: cirrus/cs35l41-dsp1-spk-cali-103c8b45.bin +-Link: cirrus/cs35l41-dsp1-spk-prot-103c8b46.bin -> cs35l41-dsp1-spk-prot-103c8b45.bin +-Link: cirrus/cs35l41-dsp1-spk-cali-103c8b46.bin -> cs35l41-dsp1-spk-cali-103c8b45.bin +-File: cirrus/cs35l41-dsp1-spk-prot-103c8b47.bin +-File: cirrus/cs35l41-dsp1-spk-cali-103c8b47.bin +-File: cirrus/cs35l41-dsp1-spk-prot-103c8b63-r0.bin +-File: cirrus/cs35l41-dsp1-spk-cali-103c8b63-r0.bin +-File: cirrus/cs35l41-dsp1-spk-prot-103c8b63-r1.bin +-File: cirrus/cs35l41-dsp1-spk-cali-103c8b63-r1.bin +-File: cirrus/cs35l41-dsp1-spk-prot-103c8b63-l0.bin +-File: cirrus/cs35l41-dsp1-spk-cali-103c8b63-l0.bin +-File: cirrus/cs35l41-dsp1-spk-prot-103c8b63-l1.bin +-File: cirrus/cs35l41-dsp1-spk-cali-103c8b63-l1.bin +-Link: cirrus/cs35l41-dsp1-spk-prot-103c8b70.bin -> cs35l41-dsp1-spk-prot-103c8b42.bin +-Link: cirrus/cs35l41-dsp1-spk-cali-103c8b70.bin -> cs35l41-dsp1-spk-cali-103c8b42.bin +-Link: cirrus/cs35l41-dsp1-spk-prot-103c8b72.bin -> cs35l41-dsp1-spk-prot-103c8b45.bin +-Link: cirrus/cs35l41-dsp1-spk-cali-103c8b72.bin -> cs35l41-dsp1-spk-cali-103c8b45.bin +-Link: cirrus/cs35l41-dsp1-spk-prot-103c8b74.bin -> cs35l41-dsp1-spk-prot-103c8b47.bin +-Link: cirrus/cs35l41-dsp1-spk-cali-103c8b74.bin -> cs35l41-dsp1-spk-cali-103c8b47.bin +-Link: cirrus/cs35l41-dsp1-spk-prot-103c8b77.bin -> cs35l41-dsp1-spk-prot-103c8b45.bin +-Link: cirrus/cs35l41-dsp1-spk-cali-103c8b77.bin -> cs35l41-dsp1-spk-cali-103c8b45.bin +-File: cirrus/cs35l41-dsp1-spk-prot-103c8b8f-r0.bin +-File: cirrus/cs35l41-dsp1-spk-prot-103c8b8f-r1.bin +-File: cirrus/cs35l41-dsp1-spk-cali-103c8b8f-r0.bin +-File: cirrus/cs35l41-dsp1-spk-cali-103c8b8f-r1.bin +-Link: cirrus/cs35l41-dsp1-spk-prot-103c8b8f-l0.bin -> cs35l41-dsp1-spk-prot-103c8b8f-r0.bin +-Link: cirrus/cs35l41-dsp1-spk-prot-103c8b8f-l1.bin -> cs35l41-dsp1-spk-prot-103c8b8f-r1.bin +-Link: cirrus/cs35l41-dsp1-spk-cali-103c8b8f-l0.bin -> cs35l41-dsp1-spk-cali-103c8b8f-r0.bin +-Link: cirrus/cs35l41-dsp1-spk-cali-103c8b8f-l1.bin -> cs35l41-dsp1-spk-cali-103c8b8f-r1.bin +-File: cirrus/cs35l41-dsp1-spk-prot-103c8b92.bin +-File: cirrus/cs35l41-dsp1-spk-cali-103c8b92.bin +-Link: cirrus/cs35l41-dsp1-spk-prot-103c8c26.bin -> cs35l41-dsp1-spk-prot-103c8b45.bin +-Link: cirrus/cs35l41-dsp1-spk-cali-103c8c26.bin -> cs35l41-dsp1-spk-cali-103c8b45.bin +- +-License: Redistributable. See LICENSE.cirrus for details. +- +-Use of Cirrus Logic drivers, firmware and other materials is permitted +-only in connection with Cirrus Logic hardware products. +- +-Copyright © 2022 Cirrus Logic, Inc. and Cirrus Logic International +-Semiconductor Ltd. All Rights Reserved. +- +---------------------------------------------------------------------------- +- +-Driver: mtk-sof - MediaTek Sound Open Firmware driver +- +-File: mediatek/sof/sof-mt8186.ri +-File: mediatek/sof/sof-mt8186.ldc +-File: mediatek/sof-tplg/sof-mt8186.tplg +-Version: v0.2.1 +- +-File: mediatek/sof/sof-mt8195.ri +-File: mediatek/sof/sof-mt8195.ldc +-File: mediatek/sof-tplg/sof-mt8195-mt6359-rt1019-rt5682.tplg +-File: mediatek/sof-tplg/sof-mt8195-mt6359-rt1019-rt5682-dts.tplg +-Version: v0.4.1 +- +-Licence: Redistributable. See LICENCE.mediatek for details. +- +--------------------------------------------------------------------------- +- + Driver: nxp-sr1xx - NXP Ultra Wide Band driver + File: nxp/sr150_fw.bin + Version: 35.00.03 +-- +2.40.1 + diff --git a/packages/linux-firmware/0002-linux-firmware-video-Remove-firmware-for-video-broad.patch b/packages/linux-firmware/0002-linux-firmware-video-Remove-firmware-for-video-broad.patch new file mode 100644 index 00000000..ad4b0ea6 --- /dev/null +++ b/packages/linux-firmware/0002-linux-firmware-video-Remove-firmware-for-video-broad.patch @@ -0,0 +1,1630 @@ +From 80d430aa70fec3a2d0fdbe59f3a102c8aeaa564a Mon Sep 17 00:00:00 2001 +From: Leonard Foerster +Date: Tue, 25 Jul 2023 09:43:12 +0000 +Subject: [PATCH] linux-firmware: video: Remove firmware for video/broadcast + devices + +Bottlerocket does not configure any special video encoding/decoding +hardware, DVB/DAB tuner, TV cards, and V4L2 hardware. We do not need +to ship firmware for devices we do not ship drivers for. The following +list maps the drivers as named in WHENCE to kernel config options to +easily check if we need to ship additional firmware in the future. + +* cpia2 - CONFIG_VIDEO_CPIA2 +* dabusb - CONFIG_USB_DABUSB (not available since 2.6.39) +* vicam - CONFIG_USB_GSPCA_VICAM +* ipu3-imgu - CONFIG_VIDEO_IPU3_IMGU +* cx231xx - CONFIG_VIDEO_CX231XX +* cx23418 - CONFIG_VIDEO_CX18 +* cx23885 - CONFIG_VIDEO_CX23885 +* cx25840 - CONFIG_VIDEO_CX25840 +* mtk-vpu - CONFIG_VIDEO_MEDIATEK_VPU +* ti-vpe - CONFIG_VIDEO_TI_VPE +* tlg2300 - CONFIG_VIDEO_TLG2300 +* s5p-mfc - CONFIG_VIDEO_SAMSUNG_S5P_MFC +* go7007 - CONFIG_VIDEO_GO7007 +* venus - CONFIG_VIDEO_QCOM_VENUS +* meson-vdec - CONFIG_VIDEO_MESON_VDEC +* wave5 - CONFIG_VIDEO_WAVE_VPU (driver not yet included upstream) +* amphion - CONFIG_VIDEO_AMPHION_VPU +* dvb-ttusb-budget - CONFIG_DVB_TTUSB_BUDGET +* dvb-ttpci - CONFIG_DVB_AV7110 +* xc4000 - CONFIG_MEDIA_TUNER_XC4000 +* xc5000 - CONFIG_MEDIA_TUNER_XC5000 +* dib0700 - CONFIG_DVB_USB_DIB0700 +* lsg8gxx - CONFIG_DVB_LGS8GXX +* drxk - CONFIG_DVB_DRXK +* as102 - CONFIG_DVB_AS102 +* it9135 - CONFIG_MEDIA_TUNER_IT913X +* smsmdtv - CONFIG_SMS_SIANO_MDTV +* tegra-vix - CONFIG_DRM_TEGRA +* rk3399-dptx - CONFIG_ROCKCHIP_CDN_DP +* cdns-mhdp - CONFIG_DRM_CDNS_MHDP8546 +* lt9611uxc - CONFIG_DRM_LONTIUM_LT9611UXC + +Signed-off-by: Leonard Foerster +--- + LICENCE.Abilis | 22 -- + LICENCE.cadence | 63 ------ + LICENCE.cnm | 23 --- + LICENCE.go7007 | 457 ------------------------------------------ + LICENCE.it913x | 17 -- + LICENCE.rockchip | 41 ---- + LICENCE.siano | 31 --- + LICENCE.ti-tspa | 46 ----- + LICENCE.xc4000 | 23 --- + LICENCE.xc5000 | 23 --- + LICENCE.xc5000c | 23 --- + LICENSE.Lontium | 2 - + LICENSE.amlogic_vdec | 15 -- + LICENSE.amphion_vpu | 48 ----- + LICENSE.dib0700 | 22 -- + LICENSE.ipu3_firmware | 36 ---- + WHENCE | 400 ------------------------------------ + 17 files changed, 1292 deletions(-) + delete mode 100644 LICENCE.Abilis + delete mode 100644 LICENCE.cadence + delete mode 100644 LICENCE.cnm + delete mode 100644 LICENCE.go7007 + delete mode 100644 LICENCE.it913x + delete mode 100644 LICENCE.rockchip + delete mode 100644 LICENCE.siano + delete mode 100644 LICENCE.ti-tspa + delete mode 100644 LICENCE.xc4000 + delete mode 100644 LICENCE.xc5000 + delete mode 100644 LICENCE.xc5000c + delete mode 100644 LICENSE.Lontium + delete mode 100644 LICENSE.amlogic_vdec + delete mode 100644 LICENSE.amphion_vpu + delete mode 100644 LICENSE.dib0700 + delete mode 100644 LICENSE.ipu3_firmware + +diff --git a/LICENCE.Abilis b/LICENCE.Abilis +deleted file mode 100644 +index 9050d2b..0000000 +--- a/LICENCE.Abilis ++++ /dev/null +@@ -1,22 +0,0 @@ +-Firmware provided by Pierrick Hascoet to Devin +-Heitmueller on January 15, 2010. +- +-The USB firmware files "dvb-as102_data1_st.hex" and "as102_data2_st.hex" for +-Abilis's AS10X, used together with the AS10X USB Kernel driver, is provided +-under the following licensing terms: +- +-Copyright (c) 2010, Abilis Systems Sarl +- +-Permission to use, copy, modify, and/or distribute this software for +-any purpose with or without fee is hereby granted, provided that the +-above copyright notice and this permission notice appear in all +-copies. +- +-THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL +-WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED +-WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE +-AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL +-DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR +-PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER +-TORTUOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR +-PERFORMANCE OF THIS SOFTWARE. +diff --git a/LICENCE.cadence b/LICENCE.cadence +deleted file mode 100644 +index b3564c2..0000000 +--- a/LICENCE.cadence ++++ /dev/null +@@ -1,63 +0,0 @@ +-Copyright (c) 2018, Cadence Design Systems, Inc. +-All rights reserved. +- +-Redistribution. Redistribution and use in binary form, without +-modification, are permitted provided that the following conditions are +-met: +- +-* Redistributions must reproduce the above copyright notice and the +- following disclaimer in the documentation and/or other materials +- provided with the distribution. +- +-* Neither the name of Cadence Design Systems, Inc., its products +- nor the names of its suppliers may be used to endorse or promote products +- derived from this Software without specific prior written permission. +- +-* No reverse engineering, decompilation, or disassembly of this software +- is permitted. +- +-DISCLAIMER. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND +-CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, +-BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND +-FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE +-COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, +-INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, +-BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS +-OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +-ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR +-TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE +-USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH +-DAMAGE. +- +-This software contains: +- +-HDCP Cipher is licensed under the FreeBSD license. A copy of the FreeBSD +-license can be found at +-https://www.freebsd.org/copyright/freebsd-license.html. +-The source code for HDCP Cipher can is available here: +-http://www3.cs.stonybrook.edu/~rob/hdcp.html +- +-SSL Library is licensed under the Apache License, Version 2.0. +-A copy of the Apache License, Version 2.0 can be found at +-http://www.apache.org/licenses/LICENSE-2.0. +-The original source code for SSL Library can is available here: +-https://tls.mbed.org/download +- +-Fast discrete Fourier and cosine transforms and inverses +-author: Monty +-modifications by: Monty +-last modification date: Jul 1 1996 +- +-/* These Fourier routines were originally based on the Fourier +-routines of the same names from the NETLIB bihar and fftpack +-fortran libraries developed by Paul N. Swarztrauber at the National +-Center for Atmospheric Research in Boulder, CO USA. They have been +-reimplemented in C and optimized in a few ways for OggSquish. */ +- +-/* As the original fortran libraries are public domain, the C Fourier +-routines in this file are hereby released to the public domain as +-well. The C routines here produce output exactly equivalent to the +-original fortran routines. Of particular interest are the facts +-that (like the original fortran), these routines can work on +-arbitrary length vectors that need not be powers of two in +-length. */ +diff --git a/LICENCE.cnm b/LICENCE.cnm +deleted file mode 100644 +index 48d23ea..0000000 +--- a/LICENCE.cnm ++++ /dev/null +@@ -1,23 +0,0 @@ +-Copyright (C) 2021 Chips&Media, Inc. +-All rights reserved. +- +-Redistribution and use in binary form is permitted provided that the following +-conditions are met: +- +-1. Redistributions must reproduce the above copyright notice, this list of +-conditions and the following disclaimer in the documentation and/or other +-materials provided with the distribution. +- +-2. Redistribution and use shall be used only with Texas Instruments Incorporateds +-silicon products. Any other use, reproduction, modification, translation, +-or compilation of the Software is prohibited. +- +-3. No reverse engineering, decompilation, or disassembly is permitted. +- +-TO THE MAXIMUM EXTENT PERMITTED BY APPLICABLE LAW, THIS SOFTWARE IS PROVIDED +-"AS IS" WITHOUT WARRANTY OF ANY KIND, INCLUDING, WITHOUT LIMITATION, ANY EXPRESS +-OR IMPLIED WARRANTIES OF MERCHANTABILITY, ACCURACY, FITNESS OR SUFFICIENCY FOR A +-PARTICULAR PURPOSE, SATISFACTORY QUALITY, CORRESPONDENCE WITH DESCRIPTION, QUIET +-ENJOYMENT OR NON-INFRINGEMENT OF THIRD PARTY INTELLECTUAL PROPERTY RIGHTS. +-CHIPS&MEDIA, INC., ITS AFFILIATES AND THEIR SUPPLIERS DISCLAIM ANY WARRANTY THAT THE +-DELIVERABLES WILL OPERATE WITHOUT INTERRUPTION OR BE ERROR-FREE. +diff --git a/LICENCE.go7007 b/LICENCE.go7007 +deleted file mode 100644 +index 3689f3b..0000000 +--- a/LICENCE.go7007 ++++ /dev/null +@@ -1,457 +0,0 @@ +-The README file from the original package from Micronas appears below. Only +-the part about the firmware redistribution in section 0 is relevant, all +-other sections are completely obsolete. +- +---------------------------------------------------------------------------- +- WIS GO7007SB Public Linux Driver +---------------------------------------------------------------------------- +- +- +-*** Please see the file RELEASE-NOTES for important last-minute updates *** +- +- +- 0. OVERVIEW AND LICENSING/DISCLAIMER +- +- +-This driver kit contains Linux drivers for the WIS GO7007SB multi-format +-video encoder. Only kernel version 2.6.x is supported. The video stream +-is available through the Video4Linux2 API and the audio stream is available +-through the ALSA API (or the OSS emulation layer of the ALSA system). +- +-The files in kernel/ and hotplug/ are licensed under the GNU General Public +-License Version 2 from the Free Software Foundation. A copy of the license +-is included in the file COPYING. +- +-The example applications in apps/ and C header files in include/ are +-licensed under a permissive license included in the source files which +-allows copying, modification and redistribution for any purpose without +-attribution. +- +-The firmware files included in the firmware/ directory may be freely +-redistributed only in conjunction with this document; but modification, +-tampering and reverse engineering are prohibited. +- +-MICRONAS USA, INC., MAKES NO WARRANTIES TO ANY PERSON OR ENTITY WITH +-RESPECT TO THE SOFTWARE OR ANY DERIVATIVES THEREOF OR ANY SERVICES OR +-LICENSES AND DISCLAIMS ALL IMPLIED WARRANTIES, INCLUDING WITHOUT LIMITATION +-WARRANTIES OF MERCHANTABILITY, SUPPORT, AND FITNESS FOR A PARTICULAR +-PURPOSE AND NON-INFRINGEMENT. +- +- +- 1. SYSTEM REQUIREMENTS +- +- +-This driver requires Linux kernel 2.6. Kernel 2.4 is not supported. Using +-kernel 2.6.10 or later is recommended, as earlier kernels are known to have +-unstable USB 2.0 support. +- +-A fully built kernel source tree must be available. Typically this will be +-linked from "/lib/modules//build" for convenience. If this +-link does not exist, an extra parameter will need to be passed to the +-`make` command. +- +-All vendor-built kernels should already be configured properly. However, +-for custom-built kernels, the following options need to be enabled in the +-kernel as built-in or modules: +- +- CONFIG_HOTPLUG - Support for hot-pluggable devices +- CONFIG_MODULES - Enable loadable module support +- CONFIG_KMOD - Automatic kernel module loading +- CONFIG_FW_LOADER - Hotplug firmware loading support +- CONFIG_I2C - I2C support +- CONFIG_VIDEO_DEV - Video For Linux +- CONFIG_SOUND - Sound card support +- CONFIG_SND - Advanced Linux Sound Architecture +- CONFIG_USB - Support for Host-side USB +- CONFIG_USB_DEVICEFS - USB device filesystem +- CONFIG_USB_EHCI_HCD - EHCI HCD (USB 2.0) support +- +-Additionally, to use the example application, the following options need to +-be enabled in the ALSA section: +- +- CONFIG_SND_MIXER_OSS - OSS Mixer API +- CONFIG_SND_PCM_OSS - OSS PCM (digital audio) API +- +-The hotplug scripts, along with the fxload utility, must also be installed. +-These scripts can be obtained from . +-Hotplugging is used for loading firmware into the Cypruss EZ-USB chip using +-fxload and for loading firmware into the driver using the firmware agent. +- +- +- 2. COMPILING AND INSTALLING THE DRIVER +- +- +-Most users should be able to compile the driver by simply running: +- +- $ make +- +-in the top-level directory of the driver kit. First the kernel modules +-will be built, followed by the example applications. +- +-If the build system is unable to locate the kernel source tree for the +-currently-running kernel, or if the module should be built for a kernel +-other than the currently-running kernel, an additional parameter will need +-to be passed to make to specify the appropriate kernel source directory: +- +- $ make KERNELSRC=/usr/src/linux-2.6.10-custom3 +- +-Once the compile completes, the driver and firmware files should be +-installed by running: +- +- $ make install +- +-The kernel modules will be placed in "/lib/modules//extra" +-and the firmware files will be placed in the appropriate hotplug firmware +-directory, usually /lib/firmware. In addition, USB maps and scripts will +-be placed in /etc/hotplug/usb to enable fxload to initialize the EZ-USB +-control chip when the device is connected. +- +- +- 3. PAL/SECAM TUNER CONFIGURATION (TV402U-EU only) +- +- +-The PAL model of the Plextor ConvertX TV402U may require additional +-configuration to correctly select the appropriate TV frequency band and +-audio subchannel. +- +-Users with a device other than the Plextor ConvertX TV402U-EU should skip +-this section. +- +-The wide variety of PAL TV systems used in Europe requires that additional +-information about the local TV standards be passed to the driver in order +-to properly tune TV channels. The two necessary parameters are (a) the PAL +-TV band, and (b) the audio subchannel format in use. +- +-In many cases, the appropriate TV band selection is passed to the driver +-from applications. However, in some cases, the application only specifies +-that the driver should use PAL but not the specific information about the +-appropriate TV band. To work around this issue, the correct TV band may be +-specified in the "force_band" parameter to the wis-sony-tuner module: +- +- TV band force_band +- ------- ---------- +- PAL B/G B +- PAL I I +- PAL D/K D +- SECAM L L +- +-If the "force_band" parameter is specified, the driver will ignore any TV +-band specified by applications and will always use the band provided in the +-module parameter. +- +-The other parameter that can be specified is the audio subchannel format. +-There are several stereo audio carrier systems in use, including NICAM and +-three varieties of A2. To receive audio broadcast on one of these stereo +-carriers, the "force_mpx_mode" parameter must be specified to the +-wis-sony-tuner module. +- +- TV band Audio subcarrier force_mpx_mode +- ------- ---------------- -------------- +- PAL B/G Mono (default) 1 +- PAL B/G A2 2 +- PAL B/G NICAM 3 +- PAL I Mono (default) 4 +- PAL I NICAM 5 +- PAL D/K Mono (default) 6 +- PAL D/K A2 (1) 7 +- PAL D/K A2 (2) 8 +- PAL D/K A2 (3) 9 +- PAL D/K NICAM 10 +- SECAM L Mono (default) 11 +- SECAM L NICAM 12 +- +-If the "force_mpx_mode" parameter is not specified, the correct mono-only +-mode will be chosen based on the TV band. However, the tuner will not +-receive stereo audio or bilingual broadcasts correctly. +- +-To pass the "force_band" or "force_mpx_mode" parameters to the +-wis-sony-tuner module, the following line must be added to the modprobe +-configuration file, which varies from one Linux distribution to another. +- +- options wis-sony-tuner force_band=B force_mpx_mode=2 +- +-The above example would force the tuner to the PAL B/G TV band and receive +-stereo audio broadcasts on the A2 carrier. +- +-To verify that the configuration has been placed in the correct location, +-execute: +- +- $ modprobe -c | grep wis-sony-tuner +- +-If the configuration line appears, then modprobe will pass the parameters +-correctly the next time the wis-sony-tuner module is loaded into the +-kernel. +- +- +- 4. TESTING THE DRIVER +- +- +-Because few Linux applications are able to correctly capture from +-Video4Linux2 devices with only compressed formats supported, the new driver +-should be tested with the "gorecord" application in the apps/ directory. +- +-First connect a video source to the device, such as a DVD player or VCR. +-This will be captured to a file for testing the driver. If an input source +-is unavailable, a test file can still be captured, but the video will be +-black and the audio will be silent. +- +-This application will auto-detect the V4L2 and ALSA/OSS device names of the +-hardware and will record video and audio to an AVI file for a specified +-number of seconds. For example: +- +- $ apps/gorecord -duration 60 capture.avi +- +-If this application does not successfully record an AVI file, the error +-messages produced by gorecord and recorded in the system log (usually in +-/var/log/messages) should provide information to help resolve the problem. +- +-Supplying no parameters to gorecord will cause it to probe the available +-devices and exit. Use the -help flag for usage information. +- +- +- 5. USING THE DRIVER +- +- +-The V4L2 device implemented by the driver provides a standard compressed +-format API, within the following criteria: +- +- * Applications that only support the original Video4Linux1 API will not +- be able to communicate with this driver at all. +- +- * No raw video modes are supported, so applications like xawtv that +- expect only uncompressed video will not function. +- +- * Supported compression formats are: Motion-JPEG, MPEG1, MPEG2 and MPEG4. +- +- * MPEG video formats are delivered as Video Elementary Streams only. +- Program Stream (PS), Transport Stream (TS) and Packetized Elementary +- Stream (PES) formats are not supported. +- +- * Video parameters such as format and input port may not be changed while +- the encoder is active. +- +- * The audio capture device only functions when the video encoder is +- actively capturing video. Attempts to read from the audio device when +- the encoder is inactive will result in an I/O error. +- +- * The native format of the audio device is 48Khz 2-channel 16-bit +- little-endian PCM, delivered through the ALSA system. No audio +- compression is implemented in the hardware. ALSA may convert to other +- uncompressed formats on the fly. +- +-The include/ directory contains a C header file describing non-standard +-features of the GO7007SB encoder, which are described below: +- +- +- GO7007IOC_S_COMP_PARAMS, GO7007IOC_G_COMP_PARAMS +- +- These ioctls are used to negotiate general compression parameters. +- +- To query the current parameters, call the GO7007IOC_G_COMP_PARAMS ioctl +- with a pointer to a struct go7007_comp_params. If the driver is not +- set to MPEG format, the EINVAL error code will be returned. +- +- To change the current parameters, initialize all fields of a struct +- go7007_comp_params and call the GO7007_IOC_S_COMP_PARAMS ioctl with a +- pointer to this structure. The driver will return the current +- parameters with any necessary changes to conform to the limitations of +- the hardware or current compression mode. Any or all fields can be set +- to zero to request a reasonable default value. If the driver is not +- set to MPEG format, the EINVAL error code will be returned. When I/O +- is in progress, the EBUSY error code will be returned. +- +- Fields in struct go7007_comp_params: +- +- __u32 The maximum number of frames in each +- gop_size Group Of Pictures; i.e. the maximum +- number of frames minus one between +- each key frame. +- +- __u32 The maximum number of sequential +- max_b_frames bidirectionally-predicted frames. +- (B-frames are not yet supported.) +- +- enum go7007_aspect_ratio The aspect ratio to be encoded in the +- aspect_ratio meta-data of the compressed format. +- +- Choices are: +- GO7007_ASPECT_RATIO_1_1 +- GO7007_ASPECT_RATIO_4_3_NTSC +- GO7007_ASPECT_RATIO_4_3_PAL +- GO7007_ASPECT_RATIO_16_9_NTSC +- GO7007_ASPECT_RATIO_16_9_PAL +- +- __u32 Bit-wise OR of control flags (below) +- flags +- +- Flags in struct go7007_comp_params: +- +- GO7007_COMP_CLOSED_GOP Only produce self-contained GOPs, used +- to produce streams appropriate for +- random seeking. +- +- GO7007_COMP_OMIT_SEQ_HEADER Omit the stream sequence header. +- +- +- GO7007IOC_S_MPEG_PARAMS, GO7007IOC_G_MPEG_PARAMS +- +- These ioctls are used to negotiate MPEG-specific stream parameters when +- the pixelformat has been set to V4L2_PIX_FMT_MPEG. +- +- To query the current parameters, call the GO7007IOC_G_MPEG_PARAMS ioctl +- with a pointer to a struct go7007_mpeg_params. If the driver is not +- set to MPEG format, the EINVAL error code will be returned. +- +- To change the current parameters, initialize all fields of a struct +- go7007_mpeg_params and call the GO7007_IOC_S_MPEG_PARAMS ioctl with a +- pointer to this structure. The driver will return the current +- parameters with any necessary changes to conform to the limitations of +- the hardware or selected MPEG mode. Any or all fields can be set to +- zero to request a reasonable default value. If the driver is not set +- to MPEG format, the EINVAL error code will be returned. When I/O is in +- progress, the EBUSY error code will be returned. +- +- Fields in struct go7007_mpeg_params: +- +- enum go7007_mpeg_video_standard +- mpeg_video_standard The MPEG video standard in which to +- compress the video. +- +- Choices are: +- GO7007_MPEG_VIDEO_MPEG1 +- GO7007_MPEG_VIDEO_MPEG2 +- GO7007_MPEG_VIDEO_MPEG4 +- +- __u32 Bit-wise OR of control flags (below) +- flags +- +- __u32 The profile and level indication to be +- pali stored in the sequence header. This +- is only used as an indicator to the +- decoder, and does not affect the MPEG +- features used in the video stream. +- Not valid for MPEG1. +- +- Choices for MPEG2 are: +- GO7007_MPEG2_PROFILE_MAIN_MAIN +- +- Choices for MPEG4 are: +- GO7007_MPEG4_PROFILE_S_L0 +- GO7007_MPEG4_PROFILE_S_L1 +- GO7007_MPEG4_PROFILE_S_L2 +- GO7007_MPEG4_PROFILE_S_L3 +- GO7007_MPEG4_PROFILE_ARTS_L1 +- GO7007_MPEG4_PROFILE_ARTS_L2 +- GO7007_MPEG4_PROFILE_ARTS_L3 +- GO7007_MPEG4_PROFILE_ARTS_L4 +- GO7007_MPEG4_PROFILE_AS_L0 +- GO7007_MPEG4_PROFILE_AS_L1 +- GO7007_MPEG4_PROFILE_AS_L2 +- GO7007_MPEG4_PROFILE_AS_L3 +- GO7007_MPEG4_PROFILE_AS_L4 +- GO7007_MPEG4_PROFILE_AS_L5 +- +- Flags in struct go7007_mpeg_params: +- +- GO7007_MPEG_FORCE_DVD_MODE Force all compression parameters and +- bitrate control settings to comply +- with DVD MPEG2 stream requirements. +- This overrides most compression and +- bitrate settings! +- +- GO7007_MPEG_OMIT_GOP_HEADER Omit the GOP header. +- +- GO7007_MPEG_REPEAT_SEQHEADER Repeat the MPEG sequence header at +- the start of each GOP. +- +- +- GO7007IOC_S_BITRATE, GO7007IOC_G_BITRATE +- +- These ioctls are used to set and query the target bitrate value for the +- compressed video stream. The bitrate may be selected by storing the +- target bits per second in an int and calling GO7007IOC_S_BITRATE with a +- pointer to the int. The bitrate may be queried by calling +- GO7007IOC_G_BITRATE with a pointer to an int where the current bitrate +- will be stored. +- +- Note that this is the primary means of controlling the video quality +- for all compression modes, including V4L2_PIX_FMT_MJPEG. The +- VIDIOC_S_JPEGCOMP ioctl is not supported. +- +- +----------------------------------------------------------------------------- +- Installing the WIS PCI Voyager Driver +---------------------------------------------------------------------------- +- +-The WIS PCI Voyager driver requires several patches to the Linux 2.6.11.x +-kernel source tree before compiling the driver. These patches update the +-in-kernel SAA7134 driver to the newest development version and patch bugs +-in the TDA8290/TDA8275 tuner driver. +- +-The following patches must be downloaded from Gerd Knorr's website and +-applied in the order listed: +- +- http://dl.bytesex.org/patches/2.6.11-2/i2c-tuner +- http://dl.bytesex.org/patches/2.6.11-2/i2c-tuner2 +- http://dl.bytesex.org/patches/2.6.11-2/v4l2-api-mpeg +- http://dl.bytesex.org/patches/2.6.11-2/saa7134-update +- +-The following patches are included with this SDK and can be applied in any +-order: +- +- patches/2.6.11/saa7134-voyager.diff +- patches/2.6.11/tda8275-newaddr.diff +- patches/2.6.11/tda8290-ntsc.diff +- +-Check to make sure the CONFIG_VIDEO_SAA7134 option is enabled in the kernel +-configuration, and build and install the kernel. +- +-After rebooting into the new kernel, the GO7007 driver can be compiled and +-installed: +- +- $ make SAA7134_BUILD=y +- $ make install +- $ modprobe saa7134-go7007 +- +-There will be two V4L video devices associated with the PCI Voyager. The +-first device (most likely /dev/video0) provides access to the raw video +-capture mode of the SAA7133 device and is used to configure the source +-video parameters and tune the TV tuner. This device can be used with xawtv +-or other V4L(2) video software as a standard uncompressed device. +- +-The second device (most likely /dev/video1) provides access to the +-compression functions of the GO7007. It can be tested using the gorecord +-application in the apps/ directory of this SDK: +- +- $ apps/gorecord -vdevice /dev/video1 -noaudio test.avi +- +-Currently the frame resolution is fixed at 720x480 (NTSC) or 720x576 (PAL), +-and the video standard must be specified to both the raw and the compressed +-video devices (xawtv and gorecord, for example). +- +- +--------------------------------------------------------------------------- +-RELEASE NOTES FOR WIS GO7007SB LINUX DRIVER +---------------------------------------------------------------------------- +- +-Last updated: 5 November 2005 +- +- - Release 0.9.7 includes new support for using udev to run fxload. The +- install script should automatically detect whether the old hotplug +- scripts or the new udev rules should be used. To force the use of +- hotplug, run "make install USE_UDEV=n". To force the use of udev, run +- "make install USE_UDEV=y". +- +- - Motion detection is supported but undocumented. Try the `modet` app +- for a demonstration of how to use the facility. +- +- - Using USB2.0 devices such as the TV402U with USB1.1 HCDs or hubs can +- cause buffer overruns and frame drops, even at low framerates, due to +- inconsistency in the bitrate control mechanism. +- +- - On devices with an SAA7115, including the Plextor ConvertX, video height +- values of 96, 128, 160, 192, 256, 320, and 384 do not work in NTSC mode. +- All valid heights up to 512 work correctly in PAL mode. +- +- - The WIS Star Trek and PCI Voyager boards have no support yet for audio +- or the TV tuner. +diff --git a/LICENCE.it913x b/LICENCE.it913x +deleted file mode 100644 +index ec8f56c..0000000 +--- a/LICENCE.it913x ++++ /dev/null +@@ -1,17 +0,0 @@ +-Copyright (c) 2014, ITE Tech. Inc. +- +-The firmware files "dvb-usb-it9135-01.fw" and "dvb-usb-it9135-02.fw" +-are for ITEtech it9135 Ax and Bx chip versions. +- +-Permission to use, copy, modify, and/or distribute this software for +-any purpose with or without fee is hereby granted, provided that the +-above copyright notice and this permission notice appear in all copies. +- +-THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +-WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +-MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE +-FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY +-DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, +-WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, +-ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS +-SOFTWARE. +diff --git a/LICENCE.rockchip b/LICENCE.rockchip +deleted file mode 100644 +index d23b4c4..0000000 +--- a/LICENCE.rockchip ++++ /dev/null +@@ -1,41 +0,0 @@ +-Copyright (c) 2016, Fuzhou Rockchip Electronics Co.Ltd +-All rights reserved. +- +-Redistribution. Redistribution and use in binary form, without +-modification, are permitted provided that the following conditions are +-met: +- +-* Redistributions must reproduce the above copyright notice and the +- following disclaimer in the documentation and/or other materials +- provided with the distribution. +- +-* Neither the name of Fuzhou Rockchip Electronics Co.Ltd, its products +- nor the names of its suppliers may be used to endorse or promote products +- derived from this Software without specific prior written permission. +- +-* No reverse engineering, decompilation, or disassembly of this software +- is permitted. +- +-Limited patent license. Fuzhou Rockchip Electronics Co.Ltd grants a world-wide, +-royalty-free, non-exclusive license under patents it now or hereafter +-owns or controls to make, have made, use, import, offer to sell and +-sell ("Utilize") this software, but solely to the extent that any +-such patent is necessary to Utilize the software alone, or in +-combination with an operating system licensed under an approved Open +-Source license as listed by the Open Source Initiative at +-http://opensource.org/licenses. The patent license shall not apply to +-any other combinations which include this software. No hardware per +-se is licensed hereunder. +- +-DISCLAIMER. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND +-CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, +-BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND +-FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE +-COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, +-INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, +-BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS +-OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +-ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR +-TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE +-USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH +-DAMAGE. +diff --git a/LICENCE.siano b/LICENCE.siano +deleted file mode 100644 +index 97e5440..0000000 +--- a/LICENCE.siano ++++ /dev/null +@@ -1,31 +0,0 @@ +-FIRMWARE LICENSE TERMS +- +-Copyright (c) 2005-2014 Siano Mobile Silicon Ltd. +-All rights reserved. +- +-Redistribution. Redistribution and use in binary form, without +-modification, are permitted provided that the following conditions are +-met: +- +-* Redistributions must reproduce the above copyright notice and the +-following disclaimer in the documentation and/or other materials +-provided with the distribution. +- +-* Neither the name of Siano Mobile Silicon Ltd. nor the names of its +-suppliers may be used to endorse or promote products derived from this +-software without specific prior written permission. +- +-* No reverse engineering, decompilation, or disassembly of this software +-is permitted. +- +-DISCLAIMER. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND +-CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, +-BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND +-FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE +-COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, +-INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT +-NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF +-USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON +-ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +-(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF +-THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE +diff --git a/LICENCE.ti-tspa b/LICENCE.ti-tspa +deleted file mode 100644 +index 728fc2b..0000000 +--- a/LICENCE.ti-tspa ++++ /dev/null +@@ -1,46 +0,0 @@ +-TI TSPA License +-TECHNOLOGY AND SOFTWARE PUBLICLY AVAILABLE +-SOFTWARE LICENSE +- +-Copyright (c) 2020, Texas Instruments Incorporated. +- +-All rights reserved not granted herein. +- +-Limited License. +- +-Texas Instruments Incorporated grants a world-wide, royalty-free, non-exclusive +-license under copyrights and patents it now or hereafter owns or controls to +-make, have made, use, import, offer to sell and sell ("Utilize") this software, +-but solely to the extent that any such patent is necessary to Utilize the +-software alone. The patent license shall not apply to any combinations which +-include this software. No hardware per se is licensed hereunder. +- +-Redistribution and use in binary form, without modification, are permitted +-provided that the following conditions are met: +- +-* Redistributions must preserve existing copyright notices and reproduce this +-license (including the above copyright notice and the disclaimer below) in the +-documentation and/or other materials provided with the distribution. +- +-* Neither the name of Texas Instruments Incorporated nor the names of its +-suppliers may be used to endorse or promote products derived from this software +-without specific prior written permission. +- +-* No reverse engineering, decompilation, or disassembly of this software is +-permitted. +- +-* Nothing shall obligate TI to provide you with source code for the software +-licensed and provided to you in object code. +- +-DISCLAIMER. +- +-THIS SOFTWARE IS PROVIDED BY TI AND TI’S LICENSORS "AS IS" AND ANY EXPRESS OR +-IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +-MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO +-EVENT SHALL TI AND TI’S LICENSORS BE LIABLE FOR ANY DIRECT, INDIRECT, +-INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +-LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR +-PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF +-LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING +-NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, +-EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +diff --git a/LICENCE.xc4000 b/LICENCE.xc4000 +deleted file mode 100644 +index e3cd261..0000000 +--- a/LICENCE.xc4000 ++++ /dev/null +@@ -1,23 +0,0 @@ +-The following XC4000 firmware file "dvb-fe-xc4000-1.4.1.fw" was +-created based on version 1.4 of "xc4000_firmwares.h". +- +-Firmware provided as part of an XC4000 Linux developers kit by Brian +-Mathews to Devin Heitmueller +- on July 1, 2009. +- +-The code was released by Xceive under the following license: +- +-// Copyright (c) 2009, Xceive Corporation +-// +-// Permission to use, copy, modify, and/or distribute this software, only +-// for use with Xceive ICs, for any purpose with or without fee is hereby +-// granted, provided that the above copyright notice and this permission +-// notice appear in all source code copies. +-// +-// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +-// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +-// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +-// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +-// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +-// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +-// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +diff --git a/LICENCE.xc5000 b/LICENCE.xc5000 +deleted file mode 100644 +index 0ac8557..0000000 +--- a/LICENCE.xc5000 ++++ /dev/null +@@ -1,23 +0,0 @@ +-The following XC500 firmware file "dvb-fe-xc5000-1.6.114.fw" was +-created based on "xc5000_firmwares_32000Khz.h". +- +-Firmware provided as part of an XC5000 Linux developers kit by Brian +-Mathews to Devin Heitmueller +-on July 1, 2009. +- +-The code was released by Xceive under the following license: +- +-// Copyright (c) 2009, Xceive Corporation +-// +-// Permission to use, copy, modify, and/or distribute this software, only +-// for use with Xceive ICs, for any purpose with or without fee is hereby +-// granted, provided that the above copyright notice and this permission +-// notice appear in all source code copies. +-// +-// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +-// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +-// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +-// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +-// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +-// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +-// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +diff --git a/LICENCE.xc5000c b/LICENCE.xc5000c +deleted file mode 100644 +index 23b81e7..0000000 +--- a/LICENCE.xc5000c ++++ /dev/null +@@ -1,23 +0,0 @@ +-The following XC500C firmware file "dvb-fe-xc5000C-4.1.30.7.fw" was created +-based on "Xc5200_firmwares_32000Khz.h". +- +-Firmware provided as part of an XC5000C Linux developers kit by Ramon Cazares +- to Devin Heitmueller dheitmueller@linuxtv.org +-on July 25, 2012. +- +-The code was released by Cresta Technology under the following license: +- +-// Copyright (c) 2012, Cresta Technology Corporation +-// +-// Permission to use, copy, modify, and/or distribute this software, only +-// for use with Cresta Technlogy ICs, for any purpose with or without fee is +-// hereby granted, provided that the above copyright notice and this +-// permission notice appear in all source code copies. +-// +-// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +-// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +-// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +-// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +-// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +-// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +-// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +diff --git a/LICENSE.Lontium b/LICENSE.Lontium +deleted file mode 100644 +index 2989473..0000000 +--- a/LICENSE.Lontium ++++ /dev/null +@@ -1,2 +0,0 @@ +-Lontium Semiconductor Corp. grants permission to use and redistribute aforementioned firmware file for the use with devices containing Lontium chipsets, but not as part of the Linux kernel or in any other form which would require the file itself to be covered by the terms of the GNU General Public License or the GNU Lesser General Public License. +-The firmware file is distributed in the hope that it will be useful, but is provided WITHOUT ANY WARRANTY, INCLUDING BUT NOT LIMITED TO IMPLIED WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. +diff --git a/LICENSE.amlogic_vdec b/LICENSE.amlogic_vdec +deleted file mode 100644 +index ac48f20..0000000 +--- a/LICENSE.amlogic_vdec ++++ /dev/null +@@ -1,15 +0,0 @@ +---------------------------------------------------------------------- +-Amlogic Co., Inc. grants permission to use and redistribute +-aforementioned firmware files for the use with devices containing +-Amlogic chipsets, but not as part of the Linux kernel or in any other +-form which would require these files themselves to be covered by the +-terms of the GNU General Public License or the GNU Lesser General +-Public License. +- +-These firmware files are distributed in the hope that they will be +-useful, but are provided WITHOUT ANY WARRANTY, INCLUDING BUT NOT +-LIMITED TO IMPLIED WARRANTY OF MERCHANTABILITY OR FITNESS FOR A +-PARTICULAR PURPOSE. +- +-Amlogic Contact: Arden Jin +---------------------------------------------------------------------- +diff --git a/LICENSE.amphion_vpu b/LICENSE.amphion_vpu +deleted file mode 100644 +index 31840ec..0000000 +--- a/LICENSE.amphion_vpu ++++ /dev/null +@@ -1,48 +0,0 @@ +-Copyright 2015, Amphion Semiconductor Ltd +-Copyright 2021, NXP +-All rights reserved. +- +-Redistribution. Reproduction and redistribution in binary form, without +-modification, for use solely in conjunction with a NXP +-chipset, is permitted provided that the following conditions are met: +- +- . Redistributions must reproduce the above copyright notice and the following +- disclaimer in the documentation and/or other materials provided with the +- distribution. +- +- . Neither the name of NXP nor the names of its suppliers +- may be used to endorse or promote products derived from this Software +- without specific prior written permission. +- +- . No reverse engineering, decompilation, or disassembly of this Software is +- permitted. +- +-Limited patent license. NXP (.Licensor.) grants you +-(.Licensee.) a limited, worldwide, royalty-free, non-exclusive license under +-the Patents to make, have made, use, import, offer to sell and sell the +-Software. No hardware per se is licensed hereunder. +-The term .Patents. as used in this agreement means only those patents or patent +-applications owned solely and exclusively by Licensor as of the date of +-Licensor.s submission of the Software and any patents deriving priority (i.e., +-having a first effective filing date) therefrom. The term .Software. as used in +-this agreement means the firmware image submitted by Licensor, under the terms +-of this license, to git://git.kernel.org/pub/scm/linux/kernel/git/firmware/ +-linux-firmware.git. +-Notwithstanding anything to the contrary herein, Licensor does not grant and +-Licensee does not receive, by virtue of this agreement or the Licensor's +-submission of any Software, any license or other rights under any patent or +-patent application owned by any affiliate of Licensor or any other entity +-(other than Licensor), whether expressly, impliedly, by virtue of estoppel or +-exhaustion, or otherwise. +- +-DISCLAIMER. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND +-CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, +-BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND +-FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL +-THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, +-INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, +-BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS +-OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +-ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR +-TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE +-USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +diff --git a/LICENSE.dib0700 b/LICENSE.dib0700 +deleted file mode 100644 +index fdb6bde..0000000 +--- a/LICENSE.dib0700 ++++ /dev/null +@@ -1,22 +0,0 @@ +-Firmware provided by Patrick Boettcher to Devin +-Heitmueller on October 8, 2009. +- +-The USB firmware file "dvb-usb-dib0700.1.20.fw" for DiBcom's DiB0700, +-used together with the Linux driver module dvb-usb-dib0700, is +-provided under the following licensing terms: +- +-Copyright (c) 2009, DiBcom +- +-Permission to use, copy, modify, and/or distribute this software for +-any purpose with or without fee is hereby granted, provided that the +-above copyright notice and this permission notice appear in all +-copies. +- +-THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL +-WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED +-WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE +-AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL +-DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR +-PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER +-TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR +-PERFORMANCE OF THIS SOFTWARE. +diff --git a/LICENSE.ipu3_firmware b/LICENSE.ipu3_firmware +deleted file mode 100644 +index 2559884..0000000 +--- a/LICENSE.ipu3_firmware ++++ /dev/null +@@ -1,36 +0,0 @@ +-Copyright (c) 2017, Intel Corporation. +-All rights reserved. +- +-Redistribution. Redistribution and use in binary form, without +-modification, are permitted provided that the following conditions are +-met: +- +-* Redistributions must reproduce the above copyright notice and the +- following disclaimer in the documentation and/or other materials +- provided with the distribution. +-* Neither the name of Intel Corporation nor the names of its suppliers +- may be used to endorse or promote products derived from this software +- without specific prior written permission. +-* No reverse engineering, decompilation, or disassembly of this software +- is permitted. +- +-Limited patent license. Intel Corporation grants a world-wide, +-royalty-free, non-exclusive license under patents it now or hereafter +-owns or controls to make, have made, use, import, offer to sell and +-sell (“Utilize”) this software, but solely to the extent that any +-such patent is necessary to Utilize the software alone. The patent license +-shall not apply to any combinations which include this software. No hardware +-per se is licensed hereunder. +- +-DISCLAIMER. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND +-CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, +-BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND +-FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE +-COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, +-INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, +-BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS +-OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +-ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR +-TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE +-USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH +-DAMAGE. +diff --git a/WHENCE b/WHENCE +index 116d04d..d78e45e 100644 +--- a/WHENCE ++++ b/WHENCE +@@ -53,16 +53,6 @@ Found in hex form in the kernel source. + + -------------------------------------------------------------------------- + +-Driver: dvb-ttusb-budget -- Technotrend/Hauppauge Nova-USB devices +- +-File: ttusb-budget/dspbootcode.bin +- +-Licence: Unknown +- +-Found in hex form in the kernel source. +- +--------------------------------------------------------------------------- +- + Driver: keyspan -- USB Keyspan USA-xxx serial device + + File: keyspan/mpr.fw +@@ -236,45 +226,6 @@ Converted from Intel HEX files, used in our binary representation of ihex. + + -------------------------------------------------------------------------- + +-Driver: cpia2 -- cameras based on Vision's CPiA2 +- +-File: cpia2/stv0672_vp4.bin +- +-Licence: Allegedly GPLv2+, but no source visible. Marked: +- Copyright (C) 2001 STMicroelectronics, Inc. +- Contact: steve.miller@st.com +- Description: This file contains patch data for the CPiA2 (stv0672) VP4. +- +-Found in hex form in kernel source. +- +--------------------------------------------------------------------------- +- +-Driver: dabusb -- Digital Audio Broadcasting (DAB) Receiver for USB and Linux +- +-File: dabusb/firmware.fw +-File: dabusb/bitstream.bin +- +-Licence: Distributable +- +- * Copyright (C) 1999 BayCom GmbH +- * +- * Redistribution and use in source and binary forms, with or without +- * modification, are permitted provided that redistributions of source +- * code retain the above copyright notice and this comment without +- * modification. +- +--------------------------------------------------------------------------- +- +-Driver: vicam -- USB 3com HomeConnect (aka vicam) +- +-File: vicam/firmware.fw +- +-Licence: Unknown +- +-Found in hex form in kernel source. +- +--------------------------------------------------------------------------- +- + Driver: io_edgeport - USB Inside Out Edgeport Serial Driver + + File: edgeport/boot.fw +@@ -1038,17 +989,6 @@ Also available from http://wireless.kernel.org/en/users/Drivers/iwlwifi#Firmware + + -------------------------------------------------------------------------- + +-Driver: ipu3-imgu - Intel IPU3 (3rd Gen Image Processing Unit) driver +- +-File: intel/irci_irci_ecr-master_20161208_0213_20170112_1500.bin +-Version: irci_irci_ecr-master_20161208_0213_20170112_1500 +-md5sum: 59abc311fce49c5a180b5a8a3917912d +-Link: intel/ipu3-fw.bin -> irci_irci_ecr-master_20161208_0213_20170112_1500.bin +- +-Licence: Redistributable. See LICENSE.ipu3_firmware for details +- +--------------------------------------------------------------------------- +- + Driver: tehuti - Tehuti Networks 10G Ethernet + + File: tehuti/bdx.bin +@@ -1203,36 +1143,6 @@ Found in hex form in kernel source. + + -------------------------------------------------------------------------- + +-Driver: cx231xx - Conexant Cx23100/101/102 USB broadcast A/V decoder +- +-File: v4l-cx231xx-avcore-01.fw +- +-Driver: cx23418 - Conexant PCI Broadcast A/V with MPEG encoder +- +-File: v4l-cx23418-apu.fw +-File: v4l-cx23418-cpu.fw +-File: v4l-cx23418-dig.fw +- +-Driver: cx23885 - Conexant PCI Express Broadcast A/V decoder +- +-File: v4l-cx23885-avcore-01.fw +- +-Driver: cx23840 - Conexant sideport Broadcast A/V decoder +- +-File: v4l-cx25840.fw +- +-Licence: Redistributable. +- +- Conexant grants permission to use and redistribute these firmware +- files for use with Conexant devices, but not as a part of the Linux +- kernel or in any other form which would require these files themselves +- to be covered by the terms of the GNU General Public License. +- These firmware files are distributed in the hope that they will be +- useful, but WITHOUT ANY WARRANTY; without even the implied warranty +- of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. +- +--------------------------------------------------------------------------- +- + Driver: qlogicpti - PTI Qlogic, ISP Driver + + File: qlogic/isp1000.bin +@@ -1316,18 +1226,6 @@ Available from http://ldriver.qlogic.com/firmware/netxen_nic/new/ + + -------------------------------------------------------------------------- + +-Driver: dvb-ttpci -- AV7110 cards +- +-File: av7110/bootcode.bin +-Source: av7110/Boot.S +-Source: av7110/Makefile +- +-Licence: GPLv2 or later. See GPL-2 and GPL-3 for details. +- +-ARM assembly source code from https://linuxtv.org/downloads/firmware/Boot.S +- +--------------------------------------------------------------------------- +- + Driver: rt61pci - Ralink RT2561, RT2561S, RT2661 wireless MACs + + File: rt2561.bin +@@ -1421,35 +1319,6 @@ Provided from the author, Bernd Porr + + -------------------------------------------------------------------------- + +-Driver: xc4000 - Xceive 4000 Tuner driver +- +-File: dvb-fe-xc4000-1.4.1.fw +-Version: 1.4.1 +- +-Licence: Redistributable. See LICENCE.xc4000 for details +- +--------------------------------------------------------------------------- +-Driver: xc5000 - Xceive 5000 Tuner driver +- +-File: dvb-fe-xc5000-1.6.114.fw +-Version: 1.6.114 +- +-File: dvb-fe-xc5000c-4.1.30.7.fw +-Version: 4.1.30.7 +- +-Licence: Redistributable. See LICENCE.xc5000 and LICENCE.xc5000c for details +- +--------------------------------------------------------------------------- +- +-Driver: dib0700 - DiBcom dib0700 USB DVB bridge driver +- +-File: dvb-usb-dib0700-1.20.fw +-Version: 1.20 +- +-Licence: Redistributable. See LICENSE.dib0700 for details +- +--------------------------------------------------------------------------- +- + Driver: ath3k - DFU Driver for Atheros bluetooth chipset AR3011 + + File: ath3k-1.fw +@@ -2387,14 +2256,6 @@ Licence: Redistributable, provided by Realtek in their driver + + -------------------------------------------------------------------------- + +-Driver: lgs8gxx - Legend Silicon GB20600 demodulator driver +- +-File: lgs8g75.fw +- +-Licence: Unknown +- +--------------------------------------------------------------------------- +- + Driver: ib_qib - QLogic Infiniband + + File: qlogic/sd7220.fw +@@ -2671,14 +2532,6 @@ Licence: GPLv2. See GPL-2 for details. + + -------------------------------------------------------------------------- + +-Driver: ti-vpe - Texas Instruments V4L2 driver for Video Processing Engine +- +-File: ti/vpdma-1b8.bin +- +-Licence: Redistributable. See LICENCE.ti-tspa for details. +- +--------------------------------------------------------------------------- +- + Driver: wl1251 - Texas Instruments 802.11 WLAN driver for WiLink4 chips + + File: ti-connectivity/wl1251-fw.bin +@@ -2807,23 +2660,6 @@ Licence: Redistributable. See LICENCE.ti-connectivity for details. + + -------------------------------------------------------------------------- + +-Driver: tlg2300 - Telgent 2300 V4L/DVB driver. +- +-File: tlg2300_firmware.bin +- +-Licence: Redistributable. +- +- Telegent System grants permission to use and redistribute these +- firmware files for use with devices containing the chip tlg2300, but +- not as a part of the Linux kernel or in any other form which would +- require these files themselves to be covered by the terms of the GNU +- General Public License. These firmware files are distributed in the +- hope that they will be useful, but WITHOUT ANY WARRANTY; without even +- the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR +- PURPOSE. +- +--------------------------------------------------------------------------- +- + Driver: r8712u - Realtek 802.11n WLAN driver for RTL8712U + + File: rtlwifi/rtl8712u.bin +@@ -3459,23 +3295,6 @@ License: Redistributable. See LICENCE.atheros_firmware for details + + -------------------------------------------------------------------------- + +-Driver: drxk - Micronas DRX-K demodulator driver +- +-File: dvb-usb-terratec-h5-drxk.fw +- +-Licence: Redistributable. +- +-TERRATEC grants permission to use and redistribute these firmware +-files for use with TERRATEC devices, but not as part of the Linux +-kernel or in any other form which would require these files themselves +-to be covered by the terms of the GNU General Public License. +- +-These firmware files are distributed in the hope that they will be +-useful, but WITHOUT ANY WARRANTY; without even the implied warranty +-of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. +- +--------------------------------------------------------------------------- +- + Driver: ene-ub6250 -- ENE UB6250 SD card reader driver + + File: ene-ub6250/sd_init1.bin +@@ -3506,27 +3325,6 @@ Licence: Redistributable. See LICENCE.atheros_firmware for details + + -------------------------------------------------------------------------- + +-Driver: s5p-mfc - Samsung MFC video encoder/decoder driver +- +-File: s5p-mfc.fw +-File: s5p-mfc-v6.fw +-File: s5p-mfc-v6-v2.fw +-File: s5p-mfc-v7.fw +-File: s5p-mfc-v8.fw +- +-Licence: Redistributable. +- +-Samsung grants permission to use and redistribute aforementioned firmware +-files for the use with Exynos series devices, but not as part of the Linux +-kernel, or in any other form which would require these files themselves +-to be covered by the terms of the GNU General Public License. +- +-These firmware files are distributed in the hope that they will be +-useful, but WITHOUT ANY WARRANTY; without even the implied warranty +-of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. +- +--------------------------------------------------------------------------- +- + Driver: carl9170 -- Atheros AR9170 802.11 draft-n USB driver + + File: carl9170-1.fw +@@ -3770,33 +3568,6 @@ of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + + -------------------------------------------------------------------------- + +-Driver: go7007 +- +-File: go7007/s2250-1.fw +-File: go7007/s2250-2.fw +-Link: s2250.fw -> go7007/s2250-2.fw +-Link: s2250_loader.fw -> go7007/s2250-1.fw +- +-Licence: +- Sensoray grants permission to use and redistribute these firmware +- files for use with Sensoray devices, but not as a part of the Linux +- kernel or in any other form which would require these files themselves +- to be covered by the terms of the GNU General Public License. +- These firmware files are distributed in the hope that they will be +- useful, but WITHOUT ANY WARRANTY; without even the implied warranty +- of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. +- +-File: go7007/go7007fw.bin +-File: go7007/go7007tv.bin +-File: go7007/lr192.fw +-File: go7007/px-m402u.fw +-File: go7007/px-tv402u.fw +-File: go7007/wis-startrek.fw +- +-Licence: Redistributable. See LICENCE.go7007 for details +- +--------------------------------------------------------------------------- +- + Driver: ccp - Platform Security Processor (PSP) device + + File: amd/amd_sev_fam17h_model0xh.sbin +@@ -3967,44 +3738,6 @@ Licence: Redistributable. See LICENCE.r8a779x_usb3 for details. + + -------------------------------------------------------------------------- + +-Driver: as102 - Abilis Systems Single DVB-T Receiver +- +-File: as102_data1_st.hex +-File: as102_data2_st.hex +- +-License: Redistributable. See LICENCE.Abilis for details +- +--------------------------------------------------------------------------- +- +-Driver: it9135 -- ITEtech IT913x DVB-T USB driver +- +-File: dvb-usb-it9135-01.fw +-File: dvb-usb-it9135-02.fw +- +-Licence: Redistributable. See LICENCE.it913x for details +- +--------------------------------------------------------------------------- +- +-Driver: smsmdtv - Siano MDTV Core module +- +-File: cmmb_vega_12mhz.inp +-File: cmmb_venice_12mhz.inp +-File: dvb_nova_12mhz.inp +-File: dvb_nova_12mhz_b0.inp +-File: isdbt_nova_12mhz.inp +-File: isdbt_nova_12mhz_b0.inp +-File: isdbt_rio.inp +-File: sms1xxx-hcw-55xxx-dvbt-02.fw +-File: sms1xxx-hcw-55xxx-isdbt-02.fw +-File: sms1xxx-nova-a-dvbt-01.fw +-File: sms1xxx-nova-b-dvbt-01.fw +-File: sms1xxx-stellar-dvbt-01.fw +-File: tdmb_nova_12mhz.inp +- +-Licence: Redistributable. See LICENCE.siano for details +- +--------------------------------------------------------------------------- +- + Driver: xhci-tegra -- NVIDIA Tegra XHCI driver + + File: nvidia/tegra124/xusb.bin +@@ -4023,23 +3756,6 @@ Licence: Redistributable. See LICENCE.nvidia for details + + -------------------------------------------------------------------------- + +-Driver: tegra-vic -- NVIDIA Tegra VIC driver +- +-File: nvidia/tegra124/vic03_ucode.bin +-Link: nvidia/tegra124/vic.bin -> vic03_ucode.bin +- +-File: nvidia/tegra210/vic04_ucode.bin +-Link: nvidia/tegra210/vic.bin -> vic04_ucode.bin +- +-File: nvidia/tegra186/vic04_ucode.bin +-Link: nvidia/tegra186/vic.bin -> vic04_ucode.bin +- +-File: nvidia/tegra194/vic.bin +- +-Licence: Redistributable. See LICENCE.nvidia for details +- +--------------------------------------------------------------------------- +- + Driver: atusb - ATUSB IEEE 802.15.4 transceiver driver + + File: atusb/atusb-0.2.dfu +@@ -4995,17 +4711,6 @@ Licence: Redistributable. See LICENCE.Marvell for details. + + -------------------------------------------------------------------------- + +-Driver: mtk-vpu - MediaTek VPU video processing unit driver +- +-File: mediatek/mt8173/vpu_d.bin +-File: mediatek/mt8173/vpu_p.bin +-Link: vpu_d.bin -> mediatek/mt8173/vpu_d.bin +-Link: vpu_p.bin -> mediatek/mt8173/vpu_p.bin +- +-Licence: Redistributable. See LICENCE.mediatek for details. +- +--------------------------------------------------------------------------- +- + Driver: mtk_scp - MediaTek SCP System Control Processing Driver + + File: mediatek/mt8183/scp.img +@@ -5035,15 +4740,6 @@ Licence: Redistributable. See LICENCE.mediatek for details. + + -------------------------------------------------------------------------- + +-Driver: rk3399-dptx - ROCKCHIP rk3399 dptx firmware +- +-File: rockchip/dptx.bin +-Version: 3.1 +- +-Licence: Redistributable. See LICENCE.rockchip for details. +- +--------------------------------------------------------------------------- +- + Driver: mt76x0 - MediaTek MT76x0 Wireless MACs + + File: mediatek/mt7610u.bin +@@ -5323,44 +5019,6 @@ Licence: Redistributable. See LICENSE.QualcommAtheros_ath10k for details + + -------------------------------------------------------------------------- + +-Driver: venus - Qualcomm Venus video codec accelerator +- +-File: qcom/venus-1.8/venus.mbn +-Link: qcom/venus-1.8/venus.mdt -> venus.mbn +- +-Version: 1.8-00109 +- +-File: qcom/venus-4.2/venus.mbn +-Link: qcom/venus-4.2/venus.mdt -> venus.mbn +- +-Version: 4.2 +- +-File: qcom/venus-5.2/venus.mbn +-Link: qcom/venus-5.2/venus.mdt -> venus.mbn +- +-Version: 5.2-00023 +- +-File: qcom/venus-5.4/venus.mbn +-Link: qcom/venus-5.4/venus.mdt -> venus.mbn +- +-Version: 5.4-00053 +- +-File: qcom/vpu-1.0/venus.mbn +-Link: qcom/vpu-1.0/venus.mdt -> venus.mbn +- +-Version: VIDEO.VPU.1.0-00087-PROD-1 +- +-File: qcom/vpu-2.0/venus.mbn +- +-Version: VIDEO.VPU.2.0-00049-PROD-1 +- +-Licence: Redistributable. See LICENSE.qcom and qcom/NOTICE.txt for details +- +-Binary files supplied originally from +-https://developer.qualcomm.com/hardware/dragonboard-410c/tools +- +--------------------------------------------------------------------------- +- + Driver: imx-sdma - support for i.MX SDMA driver + + File: imx/sdma/sdma-imx6q.bin +@@ -5582,15 +5240,6 @@ Licence: + + -------------------------------------------------------------------------- + +-Driver: cdns-mhdp - Cadence MHDP8546 DP bridge +- +-File: cadence/mhdp8546.bin +-Version: 2.1.0 +- +-Licence: Redistributable. See LICENCE.cadence for details +- +--------------------------------------------------------------------------- +- + Driver: fsl-mc bus - NXP Management Complex Bus Driver + + File: dpaa2/mc/mc_10.10.0_ls1088a.itb +@@ -5622,28 +5271,6 @@ Licence: Redistributable. See LICENCE.microchip for details + + -------------------------------------------------------------------------- + +-Driver: meson-vdec - Amlogic video decoder +- +-File: meson/vdec/g12a_h264.bin +-File: meson/vdec/g12a_hevc_mmu.bin +-File: meson/vdec/g12a_vp9.bin +-File: meson/vdec/gxbb_h264.bin +-File: meson/vdec/gxl_h263.bin +-File: meson/vdec/gxl_h264.bin +-File: meson/vdec/gxl_hevc.bin +-File: meson/vdec/gxl_hevc_mmu.bin +-File: meson/vdec/gxl_mjpeg.bin +-File: meson/vdec/gxl_mpeg12.bin +-File: meson/vdec/gxl_mpeg4_5.bin +-File: meson/vdec/gxl_vp9.bin +-File: meson/vdec/gxm_h264.bin +-File: meson/vdec/sm1_hevc_mmu.bin +-File: meson/vdec/sm1_vp9_mmu.bin +- +-Licence: Redistributable. See LICENSE.amlogic_vdec for details. +- +--------------------------------------------------------------------------- +- + Driver: ice - Intel(R) Ethernet Connection E800 Series + + File: intel/ice/ddp/ice-1.3.30.0.pkg +@@ -5685,14 +5312,6 @@ Licence: Redistributable. See LICENCE.Marvell for details. + + ------------------------------------------------ + +-Driver: lt9611uxc - Lontium DSI to HDMI bridge +- +-File: lt9611uxc_fw.bin +- +-License: Redistributable. See LICENSE.Lontium for details. +- +--------------------------------------------------------------------------- +- + Driver: wfx - Silicon Labs Wi-Fi Transceiver + + File: wfx/wfm_wf200_C0.sec +@@ -5713,14 +5332,6 @@ https://github.com/SiliconLabs/wfx-linux-tools + + -------------------------------------------------------------------------- + +-Driver: wave5 - Chips&Media, Inc. video codec driver +- +-File: cnm/wave521c_k3_codec_fw.bin +- +-Licence: Redistributable. See LICENCE.cnm for details. +- +---------------------------------------------------------------------------- +- + Driver: rvu_cptpf - Marvell CPT driver + + File: mrvl/cpt01/ae.out +@@ -5741,17 +5352,6 @@ Licence: Redistributable. See LICENCE.Marvell for details. + + --------------------------------------------------------------------------- + +-Driver: amphion - Amphion VPU(Video Processing Unit) Codec IP driver +- +-File: amphion/vpu/vpu_fw_imx8_dec.bin +-Version: 1.8.8 +-File: amphion/vpu/vpu_fw_imx8_enc.bin +-Version: 1.3.4 +- +-Licence: Redistributable. See LICENSE.amphion_vpu for details +- +---------------------------------------------------------------------------- +- + Driver: nxp-sr1xx - NXP Ultra Wide Band driver + File: nxp/sr150_fw.bin + Version: 35.00.03 +-- +2.40.1 + diff --git a/packages/linux-firmware/0003-linux-firmware-bt-wifi-Remove-firmware-for-Bluetooth.patch b/packages/linux-firmware/0003-linux-firmware-bt-wifi-Remove-firmware-for-Bluetooth.patch new file mode 100644 index 00000000..5d0bb05c --- /dev/null +++ b/packages/linux-firmware/0003-linux-firmware-bt-wifi-Remove-firmware-for-Bluetooth.patch @@ -0,0 +1,3657 @@ +From 8330b130d288943c11658a69c033e97f02a69591 Mon Sep 17 00:00:00 2001 +From: Leonard Foerster +Date: Tue, 25 Jul 2023 10:29:08 +0000 +Subject: [PATCH] linux-firmware: bt/wifi: Remove firmware for Bluetooth/WiFi + devices + +Bottlerocket does not configure any drivers for Bluetooth or WiFi +devices. Without the drivers the firmware is useless and does not need +to be shipped. The following list matches driver names as listed in +WHENCE to the kernel config options enabling those driver in case we do +add drivers in the future we can easily check if we need to add firmware +binaries. + +* ar9170 - CONFIG_CARL9170 +* carl9170 - CONFIG_CARL9170 +* ath9k_htc - CONFIG_ATH9K_HTC +* ath3k - CONFIG_BT_ATH3K +* DFU Driver [...] AR3012 - CONFIG_BT_ATH3K +* Atheros AR300x UART [...] - CONFIG_BT_HCIUART_ATH3K +* ath6kl - CONFIG_ATH6KL +* ath10k - CONFIG_ATH10K +* ath11k - CONFIG_ATH11K +* ar5523 - CONFIG_AR5523 +* btqca - CONFIG_BT_QCA +* qca - CONFIG_QCA7000 +* mt7601u - CONFIG_MT7601U +* btmtk_usb - CONFIG_BT_HCIBTUSB_MTK +* btmtk - CONFIG_BT_MTK +* mt76x0 - CONFIG_MT76x0U && CONFIG_MT76x0E +* mt76x2e - CONFIG_MT76x2E +* mt76x2u - CONFIG_MT76x2U +* mt7615e - CONFIG_MT7615E +* mt7622 - CONFIG_MT7622WMAC +* mt7663 - CONFIG_MT7663U && CONFIG_MT7663S +* mt7915e - CONFIG_MT7915E +* mt7921 - CONFIG_MT7921U && CONFIG_MT7921S && CONFIG_MT7921E +* mt7922 - CONFIG_MT7921U && CONFIG_MT7921S && CONFIG_MT7921E +* brcmsmac - CONFIG_BRCMSMAC +* brcmfmac - CONFIG_BRCMFMAC +* BCM-0bb4-0306 - CONFIG_BT_BCM +* wl1251 - CONFIG_WL1251 +* wl12xx - CONFIG_WL12XX +* wl18xx - CONFIG_WL18XX +* TI_ST - CONFIG_TI_ST +* r8152 - CONFIG_USB_RTL8152 +* r8169 - CONFIG_R8169 +* r8712u - CONFIG_R8712U +* rtl8188ee - CONFIG_RTL8188EE +* rtl8192e - CONFIG_RTL8192E +* rtl8192ce - CONFIG_RTL8192CE +* rtl8192cu - CONFIG_RTL8192CU +* rtl8192de - CONFIG_RTL8192DE +* rtl8192ee - CONFIG_RTL8192EE +* rtl8192se - CONFIG_RTL8192SE +* rtl8723be - CONFIG_RTL8723BE +* rtl8723bs - CONFIG_RTL8723BS +* rtl8723de - CONFIG_RTL8723_COMMON +* rtl8723e - CONFIG_RTL8723_COMMON +* rtl8821ae - CONFIG_RTL8821AE +* rtl8822be - CONFIG_RTW88_8822BE +* rtl8xxxu - CONFIG_RTL8XXXU +* rtw88 - CONFIG_RTW88 +* rtw89 - CONFIG_RTW89 +* btusb - CONFIG_BT_HCIBTUSB +* nxp-sr1xx - CONFIG_NXP_UWB (driver has yet to be accepted upstream) +* btnxpuart - CONFIG_BT_NXPUART +* cw1200 - CONFIG_CW1200 +* rsi - CONFIG_RSI_91X +* wilc1000 - CONFIG_WILC1000 +* qcom_q6v5_pas - CONFIG_QCOM_Q6V5_PAS +* qcom_q6v5_mss - CONFIG_QCOM_Q6V5_MSS +* iwlwifi - CONFIG_IWLWIFI +* rt2800pci - CONFIG_RT2800PCI +* rt2800usb - CONFIG_RT2800USB +* rt2860sta - CONFIG_RT2800PCI && CONFIG_RT2800USB +* rt2870sta - CONFIG_RT2800PCI && CONFIG_RT2800USB +* rt61pci - CONFIG_RT61PCI +* rt73usb - CONFIG_RT73USB +* wfx - CONFIG_WFX + +Signed-off-by: Leonard Foerster +--- + LICENCE.NXP | 22 - + LICENCE.OLPC | 33 - + LICENCE.atheros_firmware | 38 - + LICENCE.broadcom_bcm43xx | 65 - + LICENCE.cw1200 | 35 - + LICENCE.cypress | 138 -- + LICENCE.ibt_firmware | 39 - + LICENCE.iwlwifi_firmware | 39 - + LICENCE.open-ath9k-htc-firmware | 206 -- + LICENCE.ralink-firmware.txt | 39 - + LICENCE.ralink_a_mediatek_company_firmware | 39 - + LICENCE.rtlwifi_firmware.txt | 39 - + LICENCE.ti-connectivity | 61 - + LICENCE.wl1251 | 59 - + LICENSE.QualcommAtheros_ar3k | 47 - + LICENSE.QualcommAtheros_ath10k | 47 - + LICENSE.atmel | 36 - + LICENSE.nxp | 26 - + WHENCE | 2279 +------------------- + 19 files changed, 27 insertions(+), 3260 deletions(-) + delete mode 100644 LICENCE.NXP + delete mode 100644 LICENCE.OLPC + delete mode 100644 LICENCE.atheros_firmware + delete mode 100644 LICENCE.broadcom_bcm43xx + delete mode 100644 LICENCE.cw1200 + delete mode 100644 LICENCE.cypress + delete mode 100644 LICENCE.ibt_firmware + delete mode 100644 LICENCE.iwlwifi_firmware + delete mode 100644 LICENCE.open-ath9k-htc-firmware + delete mode 100644 LICENCE.ralink-firmware.txt + delete mode 100644 LICENCE.ralink_a_mediatek_company_firmware + delete mode 100644 LICENCE.rtlwifi_firmware.txt + delete mode 100644 LICENCE.ti-connectivity + delete mode 100644 LICENCE.wl1251 + delete mode 100644 LICENSE.QualcommAtheros_ar3k + delete mode 100644 LICENSE.QualcommAtheros_ath10k + delete mode 100644 LICENSE.atmel + delete mode 100644 LICENSE.nxp + +diff --git a/LICENCE.NXP b/LICENCE.NXP +deleted file mode 100644 +index 96215f1..0000000 +--- a/LICENCE.NXP ++++ /dev/null +@@ -1,22 +0,0 @@ +-Copyright 2019. NXP B.V. All rights reserved. +- +-Redistribution and use in binary form is permitted provided that the following +-conditions are met: +- +-1. Redistributions must reproduce the above copyright notice, this list of +-conditions and the following disclaimer in the documentation and/or other +-materials provided with the distribution. +- +-2. Redistribution and use shall be used only with NXP B.V. silicon products. +-Any other use, reproduction, modification, translation, or compilation of the +-Software is prohibited. +- +-3. No reverse engineering, decompilation, or disassembly is permitted. +- +-TO THE MAXIMUM EXTENT PERMITTED BY APPLICABLE LAW, THIS SOFTWARE IS PROVIDED +-"AS IS" WITHOUT WARRANTY OF ANY KIND, INCLUDING, WITHOUT LIMITATION, ANY EXPRESS +-OR IMPLIED WARRANTIES OF MERCHANTABILITY, ACCURACY, FITNESS OR SUFFICIENCY FOR A +-PARTICULAR PURPOSE, SATISFACTORY QUALITY, CORRESPONDENCE WITH DESCRIPTION, QUIET +-ENJOYMENT OR NON-INFRINGEMENT OF THIRD PARTY INTELLECTUAL PROPERTY RIGHTS. +-NXP B.V., ITS AFFILIATES AND THEIR SUPPLIERS DISCLAIM ANY WARRANTY THAT THE +-DELIVERABLES WILL OPERATE WITHOUT INTERRUPTION OR BE ERROR-FREE. +diff --git a/LICENCE.OLPC b/LICENCE.OLPC +deleted file mode 100644 +index a740952..0000000 +--- a/LICENCE.OLPC ++++ /dev/null +@@ -1,33 +0,0 @@ +-Copyright (c) 2006, One Laptop per Child and Marvell Corporation. +-All rights reserved. +- +-Redistribution. Redistribution and use in binary form, without +-modification, are permitted provided that the following conditions are +-met: +- +-* Redistributions must reproduce the above copyright notice and the +- following disclaimer in the documentation and/or other materials +- provided with the distribution. +-* Neither the name of Marvell Corporation nor the names of its suppliers +- may be used to endorse or promote products derived from this software +- without specific prior written permission. +-* No reverse engineering, decompilation, or disassembly of this software +- is permitted. +-* You may not use or attempt to use this software in conjunction with +- any product that is offered by a third party as a replacement, +- substitute or alternative to a Marvell Product where a Marvell Product +- is defined as a proprietary wireless LAN embedded client solution of +- Marvell or a Marvell Affiliate. +- +-DISCLAIMER. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND +-CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, +-BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND +-FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE +-COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, +-INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, +-BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS +-OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +-ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR +-TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE +-USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH +-DAMAGE. +diff --git a/LICENCE.atheros_firmware b/LICENCE.atheros_firmware +deleted file mode 100644 +index e0ebdac..0000000 +--- a/LICENCE.atheros_firmware ++++ /dev/null +@@ -1,38 +0,0 @@ +-Copyright (c) 2008-2010, Atheros Communications, Inc. +-All rights reserved. +- +-Redistribution. Redistribution and use in binary form, without +-modification, are permitted provided that the following conditions are +-met: +- +-* Redistributions must reproduce the above copyright notice and the +- following disclaimer in the documentation and/or other materials +- provided with the distribution. +- +-* Neither the name of Atheros Communications, Inc. nor the names of +- its suppliers may be used to endorse or promote products derived +- from this software without specific prior written permission. +- +-* No reverse engineering, decompilation, or disassembly of this +- software is permitted. +- +-Limited patent license. Atheros Communications, Inc. grants a +-world-wide, royalty-free, non-exclusive license under patents it +-now or hereafter owns or controls to make, have made, use, import, +-offer to sell and sell ("Utilize") this software, but solely to +-the extent that any such patent is necessary to Utilize the software +-in conjunction with an Atheros Chipset. The patent license shall not +-apply to any other combinations which include this software. No +-hardware per se is licensed hereunder. +- +-DISCLAIMER. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND +-CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, +-BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND +-FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL +-THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, +-INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, +-BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS +-OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +-ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR +-TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE +-USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +diff --git a/LICENCE.broadcom_bcm43xx b/LICENCE.broadcom_bcm43xx +deleted file mode 100644 +index ff26fdd..0000000 +--- a/LICENCE.broadcom_bcm43xx ++++ /dev/null +@@ -1,65 +0,0 @@ +-SOFTWARE LICENSE AGREEMENT +- +-The accompanying software in binary code form (“Software”), is licensed to you, +-or, if you are accepting on behalf of an entity, the entity and its affiliates +-exercising rights hereunder (“Licensee”) subject to the terms of this software +-license agreement (“Agreement”), unless Licensee and Broadcom Corporation +-(“Broadcom”) execute a separate written software license agreement governing +-use of the Software. ANY USE, REPRODUCTION, OR DISTRIBUTION OF THE SOFTWARE +-CONSTITUTES LICENSEE’S ACCEPTANCE OF THIS AGREEMENT. +- +-1. License. Subject to the terms and conditions of this Agreement, +-Broadcom hereby grants to Licensee a limited, non-exclusive, non-transferable, +-royalty-free license: (i) to use and integrate the Software with any other +-software; and (ii) to reproduce and distribute the Software complete, +-unmodified, and as provided by Broadcom, solely for use with Broadcom +-proprietary integrated circuit product(s) sold by Broadcom with which the +-Software was designed to be used, or their successors. +- +-2. Restrictions. Licensee shall distribute Software with a copy of this +-Agreement. Licensee shall not remove, efface or obscure any copyright or +-trademark notices from the Software. Reproductions of the Broadcom copyright +-notice shall be included with each copy of the Software, except where such +-Software is embedded in a manner not readily accessible to the end user. +-Licensee shall not: (i) use, license, sell or otherwise distribute the Software +-except as provided in this Agreement; (ii) attempt to modify in any way, +-reverse engineer, decompile or disassemble any portion of the Software; or +-(iii) use the Software or other material in violation of any applicable law or +-regulation, including but not limited to any regulatory agency. This Agreement +-shall automatically terminate upon Licensee’s failure to comply with any of the +-terms of this Agreement. In such event, Licensee will destroy all copies of the +-Software and its component parts. +- +-3. Ownership. The Software is licensed and not sold. Title to and +-ownership of the Software, including all intellectual property rights thereto, +-and any portion thereof remain with Broadcom or its licensors. Licensee hereby +-covenants that it will not assert any claim that the Software created by or for +-Broadcom infringe any intellectual property right owned or controlled by +-Licensee. +- +-4. Disclaimer. THE SOFTWARE IS OFFERED “AS IS,” AND BROADCOM PROVIDES AND +-GRANTS AND LICENSEE RECEIVES NO SUPPORT AND NO WARRANTIES OF ANY KIND, EXPRESS +-OR IMPLIED, BY STATUTE, COMMUNICATION OR CONDUCT WITH LICENSEE, OR OTHERWISE. +-BROADCOM SPECIFICALLY DISCLAIMS ANY IMPLIED WARRANTIES OF MERCHANTABILITY, +-FITNESS FOR A SPECIFIC PURPOSE, OR NONINFRINGEMENT CONCERNING THE SOFTWARE OR +-ANY UPGRADES TO OR DOCUMENTATION FOR THE SOFTWARE. WITHOUT LIMITATION OF THE +-ABOVE, BROADCOM GRANTS NO WARRANTY THAT THE SOFTWARE IS ERROR-FREE OR WILL +-OPERATE WITHOUT INTERRUPTION, AND GRANTS NO WARRANTY REGARDING ITS USE OR THE +-RESULTS THEREFROM INCLUDING, WITHOUT LIMITATION, ITS CORRECTNESS, ACCURACY, OR +-RELIABILITY. TO THE MAXIMUM EXTENT PERMITTED BY LAW, IN NO EVENT SHALL BROADCOM +-OR ANY OF ITS LICENSORS HAVE ANY LIABILITY FOR ANY DIRECT, INDIRECT, +-INCIDENTAL, SPECIAL, OR CONSEQUENTIAL DAMAGES, HOWEVER CAUSED AND ON ANY THEORY +-OF LIABILITY, WHETHER FOR BREACH OF CONTRACT, TORT (INCLUDING NEGLIGENCE) OR +-OTHERWISE, ARISING OUT OF THIS AGREEMENT OR USE, REPRODUCTION, OR DISTRIBUTION +-OF THE SOFTWARE, INCLUDING BUT NOT LIMITED TO LOSS OF DATA AND LOSS OF PROFITS, +-EVEN IF SUCH PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. THESE +-LIMITATIONS SHALL APPLY NOTWITHSTANDING ANY FAILURE OF ESSENTIAL PURPOSE OF ANY +-LIMITED REMEDY. +- +-5. Export Laws. LICENSEE UNDERSTANDS AND AGREES THAT THE SOFTWARE IS +-SUBJECT TO UNITED STATES AND OTHER APPLICABLE EXPORT-RELATED LAWS AND +-REGULATIONS AND THAT LICENSEE MAY NOT EXPORT, RE-EXPORT OR TRANSFER THE +-SOFTWARE OR ANY DIRECT PRODUCT OF THE SOFTWARE EXCEPT AS PERMITTED UNDER THOSE +-LAWS. WITHOUT LIMITING THE FOREGOING, EXPORT, RE-EXPORT, OR TRANSFER OF THE +-SOFTWARE TO CUBA, IRAN, NORTH KOREA, SUDAN, AND SYRIA IS PROHIBITED. +- +diff --git a/LICENCE.cw1200 b/LICENCE.cw1200 +deleted file mode 100644 +index 1016eca..0000000 +--- a/LICENCE.cw1200 ++++ /dev/null +@@ -1,35 +0,0 @@ +-Copyright (c) 2007-2013, ST Microelectronics NV. +-All rights reserved. +- +-Redistribution. Redistribution and use in binary form, without modification, +-are permitted provided that the following conditions are met: +- +-* Redistributions must reproduce the above copyright notice and the following +-disclaimer in the documentation and/or other materials provided with the +-distribution. +- +-* Neither the name of ST Microelectronics NV. nor the names of its suppliers +-may be used to endorse or promote products derived from this software without +-specific prior written permission. +- +-* No reverse engineering, decompilation, or disassembly of this software is +-permitted. +- +-Limited patent license. ST Microelectronics NV. grants a world-wide, royalty-free, +- non-exclusive license under patents it now or hereafter owns or controls to make, +- have made, use, import, offer to sell and sell ("Utilize") this software, but +- solely to the extent that any such patent is necessary to Utilize the software in +-conjunction with an ST Microelectronics chipset. The patent license shall not +-apply to any other combinations which include this software. No hardware per se +-is licensed hereunder. +- +-DISCLAIMER. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS ANDCONTRIBUTORS +-"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +-IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +-DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR +-ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES +-(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; +-LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON +-ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +-(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS +-SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +diff --git a/LICENCE.cypress b/LICENCE.cypress +deleted file mode 100644 +index 070ef66..0000000 +--- a/LICENCE.cypress ++++ /dev/null +@@ -1,138 +0,0 @@ +-### CYPRESS WIRELESS CONNECTIVITY DEVICES +-### DRIVER END USER LICENSE AGREEMENT (SOURCE AND BINARY DISTRIBUTION) +- +-PLEASE READ THIS END USER LICENSE AGREEMENT ("Agreement") CAREFULLY BEFORE +-DOWNLOADING, INSTALLING, OR USING THIS SOFTWARE, ANY ACCOMPANYING +-DOCUMENTATION, OR ANY UPDATES PROVIDED BY CYPRESS ("Software"). BY +-DOWNLOADING, INSTALLING, OR USING THE SOFTWARE, YOU ARE AGREEING TO BE BOUND +-BY THIS AGREEMENT. IF YOU DO NOT AGREE TO ALL OF THE TERMS OF THIS +-AGREEMENT, PROMPTLY RETURN AND DO NOT USE THE SOFTWARE. IF YOU HAVE +-PURCHASED THE SOFTWARE, YOUR RIGHT TO RETURN THE SOFTWARE EXPIRES 30 DAYS +-AFTER YOUR PURCHASE AND APPLIES ONLY TO THE ORIGINAL PURCHASER. +- +-Software Provided in Binary Code Form. This paragraph applies to any Software +-provided in binary code form. Subject to the terms and conditions of this +-Agreement, Cypress Semiconductor Corporation ("Cypress") grants you a +-non-exclusive, non-transferable license under its copyright rights in the +-Software to reproduce and distribute the Software in object code form only, +-solely for use in connection with Cypress integrated circuit products +-("Purpose"). +- +-Software Provided in Source Code Form. This paragraph applies to any Software +-provided in source code form ("Cypress Source Code"). Subject to the terms and +-conditions of this Agreement, Cypress grants you a non-exclusive, +-non-transferable license under its copyright rights in the Cypress Source Code +-to reproduce, modify, compile, and distribute the Cypress Source Code (whether +-in source code form or as compiled into binary code form) solely for the +-Purpose. Cypress retains ownership of the Cypress Source Code and any compiled +-version thereof. Subject to Cypress' ownership of the underlying Cypress +-Source Code, you retain ownership of any modifications you make to the +-Cypress Source Code. You agree not to remove any Cypress copyright or other +-notices from the Cypress Source Code and any modifications thereof. Any +-reproduction, modification, translation, compilation, or representation of +-the Cypress Source Code except as permitted in this paragraph is prohibited +-without the express written permission of Cypress. +- +-Free and Open Source Software. Portions of the Software may be licensed under +-free and/or open source licenses such as the GNU General Public License +-("FOSS"). FOSS is subject to the applicable license agreement and not this +-Agreement. If you are entitled to receive the source code from Cypress for any +-FOSS included with the Software, either the source code will be included with +-the Software or you may obtain the source code at no charge from +-. The applicable license terms will +-accompany each source code package. To review the license terms applicable to +-any FOSS for which Cypress is not required to provide you with source code, +-please see the Software's installation directory on your computer. +- +-Proprietary Rights. The Software, including all intellectual property rights +-therein, is and will remain the sole and exclusive property of Cypress or its +-suppliers. Except as otherwise expressly provided in this Agreement, you may +-not: (i) modify, adapt, or create derivative works based upon the Software; +-(ii) copy the Software; (iii) except and only to the extent explicitly +-permitted by applicable law despite this limitation, decompile, translate, +-reverse engineer, disassemble or otherwise reduce the Software to +-human-readable form; or (iv) use the Software other than for the Purpose. +- +-No Support. Cypress may, but is not required to, provide technical support for +-the Software. +- +-Term and Termination. This Agreement is effective until terminated. This +-Agreement and Your license rights will terminate immediately without notice +-from Cypress if you fail to comply with any provision of this Agreement. Upon +-termination, you must destroy all copies of Software in your possession or +-control. Termination of this Agreement will not affect any licenses validly +-granted as of the termination date to any end users of the Software. The +-following paragraphs shall survive any termination of this Agreement: "Free and +-Open Source Software," "Proprietary Rights," "Compliance With Law," +-"Disclaimer," "Limitation of Liability," and "General." +- +-Compliance With Law. Each party agrees to comply with all applicable laws, +-rules and regulations in connection with its activities under this Agreement. +-Without limiting the foregoing, the Software may be subject to export control +-laws and regulations of the United States and other countries. You agree to +-comply strictly with all such laws and regulations and acknowledge that you +-have the responsibility to obtain licenses to export, re-export, or import +-the Software. +- +-Disclaimer. TO THE MAXIMUM EXTENT PERMITTED BY APPLICABLE LAW, CYPRESS MAKES +-NO WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, WITH REGARD TO THE SOFTWARE, +-INCLUDING, BUT NOT LIMITED TO, INFRINGEMENT AND THE IMPLIED WARRANTIES OF +-MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. Cypress reserves the +-right to make changes to the Software without notice. Cypress does not assume +-any liability arising out of the application or use of Software or any +-product or circuit described in the Software. Cypress does not authorize its +-products for use as critical components in life-support systems where a +-malfunction or failure may reasonably be expected to result in significant +-injury to the user. The inclusion of Cypress' product in a life-support +-system or application implies that the manufacturer of such system or +-application assumes all risk of such use and in doing so indemnifies Cypress +-against all charges. +- +-Limitation of Liability. IN NO EVENT WILL CYPRESS OR ITS SUPPLIERS, +-RESELLERS, OR DISTRIBUTORS BE LIABLE FOR ANY LOST REVENUE, PROFIT, OR DATA, +-OR FOR SPECIAL, INDIRECT, CONSEQUENTIAL, INCIDENTAL, OR PUNITIVE DAMAGES +-HOWEVER CAUSED AND REGARDLESS OF THE THEORY OF LIABILITY, ARISING OUT OF THE +-USE OF OR INABILITY TO USE THE SOFTWARE EVEN IF CYPRESS OR ITS SUPPLIERS, +-RESELLERS, OR DISTRIBUTORS HAVE BEEN ADVISED OF THE POSSIBILITY OF SUCH +-DAMAGES. IN NO EVENT SHALL CYPRESS' OR ITS SUPPLIERS' RESELLERS', OR +-DISTRIBUTORS' TOTAL LIABILITY TO YOU, WHETHER IN CONTRACT, TORT (INCLUDING +-NEGLIGENCE), OR OTHERWISE, EXCEED THE PRICE PAID BY YOU FOR THE SOFTWARE. +-THE FOREGOING LIMITATIONS SHALL APPLY EVEN IF THE ABOVE-STATED WARRANTY FAILS +-OF ITS ESSENTIAL PURPOSE. BECAUSE SOME STATES OR JURISDICTIONS DO NOT ALLOW +-LIMITATION OR EXCLUSION OF CONSEQUENTIAL OR INCIDENTAL DAMAGES, THE ABOVE +-LIMITATION MAY NOT APPLY TO YOU. +- +-Restricted Rights. The Software under this Agreement is commercial computer +-software as that term is described in 48 C.F.R. 252.227-7014(a)(1). If +-acquired by or on behalf of a civilian agency, the U.S. Government acquires +-this commercial computer software and/or commercial computer software +-documentation subject to the terms of this Agreement as specified in 48 +-C.F.R. 12.212 (Computer Software) and 12.211 (Technical Data) of the Federal +-Acquisition Regulations ("FAR") and its successors. If acquired by or on +-behalf of any agency within the Department of Defense ("DOD"), the U.S. +-Government acquires this commercial computer software and/or commercial +-computer software documentation subject to the terms of this Agreement as +-specified in 48 C.F.R. 227.7202-3 of the DOD FAR Supplement ("DFAR") and its +-successors. +- +-General. This Agreement will bind and inure to the benefit of each party's +-successors and assigns, provided that you may not assign or transfer this +-Agreement, in whole or in part, without Cypress' written consent. This +-Agreement shall be governed by and construed in accordance with the laws of +-the State of California, United States of America, as if performed wholly +-within the state and without giving effect to the principles of conflict of +-law. The parties consent to personal and exclusive jurisdiction of and venue +-in, the state and federal courts within Santa Clara County, California; +-provided however, that nothing in this Agreement will limit Cypress' right to +-bring legal action in any venue in order to protect or enforce its +-intellectual property rights. No failure of either party to exercise or +-enforce any of its rights under this Agreement will act as a waiver of such +-rights. If any portion hereof is found to be void or unenforceable, the +-remaining provisions of this Agreement shall remain in full force and +-effect. This Agreement is the complete and exclusive agreement between the +-parties with respect to the subject matter hereof, superseding and replacing +-any and all prior agreements, communications, and understandings (both +-written and oral) regarding such subject matter. Any notice to Cypress will +-be deemed effective when actually received and must be sent to Cypress +-Semiconductor Corporation, ATTN: Chief Legal Officer, 198 Champion Court, San +-Jose, CA 95134 USA. +diff --git a/LICENCE.ibt_firmware b/LICENCE.ibt_firmware +deleted file mode 100644 +index f878c6a..0000000 +--- a/LICENCE.ibt_firmware ++++ /dev/null +@@ -1,39 +0,0 @@ +-Copyright © 2014, Intel Corporation. +-All rights reserved. +- +-Redistribution. Redistribution and use in binary form, without +-modification, are permitted provided that the following conditions are +-met: +- +-* Redistributions must reproduce the above copyright notice and the +- following disclaimer in the documentation and/or other materials +- provided with the distribution. +-* Neither the name of Intel Corporation nor the names of its suppliers +- may be used to endorse or promote products derived from this software +- without specific prior written permission. +-* No reverse engineering, decompilation, or disassembly of this software +- is permitted. +- +-Limited patent license. Intel Corporation grants a world-wide, +-royalty-free, non-exclusive license under patents it now or hereafter +-owns or controls to make, have made, use, import, offer to sell and +-sell ("Utilize") this software, but solely to the extent that any +-such patent is necessary to Utilize the software alone, or in +-combination with an operating system licensed under an approved Open +-Source license as listed by the Open Source Initiative at +-http://opensource.org/licenses. The patent license shall not apply to +-any other combinations which include this software. No hardware per +-se is licensed hereunder. +- +-DISCLAIMER. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND +-CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, +-BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND +-FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE +-COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, +-INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, +-BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS +-OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +-ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR +-TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE +-USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH +-DAMAGE. +diff --git a/LICENCE.iwlwifi_firmware b/LICENCE.iwlwifi_firmware +deleted file mode 100644 +index 6bdd16d..0000000 +--- a/LICENCE.iwlwifi_firmware ++++ /dev/null +@@ -1,39 +0,0 @@ +-Copyright (c) 2006-2021, Intel Corporation. +-All rights reserved. +- +-Redistribution. Redistribution and use in binary form, without +-modification, are permitted provided that the following conditions are +-met: +- +-* Redistributions must reproduce the above copyright notice and the +- following disclaimer in the documentation and/or other materials +- provided with the distribution. +-* Neither the name of Intel Corporation nor the names of its suppliers +- may be used to endorse or promote products derived from this software +- without specific prior written permission. +-* No reverse engineering, decompilation, or disassembly of this software +- is permitted. +- +-Limited patent license. Intel Corporation grants a world-wide, +-royalty-free, non-exclusive license under patents it now or hereafter +-owns or controls to make, have made, use, import, offer to sell and +-sell ("Utilize") this software, but solely to the extent that any +-such patent is necessary to Utilize the software alone, or in +-combination with an operating system licensed under an approved Open +-Source license as listed by the Open Source Initiative at +-http://opensource.org/licenses. The patent license shall not apply to +-any other combinations which include this software. No hardware per +-se is licensed hereunder. +- +-DISCLAIMER. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND +-CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, +-BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND +-FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE +-COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, +-INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, +-BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS +-OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +-ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR +-TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE +-USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH +-DAMAGE. +diff --git a/LICENCE.open-ath9k-htc-firmware b/LICENCE.open-ath9k-htc-firmware +deleted file mode 100644 +index 36655b7..0000000 +--- a/LICENCE.open-ath9k-htc-firmware ++++ /dev/null +@@ -1,206 +0,0 @@ +-This is a concatenation of LICENCE.txt and NOTICE.txt from the +-open-ath9k-htc-firmware repository describing licensing terms for the +-firmware image and its sources. +- +-The source code repository is publicly available at +-https://github.com/qca/open-ath9k-htc-firmware . +- +- +-LICENCE.txt +------------ +- +-Files with a Qualcomm Atheros / Atheros licence fall under the following +-licence. Please see NOTICES.TXT for information about other files in this +-repository. +- +----- +- +-Copyright (c) 2013 Qualcomm Atheros, Inc. +- +-All rights reserved. +- +-Redistribution and use in source and binary forms, with or without +-modification, are permitted (subject to the limitations in the +-disclaimer below) provided that the following conditions are met: +- +- * Redistributions of source code must retain the above copyright +- notice, this list of conditions and the following disclaimer. +- +- * Redistributions in binary form must reproduce the above copyright +- notice, this list of conditions and the following disclaimer in the +- documentation and/or other materials provided with the +- distribution. +- +- * Neither the name of Qualcomm Atheros nor the names of its +- contributors may be used to endorse or promote products derived +- from this software without specific prior written permission. +- +-NO EXPRESS OR IMPLIED LICENSES TO ANY PARTY'S PATENT RIGHTS ARE +-GRANTED BY THIS LICENSE. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT +-HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED +-WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +-MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +-DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE +-LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR +-CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF +-SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR +-BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, +-WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE +-OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN +-IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +- +----- +- +- +-NOTICE.TXT +----------- +- +-This NOTICE.TXT file contains certain notices of software components included +-with the software that QUALCOMM ATHEROS Incorporated ('Qualcomm Atheros') is +-required to provide you. Notwithstanding anything in the notices in this file, +-your use of these software components together with the Qualcomm Atheros +-software (Qualcomm Atheros software hereinafter referred to as 'Software') is +-subject to the terms of your license from Qualcomm Atheros. Compliance with +-all copyright laws and software license agreements included in the notice +-section of this file are the responsibility of the user. Except as may be +-granted by separate express written agreement, this file provides no license +-to any Qualcomm Atheros patents, trademarks, copyrights, or other intellectual +-property. +- +-Copyright (c) 2013 QUALCOMM ATHEROS Incorporated. All rights reserved. +- +-QUALCOMM ATHEROS is a registered trademark and registered service mark of +-QUALCOMM ATHEROS Incorporated. All other trademarks and service marks are +-the property of their respective owners. +- +-NOTICES: +- +-/* +- * Copyright (c) 2005-2012 Atheros Communications Inc. +- * +- * Permission to use, copy, modify, and/or distribute this software for any +- * purpose with or without fee is hereby granted, provided that the above +- * copyright notice and this permission notice appear in all copies. +- * +- * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +- * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +- * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +- * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +- * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +- * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +- * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +- */ +- +-/* +- * Copyright (c) 2002-2005 Sam Leffler, Errno Consulting +- * Copyright (c) 2002-2005 Atheros Communications, Inc. +- * Copyright (c) 2008-2010, Atheros Communications Inc. +- * +- * Redistribution and use in source and binary forms are permitted +- * provided that the following conditions are met: +- * 1. The materials contained herein are unmodified and are used +- * unmodified. +- * 2. Redistributions of source code must retain the above copyright +- * notice, this list of conditions and the following NO +- * ''WARRANTY'' disclaimer below (''Disclaimer''), without +- * modification. +- * 3. Redistributions in binary form must reproduce at minimum a +- * disclaimer similar to the Disclaimer below and any redistribution +- * must be conditioned upon including a substantially similar +- * Disclaimer requirement for further binary redistribution. +- * 4. Neither the names of the above-listed copyright holders nor the +- * names of any contributors may be used to endorse or promote +- * product derived from this software without specific prior written +- * permission. +- * +- * NO WARRANTY +- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +- * ''AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +- * LIMITED TO, THE IMPLIED WARRANTIES OF NONINFRINGEMENT, +- * MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. +- * IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE +- * FOR SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF +- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT +- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +- * SUCH DAMAGES. +- */ +- +----- +- +-The following files are from ECoS with a GPLv2 licence with modification +-and linking caveats. Please see the licence below for more information: +- +-target_firmware/magpie_fw_dev/build/magpie_1_1/sboot/cmnos/printf/src/cmnos_printf.c +-target_firmware/magpie_fw_dev/target/cmnos/cmnos_printf.c +-target_firmware/magpie_fw_dev/target/cmnos/k2_fw_cmnos_printf.c +- +-//####ECOSGPLCOPYRIGHTBEGIN#### +-// ------------------------------------------- +-// This file is part of eCos, the Embedded Configurable Operating System. +-// Copyright (C) 1998, 1999, 2000, 2001, 2002 Red Hat, Inc. +-// Copyright (C) 2002 Gary Thomas +-// +-// eCos is free software; you can redistribute it and/or modify it under +-// the terms of the GNU General Public License as published by the Free +-// Software Foundation; either version 2 or (at your option) any later version. +-// +-// eCos is distributed in the hope that it will be useful, but WITHOUT ANY +-// WARRANTY; without even the implied warranty of MERCHANTABILITY or +-// FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License +-// for more details. +-// +-// You should have received a copy of the GNU General Public License along +-// with eCos; if not, write to the Free Software Foundation, Inc., +-// 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. +-// +-// As a special exception, if other files instantiate templates or use macros +-// or inline functions from this file, or you compile this file and link it +-// with other works to produce a work based on this file, this file does not +-// by itself cause the resulting work to be covered by the GNU General Public +-// License. However the source code for this file must still be made available +-// in accordance with section (3) of the GNU General Public License. +-// +-// This exception does not invalidate any other reasons why a work based on +-// this file might be covered by the GNU General Public License. +-// +-// Alternative licenses for eCos may be arranged by contacting Red Hat, Inc. +-// at http://sources.redhat.com/ecos/ecos-license/ +-// ------------------------------------------- +-//####ECOSGPLCOPYRIGHTEND#### +- +----- +- +-Some of the source code is sourced from Tensilica, Inc. +- +-Although most of the files fall under the MIT licence, some of the source +-files generated as part of the system development have a proprietary +-Tensilica licence. +- +-With permission from Tensilica, Inc, these files have been relicenced +-under the following licence: +- +-/* +- * Copyright (c) 2013 Tensilica Inc. +- * +- * Permission is hereby granted, free of charge, to any person obtaining +- * a copy of this software and associated documentation files (the +- * "Software"), to deal in the Software without restriction, including +- * without limitation the rights to use, copy, modify, merge, publish, +- * distribute, sublicense, and/or sell copies of the Software, and to +- * permit persons to whom the Software is furnished to do so, subject to +- * the following conditions: +- * +- * The above copyright notice and this permission notice shall be included +- * in all copies or substantial portions of the Software. +- * +- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +- * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +- * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. +- * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY +- * CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, +- * TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE +- * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. +- */ +diff --git a/LICENCE.ralink-firmware.txt b/LICENCE.ralink-firmware.txt +deleted file mode 100644 +index 18dd038..0000000 +--- a/LICENCE.ralink-firmware.txt ++++ /dev/null +@@ -1,39 +0,0 @@ +-Copyright (c) 2007, Ralink Technology Corporation +-All rights reserved. +- +-Redistribution. Redistribution and use in binary form, without +-modification, are permitted provided that the following conditions are +-met: +- +-* Redistributions must reproduce the above copyright notice and the +- following disclaimer in the documentation and/or other materials +- provided with the distribution. +-* Neither the name of Ralink Technology Corporation nor the names of its +- suppliers may be used to endorse or promote products derived from this +- software without specific prior written permission. +-* No reverse engineering, decompilation, or disassembly of this software +- is permitted. +- +-Limited patent license. Ralink Technology Corporation grants a world-wide, +-royalty-free, non-exclusive license under patents it now or hereafter +-owns or controls to make, have made, use, import, offer to sell and +-sell ("Utilize") this software, but solely to the extent that any +-such patent is necessary to Utilize the software alone, or in +-combination with an operating system licensed under an approved Open +-Source license as listed by the Open Source Initiative at +-http://opensource.org/licenses. The patent license shall not apply to +-any other combinations which include this software. No hardware per +-se is licensed hereunder. +- +-DISCLAIMER. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND +-CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, +-BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND +-FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE +-COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, +-INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, +-BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS +-OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +-ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR +-TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE +-USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH +-DAMAGE. +diff --git a/LICENCE.ralink_a_mediatek_company_firmware b/LICENCE.ralink_a_mediatek_company_firmware +deleted file mode 100644 +index fef16b6..0000000 +--- a/LICENCE.ralink_a_mediatek_company_firmware ++++ /dev/null +@@ -1,39 +0,0 @@ +-Copyright (c) 2013, Ralink, A MediaTek Company +-All rights reserved. +- +-Redistribution. Redistribution and use in binary form, without +-modification, are permitted provided that the following conditions are +-met: +- +-* Redistributions must reproduce the above copyright notice and the +- following disclaimer in the documentation and/or other materials +- provided with the distribution. +-* Neither the name of Ralink Technology Corporation nor the names of its +- suppliers may be used to endorse or promote products derived from this +- software without specific prior written permission. +-* No reverse engineering, decompilation, or disassembly of this software +- is permitted. +- +-Limited patent license. Ralink Technology Corporation grants a world-wide, +-royalty-free, non-exclusive license under patents it now or hereafter +-owns or controls to make, have made, use, import, offer to sell and +-sell ("Utilize") this software, but solely to the extent that any +-such patent is necessary to Utilize the software alone, or in +-combination with an operating system licensed under an approved Open +-Source license as listed by the Open Source Initiative at +-http://opensource.org/licenses. The patent license shall not apply to +-any other combinations which include this software. No hardware per +-se is licensed hereunder. +- +-DISCLAIMER. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND +-CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, +-BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND +-FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE +-COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, +-INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, +-BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS +-OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +-ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR +-TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE +-USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH +-DAMAGE. +diff --git a/LICENCE.rtlwifi_firmware.txt b/LICENCE.rtlwifi_firmware.txt +deleted file mode 100644 +index d70921f..0000000 +--- a/LICENCE.rtlwifi_firmware.txt ++++ /dev/null +@@ -1,39 +0,0 @@ +-Copyright (c) 2010, Realtek Semiconductor Corporation +-All rights reserved. +- +-Redistribution. Redistribution and use in binary form, without +-modification, are permitted provided that the following conditions are +-met: +- +-* Redistributions must reproduce the above copyright notice and the +- following disclaimer in the documentation and/or other materials +- provided with the distribution. +-* Neither the name of Realtek Semiconductor Corporation nor the names of its +- suppliers may be used to endorse or promote products derived from this +- software without specific prior written permission. +-* No reverse engineering, decompilation, or disassembly of this software +- is permitted. +- +-Limited patent license. Realtek Semiconductor Corporation grants a world-wide, +-royalty-free, non-exclusive license under patents it now or hereafter +-owns or controls to make, have made, use, import, offer to sell and +-sell ("Utilize") this software, but solely to the extent that any +-such patent is necessary to Utilize the software alone, or in +-combination with an operating system licensed under an approved Open +-Source license as listed by the Open Source Initiative at +-http://opensource.org/licenses. The patent license shall not apply to +-any other combinations which include this software. No hardware per +-se is licensed hereunder. +- +-DISCLAIMER. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND +-CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, +-BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND +-FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE +-COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, +-INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, +-BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS +-OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +-ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR +-TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE +-USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH +-DAMAGE. +diff --git a/LICENCE.ti-connectivity b/LICENCE.ti-connectivity +deleted file mode 100644 +index 22f617f..0000000 +--- a/LICENCE.ti-connectivity ++++ /dev/null +@@ -1,61 +0,0 @@ +-Copyright (c) 2016 Texas Instruments Incorporated +- +-All rights reserved not granted herein. +- +-Limited License. +- +-Texas Instruments Incorporated grants a world-wide, royalty-free, non-exclusive +-license under copyrights and patents it now or hereafter owns or controls to +-make, have made, use, import, offer to sell and sell ("Utilize") this software +-subject to the terms herein. With respect to the foregoing patent license, such +-license is granted solely to the extent that any such patent is necessary to +-Utilize the software alone. The patent license shall not apply to any +-combinations which include this software, other than combinations with devices +-manufactured by or for TI (“TI Devices”). No hardware patent is licensed +-hereunder. +- +-Redistributions must preserve existing copyright notices and reproduce this +-license (including the above copyright notice and the disclaimer and +-(if applicable) source code license limitations below) in the documentation +-and/or other materials provided with the distribution +- +-Redistribution and use in binary form, without modification, are permitted +-provided that the following conditions are met: +- +- * No reverse engineering, decompilation, or disassembly of this +- software is permitted with respect to any software provided in binary +- form. +- +- * any redistribution and use are licensed by TI for use only with TI +- Devices. +- +- * Nothing shall obligate TI to provide you with source code for the +- software licensed and provided to you in object code. +- +-If software source code is provided to you, modification and redistribution of +-the source code are permitted provided that the following conditions are met: +- +- * any redistribution and use of the source code, including any +- resulting derivative works, are licensed by TI for use only with TI +- Devices. +- +- * any redistribution and use of any object code compiled from the +- source code and any resulting derivative works, are licensed by TI +- for use only with TI Devices. +- +-Neither the name of Texas Instruments Incorporated nor the names of its +-suppliers may be used to endorse or promote products derived from this +-software without specific prior written permission. +- +-DISCLAIMER. +- +-THIS SOFTWARE IS PROVIDED BY TI AND TI’S LICENSORS "AS IS" AND ANY EXPRESS OR +-IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +-MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO +-EVENT SHALL TI AND TI’S LICENSORS BE LIABLE FOR ANY DIRECT, INDIRECT, +-INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +-LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR +-PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF +-LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE +-OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF +-ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +diff --git a/LICENCE.wl1251 b/LICENCE.wl1251 +deleted file mode 100644 +index bd0f5f1..0000000 +--- a/LICENCE.wl1251 ++++ /dev/null +@@ -1,59 +0,0 @@ +-Copyright (c) 2000 – 2013 Texas Instruments Incorporated +- +-All rights reserved not granted herein. +- +-Limited License. +- +-Texas Instruments Incorporated grants a world-wide, royalty-free, non-exclusive +-license under copyrights and patents it now or hereafter owns or controls to +-make, have made, use, import, offer to sell and sell ("Utilize") this software +-subject to the terms herein. With respect to the foregoing patent license, +-such license is granted solely to the extent that any such patent is necessary +-to Utilize the software alone. The patent license shall not apply to any +-combinations which include this software, other than combinations with devices +-manufactured by or for TI (“TI Devices”). No hardware patent is licensed +-hereunder. +- +-Redistributions must preserve existing copyright notices and reproduce this +-license (including the above copyright notice and the disclaimer and (if +-applicable) source code license limitations below) in the documentation and/or +-other materials provided with the distribution +- +-Redistribution and use in binary form, without modification, are permitted +-provided that the following conditions are met: +- +-* No reverse engineering, decompilation, or disassembly of this software +- is permitted with respect to any software provided in binary form. +- +-* any redistribution and use are licensed by TI for use only with TI +- Devices. +- +-* Nothing shall obligate TI to provide you with source code for the +- software licensed and provided to you in object code. +- +-If software source code is provided to you, modification and redistribution of +-the source code are permitted provided that the following conditions are met: +- +-* any redistribution and use of the source code, including any resulting +- derivative works, are licensed by TI for use only with TI Devices. +- +-* any redistribution and use of any object code compiled from the source +- code and any resulting derivative works, are licensed by TI for use +- only with TI Devices. +- +-Neither the name of Texas Instruments Incorporated nor the names of its +-suppliers may be used to endorse or promote products derived from this software +-without specific prior written permission. +- +-DISCLAIMER. +- +-THIS SOFTWARE IS PROVIDED BY TI AND TI’S LICENSORS "AS IS" AND ANY EXPRESS OR +-IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +-MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO +-EVENT SHALL TI AND TI’S LICENSORS BE LIABLE FOR ANY DIRECT, INDIRECT, +-INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +-LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR +-PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF +-LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE +-OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF +-ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +diff --git a/LICENSE.QualcommAtheros_ar3k b/LICENSE.QualcommAtheros_ar3k +deleted file mode 100644 +index 7fae632..0000000 +--- a/LICENSE.QualcommAtheros_ar3k ++++ /dev/null +@@ -1,47 +0,0 @@ +-Copyright (c) 2015, Qualcomm Atheros, Inc. +-All rights reserved. +- +-Redistribution. Reproduction and redistribution in binary form, without +-modification, for use solely in conjunction with a Qualcomm Atheros, Inc. +-chipset, is permitted provided that the following conditions are met: +- +- • Redistributions must reproduce the above copyright notice and the following +- disclaimer in the documentation and/or other materials provided with the +- distribution. +- +- • Neither the name of Qualcomm Atheros, Inc. nor the names of its suppliers +- may be used to endorse or promote products derived from this Software +- without specific prior written permission. +- +- • No reverse engineering, decompilation, or disassembly of this Software is +- permitted. +- +-Limited patent license. Qualcomm Atheros, Inc. (“Licensor”) grants you +-(“Licensee”) a limited, worldwide, royalty-free, non-exclusive license under +-the Patents to make, have made, use, import, offer to sell and sell the +-Software. No hardware per se is licensed hereunder. +-The term “Patents” as used in this agreement means only those patents or patent +-applications owned solely and exclusively by Licensor as of the date of +-Licensor’s submission of the Software and any patents deriving priority (i.e., +-having a first effective filing date) therefrom. The term “Software” as used in +-this agreement means the firmware image submitted by Licensor, under the terms +-of this license, to git://git.kernel.org/pub/scm/linux/kernel/git/firmware/ +-linux-firmware.git. +-Notwithstanding anything to the contrary herein, Licensor does not grant and +-Licensee does not receive, by virtue of this agreement or the Licensor’s +-submission of any Software, any license or other rights under any patent or +-patent application owned by any affiliate of Licensor or any other entity +-(other than Licensor), whether expressly, impliedly, by virtue of estoppel or +-exhaustion, or otherwise. +- +-DISCLAIMER. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND +-CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, +-BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND +-FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL +-THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, +-INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, +-BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS +-OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +-ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR +-TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE +-USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +diff --git a/LICENSE.QualcommAtheros_ath10k b/LICENSE.QualcommAtheros_ath10k +deleted file mode 100644 +index c68935c..0000000 +--- a/LICENSE.QualcommAtheros_ath10k ++++ /dev/null +@@ -1,47 +0,0 @@ +-Copyright (c) 2015-2017, Qualcomm Atheros, Inc. +-All rights reserved. +- +-Redistribution. Reproduction and redistribution in binary form, without +-modification, for use solely in conjunction with a Qualcomm Atheros, Inc. +-chipset, is permitted provided that the following conditions are met: +- +- • Redistributions must reproduce the above copyright notice and the following +- disclaimer in the documentation and/or other materials provided with the +- distribution. +- +- • Neither the name of Qualcomm Atheros, Inc. nor the names of its suppliers +- may be used to endorse or promote products derived from this Software +- without specific prior written permission. +- +- • No reverse engineering, decompilation, or disassembly of this Software is +- permitted. +- +-Limited patent license. Qualcomm Atheros, Inc. (“Licensor”) grants you +-(“Licensee”) a limited, worldwide, royalty-free, non-exclusive license under +-the Patents to make, have made, use, import, offer to sell and sell the +-Software. No hardware per se is licensed hereunder. +-The term “Patents” as used in this agreement means only those patents or patent +-applications owned solely and exclusively by Licensor as of the date of +-Licensor’s submission of the Software and any patents deriving priority (i.e., +-having a first effective filing date) therefrom. The term “Software” as used in +-this agreement means the firmware image submitted by Licensor, under the terms +-of this license, to git://git.kernel.org/pub/scm/linux/kernel/git/firmware/ +-linux-firmware.git. +-Notwithstanding anything to the contrary herein, Licensor does not grant and +-Licensee does not receive, by virtue of this agreement or the Licensor’s +-submission of any Software, any license or other rights under any patent or +-patent application owned by any affiliate of Licensor or any other entity +-(other than Licensor), whether expressly, impliedly, by virtue of estoppel or +-exhaustion, or otherwise. +- +-DISCLAIMER. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND +-CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, +-BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND +-FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL +-THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, +-INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, +-BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS +-OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +-ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR +-TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE +-USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +diff --git a/LICENSE.atmel b/LICENSE.atmel +deleted file mode 100644 +index 5feb313..0000000 +--- a/LICENSE.atmel ++++ /dev/null +@@ -1,36 +0,0 @@ +-Copyright (C) 2015 Atmel Corporation. All rights reserved. +- +-REDISTRIBUTION: Permission is hereby granted by Atmel Corporation (Atmel), free +-of any license fees, to any person obtaining a copy of this firmware (the +-"Software"), to install, reproduce, copy and distribute copies, in binary form, +-in hexadecimal or equivalent formats, of the Software and to permit persons to +-whom the Software is provided to do the same, subject to the following +-conditions: +- +-* Any redistribution of the Software must reproduce the above copyright notice, +- this license notice, and the following disclaimers and notices in the +- documentation and/or other materials provided with the Software. +- +-* Neither the name of Atmel Corporation, its products nor the names of its +- suppliers may be used to endorse or promote products derived from this +- Software without specific prior written permission. +- +-* All matters arising out of or in connection with this License and/or Software +- shall be governed by California law and the parties agree to the exclusive +- jurisdiction of the Californian courts to decide all disputes arising. +- +-* The licensee shall defend and indemnify Atmel against any and all claims, +- costs, losses and damages (including reasonable legal fees) incurred by tme +- arising out of any claim relating to the Software due to the licensee’s use or +- sub-licensing of the Software +- +-DISCLAIMER: THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR +-IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +-MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE +-DISCLAIMED. IN NO EVENT SHALL ATMEL BE LIABLE FOR ANY DIRECT, INDIRECT, +-INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +-LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR +-PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF +-LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE +-OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF +-ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +diff --git a/LICENSE.nxp b/LICENSE.nxp +deleted file mode 100644 +index bfd2c70..0000000 +--- a/LICENSE.nxp ++++ /dev/null +@@ -1,26 +0,0 @@ +-LA_OPT_BINARY_FIRMWARE_ONLY rev2 June 2020 +- +-Copyright © 2018 NXP. All rights reserved. +- +-Software License Agreement (“Agreement”) +- +-ANY USE, REPRODUCTION, OR DISTRIBUTION OF THE ACCOMPANYING BINARY SOFTWARE CONSTITUTES LICENSEE'S ACCEPTANCE OF THE TERMS AND CONDITIONS OF THIS AGREEMENT. +- +-Licensed Software. “Binary Software” means the software in binary form supplied directly by NXP pursuant to this Agreement. Subject to the terms and conditions of this Agreement, NXP USA, Inc. ("Licensor"), grants to you (“Licensee”) a worldwide, non-exclusive, and royalty-free copyright license to reproduce and distribute the Binary Software in its complete and unmodified binary form as provided by Licensor, for use solely in conjunction with a programmable processing unit supplied directly or indirectly from Licensor. +- +-Restrictions. Licensee must reproduce the Licensor copyright notice above with each binary copy of the Binary Software or in the accompanying documentation. Licensee must not reverse engineer, decompile, disassemble or modify in any way the Binary Software. Licensee must not use the Binary Software in violation of any applicable law or regulation. This Agreement shall automatically terminate upon Licensee's breach of any term or condition of this Agreement in which case, Licensee shall destroy all copies of the Binary Software. Neither the name of Licensor nor the names of its suppliers may be used to endorse or promote products derived from this Binary Software without specific prior written permission. +-Disclaimer. TO THE MAXIMUM EXTENT PERMITTED BY LAW, LICENSOR EXPRESSLY DISCLAIMS ANY WARRANTY FOR THE BINARY SOFTWARE. THE BINARY SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION THE IMPLIED WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, OR NON-INFRINGEMENT. WITHOUT LIMITING THE GENERALITY OF THE FOREGOING, LICENSOR DOES NOT WARRANT THAT THE BINARY SOFTWARE IS ERROR-FREE OR WILL OPERATE WITHOUT INTERRUPTION, AND LICENSOR GRANTS NO WARRANTY REGARDING ITS USE OR THE RESULTS THEREFROM, INCLUDING ITS CORRECTNESS, ACCURACY, OR RELIABILITY. +- +-Limitation of Liability. IN NO EVENT WILL LICENSOR, OR ANY OF LICENSOR'S LICENSORS HAVE ANY LIABILITY HEREUNDER FOR ANY INDIRECT, SPECIAL, OR +-CONSEQUENTIAL DAMAGES, HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER FOR BREACH OF CONTRACT, TORT (INCLUDING NEGLIGENCE), OR OTHERWISE, ARISING OUT OF THIS AGREEMENT, INCLUDING DAMAGES FOR LOSS OF PROFITS, OR THE COST OF PROCUREMENT OF SUBSTITUTE GOODS, EVEN IF SUCH PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. LICENSOR’S TOTAL LIABILITY FOR ALL COSTS, DAMAGES, CLAIMS, OR LOSSES WHATSOEVER ARISING OUT OF OR IN CONNECTION WITH THIS AGREEMENT OR THE BINARY SOFTWARE SUPPLIED UNDER THIS AGREEMENT IS LIMITED TO THE AGGREGATE AMOUNT PAID BY LICENSEE TO LICENSOR IN CONNECTION WITH THE BINARY SOFTWARE TO WHICH LOSSES OR DAMAGES ARE CLAIMED. +- +-Trade Compliance. Licensee shall comply with all applicable export and import control laws and regulations including but not limited to the US Export Administration Regulation (including restrictions on certain military end uses and military end users as specified in Section 15 C.F.R. § 744.21 and prohibited party lists issued by other federal governments), Catch-all regulations and all national and international embargoes. Licensee further agrees that it will not knowingly transfer, divert, export or re-export, directly or indirectly, any product, software, including software source code, or technology restricted by such regulations or by other applicable national regulations, received from Licensor under this Agreement, or any direct product of such software or technical data to any person, firm, entity, country or destination to which such transfer, diversion, export or re-export is restricted or prohibited, without obtaining prior written authorization from the applicable competent government authorities to the extent required by those laws. Licensee acknowledge that the “restricted encryption software” that is subject to the US Export Administration Regulations (EAR), is not intended for use by a government end user, as defined in part 772 of the EAR. This provision shall survive termination or expiration of this Agreement. +- +-Assignment. Licensee may not assign this Agreement without the prior written consent of Licensor. Licensor may assign this Agreement without Licensee’s consent. +- +-Governing Law. This Agreement will be governed by, construed, and enforced in accordance with the laws of the State of Texas, USA, without regard to conflicts of laws principles, will apply to all matters relating to this Agreement or the Binary Software, and Licensee agrees that any litigation will be subject to the exclusive jurisdiction of the state or federal courts Texas, USA. The United Nations Convention on Contracts for the International Sale of Goods will not apply to this Agreement. +-Restrictions, Disclaimer, Limitation of Liability, Trade Compliance, Assignment, and Governing Law shall survive termination or expiration of this Agreement. +- +- +- +- +diff --git a/WHENCE b/WHENCE +index d78e45e..edf6f75 100644 +--- a/WHENCE ++++ b/WHENCE +@@ -8,15 +8,6 @@ kernel. + + -------------------------------------------------------------------------- + +-Driver: BCM-0bb4-0306 Cypress Bluetooth firmware for HTC Vive +- +-File: brcm/BCM-0bb4-0306.hcd +-Link: brcm/BCM-0a5c-6410.hcd -> BCM-0bb4-0306.hcd +- +-Licence: Redistributable. See LICENCE.cypress for details. +- +--------------------------------------------------------------------------- +- + Driver: advansys - AdvanSys SCSI + + File: advansys/mcode.bin +@@ -306,36 +297,6 @@ Licence: Redistributable. See LICENCE.agere for details + + -------------------------------------------------------------------------- + +-Driver: ar9170 - Atheros 802.11n "otus" USB +- +-File: ar9170-1.fw +-File: ar9170-2.fw +- +-Licence: Redistributable. See LICENCE.atheros_firmware for details +- +--------------------------------------------------------------------------- +- +-Driver: ath9k_htc - Atheros HTC devices (USB) +- +-File: ar9271.fw +-File: ar7010.fw +-File: ar7010_1_1.fw +-File: htc_9271.fw +-Version: 1.3.1 +-File: htc_7010.fw +-Version: 1.3.1 +- +-Licence: Redistributable. See LICENCE.atheros_firmware for details +- +-File: ath9k_htc/htc_7010-1.4.0.fw +-Version: 1.4.0 +-File: ath9k_htc/htc_9271-1.4.0.fw +-Version: 1.4.0 +- +-Licence: Free software. See LICENCE.open-ath9k-htc-firmware for details +- +--------------------------------------------------------------------------- +- + Driver: cassini - Sun Cassini + + File: sun/cassini.bin +@@ -516,479 +477,6 @@ Found in hex form in kernel source, with the following notice: + + -------------------------------------------------------------------------- + +-Driver: libertas - Marvell Libertas fullmac-type 802.11b/g cards +- +-File: libertas/cf8381.bin +-File: libertas/cf8381_helper.bin +-File: libertas/cf8385.bin +-File: libertas/cf8385_helper.bin +-File: libertas/gspi8682.bin +-File: libertas/gspi8682_helper.bin +-File: libertas/gspi8686_v9.bin +-File: libertas/gspi8686_v9_helper.bin +-File: libertas/gspi8688.bin +-File: libertas/gspi8688_helper.bin +-File: libertas/sd8385.bin +-File: libertas/sd8385_helper.bin +-File: libertas/sd8682.bin +-File: libertas/sd8682_helper.bin +-File: libertas/sd8686_v8.bin +-File: libertas/sd8686_v8_helper.bin +-File: libertas/sd8686_v9.bin +-File: libertas/sd8686_v9_helper.bin +-File: libertas/usb8388_v5.bin +-File: libertas/usb8388_v9.bin +-File: libertas/usb8682.bin +-File: mrvl/sd8688.bin +-Link: libertas/sd8688.bin -> ../mrvl/sd8688.bin +-File: mrvl/sd8688_helper.bin +-Link: libertas/sd8688_helper.bin -> ../mrvl/sd8688_helper.bin +- +-Licence: Redistributable. See LICENCE.Marvell for details. Extracted from +-Linux driver tarballs downloaded from Marvell's "Extranet" with permission. +- +--------------------------------------------------------------------------- +- +-Driver: libertas - Marvell Libertas 802.11b/g cards, OLPC firmware +- +-File: libertas/lbtf_sdio.bin +-Version: 9.0.7.p4 +- +-File: lbtf_usb.bin +-Version: 5.132.3.p1 +- +-File: libertas/usb8388_olpc.bin +-Version: 5.110.22.p23 +- +-Licence: Redistributable. See LICENCE.OLPC for details. +- +-Available from http://dev.laptop.org/pub/firmware/libertas/ +- +--------------------------------------------------------------------------- +- +-Driver: mwl8k - Marvell Libertas softmac-type 802.11b/g/n cards +- +-File: mwl8k/fmimage_8687.fw +-File: mwl8k/helper_8687.fw +-File: mwl8k/fmimage_8366.fw +-File: mwl8k/fmimage_8366_ap-1.fw +-File: mwl8k/fmimage_8366_ap-2.fw +-File: mwl8k/fmimage_8366_ap-3.fw +-Version: 5.2.8.16 +-File: mwl8k/helper_8366.fw +- +-File: mwl8k/fmimage_8764_ap-1.fw +-Version: 7.4.0.9 +- +-Licence: Redistributable. See LICENCE.Marvell for details. 8687 images +-downloaded from Marvell's "Extranet" with permission. 8366 images contributed +-directly by Marvell. +- +--------------------------------------------------------------------------- +- +-Driver: mwifiex - Marvell Wi-Fi fullmac-type 802.11n/ac cards +- +-File: mrvl/sd8787_uapsta.bin +-Version: W14.68.35.p66 +- +-File: mrvl/usb8766_uapsta.bin +-Version: 14.68.22.p16 +- +-File: mrvl/sd8797_uapsta.bin +-Version: W14.68.29.p59 +- +-File: mrvl/usb8797_uapsta.bin +-Version: W14.68.29.p60 +- +-File: mrvl/sd8897_uapsta.bin +-Version: W15.68.19.17 +- +-File: mrvl/usb8897_uapsta.bin +-Version: 15.68.4.p103 +- +-File: mrvl/pcie8897_uapsta.bin +-Version: W15.68.19.p21 +- +-File: mrvl/sd8887_uapsta.bin +-Version: W15.68.7.p189 +- +-File: mrvl/sd8801_uapsta.bin +-Version: W14.68.36.p204 +- +-File: mrvl/usb8801_uapsta.bin +-Version: W14.68.36.p138 +- +-File: mrvl/pcieuart8997_combo_v4.bin +-Version: W16.68.1.p179 +- +-File: mrvl/pcieusb8997_combo_v4.bin +-Version: W16.68.1.p195 +- +-File: mrvl/pcie8997_wlan_v4.bin +-Version: W16.68.1.p195 +- +-File: mrvl/usbusb8997_combo_v4.bin +-Version: W16.68.1.p183 +- +-File: mrvl/sdsd8997_combo_v4.bin +-Version: W16.68.1.p179 +- +-File: mrvl/sdsd8977_combo_v2.bin +-Version: W16.68.1.p195 +- +-Licence: Redistributable. See LICENCE.NXP for details. +-Originates from https://github.com/NXP/mwifiex-firmware.git +- +--------------------------------------------------------------------------- +- +- +-Driver: iwlwifi - Intel Wireless Wifi +- +-File: iwlwifi-3945-2.ucode +-Version: 15.32.2.9 +- +-File: iwlwifi-4965-2.ucode +-Version: 228.61.2.24 +- +-File: iwlwifi-5000-5.ucode +-Version: 8.83.5.1 +- +-File: iwlwifi-5150-2.ucode +-Version: 8.24.2.2 +- +-File: iwlwifi-1000-5.ucode +-Version: 39.31.5.1 +- +-File: iwlwifi-6000-4.ucode +-Version: 9.221.4.1 +- +-File: iwlwifi-6050-5.ucode +-Version: 41.28.5.1 +- +-File: iwlwifi-6000g2a-6.ucode +-Version: 18.168.6.1 +- +-File: iwlwifi-6000g2b-6.ucode +-Version: 18.168.6.1 +- +-File: iwlwifi-135-6.ucode +-Version: 18.168.6.1 +- +-File: iwlwifi-100-5.ucode +-Version: 39.31.5.1 +- +-File: iwlwifi-105-6.ucode +-Version: 18.168.6.1 +- +-File: iwlwifi-2030-6.ucode +-Version: 18.168.6.1 +- +-File: iwlwifi-2000-6.ucode +-Version: 18.168.6.1 +- +-File: iwlwifi-7260-17.ucode +-Version: 17.bfb58538.0 +- +-File: iwlwifi-3160-17.ucode +-Version: 17.bfb58538.0 +- +-File: iwlwifi-7265-17.ucode +-Version: 17.bfb58538.0 +- +-File: iwlwifi-7265D-29.ucode +-Version: 29.f2390aa8.0 +- +-File: iwlwifi-3168-29.ucode +-Version: 29.0bd893f3.0 +- +-File: iwlwifi-8000C-34.ucode +-Version: 34.610288.0 +- +-File: iwlwifi-8000C-36.ucode +-Version: 36.ca7b901d.0 +- +-File: iwlwifi-8265-34.ucode +-Version: 34.610288.0 +- +-File: iwlwifi-8265-36.ucode +-Version: 36.ca7b901d.0 +- +-File: iwlwifi-9000-pu-b0-jf-b0-34.ucode +-Version: 34.ba501b11.0 +- +-File: iwlwifi-9000-pu-b0-jf-b0-38.ucode +-Version: 38.755cfdd8.0 +- +-File: iwlwifi-9000-pu-b0-jf-b0-46.ucode +-Version: 46.ff18e32a.0 +- +-File: iwlwifi-9260-th-b0-jf-b0-34.ucode +-Version: 34.ba501b11.0 +- +-File: iwlwifi-9260-th-b0-jf-b0-38.ucode +-Version: 38.755cfdd8.0 +- +-File: iwlwifi-9260-th-b0-jf-b0-46.ucode +-Version: 46.ff18e32a.0 +- +-File: iwlwifi-cc-a0-50.ucode +-Version: 50.3e391d3e.0 +- +-File: iwlwifi-Qu-b0-hr-b0-50.ucode +-Version: 50.3e391d3e.0 +- +-File: iwlwifi-Qu-b0-jf-b0-50.ucode +-Version: 50.3e391d3e.0 +- +-File: iwlwifi-Qu-c0-hr-b0-50.ucode +-Version: 50.3e391d3e.0 +- +-File: iwlwifi-Qu-c0-jf-b0-50.ucode +-Version: 50.3e391d3e.0 +- +-File: iwlwifi-QuZ-a0-hr-b0-50.ucode +-Version: 50.3e391d3e.0 +- +-File: iwlwifi-QuZ-a0-jf-b0-50.ucode +-Version: 50.3e391d3e.0 +- +-File: iwlwifi-cc-a0-59.ucode +-Version: 59.601f3a66.0 +- +-File: iwlwifi-Qu-b0-hr-b0-59.ucode +-Version: 59.601f3a66.0 +- +-File: iwlwifi-Qu-b0-jf-b0-59.ucode +-Version: 59.601f3a66.0 +- +-File: iwlwifi-Qu-c0-hr-b0-59.ucode +-Version: 59.601f3a66.0 +- +-File: iwlwifi-Qu-c0-jf-b0-59.ucode +-Version: 59.601f3a66.0 +- +-File: iwlwifi-QuZ-a0-hr-b0-59.ucode +-Version: 59.601f3a66.0 +- +-File: iwlwifi-QuZ-a0-jf-b0-59.ucode +-Version: 59.601f3a66.0 +- +-File: iwlwifi-so-a0-gf-a0.pnvm +- +-File: iwlwifi-so-a0-gf4-a0.pnvm +- +-File: iwlwifi-ty-a0-gf-a0-59.ucode +-Version: 59.601f3a66.0 +- +-File: iwlwifi-cc-a0-66.ucode +-Version: 66.f1c864e0.0 +- +-File: iwlwifi-Qu-b0-hr-b0-66.ucode +-Version: 66.f1c864e0.0 +- +-File: iwlwifi-Qu-b0-jf-b0-66.ucode +-Version: 66.f1c864e0.0 +- +-File: iwlwifi-Qu-c0-hr-b0-66.ucode +-Version: 66.f1c864e0.0 +- +-File: iwlwifi-Qu-c0-jf-b0-66.ucode +-Version: 66.f1c864e0.0 +- +-File: iwlwifi-QuZ-a0-hr-b0-66.ucode +-Version: 66.f1c864e0.0 +- +-File: iwlwifi-QuZ-a0-jf-b0-66.ucode +-Version: 66.f1c864e0.0 +- +-File: iwlwifi-ty-a0-gf-a0-66.ucode +-Version: 66.f1c864e0.0 +- +-File: iwlwifi-cc-a0-72.ucode +-Version: 72.daa05125.0 +- +-File: iwlwifi-Qu-b0-hr-b0-72.ucode +-Version: 72.daa05125.0 +- +-File: iwlwifi-Qu-b0-jf-b0-72.ucode +-Version: 72.daa05125.0 +- +-File: iwlwifi-Qu-c0-hr-b0-72.ucode +-Version: 72.daa05125.0 +- +-File: iwlwifi-Qu-c0-jf-b0-72.ucode +-Version: 72.daa05125.0 +- +-File: iwlwifi-QuZ-a0-hr-b0-72.ucode +-Version: 72.daa05125.0 +- +-File: iwlwifi-QuZ-a0-jf-b0-72.ucode +-Version: 72.daa05125.0 +- +-File: iwlwifi-ty-a0-gf-a0-72.ucode +-Version: 72.a764baac.0 +- +-File: iwlwifi-so-a0-gf4-a0-72.ucode +-Version: 72.a764baac.0 +- +-File: iwlwifi-so-a0-gf-a0-72.ucode +-Version: 72.a764baac.0 +- +-File: iwlwifi-so-a0-hr-b0-72.ucode +-Version: 72.daa05125.0 +- +-File: iwlwifi-so-a0-jf-b0-72.ucode +-Version: 72.daa05125.0 +- +-File: iwlwifi-cc-a0-73.ucode +-Version: 73.35c0a2c6.0 +- +-File: iwlwifi-Qu-b0-hr-b0-73.ucode +-Version: 73.35c0a2c6.0 +- +-File: iwlwifi-Qu-b0-jf-b0-73.ucode +-Version: 73.35c0a2c6.0 +- +-File: iwlwifi-Qu-c0-hr-b0-73.ucode +-Version: 73.35c0a2c6.0 +- +-File: iwlwifi-Qu-c0-jf-b0-73.ucode +-Version: 73.35c0a2c6.0 +- +-File: iwlwifi-QuZ-a0-hr-b0-73.ucode +-Version: 73.35c0a2c6.0 +- +-File: iwlwifi-QuZ-a0-jf-b0-73.ucode +-Version: 73.35c0a2c6.0 +- +-File: iwlwifi-ty-a0-gf-a0-73.ucode +-Version: 73.35c0a2c6.0 +- +-File: iwlwifi-so-a0-gf4-a0-73.ucode +-Version: 73.35c0a2c6.0 +- +-File: iwlwifi-so-a0-gf-a0-73.ucode +-Version: 73.35c0a2c6.0 +- +-File: iwlwifi-so-a0-hr-b0-73.ucode +-Version: 73.35c0a2c6.0 +- +-File: iwlwifi-so-a0-jf-b0-73.ucode +-Version: 73.35c0a2c6.0 +- +-File: iwlwifi-cc-a0-74.ucode +-Version: 74.a5e9588b.0 +- +-File: iwlwifi-Qu-b0-hr-b0-74.ucode +-Version: 74.a5e9588b.0 +- +-File: iwlwifi-Qu-b0-jf-b0-74.ucode +-Version: 74.a5e9588b.0 +- +-File: iwlwifi-Qu-c0-hr-b0-74.ucode +-Version: 74.a5e9588b.0 +- +-File: iwlwifi-Qu-c0-jf-b0-74.ucode +-Version: 74.a5e9588b.0 +- +-File: iwlwifi-QuZ-a0-hr-b0-74.ucode +-Version: 74.a5e9588b.0 +- +-File: iwlwifi-QuZ-a0-jf-b0-74.ucode +-Version: 74.a5e9588b.0 +- +-File: iwlwifi-ty-a0-gf-a0-74.ucode +-Version: 74.fe17486e.0 +- +-File: iwlwifi-so-a0-gf4-a0-74.ucode +-Version: 74.fe17486e.0 +- +-File: iwlwifi-so-a0-gf-a0-74.ucode +-Version: 74.fe17486e.0 +- +-File: iwlwifi-so-a0-hr-b0-74.ucode +-Version: 74.a5e9588b.0 +- +-File: iwlwifi-so-a0-jf-b0-74.ucode +-Version: 74.a5e9588b.0 +- +-File: iwlwifi-cc-a0-77.ucode +-Version: 74.206b0184.0 +- +-File: iwlwifi-Qu-b0-hr-b0-77.ucode +-Version: 74.206b0184.0 +- +-File: iwlwifi-Qu-b0-jf-b0-77.ucode +-Version: 74.206b0184.0 +- +-File: iwlwifi-Qu-c0-hr-b0-77.ucode +-Version: 74.206b0184.0 +- +-File: iwlwifi-Qu-c0-jf-b0-77.ucode +-Version: 74.206b0184.0 +- +-File: iwlwifi-QuZ-a0-hr-b0-77.ucode +-Version: 74.206b0184.0 +- +-File: iwlwifi-QuZ-a0-jf-b0-77.ucode +-Version: 74.206b0184.0 +- +-File: iwlwifi-ty-a0-gf-a0-77.ucode +-Version: 74.f92b5fed.0 +- +-File: iwlwifi-ty-a0-gf-a0-78.ucode +-Version: 75.3bfdc55f.0 +- +-File: iwlwifi-ty-a0-gf-a0-79.ucode +-Version: 76.27f1c37b.0 +- +-File: iwlwifi-ty-a0-gf-a0-81.ucode +-Version: 78.31fc9ae6.0 +- +-File: iwlwifi-so-a0-gf4-a0-77.ucode +-Version: 74.f92b5fed.0 +- +-File: iwlwifi-so-a0-gf4-a0-78.ucode +-Version: 75.3bfdc55f.0 +- +-File: iwlwifi-so-a0-gf4-a0-79.ucode +-Version: 76.27f1c37b.0 +- +-File: iwlwifi-so-a0-gf4-a0-81.ucode +-Version: 78.31fc9ae6.0 +- +-File: iwlwifi-so-a0-gf-a0-77.ucode +-Version: 74.f92b5fed.0 +- +-File: iwlwifi-so-a0-gf-a0-78.ucode +-Version: 74.3bfdc55f.0 +- +-File: iwlwifi-so-a0-gf-a0-79.ucode +-Version: 75.27f1c37b.0 +- +-File: iwlwifi-so-a0-gf-a0-81.ucode +-Version: 78.31fc9ae6.0 +- +-File: iwlwifi-so-a0-hr-b0-77.ucode +-Version: 74.f92b5fed.0 +- +-File: iwlwifi-so-a0-hr-b0-79.ucode +-Version: 75.27f1c37b.0 +- +-File: iwlwifi-so-a0-hr-b0-81.ucode +-Version: 78.31fc9ae6.0 +- +-File: iwlwifi-so-a0-jf-b0-77.ucode +-Version: 74.f92b5fed.0 +- +-File: iwlwifi-ty-a0-gf-a0.pnvm +- +-Licence: Redistributable. See LICENCE.iwlwifi_firmware for details +- +-Also available from http://wireless.kernel.org/en/users/Drivers/iwlwifi#Firmware +- +--------------------------------------------------------------------------- +- + Driver: tehuti - Tehuti Networks 10G Ethernet + + File: tehuti/bdx.bin +@@ -1226,86 +714,6 @@ Available from http://ldriver.qlogic.com/firmware/netxen_nic/new/ + + -------------------------------------------------------------------------- + +-Driver: rt61pci - Ralink RT2561, RT2561S, RT2661 wireless MACs +- +-File: rt2561.bin +-File: rt2561s.bin +-File: rt2661.bin +- +-Licence: Redistributable. See LICENCE.ralink-firmware.txt for details +- +-Downloaded from http://www.ralinktech.com/ralink/Home/Support/Linux.html +- +--------------------------------------------------------------------------- +- +-Driver: rt73usb - Ralink RT2571W, RT2671 wireless MACs +- +-File: rt73.bin +- +-Licence: Redistributable. See LICENCE.ralink-firmware.txt for details +- +-Downloaded from http://www.ralinktech.com/ralink/Home/Support/Linux.html +- +---------------------------------------------------------------------------- +- +-Driver: mt7601u - MediaTek MT7601U Wireless MACs +- +-File: mediatek/mt7601u.bin +-Version: 34 +-Link: mt7601u.bin -> mediatek/mt7601u.bin +- +-Licence: Redistributable. See LICENCE.ralink_a_mediatek_company_firmware for details +- +-Downloaded from http://www.mediatek.com/en/downloads/ +- +--------------------------------------------------------------------------- +- +-Driver: rt2800pci - Ralink RT2860, RT2890, RT3090, RT3290, RT5390 wireless MACs +- +-File: rt2860.bin +-Version: 40 +- +-File: rt3290.bin +-Version: 37 +- +-Licence: Redistributable. See LICENCE.ralink-firmware.txt for details +- +-Binary file supplied originally by Shiang Tu , latest +-from http://www.mediatek.com/en/downloads1/downloads/ +- +--------------------------------------------------------------------------- +- +-Driver: rt2860sta - Ralink RT3090 wireless MACs +- +-Link: rt3090.bin -> rt2860.bin +- +-Licence: Redistributable. See LICENCE.ralink-firmware.txt for details +- +--------------------------------------------------------------------------- +- +-Driver: rt2800usb - Ralink RT2870, RT3070, RT3071, RT3072, RT5370 wireless MACs +- +-File: rt2870.bin +-Version: 36 +- +-Licence: Redistributable. See LICENCE.ralink-firmware.txt for details +- +-Binary file supplied originally by Shiang Tu , latest +-from http://www.mediatek.com/en/downloads1/downloads/ +- +--------------------------------------------------------------------------- +- +-Driver: rt2870sta - Ralink RT2870, RT3070, RT3071 wireless MACs +- +-Link: rt3070.bin -> rt2870.bin +-File: rt3071.bin +- +-Licence: Redistributable. See LICENCE.ralink-firmware.txt for details +- +-rt3071.bin is a copy of bytes 4096-8191 of rt2870.bin for compatibility. +- +--------------------------------------------------------------------------- +- + Driver: usbdux/usbduxfast/usbduxsigma - usbdux data acquisition cards + + File: usbdux_firmware.bin +@@ -1319,17 +727,6 @@ Provided from the author, Bernd Porr + + -------------------------------------------------------------------------- + +-Driver: ath3k - DFU Driver for Atheros bluetooth chipset AR3011 +- +-File: ath3k-1.fw +-Version: 1.0 +- +-Fix EEPROM radio table issue and change PID to 3005 +- +-Licence: Redistributable. See LICENCE.atheros_firmware for details +- +--------------------------------------------------------------------------- +- + Driver: mga - Matrox G200/G400/G550 + + File: matrox/g200_warp.fw +@@ -2245,17 +1642,6 @@ Licence: Redistributable. + + -------------------------------------------------------------------------- + +-Driver: rtl8192e - Realtek 8192 PCI wireless driver +- +-File: RTL8192E/boot.img +-File: RTL8192E/data.img +-File: RTL8192E/main.img +- +-Licence: Redistributable, provided by Realtek in their driver +- source download. +- +--------------------------------------------------------------------------- +- + Driver: ib_qib - QLogic Infiniband + + File: qlogic/sd7220.fw +@@ -2388,1167 +1774,51 @@ Licence: + + -------------------------------------------------------------------------- + +-Driver: brcmsmac - Broadcom 802.11n softmac wireless LAN driver. ++Driver: vt6656 - VIA VT6656 USB wireless driver + +-File: brcm/bcm43xx-0.fw +-File: brcm/bcm43xx_hdr-0.fw +-Version: 610.812 ++File: vntwusb.fw + +-Licence: Redistributable. See LICENCE.broadcom_bcm43xx for details. ++Licence: Redistributable. See LICENCE.via_vt6656 for details. + + -------------------------------------------------------------------------- + +-Driver: brcmfmac - Broadcom 802.11n fullmac wireless LAN driver. +- +-File: brcm/bcm4329-fullmac-4.bin +-File: brcm/brcmfmac43236b.bin +-File: brcm/brcmfmac4329-sdio.bin +-File: brcm/brcmfmac4330-sdio.bin +-File: brcm/brcmfmac4334-sdio.bin +-File: brcm/brcmfmac4335-sdio.bin +-File: brcm/brcmfmac43241b0-sdio.bin +-File: brcm/brcmfmac43241b4-sdio.bin +-File: brcm/brcmfmac43241b5-sdio.bin +-File: brcm/brcmfmac43242a.bin +-File: brcm/brcmfmac43143.bin +-File: brcm/brcmfmac43143-sdio.bin +-File: brcm/brcmfmac43430a0-sdio.bin +-File: brcm/brcmfmac4350c2-pcie.bin +-File: brcm/brcmfmac4350-pcie.bin +-File: brcm/brcmfmac43569.bin +-File: brcm/brcmfmac4358-pcie.bin +-File: brcm/brcmfmac43602-pcie.bin +-File: brcm/brcmfmac43602-pcie.ap.bin +-File: brcm/brcmfmac4366b-pcie.bin +-File: brcm/brcmfmac4366c-pcie.bin +-File: brcm/brcmfmac4371-pcie.bin +- +-Licence: Redistributable. See LICENCE.broadcom_bcm43xx for details. +- +-File: brcm/brcmfmac4373.bin +-File: cypress/cyfmac43012-sdio.bin +-Link: brcm/brcmfmac43012-sdio.bin -> ../cypress/cyfmac43012-sdio.bin +-File: cypress/cyfmac43012-sdio.clm_blob +-Link: brcm/brcmfmac43012-sdio.clm_blob -> ../cypress/cyfmac43012-sdio.clm_blob +-File: cypress/cyfmac43340-sdio.bin +-Link: brcm/brcmfmac43340-sdio.bin -> ../cypress/cyfmac43340-sdio.bin +-File: cypress/cyfmac43362-sdio.bin +-Link: brcm/brcmfmac43362-sdio.bin -> ../cypress/cyfmac43362-sdio.bin +-File: cypress/cyfmac4339-sdio.bin +-Link: brcm/brcmfmac4339-sdio.bin -> ../cypress/cyfmac4339-sdio.bin +-File: cypress/cyfmac43430-sdio.bin +-Link: brcm/brcmfmac43430-sdio.bin -> ../cypress/cyfmac43430-sdio.bin +-File: cypress/cyfmac43430-sdio.clm_blob +-Link: brcm/brcmfmac43430-sdio.clm_blob -> ../cypress/cyfmac43430-sdio.clm_blob +-File: cypress/cyfmac43455-sdio.bin +-Link: brcm/brcmfmac43455-sdio.bin -> ../cypress/cyfmac43455-sdio.bin +-File: cypress/cyfmac43455-sdio.clm_blob +-Link: brcm/brcmfmac43455-sdio.clm_blob -> ../cypress/cyfmac43455-sdio.clm_blob +-File: cypress/cyfmac4354-sdio.bin +-Link: brcm/brcmfmac4354-sdio.bin -> ../cypress/cyfmac4354-sdio.bin +-File: cypress/cyfmac4354-sdio.clm_blob +-Link: brcm/brcmfmac4354-sdio.clm_blob -> ../cypress/cyfmac4354-sdio.clm_blob +-File: cypress/cyfmac4356-pcie.bin +-Link: brcm/brcmfmac4356-pcie.bin -> ../cypress/cyfmac4356-pcie.bin +-File: cypress/cyfmac4356-pcie.clm_blob +-Link: brcm/brcmfmac4356-pcie.clm_blob -> ../cypress/cyfmac4356-pcie.clm_blob +-File: cypress/cyfmac4356-sdio.bin +-Link: brcm/brcmfmac4356-sdio.bin -> ../cypress/cyfmac4356-sdio.bin +-File: cypress/cyfmac4356-sdio.clm_blob +-Link: brcm/brcmfmac4356-sdio.clm_blob -> ../cypress/cyfmac4356-sdio.clm_blob +-File: cypress/cyfmac43570-pcie.bin +-Link: brcm/brcmfmac43570-pcie.bin -> ../cypress/cyfmac43570-pcie.bin +-File: cypress/cyfmac43570-pcie.clm_blob +-Link: brcm/brcmfmac43570-pcie.clm_blob -> ../cypress/cyfmac43570-pcie.clm_blob +-File: cypress/cyfmac4373-sdio.bin +-Link: brcm/brcmfmac4373-sdio.bin -> ../cypress/cyfmac4373-sdio.bin +-File: cypress/cyfmac4373-sdio.clm_blob +-Link: brcm/brcmfmac4373-sdio.clm_blob -> ../cypress/cyfmac4373-sdio.clm_blob +-File: cypress/cyfmac54591-pcie.bin +-Link: brcm/brcmfmac54591-pcie.bin -> ../cypress/cyfmac54591-pcie.bin +-File: cypress/cyfmac54591-pcie.clm_blob +-Link: brcm/brcmfmac54591-pcie.clm_blob -> ../cypress/cyfmac54591-pcie.clm_blob +- +-Licence: Redistributable. See LICENCE.cypress for details. +- +-File: "brcm/brcmfmac43241b4-sdio.Advantech-MICA-071.txt" +-File: "brcm/brcmfmac43241b4-sdio.Intel Corp.-VALLEYVIEW C0 PLATFORM.txt" +-File: "brcm/brcmfmac4330-sdio.Prowise-PT301.txt" +-File: "brcm/brcmfmac43340-sdio.ASUSTeK COMPUTER INC.-TF103CE.txt" +-File: "brcm/brcmfmac43340-sdio.meegopad-t08.txt" +-File: "brcm/brcmfmac43340-sdio.pov-tab-p1006w-data.txt" +-File: "brcm/brcmfmac43340-sdio.predia-basic.txt" +-File: "brcm/brcmfmac43362-sdio.WC121.txt" +-File: "brcm/brcmfmac43362-sdio.cubietech,cubietruck.txt" +-Link: brcm/brcmfmac43362-sdio.kobo,aura.txt -> brcmfmac43362-sdio.WC121.txt +-Link: brcm/brcmfmac43362-sdio.kobo,tolino-shine2hd.txt -> brcmfmac43362-sdio.WC121.txt +-Link: brcm/brcmfmac43362-sdio.lemaker,bananapro.txt -> brcmfmac43362-sdio.cubietech,cubietruck.txt +-File: "brcm/brcmfmac43430a0-sdio.ilife-S806.txt" +-File: "brcm/brcmfmac43430a0-sdio.jumper-ezpad-mini3.txt" +-File: "brcm/brcmfmac43430a0-sdio.ONDA-V80 PLUS.txt" +-File: "brcm/brcmfmac43430-sdio.AP6212.txt" +-Link: brcm/brcmfmac43430-sdio.sinovoip,bpi-m2-plus.txt -> brcmfmac43430-sdio.AP6212.txt +-Link: brcm/brcmfmac43430-sdio.sinovoip,bpi-m2-zero.txt -> brcmfmac43430-sdio.AP6212.txt +-Link: brcm/brcmfmac43430-sdio.sinovoip,bpi-m2-ultra.txt -> brcmfmac43430-sdio.AP6212.txt +-Link: brcm/brcmfmac43430-sdio.sinovoip,bpi-m3.txt -> brcmfmac43430-sdio.AP6212.txt +-Link: brcm/brcmfmac43430-sdio.friendlyarm,nanopi-r1.txt -> brcmfmac43430-sdio.AP6212.txt +-Link: brcm/brcmfmac43430-sdio.starfive,visionfive-v1.txt -> brcmfmac43430-sdio.AP6212.txt +-Link: brcm/brcmfmac43430-sdio.beagle,beaglev-starlight-jh7100-a1.txt -> brcmfmac43430-sdio.AP6212.txt +-Link: brcm/brcmfmac43430-sdio.beagle,beaglev-starlight-jh7100-r0.txt -> brcmfmac43430-sdio.AP6212.txt +-File: "brcm/brcmfmac43430-sdio.Hampoo-D2D3_Vi8A1.txt" +-File: "brcm/brcmfmac43430-sdio.MUR1DX.txt" +-File: "brcm/brcmfmac43430-sdio.raspberrypi,3-model-b.txt" +-Link: brcm/brcmfmac43430-sdio.raspberrypi,model-zero-w.txt -> brcmfmac43430-sdio.raspberrypi,3-model-b.txt +-Link: brcm/brcmfmac43430-sdio.raspberrypi,model-zero-2-w.txt -> brcmfmac43430-sdio.raspberrypi,3-model-b.txt +-File: "brcm/brcmfmac43455-sdio.acepc-t8.txt" +-File: "brcm/brcmfmac43455-sdio.raspberrypi,3-model-b-plus.txt" +-Link: brcm/brcmfmac43455-sdio.raspberrypi,3-model-a-plus.txt -> brcmfmac43455-sdio.raspberrypi,3-model-b-plus.txt +-File: "brcm/brcmfmac43455-sdio.raspberrypi,4-model-b.txt" +-Link: brcm/brcmfmac43455-sdio.Raspberry\ Pi\ Foundation-Raspberry\ Pi\ 4\ Model\ B.txt -> brcmfmac43455-sdio.raspberrypi,4-model-b.txt +-Link: brcm/brcmfmac43455-sdio.Raspberry\ Pi\ Foundation-Raspberry\ Pi\ Compute\ Module\ 4.txt -> brcmfmac43455-sdio.raspberrypi,4-model-b.txt +-File: "brcm/brcmfmac43455-sdio.MINIX-NEO Z83-4.txt" +-File: "brcm/brcmfmac4356-pcie.gpd-win-pocket.txt" +-File: "brcm/brcmfmac4356-pcie.Intel Corporation-CHERRYVIEW D1 PLATFORM.txt" +-File: "brcm/brcmfmac4356-pcie.Xiaomi Inc-Mipad2.txt" +-File: brcm/brcmfmac4356-sdio.AP6356S.txt +-Link: brcm/brcmfmac4356-sdio.firefly,firefly-rk3399.txt -> brcmfmac4356-sdio.AP6356S.txt +-Link: brcm/brcmfmac4356-sdio.khadas,vim2.txt -> brcmfmac4356-sdio.AP6356S.txt +-Link: brcm/brcmfmac4356-sdio.vamrs,rock960.txt -> brcmfmac4356-sdio.AP6356S.txt +-File: brcm/brcmfmac43455-sdio.AW-CM256SM.txt +-Link: brcm/brcmfmac43455-sdio.beagle,am5729-beagleboneai.txt -> brcmfmac43455-sdio.AW-CM256SM.txt +-Link: brcm/brcmfmac43455-sdio.pine64,pinebook-pro.txt -> brcmfmac43455-sdio.AW-CM256SM.txt +-Link: brcm/brcmfmac43455-sdio.pine64,pinenote-v1.1.txt -> brcmfmac43455-sdio.AW-CM256SM.txt +-Link: brcm/brcmfmac43455-sdio.pine64,pinenote-v1.2.txt -> brcmfmac43455-sdio.AW-CM256SM.txt +-Link: brcm/brcmfmac43455-sdio.pine64,pinephone-pro.txt -> brcmfmac43455-sdio.AW-CM256SM.txt +-Link: brcm/brcmfmac43455-sdio.pine64,quartz64-a.txt -> brcmfmac43455-sdio.AW-CM256SM.txt +-Link: brcm/brcmfmac43455-sdio.pine64,quartz64-b.txt -> brcmfmac43455-sdio.AW-CM256SM.txt +-Link: brcm/brcmfmac43455-sdio.pine64,rockpro64-v2.0.txt -> brcmfmac43455-sdio.AW-CM256SM.txt +-Link: brcm/brcmfmac43455-sdio.pine64,rockpro64-v2.1.txt -> brcmfmac43455-sdio.AW-CM256SM.txt +-Link: brcm/brcmfmac43455-sdio.pine64,soquartz-model-a.txt -> brcmfmac43455-sdio.AW-CM256SM.txt +-Link: brcm/brcmfmac43455-sdio.pine64,soquartz-cm4io.txt -> brcmfmac43455-sdio.AW-CM256SM.txt +-Link: brcm/brcmfmac43455-sdio.pine64,soquartz-blade.txt -> brcmfmac43455-sdio.AW-CM256SM.txt ++Driver: myri10ge - Myri10GE 10GbE NIC driver + +-Licence: GPLv2. See GPL-2 for details. ++File: myri10ge_eth_z8e.dat ++File: myri10ge_ethp_z8e.dat ++File: myri10ge_rss_eth_z8e.dat ++File: myri10ge_rss_ethp_z8e.dat ++File: myri10ge_eth_big_z8e.dat ++File: myri10ge_ethp_big_z8e.dat ++File: myri10ge_rss_eth_big_z8e.dat ++File: myri10ge_rss_ethp_big_z8e.dat ++Version: 1.4.57 ++ ++License: Redistributable. See LICENCE.myri10ge_firmware for details. + + -------------------------------------------------------------------------- ++Driver: ene-ub6250 -- ENE UB6250 SD card reader driver + +-Driver: wl1251 - Texas Instruments 802.11 WLAN driver for WiLink4 chips ++File: ene-ub6250/sd_init1.bin ++File: ene-ub6250/sd_init2.bin ++File: ene-ub6250/sd_rdwr.bin ++File: ene-ub6250/ms_init.bin ++File: ene-ub6250/msp_rdwr.bin ++File: ene-ub6250/ms_rdwr.bin + +-File: ti-connectivity/wl1251-fw.bin +-Version: 4.0.4.3.7 ++Licence: Redistributable. See LICENCE.ene_firmware for details. + +-File: ti-connectivity/wl1251-nvs.bin ++-------------------------------------------------------------------------- + +-Licence: Redistributable. See LICENCE.wl1251 for details. ++Driver: isci -- Intel C600 SAS controller driver + +-The published NVS files are for testing only. Every device needs to +-have a unique NVS which is properly calibrated for best results. +- +-The driver expects to find the firmwares under a ti-connectivity subdirectory. +-So if your system looks for firmwares in /lib/firmware, the firmwares for +-wl12xx chips must be located in /lib/firmware/ti-connectivity/. +- +--------------------------------------------------------------------------- +- +-Driver: wl12xx - Texas Instruments 802.11 WLAN driver for WiLink6/7 chips +- +-File: ti-connectivity/wl1271-fw.bin +-Version: 6.1.0.50.350 (STA-only) +-File: ti-connectivity/wl1271-fw-2.bin +-Version: 6.1.5.50.74 (STA-only) +-File: ti-connectivity/wl1271-fw-ap.bin +-Version: 6.2.1.0.54 (AP-only) +-File: ti-connectivity/wl127x-fw-3.bin +-Version: 6.3.0.0.77 +-File: ti-connectivity/wl127x-fw-plt-3.bin +-Version: 6.3.0.0.77 (PLT-only) +-File: ti-connectivity/wl127x-fw-4-sr.bin +-Version: 6.3.5.0.98 (Single-role) +-File: ti-connectivity/wl127x-fw-4-mr.bin +-Version: 6.5.2.0.15 (Multi-role) +-File: ti-connectivity/wl127x-fw-4-plt.bin +-Version: 6.3.5.0.98 (PLT-only) +-File: ti-connectivity/wl127x-fw-5-sr.bin +-Version: 6.3.10.0.142 (Single-role) +-File: ti-connectivity/wl127x-fw-5-mr.bin +-Version: 6.5.7.0.50 (Multi-role) +-File: ti-connectivity/wl127x-fw-5-plt.bin +-Version: 6.3.10.0.142 (PLT-only) +- +-File: ti-connectivity/wl128x-fw.bin +-Version: 7.1.5.50.74 (STA-only) +-File: ti-connectivity/wl128x-fw-ap.bin +-Version: 7.2.1.0.54 (AP-only) +-File: ti-connectivity/wl128x-fw-3.bin +-Version: 7.3.0.0.77 +-File: ti-connectivity/wl128x-fw-plt-3.bin +-Version: 7.3.0.0.77 +-File: ti-connectivity/wl128x-fw-4-sr.bin +-Version: 7.3.5.0.98 (Single-role) +-File: ti-connectivity/wl128x-fw-4-mr.bin +-Version: 7.5.2.0.15 (Multi-role) +-File: ti-connectivity/wl128x-fw-4-plt.bin +-Version: 7.3.5.0.98 (PLT) +-File: ti-connectivity/wl128x-fw-5-sr.bin +-Version: 7.3.10.0.142 (Single-role) +-File: ti-connectivity/wl128x-fw-5-mr.bin +-Version: 7.5.7.0.50 (Multi-role) +-File: ti-connectivity/wl128x-fw-5-plt.bin +-Version: 7.3.10.2.142 (PLT-only) +- +-File: ti-connectivity/wl127x-nvs.bin +-File: ti-connectivity/wl128x-nvs.bin +-Link: ti-connectivity/wl12xx-nvs.bin -> wl127x-nvs.bin +-Link: ti-connectivity/wl1271-nvs.bin -> wl127x-nvs.bin +- +-Licence: Redistributable. See LICENCE.ti-connectivity for details. +- +-The NVS file includes two parts: +- - radio calibration +- - HW configuration parameters (aka. INI values) +- +-The published NVS files are for testing only. Every device needs to +-hava a unique NVS which is properly calibrated for best results. You +-can find more information about NVS generation for your device here: +- +-http://wireless.kernel.org/en/users/Drivers/wl12xx/calibrator +- +-If you're using a wl127x based device, use a symbolic link called +-wl1271-nvs.bin that links to the wl127x-nvs.bin file. If you are +-using wl128x, link to wl128x-nvs.bin instead. +- +-The driver expects to find the firmwares under a ti-connectivity +-subdirectory. So if your system looks for firmwares in /lib/firmware, +-the firmwares for wl12xx chips must be located in +-/lib/firmware/ti-connectivity/. +- +--------------------------------------------------------------------------- +- +-Driver: wl18xx - Texas Instruments 802.11 WLAN driver for WiLink8 chips +- +-File: ti-connectivity/wl18xx-fw.bin +-Version: 8.2.0.0.100 +-File: ti-connectivity/wl18xx-fw-2.bin +-Version: 8.5.0.0.55 +-File: ti-connectivity/wl18xx-fw-3.bin +-Version: 8.8.0.0.13 +-File: ti-connectivity/wl18xx-fw-4.bin +-Version: 8.9.0.0.79 +- +-Licence: Redistributable. See LICENCE.ti-connectivity for details. +- +-The driver expects to find the firmwares under a ti-connectivity +-subdirectory. So if your system looks for firmwares in /lib/firmware, +-the firmwares for wl18xx chips must be located in +-/lib/firmware/ti-connectivity/. +- +--------------------------------------------------------------------------- +- +-Driver: TI_ST - Texas Instruments bluetooth driver +- +-File: ti-connectivity/TIInit_6.2.31.bts +-Version: 2.44 (TI_P31.123) +-File: ti-connectivity/TIInit_6.6.15.bts +-Version: 2.14 (TI_P6_15.93) +-File: ti-connectivity/TIInit_7.2.31.bts +- +-Licence: Redistributable. See LICENCE.ti-connectivity for details. +- +- TIInit_7.2.31.bts version 7.2.31 +- +- In order to use that file copy it to /lib/firmware/ti-connectivity. +- +--------------------------------------------------------------------------- +- +-Driver: r8712u - Realtek 802.11n WLAN driver for RTL8712U +- +-File: rtlwifi/rtl8712u.bin +-Info: From Vendor's rtl8712_8188_8191_8192SU_usb_linux_v7_0.20100831 +- Reverted rtl8188C_8192C_8192D_usb_linux_v3.4.2_3727.20120404 +- +-Licence: Redistributable. See LICENCE.rtlwifi_firmware.txt for details. +- +--------------------------------------------------------------------------- +- +-Driver: rtl8192ce - Realtek 802.11n WLAN driver for RTL8192CE +- +-File: rtlwifi/rtl8192cfw.bin +-File: rtlwifi/rtl8192cfwU.bin +-File: rtlwifi/rtl8192cfwU_B.bin +-Info: From Vendor's realtek/rtlwifi_linux_mac80211_0019.0320.2014V628 driver +- +-Licence: Redistributable. See LICENCE.rtlwifi_firmware.txt for details. +- +--------------------------------------------------------------------------- +- +-Driver: rtl8192cu - Realtek 802.11n WLAN driver for RTL8192CU +- +-File: rtlwifi/rtl8192cufw.bin +-File: rtlwifi/rtl8192cufw_A.bin +-File: rtlwifi/rtl8192cufw_B.bin +-File: rtlwifi/rtl8192cufw_TMSC.bin +-Info: From Vendor's rtl8188C_8192C_usb_linux_v4.0.1_6911.20130308 driver +- All files extracted from driver/hal/rtl8192c/usb/Hal8192CUHWImg.c +- Relevant variables (CONFIG_BT_COEXISTENCE not set): +- - rtlwifi/rtl8192cufw_A.bin: Rtl8192CUFwUMCACutImgArray +- - rtlwifi/rtl8192cufw_B.bin: Rtl8192CUFwUMCBCutImgArray +- - rtlwifi/rtl8192cufw_TMSC.bin: Rtl8192CUFwTSMCImgArray +- +-Licence: Redistributable. See LICENCE.rtlwifi_firmware.txt for details. +- +--------------------------------------------------------------------------- +- +-Driver: rtl8192se - Realtek 802.11n WLAN driver for RTL8192SE +- +-Info: updated from rtl_92ce_92se_92de_linux_mac80211_0004.0816.2011 driver version +-File: rtlwifi/rtl8192sefw.bin +- +-Licence: Redistributable. See LICENCE.rtlwifi_firmware.txt for details. +- +--------------------------------------------------------------------------- +- +-Driver: rtl8192de - Realtek 802.11n WLAN driver for RTL8192DE +- +-Info: Updated from Realtek version rtl_92ce_92se_92de_8723ae_linux_mac80211_0007.0809.2012 +-File: rtlwifi/rtl8192defw.bin +- +-Licence: Redistributable. See LICENCE.rtlwifi_firmware.txt for details. +- +--------------------------------------------------------------------------- +- +-Driver: rtl8723e - Realtek 802.11n WLAN driver for RTL8723E +- +-Info: Taken from Realtek version rtl_92ce_92se_92de_8723ae_linux_mac80211_0007.0809.2012 +-File: rtlwifi/rtl8723fw.bin +-File: rtlwifi/rtl8723fw_B.bin +- +-Licence: Redistributable. See LICENCE.rtlwifi_firmware.txt for details. +- +--------------------------------------------------------------------------- +- +-Driver: rtl8723be - Realtek 802.11n WLAN driver for RTL8723BE +- +-Info: From Vendor's realtek/rtlwifi_linux_mac80211_0019.0320.2014V628 driver +-File: rtlwifi/rtl8723befw.bin +-Info: Update to version 36 - Sent by Realtek +-File: rtlwifi/rtl8723befw_36.bin +- +-Licence: Redistributable. See LICENCE.rtlwifi_firmware.txt for details. +- +--------------------------------------------------------------------------- +- +-Driver: rtl8723de - Realtek 802.11ac WLAN driver for RTL8723DE +- +-Info: Supplied by Vendor at https://github.com/pkshih/rtlwifi_rtl8723de +-File: rtlwifi/rtl8723defw.bin +- +-Licence: Redistributable. See LICENCE.rtlwifi_firmware.txt for details. +- +--------------------------------------------------------------------------- +- +-Driver: rtl8188ee - Realtek 802.11n WLAN driver for RTL8188EE +- +-Info: Taken from Realtek version rtl_92ce_92se_92de_8723ae_88ee_linux_mac80211_0010.0109.2013 +-File: rtlwifi/rtl8188efw.bin +- +-Licence: Redistributable. See LICENCE.rtlwifi_firmware.txt for details. +- +--------------------------------------------------------------------------- +- +-Driver: rtl8821ae - Realtek 802.11n WLAN driver for RTL8812AE +- +-Info: From Vendor's realtek/rtlwifi_linux_mac80211_0019.0320.2014V628 driver +-File: rtlwifi/rtl8812aefw.bin +-File: rtlwifi/rtl8812aefw_wowlan.bin +- +-Licence: Redistributable. See LICENCE.rtlwifi_firmware.txt for details. +- +--------------------------------------------------------------------------- +- +-Driver: rtl8821ae - Realtek 802.11n WLAN driver for RTL8821AE +- +-Info: From Vendor's realtek/rtlwifi_linux_mac80211_0019.0320.2014V628 driver +-File: rtlwifi/rtl8821aefw.bin +-File: rtlwifi/rtl8821aefw_wowlan.bin +-Info: Update to version 29 - Sent by Realtek +-File: rtlwifi/rtl8821aefw_29.bin +- +-Licence: Redistributable. See LICENCE.rtlwifi_firmware.txt for details. +- +--------------------------------------------------------------------------- +- +-Driver: rtl8822be - Realtek 802.11n WLAN driver for RTL8822BE +- +-Info: Sent to Larry Finger by Realtek engineer Ping-Ke Shih +-File: rtlwifi/rtl8822befw.bin +- +-Licence: Redistributable. See LICENCE.rtlwifi_firmware.txt for details. +- +--------------------------------------------------------------------------- +- +-Driver: rtw88 - Realtek 802.11ac WLAN driver for RTL8822BE and RTL8822CE +- +-Info: Sent to Larry Finger by Realtek engineer Yan-Hsuan Chuang +-File: rtw88/rtw8822b_fw.bin +-File: rtw88/rtw8822c_fw.bin +-File: rtw88/rtw8822c_wow_fw.bin +-File: rtw88/README +-File: rtw88/rtw8723d_fw.bin +-File: rtw88/rtw8821c_fw.bin +- +-Licence: Redistributable. See LICENCE.rtlwifi_firmware.txt for details. +- +- These firmware should be put under /lib/firmware/rtw88/ +- And note that the rtw88 driver is able to support wake-on-wireless LAN +- for RTL8822C devices, after kernel v5.6+. So, make sure the firmware +- rtw88/rtw8822c_wow_fw.bin is also packed, otherwise the firmware load +- fail could be a problem. +- Although RTL8723D devices are 802.11n device, they are also supported +- by rtw88 because the hardware arch is similar. +- +--------------------------------------------------------------------------- +- +-Driver: rtw89 - Realtek 802.11ax WLAN driver for RTL8851B/RTL8852A/RTL8852B/RTL8852C +- +-File: rtw89/rtw8851b_fw.bin +-File: rtw89/rtw8852a_fw.bin +-File: rtw89/rtw8852b_fw.bin +-File: rtw89/rtw8852b_fw-1.bin +-File: rtw89/rtw8852c_fw.bin +- +-Licence: Redistributable. See LICENCE.rtlwifi_firmware.txt for details. +- +--------------------------------------------------------------------------- +- +-Driver: rtl8192ee - Realtek 802.11n WLAN driver for RTL8192EE +- +-Info: Initial version taken from Realtek version +- rtl_92ce_92se_92de_8723ae_88ee_8723be_92ee_linux_mac80211_0017.1224.2013 +- Updated Jan. 14, 2015 with file added by Realtek to +- http://github.com/lwfinger/rtlwifi_new.git. +- Same firmware rtl8192eu_nic.bin so just link them +-Link: rtlwifi/rtl8192eefw.bin -> rtl8192eu_nic.bin +- +-Licence: Redistributable. See LICENCE.rtlwifi_firmware.txt for details. +- +--------------------------------------------------------------------------- +- +-Driver: rtl8723bs - Realtek 802.11n WLAN driver for RTL8723BS +- +-Info: Firmware files extracted from data statements in Realtek driver +- v4.3.5.5_12290.20140916_BTCOEX20140507-4E40. +-File: rtlwifi/rtl8723bs_bt.bin +-Link: rtlwifi/rtl8723bs_nic.bin -> rtl8723bu_nic.bin +-Link: rtlwifi/rtl8723bs_ap_wowlan.bin -> rtl8723bu_ap_wowlan.bin +-Link: rtlwifi/rtl8723bs_wowlan.bin -> rtl8723bu_wowlan.bin +- +-Licence: Redistributable. See LICENCE.rtlwifi_firmware.txt for details. +- +--------------------------------------------------------------------------- +- +-Driver: rtl8xxxu - Realtek 802.11n WLAN driver for RTL8XXX USB devices +- +-Info: rtl8723au taken from Realtek driver +- rtl8723A_WiFi_linux_v4.1.3_6044.20121224 +- Firmware is embedded in the driver as data statements. This info +- has been extracted into a binary file. +-File: rtlwifi/rtl8723aufw_A.bin +-File: rtlwifi/rtl8723aufw_B.bin +-File: rtlwifi/rtl8723aufw_B_NoBT.bin +- +-Info: rtl8723bu taken from Realtek driver +- rtl8723BU_WiFi_linux_v4.3.16_14189.20150519_BTCOEX20150119-5844 +- Firmware is embedded in the driver as data statements. This info +- has been extracted into a binary file. +-File: rtlwifi/rtl8723bu_nic.bin +-File: rtlwifi/rtl8723bu_wowlan.bin +-File: rtlwifi/rtl8723bu_ap_wowlan.bin +- +-Info: rtl8192eu taken from Realtek driver +- rtl8192EU_WiFi_linux_v5.11.2.1-18-g8e7df912b.20210527_COEX20171113-0047 +- Firmware is embedded in the driver as data statements. This info +- has been extracted into a binary file. +-File: rtlwifi/rtl8192eu_nic.bin +-Version: 35.7 +-File: rtlwifi/rtl8192eu_wowlan.bin +-Version: 35.7 +-File: rtlwifi/rtl8192eu_ap_wowlan.bin +-Version: 18.0 +- +-Info: rtl8188fu taken from Realtek driver +- RTL8188FU_Linux_v4.3.23.6_20964.20170110 +- Firmware was embedded in the driver as data statements. This info +- has been extracted into a binary file. +-File: rtlwifi/rtl8188fufw.bin +- +-File: rtlwifi/rtl8710bufw_SMIC.bin +-Version: 16.0 +-File: rtlwifi/rtl8710bufw_UMC.bin +-Version: 16.0 +- +-Info: rtl8188eu taken from Realtek driver version +- v5.2.2.4_25483.20171222. +- Firmware is embedded in the driver as data statements. This info +- has been extracted into a binary file. +-File: rtlwifi/rtl8188eufw.bin +-Version: 28.0 +- +-Info: rtl8192fu taken from Realtek driver version +- v5.8.6.2_35538.20191028_COEX20190910-0d02. +- Firmware is embedded in the driver as data statements. This info +- has been extracted into a binary file. +-File: rtlwifi/rtl8192fufw.bin +-Version: 6.0 +- +-Licence: Redistributable. See LICENCE.rtlwifi_firmware.txt for details. +- +--------------------------------------------------------------------------- +- +-Driver: r8169 - RealTek 8169/8168/8101 ethernet driver. +- +-File: rtl_nic/rtl8168d-1.fw +-File: rtl_nic/rtl8168d-2.fw +-File: rtl_nic/rtl8105e-1.fw +-File: rtl_nic/rtl8168e-1.fw +-File: rtl_nic/rtl8168e-2.fw +- +-File: rtl_nic/rtl8168e-3.fw +-Version: 0.0.4 +- +-File: rtl_nic/rtl8168f-1.fw +-Version: 0.0.5 +- +-File: rtl_nic/rtl8168f-2.fw +-Version: 0.0.4 +- +-File: rtl_nic/rtl8411-1.fw +-Version: 0.0.3 +- +-File: rtl_nic/rtl8411-2.fw +-Version: 0.0.1 +- +-File: rtl_nic/rtl8402-1.fw +-Version: 0.0.1 +- +-File: rtl_nic/rtl8106e-1.fw +-Version: 0.0.1 +- +-File: rtl_nic/rtl8106e-2.fw +-Version: 0.0.1 +- +-File: rtl_nic/rtl8168g-1.fw +-Version: 0.0.3 +- +-File: rtl_nic/rtl8168g-2.fw +-Version: 0.0.1 +- +-File: rtl_nic/rtl8168g-3.fw +-Version: 0.0.1 +- +-File: rtl_nic/rtl8168h-1.fw +-Version: 0.0.2 +- +-File: rtl_nic/rtl8168h-2.fw +-Version: 0.0.2 +- +-File: rtl_nic/rtl8168fp-3.fw +-Version: 0.0.1 +- +-File: rtl_nic/rtl8107e-1.fw +-Version: 0.0.2 +- +-File: rtl_nic/rtl8107e-2.fw +-Version: 0.0.2 +- +-File: rtl_nic/rtl8125a-3.fw +-Version: 0.0.1 +- +-File: rtl_nic/rtl8125b-1.fw +-Version: 0.0.2 +- +-File: rtl_nic/rtl8125b-2.fw +-Version: 0.0.2 +- +-Licence: +- * Copyright © 2011-2013, Realtek Semiconductor Corporation +- * +- * Permission is hereby granted for the distribution of this firmware +- * data in hexadecimal or equivalent format, provided this copyright +- * notice is accompanying it. +- +--------------------------------------------------------------------------- +- +-Driver: r8152 - Realtek RTL8152/RTL8153 Based USB Ethernet Adapters +- +-File: rtl_nic/rtl8153a-2.fw +-File: rtl_nic/rtl8153a-3.fw +-File: rtl_nic/rtl8153a-4.fw +-File: rtl_nic/rtl8153b-2.fw +-File: rtl_nic/rtl8153c-1.fw +-File: rtl_nic/rtl8156a-2.fw +-File: rtl_nic/rtl8156b-2.fw +- +-Licence: Redistributable. See LICENCE.rtlwifi_firmware.txt for details. +- +--------------------------------------------------------------------------- +- +-Driver: vt6656 - VIA VT6656 USB wireless driver +- +-File: vntwusb.fw +- +-Licence: Redistributable. See LICENCE.via_vt6656 for details. +- +--------------------------------------------------------------------------- +- +-Driver: DFU Driver for Atheros bluetooth chipset AR3012 +- +-File: ar3k/AthrBT_0x01020001.dfu +-File: ar3k/ramps_0x01020001_26.dfu +-File: ar3k/AthrBT_0x01020200.dfu +-File: ar3k/ramps_0x01020200_26.dfu +-File: ar3k/ramps_0x01020200_40.dfu +-File: ar3k/AthrBT_0x31010000.dfu +-File: ar3k/ramps_0x31010000_40.dfu +-File: ar3k/AthrBT_0x11020000.dfu +-File: ar3k/ramps_0x11020000_40.dfu +-File: ar3k/ramps_0x01020201_26.dfu +-File: ar3k/ramps_0x01020201_40.dfu +-File: ar3k/AthrBT_0x41020000.dfu +-File: ar3k/ramps_0x41020000_40.dfu +-File: ar3k/AthrBT_0x11020100.dfu +-File: ar3k/ramps_0x11020100_40.dfu +-File: ar3k/AthrBT_0x31010100.dfu +-File: ar3k/ramps_0x31010100_40.dfu +- +-Licence: Redistributable. See LICENCE.atheros_firmware for details +- +--------------------------------------------------------------------------- +- +-Driver: DFU Driver for Atheros bluetooth chipset AR3012 +- +-File: ar3k/AthrBT_0x01020201.dfu +-File: ar3k/1020201coex/ramps_0x01020201_26_HighPriority.dfu +- +-Licence: Redistributable. See LICENSE.QualcommAtheros_ar3k for details +- +--------------------------------------------------------------------------- +- +-Driver:Atheros AR300x UART HCI Bluetooth Chip driver +- +-File: ar3k/1020201/PS_ASIC.pst +-File: ar3k/1020201/RamPatch.txt +-File: ar3k/1020200/ar3kbdaddr.pst +-File: ar3k/1020200/PS_ASIC.pst +-File: ar3k/1020200/RamPatch.txt +-File: ar3k/30101/ar3kbdaddr.pst +-File: ar3k/30101/PS_ASIC.pst +-File: ar3k/30101/RamPatch.txt +-File: ar3k/30000/ar3kbdaddr.pst +-File: ar3k/30000/PS_ASIC.pst +-File: ar3k/30000/RamPatch.txt +- +-Licence: Redistributable. See LICENCE.atheros_firmware for details +- +--------------------------------------------------------------------------- +- +-Driver: ath6kl - Atheros support for AR6003 +- +-File: ath6k/AR6004/hw1.3/fw-3.bin +-File: ath6k/AR6004/hw1.3/bdata.bin +-File: ath6k/AR6004/hw1.2/fw-2.bin +-File: ath6k/AR6004/hw1.2/bdata.bin +-File: ath6k/AR6003/hw1.0/otp.bin.z77 +-File: ath6k/AR6003/hw1.0/bdata.SD31.bin +-File: ath6k/AR6003/hw1.0/bdata.SD32.bin +-File: ath6k/AR6003/hw1.0/data.patch.bin +-File: ath6k/AR6003/hw1.0/bdata.WB31.bin +-File: ath6k/AR6003/hw1.0/athwlan.bin.z77 +-File: ath6k/AR6003/hw2.1.1/fw-2.bin +-File: ath6k/AR6003/hw2.1.1/fw-3.bin +-File: ath6k/AR6003/hw2.1.1/otp.bin +-File: ath6k/AR6003/hw2.1.1/athwlan.bin +-File: ath6k/AR6003/hw2.1.1/endpointping.bin +-File: ath6k/AR6003/hw2.1.1/bdata.SD31.bin +-File: ath6k/AR6003/hw2.1.1/bdata.SD32.bin +-File: ath6k/AR6003/hw2.1.1/data.patch.bin +-File: ath6k/AR6003/hw2.1.1/bdata.WB31.bin +-File: ath6k/AR6003/hw2.0/otp.bin.z77 +-File: ath6k/AR6003/hw2.0/bdata.SD31.bin +-File: ath6k/AR6003/hw2.0/bdata.SD32.bin +-File: ath6k/AR6003/hw2.0/data.patch.bin +-File: ath6k/AR6003/hw2.0/bdata.WB31.bin +-File: ath6k/AR6003/hw2.0/athwlan.bin.z77 +-File: ath6k/AR6002/eeprom.data +-File: ath6k/AR6002/eeprom.bin +-File: ath6k/AR6002/athwlan.bin.z77 +-File: ath6k/AR6002/data.patch.hw2_0.bin +- +-Licence: Redistributable. See LICENCE.atheros_firmware for details +- +--------------------------------------------------------------------------- +- +-Driver: ath10k - Qualcomm Atheros support for QCA988x family of chips +- +-File: ath10k/QCA988X/hw2.0/board.bin +-File: ath10k/QCA988X/hw2.0/firmware-4.bin +-Version: 10.2.4.45 +-File: ath10k/QCA988X/hw2.0/notice_ath10k_firmware-4.txt +-File: ath10k/QCA988X/hw2.0/firmware-5.bin +-Version: 10.2.4-1.0-00047 +-File: ath10k/QCA988X/hw2.0/notice_ath10k_firmware-5.txt +-File: ath10k/QCA6174/hw2.1/board.bin +-File: ath10k/QCA6174/hw2.1/board-2.bin +-File: ath10k/QCA6174/hw2.1/firmware-5.bin +-Version: SW_RM.1.1.1-00157-QCARMSWPZ-1 +-File: ath10k/QCA6174/hw2.1/notice_ath10k_firmware-5.txt +-File: ath10k/QCA6174/hw3.0/board.bin +-File: ath10k/QCA6174/hw3.0/board-2.bin +-File: ath10k/QCA6174/hw3.0/firmware-4.bin +-Version: WLAN.RM.2.0-00180-QCARMSWPZ-1 +-File: ath10k/QCA6174/hw3.0/notice_ath10k_firmware-4.txt +-File: ath10k/QCA6174/hw3.0/firmware-6.bin +-Version: WLAN.RM.4.4.1-00288-QCARMSWPZ-1 +-File: ath10k/QCA6174/hw3.0/notice_ath10k_firmware-6.txt +-File: ath10k/QCA6174/hw3.0/firmware-sdio-6.bin +-Version: WLAN.RMH.4.4.1-00174 +-File: ath10k/QCA6174/hw3.0/notice_ath10k_firmware-sdio-6.txt +-File: ath10k/QCA9377/hw1.0/board.bin +-File: ath10k/QCA9377/hw1.0/board-2.bin +-File: ath10k/QCA9377/hw1.0/firmware-5.bin +-Version: WLAN.TF.1.0-00002-QCATFSWPZ-5 +-File: ath10k/QCA9377/hw1.0/notice_ath10k_firmware-5.txt +-File: ath10k/QCA9377/hw1.0/firmware-sdio-5.bin +-Version: WLAN.TF.1.1.1-00061-QCATFSWPZ-1 +-File: ath10k/QCA9377/hw1.0/notice_ath10k_firmware-sdio-5.txt +-File: ath10k/QCA99X0/hw2.0/board-2.bin +-File: ath10k/QCA99X0/hw2.0/firmware-5.bin +-Version: 10.4.1.00030-1 +-File: ath10k/QCA99X0/hw2.0/notice_ath10k_firmware-5.txt +-File: ath10k/QCA4019/hw1.0/board-2.bin +-File: ath10k/QCA4019/hw1.0/firmware-5.bin +-Version: 10.4-3.6-00140 +-File: ath10k/QCA4019/hw1.0/notice_ath10k_firmware-5.txt +-File: ath10k/QCA9887/hw1.0/board.bin +-File: ath10k/QCA9887/hw1.0/firmware-5.bin +-Version: 10.2.4-1.0-00047 +-File: ath10k/QCA9887/hw1.0/notice_ath10k_firmware-5.txt +-File: ath10k/QCA9888/hw2.0/board-2.bin +-File: ath10k/QCA9888/hw2.0/firmware-5.bin +-Version: 10.4-3.9.0.2-00157 +-File: ath10k/QCA9888/hw2.0/notice_ath10k_firmware-5.txt +-File: ath10k/QCA9984/hw1.0/board-2.bin +-File: ath10k/QCA9984/hw1.0/firmware-5.bin +-Version: 10.4-3.9.0.2-00157 +-File: ath10k/QCA9984/hw1.0/notice_ath10k_firmware-5.txt +-File: ath10k/QCA9377/hw1.0/firmware-6.bin +-Version: WLAN.TF.2.1-00021-QCARMSWP-1 +-File: ath10k/QCA9377/hw1.0/notice_ath10k_firmware-6.txt +-File: ath10k/WCN3990/hw1.0/board-2.bin +-File: ath10k/WCN3990/hw1.0/firmware-5.bin +-File: ath10k/WCN3990/hw1.0/wlanmdsp.mbn +-Link: qcom/sdm845/wlanmdsp.mbn -> ../../ath10k/WCN3990/hw1.0/wlanmdsp.mbn +-Version: WLAN.HL.2.0-01387-QCAHLSWMTPLZ-1 +-File: ath10k/WCN3990/hw1.0/notice.txt_wlanmdsp +- +-Licence: Redistributable. See LICENSE.QualcommAtheros_ath10k for details +- +--------------------------------------------------------------------------- +- +-Driver: ath11k - Qualcomm Technologies 802.11ax chipset support +- +-File: ath11k/IPQ6018/hw1.0/board-2.bin +-File: ath11k/IPQ6018/hw1.0/m3_fw.b00 +-File: ath11k/IPQ6018/hw1.0/m3_fw.b01 +-File: ath11k/IPQ6018/hw1.0/m3_fw.b02 +-File: ath11k/IPQ6018/hw1.0/m3_fw.flist +-File: ath11k/IPQ6018/hw1.0/m3_fw.mdt +-File: ath11k/IPQ6018/hw1.0/q6_fw.b00 +-File: ath11k/IPQ6018/hw1.0/q6_fw.b01 +-File: ath11k/IPQ6018/hw1.0/q6_fw.b02 +-File: ath11k/IPQ6018/hw1.0/q6_fw.b03 +-File: ath11k/IPQ6018/hw1.0/q6_fw.b04 +-File: ath11k/IPQ6018/hw1.0/q6_fw.b05 +-File: ath11k/IPQ6018/hw1.0/q6_fw.b07 +-File: ath11k/IPQ6018/hw1.0/q6_fw.b08 +-File: ath11k/IPQ6018/hw1.0/q6_fw.flist +-File: ath11k/IPQ6018/hw1.0/q6_fw.mdt +-Version: WLAN.HK.2.7.0.1-01744-QCAHKSWPL_SILICONZ-1 +-File: ath11k/IPQ6018/hw1.0/Notice.txt +-File: ath11k/IPQ8074/hw2.0/board-2.bin +-File: ath11k/IPQ8074/hw2.0/m3_fw.b00 +-File: ath11k/IPQ8074/hw2.0/m3_fw.b01 +-File: ath11k/IPQ8074/hw2.0/m3_fw.b02 +-File: ath11k/IPQ8074/hw2.0/m3_fw.flist +-File: ath11k/IPQ8074/hw2.0/m3_fw.mdt +-File: ath11k/IPQ8074/hw2.0/q6_fw.b00 +-File: ath11k/IPQ8074/hw2.0/q6_fw.b01 +-File: ath11k/IPQ8074/hw2.0/q6_fw.b02 +-File: ath11k/IPQ8074/hw2.0/q6_fw.b03 +-File: ath11k/IPQ8074/hw2.0/q6_fw.b04 +-File: ath11k/IPQ8074/hw2.0/q6_fw.b05 +-File: ath11k/IPQ8074/hw2.0/q6_fw.b07 +-File: ath11k/IPQ8074/hw2.0/q6_fw.b08 +-File: ath11k/IPQ8074/hw2.0/q6_fw.flist +-File: ath11k/IPQ8074/hw2.0/q6_fw.mdt +-Version: WLAN.HK.2.7.0.1-01744-QCAHKSWPL_SILICONZ-1 +-File: ath11k/IPQ8074/hw2.0/Notice.txt +-File: ath11k/QCA6390/hw2.0/board-2.bin +-File: ath11k/QCA6390/hw2.0/amss.bin +-File: ath11k/QCA6390/hw2.0/m3.bin +-Version: WLAN.HST.1.0.1-05266-QCAHSTSWPLZ_V2_TO_X86-1 +-File: ath11k/QCA6390/hw2.0/Notice.txt +-File: ath11k/WCN6855/hw2.0/regdb.bin +-File: ath11k/WCN6855/hw2.0/board-2.bin +-File: ath11k/WCN6855/hw2.0/amss.bin +-File: ath11k/WCN6855/hw2.0/m3.bin +-Version: WLAN.HSP.1.1-03125-QCAHSPSWPL_V1_V2_SILICONZ_LITE-3.6510.23 +-File: ath11k/WCN6855/hw2.0/Notice.txt +-Link: ath11k/WCN6855/hw2.1/regdb.bin -> ../hw2.0/regdb.bin +-Link: ath11k/WCN6855/hw2.1/board-2.bin -> ../hw2.0/board-2.bin +-Link: ath11k/WCN6855/hw2.1/amss.bin -> ../hw2.0/amss.bin +-Link: ath11k/WCN6855/hw2.1/m3.bin -> ../hw2.0/m3.bin +-File: ath11k/QCN9074/hw1.0/board-2.bin +-File: ath11k/QCN9074/hw1.0/amss.bin +-File: ath11k/QCN9074/hw1.0/m3.bin +-Version: WLAN.HK.2.7.0.1-01744-QCAHKSWPL_SILICONZ-1 +-File: ath11k/QCN9074/hw1.0/Notice.txt +-File: ath11k/WCN6750/hw1.0/board-2.bin +-File: ath11k/WCN6750/hw1.0/wpss.b00 +-File: ath11k/WCN6750/hw1.0/wpss.b01 +-File: ath11k/WCN6750/hw1.0/wpss.b02 +-File: ath11k/WCN6750/hw1.0/wpss.b03 +-File: ath11k/WCN6750/hw1.0/wpss.b04 +-File: ath11k/WCN6750/hw1.0/wpss.b05 +-File: ath11k/WCN6750/hw1.0/wpss.b06 +-File: ath11k/WCN6750/hw1.0/wpss.b07 +-File: ath11k/WCN6750/hw1.0/wpss.b08 +-File: ath11k/WCN6750/hw1.0/wpss.mdt +-Version: WLAN.MSL.1.0.1-01160-QCAMSLSWPLZ-1 +-File: ath11k/WCN6750/hw1.0/Notice.txt +-File: ath11k/IPQ5018/hw1.0/board-2.bin +-File: ath11k/IPQ5018/hw1.0/m3_fw.b00 +-File: ath11k/IPQ5018/hw1.0/m3_fw.b01 +-File: ath11k/IPQ5018/hw1.0/m3_fw.b02 +-File: ath11k/IPQ5018/hw1.0/m3_fw.flist +-File: ath11k/IPQ5018/hw1.0/m3_fw.mdt +-File: ath11k/IPQ5018/hw1.0/q6_fw.b00 +-File: ath11k/IPQ5018/hw1.0/q6_fw.b01 +-File: ath11k/IPQ5018/hw1.0/q6_fw.b02 +-File: ath11k/IPQ5018/hw1.0/q6_fw.b03 +-File: ath11k/IPQ5018/hw1.0/q6_fw.b04 +-File: ath11k/IPQ5018/hw1.0/q6_fw.b05 +-File: ath11k/IPQ5018/hw1.0/q6_fw.b07 +-File: ath11k/IPQ5018/hw1.0/q6_fw.b08 +-File: ath11k/IPQ5018/hw1.0/q6_fw.b09 +-File: ath11k/IPQ5018/hw1.0/q6_fw.b10 +-File: ath11k/IPQ5018/hw1.0/q6_fw.b11 +-File: ath11k/IPQ5018/hw1.0/q6_fw.b13 +-File: ath11k/IPQ5018/hw1.0/q6_fw.b14 +-File: ath11k/IPQ5018/hw1.0/q6_fw.flist +-File: ath11k/IPQ5018/hw1.0/q6_fw.mdt +-Version: WLAN.HK.2.6.0.1-00861-QCAHKSWPL_SILICONZ-1 +-File: ath11k/IPQ5018/hw1.0/Notice.txt +- +-Licence: Redistributable. See LICENSE.QualcommAtheros_ath10k for details +- +--------------------------------------------------------------------------- +- +-Driver: myri10ge - Myri10GE 10GbE NIC driver +- +-File: myri10ge_eth_z8e.dat +-File: myri10ge_ethp_z8e.dat +-File: myri10ge_rss_eth_z8e.dat +-File: myri10ge_rss_ethp_z8e.dat +-File: myri10ge_eth_big_z8e.dat +-File: myri10ge_ethp_big_z8e.dat +-File: myri10ge_rss_eth_big_z8e.dat +-File: myri10ge_rss_ethp_big_z8e.dat +-Version: 1.4.57 +- +-License: Redistributable. See LICENCE.myri10ge_firmware for details. +- +--------------------------------------------------------------------------- +- +-Driver: ath6kl - Atheros support for AR6003 WiFi-Bluetooth combo module +- +-File: ath6k/AR6003.1/hw2.1.1/athwlan.bin +-File: ath6k/AR6003.1/hw2.1.1/bdata.SD31.bin +-File: ath6k/AR6003.1/hw2.1.1/bdata.SD32.bin +-File: ath6k/AR6003.1/hw2.1.1/bdata.WB31.bin +-File: ath6k/AR6003.1/hw2.1.1/data.patch.bin +-File: ath6k/AR6003.1/hw2.1.1/endpointping.bin +-File: ath6k/AR6003.1/hw2.1.1/otp.bin +- +-License: Redistributable. See LICENCE.atheros_firmware for details +- +--------------------------------------------------------------------------- +- +-Driver: ath6kl - Atheros support for AR3001 WiFi-Bluetooth combo module +- +-File: ar3k/30101coex/ar3kbdaddr.pst +-File: ar3k/30101coex/PS_ASIC_aclLowPri.pst +-File: ar3k/30101coex/PS_ASIC_aclHighPri.pst +-File: ar3k/30101coex/PS_ASIC.pst +-File: ar3k/30101coex/RamPatch.txt +- +-License: Redistributable. See LICENCE.atheros_firmware for details +- +--------------------------------------------------------------------------- +- +-Driver: ene-ub6250 -- ENE UB6250 SD card reader driver +- +-File: ene-ub6250/sd_init1.bin +-File: ene-ub6250/sd_init2.bin +-File: ene-ub6250/sd_rdwr.bin +-File: ene-ub6250/ms_init.bin +-File: ene-ub6250/msp_rdwr.bin +-File: ene-ub6250/ms_rdwr.bin +- +-Licence: Redistributable. See LICENCE.ene_firmware for details. +- +--------------------------------------------------------------------------- +- +-Driver: isci -- Intel C600 SAS controller driver +- +-File: isci/isci_firmware.bin +-Source: isci/ ++File: isci/isci_firmware.bin ++Source: isci/ + + Licence: GPLv2. See GPL-2 for details. + + -------------------------------------------------------------------------- + +-Driver: ar5523 -- Atheros AR5523 based USB Wifi dongles +- +-File: ar5523.bin +- +-Licence: Redistributable. See LICENCE.atheros_firmware for details +- +--------------------------------------------------------------------------- +- +-Driver: carl9170 -- Atheros AR9170 802.11 draft-n USB driver +- +-File: carl9170-1.fw +-Version: 1.9.6 +-Source: carl9170fw/ +- +-Downloaded from http://linuxwireless.org/en/users/Drivers/carl9170 +- +-Licence: GPLv2. Some build scripts use the New BSD (3-clause) licence.. See GPL-2 for details. +- +--------------------------------------------------------------------------- +- +-Driver: btusb - Bluetooth USB driver +- +-File: intel/ibt-hw-37.7.bseq +-Version: 1316.02.00 +-File: intel/ibt-hw-37.7.10-fw-1.80.2.3.d.bseq +-Version: BT_WilkinsPeak_B3_REL_87_0001 +-File: intel/ibt-hw-37.7.10-fw-1.0.2.3.d.bseq +-Version: BT_WilkinsPeak_B3_REL_87_0001 +-File: intel/ibt-hw-37.7.10-fw-1.80.1.2d.d.bseq +-Version: BT_WilkinsPeak_B5_REL_42_0001 +-File: intel/ibt-hw-37.7.10-fw-1.0.1.2d.d.bseq +-Version: BT_WilkinsPeak_B5_REL_42_0001 +-File: intel/ibt-hw-37.8.bseq +-Version: 1339_02.00 +-File: intel/ibt-hw-37.8.10-fw-1.10.2.27.d.bseq +-Version: BT_StonePeak_C0_REL_59_0001 +-File: intel/ibt-hw-37.8.10-fw-1.10.3.11.e.bseq +-Version: BT_StonePeak_D0_REL_50_0002 +-File: intel/ibt-hw-37.8.10-fw-22.50.19.14.f.bseq +-Version: BT_StonePeak_D1_REL_67_1278 +-File: intel/ibt-11-5.ddc +-Version: LnP/SfP_REL1294 +-File: intel/ibt-11-5.sfi +-Version: BT_LightningPeak_REL0487 +-File: intel/ibt-12-16.ddc +-Version: BT_WindStormPeak_REL1299 +-File: intel/ibt-12-16.sfi +-Version: BT_WindStormPeak_REL1299 +-File: intel/ibt-17-16-1.sfi +-Version: BT_JeffersonPeak_B0_B0_REL20332 +-File: intel/ibt-17-16-1.ddc +-Version: BT_JeffersonPeak_B0_B0_REL20332 +-File: intel/ibt-17-2.sfi +-Version: BT_JeffersonPeak_B0_B0_REL20332 +-File: intel/ibt-17-2.ddc +-Version: BT_JeffersonPeak_B0_B0_REL20332 +-File: intel/ibt-17-0-1.sfi +-Version: BT_JeffersonPeak_A0_B0_REL0201 +-File: intel/ibt-17-0-1.ddc +-Version: BT_JeffersonPeak_A0_B0_REL0201 +-File: intel/ibt-17-1.sfi +-Version: BT_JeffersonPeak_A0_B0_REL0201 +-File: intel/ibt-17-1.ddc +-Version: BT_JeffersonPeak_A0_B0_REL0201 +-File: intel/ibt-18-16-1.sfi +-Version: BT_ThunderPeak_B0_B0_REL20182 +-File: intel/ibt-18-16-1.ddc +-Version: BT_ThunderPeak_B0_B0_REL20182 +-File: intel/ibt-18-2.sfi +-Version: BT_ThunderPeak_B0_B0_REL20182 +-File: intel/ibt-18-2.ddc +-Version: BT_ThunderPeak_B0_B0_REL20182 +-File: intel/ibt-18-0-1.sfi +-Version: BT_ThunderPeak_A0_B0_REL0201 +-File: intel/ibt-18-0-1.ddc +-Version: BT_ThunderPeak_A0_B0_REL0201 +-File: intel/ibt-18-1.sfi +-Version: BT_ThunderPeak_A0_B0_REL0201 +-File: intel/ibt-18-1.ddc +-Version: BT_ThunderPeak_A0_B0_REL0201 +-File:intel/ibt-20-0-3.sfi +-Version: BT_CyclonePeak_A0_REL53392 +-File:intel/ibt-20-0-3.ddc +-Version: BT_CyclonePeak_A0_REL53392 +-File:intel/ibt-20-1-3.sfi +-Version: BT_CyclonePeak_A0_REL53392 +-File:intel/ibt-20-1-3.ddc +-Version: BT_CyclonePeak_A0_REL53392 +-File:intel/ibt-20-1-4.sfi +-Version: BT_CyclonePeak_A0_REL53392 +-File:intel/ibt-20-1-4.ddc +-Version: BT_CyclonePeak_A0_REL53392 +-File:intel/ibt-19-0-0.sfi +-Version: BT_Quasar_REL53392 +-File:intel/ibt-19-0-0.ddc +-Version: BT_Quasar_REL53392 +-File:intel/ibt-19-0-1.sfi +-Version: BT_Quasar_REL53392 +-File:intel/ibt-19-0-1.ddc +-Version: BT_Quasar_REL53392 +-File:intel/ibt-19-0-3.sfi +-Version: BT_Quasar_REL53263 +-File:intel/ibt-19-0-3.ddc +-Version: BT_Quasar_REL53263 +-File:intel/ibt-19-0-4.sfi +-Version: BT_HarrisonPeak_REL53392 +-File:intel/ibt-19-0-4.ddc +-Version: BT_HarrisonPeak_REL53392 +-File:intel/ibt-19-16-4.sfi +-Version: BT_HarrisonPeak_REL53392 +-File:intel/ibt-19-16-4.ddc +-Version: BT_HarrisonPeak_REL53392 +-File:intel/ibt-19-32-1.sfi +-Version: BT_HarrisonPeak_REL53392 +-File:intel/ibt-19-32-1.ddc +-Version: BT_HarrisonPeak_REL53392 +-File:intel/ibt-19-32-0.sfi +-Version: BT_HarrisonPeak_REL53392 +-File:intel/ibt-19-32-0.ddc +-Version: BT_HarrisonPeak_REL53392 +-File:intel/ibt-19-32-4.sfi +-Version: BT_HarrisonPeak_REL53392 +-File:intel/ibt-19-32-4.ddc +-Version: BT_HarrisonPeak_REL53392 +-File:intel/ibt-19-240-1.sfi +-Version: BT_HarrisonPeak_REL53392 +-File:intel/ibt-19-240-1.ddc +-Version: BT_HarrisonPeak_REL53392 +-File:intel/ibt-19-240-4.sfi +-Version: BT_HarrisonPeak_REL53392 +-File:intel/ibt-19-240-4.ddc +-Version: BT_HarrisonPeak_REL53392 +-File:intel/ibt-0041-0041.sfi +-Version: BT_TyphoonPeak_REL62562 +-File:intel/ibt-0041-0041.ddc +-Version: BT_TyphoonPeak_REL62562 +-File:intel/ibt-0040-0041.sfi +-Version: BT_Solar_GfP2_REL62562 +-File:intel/ibt-0040-0041.ddc +-Version: BT_Solar_GfP2_REL62562 +-File:intel/ibt-1040-0041.sfi +-Version: BT_SolarF_GfP2_REL62562 +-File:intel/ibt-1040-0041.ddc +-Version: BT_SolarF_GfP2_REL62562 +- +-File:intel/ibt-0040-1020.sfi +-Version: BT_Solar_JfP1_REL59564 +-File:intel/ibt-0040-1020.ddc +-Version: BT_Solar_JfP1_REL59564 +-File:intel/ibt-1040-1020.sfi +-Version: BT_SolarF_JfP1_REL59564 +-File:intel/ibt-1040-1020.ddc +-Version: BT_SolarF_JfP1_REL59564 +- +-File:intel/ibt-0040-2120.sfi +-Version: BT_Solar_JfP2_REL52159 +-File:intel/ibt-0040-2120.ddc +-Version: BT_Solar_JfP2_REL52159 +-File:intel/ibt-1040-2120.sfi +-Version: BT_SolarF_JfP2_REL59564 +-File:intel/ibt-1040-2120.ddc +-Version: BT_SolarF_JfP2_REL59564 +- +-File:intel/ibt-0040-4150.sfi +-Version: BT_Solar_JnP2_REL62562 +-File:intel/ibt-0040-4150.ddc +-Version: BT_Solar_JnP2_REL62562 +-File:intel/ibt-1040-4150.sfi +-Version: BT_SolarF_JnP2_REL62562 +-File:intel/ibt-1040-4150.ddc +-Version: BT_SolarF_JnP2_REL62562 +- +-Licence: Redistributable. See LICENCE.ibt_firmware for details +- +-File: rtl_bt/rtl8192ee_fw.bin +-File: rtl_bt/rtl8192eu_fw.bin +-File: rtl_bt/rtl8723a_fw.bin +-File: rtl_bt/rtl8723b_fw.bin +-File: rtl_bt/rtl8723bs_fw.bin +-File: rtl_bt/rtl8723bs_config-OBDA8723.bin +-Link: rtl_bt/rtl8723bs_config-OBDA0623.bin -> rtl8723bs_config-OBDA8723.bin +-File: rtl_bt/rtl8761a_fw.bin +-File: rtl_bt/rtl8761b_fw.bin +-File: rtl_bt/rtl8761b_config.bin +-File: rtl_bt/rtl8761bu_fw.bin +-File: rtl_bt/rtl8761bu_config.bin +-File: rtl_bt/rtl8812ae_fw.bin +-File: rtl_bt/rtl8821a_fw.bin +-Link: rtl_bt/rtl8821a_config.bin -> rtl8821c_config.bin +-File: rtl_bt/rtl8822b_fw.bin +-File: rtl_bt/rtl8822b_config.bin +-File: rtl_bt/rtl8723d_fw.bin +-File: rtl_bt/rtl8723d_config.bin +-File: rtl_bt/rtl8821c_fw.bin +-File: rtl_bt/rtl8821c_config.bin +-File: rtl_bt/rtl8821cs_fw.bin +-File: rtl_bt/rtl8821cs_config.bin +-File: rtl_bt/rtl8822cu_fw.bin +-File: rtl_bt/rtl8822cu_config.bin +-File: rtl_bt/rtl8822cs_fw.bin +-File: rtl_bt/rtl8822cs_config.bin +-File: rtl_bt/rtl8852au_fw.bin +-File: rtl_bt/rtl8852au_config.bin +-File: rtl_bt/rtl8852bu_fw.bin +-File: rtl_bt/rtl8852bu_config.bin +-File: rtl_bt/rtl8852cu_fw.bin +-File: rtl_bt/rtl8852cu_config.bin +-File: rtl_bt/rtl8851bu_fw.bin +-File: rtl_bt/rtl8851bu_config.bin +- +-Licence: Redistributable. See LICENCE.rtlwifi_firmware.txt for details. +- +-Found in vendor driver, linux_bt_usb_2.11.20140423_8723be.rar +-From https://github.com/troy-tan/driver_store +-Files rtl_bt/rtl8822b_* came directly from Realtek. These files are +-updated on April 14, 2017. +- +-Found in vendor driver, 20200806_LINUX_BT_DRIVER_RTL8761B_COEX_v0202.zip +-File rtl_bt/rtl8761b_config.bin +-File rtl_bt/rtl8761bu_config.bin +- +--------------------------------------------------------------------------- +- +-Driver: btmtk_usb - Bluetooth USB driver +- +-File: mediatek/mt7650.bin +-Link: mt7650.bin -> mediatek/mt7650.bin +- +-Licence: Redistributable. See LICENCE.ralink_a_mediatek_company_firmware for details +- +--------------------------------------------------------------------------- +- + Driver: rp2 -- Comtrol RocketPort 2 serial driver + + File: rp2.fw +@@ -3632,56 +1902,6 @@ License: Redistributable. See LICENCE.moxa for details + + -------------------------------------------------------------------------- + +-Driver: cw1200 - ST-E CW1100/CW1200 WLAN driver +- +-File: wsm_22.bin +-Version: WSM395 +-Licence: Redistributable. See LICENCE.cw1200 for details. +- +-File: sdd_sagrad_1091_1098.bin +- +-License: +- Copyright (c) 2011-2013 Sagrad, Inc. +- +- This SDD ("Static Dynamic Data") file is licensed strictly for use with +- the Sagrad WiFi modules (such as the SG901-1091/1098) that utilize the +- cw1200 driver. There is no warranty expressed or implied about its +- fitness for any purpose. +- +- Permission is hereby granted for the distribution of this SDD file as +- part of Linux or other Open Source operating system kernel in text or +- binary form as required. +- +- (Please note that the actual device firmware is separately licensed) +- +--------------------------------------------------------------------------- +- +-Driver: BFA/BNA - QLogic BR-series Adapter FC/FCOE drivers +- +-File: cbfw-3.2.5.1.bin +-File: ctfw-3.2.5.1.bin +-File: ct2fw-3.2.5.1.bin +- +-Licence: +- +-This file contains firmware data derived from proprietary unpublished +-source code. +-Copyright (c) 2013-2014 Brocade Communications Systems, Inc. +-Copyright (c) 2014-2015 QLogic Corporation. +- +-Permission is hereby granted for the distribution of this firmware data +-in hexadecimal or equivalent format, provided this copyright notice is +-accompanying it. +- +-QLogic grants permission to use and redistribute these firmware files +-for use with QLogic BR-series devices, but not as a part of the Linux +-kernel or in any other form which would require these files themselves +-to be covered by the terms of the GNU General Public License. +-These firmware files are distributed in the hope that they will be +-useful, but WITHOUT ANY WARRANTY; without even the implied warranty +-of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. +- +--------------------------------------------------------------------------- + Driver: qat - Intel(R) QAT crypto accelerator + + File: qat_895xcc.bin +@@ -3698,36 +1918,6 @@ Licence: Redistributable. See LICENCE.qat_firmware for details + + -------------------------------------------------------------------------- + +-Driver: rsi -- Redpine Signals Inc 91x driver +- +-File: rsi_91x.fw +- +-File: rsi/rs9113_wlan_qspi.rps +-Version: 1.6.1 +- +-File: rsi/rs9113_wlan_bt_dual_mode.rps +-Version: 1.6.1 +- +-File: rsi/rs9113_ap_bt_dual_mode.rps +-Version: 1.6.1 +- +-File: rsi/rs9116_wlan.rps +-Version: 1.0.5b +- +-File: rsi/rs9116_wlan_bt_classic.rps +-Version: 1.0.5b +- +-Licence: +- * Firmware is: +- * Derived from proprietary unpublished source code, +- * Copyright (C) 2019 Redpine Signals Inc. +- * +- * Permission is hereby granted for the distribution of this firmware +- * as part of Linux or other Open Source operating system kernel +- * provided this copyright notice is accompanying it. +- +--------------------------------------------------------------------------- +- + Driver: xhci-rcar -- Renesas R-Car Gen2/3 USB 3.0 host controller driver + + File: r8a779x_usb3_v1.dlmem +@@ -3770,86 +1960,6 @@ Licence: GPLv2 or later. See GPL-2 and GPL-3 for details. + + -------------------------------------------------------------------------- + +-Driver: btqca - Qualcomm Atheros Bluetooth support for QCA61x4 chips +- +-File: qca/nvm_usb_00000201.bin +-File: qca/nvm_usb_00000200.bin +-File: qca/nvm_usb_00000300.bin +-File: qca/nvm_usb_00000302.bin +-File: qca/nvm_00130300.bin +-File: qca/nvm_00130302.bin +-File: qca/nvm_00230302.bin +-File: qca/rampatch_usb_00000200.bin +-File: qca/rampatch_usb_00000201.bin +-File: qca/rampatch_usb_00000300.bin +-File: qca/rampatch_usb_00000302.bin +-File: qca/rampatch_00130300.bin +-File: qca/rampatch_00130302.bin +-File: qca/rampatch_00230302.bin +-File: qca/nvm_00440302.bin +-File: qca/rampatch_00440302.bin +-File: qca/nvm_00440302_eu.bin +-File: qca/nvm_00440302_i2s_eu.bin +-File: qca/nvm_usb_00000302_eu.bin +-File: qca/htbtfw20.tlv +-File: qca/htnv20.bin +-File: qca/rampatch_usb_00130200.bin +-File: qca/nvm_usb_00130200.bin +-File: qca/nvm_usb_00130200_0104.bin +-File: qca/nvm_usb_00130200_0105.bin +-File: qca/nvm_usb_00130200_0106.bin +-File: qca/nvm_usb_00130200_0107.bin +-File: qca/nvm_usb_00130200_0109.bin +-File: qca/nvm_usb_00130200_0110.bin +-File: qca/rampatch_usb_00130201.bin +-File: qca/nvm_usb_00130201.bin +-File: qca/nvm_usb_00130201_010a.bin +-File: qca/nvm_usb_00130201_010b.bin +-File: qca/nvm_usb_00130201_0303.bin +-File: qca/nvm_usb_00130201_gf.bin +-File: qca/nvm_usb_00130201_gf_010a.bin +-File: qca/nvm_usb_00130201_gf_010b.bin +-File: qca/nvm_usb_00130201_gf_0303.bin +-File: qca/rampatch_usb_00190200.bin +-File: qca/nvm_usb_00190200.bin +- +-Licence: Redistributable. See LICENSE.QualcommAtheros_ath10k and qca/NOTICE.txt for details +- +--------------------------------------------------------------------------- +- +-Driver: qca - Qualcomm Atheros Bluetooth support for WCN399x chips +- +-File: qca/crbtfw21.tlv +-File: qca/crnv21.bin +-File: qca/crbtfw32.tlv +-File: qca/crnv32.bin +-File: qca/crnv32u.bin +- +-Driver: qca - Qualcomm Atheros Bluetooth support for WCN6750 chips +- +-File: qca/msbtfw11.mbn +-File: qca/msbtfw11.tlv +-File: qca/msnv11.bin +-File: qca/msnv11.b0a +-File: qca/msnv11.b09 +- +-Licence: Redistributable. See LICENSE.QualcommAtheros_ath10k and qca/NOTICE.txt for details +- +-Driver: qca - Qualcomm Atheros Bluetooth support for QCA2066 chips +- +-File: qca/hpbtfw21.tlv +-File: qca/hpnv21.bin +-File: qca/hpnv21g.bin +-File: qca/hpnv21.301 +-File: qca/hpnv21.302 +-File: qca/hpnv21g.301 +-File: qca/hpnv21g.302 +- +- +-Licence: Redistributable. See LICENSE.QualcommAtheros_ath10k and qca/NOTICE.txt for details +- +--------------------------------------------------------------------------- +- + Driver: liquidio -- Cavium LiquidIO driver + + File: liquidio/lio_23xx_nic.bin +@@ -4663,19 +2773,6 @@ Licence: Redistributable. See LICENCE.nvidia for details + + -------------------------------------------------------------------------- + +-Driver: wilc1000 - Atmel 802.11n WLAN driver for WILC1000 +- +-File: atmel/wilc1000_fw.bin +-File: atmel/wilc1000_ap_fw.bin +-File: atmel/wilc1000_p2p_fw.bin +-File: atmel/wilc1000_wifi_firmware.bin +-File: atmel/wilc1000_wifi_firmware-1.bin +-Version: 16.0 +- +-License: Redistributable. See LICENSE.atmel for details +- +--------------------------------------------------------------------------- +- + Driver: hfi1 - Intel OPA Gen 1 adapter + + File: hfi1_dc8051.fw +@@ -4699,18 +2796,6 @@ Licence: Redistributable. See LICENCE.ti-keystone for details. + + -------------------------------------------------------------------------- + +-Driver: mwlwifi - Marvell mac80211 driver for 80211ac cards. +- +-File: mwlwifi/88W8864.bin +-Version: 7.2.8.6 +- +-File: mwlwifi/88W8897.bin +-Version: 8.2.0.10 +- +-Licence: Redistributable. See LICENCE.Marvell for details. +- +--------------------------------------------------------------------------- +- + Driver: mtk_scp - MediaTek SCP System Control Processing Driver + + File: mediatek/mt8183/scp.img +@@ -4726,195 +2811,6 @@ Licence: Redistributable. See LICENCE.mediatek for details. + + -------------------------------------------------------------------------- + +-Driver: btmtk - MediaTek Bluetooth Driver +- +-File: mediatek/mt7622pr2h.bin +-Version: 20180621204904 +-File: mediatek/mt7668pr2h.bin +-Version: 20180517181834 +-# Note: explicitly commented out, since it's duplicated further down +-# File: mediatek/mt7663pr2h.bin +-# Version: 7663e2ccn04-2006030247 +- +-Licence: Redistributable. See LICENCE.mediatek for details. +- +--------------------------------------------------------------------------- +- +-Driver: mt76x0 - MediaTek MT76x0 Wireless MACs +- +-File: mediatek/mt7610u.bin +-File: mediatek/mt7610e.bin +-Version: 2.6 +-File: mediatek/mt7650e.bin +-Version: 1.0.07-b370 +- +-Licence: Redistributable. See LICENCE.mediatek for details. +- +---------------------------------------------------------------------------- +- +-Driver: mt76x2e - MediaTek MT76x2 Wireless MACs +- +-File: mediatek/mt7662.bin +-Version: 1.9 +-Link: mt7662.bin -> mediatek/mt7662.bin +- +-File: mediatek/mt7662_rom_patch.bin +-Version: 0.0.2_P69 +-Link: mt7662_rom_patch.bin -> mediatek/mt7662_rom_patch.bin +- +-Licence: Redistributable. See LICENCE.ralink_a_mediatek_company_firmware for details +- +---------------------------------------------------------------------------- +- +-Driver: mt76x2u - MediaTek MT76x2u Wireless MACs +- +-File: mediatek/mt7662u.bin +-Version: 1.5 +- +-File: mediatek/mt7662u_rom_patch.bin +-Version: 0.0.2_P48 +- +-Licence: Redistributable. See LICENCE.mediatek for details. +- +--------------------------------------------------------------------------- +- +-Driver: mt7615e - MediaTek MT7615e Wireless MACs +- +-File: mediatek/mt7615_n9.bin +-Version: 20200814 +-File: mediatek/mt7615_cr4.bin +-Version: 20190114 +-File: mediatek/mt7615_rom_patch.bin +-Version: 20190114 +- +-Licence: Redistributable. See LICENCE.mediatek for details. +- +--------------------------------------------------------------------------- +- +-Driver: mt7622 - MediaTek MT7622 Wireless MACs +- +-File: mediatek/mt7622_n9.bin +-Version: 20200630 +-File: mediatek/mt7622_rom_patch.bin +-Version: 20190114 +- +-Licence: Redistributable. See LICENCE.mediatek for details. +- +--------------------------------------------------------------------------- +- +-Driver: mt7663 - MediaTek MT7663 Wireless MACs +- +-File: mediatek/mt7663pr2h.bin +-Version: 7663e2ccn04-2006030247 +-File: mediatek/mt7663_n9_v3.bin +-Version: v3.1.1 +- +-File: mediatek/mt7663pr2h_rebb.bin +-Version: 7663e2-1802-19091404338b809 +-File: mediatek/mt7663_n9_rebb.bin +-Version: 7663mp1827-20190914043434 +- +-Licence: Redistributable. See LICENCE.mediatek for details. +- +--------------------------------------------------------------------------- +- +-Driver: mt7915e - MediaTek Wireless MACs for MT7915/MT7916/MT7986/MT7981 +- +-File: mediatek/mt7915_wm.bin +-Version: 20220929104145 +-File: mediatek/mt7915_wa.bin +-Version: 20220929104205 +-File: mediatek/mt7915_rom_patch.bin +-Version: 20220929104113a +-File: mediatek/mt7915_eeprom.bin +-Version: 20200821 +-File: mediatek/mt7915_eeprom_dbdc.bin +-Version: 20200821 +- +-File: mediatek/mt7916_wm.bin +-Version: 20230202145005 +-File: mediatek/mt7916_wa.bin +-Version: 20230202143332 +-File: mediatek/mt7916_rom_patch.bin +-Version: 20230202144915a +-File: mediatek/mt7916_eeprom.bin +-Version: 20211130 +- +-File: mediatek/mt7986_wm.bin +-Version: 20221012174725 +-File: mediatek/mt7986_wm_mt7975.bin +-Version: 20221012174805 +-File: mediatek/mt7986_wa.bin +-Version: 20221012174937 +-File: mediatek/mt7986_rom_patch.bin +-Version: 20221012174648a +-File: mediatek/mt7986_rom_patch_mt7975.bin +-Version: 20221012174743a +-File: mediatek/mt7986_wo_0.bin +-Version: 20221012175005 +-File: mediatek/mt7986_wo_1.bin +-Version: 20221012175032 +-File: mediatek/mt7986_eeprom_mt7976.bin +-Version: 20211105 +-File: mediatek/mt7986_eeprom_mt7976_dbdc.bin +-Version: 20220223 +-File: mediatek/mt7986_eeprom_mt7976_dual.bin +-Version: 20211115 +-File: mediatek/mt7986_eeprom_mt7975_dual.bin +-Version: 20220208 +- +-File: mediatek/mt7981_wm.bin +-Version: 20221208201806 +-File: mediatek/mt7981_wa.bin +-Version: 20221208202048 +-File: mediatek/mt7981_rom_patch.bin +-Version: 20221208201745a +-File: mediatek/mt7981_wo.bin +-Version: 20221208202138 +- +-Licence: Redistributable. See LICENCE.mediatek for details. +- +--------------------------------------------------------------------------- +- +-Driver: mt7921 - MediaTek MT7921 Wireless MACs +- +-File: mediatek/WIFI_MT7961_patch_mcu_1_2_hdr.bin +-Version: 20230526130917a +-File: mediatek/WIFI_RAM_CODE_MT7961_1.bin +-Version: 20230526130958 +- +-Licence: Redistributable. See LICENCE.mediatek for details. +- +--------------------------------------------------------------------------- +- +-Driver: mt7921 - MediaTek MT7921 bluetooth chipset +- +-File: mediatek/BT_RAM_CODE_MT7961_1_2_hdr.bin +-Version: 20230526131214 +- +-Licence: Redistributable. See LICENCE.mediatek for details. +- +--------------------------------------------------------------------------- +- +-Driver: mt7922 - MediaTek MT7922 Wireless MACs +- +-File: mediatek/WIFI_MT7922_patch_mcu_1_1_hdr.bin +-Version: 20230530123154a +-File: mediatek/WIFI_RAM_CODE_MT7922_1.bin +-Version: 20230530123236 +- +-Licence: Redistributable. See LICENCE.mediatek for details. +- +--------------------------------------------------------------------------- +- +-Driver: mt7922 - MediaTek MT7922 bluetooth chipset +- +-File: mediatek/BT_RAM_CODE_MT7922_1_1_hdr.bin +-Version: 20230530123531 +- +-Licence: Redistributable. See LICENCE.mediatek for details. +- +--------------------------------------------------------------------------- + Driver: nfp - Netronome Flow Processor + + Link: netronome/nic_AMDA0081-0001_1x40.nffw -> nic/nic_AMDA0081-0001_1x40.nffw +@@ -5009,16 +2905,6 @@ Licence: Redistributable. See LICENCE.Netronome for details + + -------------------------------------------------------------------------- + +-Driver: wil6210 - Qualcomm Atheros support for 11ad family of chips +- +-File: wil6210.fw +-File: wil6210.brd +-Version: 5.2.0.18 +- +-Licence: Redistributable. See LICENSE.QualcommAtheros_ath10k for details +- +--------------------------------------------------------------------------- +- + Driver: imx-sdma - support for i.MX SDMA driver + + File: imx/sdma/sdma-imx6q.bin +@@ -5077,69 +2963,6 @@ https://github.com/genesi/linux-legacy/tree/master/drivers/mxc/amd-gpu + + -------------------------------------------------------------------------- + +-Driver: qcom_q6v5_pas - Qualcomm remoteproc firmware +- +-File: qcom/apq8016/mba.mbn +-File: qcom/apq8016/modem.mbn +-File: qcom/apq8016/wcnss.mbn +-File: qcom/apq8016/WCNSS_qcom_wlan_nv_sbc.bin +-File: qcom/apq8096/adsp.mbn +-File: qcom/apq8096/adspr.jsn +-File: qcom/apq8096/adspua.jsn +-File: qcom/apq8096/mba.mbn +-File: qcom/apq8096/modem.mbn +-File: qcom/apq8096/modemr.jsn +-File: qcom/sdm845/adsp.mbn +-File: qcom/sdm845/adspr.jsn +-File: qcom/sdm845/adspua.jsn +-File: qcom/sdm845/cdsp.mbn +-File: qcom/sdm845/cdspr.jsn +-File: qcom/sm8250/adsp.mbn +-File: qcom/sm8250/adspr.jsn +-File: qcom/sm8250/adspua.jsn +-File: qcom/sm8250/cdsp.mbn +-File: qcom/sm8250/cdspr.jsn +-File: qcom/sc8280xp/LENOVO/21BX/adspr.jsn +-File: qcom/sc8280xp/LENOVO/21BX/adspua.jsn +-File: qcom/sc8280xp/LENOVO/21BX/battmgr.jsn +-File: qcom/sc8280xp/LENOVO/21BX/cdspr.jsn +-File: qcom/sc8280xp/LENOVO/21BX/qcadsp8280.mbn +-File: qcom/sc8280xp/LENOVO/21BX/qccdsp8280.mbn +-File: qcom/sc8280xp/LENOVO/21BX/qcslpi8280.mbn +-Link: qcom/LENOVO/21BX -> ../sc8280xp/LENOVO/21BX +- +-Licence: Redistributable. See LICENSE.qcom and qcom/NOTICE.txt for details +- +-Binary files supplied originally from +-http://releases.linaro.org/96boards/dragonboard410c/qualcomm/firmware/linux-board-support-package-r1036.1.zip +-http://releases.linaro.org/96boards/dragonboard845c/qualcomm/firmware/RB3_firmware_20221121000000-v5.zip +-http://releases.linaro.org/96boards/rb5/qualcomm/firmware/RB5_firmware_20210331-v4.zip +- +-adsp.mbn has been converted from 20-adsp_split/firmware/adsp.* using +-https://github.com/andersson/pil-squasher +- +-cdsp.mbn has been converted from 21-cdsp_split/firmware/cdsp.* using +-https://github.com/andersson/pil-squasher +- +--------------------------------------------------------------------------- +- +-Driver: qcom_q6v5_mss - Qualcomm modem subsystem firmware +- +-File: qcom/sdm845/mba.mbn +-File: qcom/sdm845/modem_nm.mbn +-File: qcom/sdm845/modemuw.jsn +-Link: qcom/sdm845/modem.mbn -> modem_nm.mbn +- +-Licence: Redistributable. See LICENSE.qcom and qcom/NOTICE.txt for details +- +-Binary files supplied originally from +-http://releases.linaro.org/96boards/dragonboard845c/qualcomm/firmware/RB3_firmware_20221121000000-v5.zip +- +-modem.mbn has been converted from 28-modem/modem.* using +-https://github.com/andersson/pil-squasher +- +--------------------------------------------------------------------------- +- + Driver: mlxsw_spectrum - Mellanox Spectrum switch + + File: mellanox/mlxsw_spectrum-13.1420.122.mfa2 +@@ -5312,26 +3135,6 @@ Licence: Redistributable. See LICENCE.Marvell for details. + + ------------------------------------------------ + +-Driver: wfx - Silicon Labs Wi-Fi Transceiver +- +-File: wfx/wfm_wf200_C0.sec +-Version: 3.14 +- +-File: wfx/brd4001a.pds +-File: wfx/brd8022a.pds +-File: wfx/brd8023a.pds +- +-Licence: Redistributable. See wfx/LICENCE.wf200 for details. +- +-The firmware itself originates from https://github.com/SiliconLabs/wfx-firmware +- +-The *.pds files come from https://github.com/SiliconLabs/wfx-pds +- +-They have been processed with the tool "pds_compress" available on +-https://github.com/SiliconLabs/wfx-linux-tools +- +--------------------------------------------------------------------------- +- + Driver: rvu_cptpf - Marvell CPT driver + + File: mrvl/cpt01/ae.out +@@ -5351,31 +3154,3 @@ Version: v1.21 + Licence: Redistributable. See LICENCE.Marvell for details. + + --------------------------------------------------------------------------- +- +-Driver: nxp-sr1xx - NXP Ultra Wide Band driver +-File: nxp/sr150_fw.bin +-Version: 35.00.03 +- +-Licence: Redistributable. See LICENSE.nxp for details +-Originates from https://github.com/NXP/uwb-NXPUWB-FW.git +--------------------------------------------------------------------------- +- +-Driver: btnxpuart - NXP BT UART driver +- +-File: nxp/uartuart8997_bt_v4.bin +-File: nxp/uartiw416_bt_v0.bin +-File: nxp/helper_uart_3000000.bin +-Version: 16.92.21.p81 +- +-File: nxp/uartuart8987_bt.bin +-Version: 16.92.21.p76.5 +- +-File: nxp/uartuart9098_bt_v1.bin +-Version: 17.92.1.p136.24 +- +-File: nxp/uartspi_n61x_v1.bin.se +-Version: 18.99.1.p154.40 +- +-Licence: Redistributable. See LICENSE.nxp for details +- +--------------------------------------------------------------------------- +-- +2.40.1 + diff --git a/packages/linux-firmware/0004-linux-firmware-scsi-Remove-firmware-for-SCSI-devices.patch b/packages/linux-firmware/0004-linux-firmware-scsi-Remove-firmware-for-SCSI-devices.patch new file mode 100644 index 00000000..17de9c06 --- /dev/null +++ b/packages/linux-firmware/0004-linux-firmware-scsi-Remove-firmware-for-SCSI-devices.patch @@ -0,0 +1,191 @@ +From 8d9ded48714bc49d16a2250e1b477244c66d16a9 Mon Sep 17 00:00:00 2001 +From: Leonard Foerster +Date: Tue, 25 Jul 2023 12:12:03 +0000 +Subject: [PATCH] linux-firmware: scsi: Remove firmware for SCSI devices + +Bottlerocket does not configure drivers for most SCSI devices for any of +its kernels. Without the driver support, there is no point in providing +firmware for these devices. The list below maps driver names as +specified in WHENCE and maps them to kernel config options to enable us +to easily add firmware when necessitated by driver addition. + +* advansys - CONFIG_SCSI_ADVANSYS +* qla1280 - CONFIG_SCSI_QLOGIC_1280 +* qlogicpti - CONFIG_SCSI_QLOGICPTI +* isci - CONFIG_SCSI_ISCI +* BFA/BNA - CONFIG_BNA && CONFIG_SCSI_BFA +* qla2xxx - CONFIG_TCM_QLA2XXX + +Signed-off-by: Leonard Foerster +--- + LICENCE.qla1280 | 23 ------------------ + LICENCE.qla2xxx | 31 ------------------------ + WHENCE | 63 ------------------------------------------------- + 3 files changed, 117 deletions(-) + delete mode 100644 LICENCE.qla1280 + delete mode 100644 LICENCE.qla2xxx + +diff --git a/LICENCE.qla1280 b/LICENCE.qla1280 +deleted file mode 100644 +index 00cd353..0000000 +--- a/LICENCE.qla1280 ++++ /dev/null +@@ -1,23 +0,0 @@ +-Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000 QLogic, Inc. +-All rights reserved. +- +-Redistribution and use in source and binary forms are permitted provided +-that the following conditions are met: +-1. Redistribution of source code must retain the above copyright +- notice, this list of conditions and the following disclaimer. +-2. Redistribution in binary form must reproduce the above copyright +- notice, this list of conditions and the following disclaimer in the +- documentation and/or other materials provided with the distribution. +-3. The name of the author may not be used to endorse or promote products +- derived from this software without specific prior written permission +- +-THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR +-IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES +-OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. +-IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, +-INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT +-NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +-DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY +-THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +-(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF +-THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +diff --git a/LICENCE.qla2xxx b/LICENCE.qla2xxx +deleted file mode 100644 +index 6b3d8ff..0000000 +--- a/LICENCE.qla2xxx ++++ /dev/null +@@ -1,31 +0,0 @@ +-Copyright (c) 2003-2017 QLogic Corporation +-QLogic Linux Fibre Channel Adapter Firmware +- +-Redistribution and use in binary form, without modification, for use in conjunction +-with QLogic authorized products is permitted provided that the following conditions +-are met: +- +-1. Redistribution in binary form must reproduce the above copyright notice, this +- list of conditions and the following disclaimer in the documentation and/or +- other materials provided with the distribution. +-2. The name of QLogic Corporation may not be used to endorse or promote products +- derived from this software without specific prior written permission. +-3. Reverse engineering, decompilation, or disassembly of this firmware is not +- permitted. +- +-REGARDLESS OF WHAT LICENSING MECHANISM IS USED OR APPLICABLE,THIS PROGRAM IS +-PROVIDED BY QLOGIC CORPORATION "AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, +-INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND +-FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR +-BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR +-CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE +-GOODS OR SERVICES; LOSS OF USE,DATA, OR PROFITS; OR BUSINESS INTERRUPTION) +-HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +-LIABILITY,OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +-OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +- +-USER ACKNOWLEDGES AND AGREES THAT USE OF THIS PROGRAM WILL NOT CREATE OR GIVE +-GROUNDS FOR A LICENSE BY IMPLICATION, ESTOPPEL, OR OTHERWISE IN ANY INTELLECTUAL +-PROPERTY RIGHTS (PATENT, COPYRIGHT, TRADE SECRET, MASK WORK, OR OTHER PROPRIETARY +-RIGHT) EMBODIED IN ANY OTHER QLOGIC HARDWARE OR SOFTWARE EITHER SOLELY OR IN +-COMBINATION WITH THIS PROGRAM. +diff --git a/WHENCE b/WHENCE +index edf6f75..bf5204f 100644 +--- a/WHENCE ++++ b/WHENCE +@@ -8,29 +8,6 @@ kernel. + + -------------------------------------------------------------------------- + +-Driver: advansys - AdvanSys SCSI +- +-File: advansys/mcode.bin +-File: advansys/3550.bin +-File: advansys/38C0800.bin +-File: advansys/38C1600.bin +- +-Licence: BSD, no source available. +- +-Found in hex form in kernel source. +- +--------------------------------------------------------------------------- +- +-Driver: qla1280 - Qlogic QLA 1240/1x80/1x160 SCSI support +- +-File: qlogic/1040.bin +-File: qlogic/1280.bin +-File: qlogic/12160.bin +- +-Licence: Redistributable. See LICENCE.qla1280 for details +- +--------------------------------------------------------------------------- +- + Driver: kaweth -- USB KLSI KL5USB101-based Ethernet device + + File: kaweth/new_code.bin +@@ -265,27 +242,6 @@ http://www.zdomain.com/a56.html + + -------------------------------------------------------------------------- + +-Driver: qla2xxx - QLogic QLA2XXX Fibre Channel +- +-File: ql2100_fw.bin +-Version: 1.19.38 TP +-File: ql2200_fw.bin +-Version: 2.02.08 TP +-File: ql2300_fw.bin +-Version: 3.03.28 IPX +-File: ql2322_fw.bin +-Version: 3.03.28 IPX +-File: ql2400_fw.bin +-Version: 8.07.00 MID +-File: ql2500_fw.bin +-Version: 8.07.00 MIDQ +- +-Licence: Redistributable. See LICENCE.qla2xxx for details +- +-Available from http://ldriver.qlogic.com/firmware/ +- +--------------------------------------------------------------------------- +- + Driver: orinoco - Agere/Prism/Symbol Orinoco support + + File: agere_sta_fw.bin +@@ -631,16 +587,6 @@ Found in hex form in kernel source. + + -------------------------------------------------------------------------- + +-Driver: qlogicpti - PTI Qlogic, ISP Driver +- +-File: qlogic/isp1000.bin +- +-Licence: Unknown +- +-Found in hex form in kernel source. +- +--------------------------------------------------------------------------- +- + Driver: myri_sbus - MyriCOM Gigabit Ethernet + + File: myricom/lanai.bin +@@ -1810,15 +1756,6 @@ Licence: Redistributable. See LICENCE.ene_firmware for details. + + -------------------------------------------------------------------------- + +-Driver: isci -- Intel C600 SAS controller driver +- +-File: isci/isci_firmware.bin +-Source: isci/ +- +-Licence: GPLv2. See GPL-2 for details. +- +--------------------------------------------------------------------------- +- + Driver: rp2 -- Comtrol RocketPort 2 serial driver + + File: rp2.fw +-- +2.40.1 + diff --git a/packages/linux-firmware/0005-linux-firmware-usb-remove-firmware-for-USB-Serial-PC.patch b/packages/linux-firmware/0005-linux-firmware-usb-remove-firmware-for-USB-Serial-PC.patch new file mode 100644 index 00000000..c4cf7552 --- /dev/null +++ b/packages/linux-firmware/0005-linux-firmware-usb-remove-firmware-for-USB-Serial-PC.patch @@ -0,0 +1,901 @@ +From abd8555549e48367b9edb9baaa61b40afcfd6231 Mon Sep 17 00:00:00 2001 +From: Leonard Foerster +Date: Tue, 25 Jul 2023 14:27:14 +0000 +Subject: [PATCH] linux-firmware: usb: remove firmware for USB/Serial/PCMCIA + devices + +Bottlerocket does not configure most drivers for USB,PCMCIA, and serial devices +for any of its kernels. Without those drivers, the firmware for these +devices is not of use and does not need to be shipped by us. + +The following list maps the driver names as specified in WHENCE to +kernel config options enabling drivers. That way we are able to find the +firmware for any driver we may be enabling in the future. + +* kaweth - CONFIG_USB_KAWETH +* keyspan - CONFIG_SERIAL_KEYSPAN +* keyspan_pda - CONFIG_SERIAL_KEYSPAN_PDA +* emi26 - CONFIG_USB_EMI26 +* emi62 - CONFIG_USB_EMI62 +* ti_usb_3410_5052 - CONFIG_USB_SERIAL_TI +* whiteheat - CONFIG_USB_SERIAL_WHITEHEAT +* io_edgeport - CONFIG_USB_SERIAL_EDGEPORT +* io_ti - CONFIG_USB_SERIAL_EDGEPORT_TI +* orinoco - CONFIG_ORINOCO_USB +* usbdux - CONFIG_COMEDI_USBDUX +* usbduxfast - CONFIG_COMEDI_USBDUXFAST +* usbduxsigma - CONFIG_COMEDI_USBDUXSIGMA +* s2255drv - CONFIG_USB_S2255 +* ueagle-atm - CONFIG_USB_EAGLEATM +* vt6656 - CONFIG_VT6656 +* ene-ub6250 - CONFIG_USB_STORAGE_ENE_UB6250 +* mxu11x0 - CONFIG_USB_SERIAL_MXUPORT11 +* mxuport - CONFIG_USB_SERIAL_MXUPORT +* xhci-rcar - CONFIG_USB_XHCI_RCAR +* xhci-tegra - CONFIG_USB_XHCI_TEGRA +* atusb - CONFIG_IEEE802154_ATUSB +* pcnet_cs - CONFIG_PCMCIA_PCNET +* 3c589_cs - CONFIG_PCMCIA_3C589 +* 3c574_cs - CONFIG_PCMCIA_3C574 +* serial_cs - CONFIG_SERIAL_8250_CS +* smc91c92_cs - CONFIG_PCMCIA_SMC91C92 +* rp2 - CONFIG_SERIAL_RP2 + +Signed-off-by: Leonard Foerster +--- + LICENCE.agere | 77 ------ + LICENCE.ene_firmware | 14 - + LICENCE.kaweth | 28 -- + LICENCE.moxa | 16 -- + LICENCE.r8a779x_usb3 | 26 -- + LICENCE.ueagle-atm4-firmware | 39 --- + LICENCE.via_vt6656 | 25 -- + WHENCE | 495 ----------------------------------- + 8 files changed, 720 deletions(-) + delete mode 100644 LICENCE.agere + delete mode 100644 LICENCE.ene_firmware + delete mode 100644 LICENCE.kaweth + delete mode 100644 LICENCE.moxa + delete mode 100644 LICENCE.r8a779x_usb3 + delete mode 100644 LICENCE.ueagle-atm4-firmware + delete mode 100644 LICENCE.via_vt6656 + +diff --git a/LICENCE.agere b/LICENCE.agere +deleted file mode 100644 +index c11466c..0000000 +--- a/LICENCE.agere ++++ /dev/null +@@ -1,77 +0,0 @@ +-agere_sta_fw.bin -- 9.48 Hermes I +-agere_ap_fw.bin -- 9.48 Hermes I +- +-The above firmware images were compiled from the Agere linux driver +-wl_lkm_718_release.tar.gz, and dumped. The driver is coverred by the +-following copyright and software license. +- +- * SOFTWARE LICENSE +- * +- * This software is provided subject to the following terms and conditions, +- * which you should read carefully before using the software. Using this +- * software indicates your acceptance of these terms and conditions. If you do +- * not agree with these terms and conditions, do not use the software. +- * +- * COPYRIGHT © 1994 - 1995 by AT&T. All Rights Reserved +- * COPYRIGHT © 1996 - 2000 by Lucent Technologies. All Rights Reserved +- * COPYRIGHT © 2001 - 2004 by Agere Systems Inc. All Rights Reserved +- * All rights reserved. +- * +- * Redistribution and use in source or binary forms, with or without +- * modifications, are permitted provided that the following conditions are met: +- * +- * . Redistributions of source code must retain the above copyright notice, this +- * list of conditions and the following Disclaimer as comments in the code as +- * well as in the documentation and/or other materials provided with the +- * distribution. +- * +- * . Redistributions in binary form must reproduce the above copyright notice, +- * this list of conditions and the following Disclaimer in the documentation +- * and/or other materials provided with the distribution. +- * +- * . Neither the name of Agere Systems Inc. nor the names of the contributors +- * may be used to endorse or promote products derived from this software +- * without specific prior written permission. +- * +- * Disclaimer +- * +- * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, +- * INCLUDING, BUT NOT LIMITED TO, INFRINGEMENT AND THE IMPLIED WARRANTIES OF +- * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. ANY +- * USE, MODIFICATION OR DISTRIBUTION OF THIS SOFTWARE IS SOLELY AT THE USERS OWN +- * RISK. IN NO EVENT SHALL AGERE SYSTEMS INC. OR CONTRIBUTORS BE LIABLE FOR ANY +- * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES +- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; +- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +- * ON ANY THEORY OF LIABILITY, INCLUDING, BUT NOT LIMITED TO, CONTRACT, STRICT +- * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT +- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH +- * DAMAGE. +- +-The following statement from Agere clarifies the status of the firmware +- +---- +-I would like to confirm that the two drivers; Linux LKM Wireless Driver +-Source Code, Version 7.18 and Linux LKM Wireless Driver Source Code, +-Version 7.22 comply with Open Source BSD License. Therefore the source +-code can be distributed in unmodified or modified form consistent with +-the terms of the license. +- +-The Linux driver architecture was based on two modules, the MSF (Module +-specific functions) and the HCF (Hardware Control Functions). Included +-in the HCF is run-time firmware (binary format) which is downloaded into +-the RAM of the Hermes 1/2/2.5 WMAC. +- +-This hex coded firmware is not based on any open source software and +-hence it is not subject to any Open Source License. The firmware was +-developed by Agere and runs on the DISC processor embedded within the +-Hermes 1/2/2.5 Wireless MAC devices. +- +-Hope this helps. +- +-Sincerely, +- +-Viren Pathare +-Intellectual Property Licensing Manager +-Agere +---- +diff --git a/LICENCE.ene_firmware b/LICENCE.ene_firmware +deleted file mode 100644 +index 08f2b01..0000000 +--- a/LICENCE.ene_firmware ++++ /dev/null +@@ -1,14 +0,0 @@ +-copyright (c) 2011, ENE TECHNOLOGY INC. +- +-Permission to use, copy, modify, and/or distribute this software for any purpose +-with or without fee is hereby granted, provided that the above copyright notice +-and this permission notice appear in all copies. +- +-THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL +-WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL +-IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT +-SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR +-CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM +-LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, +-NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION +-WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +diff --git a/LICENCE.kaweth b/LICENCE.kaweth +deleted file mode 100644 +index 75a59c0..0000000 +--- a/LICENCE.kaweth ++++ /dev/null +@@ -1,28 +0,0 @@ +-Copyright 1999 Kawasaki LSI. +- +-Redistribution and use in source and binary forms, with or without +-modification, are permitted provided that the following conditions +-are met: +-1. Redistributions of source code must retain the above copyright +- notice, this list of conditions and the following disclaimer. +-2. Redistributions in binary form must reproduce the above copyright +- notice, this list of conditions and the following disclaimer in the +- documentation and/or other materials provided with the distribution. +-3. All advertising materials mentioning features or use of this software +- must display the following acknowledgement: +- This product includes software developed by Kawasaki LSI. +-4. Neither the name of the company nor the names of its contributors +- may be used to endorse or promote products derived from this software +- without specific prior written permission. +- +-THIS SOFTWARE IS PROVIDED BY KAWASAKI LSI ``AS IS'' AND ANY EXPRESS OR +-IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED +-WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +-DISCLAIMED. IN NO EVENT SHALL KAWASAKI LSI BE LIABLE FOR ANY DIRECT, +-INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES +-(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +-SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) +-HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, +-STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING +-IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE +-POSSIBILITY OF SUCH DAMAGE. +diff --git a/LICENCE.moxa b/LICENCE.moxa +deleted file mode 100644 +index 120017b..0000000 +--- a/LICENCE.moxa ++++ /dev/null +@@ -1,16 +0,0 @@ +-The software accompanying this license statement (the “Software”) +-is the property of Moxa Inc. (the “Moxa”), and is protected by +-United States and International Copyright Laws and International +-treaty provisions. No ownership rights are granted by this +-Agreement or possession of the Software. Therefore, you must treat +-the Licensed Software like any other copyrighted material. Your +-rights and obligations in its use are described as follows: +- +-1. You may freely redistribute this software under this license. +-2. You may freely download and use this software on Moxa's device. +-3. You may not modify or attempt to reverse engineer the software, or +- make any attempt to change or even examine the source code of the +- software. +-4. You may not re-license or sub-license the software to any person or +- business, using any other license. +-5. Moxa(r) is worldwide registered trademark. +diff --git a/LICENCE.r8a779x_usb3 b/LICENCE.r8a779x_usb3 +deleted file mode 100644 +index e2afcc9..0000000 +--- a/LICENCE.r8a779x_usb3 ++++ /dev/null +@@ -1,26 +0,0 @@ +-Copyright (c) 2014, Renesas Electronics Corporation +-All rights reserved. +- +-Redistribution and use in binary form, without modification, are permitted +-provided that the following conditions are met: +- +-1. Redistribution in binary form must reproduce the above copyright notice, +- this list of conditions and the following disclaimer in the documentation +- and/or other materials provided with the distribution. +-2. The name of Renesas Electronics Corporation may not be used to endorse or +- promote products derived from this software without specific prior written +- permission. +-3. Reverse engineering, decompilation, or disassembly of this software is +- not permitted. +- +-THIS SOFTWARE IS PROVIDED "AS IS" AND RENESAS ELECTRONICS CORPORATION DISCLAIMS +-ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED +-WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE, AND +-NONINFRINGEMENT OF THIRD PARTY RIGHTS. IN NO EVENT SHALL RENESAS ELECTRONICS +-CORPORATION BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, +-OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF +-SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +-INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN +-CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) +-ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE +-POSSIBILITY OF SUCH DAMAGE. +diff --git a/LICENCE.ueagle-atm4-firmware b/LICENCE.ueagle-atm4-firmware +deleted file mode 100644 +index 333675d..0000000 +--- a/LICENCE.ueagle-atm4-firmware ++++ /dev/null +@@ -1,39 +0,0 @@ +-This license applies to eagle4 firmware & DSPcode +-namely, the files eagleIV.fw DSP4p.bin* +- +-| Copyright (2006) Ikanos Communications, Inc. +-| +-| Redistribution and use in source and binary forms, with or without +-| modification, are permitted provided that the following +-| conditions are met: +-| +-| * Redistribution of source code must retain the above copyright +-| notice, this list of conditions and the following disclaimer. +-| +-| * Redistribution in binary form must reproduce the above +-| copyright notice, this list of conditions and the following +-| disclaimer in the documentation and/or other materials provided +-| with the distribution. +-| +-| * The name of Ikanos Corporation may not be used to endorse +-| or promote products derived from this source code without specific +-| prior written consent of Ikanos Corporation. +-| +-| THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +-| "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +-| LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR +-| A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT +-| OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +-| SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +-| LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +-| DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY +-| THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +-| (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +-| OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +-| USER ACKNOWLEDGES AND AGREES THAT THE PURCHASE OR USE OF THIS SOFTWARE WILL +-| NOT CREATE OR GIVE GROUNDS FOR A +-| LICENSE BY IMPLICATION, ESTOPPEL, OR OTHERWISE IN ANY INTELLECTUAL +-| PROPERTY RIGHTS (PATENT, COPYRIGHT, TRADE SECRET, MASK WORK, OR OTHER +-| PROPRIETARY RIGHT) EMBODIED IN ANY OTHER IKANOS HARDWARE OR SOFTWARE +-| EITHER SOLELY OR IN COMBINATION WITH THIS SOFTWARE. +- +diff --git a/LICENCE.via_vt6656 b/LICENCE.via_vt6656 +deleted file mode 100644 +index f231f98..0000000 +--- a/LICENCE.via_vt6656 ++++ /dev/null +@@ -1,25 +0,0 @@ +-The following license applies to the binary-only VT6656 firmware +-as contained in the file "vntwusb.fw" +-================================================================ +-Copyright 1998-2010 VIA Technologies, Inc. All Rights Reserved. +- +-Permission is hereby granted, free of charge, to any person +-obtaining a copy of this software and associated documentation +-files (the "Software"), to deal in the Software without +-restriction, including without limitation the rights to use, +-copy, modify, merge, publish, distribute, sublicense, and/or sell +-copies of the Software, and to permit persons to whom the +-Software is furnished to do so, subject to the following +-conditions: +- +-The above copyright notice and this permission notice shall be +-included in all copies or substantial portions of the Software. +- +-THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +-EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES +-OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND +-NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT +-HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, +-WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING +-FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR +-OTHER DEALINGS IN THE SOFTWARE. +diff --git a/WHENCE b/WHENCE +index bf5204f..2ed9e9a 100644 +--- a/WHENCE ++++ b/WHENCE +@@ -8,226 +8,6 @@ kernel. + + -------------------------------------------------------------------------- + +-Driver: kaweth -- USB KLSI KL5USB101-based Ethernet device +- +-File: kaweth/new_code.bin +-File: kaweth/new_code_fix.bin +-File: kaweth/trigger_code.bin +-File: kaweth/trigger_code_fix.bin +- +-Licence: Redistributable. See LICENCE.kaweth for details +- +-Found in hex form in the kernel source. +- +--------------------------------------------------------------------------- +- +-Driver: keyspan -- USB Keyspan USA-xxx serial device +- +-File: keyspan/mpr.fw +-File: keyspan/usa18x.fw +-File: keyspan/usa19.fw +-File: keyspan/usa19qi.fw +-File: keyspan/usa19qw.fw +-File: keyspan/usa19w.fw +-File: keyspan/usa28.fw +-File: keyspan/usa28xa.fw +-File: keyspan/usa28xb.fw +-File: keyspan/usa28x.fw +-File: keyspan/usa49w.fw +-File: keyspan/usa49wlc.fw +- +-Converted from Intel HEX files, used in our binary representation of ihex. +- +-Original licence information: +- +- Copyright (C) 1999-2001 +- Keyspan, A division of InnoSys Incorporated ("Keyspan") +- +- as an unpublished work. This notice does not imply unrestricted or +- public access to the source code from which this firmware image is +- derived. Except as noted below this firmware image may not be +- reproduced, used, sold or transferred to any third party without +- Keyspan's prior written consent. All Rights Reserved. +- +- Permission is hereby granted for the distribution of this firmware +- image as part of a Linux or other Open Source operating system kernel +- in text or binary form as required. +- +- This firmware may not be modified and may only be used with +- Keyspan hardware. Distribution and/or Modification of the +- keyspan.c driver which includes this firmware, in whole or in +- part, requires the inclusion of this statement." +- +--------------------------------------------------------------------------- +- +-Driver: keyspan_pda -- USB Keyspan PDA single-port serial device +- +-File: keyspan_pda/keyspan_pda.fw +-Source: keyspan_pda/keyspan_pda.S +- +-File: keyspan_pda/xircom_pgs.fw +-Source: keyspan_pda/xircom_pgs.S +- +-Source: keyspan_pda/Makefile +- +-Licence: GPLv2 or later. See GPL-2 and GPL-3 for details. +- +-Compiled from original 8051 source into Intel HEX, used in our binary ihex form. +- +--------------------------------------------------------------------------- +- +-Driver: emi26 -- EMI 2|6 USB Audio interface +- +-File: emi26/bitstream.fw +-Version: 1.1.1.131 +-Info: DATE=2001dec06 +- +-File: emi26/firmware.fw +-Version: 1.0.2.916 +-Info: DATE=12.02.2002 +- +-File: emi26/loader.fw +- +-Converted from Intel HEX files, used in our binary representation of ihex. +- +-Original licence information: +-/* +- * This firmware is for the Emagic EMI 2|6 Audio Interface +- * +- * The firmware contained herein is Copyright (c) 1999-2002 Emagic +- * as an unpublished work. This notice does not imply unrestricted +- * or public access to this firmware which is a trade secret of Emagic, +- * and which may not be reproduced, used, sold or transferred to +- * any third party without Emagic's written consent. All Rights Reserved. +- * +- * Permission is hereby granted for the distribution of this firmware +- * image as part of a Linux or other Open Source operating system kernel +- * in text or binary form as required. +- * +- * This firmware may not be modified and may only be used with the +- * Emagic EMI 2|6 Audio Interface. Distribution and/or Modification of +- * any driver which includes this firmware, in whole or in part, +- * requires the inclusion of this statement. +- */ +- +--------------------------------------------------------------------------- +- +-Driver: emi62 -- EMI 6|2m USB Audio interface +- +-File: emi62/bitstream.fw +-Version: 1.0.0.191 +-Info: DATE= 2002oct28 +- +-File: emi62/loader.fw +-Version: 1.0.2.002 +-Info: DATE=10.01.2002 +- +-File: emi62/midi.fw +-Version: 1.04.062 +-Info: DATE=16.10.2002 +- +-File: emi62/spdif.fw +-Version: 1.04.062 +-Info: DATE=16.10.2002 +- +-Converted from Intel HEX files, used in our binary representation of ihex. +- +-Original licence information: None +- +--------------------------------------------------------------------------- +- +-Driver: ti_usb_3410_5052 -- USB TI 3410/5052 serial device +- +-File: ti_3410.fw +-Info: firmware 9/10/04 FW3410_Special_StartWdogOnStartPort +- +-File: ti_5052.fw +-Info: firmware 9/18/04 +- +-Licence: Allegedly GPLv2+, but no source visible. Marked: +- Copyright (C) 2004 Texas Instruments +- +-Found in hex form in kernel source. +- +--------------------------------------------------------------------------- +- +-Driver: ti_usb_3410_5052 -- Multi-Tech USB cell modems +- +-File: mts_cdma.fw +-File: mts_gsm.fw +-File: mts_edge.fw +- +-Licence: "all firmware components are redistributable in binary form" +- per support@multitech.com +- Copyright (C) 2005 Multi-Tech Systems, Inc. +- +-Found in hex form in ftp://ftp.multitech.com/wireless/wireless_linux.zip +- +--------------------------------------------------------------------------- +- +-Driver: ti_usb_3410_5052 -- Multi-Tech USB fax modems +- +-File: mts_mt9234mu.fw +-File: mts_mt9234zba.fw +- +-Licence: Unknown +- +--------------------------------------------------------------------------- +- +-Driver: whiteheat -- USB ConnectTech WhiteHEAT serial device +- +-File: whiteheat.fw +-Version: 4.06 +- +-File: whiteheat_loader.fw +- +-Licence: Allegedly GPLv2, but no source visible. Marked: +- Copyright (C) 2000-2002 ConnectTech Inc +- +-Debug loader claims the following behaviour: +- Port 1 LED flashes when the vend_ax program is running +- Port 2 LED flashes when any SETUP command arrives +- Port 3 LED flashes when any valid VENDOR request occurs +- Port 4 LED flashes when the EXTERNAL RAM DOWNLOAD request occurs +- +-Converted from Intel HEX files, used in our binary representation of ihex. +- +--------------------------------------------------------------------------- +- +-Driver: io_edgeport - USB Inside Out Edgeport Serial Driver +- +-File: edgeport/boot.fw +-File: edgeport/boot2.fw +-File: edgeport/down.fw +-File: edgeport/down2.fw +- +-Licence: Allegedly GPLv2+, but no source visible. Marked: +-//************************************************************** +-//* Edgeport/4 Binary Image +-//* Generated by HEX2C v1.06 +-//* Copyright (C) 1998 Inside Out Networks, All rights reserved. +-//************************************************************** +- +-Found in hex form in kernel source. +- +--------------------------------------------------------------------------- +- +-Driver: io_ti - USB Inside Out Edgeport Serial Driver +-(TI Devices) +- +-File: edgeport/down3.bin +- +-Licence: +-//************************************************************** +-//* Edgeport Binary Image (for TI based products) +-//* Generated by TIBin2C v2.00 (watchport) +-//* Copyright (C) 2001 Inside Out Networks, All rights reserved. +-//************************************************************** +- +-Found in hex form in kernel source. +- +--------------------------------------------------------------------------- +- + Driver: dsp56k - Atari DSP56k support + + File: dsp56k/bootstrap.bin +@@ -242,17 +22,6 @@ http://www.zdomain.com/a56.html + + -------------------------------------------------------------------------- + +-Driver: orinoco - Agere/Prism/Symbol Orinoco support +- +-File: agere_sta_fw.bin +-Version: 9.48 Hermes I +-File: agere_ap_fw.bin +-Version: 9.48 Hermes I +- +-Licence: Redistributable. See LICENCE.agere for details +- +--------------------------------------------------------------------------- +- + Driver: cassini - Sun Cassini + + File: sun/cassini.bin +@@ -503,90 +272,6 @@ Found in hex form in kernel source. + + -------------------------------------------------------------------------- + +-Driver: pcnet_cs - NE2000 compatible PCMCIA adapter +- +-File: cis/LA-PCM.cis +-File: cis/PCMLM28.cis +-File: cis/DP83903.cis +-File: cis/NE2K.cis +-File: cis/tamarack.cis +-File: cis/PE-200.cis +-File: cis/PE520.cis +-Source: cis/ +- +-Licence: Dual GPLv2/MPL +- +-Originally developed by the pcmcia-cs project +-Copyright (C) 1998, 1999, 2000 David A. Hinds +- +--------------------------------------------------------------------------- +- +-Driver: 3c589_cs - 3Com PCMCIA adapter +- +-File: cis/3CXEM556.cis +-Source: cis/src/3CXEM556.cis +- +-Licence: Dual GPLv2/MPL +- +-Originally developed by the pcmcia-cs project +-Copyright (C) 1998, 1999, 2000 David A. Hinds +- +--------------------------------------------------------------------------- +- +-Driver: 3c574_cs - 3Com PCMCIA adapter +- +-File: cis/3CCFEM556.cis +-Source: cis/src/3CCFEM556.cis +- +-Licence: Dual GPLv2/MPL +- +-Originally developed by the pcmcia-cs project +-Copyright (C) 1998, 1999, 2000 David A. Hinds +- +--------------------------------------------------------------------------- +- +-Driver: serial_cs - Serial PCMCIA adapter +- +-File: cis/MT5634ZLX.cis +-File: cis/RS-COM-2P.cis +-File: cis/COMpad2.cis +-File: cis/COMpad4.cis +-Source: cis/src/MT5634ZLX.cis +-Source: cis/src/RS-COM-2P.cis +-Source: cis/src/COMpad2.cis +-Source: cis/src/COMpad4.cis +- +-Licence: Dual GPLv2/MPL +- +-Originally developed by the pcmcia-cs project +-Copyright (C) 1998, 1999, 2000 David A. Hinds +- +--------------------------------------------------------------------------- +- +-Driver: serial_cs - Serial PCMCIA adapter +- +-File: cis/SW_555_SER.cis +-File: cis/SW_7xx_SER.cis +-File: cis/SW_8xx_SER.cis +- +-Licence: GPLv3. See GPL-3 for details. +- +-Copyright Sierra Wireless +- +--------------------------------------------------------------------------- +- +-Driver: smc91c92_cs - SMC 91Cxx PCMCIA +- +-File: ositech/Xilinx7OD.bin +- +-Licence: Allegedly GPL, but no source visible. Marked: +- This file contains the firmware of Seven of Diamonds from OSITECH. +- (Special thanks to Kevin MacPherson of OSITECH) +- +-Found in hex form in kernel source. +- +--------------------------------------------------------------------------- +- + Driver: myri_sbus - MyriCOM Gigabit Ethernet + + File: myricom/lanai.bin +@@ -660,19 +345,6 @@ Available from http://ldriver.qlogic.com/firmware/netxen_nic/new/ + + -------------------------------------------------------------------------- + +-Driver: usbdux/usbduxfast/usbduxsigma - usbdux data acquisition cards +- +-File: usbdux_firmware.bin +-File: usbduxfast_firmware.bin +-File: usbduxsigma_firmware.bin +-Source: usbdux/ +- +-Licence: GPLv2. See GPL-2 for details. +- +-Provided from the author, Bernd Porr +- +--------------------------------------------------------------------------- +- + Driver: mga - Matrox G200/G400/G550 + + File: matrox/g200_warp.fw +@@ -1571,23 +1243,6 @@ Licence: Redistributable. See LICENSE.amdgpu for details. + + -------------------------------------------------------------------------- + +-Driver: s2255drv +- +-File: f2255usb.bin +-Version: 1.2.8 +- +-Licence: Redistributable. +- +- Sensoray grants permission to use and redistribute these firmware +- files for use with Sensoray devices, but not as a part of the Linux +- kernel or in any other form which would require these files themselves +- to be covered by the terms of the GNU General Public License. +- These firmware files are distributed in the hope that they will be +- useful, but WITHOUT ANY WARRANTY; without even the implied warranty +- of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. +- +--------------------------------------------------------------------------- +- + Driver: ib_qib - QLogic Infiniband + + File: qlogic/sd7220.fw +@@ -1662,47 +1317,6 @@ Licence: + + -------------------------------------------------------------------------- + +-Driver: ueagle-atm - Driver for USB ADSL Modems based on Eagle IV Chipset +- +-File: ueagle-atm/CMV4p.bin.v2 +-File: ueagle-atm/DSP4p.bin +-File: ueagle-atm/eagleIV.fw +-Version: 1.0 +- +-Licence: Redistributable. See LICENCE.ueagle-atm4-firmware for details +- +--------------------------------------------------------------------------- +- +-Driver: ueagle-atm - Driver for USB ADSL Modems based on Eagle I,II,III +- +-File: ueagle-atm/930-fpga.bin +-File: ueagle-atm/CMVeiWO.bin +-File: ueagle-atm/CMVepFR10.bin +-File: ueagle-atm/DSP9p.bin +-File: ueagle-atm/eagleIII.fw +-File: ueagle-atm/adi930.fw +-File: ueagle-atm/CMVep.bin +-File: ueagle-atm/CMVepFR.bin +-File: ueagle-atm/DSPei.bin +-File: ueagle-atm/CMV9i.bin +-File: ueagle-atm/CMVepES03.bin +-File: ueagle-atm/CMVepIT.bin +-File: ueagle-atm/DSPep.bin +-File: ueagle-atm/CMV9p.bin +-File: ueagle-atm/CMVepES.bin +-File: ueagle-atm/CMVepWO.bin +-File: ueagle-atm/eagleI.fw +-File: ueagle-atm/CMVei.bin +-File: ueagle-atm/CMVepFR04.bin +-File: ueagle-atm/DSP9i.bin +-File: ueagle-atm/eagleII.fw +-Version: 1.1 +- +-Licence: Redistributable. Based on +- https://mail.gna.org/public/eagleusb-dev/2004-11/msg00172.html +- +--------------------------------------------------------------------------- +- + Driver: vxge - Exar X3100 Series 10GbE PCIe I/O Virtualized Server Adapter + + File: vxge/X3fw.ncf +@@ -1720,14 +1334,6 @@ Licence: + + -------------------------------------------------------------------------- + +-Driver: vt6656 - VIA VT6656 USB wireless driver +- +-File: vntwusb.fw +- +-Licence: Redistributable. See LICENCE.via_vt6656 for details. +- +--------------------------------------------------------------------------- +- + Driver: myri10ge - Myri10GE 10GbE NIC driver + + File: myri10ge_eth_z8e.dat +@@ -1742,37 +1348,6 @@ Version: 1.4.57 + + License: Redistributable. See LICENCE.myri10ge_firmware for details. + +--------------------------------------------------------------------------- +-Driver: ene-ub6250 -- ENE UB6250 SD card reader driver +- +-File: ene-ub6250/sd_init1.bin +-File: ene-ub6250/sd_init2.bin +-File: ene-ub6250/sd_rdwr.bin +-File: ene-ub6250/ms_init.bin +-File: ene-ub6250/msp_rdwr.bin +-File: ene-ub6250/ms_rdwr.bin +- +-Licence: Redistributable. See LICENCE.ene_firmware for details. +- +--------------------------------------------------------------------------- +- +-Driver: rp2 -- Comtrol RocketPort 2 serial driver +- +-File: rp2.fw +- +-Licence: Redistributable. +- +-Copyright (C) 2013 Comtrol Corporation +- +-Comtrol grants permission to use and redistribute these firmware +-files for use with Comtrol devices, but not as part of the Linux +-kernel or in any other form which would require these files themselves +-to be covered by the terms of the GNU General Public License. +- +-These firmware files are distributed in the hope that they will be +-useful, but WITHOUT ANY WARRANTY; without even the implied warranty +-of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. +- + -------------------------------------------------------------------------- + + Driver: ccp - Platform Security Processor (PSP) device +@@ -1811,34 +1386,6 @@ License: Redistributable. See LICENSE.amd-ucode for details + + -------------------------------------------------------------------------- + +-Driver: mxu11x0 - MOXA UPort 11x0 USB Serial hub driver +- +-File: moxa/moxa-1110.fw +-File: moxa/moxa-1130.fw +-File: moxa/moxa-1131.fw +-File: moxa/moxa-1150.fw +-File: moxa/moxa-1151.fw +- +-License: Redistributable. See LICENCE.moxa for details +- +--------------------------------------------------------------------------- +- +-Driver: mxuport - MOXA UPort USB Serial hub driver +- +-File: moxa/moxa-1250.fw +-File: moxa/moxa-1251.fw +-File: moxa/moxa-1410.fw +-File: moxa/moxa-1450.fw +-File: moxa/moxa-1451.fw +-File: moxa/moxa-1613.fw +-File: moxa/moxa-1618.fw +-File: moxa/moxa-1653.fw +-File: moxa/moxa-1658.fw +- +-License: Redistributable. See LICENCE.moxa for details +- +--------------------------------------------------------------------------- +- + Driver: qat - Intel(R) QAT crypto accelerator + + File: qat_895xcc.bin +@@ -1855,48 +1402,6 @@ Licence: Redistributable. See LICENCE.qat_firmware for details + + -------------------------------------------------------------------------- + +-Driver: xhci-rcar -- Renesas R-Car Gen2/3 USB 3.0 host controller driver +- +-File: r8a779x_usb3_v1.dlmem +-File: r8a779x_usb3_v2.dlmem +-File: r8a779x_usb3_v3.dlmem +- +-Licence: Redistributable. See LICENCE.r8a779x_usb3 for details. +- +--------------------------------------------------------------------------- +- +-Driver: xhci-tegra -- NVIDIA Tegra XHCI driver +- +-File: nvidia/tegra124/xusb.bin +-Version: v45.46 +- +-File: nvidia/tegra210/xusb.bin +-Version: v50.24 +- +-File: nvidia/tegra186/xusb.bin +-Version: v55.15 +- +-File: nvidia/tegra194/xusb.bin +-Version: v60.06 +- +-Licence: Redistributable. See LICENCE.nvidia for details +- +--------------------------------------------------------------------------- +- +-Driver: atusb - ATUSB IEEE 802.15.4 transceiver driver +- +-File: atusb/atusb-0.2.dfu +-Version: 0.2 +-File: atusb/atusb-0.3.dfu +-Version: 0.3 +-File: atusb/rzusb-0.3.bin +-Version: 0.3 +-Info: atusb/ChangeLog +- +-Licence: GPLv2 or later. See GPL-2 and GPL-3 for details. +- +--------------------------------------------------------------------------- +- + Driver: liquidio -- Cavium LiquidIO driver + + File: liquidio/lio_23xx_nic.bin +-- +2.40.1 + diff --git a/packages/linux-firmware/0006-linux-firmware-ethernet-Remove-firmware-for-ethernet.patch b/packages/linux-firmware/0006-linux-firmware-ethernet-Remove-firmware-for-ethernet.patch new file mode 100644 index 00000000..d5bdb124 --- /dev/null +++ b/packages/linux-firmware/0006-linux-firmware-ethernet-Remove-firmware-for-ethernet.patch @@ -0,0 +1,539 @@ +From 138cb336108faab12961813bdf7ccc1ae4e1822b Mon Sep 17 00:00:00 2001 +From: Leonard Foerster +Date: Wed, 26 Jul 2023 08:40:14 +0000 +Subject: [PATCH] linux-firmware: ethernet: Remove firmware for ethernet/IB + devices + +Bottlerocket does not ship drivers for older network equipment. Without +the drivers shipping the firmware for thesde devices does not make +sense. Drop the firmware to reduce image size. + +The following list maps driver names as specified in WHENCE to kernel +config options enabling the driver. This way we can easily decide if we +need to add firmware back into the package when we enable new drivers. + +* cassini - CONFIG_CASSINI +* slicoss - CONFIG_SLICOSS +* sxg - CONFIG_SXG +* cxgb3 - CONFIG_CHELSIO_T3 +* e100 - CONFIG_E100 +* acenic - CONFIG_ACENIC +* tehuti - CONFIG_TEHUTI +* bnx2 - CONFIG_BNX2 +* ib_qib - CONFIG_INFINIBAND_QIB +* myri_sbus - CONFIG_MYRI_SBUS (dropped upstream after 3.0) +* hfi1 - CONFIG_INFINIBAND_HFI1 +* starfire - CONFIG_ADAPTEC_STARFIRE +* typhoon - CONFIG_TYPHOON +* vxge - CONFIG_VXGE +* mscc-phy - CONFIG_MICROSEMI_PHY + +Signed-off-by: Leonard Foerster +--- + LICENCE.e100 | 28 ---- + LICENCE.microchip | 40 ------ + LICENSE.hfi1_firmware | 39 ------ + WHENCE | 303 ------------------------------------------ + 4 files changed, 410 deletions(-) + delete mode 100644 LICENCE.e100 + delete mode 100644 LICENCE.microchip + delete mode 100644 LICENSE.hfi1_firmware + +diff --git a/LICENCE.e100 b/LICENCE.e100 +deleted file mode 100644 +index 0553817..0000000 +--- a/LICENCE.e100 ++++ /dev/null +@@ -1,28 +0,0 @@ +-Copyright (c) 1999-2001, Intel Corporation +- +-All rights reserved. +- +-Redistribution and use in source and binary forms, with or without +-modification, are permitted provided that the following conditions are met: +- +- 1. Redistributions of source code must retain the above copyright notice, +- this list of conditions and the following disclaimer. +- +- 2. Redistributions in binary form must reproduce the above copyright notice, +- this list of conditions and the following disclaimer in the documentation +- and/or other materials provided with the distribution. +- +- 3. Neither the name of Intel Corporation nor the names of its contributors +- may be used to endorse or promote products derived from this software +- without specific prior written permission. +- +-THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS ``AS IS'' +-AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +-IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +-DISCLAIMED. IN NO EVENT SHALL CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, +-INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +-LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR +-PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF +-LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING +-NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, +-EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +diff --git a/LICENCE.microchip b/LICENCE.microchip +deleted file mode 100644 +index f270c99..0000000 +--- a/LICENCE.microchip ++++ /dev/null +@@ -1,40 +0,0 @@ +-Copyright (C) 2018 Microchip Technology Incorporated and its subsidiaries. +-All rights reserved. +- +-REDISTRIBUTION: Permission is hereby granted by Microchip Technology +-Incorporated (Microchip), free of any license fees, to any person obtaining a +-copy of this firmware (the "Software"), to install, reproduce, copy and +-distribute copies, in binary form, hexadecimal or equivalent formats only, the +-Software and to permit persons to whom the Software is provided to do the same, +-subject to the following conditions: +- +-* Any redistribution of the Software must reproduce the above copyright notice, +- this license notice, and the following disclaimers and notices in the +- documentation and/or other materials provided with the Software. +- +-* Neither the name of Microchip, its products nor the names of its suppliers +- may be used to endorse or promote products derived from this Software without +- specific prior written permission. +- +-* No reverse engineering, decompilation, or disassembly of this Software is +- permitted. +- +-Limited patent license. Microchip grants a world-wide, royalty-free, +-non-exclusive, revocable license under any patents that it now has or hereafter +-may have, own or control related to the Software to make, have made, use, +-import, offer to sell and sell ("Utilize") this Software, but solely to the +-extent that any such patent is necessary to Utilize the Software in conjunction +-with Microchip processors. The patent license shall not apply to any other +-combinations which include this Software nor to any other Microchip patents or +-patent rights. No hardware per se is licensed hereunder. +- +-DISCLAIMER: THIS SOFTWARE IS PROVIDED BY MICROCHIP "AS IS" AND ANY EXPRESS OR +-IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +-MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE +-DISCLAIMED. IN NO EVENT SHALL ATMEL BE LIABLE FOR ANY DIRECT, INDIRECT, +-INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +-LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR +-PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF +-LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE +-OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF +-ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +diff --git a/LICENSE.hfi1_firmware b/LICENSE.hfi1_firmware +deleted file mode 100644 +index 01f0932..0000000 +--- a/LICENSE.hfi1_firmware ++++ /dev/null +@@ -1,39 +0,0 @@ +-Copyright (c) 2015, Intel Corporation. +-All rights reserved. +- +-Redistribution. +- +-Redistribution and use in binary form, without modification, are permitted +-provided that the following conditions are met: +-* Redistributions must reproduce the above copyright notice and the +- following disclaimer in the documentation and/or other materials provided +- with the distribution. +-* Neither the name of Intel Corporation nor the names of its suppliers may +- be used to endorse or promote products derived from this software without +- specific prior written permission. +-* No reverse engineering, decompilation, or disassembly of this software is +- permitted. +- +-Limited patent license. +- +-Intel Corporation grants a world-wide, royalty-free, non-exclusive license +-under patents it now or hereafter owns or controls to make, have made, use, +-import, offer to sell and sell (“Utilize”) this software, but solely to the +-extent that any such patent is necessary to Utilize the software alone. The +-patent license shall not apply to any combinations which include this software. +-No hardware per se is licensed hereunder. +- +- +-DISCLAIMER. +- +-THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND +-ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED +-WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +-DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR +-ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES +-(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; +-LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON +-ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +-(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS +-SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +- +diff --git a/WHENCE b/WHENCE +index 2ed9e9a..f6b0299 100644 +--- a/WHENCE ++++ b/WHENCE +@@ -22,98 +22,6 @@ http://www.zdomain.com/a56.html + + -------------------------------------------------------------------------- + +-Driver: cassini - Sun Cassini +- +-File: sun/cassini.bin +- +-Licence: Unknown +- +-Found in hex form in kernel source. +- +--------------------------------------------------------------------------- +- +-Driver: slicoss - Alacritech IS-NIC products +- +-File: slicoss/gbdownload.sys +-File: slicoss/gbrcvucode.sys +-File: slicoss/oasisdbgdownload.sys +-File: slicoss/oasisdownload.sys +-File: slicoss/oasisrcvucode.sys +- +-Licence: +- Copyright (C) 1999-2009 Alacritech, Inc. +- +- as an unpublished work. This notice does not imply unrestricted or +- public access to the source code from which this firmware image is +- derived. Except as noted below this firmware image may not be +- reproduced, used, sold or transferred to any third party without +- Alacritech's prior written consent. All Rights Reserved. +- +- Permission is hereby granted for the distribution of this firmware +- image as part of a Linux or other Open Source operating system kernel +- in text or binary form as required. +- +- This firmware may not be modified. +- +-Found in hex form in kernel source. +- +--------------------------------------------------------------------------- +- +-Driver: sxg - Alacritech IS-NIC products +- +-File: sxg/saharadownloadB.sys +-File: sxg/saharadbgdownloadB.sys +- +-Licence: +- Copyright (C) 1999-2009 Alacritech, Inc. +- +- as an unpublished work. This notice does not imply unrestricted or +- public access to the source code from which this firmware image is +- derived. Except as noted below this firmware image may not be +- reproduced, used, sold or transferred to any third party without +- Alacritech's prior written consent. All Rights Reserved. +- +- Permission is hereby granted for the distribution of this firmware +- image as part of a Linux or other Open Source operating system kernel +- in text or binary form as required. +- +- This firmware may not be modified. +- +-Found in hex form in kernel source. +- +--------------------------------------------------------------------------- +- +-Driver: cxgb3 - Chelsio Terminator 3 1G/10G Ethernet adapter +- +-File: cxgb3/t3b_psram-1.1.0.bin +-File: cxgb3/t3c_psram-1.1.0.bin +-File: cxgb3/t3fw-7.0.0.bin +-File: cxgb3/t3fw-7.1.0.bin +-File: cxgb3/t3fw-7.4.0.bin +-File: cxgb3/t3fw-7.10.0.bin +-File: cxgb3/t3fw-7.12.0.bin +- +-Licence: GPLv2 or OpenIB.org BSD license, no source visible +- +--------------------------------------------------------------------------- +- +-Driver: cxgb3 - Chelsio Terminator 3 1G/10G Ethernet adapter +- +-File: cxgb3/ael2005_opt_edc.bin +-File: cxgb3/ael2005_twx_edc.bin +-File: cxgb3/ael2020_twx_edc.bin +- +-Licence: +- * Copyright (c) 2007-2009 NetLogic Microsystems, Inc. +- * +- * Permission is hereby granted for the distribution of this firmware +- * data in hexadecimal or equivalent format, provided this copyright +- * notice is accompanying it. +- +-Found in hex form in kernel source. +- +--------------------------------------------------------------------------- +- + Driver: cxgb4 - Chelsio Terminator 4/5/6 1/10/25/40/100G Ethernet adapter + + File: cxgb4/t4fw-1.14.4.0.bin +@@ -141,28 +49,6 @@ Licence: Redistributable. See LICENCE.chelsio_firmware for details + + -------------------------------------------------------------------------- + +-Driver: e100 -- Intel PRO/100 Ethernet NIC +- +-File: e100/d101m_ucode.bin +-File: e100/d101s_ucode.bin +-File: e100/d102e_ucode.bin +- +-Licence: Redistributable. See LICENCE.e100 for details +- +--------------------------------------------------------------------------- +- +-Driver: acenic -- Alteon AceNIC Gigabit Ethernet card +- +-File: acenic/tg1.bin +-File: acenic/tg2.bin +- +-Licence: Unknown +- +-Found in hex form in kernel source, but source allegedly available at +-http://alteon.shareable.org/ +- +--------------------------------------------------------------------------- +- + Driver: tg3 -- Broadcom Tigon3 based gigabit Ethernet cards + + File: tigon/tg3.bin +@@ -183,83 +69,6 @@ Found in hex form in kernel source. + + -------------------------------------------------------------------------- + +-Driver: starfire - Adaptec Starfire/DuraLAN support +- +-File: adaptec/starfire_rx.bin +-File: adaptec/starfire_tx.bin +- +-Licence: Allegedly GPLv2, but no source visible. +- +-Found in hex form in kernel source, with the following notice: +- +- BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE IT IS LICENSED "AS IS" AND +- THERE IS NO WARRANTY FOR THE PROGRAM, INCLUDING BUT NOT LIMITED TO THE +- IMPLIED WARRANTIES OF MERCHANTIBILITY OR FITNESS FOR A PARTICULAR PURPOSE +- (TO THE EXTENT PERMITTED BY APPLICABLE LAW). USE OF THE PROGRAM IS AT YOUR +- OWN RISK. IN NO EVENT WILL ADAPTEC OR ITS LICENSORS BE LIABLE TO YOU FOR +- DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES +- ARISING OUT OF THE USE OR INABILITY TO USE THE PROGRAM. +- +--------------------------------------------------------------------------- +- +-Driver: tehuti - Tehuti Networks 10G Ethernet +- +-File: tehuti/bdx.bin +- +-Licence: +- +- Copyright (C) 2007 Tehuti Networks Ltd. +- +- Permission is hereby granted for the distribution of this firmware data +- in hexadecimal or equivalent format, provided this copyright notice is +- accompanying it. +- +-Found in hex form in kernel source. +- +--------------------------------------------------------------------------- +- +-Driver: typhoon - 3cr990 series Typhoon +- +-File: 3com/typhoon.bin +- +-Licence: +-/* +- * Copyright 1999-2004 3Com Corporation. All Rights Reserved. +- * +- * Redistribution and use in source and binary forms of the 3c990img.h +- * microcode software are permitted provided that the following conditions +- * are met: +- * 1. Redistribution of source code must retain the above copyright +- * notice, this list of conditions and the following disclaimer. +- * 2. Redistribution in binary form must reproduce the above copyright +- * notice, this list of conditions and the following disclaimer in the +- * documentation and/or other materials provided with the distribution. +- * 3. The name of 3Com may not be used to endorse or promote products +- * derived from this software without specific prior written permission +- * +- * THIS SOFTWARE IS PROVIDED BY 3COM ``AS IS'' AND ANY EXPRESS OR +- * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES +- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. +- * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, +- * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT +- * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +- * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY +- * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF +- * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +- * +- * USER ACKNOWLEDGES AND AGREES THAT PURCHASE OR USE OF THE 3c990img.h +- * MICROCODE SOFTWARE WILL NOT CREATE OR GIVE GROUNDS FOR A LICENSE BY +- * IMPLICATION, ESTOPPEL, OR OTHERWISE IN ANY INTELLECTUAL PROPERTY RIGHTS +- * (PATENT, COPYRIGHT, TRADE SECRET, MASK WORK, OR OTHER PROPRIETARY RIGHT) +- * EMBODIED IN ANY OTHER 3COM HARDWARE OR SOFTWARE EITHER SOLELY OR IN +- * COMBINATION WITH THE 3c990img.h MICROCODE SOFTWARE +- */ +- +-Found in hex form in kernel source. +- +--------------------------------------------------------------------------- +- + Driver: yam - YAM driver for AX.25 + + File: yam/1200.bin +@@ -272,16 +81,6 @@ Found in hex form in kernel source. + + -------------------------------------------------------------------------- + +-Driver: myri_sbus - MyriCOM Gigabit Ethernet +- +-File: myricom/lanai.bin +- +-Licence: Unknown +- +-Found in hex form in kernel source. +- +--------------------------------------------------------------------------- +- + Driver: bnx2x: Broadcom Everest + + File: bnx2x/bnx2x-e1-7.13.1.0.fw +@@ -313,27 +112,6 @@ Found in hex form in kernel source. + + -------------------------------------------------------------------------- + +-Driver: bnx2 - Broadcom NetXtremeII +- +-File: bnx2/bnx2-mips-06-6.2.3.fw +-File: bnx2/bnx2-mips-09-6.2.1b.fw +-File: bnx2/bnx2-rv2p-06-6.0.15.fw +-File: bnx2/bnx2-rv2p-09-6.0.17.fw +-File: bnx2/bnx2-rv2p-09ax-6.0.17.fw +- +-Licence: +- +- This file contains firmware data derived from proprietary unpublished +- source code, Copyright (c) 2004 - 2010 Broadcom Corporation. +- +- Permission is hereby granted for the distribution of this firmware data +- in hexadecimal or equivalent format, provided this copyright notice is +- accompanying it. +- +-Found in hex form in kernel source. +- +--------------------------------------------------------------------------- +- + Driver: netxen_nic - NetXen Multi port (1/10) Gigabit Ethernet NIC + + File: phanfw.bin +@@ -1243,46 +1021,6 @@ Licence: Redistributable. See LICENSE.amdgpu for details. + + -------------------------------------------------------------------------- + +-Driver: ib_qib - QLogic Infiniband +- +-File: qlogic/sd7220.fw +- +-Licence: +- +- * Copyright (c) 2007, 2008 QLogic Corporation. All rights reserved. +- * +- * This software is available to you under a choice of one of two +- * licenses. You may choose to be licensed under the terms of the GNU +- * General Public License (GPL) Version 2, available from the file +- * COPYING in the main directory of this source tree, or the +- * OpenIB.org BSD license below: +- * +- * Redistribution and use in source and binary forms, with or +- * without modification, are permitted provided that the following +- * conditions are met: +- * +- * - Redistributions of source code must retain the above +- * copyright notice, this list of conditions and the following +- * disclaimer. +- * +- * - Redistributions in binary form must reproduce the above +- * copyright notice, this list of conditions and the following +- * disclaimer in the documentation and/or other materials +- * provided with the distribution. +- * +- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +- * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +- * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND +- * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS +- * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN +- * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +- * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +- * SOFTWARE. +- +-Found in hex form in kernel source. +- +--------------------------------------------------------------------------- +- + Driver: qed - QLogic 4xxxx Ethernet Driver Core Module. + + File: qed/qed_init_values_zipped-8.4.2.0.bin +@@ -1317,23 +1055,6 @@ Licence: + + -------------------------------------------------------------------------- + +-Driver: vxge - Exar X3100 Series 10GbE PCIe I/O Virtualized Server Adapter +- +-File: vxge/X3fw.ncf +-File: vxge/X3fw-pxe.ncf +-Version: 1.8.1 +- +-Licence: +- +- This file contains firmware data derived from proprietary unpublished +- source code, Copyright (c) 2010 Exar Corporation. +- +- Permission is hereby granted for the distribution of this firmware data +- in hexadecimal or equivalent format, provided this copyright notice is +- accompanying it. +- +--------------------------------------------------------------------------- +- + Driver: myri10ge - Myri10GE 10GbE NIC driver + + File: myri10ge_eth_z8e.dat +@@ -2215,21 +1936,6 @@ Licence: Redistributable. See LICENCE.nvidia for details + + -------------------------------------------------------------------------- + +-Driver: hfi1 - Intel OPA Gen 1 adapter +- +-File: hfi1_dc8051.fw +-Version: 1.27.0 +-File: hfi1_fabric.fw +-Version: 0x1055 +-File: hfi1_pcie.fw +-Version: 0x4755 +-File: hfi1_sbus.fw +-Version: 0x10130001 +- +-Licence: Redistributable. See LICENSE.hfi1_firmware for details +- +--------------------------------------------------------------------------- +- + Driver: knav_qmss_queue - TI Keystone 2 QMSS driver + + File: ti-keystone/ks2_qmss_pdsp_acc48_k2_le_1_0_0_9.bin +@@ -2527,15 +2233,6 @@ Licence: Redistributable. See LICENSE.nxp_mc_firmware for details + + -------------------------------------------------------------------------- + +-Driver: mscc-phy - Microchip PHY drivers +- +-File: microchip/mscc_vsc8574_revb_int8051_29e8.bin +-File: microchip/mscc_vsc8584_revb_int8051_fb48.bin +- +-Licence: Redistributable. See LICENCE.microchip for details +- +--------------------------------------------------------------------------- +- + Driver: ice - Intel(R) Ethernet Connection E800 Series + + File: intel/ice/ddp/ice-1.3.30.0.pkg +-- +2.40.1 + diff --git a/packages/linux-firmware/0007-linux-firmware-Remove-firmware-for-Accelarator-devic.patch b/packages/linux-firmware/0007-linux-firmware-Remove-firmware-for-Accelarator-devic.patch new file mode 100644 index 00000000..15bec937 --- /dev/null +++ b/packages/linux-firmware/0007-linux-firmware-Remove-firmware-for-Accelarator-devic.patch @@ -0,0 +1,836 @@ +From eaa004914098930239abf2f3c2e9f4acc79c10b0 Mon Sep 17 00:00:00 2001 +From: Leonard Foerster +Date: Wed, 26 Jul 2023 11:06:45 +0000 +Subject: [PATCH] linux-firmware: Remove firmware for Accelarator devices + +Bottlerocket does not ship drivers for specialty accelarator hardware. +Without those drivers the firmware is of no use. Drop the firmware from +our images to reduce image size. + +The following list maps the driver names as specified in WHENCE to +kernel config options. This creates an easy reference should we need to +ship addiitonal firmware when adding drivers. + +* rvu_cptpf - CONFIG_CRYPTO_DEV_OCTEONTX_CPT && + CONFIG_CRYPTO_DEV_OCTEONTX2_CPT +* ccp - CONFIG_CRYPTO_DEV_CCP +* qat - CONFIG_CRYPTO_DEV_QAT +* liquidio - CONFIG_LIQUIDIO +* nitrox - CONFIG_NITROX +* knav_qmss_queue - CONFIG_KEYSTONE_NAVIGATOR_QMSS +* nfp - CONFIG_NFP +* fsl_mc bus - CONFIG_FSL_MC_BUS +* inside-secure - CONFIG_CRYPTO_DEV_SAFEXCEL + +Signed-off-by: Leonard Foerster +--- + LICENCE.Netronome | 65 ------------ + LICENCE.cavium | 59 ----------- + LICENCE.cavium_liquidio | 68 ------------- + LICENCE.qat_firmware | 36 ------- + LICENCE.ti-keystone | 61 ----------- + LICENSE.amd-sev | 64 ------------ + LICENSE.nxp_mc_firmware | 127 ----------------------- + WHENCE | 218 ---------------------------------------- + 8 files changed, 698 deletions(-) + delete mode 100644 LICENCE.Netronome + delete mode 100644 LICENCE.cavium + delete mode 100644 LICENCE.cavium_liquidio + delete mode 100644 LICENCE.qat_firmware + delete mode 100644 LICENCE.ti-keystone + delete mode 100644 LICENSE.amd-sev + delete mode 100644 LICENSE.nxp_mc_firmware + +diff --git a/LICENCE.Netronome b/LICENCE.Netronome +deleted file mode 100644 +index 1ed7a7c..0000000 +--- a/LICENCE.Netronome ++++ /dev/null +@@ -1,65 +0,0 @@ +-Copyright (c) 2017, NETRONOME Systems, Inc. All rights reserved. +- +-Agilio(r) Firmware License Agreement (the "AGREEMENT") +- +-BY INSTALLING OR USING IN ANY MANNER THE SOFTWARE THAT ACCOMPANIES THIS +-AGREEMENT (THE "SOFTWARE") YOU (THE "LICENSEE") ACKNOWLEDGE TO BE BOUND +-BY ALL OF THE TERMS OF THIS AGREEMENT. +- +-LICENSE GRANT. Subject to the terms and conditions set forth herein, +-Netronome Systems, Inc. ("NETRONOME") hereby grants LICENSEE a non- +-exclusive license to use, reproduce and distribute the SOFTWARE +-exclusively in object form. +- +-Restrictions. LICENSEE agrees that, (a) unless explicitly provided by +-NETRONOME, the source code of the SOFTWARE is not being provided to +-LICENSEE and is confidential and proprietary to NETRONOME and that +-LICENSEE has no right to access or use such source code. Accordingly, +-LICENSEE agrees that it shall not cause or permit the disassembly, +-decompilation or reverse engineering of the SOFTWARE or otherwise attempt +-to gain access to the source code for the SOFTWARE; and (b) LICENSEE +-agrees that it shall not subject the SOFTWARE in whole or in part, to the +-terms of any software license that requires, as a condition of use, +-modification and/or distribution that the source code of the SOFTWARE, or +-the SOFTWARE be i) disclosed or distributed in source code form; ii) +-licensed for the purpose of making derivative works of the source code of +-the SOFTWARE; or iii) redistribution of the source code of the SOFTWARE +-at no charge. +- +-DISCLAIMER OF ALL WARRANTIES. THE SOFTWARE IS PROVIDED "AS IS" AND WITH +-ALL FAULTS AND NETRONOME AND ITS LICENSORS HEREBY DISCLAIM ALL EXPRESS OR +-IMPLIED WARRANTIES OF ANY KIND, INCLUDING, WITHOUT LIMITATION, ANY +-WARRANTIES OF MERCHANTABILITY, NON-INFRINGEMENT AND FITNESS FOR A +-PARTICULAR PURPOSE. +- +-LIMITATIONS OF LIABILITY. EXCEPT WHERE PROHIBITED BY LAW, IN NO EVENT +-SHALL NETRONOME OR ANY OTHER PARTY INVOLVED IN THE CREATION, PRODUCTION, +-OR DELIVERY OF THE SOFTWARE BE LIABLE FOR ANY LOSS OF PROFITS, DATA, USE +-OF THE SOFTWARE, DOCUMENTATION OR EQUIPMENT, OR FOR ANY SPECIAL, +-INCIDENTAL, CONSEQUENTIAL, EXEMPLARY, PUNITIVE, MULTIPLE OR OTHER +-DAMAGES, ARISING FROM OR IN CONNECTION WITH THE SOFTWARE EVEN IF +-NETRONOME OR ITS LICENSORS HAVE BEEN MADE AWARE OF THE POSSIBILITY OF +-SUCH DAMAGES AND NOTWITHSTANDING ANY FAILURE OF ESSENTIAL PURPOSE OF ANY +-LIMITED REMEDY. +- +-EXPORT COMPLIANCE. LICENSEE shall not use or export or transmit the +-SOFTWARE, directly or indirectly, to any restricted countries or in any +-other manner that would violate any applicable US and other export +-control and other regulations and laws as shall from time to time govern +-the delivery, license and use of technology, including without limitation +-the Export Administration Act of 1979, as amended, and any regulations +-issued thereunder. +- +-PROHIBITION OF SOFTWARE USE IN HIGH RISK ACTIVITIES AND LIFE +-SUPPORT APPLICATIONS. The SOFTWARE is not designed, manufactured or +-intended for use as on-line control equipment in hazardous environments +-requiring fail-safe performance, such as in the operation of nuclear +-facilities, aircraft navigation or communications systems, air traffic +-control, life support systems, human implantation or any other +-application where product failure could lead to loss of life or +-catastrophic property damage or weapons systems, in which the failure of +-the SOFTWARE could lead directly to death, personal injury, or severe +-physical or environmental damage ("High Risk Activities"). Accordingly +-NETRONOME and, where applicable, NETRONOME'S third party licensors +-specifically disclaim any express or implied warranty of fitness for High +-Risk Activities. +diff --git a/LICENCE.cavium b/LICENCE.cavium +deleted file mode 100644 +index 5d2a2bb..0000000 +--- a/LICENCE.cavium ++++ /dev/null +@@ -1,59 +0,0 @@ +-Copyright © 2015, Cavium, Inc. All rights reserved. +- +-Software License Agreement +- +-ANY USE, REPRODUCTION, OR DISTRIBUTION OF THE ACCOMPANYING BINARY SOFTWARE +-CONSTITUTES LICENSEEE'S ACCEPTANCE OF THE TERMS AND CONDITIONS OF THIS AGREEMENT. +- +-Licensed Software. Subject to the terms and conditions of this Agreement, +-Cavium, Inc. ("Cavium") grants to Licensee a worldwide, non-exclusive, and +-royalty-free license to use, reproduce, and distribute the binary software in +-its complete and unmodified form as provided by Cavium. +- +-Restrictions. Licensee must reproduce the Cavium copyright notice above with +-each binary software copy. Licensee must not reverse engineer, decompile, +-disassemble or modify in any way the binary software. Licensee must not use +-the binary software in violation of any applicable law or regulation. This +-Agreement shall automatically terminate upon Licensee's breach of any term or +-condition of this Agreement in which case, Licensee shall destroy all copies of +-the binary software. +- +-Warranty Disclaimer. THE LICENSED SOFTWARE IS OFFERED "AS IS," AND CAVIUM +-GRANTS AND LICENSEE RECEIVES NO WARRANTIES OF ANY KIND, WHETHER EXPRESS, +-IMPLIED, STATUTORY, OR BY COURSE OF COMMUNICATION OR DEALING WITH LICENSEE, OR +-OTHERWISE. CAVIUM AND ITS LICENSORS SPECIFICALLY DISCLAIM ANY IMPLIED +-WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, TITLE, OR +-NONINFRINGEMENT OF THIRD PARTY RIGHTS, CONCERNING THE LICENSED SOFTWARE, +-DERIVATIVE WORKS, OR ANY DOCUMENTATION PROVIDED WITH THE FOREGOING. WITHOUT +-LIMITING THE GENERALITY OF THE FOREGOING, CAVIUM DOES NOT WARRANT THAT THE +-LICENSED SOFTWARE IS ERROR-FREE OR WILL OPERATE WITHOUT INTERRUPTION, AND +-CAVIUM GRANTS NO WARRANTY REGARDING ITS USE OR THE RESULTS THEREFROM, INCLUDING +-ITS CORRECTNESS, ACCURACY, OR RELIABILITY. +- +-Limitation of Liability. IN NO EVENT WILL LICENSEE, CAVIUM, OR ANY OF CAVIUM'S +-LICENSORS HAVE ANY LIABILITY HEREUNDER FOR ANY INDIRECT, SPECIAL, OR +-CONSEQUENTIAL DAMAGES, HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER +-FOR BREACH OF CONTRACT, TORT (INCLUDING NEGLIGENCE), OR OTHERWISE, ARISING OUT +-OF THIS AGREEMENT, INCLUDING DAMAGES FOR LOSS OF PROFITS, OR THE COST OF +-PROCUREMENT OF SUBSTITUTE GOODS, EVEN IF SUCH PARTY HAS BEEN ADVISED OF THE +-POSSIBILITY OF SUCH DAMAGES. +- +-Export and Import Laws. Licensee acknowledges and agrees that the Licensed +-Software (including technical data and related technology) may be controlled by +-the export control laws, rules, regulations, restrictions and national security +-controls of the United States and other applicable foreign agencies (the +-"Export Controls"), and agrees not export or re-export, or allow the export or +-re-export of export-controlled the Licensed Software (including technical data +-and related technology) or any copy, portion or direct product of the foregoing +-in violation of the Export Controls. Licensee hereby represents that +-(i) Licensee is not an entity or person to whom provision of the Licensed +-Software (including technical data and related technology) is restricted or +-prohibited by the Export Controls; and (ii) Licensee will not export, re-export +-or otherwise transfer the export-controlled Licensed Software (including +-technical data and related technology) in violation of U.S. sanction programs +-or export control regulations to (a) any country, or national or resident of +-any country, subject to a United States trade embargo, (b) any person or entity +-to whom shipment is restricted or prohibited by the Export Controls, or +-(c) anyone who is engaged in activities related to the design, development, +-production, or use of nuclear materials, nuclear facilities, nuclear weapons, +-missiles or chemical or biological weapons. +diff --git a/LICENCE.cavium_liquidio b/LICENCE.cavium_liquidio +deleted file mode 100644 +index 250b9fe..0000000 +--- a/LICENCE.cavium_liquidio ++++ /dev/null +@@ -1,68 +0,0 @@ +-This file contains licences pertaining to the following firmwares for +-LiquidIO (c) adapters +- +-1. lio_nic_23xx.bin, lio_210nv_nic.bin, lio_410nv_nic.bin +- +-########################################################################### +- +-1. lio_nic_23xx.bin, lio_210nv_nic.bin, lio_410nv_nic.bin +- +-Copyright (c) 2018, Cavium, Inc. All rights reserved. +- +-Software License Agreement +- +-ANY USE, REPRODUCTION, OR DISTRIBUTION OF THE ACCOMPANYING BINARY SOFTWARE +-CONSTITUTES LICENSEEE'S ACCEPTANCE OF THE TERMS AND CONDITIONS OF THIS AGREEMENT. +- +-Licensed Software. Subject to the terms and conditions of this Agreement, +-Cavium, Inc. ("Cavium") grants to Licensee a worldwide, non-exclusive, and +-royalty-free license to use, reproduce, and distribute the binary software in +-its complete and unmodified form as provided by Cavium. +- +-Restrictions. Licensee must reproduce the Cavium copyright notice above with +-each binary software copy. Licensee must not reverse engineer, decompile, +-disassemble or modify in any way the binary software. Licensee must not use +-the binary software in violation of any applicable law or regulation. This +-Agreement shall automatically terminate upon Licensee's breach of any term or +-condition of this Agreement in which case, Licensee shall destroy all copies of +-the binary software. +- +-Warranty Disclaimer. THE LICENSED SOFTWARE IS OFFERED "AS IS," AND CAVIUM +-GRANTS AND LICENSEE RECEIVES NO WARRANTIES OF ANY KIND, WHETHER EXPRESS, +-IMPLIED, STATUTORY, OR BY COURSE OF COMMUNICATION OR DEALING WITH LICENSEE, OR +-OTHERWISE. CAVIUM AND ITS LICENSORS SPECIFICALLY DISCLAIM ANY IMPLIED +-WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, TITLE, OR +-NONINFRINGEMENT OF THIRD PARTY RIGHTS, CONCERNING THE LICENSED SOFTWARE, +-DERIVATIVE WORKS, OR ANY DOCUMENTATION PROVIDED WITH THE FOREGOING. WITHOUT +-LIMITING THE GENERALITY OF THE FOREGOING, CAVIUM DOES NOT WARRANT THAT THE +-LICENSED SOFTWARE IS ERROR-FREE OR WILL OPERATE WITHOUT INTERRUPTION, AND +-CAVIUM GRANTS NO WARRANTY REGARDING ITS USE OR THE RESULTS THEREFROM, INCLUDING +-ITS CORRECTNESS, ACCURACY, OR RELIABILITY. +- +-Limitation of Liability. IN NO EVENT WILL LICENSEE, CAVIUM, OR ANY OF CAVIUM'S +-LICENSORS HAVE ANY LIABILITY HEREUNDER FOR ANY INDIRECT, SPECIAL, OR +-CONSEQUENTIAL DAMAGES, HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER +-FOR BREACH OF CONTRACT, TORT (INCLUDING NEGLIGENCE), OR OTHERWISE, ARISING OUT +-OF THIS AGREEMENT, INCLUDING DAMAGES FOR LOSS OF PROFITS, OR THE COST OF +-PROCUREMENT OF SUBSTITUTE GOODS, EVEN IF SUCH PARTY HAS BEEN ADVISED OF THE +-POSSIBILITY OF SUCH DAMAGES. +- +-Export and Import Laws. Licensee acknowledges and agrees that the Licensed +-Software (including technical data and related technology) may be controlled by +-the export control laws, rules, regulations, restrictions and national security +-controls of the United States and other applicable foreign agencies (the +-"Export Controls"), and agrees not export or re-export, or allow the export or +-re-export of export-controlled the Licensed Software (including technical data +-and related technology) or any copy, portion or direct product of the foregoing +-in violation of the Export Controls. Licensee hereby represents that +-(i) Licensee is not an entity or person to whom provision of the Licensed +-Software (including technical data and related technology) is restricted or +-prohibited by the Export Controls; and (ii) Licensee will not export, re-export +-or otherwise transfer the export-controlled Licensed Software (including +-technical data and related technology) in violation of U.S. sanction programs +-or export control regulations to (a) any country, or national or resident of +-any country, subject to a United States trade embargo, (b) any person or entity +-to whom shipment is restricted or prohibited by the Export Controls, or +-(c) anyone who is engaged in activities related to the design, development, +-production, or use of nuclear materials, nuclear facilities, nuclear weapons, +-missiles or chemical or biological weapons. +diff --git a/LICENCE.qat_firmware b/LICENCE.qat_firmware +deleted file mode 100644 +index 75a4ff1..0000000 +--- a/LICENCE.qat_firmware ++++ /dev/null +@@ -1,36 +0,0 @@ +-Copyright (c) 2014-2023 Intel Corporation. +-All rights reserved. +- +-Redistribution. Redistribution and use in binary form, without +-modification, are permitted provided that the following conditions are +-met: +- +-* Redistributions must reproduce the above copyright notice and the +- following disclaimer in the documentation and/or other materials +- provided with the distribution. +-* Neither the name of Intel Corporation nor the names of its suppliers +- may be used to endorse or promote products derived from this software +- without specific prior written permission. +-* No reverse engineering, decompilation, or disassembly of this software +- is permitted. +- +-Limited patent license. Intel Corporation grants a world-wide, +-royalty-free, non-exclusive license under patents it now or hereafter +-owns or controls to make, have made, use, import, offer to sell and +-sell ("Utilize") this software, but solely to the extent that any +-such patent is necessary to Utilize the software alone. The patent +-license shall not apply to any other combinations which include this +-software. No hardware per se is licensed hereunder. +- +-DISCLAIMER. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND +-CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, +-BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND +-FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE +-COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, +-INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, +-BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS +-OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +-ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR +-TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE +-USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH +-DAMAGE. +diff --git a/LICENCE.ti-keystone b/LICENCE.ti-keystone +deleted file mode 100644 +index 62cc3b3..0000000 +--- a/LICENCE.ti-keystone ++++ /dev/null +@@ -1,61 +0,0 @@ +-Copyright (c) 2015 Texas Instruments Incorporated +- +-All rights reserved not granted herein. +- +-Limited License. +- +-Texas Instruments Incorporated grants a world-wide, royalty-free, non-exclusive +-license under copyrights and patents it now or hereafter owns or controls to +-make, have made, use, import, offer to sell and sell ("Utilize") this software +-subject to the terms herein. With respect to the foregoing patent license, such +-license is granted solely to the extent that any such patent is necessary to +-Utilize the software alone. The patent license shall not apply to any +-combinations which include this software, other than combinations with devices +-manufactured by or for TI (“TI Devices”). No hardware patent is licensed +-hereunder. +- +-Redistributions must preserve existing copyright notices and reproduce this +-license (including the above copyright notice and the disclaimer and +-(if applicable) source code license limitations below) in the documentation +-and/or other materials provided with the distribution +- +-Redistribution and use in binary form, without modification, are permitted +-provided that the following conditions are met: +- +- * No reverse engineering, decompilation, or disassembly of this +- software is permitted with respect to any software provided in binary +- form. +- +- * any redistribution and use are licensed by TI for use only with TI +- Devices. +- +- * Nothing shall obligate TI to provide you with source code for the +- software licensed and provided to you in object code. +- +-If software source code is provided to you, modification and redistribution of +-the source code are permitted provided that the following conditions are met: +- +- * any redistribution and use of the source code, including any +- resulting derivative works, are licensed by TI for use only with TI +- Devices. +- +- * any redistribution and use of any object code compiled from the +- source code and any resulting derivative works, are licensed by TI +- for use only with TI Devices. +- +-Neither the name of Texas Instruments Incorporated nor the names of its +-suppliers may be used to endorse or promote products derived from this +-software without specific prior written permission. +- +-DISCLAIMER. +- +-THIS SOFTWARE IS PROVIDED BY TI AND TI’S LICENSORS "AS IS" AND ANY EXPRESS OR +-IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +-MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO +-EVENT SHALL TI AND TI’S LICENSORS BE LIABLE FOR ANY DIRECT, INDIRECT, +-INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +-LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR +-PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF +-LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE +-OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF +-ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +diff --git a/LICENSE.amd-sev b/LICENSE.amd-sev +deleted file mode 100644 +index de4d948..0000000 +--- a/LICENSE.amd-sev ++++ /dev/null +@@ -1,64 +0,0 @@ +-Copyright (C) 2015-2019 Advanced Micro Devices, Inc., All rights reserved. +- +-Permission is hereby granted by Advanced Micro Devices, Inc. ("AMD"), +-free of any license fees, to any person obtaining a copy of this +-microcode in binary form (the "Software") ("You"), to install, +-reproduce, copy and distribute copies of the Software and to permit +-persons to whom the Software is provided to do the same, subject to +-the following terms and conditions. Your use of any portion of the +-Software shall constitute Your acceptance of the following terms and +-conditions. If You do not agree to the following terms and conditions, +-do not use, retain or redistribute any portion of the Software. +- +-If You redistribute this Software, You must reproduce the above +-copyright notice and this license with the Software. +-Without specific, prior, written permission from AMD, You may not +-reference AMD or AMD products in the promotion of any product derived +-from or incorporating this Software in any manner that implies that +-AMD endorses or has certified such product derived from or +-incorporating this Software. +- +-You may not reverse engineer, decompile, or disassemble this Software +-or any portion thereof. +- +-THE SOFTWARE IS PROVIDED "AS IS" WITHOUT ANY EXPRESS OR IMPLIED +-WARRANTY OF ANY KIND, INCLUDING BUT NOT LIMITED TO WARRANTIES OF +-MERCHANTABILITY, NONINFRINGEMENT, TITLE, FITNESS FOR ANY PARTICULAR +-PURPOSE, OR WARRANTIES ARISING FROM CONDUCT, COURSE OF DEALING, OR +-USAGE OF TRADE. IN NO EVENT SHALL AMD OR ITS LICENSORS BE LIABLE FOR +-ANY DAMAGES WHATSOEVER (INCLUDING, WITHOUT LIMITATION, DAMAGES FOR +-LOSS OF PROFITS, BUSINESS INTERRUPTION, OR LOSS OF DATA OR +-INFORMATION) ARISING OUT OF AMD'S NEGLIGENCE, GROSS NEGLIGENCE, THE +-USE OF OR INABILITY TO USE THE SOFTWARE, EVEN IF AMD HAS BEEN ADVISED +-OF THE POSSIBILITY OF SUCH DAMAGES. BECAUSE SOME JURISDICTIONS +-PROHIBIT THE EXCLUSION OR LIMITATION OF LIABILITY FOR CONSEQUENTIAL OR +-INCIDENTAL DAMAGES OR THE EXCLUSION OF IMPLIED WARRANTIES, THE ABOVE +-LIMITATION MAY NOT APPLY TO YOU. +- +-Without limiting the foregoing, the Software may implement third party +-technologies for which You must obtain licenses from parties other +-than AMD. You agree that AMD has not obtained or conveyed to You, and +-that You shall be responsible for obtaining the rights to use and/or +-distribute the applicable underlying intellectual property rights +-related to the third party technologies. These third party +-technologies are not licensed hereunder. +- +-If You use the Software (in whole or in part), You shall adhere to all +-applicable U.S., European, and other export laws, including but not +-limited to the U.S. Export Administration Regulations ("EAR"), (15 +-C.F.R. Sections 730 through 774), and E.U. Council Regulation (EC) No +-1334/2000 of 22 June 2000. Further, pursuant to Section 740.6 of the +-EAR, You hereby certify that, except pursuant to a license granted by +-the United States Department of Commerce Bureau of Industry and +-Security or as otherwise permitted pursuant to a License Exception +-under the U.S. Export Administration Regulations ("EAR"), You will not +-(1) export, re-export or release to a national of a country in Country +-Groups D:1, E:1 or E:2 any restricted technology, software, or source +-code You receive hereunder, or (2) export to Country Groups D:1, E:1 +-or E:2 the direct product of such technology or software, if such +-foreign produced direct product is subject to national security +-controls as identified on the Commerce Control List (currently found +-in Supplement 1 to Part 774 of EAR). For the most current Country +-Group listings, or for additional information about the EAR or Your +-obligations under those regulations, please refer to the U.S. Bureau +-of Industry and Security’s website at ttp://www.bis.doc.gov/. +diff --git a/LICENSE.nxp_mc_firmware b/LICENSE.nxp_mc_firmware +deleted file mode 100644 +index 4b12f58..0000000 +--- a/LICENSE.nxp_mc_firmware ++++ /dev/null +@@ -1,127 +0,0 @@ +-Copyright (c) 2018 NXP. All rights reserved. +- +-Software License Agreement ("Agreement") +- +-ANY USE, REPRODUCTION, OR DISTRIBUTION OF THE ACCOMPANYING BINARY SOFTWARE +-CONSTITUTES LICENSEE'S ACCEPTANCE OF THE TERMS AND CONDITIONS OF THIS AGREEMENT. +- +-Licensed Software. "Binary Software" means software in binary form specified in +-ANNEX A. Subject to the terms and conditions of this Agreement, NXP USA, Inc. +-("Licensor"), grants to you ("Licensee") a worldwide, non-exclusive, and +-royalty-free license to reproduce and distribute the Binary Software in its +-complete and unmodified binary form as provided by Licensor, for use solely in +-conjunction with a programmable processing unit supplied directly or indirectly +-from Licensor. +- +-Restrictions. Licensee must reproduce the Licensor copyright notice above with +-each binary copy of the Binary Software or in the accompanying documentation. +-Licensee must not reverse engineer, decompile, disassemble or modify in any way +-the Binary Software. Licensee must not use the Binary Software in violation of +-any applicable law or regulation. This Agreement shall automatically terminate +-upon Licensee's breach of any term or condition of this Agreement in which case, +-Licensee shall destroy all copies of the Binary Software. Neither the name of +-Licensor nor the names of its suppliers may be used to endorse or promote +-products derived from this Binary Software without specific prior written +-permission. +- +-Disclaimer. TO THE MAXIMUM EXTENT PERMITTED BY LAW, LICENSOR EXPRESSLY +-DISCLAIMS ANY WARRANTY FOR THE BINARY SOFTWARE. THE BINARY SOFTWARE IS PROVIDED +-"AS IS", WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESS OR IMPLIED, INCLUDING +-WITHOUT LIMITATION THE IMPLIED WARRANTIES OF MERCHANTABILITY, FITNESS FOR A +-PARTICULAR PURPOSE, OR NON-INFRINGEMENT. WITHOUT LIMITING THE GENERALITY OF THE +-FOREGOING, LICENSOR DOES NOT WARRANT THAT THE BINARY SOFTWARE IS ERROR-FREE OR +-WILL OPERATE WITHOUT INTERRUPTION, AND LICENSOR GRANTS NO WARRANTY REGARDING ITS +-USE OR THE RESULTS THEREFROM, INCLUDING ITS CORRECTNESS, ACCURACY, OR +-RELIABILITY. +- +-Limitation of Liability. IN NO EVENT WILL LICENSOR, OR ANY OF LICENSOR'S +-LICENSORS HAVE ANY LIABILITY HEREUNDER FOR ANY INDIRECT, SPECIAL, OR +-CONSEQUENTIAL DAMAGES, HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER +-FOR BREACH OF CONTRACT, TORT (INCLUDING NEGLIGENCE), OR OTHERWISE, ARISING OUT +-OF THIS AGREEMENT, INCLUDING DAMAGES FOR LOSS OF PROFITS, OR THE COST OF +-PROCUREMENT OF SUBSTITUTE GOODS, EVEN IF SUCH PARTY HAS BEEN ADVISED OF THE +-POSSIBILITY OF SUCH DAMAGES. LICENSOR'S TOTAL LIABILITY FOR ALL COSTS, DAMAGES, +-CLAIMS, OR LOSSES WHATSOEVER ARISING OUT OF OR IN CONNECTION WITH THIS AGREEMENT +-OR THE BINARY SOFTWARE SUPPLIED UNDER THIS AGREEMENT IS LIMITED TO THE AGGREGATE +-AMOUNT PAID BY LICENSEE TO LICENSOR IN CONNECTION WITH THE BINARY SOFTWARE TO +-WHICH LOSSES OR DAMAGES ARE CLAIMED. +- +-Trade Compliance. Licensee shall comply with all applicable export and import +-control laws and regulations including but not limited to the US Export +-Administration Regulation (including prohibited party lists issued by other +-federal governments), Catch-all regulations and all national and international +-embargoes. Licensee further agrees that it will not knowingly transfer, divert, +-export or re-export, directly or indirectly, any product, software, including +-software source code, or technology restricted by such regulations or by other +-applicable national regulations, received from Licensor under this Agreement, +-or any direct product of such software or technical data to any person, firm, +-entity, country or destination to which such transfer, diversion, export or +-re-export is restricted or prohibited, without obtaining prior written +-authorization from the applicable competent government authorities to the extent +-required by those laws. Licensee acknowledge that the "restricted encryption +-software" that is subject to the US Export Administration Regulations (EAR), is +-not intended for use by a government end user, as defined in part 772 of the +-EAR. This provision shall survive termination or expiration of this Agreement. +- +-Assignment. Licensee may not assign this Agreement without the prior written +-consent of Licensor. Licensor may assign this Agreement without Licensee's +-consent. +- +-Governing Law. This Agreement will be governed by, construed, and enforced in +-accordance with the laws of the State of Texas, USA, without regard to conflicts +-of laws principles, will apply to all matters relating to this Agreement or the +-Binary Software, and Licensee agrees that any litigation will be subject to the +-exclusive jurisdiction of the state or federal courts Texas, USA. The United +-Nations Convention on Contracts for the International Sale of Goods will not +-apply to this Agreement. +- +-Restrictions, Warranty Disclaimer, Limitation of Liability, Trade Compliance, +-Assignment, Governing Law, and Third Party Terms shall survive termination or +-expiration of this Agreement. +- +-Third Party Terms. The licensed Binary Software includes the following third +-party software for which the following terms apply: +- +-Libfdt - Flat Device Tree manipulation +-Copyright (c) 2006 David Gibson, IBM Corporation +-All rights reserved. +- +-Redistributions must reproduce the above copyright notice, this list of +-conditions and the following disclaimer in the documentation and/or other +-materials provided with the distribution. +- +-THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND +-ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED +-WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +-DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR +-ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES +-(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; +-LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON +-ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +-(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS +-SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +- +-LibElf +-Copyright (c) 2006,2008-2011 Joseph Koshy +-All rights reserved. +- +-Redistributions must reproduce the above copyright notice, this list of +-conditions and the following disclaimer in the documentation and/or other +-materials provided with the distribution. +- +-THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND +-ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED +-WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +-DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR +-ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES +-(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; +-LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON +-ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +-(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS +-SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +- +- +-ANNEX A +-BINARY SOFTWARE +-Only software in binary form may be provided under this Agreement +- +diff --git a/WHENCE b/WHENCE +index f6b0299..58e9ca1 100644 +--- a/WHENCE ++++ b/WHENCE +@@ -1071,19 +1071,6 @@ License: Redistributable. See LICENCE.myri10ge_firmware for details. + + -------------------------------------------------------------------------- + +-Driver: ccp - Platform Security Processor (PSP) device +- +-File: amd/amd_sev_fam17h_model0xh.sbin +-Version: 2022-2-25 +-File: amd/amd_sev_fam17h_model3xh.sbin +-Version: 2022-2-25 +-File: amd/amd_sev_fam19h_model0xh.sbin +-Version: 2022-2-25 +- +-License: Redistributable. See LICENSE.amd-sev for details +- +--------------------------------------------------------------------------- +- + Driver: microcode_amd - AMD CPU Microcode Update Driver for Linux + + File: amd-ucode/microcode_amd.bin +@@ -1107,52 +1094,6 @@ License: Redistributable. See LICENSE.amd-ucode for details + + -------------------------------------------------------------------------- + +-Driver: qat - Intel(R) QAT crypto accelerator +- +-File: qat_895xcc.bin +-File: qat_895xcc_mmp.bin +-File: qat_c3xxx.bin +-File: qat_c3xxx_mmp.bin +-File: qat_c62x.bin +-File: qat_c62x_mmp.bin +-Link: qat_mmp.bin -> qat_895xcc_mmp.bin +-File: qat_4xxx.bin +-File: qat_4xxx_mmp.bin +- +-Licence: Redistributable. See LICENCE.qat_firmware for details +- +--------------------------------------------------------------------------- +- +-Driver: liquidio -- Cavium LiquidIO driver +- +-File: liquidio/lio_23xx_nic.bin +-Version: v1.7.2 +- +-File: liquidio/lio_210nv_nic.bin +-Version: v1.7.2 +- +-File: liquidio/lio_210sv_nic.bin +-Version: v1.7.2 +- +-File: liquidio/lio_410nv_nic.bin +-Version: v1.7.2 +- +-Licence: Redistributable. See LICENCE.cavium_liquidio for details +- +--------------------------------------------------------------------------- +- +-Driver: nitrox -- Cavium CNN55XX crypto driver +- +-File: cavium/cnn55xx_ae.fw +-Version: v01 +- +-File: cavium/cnn55xx_se.fw +-Version: v10 +- +-Licence: Redistributable. See LICENCE.cavium for details +- +--------------------------------------------------------------------------- +- + Driver: i915 -- Intel Integrated Graphics driver + + File: i915/skl_dmc_ver1_23.bin +@@ -1936,14 +1877,6 @@ Licence: Redistributable. See LICENCE.nvidia for details + + -------------------------------------------------------------------------- + +-Driver: knav_qmss_queue - TI Keystone 2 QMSS driver +- +-File: ti-keystone/ks2_qmss_pdsp_acc48_k2_le_1_0_0_9.bin +- +-Licence: Redistributable. See LICENCE.ti-keystone for details. +- +--------------------------------------------------------------------------- +- + Driver: mtk_scp - MediaTek SCP System Control Processing Driver + + File: mediatek/mt8183/scp.img +@@ -1959,100 +1892,6 @@ Licence: Redistributable. See LICENCE.mediatek for details. + + -------------------------------------------------------------------------- + +-Driver: nfp - Netronome Flow Processor +- +-Link: netronome/nic_AMDA0081-0001_1x40.nffw -> nic/nic_AMDA0081-0001_1x40.nffw +-Link: netronome/nic_AMDA0097-0001_2x40.nffw -> nic/nic_AMDA0097-0001_2x40.nffw +-Link: netronome/nic_AMDA0099-0001_2x10.nffw -> nic/nic_AMDA0099-0001_2x10.nffw +-Link: netronome/nic_AMDA0081-0001_4x10.nffw -> nic/nic_AMDA0081-0001_4x10.nffw +-Link: netronome/nic_AMDA0097-0001_4x10_1x40.nffw -> nic/nic_AMDA0097-0001_4x10_1x40.nffw +-Link: netronome/nic_AMDA0099-0001_1x10_1x25.nffw -> nic/nic_AMDA0099-0001_1x10_1x25.nffw +-Link: netronome/nic_AMDA0099-0001_2x25.nffw -> nic/nic_AMDA0099-0001_2x25.nffw +-Link: netronome/nic_AMDA0096-0001_2x10.nffw -> nic/nic_AMDA0096-0001_2x10.nffw +-Link: netronome/nic_AMDA0097-0001_8x10.nffw -> nic/nic_AMDA0097-0001_8x10.nffw +-Link: netronome/nic_AMDA0058-0011_2x40.nffw -> nic/nic_AMDA0058-0011_2x40.nffw +-Link: netronome/nic_AMDA0058-0012_2x40.nffw -> nic/nic_AMDA0058-0012_2x40.nffw +-Link: netronome/nic_AMDA0078-0011_1x100.nffw -> nic/nic_AMDA0078-0011_1x100.nffw +-File: netronome/nic/nic_AMDA0081-0001_1x40.nffw +-File: netronome/nic/nic_AMDA0097-0001_2x40.nffw +-File: netronome/nic/nic_AMDA0099-0001_2x10.nffw +-File: netronome/nic/nic_AMDA0081-0001_4x10.nffw +-File: netronome/nic/nic_AMDA0097-0001_4x10_1x40.nffw +-File: netronome/nic/nic_AMDA0099-0001_1x10_1x25.nffw +-File: netronome/nic/nic_AMDA0099-0001_2x25.nffw +-File: netronome/nic/nic_AMDA0096-0001_2x10.nffw +-File: netronome/nic/nic_AMDA0097-0001_8x10.nffw +-File: netronome/nic/nic_AMDA0058-0011_2x40.nffw +-File: netronome/nic/nic_AMDA0058-0012_2x40.nffw +-File: netronome/nic/nic_AMDA0078-0011_1x100.nffw +-File: netronome/nic-sriov/nic_AMDA0081-0001_1x40.nffw +-File: netronome/nic-sriov/nic_AMDA0097-0001_2x40.nffw +-File: netronome/nic-sriov/nic_AMDA0099-0001_2x10.nffw +-File: netronome/nic-sriov/nic_AMDA0081-0001_4x10.nffw +-File: netronome/nic-sriov/nic_AMDA0097-0001_4x10_1x40.nffw +-File: netronome/nic-sriov/nic_AMDA0099-0001_1x10_1x25.nffw +-File: netronome/nic-sriov/nic_AMDA0099-0001_2x25.nffw +-File: netronome/nic-sriov/nic_AMDA0096-0001_2x10.nffw +-File: netronome/nic-sriov/nic_AMDA0097-0001_8x10.nffw +-File: netronome/nic-sriov/nic_AMDA0058-0011_2x40.nffw +-File: netronome/nic-sriov/nic_AMDA0058-0012_2x40.nffw +-File: netronome/nic-sriov/nic_AMDA0078-0011_1x100.nffw +- +-Version: v2.1.16.1 +- +-File: netronome/flower/nic_AMDA0099.nffw +-File: netronome/flower/nic_AMDA0096.nffw +-File: netronome/flower/nic_AMDA0097.nffw +-File: netronome/flower/nic_AMDA0058.nffw +-Link: netronome/flower/nic_AMDA0081.nffw -> nic_AMDA0097.nffw +-Link: netronome/flower/nic_AMDA0081-0001_1x40.nffw -> nic_AMDA0081.nffw +-Link: netronome/flower/nic_AMDA0097-0001_2x40.nffw -> nic_AMDA0097.nffw +-Link: netronome/flower/nic_AMDA0099-0001_2x10.nffw -> nic_AMDA0099.nffw +-Link: netronome/flower/nic_AMDA0081-0001_4x10.nffw -> nic_AMDA0081.nffw +-Link: netronome/flower/nic_AMDA0097-0001_4x10_1x40.nffw -> nic_AMDA0097.nffw +-Link: netronome/flower/nic_AMDA0099-0001_2x25.nffw -> nic_AMDA0099.nffw +-Link: netronome/flower/nic_AMDA0096-0001_2x10.nffw -> nic_AMDA0096.nffw +-Link: netronome/flower/nic_AMDA0097-0001_8x10.nffw -> nic_AMDA0097.nffw +-Link: netronome/flower/nic_AMDA0099-0001_1x10_1x25.nffw -> nic_AMDA0099.nffw +-Link: netronome/flower/nic_AMDA0058-0011_1x100.nffw -> nic_AMDA0058.nffw +-Link: netronome/flower/nic_AMDA0058-0011_2x40.nffw -> nic_AMDA0058.nffw +-Link: netronome/flower/nic_AMDA0058-0011_4x10_1x40.nffw -> nic_AMDA0058.nffw +-Link: netronome/flower/nic_AMDA0058-0011_8x10.nffw -> nic_AMDA0058.nffw +-Link: netronome/flower/nic_AMDA0058-0012_1x100.nffw -> nic_AMDA0058.nffw +-Link: netronome/flower/nic_AMDA0058-0012_2x40.nffw -> nic_AMDA0058.nffw +-Link: netronome/flower/nic_AMDA0058-0012_4x10_1x40.nffw -> nic_AMDA0058.nffw +-Link: netronome/flower/nic_AMDA0058-0012_8x10.nffw -> nic_AMDA0058.nffw +-Link: netronome/flower/nic_AMDA0078-0011_1x100.nffw -> nic_AMDA0058.nffw +-Link: netronome/flower/nic_AMDA0078-0011_2x40.nffw -> nic_AMDA0058.nffw +-Link: netronome/flower/nic_AMDA0078-0011_4x10_1x40.nffw -> nic_AMDA0058.nffw +-Link: netronome/flower/nic_AMDA0078-0011_8x10.nffw -> nic_AMDA0058.nffw +-Link: netronome/flower/nic_AMDA0078-0012_1x100.nffw -> nic_AMDA0058.nffw +-Link: netronome/flower/nic_AMDA0078-0012_2x40.nffw -> nic_AMDA0058.nffw +-Link: netronome/flower/nic_AMDA0078-0012_4x10_1x40.nffw -> nic_AMDA0058.nffw +-Link: netronome/flower/nic_AMDA0078-0012_8x10.nffw -> nic_AMDA0058.nffw +- +-Version: AOTC-2.14.A.6 +- +-File: netronome/bpf/nic_AMDA0081-0001_1x40.nffw +-File: netronome/bpf/nic_AMDA0097-0001_2x40.nffw +-File: netronome/bpf/nic_AMDA0099-0001_2x10.nffw +-File: netronome/bpf/nic_AMDA0081-0001_4x10.nffw +-File: netronome/bpf/nic_AMDA0097-0001_4x10_1x40.nffw +-File: netronome/bpf/nic_AMDA0099-0001_1x10_1x25.nffw +-File: netronome/bpf/nic_AMDA0099-0001_2x25.nffw +-File: netronome/bpf/nic_AMDA0096-0001_2x10.nffw +-File: netronome/bpf/nic_AMDA0097-0001_8x10.nffw +-File: netronome/bpf/nic_AMDA0058-0011_2x40.nffw +-File: netronome/bpf/nic_AMDA0058-0012_2x40.nffw +-File: netronome/bpf/nic_AMDA0078-0011_1x100.nffw +- +-Version: v2.0.6.124 +- +- +-Licence: Redistributable. See LICENCE.Netronome for details +- +--------------------------------------------------------------------------- +- + Driver: imx-sdma - support for i.MX SDMA driver + + File: imx/sdma/sdma-imx6q.bin +@@ -2211,28 +2050,6 @@ Licence: + + -------------------------------------------------------------------------- + +-Driver: fsl-mc bus - NXP Management Complex Bus Driver +- +-File: dpaa2/mc/mc_10.10.0_ls1088a.itb +-File: dpaa2/mc/mc_10.10.0_ls2088a.itb +-File: dpaa2/mc/mc_10.10.0_lx2160a.itb +-File: dpaa2/mc/mc_10.14.3_ls1088a.itb +-File: dpaa2/mc/mc_10.14.3_ls2088a.itb +-File: dpaa2/mc/mc_10.14.3_lx2160a.itb +-File: dpaa2/mc/mc_10.16.2_ls1088a.itb +-File: dpaa2/mc/mc_10.16.2_ls2088a.itb +-File: dpaa2/mc/mc_10.16.2_lx2160a.itb +-File: dpaa2/mc/mc_10.18.0_ls1088a.itb +-File: dpaa2/mc/mc_10.18.0_ls2088a.itb +-File: dpaa2/mc/mc_10.18.0_lx2160a.itb +-File: dpaa2/mc/mc_10.28.1_ls1088a.itb +-File: dpaa2/mc/mc_10.28.1_ls2088a.itb +-File: dpaa2/mc/mc_10.28.1_lx2160a.itb +- +-Licence: Redistributable. See LICENSE.nxp_mc_firmware for details +- +--------------------------------------------------------------------------- +- + Driver: ice - Intel(R) Ethernet Connection E800 Series + + File: intel/ice/ddp/ice-1.3.30.0.pkg +@@ -2247,21 +2064,6 @@ License: Redistributable. See LICENSE.ice_enhanced for details + + -------------------------------------------------------------------------- + +-Driver: inside-secure -- Inside Secure EIP197 crypto driver +- +-File: inside-secure/eip197_minifw/ipue.bin +-File: inside-secure/eip197_minifw/ifpp.bin +- +-Licence: Redistributable. +-Copyright (c) 2019 Verimatrix, Inc. +- +-Derived from proprietary unpublished source code. +-Permission is hereby granted for the distribution of this firmware +-as part of Linux or other Open Source operating system kernel, +-provided this copyright notice is accompanying it. +- +------------------------------------------------- +- + Driver: prestera - Marvell driver for Prestera family ASIC devices + + File: mrvl/prestera/mvsw_prestera_fw-v2.0.img +@@ -2273,23 +2075,3 @@ File: mrvl/prestera/mvsw_prestera_fw_arm64-v4.1.img + Licence: Redistributable. See LICENCE.Marvell for details. + + ------------------------------------------------ +- +-Driver: rvu_cptpf - Marvell CPT driver +- +-File: mrvl/cpt01/ae.out +-File: mrvl/cpt01/se.out +-File: mrvl/cpt01/ie.out +-File: mrvl/cpt02/ae.out +-File: mrvl/cpt02/se.out +-File: mrvl/cpt02/ie.out +-File: mrvl/cpt03/ae.out +-File: mrvl/cpt03/se.out +-File: mrvl/cpt03/ie.out +-File: mrvl/cpt04/ae.out +-File: mrvl/cpt04/se.out +-File: mrvl/cpt04/ie.out +-Version: v1.21 +- +-Licence: Redistributable. See LICENCE.Marvell for details. +- +---------------------------------------------------------------------------- +-- +2.40.1 + diff --git a/packages/linux-firmware/0008-linux-firmware-gpu-Remove-firmware-for-GPU-devices.patch b/packages/linux-firmware/0008-linux-firmware-gpu-Remove-firmware-for-GPU-devices.patch new file mode 100644 index 00000000..92eb94f9 --- /dev/null +++ b/packages/linux-firmware/0008-linux-firmware-gpu-Remove-firmware-for-GPU-devices.patch @@ -0,0 +1,1923 @@ +From 2819be643186fa19869700e0af67444872d677c7 Mon Sep 17 00:00:00 2001 +From: Leonard Foerster +Date: Wed, 26 Jul 2023 11:16:37 +0000 +Subject: [PATCH] linux-firmware: gpu: Remove firmware for GPU devices + +Bottlerocket does not provide drivers for any GPUs for any of its +kernels. Thus, shipping firmware for any of these non-supported devices +makes no sense. One exception is the nvidia drivers for tesla devices in +aws-*-nvidia variants. These variants include drivers through +kmod-*-nvidia packages which ship device specific firmware for supported +cards. + +The following list maps drivers as specified in WHENCE to kernel config +options for easy reference, should firmware be needed through driver +addition. + +* mga - CONFIG_DRM_MGA && CONFIG_DRM_MGAG200 +* r128 - CONFIG_DRM_R128 +* radeon - CONFIG_DRM_RADEON +* amdgpu - CONFIG_DRM_AMDGPU +* nouveau - CONFIG_DRM_NOUVEAU +* adreno - CONFIG_DRM_MSM + +Signed-off-by: Leonard Foerster +--- + LICENCE.nvidia | 131 ----- + LICENSE.amdgpu | 51 -- + LICENSE.qcom | 206 ------- + LICENSE.qcom_yamato | 25 - + LICENSE.radeon | 51 -- + WHENCE | 1363 ------------------------------------------- + 6 files changed, 1827 deletions(-) + delete mode 100644 LICENCE.nvidia + delete mode 100644 LICENSE.amdgpu + delete mode 100644 LICENSE.qcom + delete mode 100644 LICENSE.qcom_yamato + delete mode 100644 LICENSE.radeon + +diff --git a/LICENCE.nvidia b/LICENCE.nvidia +deleted file mode 100644 +index b99d5a3..0000000 +--- a/LICENCE.nvidia ++++ /dev/null +@@ -1,131 +0,0 @@ +- License For Customer Use of NVIDIA Software +- +- +-IMPORTANT NOTICE -- READ CAREFULLY: This License For Customer Use of +-NVIDIA Software ("LICENSE") is the agreement which governs use of +-the software of NVIDIA Corporation and its subsidiaries ("NVIDIA") +-downloadable herefrom, including computer software and associated +-printed materials ("SOFTWARE"). By downloading, installing, copying, +-or otherwise using the SOFTWARE, you agree to be bound by the terms +-of this LICENSE. If you do not agree to the terms of this LICENSE, +-do not download the SOFTWARE. +- +-RECITALS +- +-Use of NVIDIA's products requires three elements: the SOFTWARE, the +-hardware, and a personal computer. The SOFTWARE is protected by copyright +-laws and international copyright treaties, as well as other intellectual +-property laws and treaties. The SOFTWARE may be protected by various +-patents, and is not sold, and instead is only licensed for use, strictly +-in accordance with this document. The hardware is protected by various +-patents, and is sold, but this agreement does not cover that sale, since +-it may not necessarily be sold as a package with the SOFTWARE. This +-agreement sets forth the terms and conditions of the SOFTWARE LICENSE only. +- +-1. DEFINITIONS +- +-1.1 Customer. Customer means the entity or individual that +-downloads or otherwise obtains the SOFTWARE. +- +-2. GRANT OF LICENSE +- +-2.1 Rights and Limitations of Grant. NVIDIA hereby grants Customer +-the following non-exclusive, non-transferable right to use the +-SOFTWARE, with the following limitations: +- +-2.1.1 Rights. Customer may install and use multiple copies of the +-SOFTWARE on a shared computer or concurrently on different computers, +-and make multiple back-up copies of the SOFTWARE, solely for Customer's +-use within Customer's Enterprise. "Enterprise" shall mean individual use +-by Customer or any legal entity (such as a corporation or university) +-and the subsidiaries it owns by more than fifty percent (50%). +- +-2.1.2 Open Source Exception. Notwithstanding the foregoing terms +-of Section 2.1.1, SOFTWARE may be copied and redistributed solely for +-use on operating systems distributed under the terms of an OSI-approved +-open source license as listed by the Open Source Initiative at +-http://opensource.org, provided that the binary files thereof are not +-modified, and Customer provides a copy of this license with the SOFTWARE. +- +-2.1.3 Limitations. +- +-No Reverse Engineering. Customer may not reverse engineer, +-decompile, or disassemble the SOFTWARE, nor attempt in any other +-manner to obtain the source code. +- +-Usage. SOFTWARE is licensed only for use with microprocessor(s) which have +-been (i) designed by NVIDIA and (ii) either (a) sold by or (b) licensed by +-NVIDIA. Customer shall not use SOFTWARE in conjunction with, nor cause +-SOFTWARE to be executed by, any other microprocessor. +- +-No Translation. Customer shall not translate SOFTWARE, nor cause or permit +-SOFTWARE to be translated, from the architecture or language in which it is +-originally provided by NVIDIA, into any other architecture or language. +- +-No Rental. Customer may not rent or lease the SOFTWARE to someone +-else. +- +-3. TERMINATION +- +-This LICENSE will automatically terminate if Customer fails to +-comply with any of the terms and conditions hereof. In such event, +-Customer must destroy all copies of the SOFTWARE and all of its +-component parts. +- +-Defensive Suspension. If Customer commences or participates in any legal +-proceeding against NVIDIA, then NVIDIA may, in its sole discretion, +-suspend or terminate all license grants and any other rights provided +-under this LICENSE during the pendency of such legal proceedings. +- +-4. COPYRIGHT +- +-All title and copyrights in and to the SOFTWARE (including but +-not limited to all images, photographs, animations, video, audio, +-music, text, and other information incorporated into the SOFTWARE), +-the accompanying printed materials, and any copies of the SOFTWARE, +-are owned by NVIDIA, or its suppliers. The SOFTWARE is protected +-by copyright laws and international treaty provisions. Accordingly, +-Customer is required to treat the SOFTWARE like any other copyrighted +-material, except as otherwise allowed pursuant to this LICENSE +-and that it may make one copy of the SOFTWARE solely for backup or +-archive purposes. +- +-5. APPLICABLE LAW +- +-This agreement shall be deemed to have been made in, and shall be +-construed pursuant to, the laws of the State of California. +- +-6. DISCLAIMER OF WARRANTIES AND LIMITATION ON LIABILITY +- +-6.1 No Warranties. TO THE MAXIMUM EXTENT PERMITTED BY APPLICABLE +-LAW, THE SOFTWARE IS PROVIDED "AS IS" AND NVIDIA AND ITS SUPPLIERS +-DISCLAIM ALL WARRANTIES, EITHER EXPRESS OR IMPLIED, INCLUDING, BUT +-NOT LIMITED TO, IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS +-FOR A PARTICULAR PURPOSE. +- +-6.2 No Liability for Consequential Damages. TO THE MAXIMUM +-EXTENT PERMITTED BY APPLICABLE LAW, IN NO EVENT SHALL NVIDIA OR +-ITS SUPPLIERS BE LIABLE FOR ANY SPECIAL, INCIDENTAL, INDIRECT, OR +-CONSEQUENTIAL DAMAGES WHATSOEVER (INCLUDING, WITHOUT LIMITATION, +-DAMAGES FOR LOSS OF BUSINESS PROFITS, BUSINESS INTERRUPTION, LOSS +-OF BUSINESS INFORMATION, OR ANY OTHER PECUNIARY LOSS) ARISING OUT +-OF THE USE OF OR INABILITY TO USE THE SOFTWARE, EVEN IF NVIDIA HAS +-BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. +- +-7. MISCELLANEOUS +- +-The United Nations Convention on Contracts for the International +-Sale of Goods is specifically disclaimed. If any provision of this +-LICENSE is inconsistent with, or cannot be fully enforced under, +-the law, such provision will be construed as limited to the extent +-necessary to be consistent with and fully enforceable under the law. +-This agreement is the final, complete and exclusive agreement between +-the parties relating to the subject matter hereof, and supersedes +-all prior or contemporaneous understandings and agreements relating +-to such subject matter, whether oral or written. Customer agrees +-that it will not ship, transfer or export the SOFTWARE into any +-country, or use the SOFTWARE in any manner, prohibited by the +-United States Bureau of Export Administration or any export laws, +-restrictions or regulations. This LICENSE may only be modified in +-writing signed by an authorized officer of NVIDIA. +- +diff --git a/LICENSE.amdgpu b/LICENSE.amdgpu +deleted file mode 100644 +index 349e207..0000000 +--- a/LICENSE.amdgpu ++++ /dev/null +@@ -1,51 +0,0 @@ +-Copyright (C) 2023 Advanced Micro Devices, Inc. All rights reserved. +- +-REDISTRIBUTION: Permission is hereby granted, free of any license fees, +-to any person obtaining a copy of this microcode (the "Software"), to +-install, reproduce, copy and distribute copies, in binary form only, of +-the Software and to permit persons to whom the Software is provided to +-do the same, provided that the following conditions are met: +- +-No reverse engineering, decompilation, or disassembly of this Software +-is permitted. +- +-Redistributions must reproduce the above copyright notice, this +-permission notice, and the following disclaimers and notices in the +-Software documentation and/or other materials provided with the +-Software. +- +-DISCLAIMER: THE USE OF THE SOFTWARE IS AT YOUR SOLE RISK. THE SOFTWARE +-IS PROVIDED "AS IS" AND WITHOUT WARRANTY OF ANY KIND AND COPYRIGHT +-HOLDER AND ITS LICENSORS EXPRESSLY DISCLAIM ALL WARRANTIES, EXPRESS AND +-IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +-MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT. +-COPYRIGHT HOLDER AND ITS LICENSORS DO NOT WARRANT THAT THE SOFTWARE WILL +-MEET YOUR REQUIREMENTS, OR THAT THE OPERATION OF THE SOFTWARE WILL BE +-UNINTERRUPTED OR ERROR-FREE. THE ENTIRE RISK ASSOCIATED WITH THE USE OF +-THE SOFTWARE IS ASSUMED BY YOU. FURTHERMORE, COPYRIGHT HOLDER AND ITS +-LICENSORS DO NOT WARRANT OR MAKE ANY REPRESENTATIONS REGARDING THE USE +-OR THE RESULTS OF THE USE OF THE SOFTWARE IN TERMS OF ITS CORRECTNESS, +-ACCURACY, RELIABILITY, CURRENTNESS, OR OTHERWISE. +- +-DISCLAIMER: UNDER NO CIRCUMSTANCES INCLUDING NEGLIGENCE, SHALL COPYRIGHT +-HOLDER AND ITS LICENSORS OR ITS DIRECTORS, OFFICERS, EMPLOYEES OR AGENTS +-("AUTHORIZED REPRESENTATIVES") BE LIABLE FOR ANY INCIDENTAL, INDIRECT, +-SPECIAL OR CONSEQUENTIAL DAMAGES (INCLUDING DAMAGES FOR LOSS OF BUSINESS +-PROFITS, BUSINESS INTERRUPTION, LOSS OF BUSINESS INFORMATION, AND THE +-LIKE) ARISING OUT OF THE USE, MISUSE OR INABILITY TO USE THE SOFTWARE, +-BREACH OR DEFAULT, INCLUDING THOSE ARISING FROM INFRINGEMENT OR ALLEGED +-INFRINGEMENT OF ANY PATENT, TRADEMARK, COPYRIGHT OR OTHER INTELLECTUAL +-PROPERTY RIGHT EVEN IF COPYRIGHT HOLDER AND ITS AUTHORIZED +-REPRESENTATIVES HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. IN +-NO EVENT SHALL COPYRIGHT HOLDER OR ITS AUTHORIZED REPRESENTATIVES TOTAL +-LIABILITY FOR ALL DAMAGES, LOSSES, AND CAUSES OF ACTION (WHETHER IN +-CONTRACT, TORT (INCLUDING NEGLIGENCE) OR OTHERWISE) EXCEED THE AMOUNT OF +-US$10. +- +-Notice: The Software is subject to United States export laws and +-regulations. You agree to comply with all domestic and international +-export laws and regulations that apply to the Software, including but +-not limited to the Export Administration Regulations administered by the +-U.S. Department of Commerce and International Traffic in Arm Regulations +-administered by the U.S. Department of State. These laws include +-restrictions on destinations, end users and end use. +diff --git a/LICENSE.qcom b/LICENSE.qcom +deleted file mode 100644 +index faacf9c..0000000 +--- a/LICENSE.qcom ++++ /dev/null +@@ -1,206 +0,0 @@ +-PLEASE READ THIS LICENSE AGREEMENT ("AGREEMENT") CAREFULLY. THIS AGREEMENT IS +-A BINDING LEGAL AGREEMENT ENTERED INTO BY AND BETWEEN YOU (OR IF YOU ARE +-ENTERING INTO THIS AGREEMENT ON BEHALF OF AN ENTITY, THEN THE ENTITY THAT YOU +-REPRESENT) AND QUALCOMM TECHNOLOGIES, INC. ("QTI" "WE" "OUR" OR "US"). THIS IS +-THE AGREEMENT THAT APPLIES TO YOUR USE OF THE DESIGNATED AND/OR LINKED +-APPLICATIONS, THE ENCLOSED QUALCOMM TECHNOLOGIES' MATERIALS, INCLUDING RELATED +-DOCUMENTATION AND ANY UPDATES OR IMPROVEMENTS THEREOF +-(COLLECTIVELY, "MATERIALS"). BY USING OR COMPLETING THE INSTALLATION OF THE +-MATERIALS, YOU ARE ACCEPTING THIS AGREEMENT AND YOU AGREE TO BE BOUND BY ITS +-TERMS AND CONDITIONS. IF YOU DO NOT AGREE TO THESE TERMS, QTI IS UNWILLING TO +-AND DOES NOT LICENSE THE MATERIALS TO YOU. IF YOU DO NOT AGREE TO THESE TERMS +-YOU MUST DISCONTINUE THE INSTALLATION PROCESS AND YOU MAY NOT USE THE MATERIALS +-OR RETAIN ANY COPIES OF THE MATERIALS. ANY USE OR POSSESSION OF THE MATERIALS +-BY YOU IS SUBJECT TO THE TERMS AND CONDITIONS SET FORTH IN THIS AGREEMENT. +- +-1. RIGHT TO USE DELIVERABLES; RESTRICTIONS. +- +- 1.1 License. Subject to the terms and conditions of this Agreement, +- including, without limitation, the restrictions, conditions, limitations and +- exclusions set forth in this Agreement, QTI hereby grants to you a +- nonexclusive, limited license under QTI's copyrights to: (i) install and use +- the Materials; and (ii) to reproduce and redistribute the binary code portions +- of the Materials (the "Redistributable Binary Code"). You may make and use a +- reasonable number of copies of any documentation. +- +- 1.2 Redistribution Restrictions. Distribution of the Redistributable Binary +- Code is subject to the following restrictions: (i) Redistributable Binary Code +- may only be distributed in binary format and may not be distributed in source +- code format:; (ii) the Redistributable Binary Code may only operate in +- conjunction with platforms incorporating Qualcomm Technologies, Inc. chipsets; +- (iii) redistribution of the Redistributable Binary Code must include the .txt +- file setting forth the terms and condition of this Agreement; (iv) you may not +- use Qualcomm Technologies' or its affiliates or subsidiaries name, logo or +- trademarks; and (v) copyright, trademark, patent and any other notices that +- appear on the Materials may not be removed or obscured. +- +- 1.3 Additional Restrictions. Except as expressly permitted by this Agreement, +- you shall have no right to sublicense, transfer or otherwise disclose the +- Materials to any third party. You shall not reverse engineer, reverse +- assemble, reverse translate, decompile or reduce to source code form any +- portion of the Materials provided in object code form or executable form. +- Except for the purposes expressly permitted in this Agreement, You shall not +- use the Materials for any other purpose. QTI (or its licensors) shall retain +- title and all ownership rights in and to the Materials and any alterations, +- modifications (including all derivative works), translations or adaptations +- made of the Materials, and all copies thereof, and nothing herein shall be +- deemed to grant any right to You under any of QTI's or its affiliates' +- patents. You shall not subject the Materials to any third party license +- terms (e.g., open source license terms). You shall not use the Materials for +- the purpose of identifying or providing evidence to support any potential +- patent infringement claim against QTI, its affiliates, or any of QTI's or +- QTI's affiliates' suppliers and/or direct or indirect customers. QTI hereby +- reserves all rights not expressly granted herein. +- +- 1.4 Third Party Software and Materials. The Software may contain or link to +- certain software and/or materials that are written or owned by third parties. +- Such third party code and materials may be licensed under separate or +- different terms and conditions and are not licensed to you under the terms of +- this Agreement. You agree to comply with all terms and conditions imposed on +- you in the applicable third party licenses. Such terms and conditions may +- impose certain obligations on you as a condition to the permitted use of such +- third party code and materials. QTI does not represent or warrant that such +- third party licensors have or will continue to license or make available their +- code and materials to you. +- +- 1.5 Feedback. QTI may from time to time receive suggestions, feedback or +- other information from You regarding the Materials. Any suggestions, feedback +- or other disclosures received from You are and shall be entirely voluntary on +- the part of You. Notwithstanding any other term in this Agreement, QTI shall +- be free to use suggestions, feedback or other information received from You, +- without obligation of any kind to You. The Parties agree that all inventions, +- product improvements, and modifications conceived of or made by QTI that are +- based, either in whole or in part, on ideas, feedback, suggestions, or +- recommended improvements received from You are the exclusive property of QTI, +- and all right, title and interest in and to any such inventions, product +- improvements, and modifications will vest solely in QTI. +- +- 1.6 No Technical Support. QTI is under no obligation to provide any form of +- technical support for the Materials, and if QTI, in its sole discretion, +- chooses to provide any form of support or information relating to the +- Materials, such support and information shall be deemed confidential and +- proprietary to QTI. +- +-2. WARRANTY DISCLAIMER. YOU EXPRESSLY ACKNOWLEDGE AND AGREE THAT THE USE OF +-THE MATERIALS IS AT YOUR SOLE RISK. THE MATERIALS AND TECHNICAL SUPPORT, IF +-ANY, ARE PROVIDED "AS IS" AND WITHOUT WARRANTY OF ANY KIND, WHETHER EXPRESS OR +-IMPLIED. QTI ITS LICENSORS AND AFFILIATES MAKE NO WARRANTIES, EXPRESS OR +-IMPLIED, WITH RESPECT TO THE MATERIALS OR ANY OTHER INFORMATION OR DOCUMENTATION +-PROVIDED UNDER THIS AGREEMENT, INCLUDING BUT NOT LIMITED TO ANY WARRANTY OF +-MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE OR AGAINST INFRINGEMENT, OR +-ANY EXPRESS OR IMPLIED WARRANTY ARISING OUT OF TRADE USAGE OR OUT OF A COURSE OF +-DEALING OR COURSE OF PERFORMANCE. NOTHING CONTAINED IN THIS AGREEMENT SHALL BE +-CONSTRUED AS (I) A WARRANTY OR REPRESENTATION BY QTI, ITS LICENSORS OR +-AFFILIATES AS TO THE VALIDITY OR SCOPE OF ANY PATENT, COPYRIGHT OR OTHER +-INTELLECTUAL PROPERTY RIGHT OR (II) A WARRANTY OR REPRESENTATION BY QTI THAT ANY +-MANUFACTURE OR USE WILL BE FREE FROM INFRINGEMENT OF PATENTS, COPYRIGHTS OR +-OTHER INTELLECTUAL PROPERTY RIGHTS OF OTHERS, AND IT SHALL BE THE SOLE +-RESPONSIBILITY OF YOU TO MAKE SUCH DETERMINATION AS IS NECESSARY WITH RESPECT TO +-THE ACQUISITION OF LICENSES UNDER PATENTS AND OTHER INTELLECTUAL PROPERTY OF +-THIRD PARTIES. +- +-3. NO OTHER LICENSES OR INTELLECTUAL PROPERTY RIGHTS. Neither this Agreement, +-nor any act by QTI or any of its affiliates pursuant to this Agreement or +-relating to the Materials (including, without limitation, the provision by QTI +-or its affiliates of the Materials), shall provide to You any license or any +-other rights whatsoever under any patents, trademarks, trade secrets, copyrights +-or any other intellectual property of QTI or any of its affiliates, except for +-the copyright rights expressly licensed under this Agreement. You understand and +-agree that: +- +- (i) Neither this Agreement, nor delivery of the Materials, grants any right to +- practice, or any other right at all with respect to, any patent of QTI or any +- of its affiliates; and +- +- (ii) A separate license agreement from QUALCOMM Incorporated is needed to use +- or practice any patent of QUALCOMM Incorporated. You agree not to contend in +- any context that, as a result of the provision or use of the Materials, either +- QTI or any of its affiliates has any obligation to extend, or You or any other +- party has obtained any right to, any license, whether express or implied, with +- respect to any patent of QTI or any of its affiliates for any purpose. +- +-4. TERMINATION. This Agreement shall be effective upon acceptance, or access or +-use of the Materials (whichever occurs first) by You and shall continue until +-terminated. You may terminate the Agreement at any time by deleting and +-destroying all copies of the Materials and all related information in Your +-possession or control. This Agreement terminates immediately and automatically, +-with or without notice, if You fail to comply with any provision hereof. +-Additionally, QTI may at any time terminate this Agreement, without cause, upon +-notice to You. Upon termination You must, to the extent possible, delete or +-destroy all copies of the Materials in Your possession and the license granted +-to You in this Agreement shall terminate. Sections 1.2 through 10 shall survive +-the termination of this Agreement. In the event that any restrictions, +-conditions, limitations are found to be either invalid or unenforceable, the +-rights granted to You in Section 1 (License) shall be null, void and ineffective +-from the Effective Date, and QTI shall also have the right to terminate this +-Agreement immediately, and with retroactive effect to the effective date. +- +-5. LIMITATION OF LIABILITY. IN NO EVENT SHALL QTI, QTI's AFFILIATES OR ITS +-LICENSORS BE LIABLE TO YOU FOR ANY INCIDENTAL, CONSEQUENTIAL OR SPECIAL DAMAGES, +-INCLUDING BUT NOT LIMITED TO ANY LOST PROFITS, LOST SAVINGS, OR OTHER INCIDENTAL +-DAMAGES, ARISING OUT OF THE USE OR INABILITY TO USE, OR THE DELIVERY OR FAILURE +-TO DELIVER, ANY OF THE DELIVERABLES, OR ANY BREACH OF ANY OBLIGATION UNDER THIS +-AGREEMENT, EVEN IF QTI HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. +-THE FOREGOING LIMITATION OF LIABILITY SHALL REMAIN IN FULL FORCE AND EFFECT +-REGARDLESS OF WHETHER YOUR REMEDIES HEREUNDER ARE DETERMINED TO HAVE FAILED OF +-THEIR ESSENTIAL PURPOSE. THE ENTIRE LIABILITY OF QTI, QTI's AFFILIATES AND ITS +-LICENSORS, AND THE SOLE AND EXCLUSIVE REMEDY OF YOU, FOR ANY CLAIM OR CAUSE OF +-ACTION ARISING HEREUNDER (WHETHER IN CONTRACT, TORT, OR OTHERWISE) SHALL NOT +-EXCEED US$50. +- +-6. INDEMNIFICATION. You agree to indemnify and hold harmless QTI and its +-officers, directors, employees and successors and assigns against any and all +-third party claims, demands, causes of action, losses, liabilities, damages, +-costs and expenses, incurred by QTI (including but not limited to costs of +-defense, investigation and reasonable attorney's fees) arising out of, resulting +-from or related to: (i) any breach of this Agreement by You; and (ii) your acts, +-omissions, products and services. If requested by QTI, You agree to defend QTI +-in connection with any third party claims, demands, or causes of action +-resulting from, arising out of or in connection with any of the foregoing. +- +-7. ASSIGNMENT. You shall not assign this Agreement or any right or interest +-under this Agreement, nor delegate any obligation to be performed under this +-Agreement, without QTI's prior written consent. For purposes of this Section 7, +-an "assignment" by You under this Section shall be deemed to include, without +-limitation, any merger, consolidation, sale of all or substantially all of its +-assets, or any substantial change in the management or control of You. +-Any attempted assignment in contravention of this Section 9 shall be void. +-QTI may freely assign this Agreement or delegate any or all of its rights and +-obligations hereunder to any third party. +- +-8. COMPLIANCE WITH LAWS; APPLICABLE LAW. You agree to comply with all +-applicable local, international and national laws and regulations and with U.S. +-Export Administration Regulations, as they apply to the subject matter of this +-Agreement. This Agreement is governed by the laws of the State of California, +-excluding California's choice of law rules. +- +-9. CONTRACTING PARTIES. If the Materials are downloaded on any computer owned +-by a corporation or other legal entity, then this Agreement is formed by and +-between QTI and such entity. The individual accepting the terms of this +-Agreement represents and warrants to QTI that they have the authority to bind +-such entity to the terms and conditions of this Agreement. +- +-10. MISCELLANEOUS PROVISIONS. This Agreement, together with all exhibits +-attached hereto, which are incorporated herein by this reference, constitutes +-the entire agreement between QTI and You and supersedes all prior negotiations, +-representations and agreements between the parties with respect to the subject +-matter hereof. No addition or modification of this Agreement shall be effective +-unless made in writing and signed by the respective representatives of QTI and +-You. The restrictions, limitations, exclusions and conditions set forth in this +-Agreement shall apply even if QTI or any of its affiliates becomes aware of or +-fails to act in a manner to address any violation or failure to comply +-therewith. You hereby acknowledge and agree that the restrictions, limitations, +-conditions and exclusions imposed in this Agreement on the rights granted in +-this Agreement are not a derogation of the benefits of such rights. You further +-acknowledges that, in the absence of such restrictions, limitations, conditions +-and exclusions, QTI would not have entered into this Agreement with You. Each +-party shall be responsible for and shall bear its own expenses in connection +-with this Agreement. If any of the provisions of this Agreement are determined +-to be invalid, illegal, or otherwise unenforceable, the remaining provisions +-shall remain in full force and effect. This Agreement is entered into solely +-in the English language, and if for any reason any other language version is +-prepared by any party, it shall be solely for convenience and the English +-version shall govern and control all aspects. If You are located in the +-province of Quebec, Canada, the following applies: The Parties hereby confirm +-they have requested this Agreement and all related documents be prepared +-in English. +diff --git a/LICENSE.qcom_yamato b/LICENSE.qcom_yamato +deleted file mode 100644 +index 1fd702b..0000000 +--- a/LICENSE.qcom_yamato ++++ /dev/null +@@ -1,25 +0,0 @@ +-Copyright (c) 2008-2011, QUALCOMM Incorporated. All rights reserved. +- +-Redistribution and use in source and binary forms, with or without +-modification, are permitted provided that the following conditions are met: +- * Redistributions of source code must retain the above copyright +- notice, this list of conditions and the following disclaimer. +- * Redistributions in binary form must reproduce the above copyright +- notice, this list of conditions and the following disclaimer in the +- documentation and/or other materials provided with the distribution. +- * Neither the name of QUALCOMM Incorporated nor +- the names of its contributors may be used to endorse or promote +- products derived from this software without specific prior written +- permission. +- +-THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +-AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +-IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +-ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE +-LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR +-CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF +-SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +-INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN +-CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) +-ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE +-POSSIBILITY OF SUCH DAMAGE. +diff --git a/LICENSE.radeon b/LICENSE.radeon +deleted file mode 100644 +index b05e714..0000000 +--- a/LICENSE.radeon ++++ /dev/null +@@ -1,51 +0,0 @@ +-Copyright (C) 2009-2017 Advanced Micro Devices, Inc. All rights reserved. +- +-REDISTRIBUTION: Permission is hereby granted, free of any license fees, +-to any person obtaining a copy of this microcode (the "Software"), to +-install, reproduce, copy and distribute copies, in binary form only, of +-the Software and to permit persons to whom the Software is provided to +-do the same, provided that the following conditions are met: +- +-No reverse engineering, decompilation, or disassembly of this Software +-is permitted. +- +-Redistributions must reproduce the above copyright notice, this +-permission notice, and the following disclaimers and notices in the +-Software documentation and/or other materials provided with the +-Software. +- +-DISCLAIMER: THE USE OF THE SOFTWARE IS AT YOUR SOLE RISK. THE SOFTWARE +-IS PROVIDED "AS IS" AND WITHOUT WARRANTY OF ANY KIND AND COPYRIGHT +-HOLDER AND ITS LICENSORS EXPRESSLY DISCLAIM ALL WARRANTIES, EXPRESS AND +-IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +-MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT. +-COPYRIGHT HOLDER AND ITS LICENSORS DO NOT WARRANT THAT THE SOFTWARE WILL +-MEET YOUR REQUIREMENTS, OR THAT THE OPERATION OF THE SOFTWARE WILL BE +-UNINTERRUPTED OR ERROR-FREE. THE ENTIRE RISK ASSOCIATED WITH THE USE OF +-THE SOFTWARE IS ASSUMED BY YOU. FURTHERMORE, COPYRIGHT HOLDER AND ITS +-LICENSORS DO NOT WARRANT OR MAKE ANY REPRESENTATIONS REGARDING THE USE +-OR THE RESULTS OF THE USE OF THE SOFTWARE IN TERMS OF ITS CORRECTNESS, +-ACCURACY, RELIABILITY, CURRENTNESS, OR OTHERWISE. +- +-DISCLAIMER: UNDER NO CIRCUMSTANCES INCLUDING NEGLIGENCE, SHALL COPYRIGHT +-HOLDER AND ITS LICENSORS OR ITS DIRECTORS, OFFICERS, EMPLOYEES OR AGENTS +-("AUTHORIZED REPRESENTATIVES") BE LIABLE FOR ANY INCIDENTAL, INDIRECT, +-SPECIAL OR CONSEQUENTIAL DAMAGES (INCLUDING DAMAGES FOR LOSS OF BUSINESS +-PROFITS, BUSINESS INTERRUPTION, LOSS OF BUSINESS INFORMATION, AND THE +-LIKE) ARISING OUT OF THE USE, MISUSE OR INABILITY TO USE THE SOFTWARE, +-BREACH OR DEFAULT, INCLUDING THOSE ARISING FROM INFRINGEMENT OR ALLEGED +-INFRINGEMENT OF ANY PATENT, TRADEMARK, COPYRIGHT OR OTHER INTELLECTUAL +-PROPERTY RIGHT EVEN IF COPYRIGHT HOLDER AND ITS AUTHORIZED +-REPRESENTATIVES HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. IN +-NO EVENT SHALL COPYRIGHT HOLDER OR ITS AUTHORIZED REPRESENTATIVES TOTAL +-LIABILITY FOR ALL DAMAGES, LOSSES, AND CAUSES OF ACTION (WHETHER IN +-CONTRACT, TORT (INCLUDING NEGLIGENCE) OR OTHERWISE) EXCEED THE AMOUNT OF +-US$10. +- +-Notice: The Software is subject to United States export laws and +-regulations. You agree to comply with all domestic and international +-export laws and regulations that apply to the Software, including but +-not limited to the Export Administration Regulations administered by the +-U.S. Department of Commerce and International Traffic in Arm Regulations +-administered by the U.S. Department of State. These laws include +-restrictions on destinations, end users and end use. +diff --git a/WHENCE b/WHENCE +index 58e9ca1..3bb6523 100644 +--- a/WHENCE ++++ b/WHENCE +@@ -123,904 +123,6 @@ Available from http://ldriver.qlogic.com/firmware/netxen_nic/new/ + + -------------------------------------------------------------------------- + +-Driver: mga - Matrox G200/G400/G550 +- +-File: matrox/g200_warp.fw +-File: matrox/g400_warp.fw +- +-Licence: +- +-Copyright 1999 Matrox Graphics Inc. +-All Rights Reserved. +- +-Permission is hereby granted, free of charge, to any person obtaining a +-copy of this software and associated documentation files (the "Software"), +-to deal in the Software without restriction, including without limitation +-the rights to use, copy, modify, merge, publish, distribute, sublicense, +-and/or sell copies of the Software, and to permit persons to whom the +-Software is furnished to do so, subject to the following conditions: +- +-The above copyright notice and this permission notice shall be included +-in all copies or substantial portions of the Software. +- +-THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +-OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +-FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL +-MATROX GRAPHICS INC., OR ANY OTHER CONTRIBUTORS BE LIABLE FOR ANY CLAIM, +-DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR +-OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE +-OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. +- +-Found in hex form in kernel source. +- +--------------------------------------------------------------------------- +- +-Driver: r128 - ATI Rage 128 +- +-File: r128/r128_cce.bin +- +-Licence: +- +-Copyright 2000 Advanced Micro Devices, Inc. +- +- * Permission is hereby granted, free of charge, to any person obtaining a +- * copy of this software and associated documentation files (the "Software"), +- * to deal in the Software without restriction, including without limitation +- * the rights to use, copy, modify, merge, publish, distribute, sublicense, +- * and/or sell copies of the Software, and to permit persons to whom the +- * Software is furnished to do so, subject to the following conditions: +- * +- * The above copyright notice and this permission notice (including the next +- * paragraph) shall be included in all copies or substantial portions of the +- * Software. +- * +- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +- * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +- * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL +- * PRECISION INSIGHT AND/OR ITS SUPPLIERS BE LIABLE FOR ANY CLAIM, DAMAGES OR +- * OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, +- * ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER +- * DEALINGS IN THE SOFTWARE. +- +-Found in decimal form in kernel source. +- +--------------------------------------------------------------------------- +- +-Driver: radeon - ATI Radeon +- +-File: radeon/R100_cp.bin +-File: radeon/R200_cp.bin +-File: radeon/R300_cp.bin +-File: radeon/R420_cp.bin +-File: radeon/RS600_cp.bin +-File: radeon/RS690_cp.bin +-File: radeon/R520_cp.bin +-File: radeon/R600_pfp.bin +-File: radeon/R600_me.bin +-File: radeon/RV610_pfp.bin +-File: radeon/RV610_me.bin +-File: radeon/RV630_pfp.bin +-File: radeon/RV630_me.bin +-File: radeon/RV620_pfp.bin +-File: radeon/RV620_me.bin +-File: radeon/RV635_pfp.bin +-File: radeon/RV635_me.bin +-File: radeon/RV670_pfp.bin +-File: radeon/RV670_me.bin +-File: radeon/RS780_pfp.bin +-File: radeon/RS780_me.bin +-File: radeon/RV770_pfp.bin +-File: radeon/RV770_me.bin +-File: radeon/RV730_pfp.bin +-File: radeon/RV730_me.bin +-File: radeon/RV710_pfp.bin +-File: radeon/RV710_me.bin +- +-Licence: +- +- * Copyright 2007-2009 Advanced Micro Devices, Inc. +- * All Rights Reserved. +- * +- * Permission is hereby granted, free of charge, to any person obtaining a +- * copy of this software and associated documentation files (the "Software"), +- * to deal in the Software without restriction, including without limitation +- * the rights to use, copy, modify, merge, publish, distribute, sublicense, +- * and/or sell copies of the Software, and to permit persons to whom the +- * Software is furnished to do so, subject to the following conditions: +- * +- * The above copyright notice and this permission notice (including the next +- * paragraph) shall be included in all copies or substantial portions of the +- * Software. +- * +- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +- * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +- * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL +- * IN NO EVENT SHALL THE COPYRIGHT OWNER(S) AND/OR ITS SUPPLIERS BE +- * LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION +- * OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION +- * WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. +- +-Found in hex form in kernel source. +- +--------------------------------------------------------------------------- +- +-Driver: radeon - ATI Radeon +- +-File: radeon/R600_rlc.bin +-File: radeon/R600_uvd.bin +-File: radeon/RS780_uvd.bin +-File: radeon/R700_rlc.bin +-File: radeon/RV710_uvd.bin +-File: radeon/RV710_smc.bin +-File: radeon/RV730_smc.bin +-File: radeon/RV740_smc.bin +-File: radeon/RV770_smc.bin +-File: radeon/RV770_uvd.bin +-File: radeon/CEDAR_me.bin +-File: radeon/CEDAR_pfp.bin +-File: radeon/CEDAR_rlc.bin +-File: radeon/CEDAR_smc.bin +-File: radeon/CYPRESS_me.bin +-File: radeon/CYPRESS_pfp.bin +-File: radeon/CYPRESS_rlc.bin +-File: radeon/CYPRESS_uvd.bin +-File: radeon/CYPRESS_smc.bin +-File: radeon/JUNIPER_me.bin +-File: radeon/JUNIPER_pfp.bin +-File: radeon/JUNIPER_rlc.bin +-File: radeon/JUNIPER_smc.bin +-File: radeon/REDWOOD_me.bin +-File: radeon/REDWOOD_pfp.bin +-File: radeon/REDWOOD_rlc.bin +-File: radeon/REDWOOD_smc.bin +-File: radeon/PALM_me.bin +-File: radeon/PALM_pfp.bin +-File: radeon/SUMO_rlc.bin +-File: radeon/SUMO_uvd.bin +-File: radeon/BARTS_mc.bin +-File: radeon/BARTS_me.bin +-File: radeon/BARTS_pfp.bin +-File: radeon/BARTS_smc.bin +-File: radeon/BTC_rlc.bin +-File: radeon/CAICOS_mc.bin +-File: radeon/CAICOS_me.bin +-File: radeon/CAICOS_pfp.bin +-File: radeon/CAICOS_smc.bin +-File: radeon/TURKS_mc.bin +-File: radeon/TURKS_me.bin +-File: radeon/TURKS_pfp.bin +-File: radeon/TURKS_smc.bin +-File: radeon/CAYMAN_mc.bin +-File: radeon/CAYMAN_me.bin +-File: radeon/CAYMAN_pfp.bin +-File: radeon/CAYMAN_rlc.bin +-File: radeon/CAYMAN_smc.bin +-File: radeon/SUMO_pfp.bin +-File: radeon/SUMO_me.bin +-File: radeon/SUMO2_pfp.bin +-File: radeon/SUMO2_me.bin +-File: radeon/ARUBA_me.bin +-File: radeon/ARUBA_pfp.bin +-File: radeon/ARUBA_rlc.bin +-File: radeon/PITCAIRN_ce.bin +-File: radeon/PITCAIRN_mc.bin +-File: radeon/PITCAIRN_mc2.bin +-File: radeon/PITCAIRN_me.bin +-File: radeon/PITCAIRN_pfp.bin +-File: radeon/PITCAIRN_rlc.bin +-File: radeon/PITCAIRN_smc.bin +-File: radeon/TAHITI_ce.bin +-File: radeon/TAHITI_mc.bin +-File: radeon/TAHITI_mc2.bin +-File: radeon/TAHITI_me.bin +-File: radeon/TAHITI_pfp.bin +-File: radeon/TAHITI_rlc.bin +-File: radeon/TAHITI_uvd.bin +-File: radeon/TAHITI_smc.bin +-File: radeon/TAHITI_vce.bin +-File: radeon/VERDE_ce.bin +-File: radeon/VERDE_mc.bin +-File: radeon/VERDE_mc2.bin +-File: radeon/VERDE_me.bin +-File: radeon/VERDE_pfp.bin +-File: radeon/VERDE_rlc.bin +-File: radeon/VERDE_smc.bin +-File: radeon/OLAND_ce.bin +-File: radeon/OLAND_mc.bin +-File: radeon/OLAND_mc2.bin +-File: radeon/OLAND_me.bin +-File: radeon/OLAND_pfp.bin +-File: radeon/OLAND_rlc.bin +-File: radeon/OLAND_smc.bin +-File: radeon/HAINAN_ce.bin +-File: radeon/HAINAN_mc.bin +-File: radeon/HAINAN_mc2.bin +-File: radeon/HAINAN_me.bin +-File: radeon/HAINAN_pfp.bin +-File: radeon/HAINAN_rlc.bin +-File: radeon/HAINAN_smc.bin +-File: radeon/BONAIRE_ce.bin +-File: radeon/BONAIRE_mc.bin +-File: radeon/BONAIRE_mc2.bin +-File: radeon/BONAIRE_me.bin +-File: radeon/BONAIRE_mec.bin +-File: radeon/BONAIRE_pfp.bin +-File: radeon/BONAIRE_rlc.bin +-File: radeon/BONAIRE_sdma.bin +-File: radeon/BONAIRE_uvd.bin +-File: radeon/BONAIRE_smc.bin +-File: radeon/BONAIRE_vce.bin +-File: radeon/KABINI_ce.bin +-File: radeon/KABINI_me.bin +-File: radeon/KABINI_mec.bin +-File: radeon/KABINI_pfp.bin +-File: radeon/KABINI_rlc.bin +-File: radeon/KABINI_sdma.bin +-File: radeon/KAVERI_ce.bin +-File: radeon/KAVERI_me.bin +-File: radeon/KAVERI_mec.bin +-File: radeon/KAVERI_pfp.bin +-File: radeon/KAVERI_rlc.bin +-File: radeon/KAVERI_sdma.bin +-File: radeon/HAWAII_ce.bin +-File: radeon/HAWAII_mc.bin +-File: radeon/HAWAII_mc2.bin +-File: radeon/HAWAII_me.bin +-File: radeon/HAWAII_mec.bin +-File: radeon/HAWAII_pfp.bin +-File: radeon/HAWAII_rlc.bin +-File: radeon/HAWAII_sdma.bin +-File: radeon/HAWAII_smc.bin +-File: radeon/MULLINS_ce.bin +-File: radeon/MULLINS_me.bin +-File: radeon/MULLINS_mec.bin +-File: radeon/MULLINS_pfp.bin +-File: radeon/MULLINS_rlc.bin +-File: radeon/MULLINS_sdma.bin +-File: radeon/pitcairn_ce.bin +-File: radeon/pitcairn_k_smc.bin +-File: radeon/pitcairn_mc.bin +-File: radeon/pitcairn_me.bin +-File: radeon/pitcairn_pfp.bin +-File: radeon/pitcairn_rlc.bin +-File: radeon/pitcairn_smc.bin +-File: radeon/tahiti_ce.bin +-File: radeon/tahiti_k_smc.bin +-File: radeon/tahiti_mc.bin +-File: radeon/tahiti_me.bin +-File: radeon/tahiti_pfp.bin +-File: radeon/tahiti_rlc.bin +-File: radeon/tahiti_smc.bin +-File: radeon/verde_ce.bin +-File: radeon/verde_k_smc.bin +-File: radeon/verde_mc.bin +-File: radeon/verde_me.bin +-File: radeon/verde_pfp.bin +-File: radeon/verde_rlc.bin +-File: radeon/verde_smc.bin +-File: radeon/oland_ce.bin +-File: radeon/oland_k_smc.bin +-File: radeon/oland_mc.bin +-File: radeon/oland_me.bin +-File: radeon/oland_pfp.bin +-File: radeon/oland_rlc.bin +-File: radeon/oland_smc.bin +-File: radeon/hainan_ce.bin +-File: radeon/hainan_k_smc.bin +-File: radeon/hainan_mc.bin +-File: radeon/hainan_me.bin +-File: radeon/hainan_pfp.bin +-File: radeon/hainan_rlc.bin +-File: radeon/hainan_smc.bin +-File: radeon/bonaire_ce.bin +-File: radeon/bonaire_k_smc.bin +-File: radeon/bonaire_mc.bin +-File: radeon/bonaire_me.bin +-File: radeon/bonaire_mec.bin +-File: radeon/bonaire_pfp.bin +-File: radeon/bonaire_rlc.bin +-File: radeon/bonaire_sdma.bin +-File: radeon/bonaire_sdma1.bin +-File: radeon/bonaire_smc.bin +-File: radeon/bonaire_uvd.bin +-File: radeon/bonaire_vce.bin +-File: radeon/kabini_ce.bin +-File: radeon/kabini_me.bin +-File: radeon/kabini_mec.bin +-File: radeon/kabini_pfp.bin +-File: radeon/kabini_rlc.bin +-File: radeon/kabini_sdma.bin +-File: radeon/kabini_sdma1.bin +-File: radeon/kabini_uvd.bin +-File: radeon/kabini_vce.bin +-File: radeon/kaveri_ce.bin +-File: radeon/kaveri_me.bin +-File: radeon/kaveri_mec.bin +-File: radeon/kaveri_mec2.bin +-File: radeon/kaveri_pfp.bin +-File: radeon/kaveri_rlc.bin +-File: radeon/kaveri_sdma.bin +-File: radeon/kaveri_sdma1.bin +-File: radeon/kaveri_uvd.bin +-File: radeon/kaveri_vce.bin +-File: radeon/hawaii_ce.bin +-File: radeon/hawaii_k_smc.bin +-File: radeon/hawaii_mc.bin +-File: radeon/hawaii_me.bin +-File: radeon/hawaii_mec.bin +-File: radeon/hawaii_pfp.bin +-File: radeon/hawaii_rlc.bin +-File: radeon/hawaii_sdma.bin +-File: radeon/hawaii_sdma1.bin +-File: radeon/hawaii_smc.bin +-File: radeon/hawaii_uvd.bin +-File: radeon/hawaii_vce.bin +-File: radeon/mullins_ce.bin +-File: radeon/mullins_me.bin +-File: radeon/mullins_mec.bin +-File: radeon/mullins_pfp.bin +-File: radeon/mullins_rlc.bin +-File: radeon/mullins_sdma.bin +-File: radeon/mullins_sdma1.bin +-File: radeon/mullins_uvd.bin +-File: radeon/mullins_vce.bin +-File: radeon/banks_k_2_smc.bin +-File: radeon/si58_mc.bin +- +-Licence: Redistributable. See LICENSE.radeon for details. +- +--------------------------------------------------------------------------- +- +-Driver: amdgpu - AMD Radeon +- +-File: amdgpu/tahiti_ce.bin +-File: amdgpu/tahiti_k_smc.bin +-File: amdgpu/tahiti_mc.bin +-File: amdgpu/tahiti_me.bin +-File: amdgpu/tahiti_pfp.bin +-File: amdgpu/tahiti_rlc.bin +-File: amdgpu/tahiti_smc.bin +-File: amdgpu/tahiti_uvd.bin +-File: amdgpu/pitcairn_ce.bin +-File: amdgpu/pitcairn_k_smc.bin +-File: amdgpu/pitcairn_mc.bin +-File: amdgpu/pitcairn_me.bin +-File: amdgpu/pitcairn_pfp.bin +-File: amdgpu/pitcairn_rlc.bin +-File: amdgpu/pitcairn_smc.bin +-File: amdgpu/pitcairn_uvd.bin +-File: amdgpu/verde_ce.bin +-File: amdgpu/verde_k_smc.bin +-File: amdgpu/verde_mc.bin +-File: amdgpu/verde_me.bin +-File: amdgpu/verde_pfp.bin +-File: amdgpu/verde_rlc.bin +-File: amdgpu/verde_smc.bin +-File: amdgpu/verde_uvd.bin +-File: amdgpu/hainan_ce.bin +-File: amdgpu/hainan_k_smc.bin +-File: amdgpu/hainan_mc.bin +-File: amdgpu/hainan_me.bin +-File: amdgpu/hainan_pfp.bin +-File: amdgpu/hainan_rlc.bin +-File: amdgpu/hainan_smc.bin +-File: amdgpu/oland_ce.bin +-File: amdgpu/oland_k_smc.bin +-File: amdgpu/oland_mc.bin +-File: amdgpu/oland_me.bin +-File: amdgpu/oland_pfp.bin +-File: amdgpu/oland_rlc.bin +-File: amdgpu/oland_smc.bin +-File: amdgpu/oland_uvd.bin +-File: amdgpu/si58_mc.bin +-File: amdgpu/banks_k_2_smc.bin +-File: amdgpu/bonaire_ce.bin +-File: amdgpu/bonaire_k_smc.bin +-File: amdgpu/bonaire_mc.bin +-File: amdgpu/bonaire_me.bin +-File: amdgpu/bonaire_mec.bin +-File: amdgpu/bonaire_pfp.bin +-File: amdgpu/bonaire_rlc.bin +-File: amdgpu/bonaire_sdma.bin +-File: amdgpu/bonaire_sdma1.bin +-File: amdgpu/bonaire_smc.bin +-File: amdgpu/bonaire_uvd.bin +-File: amdgpu/bonaire_vce.bin +-File: amdgpu/hawaii_ce.bin +-File: amdgpu/hawaii_k_smc.bin +-File: amdgpu/hawaii_mc.bin +-File: amdgpu/hawaii_me.bin +-File: amdgpu/hawaii_mec.bin +-File: amdgpu/hawaii_pfp.bin +-File: amdgpu/hawaii_rlc.bin +-File: amdgpu/hawaii_sdma.bin +-File: amdgpu/hawaii_sdma1.bin +-File: amdgpu/hawaii_smc.bin +-File: amdgpu/hawaii_uvd.bin +-File: amdgpu/hawaii_vce.bin +-File: amdgpu/kabini_ce.bin +-File: amdgpu/kabini_me.bin +-File: amdgpu/kabini_mec.bin +-File: amdgpu/kabini_pfp.bin +-File: amdgpu/kabini_rlc.bin +-File: amdgpu/kabini_sdma.bin +-File: amdgpu/kabini_sdma1.bin +-File: amdgpu/kabini_uvd.bin +-File: amdgpu/kabini_vce.bin +-File: amdgpu/mullins_ce.bin +-File: amdgpu/mullins_me.bin +-File: amdgpu/mullins_mec.bin +-File: amdgpu/mullins_pfp.bin +-File: amdgpu/mullins_rlc.bin +-File: amdgpu/mullins_sdma.bin +-File: amdgpu/mullins_sdma1.bin +-File: amdgpu/mullins_uvd.bin +-File: amdgpu/mullins_vce.bin +-File: amdgpu/kaveri_ce.bin +-File: amdgpu/kaveri_me.bin +-File: amdgpu/kaveri_mec.bin +-File: amdgpu/kaveri_mec2.bin +-File: amdgpu/kaveri_pfp.bin +-File: amdgpu/kaveri_rlc.bin +-File: amdgpu/kaveri_sdma.bin +-File: amdgpu/kaveri_sdma1.bin +-File: amdgpu/kaveri_uvd.bin +-File: amdgpu/kaveri_vce.bin +-File: amdgpu/topaz_ce.bin +-File: amdgpu/topaz_k_smc.bin +-File: amdgpu/topaz_mc.bin +-File: amdgpu/topaz_me.bin +-File: amdgpu/topaz_mec2.bin +-File: amdgpu/topaz_mec.bin +-File: amdgpu/topaz_pfp.bin +-File: amdgpu/topaz_rlc.bin +-File: amdgpu/topaz_sdma1.bin +-File: amdgpu/topaz_sdma.bin +-File: amdgpu/topaz_smc.bin +-File: amdgpu/tonga_ce.bin +-File: amdgpu/tonga_k_smc.bin +-File: amdgpu/tonga_mc.bin +-File: amdgpu/tonga_me.bin +-File: amdgpu/tonga_mec2.bin +-File: amdgpu/tonga_mec.bin +-File: amdgpu/tonga_pfp.bin +-File: amdgpu/tonga_rlc.bin +-File: amdgpu/tonga_sdma1.bin +-File: amdgpu/tonga_sdma.bin +-File: amdgpu/tonga_smc.bin +-File: amdgpu/tonga_uvd.bin +-File: amdgpu/tonga_vce.bin +-File: amdgpu/carrizo_ce.bin +-File: amdgpu/carrizo_me.bin +-File: amdgpu/carrizo_mec2.bin +-File: amdgpu/carrizo_mec.bin +-File: amdgpu/carrizo_pfp.bin +-File: amdgpu/carrizo_rlc.bin +-File: amdgpu/carrizo_sdma1.bin +-File: amdgpu/carrizo_sdma.bin +-File: amdgpu/carrizo_uvd.bin +-File: amdgpu/carrizo_vce.bin +-File: amdgpu/fiji_ce.bin +-File: amdgpu/fiji_mc.bin +-File: amdgpu/fiji_me.bin +-File: amdgpu/fiji_mec2.bin +-File: amdgpu/fiji_mec.bin +-File: amdgpu/fiji_pfp.bin +-File: amdgpu/fiji_rlc.bin +-File: amdgpu/fiji_sdma1.bin +-File: amdgpu/fiji_sdma.bin +-File: amdgpu/fiji_smc.bin +-File: amdgpu/fiji_uvd.bin +-File: amdgpu/fiji_vce.bin +-File: amdgpu/stoney_ce.bin +-File: amdgpu/stoney_me.bin +-File: amdgpu/stoney_mec.bin +-File: amdgpu/stoney_pfp.bin +-File: amdgpu/stoney_rlc.bin +-File: amdgpu/stoney_sdma.bin +-File: amdgpu/stoney_uvd.bin +-File: amdgpu/stoney_vce.bin +-File: amdgpu/polaris10_ce.bin +-File: amdgpu/polaris10_ce_2.bin +-File: amdgpu/polaris10_mc.bin +-File: amdgpu/polaris10_k_mc.bin +-File: amdgpu/polaris10_me.bin +-File: amdgpu/polaris10_me_2.bin +-File: amdgpu/polaris10_mec2.bin +-File: amdgpu/polaris10_mec2_2.bin +-File: amdgpu/polaris10_mec.bin +-File: amdgpu/polaris10_mec_2.bin +-File: amdgpu/polaris10_pfp.bin +-File: amdgpu/polaris10_pfp_2.bin +-File: amdgpu/polaris10_rlc.bin +-File: amdgpu/polaris10_sdma1.bin +-File: amdgpu/polaris10_sdma.bin +-File: amdgpu/polaris10_smc.bin +-File: amdgpu/polaris10_k_smc.bin +-File: amdgpu/polaris10_k2_smc.bin +-File: amdgpu/polaris10_smc_sk.bin +-File: amdgpu/polaris10_uvd.bin +-File: amdgpu/polaris10_vce.bin +-File: amdgpu/polaris11_ce.bin +-File: amdgpu/polaris11_ce_2.bin +-File: amdgpu/polaris11_mc.bin +-File: amdgpu/polaris11_k_mc.bin +-File: amdgpu/polaris11_me.bin +-File: amdgpu/polaris11_me_2.bin +-File: amdgpu/polaris11_mec2.bin +-File: amdgpu/polaris11_mec2_2.bin +-File: amdgpu/polaris11_mec.bin +-File: amdgpu/polaris11_mec_2.bin +-File: amdgpu/polaris11_pfp.bin +-File: amdgpu/polaris11_pfp_2.bin +-File: amdgpu/polaris11_rlc.bin +-File: amdgpu/polaris11_sdma1.bin +-File: amdgpu/polaris11_sdma.bin +-File: amdgpu/polaris11_smc.bin +-File: amdgpu/polaris11_k_smc.bin +-File: amdgpu/polaris11_k2_smc.bin +-File: amdgpu/polaris11_smc_sk.bin +-File: amdgpu/polaris11_uvd.bin +-File: amdgpu/polaris11_vce.bin +-File: amdgpu/polaris12_ce.bin +-File: amdgpu/polaris12_ce_2.bin +-File: amdgpu/polaris12_mc.bin +-File: amdgpu/polaris12_k_mc.bin +-File: amdgpu/polaris12_32_mc.bin +-File: amdgpu/polaris12_me.bin +-File: amdgpu/polaris12_me_2.bin +-File: amdgpu/polaris12_mec.bin +-File: amdgpu/polaris12_mec_2.bin +-File: amdgpu/polaris12_mec2.bin +-File: amdgpu/polaris12_mec2_2.bin +-File: amdgpu/polaris12_pfp.bin +-File: amdgpu/polaris12_pfp_2.bin +-File: amdgpu/polaris12_rlc.bin +-File: amdgpu/polaris12_sdma.bin +-File: amdgpu/polaris12_sdma1.bin +-File: amdgpu/polaris12_smc.bin +-File: amdgpu/polaris12_k_smc.bin +-File: amdgpu/polaris12_uvd.bin +-File: amdgpu/polaris12_vce.bin +-File: amdgpu/vegam_ce.bin +-File: amdgpu/vegam_me.bin +-File: amdgpu/vegam_mec.bin +-File: amdgpu/vegam_mec2.bin +-File: amdgpu/vegam_pfp.bin +-File: amdgpu/vegam_rlc.bin +-File: amdgpu/vegam_sdma.bin +-File: amdgpu/vegam_sdma1.bin +-File: amdgpu/vegam_smc.bin +-File: amdgpu/vegam_uvd.bin +-File: amdgpu/vegam_vce.bin +-File: amdgpu/vega10_acg_smc.bin +-File: amdgpu/vega10_asd.bin +-File: amdgpu/vega10_ce.bin +-File: amdgpu/vega10_gpu_info.bin +-File: amdgpu/vega10_me.bin +-File: amdgpu/vega10_mec.bin +-File: amdgpu/vega10_mec2.bin +-File: amdgpu/vega10_pfp.bin +-File: amdgpu/vega10_rlc.bin +-File: amdgpu/vega10_sdma.bin +-File: amdgpu/vega10_sdma1.bin +-File: amdgpu/vega10_smc.bin +-File: amdgpu/vega10_sos.bin +-File: amdgpu/vega10_uvd.bin +-File: amdgpu/vega10_vce.bin +-File: amdgpu/vega12_asd.bin +-File: amdgpu/vega12_ce.bin +-File: amdgpu/vega12_gpu_info.bin +-File: amdgpu/vega12_me.bin +-File: amdgpu/vega12_mec.bin +-File: amdgpu/vega12_mec2.bin +-File: amdgpu/vega12_pfp.bin +-File: amdgpu/vega12_rlc.bin +-File: amdgpu/vega12_sdma.bin +-File: amdgpu/vega12_sdma1.bin +-File: amdgpu/vega12_smc.bin +-File: amdgpu/vega12_sos.bin +-File: amdgpu/vega12_uvd.bin +-File: amdgpu/vega12_vce.bin +-File: amdgpu/vega20_asd.bin +-File: amdgpu/vega20_ce.bin +-File: amdgpu/vega20_me.bin +-File: amdgpu/vega20_mec.bin +-File: amdgpu/vega20_mec2.bin +-File: amdgpu/vega20_pfp.bin +-File: amdgpu/vega20_rlc.bin +-File: amdgpu/vega20_sdma.bin +-File: amdgpu/vega20_sdma1.bin +-File: amdgpu/vega20_smc.bin +-File: amdgpu/vega20_sos.bin +-File: amdgpu/vega20_uvd.bin +-File: amdgpu/vega20_vce.bin +-File: amdgpu/vega20_ta.bin +-File: amdgpu/raven_asd.bin +-File: amdgpu/raven_ce.bin +-File: amdgpu/raven_gpu_info.bin +-File: amdgpu/raven_me.bin +-File: amdgpu/raven_mec.bin +-File: amdgpu/raven_mec2.bin +-File: amdgpu/raven_pfp.bin +-File: amdgpu/raven_rlc.bin +-File: amdgpu/raven_sdma.bin +-File: amdgpu/raven_vcn.bin +-File: amdgpu/raven_dmcu.bin +-File: amdgpu/raven_kicker_rlc.bin +-File: amdgpu/raven_ta.bin +-File: amdgpu/picasso_asd.bin +-File: amdgpu/picasso_ce.bin +-File: amdgpu/picasso_gpu_info.bin +-File: amdgpu/picasso_me.bin +-File: amdgpu/picasso_mec.bin +-File: amdgpu/picasso_mec2.bin +-File: amdgpu/picasso_pfp.bin +-File: amdgpu/picasso_rlc.bin +-File: amdgpu/picasso_rlc_am4.bin +-File: amdgpu/picasso_sdma.bin +-File: amdgpu/picasso_vcn.bin +-File: amdgpu/picasso_ta.bin +-File: amdgpu/raven2_asd.bin +-File: amdgpu/raven2_ce.bin +-File: amdgpu/raven2_gpu_info.bin +-File: amdgpu/raven2_me.bin +-File: amdgpu/raven2_mec.bin +-File: amdgpu/raven2_mec2.bin +-File: amdgpu/raven2_pfp.bin +-File: amdgpu/raven2_rlc.bin +-File: amdgpu/raven2_sdma.bin +-File: amdgpu/raven2_vcn.bin +-File: amdgpu/raven2_ta.bin +-File: amdgpu/navi10_asd.bin +-File: amdgpu/navi10_ce.bin +-File: amdgpu/navi10_gpu_info.bin +-File: amdgpu/navi10_me.bin +-File: amdgpu/navi10_mec.bin +-File: amdgpu/navi10_mec2.bin +-File: amdgpu/navi10_pfp.bin +-File: amdgpu/navi10_rlc.bin +-File: amdgpu/navi10_sdma.bin +-File: amdgpu/navi10_sdma1.bin +-File: amdgpu/navi10_smc.bin +-File: amdgpu/navi10_sos.bin +-File: amdgpu/navi10_vcn.bin +-File: amdgpu/navi10_ta.bin +-File: amdgpu/navi14_asd.bin +-File: amdgpu/navi14_ce.bin +-File: amdgpu/navi14_ce_wks.bin +-File: amdgpu/navi14_gpu_info.bin +-File: amdgpu/navi14_me.bin +-File: amdgpu/navi14_me_wks.bin +-File: amdgpu/navi14_mec.bin +-File: amdgpu/navi14_mec_wks.bin +-File: amdgpu/navi14_mec2.bin +-File: amdgpu/navi14_mec2_wks.bin +-File: amdgpu/navi14_pfp.bin +-File: amdgpu/navi14_pfp_wks.bin +-File: amdgpu/navi14_rlc.bin +-File: amdgpu/navi14_sdma.bin +-File: amdgpu/navi14_sdma1.bin +-File: amdgpu/navi14_smc.bin +-File: amdgpu/navi14_sos.bin +-File: amdgpu/navi14_vcn.bin +-File: amdgpu/navi14_ta.bin +-File: amdgpu/navi12_asd.bin +-File: amdgpu/navi12_ce.bin +-File: amdgpu/navi12_dmcu.bin +-File: amdgpu/navi12_gpu_info.bin +-File: amdgpu/navi12_me.bin +-File: amdgpu/navi12_mec.bin +-File: amdgpu/navi12_mec2.bin +-File: amdgpu/navi12_pfp.bin +-File: amdgpu/navi12_rlc.bin +-File: amdgpu/navi12_sdma.bin +-File: amdgpu/navi12_sdma1.bin +-File: amdgpu/navi12_smc.bin +-File: amdgpu/navi12_sos.bin +-File: amdgpu/navi12_vcn.bin +-File: amdgpu/navi12_ta.bin +-File: amdgpu/renoir_asd.bin +-File: amdgpu/renoir_ce.bin +-File: amdgpu/renoir_gpu_info.bin +-File: amdgpu/renoir_me.bin +-File: amdgpu/renoir_mec.bin +-File: amdgpu/renoir_mec2.bin +-File: amdgpu/renoir_pfp.bin +-File: amdgpu/renoir_rlc.bin +-File: amdgpu/renoir_sdma.bin +-File: amdgpu/renoir_vcn.bin +-File: amdgpu/renoir_dmcub.bin +-File: amdgpu/renoir_ta.bin +-File: amdgpu/sienna_cichlid_ce.bin +-File: amdgpu/sienna_cichlid_dmcub.bin +-File: amdgpu/sienna_cichlid_me.bin +-File: amdgpu/sienna_cichlid_mec.bin +-File: amdgpu/sienna_cichlid_mec2.bin +-File: amdgpu/sienna_cichlid_pfp.bin +-File: amdgpu/sienna_cichlid_rlc.bin +-File: amdgpu/sienna_cichlid_sdma.bin +-File: amdgpu/sienna_cichlid_smc.bin +-File: amdgpu/sienna_cichlid_sos.bin +-File: amdgpu/sienna_cichlid_ta.bin +-File: amdgpu/sienna_cichlid_vcn.bin +-File: amdgpu/green_sardine_asd.bin +-File: amdgpu/green_sardine_ce.bin +-File: amdgpu/green_sardine_dmcub.bin +-File: amdgpu/green_sardine_me.bin +-File: amdgpu/green_sardine_mec2.bin +-File: amdgpu/green_sardine_mec.bin +-File: amdgpu/green_sardine_pfp.bin +-File: amdgpu/green_sardine_rlc.bin +-File: amdgpu/green_sardine_sdma.bin +-File: amdgpu/green_sardine_ta.bin +-File: amdgpu/green_sardine_vcn.bin +-File: amdgpu/navy_flounder_ce.bin +-File: amdgpu/navy_flounder_dmcub.bin +-File: amdgpu/navy_flounder_me.bin +-File: amdgpu/navy_flounder_mec.bin +-File: amdgpu/navy_flounder_mec2.bin +-File: amdgpu/navy_flounder_pfp.bin +-File: amdgpu/navy_flounder_rlc.bin +-File: amdgpu/navy_flounder_sdma.bin +-File: amdgpu/navy_flounder_smc.bin +-File: amdgpu/navy_flounder_sos.bin +-File: amdgpu/navy_flounder_ta.bin +-File: amdgpu/navy_flounder_vcn.bin +-File: amdgpu/arcturus_asd.bin +-File: amdgpu/arcturus_gpu_info.bin +-File: amdgpu/arcturus_mec2.bin +-File: amdgpu/arcturus_mec.bin +-File: amdgpu/arcturus_rlc.bin +-File: amdgpu/arcturus_sdma.bin +-File: amdgpu/arcturus_smc.bin +-File: amdgpu/arcturus_sos.bin +-File: amdgpu/arcturus_ta.bin +-File: amdgpu/arcturus_vcn.bin +-File: amdgpu/dimgrey_cavefish_ce.bin +-File: amdgpu/dimgrey_cavefish_dmcub.bin +-File: amdgpu/dimgrey_cavefish_me.bin +-File: amdgpu/dimgrey_cavefish_mec.bin +-File: amdgpu/dimgrey_cavefish_mec2.bin +-File: amdgpu/dimgrey_cavefish_pfp.bin +-File: amdgpu/dimgrey_cavefish_rlc.bin +-File: amdgpu/dimgrey_cavefish_sdma.bin +-File: amdgpu/dimgrey_cavefish_smc.bin +-File: amdgpu/dimgrey_cavefish_sos.bin +-File: amdgpu/dimgrey_cavefish_ta.bin +-File: amdgpu/dimgrey_cavefish_vcn.bin +-File: amdgpu/vangogh_asd.bin +-File: amdgpu/vangogh_ce.bin +-File: amdgpu/vangogh_dmcub.bin +-File: amdgpu/vangogh_me.bin +-File: amdgpu/vangogh_mec2.bin +-File: amdgpu/vangogh_mec.bin +-File: amdgpu/vangogh_pfp.bin +-File: amdgpu/vangogh_rlc.bin +-File: amdgpu/vangogh_sdma.bin +-File: amdgpu/vangogh_toc.bin +-File: amdgpu/vangogh_vcn.bin +-File: amdgpu/yellow_carp_asd.bin +-File: amdgpu/yellow_carp_ce.bin +-File: amdgpu/yellow_carp_dmcub.bin +-File: amdgpu/yellow_carp_me.bin +-File: amdgpu/yellow_carp_mec.bin +-File: amdgpu/yellow_carp_mec2.bin +-File: amdgpu/yellow_carp_pfp.bin +-File: amdgpu/yellow_carp_rlc.bin +-File: amdgpu/yellow_carp_sdma.bin +-File: amdgpu/yellow_carp_ta.bin +-File: amdgpu/yellow_carp_toc.bin +-File: amdgpu/yellow_carp_vcn.bin +-File: amdgpu/beige_goby_ce.bin +-File: amdgpu/beige_goby_dmcub.bin +-File: amdgpu/beige_goby_me.bin +-File: amdgpu/beige_goby_mec.bin +-File: amdgpu/beige_goby_mec2.bin +-File: amdgpu/beige_goby_pfp.bin +-File: amdgpu/beige_goby_rlc.bin +-File: amdgpu/beige_goby_sdma.bin +-File: amdgpu/beige_goby_smc.bin +-File: amdgpu/beige_goby_sos.bin +-File: amdgpu/beige_goby_ta.bin +-File: amdgpu/beige_goby_vcn.bin +-File: amdgpu/cyan_skillfish2_ce.bin +-File: amdgpu/cyan_skillfish2_me.bin +-File: amdgpu/cyan_skillfish2_mec.bin +-File: amdgpu/cyan_skillfish2_mec2.bin +-File: amdgpu/cyan_skillfish2_pfp.bin +-File: amdgpu/cyan_skillfish2_rlc.bin +-File: amdgpu/cyan_skillfish2_sdma.bin +-File: amdgpu/cyan_skillfish2_sdma1.bin +-File: amdgpu/aldebaran_mec2.bin +-File: amdgpu/aldebaran_mec.bin +-File: amdgpu/aldebaran_rlc.bin +-File: amdgpu/aldebaran_sdma.bin +-File: amdgpu/aldebaran_sjt_mec2.bin +-File: amdgpu/aldebaran_sjt_mec.bin +-File: amdgpu/aldebaran_smc.bin +-File: amdgpu/aldebaran_sos.bin +-File: amdgpu/aldebaran_ta.bin +-File: amdgpu/aldebaran_vcn.bin +-File: amdgpu/gc_10_3_6_ce.bin +-File: amdgpu/gc_10_3_6_me.bin +-File: amdgpu/gc_10_3_6_mec.bin +-File: amdgpu/gc_10_3_6_mec2.bin +-File: amdgpu/gc_10_3_6_pfp.bin +-File: amdgpu/gc_10_3_6_rlc.bin +-File: amdgpu/gc_10_3_7_ce.bin +-File: amdgpu/gc_10_3_7_me.bin +-File: amdgpu/gc_10_3_7_mec.bin +-File: amdgpu/gc_10_3_7_mec2.bin +-File: amdgpu/gc_10_3_7_pfp.bin +-File: amdgpu/gc_10_3_7_rlc.bin +-File: amdgpu/gc_11_0_0_imu.bin +-File: amdgpu/gc_11_0_0_me.bin +-File: amdgpu/gc_11_0_0_mec.bin +-File: amdgpu/gc_11_0_0_mes1.bin +-File: amdgpu/gc_11_0_0_mes.bin +-File: amdgpu/gc_11_0_0_mes_2.bin +-File: amdgpu/gc_11_0_0_pfp.bin +-File: amdgpu/gc_11_0_0_rlc.bin +-File: amdgpu/gc_11_0_1_imu.bin +-File: amdgpu/gc_11_0_1_me.bin +-File: amdgpu/gc_11_0_1_mec.bin +-File: amdgpu/gc_11_0_1_mes.bin +-File: amdgpu/gc_11_0_1_mes1.bin +-File: amdgpu/gc_11_0_1_mes_2.bin +-File: amdgpu/gc_11_0_1_pfp.bin +-File: amdgpu/gc_11_0_1_rlc.bin +-File: amdgpu/gc_11_0_2_imu.bin +-File: amdgpu/gc_11_0_2_me.bin +-File: amdgpu/gc_11_0_2_mec.bin +-File: amdgpu/gc_11_0_2_mes1.bin +-File: amdgpu/gc_11_0_2_mes.bin +-File: amdgpu/gc_11_0_2_mes_2.bin +-File: amdgpu/gc_11_0_2_pfp.bin +-File: amdgpu/gc_11_0_2_rlc.bin +-File: amdgpu/gc_11_0_4_imu.bin +-File: amdgpu/gc_11_0_4_me.bin +-File: amdgpu/gc_11_0_4_mec.bin +-File: amdgpu/gc_11_0_4_mes.bin +-File: amdgpu/gc_11_0_4_mes1.bin +-File: amdgpu/gc_11_0_4_mes_2.bin +-File: amdgpu/gc_11_0_4_pfp.bin +-File: amdgpu/gc_11_0_4_rlc.bin +-File: amdgpu/dcn_3_1_4_dmcub.bin +-File: amdgpu/dcn_3_1_5_dmcub.bin +-File: amdgpu/dcn_3_1_6_dmcub.bin +-File: amdgpu/dcn_3_2_0_dmcub.bin +-File: amdgpu/dcn_3_2_1_dmcub.bin +-File: amdgpu/psp_13_0_0_sos.bin +-File: amdgpu/psp_13_0_0_ta.bin +-File: amdgpu/psp_13_0_4_ta.bin +-File: amdgpu/psp_13_0_4_toc.bin +-File: amdgpu/psp_13_0_5_asd.bin +-File: amdgpu/psp_13_0_5_ta.bin +-File: amdgpu/psp_13_0_5_toc.bin +-File: amdgpu/psp_13_0_7_sos.bin +-File: amdgpu/psp_13_0_7_ta.bin +-File: amdgpu/psp_13_0_8_asd.bin +-File: amdgpu/psp_13_0_8_ta.bin +-File: amdgpu/psp_13_0_8_toc.bin +-File: amdgpu/psp_13_0_11_ta.bin +-File: amdgpu/psp_13_0_11_toc.bin +-File: amdgpu/sdma_5_2_6.bin +-File: amdgpu/sdma_5_2_7.bin +-File: amdgpu/sdma_6_0_0.bin +-File: amdgpu/sdma_6_0_1.bin +-File: amdgpu/sdma_6_0_2.bin +-File: amdgpu/smu_13_0_0.bin +-File: amdgpu/smu_13_0_7.bin +-File: amdgpu/vcn_3_1_2.bin +-File: amdgpu/vcn_4_0_0.bin +-File: amdgpu/vcn_4_0_2.bin +-File: amdgpu/vcn_4_0_4.bin +- +-Licence: Redistributable. See LICENSE.amdgpu for details. +- +--------------------------------------------------------------------------- +- + Driver: qed - QLogic 4xxxx Ethernet Driver Core Module. + + File: qed/qed_init_values_zipped-8.4.2.0.bin +@@ -1459,424 +561,6 @@ Version: HuC API/APB ver 8.5.0 for Meteorlake + License: Redistributable. See LICENSE.i915 for details + -------------------------------------------------------------------------- + +-Driver: nouveau - NVIDIA GPU driver +- +-File: nvidia/gk20a/fecs_data.bin +-File: nvidia/gk20a/fecs_inst.bin +-File: nvidia/gk20a/gpccs_data.bin +-File: nvidia/gk20a/gpccs_inst.bin +-File: nvidia/gk20a/sw_bundle_init.bin +-File: nvidia/gk20a/sw_ctx.bin +-File: nvidia/gk20a/sw_method_init.bin +-File: nvidia/gk20a/sw_nonctx.bin +-File: nvidia/gm200/acr/bl.bin +-File: nvidia/gm200/acr/ucode_load.bin +-File: nvidia/gm200/acr/ucode_unload.bin +-File: nvidia/gm200/gr/fecs_bl.bin +-File: nvidia/gm200/gr/fecs_data.bin +-File: nvidia/gm200/gr/fecs_inst.bin +-File: nvidia/gm200/gr/fecs_sig.bin +-File: nvidia/gm200/gr/gpccs_bl.bin +-File: nvidia/gm200/gr/gpccs_data.bin +-File: nvidia/gm200/gr/gpccs_inst.bin +-File: nvidia/gm200/gr/gpccs_sig.bin +-File: nvidia/gm200/gr/sw_bundle_init.bin +-File: nvidia/gm200/gr/sw_ctx.bin +-File: nvidia/gm200/gr/sw_method_init.bin +-File: nvidia/gm200/gr/sw_nonctx.bin +-Link: nvidia/gm204/acr/bl.bin -> ../../gm200/acr/bl.bin +-Link: nvidia/gm204/acr/ucode_load.bin -> ../../gm200/acr/ucode_load.bin +-Link: nvidia/gm204/acr/ucode_unload.bin -> ../../gm200/acr/ucode_unload.bin +-Link: nvidia/gm204/gr/fecs_bl.bin -> ../../gm200/gr/fecs_bl.bin +-File: nvidia/gm204/gr/fecs_data.bin +-Link: nvidia/gm204/gr/fecs_inst.bin -> ../../gm200/gr/fecs_inst.bin +-File: nvidia/gm204/gr/fecs_sig.bin +-Link: nvidia/gm204/gr/gpccs_bl.bin -> ../../gm200/gr/gpccs_bl.bin +-File: nvidia/gm204/gr/gpccs_data.bin +-Link: nvidia/gm204/gr/gpccs_inst.bin -> ../../gm200/gr/gpccs_inst.bin +-File: nvidia/gm204/gr/gpccs_sig.bin +-Link: nvidia/gm204/gr/sw_bundle_init.bin -> ../../gm200/gr/sw_bundle_init.bin +-Link: nvidia/gm204/gr/sw_ctx.bin -> ../../gm200/gr/sw_ctx.bin +-Link: nvidia/gm204/gr/sw_method_init.bin -> ../../gm200/gr/sw_method_init.bin +-Link: nvidia/gm204/gr/sw_nonctx.bin -> ../../gm200/gr/sw_nonctx.bin +-Link: nvidia/gm206/acr/bl.bin -> ../../gm200/acr/bl.bin +-File: nvidia/gm206/acr/ucode_load.bin +-File: nvidia/gm206/acr/ucode_unload.bin +-Link: nvidia/gm206/gr/fecs_bl.bin -> ../../gm200/gr/fecs_bl.bin +-File: nvidia/gm206/gr/fecs_data.bin +-Link: nvidia/gm206/gr/fecs_inst.bin -> ../../gm200/gr/fecs_inst.bin +-File: nvidia/gm206/gr/fecs_sig.bin +-Link: nvidia/gm206/gr/gpccs_bl.bin -> ../../gm200/gr/gpccs_bl.bin +-File: nvidia/gm206/gr/gpccs_data.bin +-Link: nvidia/gm206/gr/gpccs_inst.bin -> ../../gm200/gr/gpccs_inst.bin +-File: nvidia/gm206/gr/gpccs_sig.bin +-Link: nvidia/gm206/gr/sw_bundle_init.bin -> ../../gm200/gr/sw_bundle_init.bin +-Link: nvidia/gm206/gr/sw_ctx.bin -> ../../gm200/gr/sw_ctx.bin +-Link: nvidia/gm206/gr/sw_method_init.bin -> ../../gm200/gr/sw_method_init.bin +-Link: nvidia/gm206/gr/sw_nonctx.bin -> ../../gm200/gr/sw_nonctx.bin +-File: nvidia/gm20b/acr/bl.bin +-File: nvidia/gm20b/acr/ucode_load.bin +-File: nvidia/gm20b/gr/fecs_bl.bin +-File: nvidia/gm20b/gr/fecs_data.bin +-File: nvidia/gm20b/gr/fecs_inst.bin +-File: nvidia/gm20b/gr/fecs_sig.bin +-File: nvidia/gm20b/gr/gpccs_data.bin +-File: nvidia/gm20b/gr/gpccs_inst.bin +-File: nvidia/gm20b/gr/sw_bundle_init.bin +-File: nvidia/gm20b/gr/sw_ctx.bin +-Link: nvidia/gm20b/gr/sw_method_init.bin -> ../../gm200/gr/sw_method_init.bin +-File: nvidia/gm20b/gr/sw_nonctx.bin +-File: nvidia/gm20b/pmu/desc.bin +-File: nvidia/gm20b/pmu/image.bin +-File: nvidia/gm20b/pmu/sig.bin +-File: nvidia/gp100/acr/bl.bin +-File: nvidia/gp100/acr/ucode_load.bin +-File: nvidia/gp100/acr/ucode_unload.bin +-Link: nvidia/gp100/gr/fecs_bl.bin -> ../../gm200/gr/fecs_bl.bin +-File: nvidia/gp100/gr/fecs_data.bin +-File: nvidia/gp100/gr/fecs_inst.bin +-File: nvidia/gp100/gr/fecs_sig.bin +-Link: nvidia/gp100/gr/gpccs_bl.bin -> ../../gm200/gr/gpccs_bl.bin +-File: nvidia/gp100/gr/gpccs_data.bin +-File: nvidia/gp100/gr/gpccs_inst.bin +-File: nvidia/gp100/gr/gpccs_sig.bin +-File: nvidia/gp100/gr/sw_bundle_init.bin +-File: nvidia/gp100/gr/sw_ctx.bin +-File: nvidia/gp100/gr/sw_method_init.bin +-File: nvidia/gp100/gr/sw_nonctx.bin +-File: nvidia/gp102/acr/bl.bin +-File: nvidia/gp102/acr/ucode_load.bin +-File: nvidia/gp102/acr/ucode_unload.bin +-File: nvidia/gp102/acr/unload_bl.bin +-Link: nvidia/gp102/gr/fecs_bl.bin -> ../../gm200/gr/fecs_bl.bin +-File: nvidia/gp102/gr/fecs_data.bin +-File: nvidia/gp102/gr/fecs_inst.bin +-File: nvidia/gp102/gr/fecs_sig.bin +-Link: nvidia/gp102/gr/gpccs_bl.bin -> ../../gm200/gr/gpccs_bl.bin +-File: nvidia/gp102/gr/gpccs_data.bin +-File: nvidia/gp102/gr/gpccs_inst.bin +-File: nvidia/gp102/gr/gpccs_sig.bin +-File: nvidia/gp102/gr/sw_bundle_init.bin +-File: nvidia/gp102/gr/sw_ctx.bin +-File: nvidia/gp102/gr/sw_method_init.bin +-File: nvidia/gp102/gr/sw_nonctx.bin +-File: nvidia/gp102/nvdec/scrubber.bin +-File: nvidia/gp102/sec2/desc.bin +-File: nvidia/gp102/sec2/image.bin +-File: nvidia/gp102/sec2/sig.bin +-File: nvidia/gp102/sec2/desc-1.bin +-File: nvidia/gp102/sec2/image-1.bin +-File: nvidia/gp102/sec2/sig-1.bin +-Link: nvidia/gp104/acr/bl.bin -> ../../gp102/acr/bl.bin +-Link: nvidia/gp104/acr/ucode_load.bin -> ../../gp102/acr/ucode_load.bin +-Link: nvidia/gp104/acr/ucode_unload.bin -> ../../gp102/acr/ucode_unload.bin +-Link: nvidia/gp104/acr/unload_bl.bin -> ../../gp102/acr/unload_bl.bin +-Link: nvidia/gp104/gr/fecs_bl.bin -> ../../gp102/gr/fecs_bl.bin +-File: nvidia/gp104/gr/fecs_data.bin +-File: nvidia/gp104/gr/fecs_inst.bin +-File: nvidia/gp104/gr/fecs_sig.bin +-Link: nvidia/gp104/gr/gpccs_bl.bin -> ../../gp102/gr/gpccs_bl.bin +-File: nvidia/gp104/gr/gpccs_data.bin +-File: nvidia/gp104/gr/gpccs_inst.bin +-File: nvidia/gp104/gr/gpccs_sig.bin +-Link: nvidia/gp104/gr/sw_bundle_init.bin -> ../../gp102/gr/sw_bundle_init.bin +-Link: nvidia/gp104/gr/sw_ctx.bin -> ../../gp102/gr/sw_ctx.bin +-Link: nvidia/gp104/gr/sw_method_init.bin -> ../../gp102/gr/sw_method_init.bin +-Link: nvidia/gp104/gr/sw_nonctx.bin -> ../../gp102/gr/sw_nonctx.bin +-Link: nvidia/gp104/nvdec/scrubber.bin -> ../../gp102/nvdec/scrubber.bin +-Link: nvidia/gp104/sec2/desc.bin -> ../../gp102/sec2/desc.bin +-Link: nvidia/gp104/sec2/image.bin -> ../../gp102/sec2/image.bin +-Link: nvidia/gp104/sec2/sig.bin -> ../../gp102/sec2/sig.bin +-Link: nvidia/gp104/sec2/desc-1.bin -> ../../gp102/sec2/desc-1.bin +-Link: nvidia/gp104/sec2/image-1.bin -> ../../gp102/sec2/image-1.bin +-Link: nvidia/gp104/sec2/sig-1.bin -> ../../gp102/sec2/sig-1.bin +-Link: nvidia/gp106/acr/bl.bin -> ../../gp102/acr/bl.bin +-Link: nvidia/gp106/acr/ucode_load.bin -> ../../gp102/acr/ucode_load.bin +-Link: nvidia/gp106/acr/ucode_unload.bin -> ../../gp102/acr/ucode_unload.bin +-Link: nvidia/gp106/acr/unload_bl.bin -> ../../gp102/acr/unload_bl.bin +-Link: nvidia/gp106/gr/fecs_bl.bin -> ../../gp102/gr/fecs_bl.bin +-File: nvidia/gp106/gr/fecs_data.bin +-Link: nvidia/gp106/gr/fecs_inst.bin -> ../../gp102/gr/fecs_inst.bin +-File: nvidia/gp106/gr/fecs_sig.bin +-Link: nvidia/gp106/gr/gpccs_bl.bin -> ../../gp102/gr/gpccs_bl.bin +-File: nvidia/gp106/gr/gpccs_data.bin +-Link: nvidia/gp106/gr/gpccs_inst.bin -> ../../gp102/gr/gpccs_inst.bin +-File: nvidia/gp106/gr/gpccs_sig.bin +-Link: nvidia/gp106/gr/sw_bundle_init.bin -> ../../gp102/gr/sw_bundle_init.bin +-Link: nvidia/gp106/gr/sw_ctx.bin -> ../../gp102/gr/sw_ctx.bin +-Link: nvidia/gp106/gr/sw_method_init.bin -> ../../gp102/gr/sw_method_init.bin +-Link: nvidia/gp106/gr/sw_nonctx.bin -> ../../gp102/gr/sw_nonctx.bin +-Link: nvidia/gp106/nvdec/scrubber.bin -> ../../gp102/nvdec/scrubber.bin +-Link: nvidia/gp106/sec2/desc.bin -> ../../gp102/sec2/desc.bin +-Link: nvidia/gp106/sec2/image.bin -> ../../gp102/sec2/image.bin +-Link: nvidia/gp106/sec2/sig.bin -> ../../gp102/sec2/sig.bin +-Link: nvidia/gp106/sec2/desc-1.bin -> ../../gp102/sec2/desc-1.bin +-Link: nvidia/gp106/sec2/image-1.bin -> ../../gp102/sec2/image-1.bin +-Link: nvidia/gp106/sec2/sig-1.bin -> ../../gp102/sec2/sig-1.bin +-Link: nvidia/gp107/acr/bl.bin -> ../../gp102/acr/bl.bin +-Link: nvidia/gp107/acr/ucode_load.bin -> ../../gp102/acr/ucode_load.bin +-Link: nvidia/gp107/acr/ucode_unload.bin -> ../../gp102/acr/ucode_unload.bin +-Link: nvidia/gp107/acr/unload_bl.bin -> ../../gp102/acr/unload_bl.bin +-File: nvidia/gp107/gr/fecs_bl.bin +-File: nvidia/gp107/gr/fecs_data.bin +-File: nvidia/gp107/gr/fecs_inst.bin +-File: nvidia/gp107/gr/fecs_sig.bin +-File: nvidia/gp107/gr/gpccs_bl.bin +-File: nvidia/gp107/gr/gpccs_data.bin +-File: nvidia/gp107/gr/gpccs_inst.bin +-File: nvidia/gp107/gr/gpccs_sig.bin +-Link: nvidia/gp107/gr/sw_bundle_init.bin -> ../../gp102/gr/sw_bundle_init.bin +-File: nvidia/gp107/gr/sw_ctx.bin +-Link: nvidia/gp107/gr/sw_method_init.bin -> ../../gp102/gr/sw_method_init.bin +-File: nvidia/gp107/gr/sw_nonctx.bin +-Link: nvidia/gp107/nvdec/scrubber.bin -> ../../gp102/nvdec/scrubber.bin +-Link: nvidia/gp107/sec2/desc.bin -> ../../gp102/sec2/desc.bin +-Link: nvidia/gp107/sec2/image.bin -> ../../gp102/sec2/image.bin +-Link: nvidia/gp107/sec2/sig.bin -> ../../gp102/sec2/sig.bin +-Link: nvidia/gp107/sec2/desc-1.bin -> ../../gp102/sec2/desc-1.bin +-Link: nvidia/gp107/sec2/image-1.bin -> ../../gp102/sec2/image-1.bin +-Link: nvidia/gp107/sec2/sig-1.bin -> ../../gp102/sec2/sig-1.bin +-File: nvidia/gp10b/acr/bl.bin +-File: nvidia/gp10b/acr/ucode_load.bin +-File: nvidia/gp10b/gr/fecs_bl.bin +-File: nvidia/gp10b/gr/fecs_data.bin +-File: nvidia/gp10b/gr/fecs_inst.bin +-File: nvidia/gp10b/gr/fecs_sig.bin +-File: nvidia/gp10b/gr/gpccs_bl.bin +-File: nvidia/gp10b/gr/gpccs_data.bin +-File: nvidia/gp10b/gr/gpccs_inst.bin +-File: nvidia/gp10b/gr/gpccs_sig.bin +-File: nvidia/gp10b/gr/sw_bundle_init.bin +-File: nvidia/gp10b/gr/sw_ctx.bin +-File: nvidia/gp10b/gr/sw_method_init.bin +-File: nvidia/gp10b/gr/sw_nonctx.bin +-File: nvidia/gp10b/pmu/desc.bin +-File: nvidia/gp10b/pmu/image.bin +-File: nvidia/gp10b/pmu/sig.bin +-Link: nvidia/gp108/acr/bl.bin -> ../../gp102/acr/bl.bin +-Link: nvidia/gp108/acr/ucode_load.bin -> ../../gp102/acr/ucode_load.bin +-Link: nvidia/gp108/acr/ucode_unload.bin -> ../../gp102/acr/ucode_unload.bin +-Link: nvidia/gp108/acr/unload_bl.bin -> ../../gp102/acr/unload_bl.bin +-File: nvidia/gp108/gr/fecs_bl.bin +-File: nvidia/gp108/gr/fecs_data.bin +-File: nvidia/gp108/gr/fecs_inst.bin +-File: nvidia/gp108/gr/fecs_sig.bin +-File: nvidia/gp108/gr/gpccs_bl.bin +-File: nvidia/gp108/gr/gpccs_data.bin +-File: nvidia/gp108/gr/gpccs_inst.bin +-File: nvidia/gp108/gr/gpccs_sig.bin +-File: nvidia/gp108/gr/sw_bundle_init.bin +-File: nvidia/gp108/gr/sw_ctx.bin +-File: nvidia/gp108/gr/sw_method_init.bin +-File: nvidia/gp108/gr/sw_nonctx.bin +-Link: nvidia/gp108/nvdec/scrubber.bin -> ../../gp102/nvdec/scrubber.bin +-Link: nvidia/gp108/sec2/desc.bin -> ../../gp102/sec2/desc-1.bin +-Link: nvidia/gp108/sec2/image.bin -> ../../gp102/sec2/image-1.bin +-Link: nvidia/gp108/sec2/sig.bin -> ../../gp102/sec2/sig-1.bin +-File: nvidia/gv100/acr/bl.bin +-File: nvidia/gv100/acr/ucode_load.bin +-File: nvidia/gv100/acr/ucode_unload.bin +-File: nvidia/gv100/acr/unload_bl.bin +-File: nvidia/gv100/gr/fecs_bl.bin +-File: nvidia/gv100/gr/fecs_data.bin +-File: nvidia/gv100/gr/fecs_inst.bin +-File: nvidia/gv100/gr/fecs_sig.bin +-File: nvidia/gv100/gr/gpccs_bl.bin +-File: nvidia/gv100/gr/gpccs_data.bin +-File: nvidia/gv100/gr/gpccs_inst.bin +-File: nvidia/gv100/gr/gpccs_sig.bin +-File: nvidia/gv100/gr/sw_bundle_init.bin +-File: nvidia/gv100/gr/sw_ctx.bin +-File: nvidia/gv100/gr/sw_method_init.bin +-File: nvidia/gv100/gr/sw_nonctx.bin +-File: nvidia/gv100/nvdec/scrubber.bin +-File: nvidia/gv100/sec2/desc.bin +-File: nvidia/gv100/sec2/image.bin +-File: nvidia/gv100/sec2/sig.bin +-File: nvidia/tu102/acr/bl.bin +-File: nvidia/tu102/acr/ucode_ahesasc.bin +-File: nvidia/tu102/acr/ucode_asb.bin +-File: nvidia/tu102/acr/unload_bl.bin +-File: nvidia/tu102/acr/ucode_unload.bin +-File: nvidia/tu102/gr/fecs_bl.bin +-File: nvidia/tu102/gr/fecs_data.bin +-File: nvidia/tu102/gr/fecs_inst.bin +-File: nvidia/tu102/gr/fecs_sig.bin +-File: nvidia/tu102/gr/gpccs_bl.bin +-File: nvidia/tu102/gr/gpccs_data.bin +-File: nvidia/tu102/gr/gpccs_inst.bin +-File: nvidia/tu102/gr/gpccs_sig.bin +-File: nvidia/tu102/gr/sw_bundle_init.bin +-File: nvidia/tu102/gr/sw_ctx.bin +-File: nvidia/tu102/gr/sw_method_init.bin +-File: nvidia/tu102/gr/sw_nonctx.bin +-File: nvidia/tu102/gr/sw_veid_bundle_init.bin +-File: nvidia/tu102/nvdec/scrubber.bin +-File: nvidia/tu102/sec2/desc.bin +-File: nvidia/tu102/sec2/image.bin +-File: nvidia/tu102/sec2/sig.bin +-Link: nvidia/tu104/acr/bl.bin -> ../../tu102/acr/bl.bin +-Link: nvidia/tu104/acr/ucode_ahesasc.bin -> ../../tu102/acr/ucode_ahesasc.bin +-Link: nvidia/tu104/acr/ucode_asb.bin -> ../../tu102/acr/ucode_asb.bin +-Link: nvidia/tu104/acr/unload_bl.bin -> ../../tu102/acr/unload_bl.bin +-Link: nvidia/tu104/acr/ucode_unload.bin -> ../../tu102/acr/ucode_unload.bin +-Link: nvidia/tu104/gr/fecs_bl.bin -> ../../tu102/gr/fecs_bl.bin +-File: nvidia/tu104/gr/fecs_data.bin +-File: nvidia/tu104/gr/fecs_inst.bin +-File: nvidia/tu104/gr/fecs_sig.bin +-Link: nvidia/tu104/gr/gpccs_bl.bin -> ../../tu102/gr/gpccs_bl.bin +-File: nvidia/tu104/gr/gpccs_data.bin +-File: nvidia/tu104/gr/gpccs_inst.bin +-File: nvidia/tu104/gr/gpccs_sig.bin +-File: nvidia/tu104/gr/sw_bundle_init.bin +-File: nvidia/tu104/gr/sw_ctx.bin +-File: nvidia/tu104/gr/sw_method_init.bin +-File: nvidia/tu104/gr/sw_nonctx.bin +-File: nvidia/tu104/gr/sw_veid_bundle_init.bin +-Link: nvidia/tu104/nvdec/scrubber.bin -> ../../tu102/nvdec/scrubber.bin +-Link: nvidia/tu104/sec2/desc.bin -> ../../tu102/sec2/desc.bin +-Link: nvidia/tu104/sec2/image.bin -> ../../tu102/sec2/image.bin +-Link: nvidia/tu104/sec2/sig.bin -> ../../tu102/sec2/sig.bin +-Link: nvidia/tu106/acr/bl.bin -> ../../tu102/acr/bl.bin +-Link: nvidia/tu106/acr/ucode_ahesasc.bin -> ../../tu102/acr/ucode_ahesasc.bin +-Link: nvidia/tu106/acr/ucode_asb.bin -> ../../tu102/acr/ucode_asb.bin +-Link: nvidia/tu106/acr/unload_bl.bin -> ../../tu102/acr/unload_bl.bin +-Link: nvidia/tu106/acr/ucode_unload.bin -> ../../tu102/acr/ucode_unload.bin +-Link: nvidia/tu106/gr/fecs_bl.bin -> ../../tu102/gr/fecs_bl.bin +-File: nvidia/tu106/gr/fecs_data.bin +-File: nvidia/tu106/gr/fecs_inst.bin +-File: nvidia/tu106/gr/fecs_sig.bin +-Link: nvidia/tu106/gr/gpccs_bl.bin -> ../../tu102/gr/gpccs_bl.bin +-File: nvidia/tu106/gr/gpccs_data.bin +-File: nvidia/tu106/gr/gpccs_inst.bin +-File: nvidia/tu106/gr/gpccs_sig.bin +-File: nvidia/tu106/gr/sw_bundle_init.bin +-File: nvidia/tu106/gr/sw_ctx.bin +-File: nvidia/tu106/gr/sw_method_init.bin +-File: nvidia/tu106/gr/sw_nonctx.bin +-File: nvidia/tu106/gr/sw_veid_bundle_init.bin +-Link: nvidia/tu106/nvdec/scrubber.bin -> ../../tu102/nvdec/scrubber.bin +-Link: nvidia/tu106/sec2/desc.bin -> ../../tu102/sec2/desc.bin +-Link: nvidia/tu106/sec2/image.bin -> ../../tu102/sec2/image.bin +-Link: nvidia/tu106/sec2/sig.bin -> ../../tu102/sec2/sig.bin +-File: nvidia/tu116/acr/bl.bin +-File: nvidia/tu116/acr/ucode_ahesasc.bin +-File: nvidia/tu116/acr/ucode_asb.bin +-File: nvidia/tu116/acr/ucode_unload.bin +-File: nvidia/tu116/acr/unload_bl.bin +-File: nvidia/tu116/gr/fecs_bl.bin +-File: nvidia/tu116/gr/fecs_data.bin +-File: nvidia/tu116/gr/fecs_inst.bin +-File: nvidia/tu116/gr/fecs_sig.bin +-File: nvidia/tu116/gr/gpccs_bl.bin +-File: nvidia/tu116/gr/gpccs_data.bin +-File: nvidia/tu116/gr/gpccs_inst.bin +-File: nvidia/tu116/gr/gpccs_sig.bin +-File: nvidia/tu116/gr/sw_bundle_init.bin +-File: nvidia/tu116/gr/sw_ctx.bin +-File: nvidia/tu116/gr/sw_method_init.bin +-File: nvidia/tu116/gr/sw_nonctx.bin +-File: nvidia/tu116/gr/sw_veid_bundle_init.bin +-File: nvidia/tu116/nvdec/scrubber.bin +-File: nvidia/tu116/sec2/desc.bin +-File: nvidia/tu116/sec2/image.bin +-File: nvidia/tu116/sec2/sig.bin +-Link: nvidia/tu117/acr/bl.bin -> ../../tu116/acr/bl.bin +-Link: nvidia/tu117/acr/ucode_ahesasc.bin -> ../../tu116/acr/ucode_ahesasc.bin +-Link: nvidia/tu117/acr/ucode_asb.bin -> ../../tu116/acr/ucode_asb.bin +-Link: nvidia/tu117/acr/ucode_unload.bin -> ../../tu116/acr/ucode_unload.bin +-Link: nvidia/tu117/acr/unload_bl.bin -> ../../tu116/acr/unload_bl.bin +-Link: nvidia/tu117/gr/fecs_bl.bin -> ../../tu116/gr/fecs_bl.bin +-File: nvidia/tu117/gr/fecs_data.bin +-File: nvidia/tu117/gr/fecs_inst.bin +-File: nvidia/tu117/gr/fecs_sig.bin +-Link: nvidia/tu117/gr/gpccs_bl.bin -> ../../tu116/gr/gpccs_bl.bin +-File: nvidia/tu117/gr/gpccs_data.bin +-File: nvidia/tu117/gr/gpccs_inst.bin +-File: nvidia/tu117/gr/gpccs_sig.bin +-File: nvidia/tu117/gr/sw_bundle_init.bin +-File: nvidia/tu117/gr/sw_ctx.bin +-File: nvidia/tu117/gr/sw_method_init.bin +-File: nvidia/tu117/gr/sw_nonctx.bin +-File: nvidia/tu117/gr/sw_veid_bundle_init.bin +-Link: nvidia/tu117/nvdec/scrubber.bin -> ../../tu116/nvdec/scrubber.bin +-Link: nvidia/tu117/sec2/desc.bin -> ../../tu116/sec2/desc.bin +-Link: nvidia/tu117/sec2/image.bin -> ../../tu116/sec2/image.bin +-Link: nvidia/tu117/sec2/sig.bin -> ../../tu116/sec2/sig.bin +-File: nvidia/ga102/acr/ucode_ahesasc.bin +-File: nvidia/ga102/acr/ucode_asb.bin +-File: nvidia/ga102/acr/ucode_unload.bin +-File: nvidia/ga102/gr/fecs_bl.bin +-File: nvidia/ga102/gr/fecs_sig.bin +-File: nvidia/ga102/gr/gpccs_bl.bin +-File: nvidia/ga102/gr/gpccs_sig.bin +-File: nvidia/ga102/gr/NET_img.bin +-File: nvidia/ga102/nvdec/scrubber.bin +-File: nvidia/ga102/sec2/desc.bin +-File: nvidia/ga102/sec2/hs_bl_sig.bin +-File: nvidia/ga102/sec2/image.bin +-File: nvidia/ga102/sec2/sig.bin +-Link: nvidia/ga103/acr/ucode_ahesasc.bin -> ../../ga102/acr/ucode_ahesasc.bin +-Link: nvidia/ga103/acr/ucode_asb.bin -> ../../ga102/acr/ucode_asb.bin +-Link: nvidia/ga103/acr/ucode_unload.bin -> ../../ga102/acr/ucode_unload.bin +-File: nvidia/ga103/gr/fecs_bl.bin +-File: nvidia/ga103/gr/fecs_sig.bin +-File: nvidia/ga103/gr/gpccs_bl.bin +-File: nvidia/ga103/gr/gpccs_sig.bin +-File: nvidia/ga103/gr/NET_img.bin +-Link: nvidia/ga103/nvdec/scrubber.bin -> ../../ga102/nvdec/scrubber.bin +-Link: nvidia/ga103/sec2/desc.bin -> ../../ga102/sec2/desc.bin +-Link: nvidia/ga103/sec2/hs_bl_sig.bin -> ../../ga102/sec2/hs_bl_sig.bin +-Link: nvidia/ga103/sec2/image.bin -> ../../ga102/sec2/image.bin +-Link: nvidia/ga103/sec2/sig.bin -> ../../ga102/sec2/sig.bin +-Link: nvidia/ga104/acr/ucode_ahesasc.bin -> ../../ga102/acr/ucode_ahesasc.bin +-Link: nvidia/ga104/acr/ucode_asb.bin -> ../../ga102/acr/ucode_asb.bin +-Link: nvidia/ga104/acr/ucode_unload.bin -> ../../ga102/acr/ucode_unload.bin +-File: nvidia/ga104/gr/fecs_bl.bin +-File: nvidia/ga104/gr/fecs_sig.bin +-File: nvidia/ga104/gr/gpccs_bl.bin +-File: nvidia/ga104/gr/gpccs_sig.bin +-File: nvidia/ga104/gr/NET_img.bin +-Link: nvidia/ga104/nvdec/scrubber.bin -> ../../ga102/nvdec/scrubber.bin +-Link: nvidia/ga104/sec2/desc.bin -> ../../ga102/sec2/desc.bin +-Link: nvidia/ga104/sec2/hs_bl_sig.bin -> ../../ga102/sec2/hs_bl_sig.bin +-Link: nvidia/ga104/sec2/image.bin -> ../../ga102/sec2/image.bin +-Link: nvidia/ga104/sec2/sig.bin -> ../../ga102/sec2/sig.bin +-Link: nvidia/ga106/acr/ucode_ahesasc.bin -> ../../ga102/acr/ucode_ahesasc.bin +-Link: nvidia/ga106/acr/ucode_asb.bin -> ../../ga102/acr/ucode_asb.bin +-Link: nvidia/ga106/acr/ucode_unload.bin -> ../../ga102/acr/ucode_unload.bin +-File: nvidia/ga106/gr/fecs_bl.bin +-File: nvidia/ga106/gr/fecs_sig.bin +-File: nvidia/ga106/gr/gpccs_bl.bin +-File: nvidia/ga106/gr/gpccs_sig.bin +-File: nvidia/ga106/gr/NET_img.bin +-Link: nvidia/ga106/nvdec/scrubber.bin -> ../../ga102/nvdec/scrubber.bin +-Link: nvidia/ga106/sec2/desc.bin -> ../../ga102/sec2/desc.bin +-Link: nvidia/ga106/sec2/hs_bl_sig.bin -> ../../ga102/sec2/hs_bl_sig.bin +-Link: nvidia/ga106/sec2/image.bin -> ../../ga102/sec2/image.bin +-Link: nvidia/ga106/sec2/sig.bin -> ../../ga102/sec2/sig.bin +-Link: nvidia/ga107/acr/ucode_ahesasc.bin -> ../../ga102/acr/ucode_ahesasc.bin +-Link: nvidia/ga107/acr/ucode_asb.bin -> ../../ga102/acr/ucode_asb.bin +-Link: nvidia/ga107/acr/ucode_unload.bin -> ../../ga102/acr/ucode_unload.bin +-File: nvidia/ga107/gr/fecs_bl.bin +-File: nvidia/ga107/gr/fecs_sig.bin +-File: nvidia/ga107/gr/gpccs_bl.bin +-File: nvidia/ga107/gr/gpccs_sig.bin +-File: nvidia/ga107/gr/NET_img.bin +-Link: nvidia/ga107/nvdec/scrubber.bin -> ../../ga102/nvdec/scrubber.bin +-Link: nvidia/ga107/sec2/desc.bin -> ../../ga102/sec2/desc.bin +-Link: nvidia/ga107/sec2/hs_bl_sig.bin -> ../../ga102/sec2/hs_bl_sig.bin +-Link: nvidia/ga107/sec2/image.bin -> ../../ga102/sec2/image.bin +-Link: nvidia/ga107/sec2/sig.bin -> ../../ga102/sec2/sig.bin +- +-File: nvidia/tu10x/typec/ccg_primary.cyacd +-File: nvidia/tu10x/typec/ccg_secondary.cyacd +-File: nvidia/tu10x/typec/ccg_boot.cyacd +- +-Licence: Redistributable. See LICENCE.nvidia for details +- +--------------------------------------------------------------------------- +- + Driver: mtk_scp - MediaTek SCP System Control Processing Driver + + File: mediatek/mt8183/scp.img +@@ -1903,53 +587,6 @@ Licence: Redistributable. See LICENSE.sdma_firmware for details + + -------------------------------------------------------------------------- + +-Driver: adreno - Qualcomm Adreno GPU firmware +- +-File: qcom/a300_pfp.fw +-Link: a300_pfp.fw -> qcom/a300_pfp.fw +-File: qcom/a300_pm4.fw +-Link: a300_pm4.fw -> qcom/a300_pm4.fw +-File: qcom/a330_pfp.fw +-File: qcom/a330_pm4.fw +-File: qcom/a420_pfp.fw +-File: qcom/a420_pm4.fw +-File: qcom/a530_pfp.fw +-File: qcom/a530_pm4.fw +-File: qcom/a530v3_gpmu.fw2 +-File: qcom/apq8096/a530_zap.mbn +-Link: qcom/a530_zap.mdt -> apq8096/a530_zap.mbn +-File: qcom/a630_gmu.bin +-File: qcom/a630_sqe.fw +-File: qcom/sdm845/a630_zap.mbn +-File: qcom/a650_gmu.bin +-File: qcom/a650_sqe.fw +-File: qcom/sm8250/a650_zap.mbn +-File: qcom/a660_gmu.bin +-File: qcom/a660_sqe.fw +-File: qcom/leia_pfp_470.fw +-File: qcom/leia_pm4_470.fw +-File: qcom/sc8280xp/LENOVO/21BX/qcdxkmsuc8280.mbn +- +-Licence: Redistributable. See LICENSE.qcom and qcom/NOTICE.txt for details +- +-Binary files supplied originally from +-https://developer.qualcomm.com/hardware/dragonboard-410c/tools +- +--------------------------------------------------------------------------- +- +-Driver: adreno - Qualcomm Adreno GPU firmware +- +-File: qcom/yamato_pfp.fw +-File: qcom/yamato_pm4.fw +- +-Licence: Redistributable, BSD-3-Clause licence, See LICENSE.qcom_yamato for details +- +-Binary files generated from header files in EfikaMX kernel sources. A prefix of +-four zero bytes was prepended to make them work with the DRM MSM driver. See +-https://github.com/genesi/linux-legacy/tree/master/drivers/mxc/amd-gpu +- +--------------------------------------------------------------------------- +- + Driver: mlxsw_spectrum - Mellanox Spectrum switch + + File: mellanox/mlxsw_spectrum-13.1420.122.mfa2 +-- +2.40.1 + diff --git a/packages/linux-firmware/0009-linux-firmware-various-Remove-firmware-for-various-d.patch b/packages/linux-firmware/0009-linux-firmware-various-Remove-firmware-for-various-d.patch new file mode 100644 index 00000000..09372aca --- /dev/null +++ b/packages/linux-firmware/0009-linux-firmware-various-Remove-firmware-for-various-d.patch @@ -0,0 +1,324 @@ +From aa70d48430741bc74b64f9ceb0df1348e7a0aa6d Mon Sep 17 00:00:00 2001 +From: Leonard Foerster +Date: Wed, 26 Jul 2023 11:23:46 +0000 +Subject: [PATCH] linux-firmware: various: Remove firmware for various devices + +This patch is a catch all for any specialized hardware that did not +losely fit into any of the other categories. Bottlerocket does not +provide drivers for any of these devices, so there is no use in shipping +firmware for them. + +The following list maps driver names as specified in WHENCE to kernel +config options to allow for easy adding of firmware should driver +enablement make that necessary. + +* dsp56k - CONFIG_ATARI_DSP56K +* yam - CONFIG_YAM +* mtk_scp - CONFIG_MTK_SCP +* imx-sdma - CONFIG_IMX_SDMA +* mlxsw_spectrum - CONFIG_MLXSW_SPECTRUM +* prestera - CONFIG_PRESTERA + +Signed-off-by: Leonard Foerster +--- + LICENCE.Marvell | 22 ------ + LICENCE.mediatek | 9 --- + LICENSE.sdma_firmware | 47 ------------ + WHENCE | 164 ------------------------------------------ + 4 files changed, 242 deletions(-) + delete mode 100644 LICENCE.Marvell + delete mode 100644 LICENCE.mediatek + delete mode 100644 LICENSE.sdma_firmware + +diff --git a/LICENCE.Marvell b/LICENCE.Marvell +deleted file mode 100644 +index fdf4cda..0000000 +--- a/LICENCE.Marvell ++++ /dev/null +@@ -1,22 +0,0 @@ +-Copyright © 2019. Marvell International Ltd. All rights reserved. +- +-Redistribution and use in binary form is permitted provided that the following +-conditions are met: +- +-1. Redistributions must reproduce the above copyright notice, this list of +-conditions and the following disclaimer in the documentation and/or other +-materials provided with the distribution. +- +-2. Redistribution and use shall be used only with Marvell silicon products. +-Any other use, reproduction, modification, translation, or compilation of the +-Software is prohibited. +- +-3. No reverse engineering, decompilation, or disassembly is permitted. +- +-TO THE MAXIMUM EXTENT PERMITTED BY APPLICABLE LAW, THIS SOFTWARE IS PROVIDED +-“AS IS” WITHOUT WARRANTY OF ANY KIND, INCLUDING, WITHOUT LIMITATION, ANY EXPRESS +-OR IMPLIED WARRANTIES OF MERCHANTABILITY, ACCURACY, FITNESS OR SUFFICIENCY FOR A +-PARTICULAR PURPOSE, SATISFACTORY QUALITY, CORRESPONDENCE WITH DESCRIPTION, QUIET +-ENJOYMENT OR NON-INFRINGEMENT OF THIRD PARTY INTELLECTUAL PROPERTY RIGHTS. +-MARVELL, ITS AFFILIATES AND THEIR SUPPLIERS DISCLAIM ANY WARRANTY THAT THE +-DELIVERABLES WILL OPERATE WITHOUT INTERRUPTION OR BE ERROR-FREE. +diff --git a/LICENCE.mediatek b/LICENCE.mediatek +deleted file mode 100644 +index 6886c61..0000000 +--- a/LICENCE.mediatek ++++ /dev/null +@@ -1,9 +0,0 @@ +-MediaTek Inc. grants permission to use and redistribute aforementioned firmware +-files for the use with devices containing MediaTek chipsets, but not as part of +-the Linux kernel or in any other form which would require these files themselves +-to be covered by the terms of the GNU General Public License or the GNU Lesser +-General Public License. +- +-These firmware files are distributed in the hope that they will be useful, but +-are provided WITHOUT ANY WARRANTY, INCLUDING BUT NOT LIMITED TO IMPLIED WARRANTY +-OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. +diff --git a/LICENSE.sdma_firmware b/LICENSE.sdma_firmware +deleted file mode 100644 +index 0d3d562..0000000 +--- a/LICENSE.sdma_firmware ++++ /dev/null +@@ -1,47 +0,0 @@ +-Copyright 2017, NXP +-All rights reserved. +- +-Redistribution. Reproduction and redistribution in binary form, without +-modification, for use solely in conjunction with a NXP +-chipset, is permitted provided that the following conditions are met: +- +- . Redistributions must reproduce the above copyright notice and the following +- disclaimer in the documentation and/or other materials provided with the +- distribution. +- +- . Neither the name of NXP nor the names of its suppliers +- may be used to endorse or promote products derived from this Software +- without specific prior written permission. +- +- . No reverse engineering, decompilation, or disassembly of this Software is +- permitted. +- +-Limited patent license. NXP (.Licensor.) grants you +-(.Licensee.) a limited, worldwide, royalty-free, non-exclusive license under +-the Patents to make, have made, use, import, offer to sell and sell the +-Software. No hardware per se is licensed hereunder. +-The term .Patents. as used in this agreement means only those patents or patent +-applications owned solely and exclusively by Licensor as of the date of +-Licensor.s submission of the Software and any patents deriving priority (i.e., +-having a first effective filing date) therefrom. The term .Software. as used in +-this agreement means the firmware image submitted by Licensor, under the terms +-of this license, to git://git.kernel.org/pub/scm/linux/kernel/git/firmware/ +-linux-firmware.git. +-Notwithstanding anything to the contrary herein, Licensor does not grant and +-Licensee does not receive, by virtue of this agreement or the Licensor's +-submission of any Software, any license or other rights under any patent or +-patent application owned by any affiliate of Licensor or any other entity +-(other than Licensor), whether expressly, impliedly, by virtue of estoppel or +-exhaustion, or otherwise. +- +-DISCLAIMER. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND +-CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, +-BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND +-FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL +-THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, +-INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, +-BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS +-OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +-ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR +-TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE +-USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +diff --git a/WHENCE b/WHENCE +index 3bb6523..748a81e 100644 +--- a/WHENCE ++++ b/WHENCE +@@ -8,20 +8,6 @@ kernel. + + -------------------------------------------------------------------------- + +-Driver: dsp56k - Atari DSP56k support +- +-File: dsp56k/bootstrap.bin +-Source: dsp56k/bootstrap.asm +-Source: dsp56k/Makefile +-Source: dsp56k/concat-bootstrap.pl +- +-Licence: GPLv2 or later. See GPL-2 and GPL-3 for details. +- +-DSP56001 assembler, buildable with a56 from +-http://www.zdomain.com/a56.html +- +--------------------------------------------------------------------------- +- + Driver: cxgb4 - Chelsio Terminator 4/5/6 1/10/25/40/100G Ethernet adapter + + File: cxgb4/t4fw-1.14.4.0.bin +@@ -69,18 +55,6 @@ Found in hex form in kernel source. + + -------------------------------------------------------------------------- + +-Driver: yam - YAM driver for AX.25 +- +-File: yam/1200.bin +-File: yam/9600.bin +- +-Licence: +- * (C) F6FBB 1998 +- +-Found in hex form in kernel source. +- +--------------------------------------------------------------------------- +- + Driver: bnx2x: Broadcom Everest + + File: bnx2x/bnx2x-e1-7.13.1.0.fw +@@ -561,132 +535,6 @@ Version: HuC API/APB ver 8.5.0 for Meteorlake + License: Redistributable. See LICENSE.i915 for details + -------------------------------------------------------------------------- + +-Driver: mtk_scp - MediaTek SCP System Control Processing Driver +- +-File: mediatek/mt8183/scp.img +-Version: v2.0.13324 +-File: mediatek/mt8186/scp.img +-Version: v0.0.9 +-File: mediatek/mt8192/scp.img +-Version: v2.0.20536 +-File: mediatek/mt8195/scp.img +-Version: v2.0.11966 +- +-Licence: Redistributable. See LICENCE.mediatek for details. +- +--------------------------------------------------------------------------- +- +-Driver: imx-sdma - support for i.MX SDMA driver +- +-File: imx/sdma/sdma-imx6q.bin +-Version: 3.3 +-File: imx/sdma/sdma-imx7d.bin +-Version: 4.2 +- +-Licence: Redistributable. See LICENSE.sdma_firmware for details +- +--------------------------------------------------------------------------- +- +-Driver: mlxsw_spectrum - Mellanox Spectrum switch +- +-File: mellanox/mlxsw_spectrum-13.1420.122.mfa2 +-File: mellanox/mlxsw_spectrum-13.1530.152.mfa2 +-File: mellanox/mlxsw_spectrum-13.1620.192.mfa2 +-File: mellanox/mlxsw_spectrum-13.1702.6.mfa2 +-File: mellanox/mlxsw_spectrum-13.1703.4.mfa2 +-File: mellanox/mlxsw_spectrum-13.1910.622.mfa2 +-File: mellanox/mlxsw_spectrum-13.2000.1122.mfa2 +-File: mellanox/mlxsw_spectrum-13.2000.1886.mfa2 +-File: mellanox/mlxsw_spectrum-13.2000.2308.mfa2 +-File: mellanox/mlxsw_spectrum2-29.2000.2308.mfa2 +-File: mellanox/mlxsw_spectrum-13.2000.2714.mfa2 +-File: mellanox/mlxsw_spectrum2-29.2000.2714.mfa2 +-File: mellanox/mlxsw_spectrum-13.2007.1168.mfa2 +-File: mellanox/mlxsw_spectrum2-29.2007.1168.mfa2 +-File: mellanox/mlxsw_spectrum3-30.2007.1168.mfa2 +-File: mellanox/mlxsw_spectrum-13.2008.1036.mfa2 +-File: mellanox/mlxsw_spectrum2-29.2008.1036.mfa2 +-File: mellanox/mlxsw_spectrum3-30.2008.1036.mfa2 +-File: mellanox/mlxsw_spectrum-13.2008.1310.mfa2 +-File: mellanox/mlxsw_spectrum2-29.2008.1310.mfa2 +-File: mellanox/mlxsw_spectrum3-30.2008.1310.mfa2 +-File: mellanox/mlxsw_spectrum-13.2008.1312.mfa2 +-File: mellanox/mlxsw_spectrum2-29.2008.1312.mfa2 +-File: mellanox/mlxsw_spectrum3-30.2008.1312.mfa2 +-File: mellanox/mlxsw_spectrum-13.2008.2018.mfa2 +-File: mellanox/mlxsw_spectrum2-29.2008.2018.mfa2 +-File: mellanox/mlxsw_spectrum3-30.2008.2018.mfa2 +-File: mellanox/mlxsw_spectrum-13.2008.2304.mfa2 +-File: mellanox/mlxsw_spectrum2-29.2008.2304.mfa2 +-File: mellanox/mlxsw_spectrum3-30.2008.2304.mfa2 +-File: mellanox/mlxsw_spectrum-13.2008.2406.mfa2 +-File: mellanox/mlxsw_spectrum2-29.2008.2406.mfa2 +-File: mellanox/mlxsw_spectrum3-30.2008.2406.mfa2 +-File: mellanox/mlxsw_spectrum-13.2008.2438.mfa2 +-File: mellanox/mlxsw_spectrum2-29.2008.2438.mfa2 +-File: mellanox/mlxsw_spectrum3-30.2008.2438.mfa2 +-File: mellanox/mlxsw_spectrum-13.2008.2946.mfa2 +-File: mellanox/mlxsw_spectrum2-29.2008.2946.mfa2 +-File: mellanox/mlxsw_spectrum3-30.2008.2946.mfa2 +-File: mellanox/mlxsw_spectrum-13.2008.3326.mfa2 +-File: mellanox/mlxsw_spectrum2-29.2008.3326.mfa2 +-File: mellanox/mlxsw_spectrum3-30.2008.3326.mfa2 +-File: mellanox/mlxsw_spectrum-13.2010.1006.mfa2 +-File: mellanox/mlxsw_spectrum2-29.2010.1006.mfa2 +-File: mellanox/mlxsw_spectrum3-30.2010.1006.mfa2 +-File: mellanox/lc_ini_bundle_2010_1006.bin +-File: mellanox/mlxsw_spectrum-13.2010.1232.mfa2 +-File: mellanox/mlxsw_spectrum2-29.2010.1232.mfa2 +-File: mellanox/mlxsw_spectrum3-30.2010.1232.mfa2 +-File: mellanox/mlxsw_spectrum-13.2010.1406.mfa2 +-File: mellanox/mlxsw_spectrum2-29.2010.1406.mfa2 +-File: mellanox/mlxsw_spectrum3-30.2010.1406.mfa2 +-File: mellanox/mlxsw_spectrum-13.2010.1502.mfa2 +-File: mellanox/mlxsw_spectrum2-29.2010.1502.mfa2 +-File: mellanox/mlxsw_spectrum3-30.2010.1502.mfa2 +-File: mellanox/lc_ini_bundle_2010_1502.bin +-File: mellanox/mlxsw_spectrum-13.2010.3020.mfa2 +-File: mellanox/mlxsw_spectrum2-29.2010.3020.mfa2 +-File: mellanox/mlxsw_spectrum3-30.2010.3020.mfa2 +-File: mellanox/lc_ini_bundle_2010_3020.bin +-File: mellanox/mlxsw_spectrum-13.2010.3146.mfa2 +-File: mellanox/mlxsw_spectrum2-29.2010.3146.mfa2 +-File: mellanox/mlxsw_spectrum3-30.2010.3146.mfa2 +-File: mellanox/lc_ini_bundle_2010_3146.bin +- +-Licence: +- Copyright (c) 2017-2020 Mellanox Technologies, Ltd. All rights reserved. +- +- Redistribution and use in source and binary forms, with or without +- modification, are permitted provided that the following conditions are met: +- +- 1. Redistributions of source code must retain the above copyright +- notice, this list of conditions and the following disclaimer. +- 2. Redistributions in binary form must reproduce the above copyright +- notice, this list of conditions and the following disclaimer in the +- documentation and/or other materials provided with the distribution. +- 3. Neither the names of the copyright holders nor the names of its +- contributors may be used to endorse or promote products derived from +- this software without specific prior written permission. +- +- Alternatively, this software may be distributed under the terms of the +- GNU General Public License ("GPL") version 2 as published by the Free +- Software Foundation. +- +- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +- AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +- IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +- ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE +- LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR +- CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF +- SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +- INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN +- CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) +- ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE +- POSSIBILITY OF SUCH DAMAGE. +- +--------------------------------------------------------------------------- +- + Driver: ice - Intel(R) Ethernet Connection E800 Series + + File: intel/ice/ddp/ice-1.3.30.0.pkg +@@ -700,15 +548,3 @@ File: intel/ice/ddp-wireless_edge/ice_wireless_edge-1.3.10.0.pkg + License: Redistributable. See LICENSE.ice_enhanced for details + + -------------------------------------------------------------------------- +- +-Driver: prestera - Marvell driver for Prestera family ASIC devices +- +-File: mrvl/prestera/mvsw_prestera_fw-v2.0.img +-File: mrvl/prestera/mvsw_prestera_fw-v3.0.img +-File: mrvl/prestera/mvsw_prestera_fw-v4.0.img +-File: mrvl/prestera/mvsw_prestera_fw-v4.1.img +-File: mrvl/prestera/mvsw_prestera_fw_arm64-v4.1.img +- +-Licence: Redistributable. See LICENCE.Marvell for details. +- +------------------------------------------------- +-- +2.40.1 + diff --git a/packages/linux-firmware/0010-linux-firmware-amd-ucode-Remove-amd-microcode.patch b/packages/linux-firmware/0010-linux-firmware-amd-ucode-Remove-amd-microcode.patch new file mode 100644 index 00000000..d1082c14 --- /dev/null +++ b/packages/linux-firmware/0010-linux-firmware-amd-ucode-Remove-amd-microcode.patch @@ -0,0 +1,122 @@ +From 820980a4ec6d39dcec84639fb4b7a80bb33f8a21 Mon Sep 17 00:00:00 2001 +From: Leonard Foerster +Date: Wed, 26 Jul 2023 11:28:35 +0000 +Subject: [PATCH] linux-firmware: amd-ucode: Remove amd microcode + +Bottlerocket ships AMD microcode as part of the kernel packages already. +There is no need to ship these microcode images twice. + +Signed-off-by: Leonard Foerster +--- + LICENSE.amd-ucode | 64 ----------------------------------------------- + WHENCE | 23 ----------------- + 2 files changed, 87 deletions(-) + delete mode 100644 LICENSE.amd-ucode + +diff --git a/LICENSE.amd-ucode b/LICENSE.amd-ucode +deleted file mode 100644 +index ea47c57..0000000 +--- a/LICENSE.amd-ucode ++++ /dev/null +@@ -1,64 +0,0 @@ +-Copyright (C) 2010-2022 Advanced Micro Devices, Inc., All rights reserved. +- +-Permission is hereby granted by Advanced Micro Devices, Inc. ("AMD"), +-free of any license fees, to any person obtaining a copy of this +-microcode in binary form (the "Software") ("You"), to install, +-reproduce, copy and distribute copies of the Software and to permit +-persons to whom the Software is provided to do the same, subject to +-the following terms and conditions. Your use of any portion of the +-Software shall constitute Your acceptance of the following terms and +-conditions. If You do not agree to the following terms and conditions, +-do not use, retain or redistribute any portion of the Software. +- +-If You redistribute this Software, You must reproduce the above +-copyright notice and this license with the Software. +-Without specific, prior, written permission from AMD, You may not +-reference AMD or AMD products in the promotion of any product derived +-from or incorporating this Software in any manner that implies that +-AMD endorses or has certified such product derived from or +-incorporating this Software. +- +-You may not reverse engineer, decompile, or disassemble this Software +-or any portion thereof. +- +-THE SOFTWARE IS PROVIDED "AS IS" WITHOUT ANY EXPRESS OR IMPLIED +-WARRANTY OF ANY KIND, INCLUDING BUT NOT LIMITED TO WARRANTIES OF +-MERCHANTABILITY, NONINFRINGEMENT, TITLE, FITNESS FOR ANY PARTICULAR +-PURPOSE, OR WARRANTIES ARISING FROM CONDUCT, COURSE OF DEALING, OR +-USAGE OF TRADE. IN NO EVENT SHALL AMD OR ITS LICENSORS BE LIABLE FOR +-ANY DAMAGES WHATSOEVER (INCLUDING, WITHOUT LIMITATION, DAMAGES FOR +-LOSS OF PROFITS, BUSINESS INTERRUPTION, OR LOSS OF DATA OR +-INFORMATION) ARISING OUT OF AMD'S NEGLIGENCE, GROSS NEGLIGENCE, THE +-USE OF OR INABILITY TO USE THE SOFTWARE, EVEN IF AMD HAS BEEN ADVISED +-OF THE POSSIBILITY OF SUCH DAMAGES. BECAUSE SOME JURISDICTIONS +-PROHIBIT THE EXCLUSION OR LIMITATION OF LIABILITY FOR CONSEQUENTIAL OR +-INCIDENTAL DAMAGES OR THE EXCLUSION OF IMPLIED WARRANTIES, THE ABOVE +-LIMITATION MAY NOT APPLY TO YOU. +- +-Without limiting the foregoing, the Software may implement third party +-technologies for which You must obtain licenses from parties other +-than AMD. You agree that AMD has not obtained or conveyed to You, and +-that You shall be responsible for obtaining the rights to use and/or +-distribute the applicable underlying intellectual property rights +-related to the third party technologies. These third party +-technologies are not licensed hereunder. +- +-If You use the Software (in whole or in part), You shall adhere to all +-applicable U.S., European, and other export laws, including but not +-limited to the U.S. Export Administration Regulations ("EAR"), (15 +-C.F.R. Sections 730 through 774), and E.U. Council Regulation (EC) No +-1334/2000 of 22 June 2000. Further, pursuant to Section 740.6 of the +-EAR, You hereby certify that, except pursuant to a license granted by +-the United States Department of Commerce Bureau of Industry and +-Security or as otherwise permitted pursuant to a License Exception +-under the U.S. Export Administration Regulations ("EAR"), You will not +-(1) export, re-export or release to a national of a country in Country +-Groups D:1, E:1 or E:2 any restricted technology, software, or source +-code You receive hereunder, or (2) export to Country Groups D:1, E:1 +-or E:2 the direct product of such technology or software, if such +-foreign produced direct product is subject to national security +-controls as identified on the Commerce Control List (currently found +-in Supplement 1 to Part 774 of EAR). For the most current Country +-Group listings, or for additional information about the EAR or Your +-obligations under those regulations, please refer to the U.S. Bureau +-of Industry and Security?s website at ttp://www.bis.doc.gov/. +diff --git a/WHENCE b/WHENCE +index 748a81e..5c19692 100644 +--- a/WHENCE ++++ b/WHENCE +@@ -147,29 +147,6 @@ License: Redistributable. See LICENCE.myri10ge_firmware for details. + + -------------------------------------------------------------------------- + +-Driver: microcode_amd - AMD CPU Microcode Update Driver for Linux +- +-File: amd-ucode/microcode_amd.bin +-Raw: amd-ucode/microcode_amd.bin +-Version: 2013-07-10 +-File: amd-ucode/microcode_amd_fam15h.bin +-Raw: amd-ucode/microcode_amd_fam15h.bin +-Version: 2018-05-24 +-File: amd-ucode/microcode_amd_fam16h.bin +-Raw: amd-ucode/microcode_amd_fam16h.bin +-Version: 2014-10-28 +-File: amd-ucode/microcode_amd_fam17h.bin +-Raw: amd-ucode/microcode_amd_fam17h.bin +-Version: 2023-04-13 +-File: amd-ucode/microcode_amd_fam19h.bin +-Raw: amd-ucode/microcode_amd_fam19h.bin +-Version: 2023-01-31 +-File: amd-ucode/README +- +-License: Redistributable. See LICENSE.amd-ucode for details +- +--------------------------------------------------------------------------- +- + Driver: i915 -- Intel Integrated Graphics driver + + File: i915/skl_dmc_ver1_23.bin +-- +2.40.1 + diff --git a/packages/linux-firmware/Cargo.toml b/packages/linux-firmware/Cargo.toml new file mode 100644 index 00000000..6cfbb6b0 --- /dev/null +++ b/packages/linux-firmware/Cargo.toml @@ -0,0 +1,16 @@ +[package] +name = "linux-firmware" +version = "0.1.0" +edition = "2021" +publish = false +build = "../build.rs" + +[package.metadata.build-package] +package-name = "linux-firmware" + +[lib] +path = "../packages.rs" + +[[package.metadata.build-package.external-files]] +url = "https://www.kernel.org/pub/linux/kernel/firmware/linux-firmware-20230625.tar.xz" +sha512 = "0e48aa7f63495485426d37491c7cb61843165625bd47f912c5d83628c6de871759f1a78be3af3d651f7c396bd87dff07e21ba7afc47896c1c143106d5f16d351" diff --git a/packages/linux-firmware/latest-upstream-tags.sh b/packages/linux-firmware/latest-upstream-tags.sh new file mode 100755 index 00000000..3177af68 --- /dev/null +++ b/packages/linux-firmware/latest-upstream-tags.sh @@ -0,0 +1,4 @@ +#!/bin/sh + +echo "Latest upstream tag for linux-firmware:" +git ls-remote --tags --refs https://git.kernel.org/pub/scm/linux/kernel/git/firmware/linux-firmware.git | tail -1 diff --git a/packages/linux-firmware/linux-firmware.spec b/packages/linux-firmware/linux-firmware.spec new file mode 100644 index 00000000..a70d43ab --- /dev/null +++ b/packages/linux-firmware/linux-firmware.spec @@ -0,0 +1,59 @@ +%global debug_package %{nil} + +%global fwdir %{_cross_libdir}/firmware + +# Many of the firmware files have specialized binary formats that are not supported +# by the strip binary used in __spec_install_post macro. Work around build failures +# by skipping striping. +%global __strip /usr/bin/true + +Name: %{_cross_os}linux-firmware +Version: 20230625 +Release: 1%{?dist} +Summary: Firmware files used by the Linux kernel +# The following list of SPDX identifiers was constructed with help of scancode +# tooling and has turned up the following licenses for different drivers by +# checking the different LICENCE/LICENSE files and the licenses in WHENCE: +# * BSD-Source-Code - myri10ge +# * LicenseRef-scancode-chelsio-linux-firmware - cxgb4 +# * LicenseRef-scancode-qlogic-firmware - netxen_nic +# * LicenseRef-scancode-intel - i915, ice +# * LicenseRef-scancode-proprietary-license - bnx2x, qed +# * LicenseRef-scancode-free-unknown - tg3 +License: GPL-1.0-or-later AND GPL-2.0-or-later AND BSD-Source-Code AND LicenseRef-scancode-chelsio-linux-firmware AND LicenseRef-scancode-qlogic-firmware AND LicenseRef-scancode-intel AND LicenseRef-scancode-proprietary-license AND LicenseRef-scancode-free-unknown +URL: https://www.kernel.org/ + +Source0: https://www.kernel.org/pub/linux/kernel/firmware/linux-firmware-%{version}.tar.xz + +Patch0001: 0001-linux-firmware-snd-remove-firmware-for-snd-audio-dev.patch +Patch0002: 0002-linux-firmware-video-Remove-firmware-for-video-broad.patch +Patch0003: 0003-linux-firmware-bt-wifi-Remove-firmware-for-Bluetooth.patch +Patch0004: 0004-linux-firmware-scsi-Remove-firmware-for-SCSI-devices.patch +Patch0005: 0005-linux-firmware-usb-remove-firmware-for-USB-Serial-PC.patch +Patch0006: 0006-linux-firmware-ethernet-Remove-firmware-for-ethernet.patch +Patch0007: 0007-linux-firmware-Remove-firmware-for-Accelarator-devic.patch +Patch0008: 0008-linux-firmware-gpu-Remove-firmware-for-GPU-devices.patch +Patch0009: 0009-linux-firmware-various-Remove-firmware-for-various-d.patch +Patch0010: 0010-linux-firmware-amd-ucode-Remove-amd-microcode.patch + +%description +%{summary}. + +%prep +%autosetup -n linux-firmware-%{version} -p1 + +%build + +%install +mkdir -p %{buildroot}/%{fwdir} +mkdir -p %{buildroot}/%{fwdir}/updates + +# Use zstd compression for firmware files to reduce size on disk. This relies on +# kernel support through FW_LOADER_COMPRESS (and FW_LOADER_COMPRESS_ZSTD for kernels >=5.19) +make DESTDIR=%{buildroot}/ FIRMWAREDIR=%{fwdir} install-zst + +%files +%dir %{fwdir} +%{fwdir}/* +%license LICENCE.* LICENSE.* GPL* WHENCE +%{_cross_attribution_file} diff --git a/packages/microcode/Cargo.toml b/packages/microcode/Cargo.toml new file mode 100644 index 00000000..7edbdc9b --- /dev/null +++ b/packages/microcode/Cargo.toml @@ -0,0 +1,19 @@ +[package] +name = "microcode" +version = "0.1.0" +edition = "2021" +publish = false +build = "../build.rs" + +[lib] +path = "../packages.rs" + +# Check the two upstream repositories for the latest releases + +[[package.metadata.build-package.external-files]] +url = "https://www.kernel.org/pub/linux/kernel/firmware/linux-firmware-20240909.tar.xz" +sha512 = "d1918364f9925291da722075cf2d038082a6b6b5c6d7e5ab8b0888c5e87563718934f493fe172db21608d6eace92ade5c519b5f50b1fc7f25a328e45be059142" + +[[package.metadata.build-package.external-files]] +url = "https://github.com/intel/Intel-Linux-Processor-Microcode-Data-Files/archive/refs/tags/microcode-20240813.tar.gz" +sha512 = "ba1fa7d9bed7d90756ea959f5878afca0deacc9b1e932a936a15d74a411b7efb6103a4af75dc3731d9cbb2e464439ce9a7d448f75bc6f38b616907ff6dec6ee3" diff --git a/packages/microcode/latest-upstream-tags.sh b/packages/microcode/latest-upstream-tags.sh new file mode 100755 index 00000000..717c7ba8 --- /dev/null +++ b/packages/microcode/latest-upstream-tags.sh @@ -0,0 +1,7 @@ +#!/bin/sh + +echo "Latest upstream tag for Intel ucode (microcode-ctl):" +git ls-remote --tags --refs https://github.com/intel/Intel-Linux-Processor-Microcode-Data-Files.git | tail -1 + +echo "Latest upstream tag for AMD ucode (linux-firmware):" +git ls-remote --tags --refs https://git.kernel.org/pub/scm/linux/kernel/git/firmware/linux-firmware.git | tail -1 diff --git a/packages/microcode/microcode.spec b/packages/microcode/microcode.spec new file mode 100644 index 00000000..5a8ad03a --- /dev/null +++ b/packages/microcode/microcode.spec @@ -0,0 +1,136 @@ +# This is a wrapper package for binary-only microcode from Intel and AMD. +%global debug_package %{nil} + +# These are specific to the upstream source RPM, and will likely need to be +# updated for each new version. +%global amd_ucode_version 20240909 +%global intel_ucode_version 20240813 + +Name: %{_cross_os}microcode +Version: 0.0 +Release: 1%{?dist} +Epoch: 1 +Summary: Microcode for AMD and Intel processors +License: LicenseRef-scancode-amd-linux-firmware-export AND LicenseRef-scancode-intel-mcu-2018 + +# Packaging AMD and Intel microcode together is specific to Bottlerocket, and +# RPM only allows one URL field per package, so this is about as accurate as we +# can be. The real upstream URLs for AMD and Intel microcode are given below in +# the subpackage definitions. +URL: https://github.com/bottlerocket-os/bottlerocket/tree/develop/packages/microcode + +Source0: https://www.kernel.org/pub/linux/kernel/firmware/linux-firmware-%{amd_ucode_version}.tar.xz +Source1: https://github.com/intel/Intel-Linux-Processor-Microcode-Data-Files/archive/refs/tags/microcode-%{intel_ucode_version}.tar.gz + +# Lets us install "microcode" to pull in the AMD and Intel updates. +Requires: %{_cross_os}microcode-amd +Requires: %{_cross_os}microcode-intel + +%description +%{summary}. + +%package amd +Summary: Microcode for AMD processors +License: LicenseRef-scancode-amd-linux-firmware-export +URL: https://git.kernel.org/pub/scm/linux/kernel/git/firmware/linux-firmware.git/tree/amd-ucode +Requires: %{_cross_os}microcode-amd-license + +%description amd +%{summary}. + +%package amd-license +Summary: License files for microcode for AMD processors +License: LicenseRef-scancode-amd-linux-firmware-export +URL: https://git.kernel.org/pub/scm/linux/kernel/git/firmware/linux-firmware.git/plain/LICENSE.amd-ucode + +%description amd-license +%{summary}. + +%package intel +Summary: Microcode for Intel processors +License: LicenseRef-scancode-intel-mcu-2018 +URL: https://github.com/intel/Intel-Linux-Processor-Microcode-Data-Files +Requires: %{_cross_os}microcode-intel-license + +%description intel +%{summary}. + +%package intel-license +Summary: License files for microcode for Intel processors +License: LicenseRef-scancode-intel-mcu-2018 +URL: https://github.com/intel/Intel-Linux-Processor-Microcode-Data-Files/blob/main/license + +%description intel-license +%{summary}. + +# Lets us install "microcode-licenses" for just the license files. +%package licenses +Summary: License files for microcode for AMD and Intel processors +License: LicenseRef-scancode-amd-linux-firmware-export AND LicenseRef-scancode-intel-mcu-2018 +URL: https://github.com/bottlerocket-os/bottlerocket/tree/develop/packages/microcode +Requires: %{_cross_os}microcode-amd-license +Requires: %{_cross_os}microcode-intel-license + +%description licenses +%{summary}. + +%prep +mkdir amd intel +tar -C amd --strip-components=1 -xof %{SOURCE0} +tar -C intel --strip-components=1 -xof %{SOURCE1} +# CVE-2023-20569 - "AMD Inception" +# This is adding new microcode for Zen3/Zen4 AMD cpus. The patch was taken +# directly from the linux-firmware repository, but has not been part of a +# release there, yet. +# Unfortunately the setup here with two separate sources being brought into +# separate directories and the patch only affecting one of the two is not conducive +# of using the standard way of applying git binary patches through `autosetup -S git ...` +# Hence we have to extract some of the parts from that macro to let the patch +# apply. +# +# As soon as we update to a release that includes this patch everything from here... +pushd amd +%global __scm git +%__scm_setup_git +%autopatch -p1 +popd +# ... to here can be dropped +cp {amd/,}LICENSE.amd-ucode +cp intel/intel-ucode-with-caveats/* intel/intel-ucode +cp intel/license LICENSE.intel-ucode + +# Create links to the SPDX identifiers we're using, so they're easier to match +# up with the license text. +ln -s LICENSE.intel-ucode LicenseRef-scancode-intel-mcu-2018 +ln -s LICENSE.amd-ucode LicenseRef-scancode-amd-linux-firmware-export + +%build + +%install +install -d %{buildroot}%{_cross_libdir}/firmware/{amd,intel}-ucode +install -p -m 0644 amd/amd-ucode/*.bin %{buildroot}%{_cross_libdir}/firmware/amd-ucode +install -p -m 0644 intel/intel-ucode/* %{buildroot}%{_cross_libdir}/firmware/intel-ucode + +%files + +%files amd +%dir %{_cross_libdir}/firmware +%dir %{_cross_libdir}/firmware/amd-ucode +%{_cross_libdir}/firmware/amd-ucode/microcode_amd*.bin + +%files amd-license +%license LICENSE.amd-ucode LicenseRef-scancode-amd-linux-firmware-export + +%files intel +%dir %{_cross_libdir}/firmware +%dir %{_cross_libdir}/firmware/intel-ucode +%{_cross_libdir}/firmware/intel-ucode/??-??-?? +%exclude %{_cross_libdir}/firmware/intel-ucode/??-??-??_DUPLICATE + +%files intel-license +%license LICENSE.intel-ucode LicenseRef-scancode-intel-mcu-2018 + +%files licenses +%{_cross_attribution_file} + +%changelog diff --git a/packages/packages.rs b/packages/packages.rs new file mode 100644 index 00000000..36be246d --- /dev/null +++ b/packages/packages.rs @@ -0,0 +1,7 @@ +/*! + +This is an intentionally empty file that all of the package `Cargo.toml` files can point to as their +`lib.rs`. The build system uses `build.rs` to invoke `buildsys` but Cargo needs something to compile +so we give it an empty `lib.rs` file. + +!*/ diff --git a/packages/shim/Cargo.toml b/packages/shim/Cargo.toml new file mode 100644 index 00000000..c402f5bf --- /dev/null +++ b/packages/shim/Cargo.toml @@ -0,0 +1,13 @@ +[package] +name = "shim" +version = "0.1.0" +edition = "2021" +publish = false +build = "../build.rs" + +[lib] +path = "../packages.rs" + +[[package.metadata.build-package.external-files]] +url = "https://github.com/rhboot/shim/releases/download/15.8/shim-15.8.tar.bz2" +sha512 = "30b3390ae935121ea6fe728d8f59d37ded7b918ad81bea06e213464298b4bdabbca881b30817965bd397facc596db1ad0b8462a84c87896ce6c1204b19371cd1" diff --git a/packages/shim/shim.spec b/packages/shim/shim.spec new file mode 100644 index 00000000..159e9992 --- /dev/null +++ b/packages/shim/shim.spec @@ -0,0 +1,63 @@ +%global debug_package %{nil} +%global __strip %{_bindir}/true + +%global efidir /boot/efi/EFI/BOOT +%global boot_efi_image boot%{_cross_efi_arch}.efi +%global grub_efi_image grub%{_cross_efi_arch}.efi +%global shim_efi_image shim%{_cross_efi_arch}.efi +%global mokm_efi_image mm%{_cross_efi_arch}.efi + +%global shimver 15.8 +%global commit 5914984a1ffeab841f482c791426d7ca9935a5e6 + +Name: %{_cross_os}shim +Version: %{shimver} +Release: 1%{?dist} +Summary: UEFI shim loader +License: BSD-3-Clause +URL: https://github.com/rhboot/shim/ +Source0: https://github.com/rhboot/shim/archive/%{shimver}/shim-%{shimver}.tar.bz2 + +%description +%{summary}. + +%prep +%autosetup -n shim-%{shimver} -p1 + +# Make sure the `.vendor_cert` section is large enough to cover a replacement +# certificate, or `objcopy` may silently retain the existing section. +# 4096 - 16 (for cert_table structure) = 4080 bytes. +truncate -s 4080 empty.cer + +%global shim_make \ +make\\\ + ARCH="%{_cross_arch}"\\\ + CROSS_COMPILE="%{_cross_target}-"\\\ + COMMIT_ID="%{commit}"\\\ + RELEASE="%{release}"\\\ + DEFAULT_LOADER="%{grub_efi_image}"\\\ + DISABLE_REMOVABLE_LOAD_OPTIONS=y\\\ + DESTDIR="%{buildroot}"\\\ + EFIDIR="BOOT"\\\ + VENDOR_CERT_FILE="empty.cer"\\\ + POST_PROCESS_PE_FLAGS="-N"\\\ +%{nil} + +%build +%shim_make + +%install +%shim_make install-as-data +install -d %{buildroot}%{efidir} +find %{buildroot}%{_datadir} -name '%{shim_efi_image}' -exec \ + mv {} "%{buildroot}%{efidir}/%{boot_efi_image}" \; +find %{buildroot}%{_datadir} -name '%{mokm_efi_image}' -exec \ + mv {} "%{buildroot}%{efidir}/%{mokm_efi_image}" \; +rm -rf %{buildroot}%{_datadir} + +%files +%license COPYRIGHT +%{_cross_attribution_file} +%dir %{efidir} +%{efidir}/%{boot_efi_image} +%{efidir}/%{mokm_efi_image} diff --git a/tools/.gitignore b/tools/.gitignore new file mode 100644 index 00000000..d745034e --- /dev/null +++ b/tools/.gitignore @@ -0,0 +1,4 @@ +/bin +/twoliter +/.crates.toml +/.crates2.json diff --git a/tools/collect-kernel-config b/tools/collect-kernel-config new file mode 100755 index 00000000..f5306abe --- /dev/null +++ b/tools/collect-kernel-config @@ -0,0 +1,45 @@ +#!/usr/bin/env bash + +output_dir=/tmp/configs + +usage() { + cat <&2 usage + bail "$1" +} + + +# +# Parse arguments +# + +while [[ $# -gt 0 ]]; do + case $1 in + -o|--output-dir) + shift; output_dir=$1 ;; + -h|--help) + usage; exit 0 ;; + *) + usage_error "Invalid option '$1'" ;; + esac + shift +done + +readonly output_dir +mkdir -p ${output_dir} +echo "Created ${output_dir}" + +for kernel in 5.10 5.15 6.1; do + for arch in x86_64 aarch64; do + rpm2cpio ./build/rpms/kernel-${kernel}/bottlerocket-kernel-${kernel}-${kernel}*.${arch}.rpm | cpio --extract --to-stdout ./boot/config > ${output_dir}/config-${kernel}-${arch}.config + done +done diff --git a/tools/diff-kernel-config b/tools/diff-kernel-config new file mode 100755 index 00000000..8aa85891 --- /dev/null +++ b/tools/diff-kernel-config @@ -0,0 +1,267 @@ +#!/usr/bin/env bash + +# +# Common error handling +# + +exit_trap_cmds=() + +on_exit() { + exit_trap_cmds+=( "$1" ) +} + +run_exit_trap_cmds() { + for cmd in "${exit_trap_cmds[@]}"; do + eval "${cmd}" + done +} + +trap run_exit_trap_cmds EXIT + +warn() { + >&2 echo "Warning: $*" +} + +bail() { + if [[ $# -gt 0 ]]; then + >&2 echo "Error: $*" + fi + exit 1 +} + +usage() { + cat <&2 usage + bail "$1" +} + + +# +# Parse arguments +# + +kernel_versions=() + +while [[ $# -gt 0 ]]; do + case $1 in + -a|--after) + shift; gitrev_after_arg=$1 ;; + -b|--before) + shift; gitrev_before_arg=$1 ;; + -k|--kernel) + shift; kernel_versions+=( "$1" ) ;; + -o|--output-dir) + shift; output_dir=$1 ;; + -r|--resume) + shift; resume=1 ;; + -h|--help) + usage; exit 0 ;; + *) + usage_error "Invalid option '$1'" ;; + esac + shift +done + +[[ -n ${output_dir} ]] || usage_error 'require -o|--output-dir' +[[ -e ${output_dir} && ! -v resume ]] && bail "Output directory '${output_dir}' exists already, not touching it" +readonly output_dir + +# Validate and resolve the given before and after Git revisions. Resolving +# them now prevents relative references from moving around after the first +# checkout. +[[ -n ${gitrev_before_arg} ]] || usage_error 'require -b|--before' +[[ -n ${gitrev_after_arg} ]] || usage_error 'require -a|--after' +[[ -n ${kernel_versions[*]} ]] || usage_error 'require -k|--kernel' +gitrev_before=$(git rev-parse --verify --end-of-options "${gitrev_before_arg}^{commit}") +gitrev_after=$(git rev-parse --verify --end-of-options "${gitrev_after_arg}^{commit}") +[[ -n ${gitrev_before} ]] || bail "Invalid Git revision '${gitrev_before_arg}'" +[[ -n ${gitrev_after} ]] || bail "Invalid Git revision '${gitrev_after_arg}'" +readonly gitrev_before +readonly gitrev_after + + +# +# Prepare working tree +# + +# We'll check out the before and after states to compare. For that the working +# tree and the index need to be clean. +if [[ -n $(git status --porcelain --untracked-files=no) ]]; then + bail 'The working tree or index of the repository are not clean. ' \ + 'Consider running "git stash" to temporarily stow away your changes.' +fi + +# Restore current repository state whenever we exit (either a checked out +# branch or the current detached head state). +gitrev_original=$(git rev-parse --abbrev-ref HEAD) +if [[ -z ${gitrev_original} ]]; then + gitrev_original=$(git rev-parse HEAD) || bail 'Cannot determine current repository HEAD.' +fi +readonly gitrev_original +on_exit "git checkout --quiet '${gitrev_original}'" + + +# +# Iterate over all viable build configurations in before and after states +# + +mkdir -p "${output_dir}" || bail "Failed to create output directory '${output_dir}'" + +for state in after before; do + + gitrev_var=gitrev_${state} + git checkout --quiet "${!gitrev_var}" || bail "Cannot check out '${!gitrev_var}'." + + for kver in "${kernel_versions[@]}"; do + + arches=( aarch64 x86_64 ) + + for arch in "${arches[@]}"; do + config_path=${output_dir}/config-${arch}-${kver}-${state} + + if [[ -v resume && -e ${config_path} ]]; then + echo "${config_path} already exists, skipping" + continue + fi + + debug_id="state=${state} arch=${arch} kernel=${kver}" + + # + # Run build + # + + BUILDSYS_ARCH="${arch}" PACKAGE="kernel-${kver/./_}" make twoliter build-package \ + || bail "Build failed for ${debug_id}" + + # + # Find kernel RPM + # + + shopt -s nullglob + kernel_rpms=( + ./build/rpms/kernel-"${kver}"/bottlerocket-kernel-"${kver}"-"${kver}".*.*.*.br1."${arch}".rpm + ) + shopt -u nullglob + + case ${#kernel_rpms[@]} in + 0) bail "No kernel RPM found for ${debug_id}" ;; + 1) kernel_rpm=${kernel_rpms[0]} ;; + *) + # shellcheck disable=SC2012 # find(1) cannot sort by mtime + kernel_rpm=$(ls -1t "${kernel_rpms[@]}" | head -n 1) + warn "More than one kernel RPM found for ${debug_id}. Choosing '${kernel_rpm}' as the latest build." + ;; + esac + + kver_full=$(rpm --query --queryformat '%{VERSION}-%{RELEASE}' "${kernel_rpm}") + + # + # Extract kernel config + # + + rpm2cpio "${kernel_rpm}" \ + | cpio --quiet --extract --to-stdout ./boot/config >"${config_path}" + [[ -s "${config_path}" ]] || bail "Failed to extract config for ${debug_id}" + + + echo "config-${arch}-${kver}-${state} -> ${kver_full}" >> "${output_dir}"/kver_mapping + done # arch + + done # kernel + + +done # state + + +# +# Post-process the collected pairs of "before" and "after" configs (generate diffs, a report, a summary) +# + +# Get the helpful diffconfig script from the kernel source tree. We package it +# in the kernel-archive RPM from where it can be extracted. Here we extract the +# latest version of the script, but any kernel version and arch will do. +latest_kver=$(printf '%s\n' "${kernel_versions[@]}" | sort -V | tail -n1) +latest_archive_rpms=( ./build/rpms/kernel-"${latest_kver}"/bottlerocket-kernel-"${latest_kver}"-archive-*.rpm ) +diffconfig=$(mktemp --suffix -bottlerocket-diffconfig) +on_exit "rm '${diffconfig}'" +rpm2cpio "${latest_archive_rpms[0]}" \ + | cpio --quiet --extract --to-stdout \ + | tar --xz --extract --to-stdout kernel-devel/scripts/diffconfig >"${diffconfig}" +[[ -s ${diffconfig} ]] || bail "Failed to extract diffconfig tool from '${latest_archive_rpms[0]}'." +chmod +x "${diffconfig}" + +# Diff the before and after states for each collected pair +for config_before in "${output_dir}"/config-*-before; do + config_after=${config_before/before/after} + config_diff=${config_before/before/diff} + "${diffconfig}" "${config_before}" "${config_after}" >"${config_diff}" \ + || bail "Failed to diff '${config_before}' and '${config_after}'" +done + +# Generate diff summary +echo +for config_diff in "${output_dir}"/config-*-diff; do + config_base=${config_diff##*/} + awk " + /^-/ { removed += 1 } + /^+/ { added += 1 } + / -> / { changed += 1 } + END { printf \"${config_base}:\t%3d removed, %3d added, %3d changed\n\", removed, added, changed } + " "${config_diff}" +done | sort -V | tee "${output_dir}"/diff-summary +echo + +# Generate combined report of changes +head -v -n 999999 "${output_dir}"/*-diff >"${output_dir}"/diff-report +echo "A full report has been placed in '${output_dir}/diff-report'" + +# Generate combined report in tabular form (csv) +echo "config change" > "${output_dir}"/diff-table +cat "${output_dir}"/*-diff | sort | uniq >> "${output_dir}"/diff-table + +for config_diff in "${output_dir}"/config-*-diff; do + kernel_version=$(echo "${config_diff}" | sed -e "s%^${output_dir}/config-%%" -e "s%-diff$%%") + kver_before=$(grep "${kernel_version}-before" "${output_dir}/kver_mapping" | cut -d ' ' -f 3) + kver_after=$(grep "${kernel_version}-after" "${output_dir}/kver_mapping" | cut -d ' ' -f 3) + col_name="${kernel_version} (${kver_before} -> ${kver_after})" + + sed -i "s/$/,/" "${output_dir}"/diff-table + sed -i "/^config change/ s/$/${col_name}/" "${output_dir}"/diff-table + + mapfile -t diff_lines < "${config_diff}" + + for line in "${diff_lines[@]}"; do + sed -i "/^${line}/ s/$/x/" "${output_dir}"/diff-table + done +done +echo "A tabular report in csv-format has been placed in '${output_dir}/diff-table'" diff --git a/tools/install-twoliter.sh b/tools/install-twoliter.sh new file mode 100755 index 00000000..8125fe0d --- /dev/null +++ b/tools/install-twoliter.sh @@ -0,0 +1,183 @@ +#!/usr/bin/env bash + +# +# Common error handling +# + +exit_trap_cmds=() + +on_exit() { + exit_trap_cmds+=( "$1" ) +} + +run_exit_trap_cmds() { + for cmd in "${exit_trap_cmds[@]}"; do + eval "${cmd}" + done +} + +trap run_exit_trap_cmds EXIT + +warn() { + >&2 echo "Warning: $*" +} + +bail() { + if [[ $# -gt 0 ]]; then + >&2 echo "Error: $*" + fi + exit 1 +} + +usage() { + cat <&2 usage + bail "$1" +} + + +# +# Parse arguments +# + +while [[ $# -gt 0 ]]; do + case $1 in + -r|--repo) + shift; repo=$1 ;; + -v|--version) + shift; version=$1 ;; + -d|--directory) + shift; dir=$1 ;; + -e|--reuse-existing-install) + reuse_existing="true" ;; + -b|--allow-binary-install) + allow_bin="true"; shift; bin_checksum=$1 ;; + -s|--allow-from-source) + from_source="true" ;; + -k|--skip-version-check) + skip_version_check="true" ;; + -h|--help) + usage; exit 0 ;; + *) + usage_error "Invalid option '$1'" ;; + esac + shift +done + +set -e + +workdir="$(mktemp -d)" +on_exit "rm -rf ${workdir}" +mkdir -p "${dir}" + +if [ "${reuse_existing}" = "true" ] ; then + if [ -x "${dir}/twoliter" ] ; then + if [ "${skip_version_check}" = "true" ]; then + echo "Twoliter binary found and --skip-version-check is true. Skipping install." + exit 0 + fi + version_output="$("${dir}/twoliter" --version)" + found_version=v$(echo $version_output | awk '{print $2}') + echo "Found Twoliter ${found_version} installed." + if [ "${found_version}" = "${version}" ] ; then + echo "Skipping installation." + exit 0 + fi + fi +fi + +if [ "${allow_bin}" = "true" ] ; then + host_arch="$(uname -m)" + host_arch="${host_arch,,}" + host_kernel="$(uname -s)" + host_kernel="${host_kernel,,}" + case "${host_kernel}-${host_arch}" in + linux-x86_64 | linux-aarch64) + echo "Installing Twoliter from binary release." + twoliter_release="${repo}/releases/download/${version}" + twoliter_target="${host_arch}-unknown-${host_kernel}-musl" + cd "${workdir}" + curl -sSL "${twoliter_release}/twoliter-${twoliter_target}.tar.xz" -o "twoliter.tar.xz" + echo "Checking binary checksum..." + sha256sum -c <<< "${bin_checksum} twoliter.tar.xz" + tar xf twoliter.tar.xz + mv "./twoliter-${twoliter_target}/twoliter" "${dir}" + exit 0 + ;; + *) + echo "No pre-built binaries available for twoliter ${version}." + ;; + esac +else + echo "Skipping binary installation of twoliter ${version} because --allow-binary-install was not set." +fi + +if [ "${from_source}" = "true" ] ; then + echo "Installing Twoliter version ${version} from source" + cargo +nightly install \ + -Z bindeps \ + --locked \ + --root "${workdir}" \ + --git "${repo}" \ + --rev "${version}" \ + --bin twoliter \ + --quiet \ + twoliter + mv "${workdir}/bin/twoliter" "${dir}/twoliter" + echo "Installed twoliter ${version} from source." + exit 0 +else + echo "Skipped installing twoliter ${version} from source." +fi + + +if [ ! -x "${dir}/twoliter" ] ; then + echo "Could not install twoliter ${version}" >&2 + exit 1 +fi