-
Notifications
You must be signed in to change notification settings - Fork 11
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Apply SPI TPM patches from upstream #9
Open
tdavenvidia
wants to merge
152
commits into
NVIDIA-BaseOS-6:main
Choose a base branch
from
tdavenvidia:spi-tpm-v3
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Signed-off-by: Ian May <[email protected]>
Signed-off-by: Ian May <[email protected]>
BugLink: https://bugs.launchpad.net/bugs/1786013 Signed-off-by: Ian May <[email protected]>
Ignore: yes Signed-off-by: Ian May <[email protected]>
Signed-off-by: Ian May <[email protected]>
Signed-off-by: Ian May <[email protected]>
Signed-off-by: Ian May <[email protected]>
This reverts commit 93f3643. Signed-off-by: Dimitri John Ledkov <[email protected]>
BugLink: https://bugs.launchpad.net/bugs/1786013 Signed-off-by: Dimitri John Ledkov <[email protected]>
Ignore: yes Signed-off-by: Dimitri John Ledkov <[email protected]>
BugLink: https://bugs.launchpad.net/bugs/1992162 Properties: no-test-build Signed-off-by: Dimitri John Ledkov <[email protected]>
Signed-off-by: Dimitri John Ledkov <[email protected]>
BugLink: https://bugs.launchpad.net/bugs/1786013 Signed-off-by: Kleber Sacilotto de Souza <[email protected]>
BugLink: https://bugs.launchpad.net/bugs/1786013 Signed-off-by: Kleber Sacilotto de Souza <[email protected]>
Ignore: yes Signed-off-by: Kleber Sacilotto de Souza <[email protected]>
BugLink: https://bugs.launchpad.net/bugs/1996300 Properties: no-test-build Signed-off-by: Kleber Sacilotto de Souza <[email protected]>
Signed-off-by: Kleber Sacilotto de Souza <[email protected]>
Ignore: yes Signed-off-by: Kleber Sacilotto de Souza <[email protected]>
BugLink: https://bugs.launchpad.net/bugs/1998795 Properties: no-test-build Signed-off-by: Kleber Sacilotto de Souza <[email protected]>
Signed-off-by: Kleber Sacilotto de Souza <[email protected]>
Ignore: yes Signed-off-by: Kleber Sacilotto de Souza <[email protected]>
BugLink: https://bugs.launchpad.net/bugs/1999745 Properties: no-test-build Signed-off-by: Kleber Sacilotto de Souza <[email protected]>
Signed-off-by: Kleber Sacilotto de Souza <[email protected]>
BugLink: https://bugs.launchpad.net/bugs/2002679 This reverts commit e96b739. In order to use the same compiler as used for kinetic:linux (gcc-12) we have made some changes to explicitly compile jammy:linux-hwe-5.19 with the same compiler. However, such changes are breaking the build of a number of dkms packages. Revert this commit, which would make the kernel compile with the default GCC in Jammy (gcc-11), while a proper solution is being worked on. Signed-off-by: Kleber Sacilotto de Souza <[email protected]>
Ignore: yes Signed-off-by: Kleber Sacilotto de Souza <[email protected]>
BugLink: https://bugs.launchpad.net/bugs/2002679 Changing the gcc version used for the build from gcc-12 to gcc (11) removed CONFIG_INIT_STACK_ALL_ZERO and CONFIG_SHADOW_CALL_STACK from being an option on the kernel config. Update the annotations file accondingly, keeping the annotation instead of simply removing it so when the configs are re-enabled in the future it stays as a reminder to update the annotation. Signed-off-by: Kleber Sacilotto de Souza <[email protected]>
BugLink: https://bugs.launchpad.net/bugs/2001755 Properties: no-test-build Signed-off-by: Kleber Sacilotto de Souza <[email protected]>
…3.01.02) BugLink: https://bugs.launchpad.net/bugs/1786013 Signed-off-by: Kleber Sacilotto de Souza <[email protected]>
Signed-off-by: Kleber Sacilotto de Souza <[email protected]>
In the Jammy environment, some config options cannot be enabled as enforced in the parent kernel. Add code to automatically adjust those. This was attempted to be manual edits to the annotations. However those get overwritten on each rebase. So instead add it to the local-mangle script but run only if the compiler set to be used is gcc-11. Ignore: yes Signed-off-by: Stefan Bader <[email protected]>
…ter) BugLink: https://bugs.launchpad.net/bugs/1786013 Signed-off-by: Ian May <[email protected]>
Signed-off-by: Ian May <[email protected]>
BugLink: https://bugs.launchpad.net/bugs/1786013 Signed-off-by: Ian May <[email protected]>
BugLink: https://bugs.launchpad.net/bugs/1982519 nvbug: https://nvbugswb.nvidia.com/NVBugs5/redir.aspx?url=/3728100 With this change, the NFS driver would be enabled to support GPUDirectStorage(GDS). The change is around frwr_map and frwr_unmap in the NFS driver, where the IO request is first intercepted to check for GDS pages and if it is a GDS page then the request is served by GDS driver component called nvidia-fs, else the request would be served by the standard NFS driver code. Signed-off-by: Sourab Gupta <[email protected]> Acked-by: Kiran Kumar Modukuri <[email protected]> Acked-by: Rebanta Mitra <[email protected]> Signed-off-by: Brad Figg <[email protected]>
Ignore: yes Signed-off-by: Brad Figg <[email protected]>
Ignore: yes Signed-off-by: Roxana Nicolescu <[email protected]> Signed-off-by: Brad Figg <[email protected]>
CVE-2023-1829 Signed-off-by: Thadeu Lima de Souza Cascardo <[email protected]> Acked-by: Cengiz Can <[email protected]> Acked-by: Stefan Bader <[email protected]> Signed-off-by: Stefan Bader <[email protected]> Signed-off-by: Thadeu Lima de Souza Cascardo <[email protected]> Signed-off-by: Brad Figg <[email protected]>
BugLink: https://bugs.launchpad.net/bugs/2017596 Properties: no-test-build Signed-off-by: Brad Figg <[email protected]>
…ter) BugLink: https://bugs.launchpad.net/bugs/1786013 Signed-off-by: Brad Figg <[email protected]>
Signed-off-by: Brad Figg <[email protected]>
CONFIG_SERIAL_8250_MID=y CONFIG_SND_HDA_INTEL_DMI_SILENT_STREAM=y CONFIG_HSU_DMA=y Signed-off-by: Brad Figg <[email protected]>
Signed-off-by: Brad Figg <[email protected]>
…idia-fs version changed to 2.15.3~jammy Signed-off-by: Brad Figg <[email protected]>
BugLink: https://bugs.launchpad.net/bugs/2021535 ARM architecture only has 'memory', so all devices are accessed by MMIO if possible. Signed-off-by: Jammy Huang <[email protected]> Reviewed-by: Thomas Zimmermann <[email protected]> Signed-off-by: Thomas Zimmermann <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected] Acked-by: Brad Figg <[email protected]> Acked-by: Jamie Nguyen <[email protected]> (cherry picked from commit 4327a6137ed43a091d900b1ac833345d60f32228) Signed-off-by: Ian May <[email protected]>
BugLink: https://bugs.launchpad.net/bugs/1786013 Signed-off-by: Ian May <[email protected]>
Ignore: yes Signed-off-by: Ian May <[email protected]>
Signed-off-by: Ian May <[email protected]>
Copied from master Ignore: yes Signed-off-by: Ian May <[email protected]>
BugLink: https://bugs.launchpad.net/bugs/2021991 Properties: no-test-build Signed-off-by: Ian May <[email protected]>
Signed-off-by: Ian May <[email protected]>
This reverts commit 68642af. Signed-off-by: Tushar Dave <[email protected]>
This reverts commit 84f2a45. Signed-off-by: Tushar Dave <[email protected]>
Tegra QSPI controller only supports half duplex transfers. Set half duplex constrain flag. Signed-off-by: Krishna Yarlagadda <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]> (cherry picked from commit f7482d8285b638be87a594a30edaaf1341135c1a) Signed-off-by: Tushar Dave <[email protected]>
Check for non dma transfers that do not fit in FIFO has issue and skips combined sequence for Tegra234 & Tegra241 which does not have GPCDMA. Fixes: 1b8342c ("spi: tegra210-quad: combined sequence mode") Signed-off-by: Krishna Yarlagadda <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]> (cherry picked from commit 047ee71ae4f412d8819e39e4b08c588fa299cfc2) Signed-off-by: Tushar Dave <[email protected]>
Fix warn: iterator used outside loop: 'xfer'. 'xfer' variable contain invalid value in few conditions. Complete transfer within DATA phase in successful case and at the end for failed transfer. Reported-by: Dan Carpenter <[email protected]> Link:https://lore.kernel.org/all/[email protected]/ Fixes: 8777dd9 ("spi: tegra210-quad: Fix combined sequence") Signed-off-by: Krishna Yarlagadda <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]> (cherry picked from commit 2449d436681d40bc63ec2c766fd51b632270d8a7) Signed-off-by: Tushar Dave <[email protected]>
TPM specification [1] defines flow control over SPI. Client device can insert a wait state on MISO when address is transmitted by controller on MOSI. Detecting the wait state in software is only possible for full duplex controllers. For controllers that support only half- duplex, the wait state detection needs to be implemented in hardware. Add a flag SPI_TPM_HW_FLOW for TPM device to set when software flow control is not possible and hardware flow control is expected from SPI controller. Reference: [1] https://trustedcomputinggroup.org/resource/pc-client-platform-tpm -profile-ptp-specification/ Signed-off-by: Krishna Yarlagadda <[email protected]> Reviewed-by: Jerry Snitselaar <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]> (cherry picked from commit 67a142dc9eb96a5cc018e5db62390665eb5f038c) (tdave: minor conflict in include/linux/spi/spi.h) Signed-off-by: Tushar Dave <[email protected]>
Trusted Platform Module requires flow control. As defined in TPM interface specification, client would drive MISO line at same cycle as last address bit on MOSI. Tegra234 and Tegra241 QSPI controllers have TPM wait state detection feature which is enabled for TPM client devices reported in SPI device mode bits. Signed-off-by: Krishna Yarlagadda <[email protected]> Reviewed-by: Jon Hunter <[email protected]> Reviewed-by: Jerry Snitselaar <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]> (cherry picked from commit 967ca91a996f82219f2883e9e53d8e20df49025a) Signed-off-by: Tushar Dave <[email protected]>
TPM devices may insert wait state on last clock cycle of ADDR phase. For SPI controllers that support full-duplex transfers, this can be detected using software by reading the MISO line. For SPI controllers that only support half-duplex transfers, such as the Tegra QSPI, it is not possible to detect the wait signal from software. The QSPI controller in Tegra234 and Tegra241 implement hardware detection of the wait signal which can be enabled in the controller for TPM devices. The current TPM TIS driver only supports software detection of the wait signal. To support SPI controllers that use hardware to detect the wait signal, add the function tpm_tis_spi_hw_flow_transfer() and move the existing code for software based detection into a function called tpm_tis_spi_sw_flow_transfer(). SPI controllers that only support half-duplex transfers will always call tpm_tis_spi_hw_flow_transfer() because they cannot support software based detection. The bit SPI_TPM_HW_FLOW is set to indicate to the SPI controller that hardware detection is required and it is the responsibility of the SPI controller driver to determine if this is supported or not. For hardware flow control, CMD-ADDR-DATA messages are combined into a single message where as for software flow control exiting method of CMD-ADDR in a message and DATA in another is followed. Signed-off-by: Krishna Yarlagadda <[email protected]> Reviewed-by: Jarkko Sakkinen <[email protected]> Signed-off-by: Jarkko Sakkinen <[email protected]> (cherry picked from commit 394dfc8ac4b00b38d4fb781794967aa5b2eac687 linux-next) Signed-off-by: Tushar Dave <[email protected]>
Enable missing configs in the arm64 defconfig to get all devices probing on the mt8183-kukui-jacuzzi-juniper machine. The devices enabled are: ATH10K SDIO wireless adapter, Elan touchscreen, cr50 TPM, MediaTek SPI controller, JPEG video decoder, ANX7625 DSI/DPI to DP bridge (used for the internal display), MT8183 sound cards, SCP co-processor, MediaTek Global Command Engine (controlled by CMDQ driver), MediaTek Smart Voltage Scaling (SVS) engine, CCI frequency and voltage scaling, AUXADC thermal sensors. All symbols are enabled as modules with the exception of SPI, which is enabled as builtin since on some platforms like mt8195-cherry, the ChromeOS Embedded Controller is connected through SPI and it is responsible for the regulators powering the MMC controller used for the SD card, and thus SPI support is required for booting. By enabling the support for all of this machine's devices on the defconfig we make it effortless to test the relevant hardware both by developers as well as CI systems like KernelCI. Signed-off-by: Nícolas F. R. A. Prado <[email protected]> Reviewed-by: Krzysztof Kozlowski <[email protected]> Tested-by: AngeloGioacchino Del Regno <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Matthias Brugger <[email protected]> (cherry picked from commit 83f3da5 linux-next) Signed-off-by: Tushar Dave <[email protected]>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
No description provided.