-
Notifications
You must be signed in to change notification settings - Fork 5.3k
6.18: PCIe GPU testing (AMD and Intel Xe) #7113
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
Open
6by9
wants to merge
647
commits into
raspberrypi:rpi-6.18.y
Choose a base branch
from
6by9:rpi-6.18.y-pcie-gpu
base: rpi-6.18.y
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.
Open
+237,674
−5,138
Conversation
This file contains hidden or 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
|
Also just to keep the breadcrumbs going:
|
94bf012 to
899d8e0
Compare
The firmware advertises its features as a string of words separated by spaces. Ensure that feature names are only matched in their entirety. Signed-off-by: Phil Elwell <phil@raspberrypi.com>
The Cypress firmwares use "extsae" to indicate wpa_supplicant-hosted SAE/WPA3. Signed-off-by: Phil Elwell <phil@raspberrypi.com>
support sae executed in wpa_supplicant and offload 4-way handshake offload. Signed-off-by: Chien-Chia Chen <carella.chen@infineon.com> JIRA: SWWLAN-142424
TMOD_TO is the transmit-only mode that doesn't put data into the receive FIFO. Using TMOD_TO when the user doesn't want the received data saves CPU time and memory bandwidth. Signed-off-by: Phil Elwell <phil@raspberrypi.com>
TMOD_RO is the receive-only mode that doesn't require data in the transmit FIFO in order to generate clock cycles. Using TMOD_RO when the device doesn't care about the data sent to it saves CPU time and memory bandwidth. Signed-off-by: Phil Elwell <phil@raspberrypi.com>
Disabling the peripheral resets controller state which has a dangerous side-effect of disabling the DMA handshake interface while it is active. This can cause DMA channels to hang. The error recovery pathway will wait for DMA to stop and reset the chip anyway, so mask further FIFO interrupts and let the transfer finish gracefully. Signed-off-by: Jonathan Bell <jonathan@raspberrypi.com>
There's no real need to constrain MEM access widths to 32-bit (or narrower), as the DMAC is intelligent enough to size memory accesses appropriately. Wider accesses are more efficient. Similarly, MEM burst lengths don't need to be a function of DEV burst lengths - the DMAC packs/unpacks data into/from its internal channel FIFOs appropriately. Longer accesses are more efficient. However, the DMAC doesn't have complete support for unaligned accesses, and blocks are always defined in integer multiples of SRC_WIDTH, so odd source lengths or buffer alignments will prevent wide accesses being used, as before. There is an implicit requirement to limit requested DEV read burst lengths to less than the hardware's maximum configured MSIZE - otherwise RX data will be left over at the end of a block. There is no config register that reports this value, so the AXI burst length parameter is used to produce a facsimile of it. Warn if such a request arrives that doesn't respect this. Signed-off-by: Jonathan Bell <jonathan@raspberrypi.com>
Do an end-run around ASoC in lieu of not being able to easily find the associated DMA controller capabilities. Signed-off-by: Jonathan Bell <jonathan@raspberrypi.com>
Ensure the transmit FIFO has emptied before ending the transfer by dropping the TX threshold to 0 when the last byte has been pushed into the FIFO. Include a similar fix for the non-IRQ paths. See: raspberrypi#6285 Fixes: 6014649 ("spi: dw: Save bandwidth with the TMOD_TO feature") Signed-off-by: Phil Elwell <phil@raspberrypi.com>
The DW SPI interface has a 16-bit clock divider, where the bottom bit of the divisor must be 0. Limit how low the clock speed can go to prevent the clock divider from being truncated, as that could lead to a much higher clock rate than requested. Signed-off-by: Phil Elwell <phil@raspberrypi.com>
Signed-off-by: Phil Elwell <phil@raspberrypi.com>
In the same way that other subsystems support the setting of device id numbers from Device Tree aliases, allow gpiochip numbers to be derived from "gpiochip<n>" aliases. Signed-off-by: Phil Elwell <phil@raspberrypi.com>
Although later functions can handle a NULL fwnode, fwnode can't handle being passed a NULL pointer. See: raspberrypi#6305 Signed-off-by: Phil Elwell <phil@raspberrypi.com>
The check if the oscillator stop bit is set was reading from Control_1 register instead of the Seconds register. This caused the Seconds register to be incorrectly changed if bit 7 of Control_1 happens to be set. Signed-off-by: Axel Hammarberg <axel.hammarberg@gmail.com>
Add YAML device tree binding for the Sony IMX500 CMOS image sensor / CNN inference engine. Also, add a MAINTAINERS entry. Signed-off-by: Richard Oliver <richard.oliver@raspberrypi.com>
The Sony IMX500 is a stacked 1/2.3-inch CMOS digital image sensor and inbuilt AI processor with an active array CNN (Convolutional Neural Network) inference engine. The native sensor size is 4056H x 3040V, and the module also contains an in-built ISP for the CNN. The module is programmable through an I2C interface with firmware and neural network uploads being made over SPI. This driver supports imaging only. Signed-off-by: Richard Oliver <richard.oliver@raspberrypi.com> media: i2c: imx500: Inbuilt AI processor support Add support for the IMX500's inbuilt AI processor. The IMX500 program loader, AI processor firmware, DNN weights are accessed via the kernel's firmware interface on 'open' and are transferred to the IMX500 over SPI. Signed-off-by: Richard Oliver <richard.oliver@raspberrypi.com> media: i2c: imx500: Enable LED during SPI transfers The Raspberry Pi 'AI Camera' is equipped with an LED. Enable this LED during SPI transfers to indicate to the end-user that progress is being made during large tramsfers. Signed-off-by: Richard Oliver <richard.oliver@raspberrypi.com> drivers: media: imx500: Fixes for vblank control Reduce the default/max framerate of the 2x2 binned mode to 30fps. The current limit of 50fps can cause the sensor to produce corrupt frames and cause missing framing events. Also fixup the vblank control min/max/default/step paramters when setting up. Signed-off-by: Naushir Patuck <naush@raspberrypi.com> drivers: media: imx500: Simplify the vblank control init Set the VBLANK control minimum and default values to IMX500_VBLANK_MIN unconditionally everywhere. Remove the mode specific framerate_default parameter, it is now unused. Signed-off-by: Naushir Patuck <naush@raspberrypi.com> drivers: media: imx500: Enable LS correction This correction is calibrated to approx 5000K. Signed-off-by: Naushir Patuck <naush@raspberrypi.com> imx500: Fix for long exposure setup The IMX500 (unlike the IMX477/IMX708) requires two regsiters to be set for the exposure shift value to work correctly. The additional register write (which was missing) is for the integration time shift. Signed-off-by: Naushir Patuck <naush@raspberrypi.com> drivers: media: imx500: Enable sensor temperature monitoring The register needs to be disabled before loading any firmware, otherwise the upload fails for unknown reasons. Re-enable before starting the sensor streaming. Signed-off-by: Naushir Patuck <naush@raspberrypi.com> drivers: media: imx500: Add device id readback control Add a new custom control V4L2_CID_USER_GET_IMX500_DEVICE_ID to allow userland to query the device id from the IMX500 sensor eeprom. Note that this device id can only be accessed when a network firmware has been upoloaded to the device, so cannot be cached on probe. Signed-off-by: Naushir Patuck <naush@raspberrypi.com> media: i2c: imx500: pm_runtime error paths This change amends various error-paths in imx500_start_streaming() to ensure that pm_runtime refcounts do not remain erroneously incremented on failure. Signed-off-by: Richard Oliver <richard.oliver@raspberrypi.com> media: i2c: imx500: GPIO acquire/release semantics When the imx500 driver is used as part of the 'AI Camera', the poweroff state is never reached as the camera and gpio driver share a regulator. By releasing the GPIOs when they are not in use, 'AI Camera' is able to achieve a powered-down state. Signed-off-by: Richard Oliver <richard.oliver@raspberrypi.com> media: i2c: imx500: input tensor injection Input tensor injection is a debug feature that allows a user-controlled input to be passed directly to IMX500's inference engine (bypassing the in-built ISP). Three new custom controls are added to ENABLE_INJECTION before streaming begins, to provide appropriate input tensors via an INPUT_TENSOR_FD, and to provide notification of DNN results in the sensor output via INJECTION_CMP_FRM. Signed-off-by: Richard Oliver <richard.oliver@raspberrypi.com>
Add EXPORT_SYMBOL_GPL() for find_cpio_data() so that loadable modules may also parse uncompressed cpio. Signed-off-by: Richard Oliver <richard.oliver@raspberrypi.com>
The i.MX8MP makes calls on it's source device to determine the link-frequency that should be configured on the CSI2 receiver. When the source is behind a video mux, we need to pass this call through to the connected device. Map the control handler of the source device to the video-mux, essentially proxying all controls on the mux to the device which has it's link enabled. Signed-off-by: Kieran Bingham <kieran.bingham@ideasonboard.com>
system_heap.max_order=<uint> Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@igalia.com>
Add numa_policy kernel argument to allow overriding the kernel's default NUMA policy at boot time. Syntax identical to what tmpfs accepts as it's mpol argument is accepted. Some examples: numa_policy=interleave numa_policy=interleave=skip-interleave numa_policy=bind:0-3,5,7,9-15 numa_policy=bind=static:1-2 Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@igalia.com>
... Make sure CMA zones do not straddle the emulated NUMA nodes ... Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@igalia.com>
…ed allocations Add iommu_dma_numa_policy= kernel parameter which can be used to modify the NUMA allocation policy of remapped buffer allocations. Policy is only used for devices which are not associated with a NUMA node. Syntax identical to what tmpfs accepts as it's mpol argument is accepted. Some examples: iommu_dma_numa_policy=interleave iommu_dma_numa_policy=interleave=skip-interleave iommu_dma_numa_policy=bind:0-3,5,7,9-15 iommu_dma_numa_policy=bind=static:1-2 Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@igalia.com>
To help work around certain memory controller limitations or similar, a random NUMA allocation memory policy is added. Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@igalia.com>
Some apps like linpack use numa_setpolicy to disable numa, but that tends to have a significant performance hit for us. If you have a cmdline.txt setting of numa_policy (to something other than default), then lets ignore runtime changes and stick with the cmdline.txt setting. Not specifying numa_setpolicy in cmdline, or setting numa_setpolicy=default(*) will allow runtime settings to work. (*) easier to do when numa_setpolicy=interleave is set in DT. Ignore logging for the first 40 seconds as there are some expected switches during boot. Signed-off-by: Dom Cobley <popcornmix@gmail.com> Show process name in set_mempolicy() ignored message Signed-off-by: Trevor Man <tman_github@trejan.com>
As a workaround (and possibly a fix) for CPU spins observed on BCM2837, use ptep_clear_flush_young instead of ptep_test_and_clear_young inside lru_gen_look_around in order to expose PTE changes to the MMU. Note that on architectures that don't require an explicit flush, ptep_clear_flush_young just calls ptep_test_and_clear_young. Signed-off-by: Phil Elwell <phil@raspberrypi.com>
A user has reported that a card of this model from late 2021 doesn't work, so extend the date range and make it match on all card sizes. Signed-off-by: Jonathan Bell <jonathan@raspberrypi.com>
d9f2960 to
4a4ea03
Compare
Add an overlay to allow composite video to be output on GPIOs 4-11 on Raspberry Pi 5, 500, 500+ or CM5 only, with an optional 108 MHz clock on GPIO 0 and duplicate MSB on GPIO 27. Requires composite video to be enabled and DPI to be disabled. Signed-off-by: Nick Hollinghurst <nick.hollinghurst@raspberrypi.com>
This reverts commit 0b54967.
This reverts commit 336ef39.
The new concept of MMIO DMA addresses is used to indicate things with fixed addresses - hardware registers, not movable pages. As such it is reasonable to bypass the SWIOTLB mapping logic, but not any CPU<->DMA address translation that has been configured by Device Tree. Doing so will break any drives using (possibly indirectly) dma_map_resource for register addresses where ther is a non-identity mapping between CPU and DMA addresses. A good example of this is the SDHOST MMC interface on BCM283x SoCs. Fix the bug by reinstating the phys_to_dma call in the MMIO code path. N.B. The upstream SDHOST driver (drivers/mmc/host/bcm2835.c) is not affected by this bug because it pulls bus/DMA addresses directly out of Device Tree. See: raspberrypi#7136 Fixes: e53d29f ("dma-mapping: convert dma_direct_*map_page to be phys_addr_t based") Signed-off-by: Phil Elwell <phil@raspberrypi.com>
Switch the power management in the imx708 device driver to use auto- suspend with a 5s timeout. This improves mode switching time that avoids additional regulator switch-on delays and common register I2C writes. Signed-off-by: Naushir Patuck <naush@raspberrypi.com>
EMMC clock speeds are based around divisions of 52Mhz, not the 50MHz used by SD. As such, relax the "full speed" check (intended to stop any overclock whenever an operation has to be retried) so that any requested speed of 50MHz or higher will be overclocked. See: raspberrypi#7120 Signed-off-by: Phil Elwell <phil@raspberrypi.com>
EMMC clock speeds are based around divisions of 52Mhz, not the 50MHz used by SD. As such, relax the "full speed" check (intended to stop any overclock whenever an operation has to be retried) so that any requested speed of 50MHz or higher will be overclocked. Signed-off-by: Phil Elwell <phil@raspberrypi.com>
Remove the need for the user to know the limitations of this PWM implementation by adjusting configuration requests to be the closest acceptable value. Add a get_state method so that the actual values can be queried. Signed-off-by: Phil Elwell <phil@raspberrypi.com>
Correct the set_period method to pass (period - 1), as required by the PIO state machine. Signed-off-by: Phil Elwell <phil@raspberrypi.com>
Signed-off-by: Waveshare_Team <support@waveshare.com>
Signed-off-by: Waveshare_Team <support@waveshare.com>
The non-pi5 variant of tc358743 needs to update the compatible of csi0 rather than csi1 if the cam0 override is used, otherwise it gets loaded in Media Controller mode. Signed-off-by: Dave Stevenson <dave.stevenson@raspberrypi.com>
This reverts commit 19a2aa9.
Device Tree properties ranges and dma-ranges describe address mappings required when moving between buses. Ensure this translation happens when mapping MMIO addresses for DMA accesses. This commit replaces another downstream commit that no longer applies as of 6.18: dma-direct: take dma-ranges/offsets into account in resource mapping Signed-off-by: Phil Elwell <phil@raspberrypi.com>
Various PCIe controllers on ARM64 platforms don't support cache snooping, which leads to numerous issues when attempting to use PCIe graphics cards. Switching ttm_prot_from_caching to return pgprot_dmacoherent for ttm_cached pages solves the issue, albeit with a performance hit. There is a second check in ttm_prot_from_caching that also needs updating. Signed-off-by: Yang Bo <bo.yang@smail.nju.edu.cn> Signed-off-by: Dave Stevenson <dave.stevenson@raspberrypi.com>
Signed-off-by: Dave Stevenson <dave.stevenson@raspberrypi.com>
Taken from https://github.com/chimera-linux/cports/blob/master/main/linux-stable/patches/xe-nonx86.patch Signed-off-by: Dave Stevenson <dave.stevenson@raspberrypi.com>
Signed-off-by: Dave Stevenson <dave.stevenson@raspberrypi.com>
Signed-off-by: Dave Stevenson <dave.stevenson@raspberrypi.com>
2ef2bea to
b17e55e
Compare
Contributor
Author
|
Branch rebased to keep it relevant. I've just noted https://lore.kernel.org/dri-devel/20250613-upstream-xe-non-4k-v2-v2-0-934f82249f8a@aosc.io/ I don't see it having been merged, so at some point it would be useful to test it as the thread appears to have stalled. |
d003d86 to
dff72a6
Compare
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.
PR to create CI artifacts supporting AMD and Intel Xe GPUs.