aboutsummaryrefslogtreecommitdiff
path: root/drivers
AgeCommit message (Collapse)AuthorFilesLines
2024-06-11Merge tag 'drm-xe-next-2024-06-06' of ↵Dave Airlie158-1775/+7993
https://gitlab.freedesktop.org/drm/xe/kernel into drm-next UAPI Changes: - Expose the L3 bank mask (Francois) Cross-subsystem Changes: - Update Xe driver maintainers (Oded) Display (i915): - Add missing include to intel_vga.c (Michal Wajdeczko) Driver Changes: - Fix Display (xe-only) detection for ADL-N (Lucas) - Runtime PM fixes that enabled PC-10 and D3Cold (Francois, Rodrigo) - Fix unexpected silent drm backmerge issues (Thomas) - More (a lot more) preparation for SR-IOV support (Michal Wajdeczko) - Devcoredump fixes and improvements (Jose, Tejas, Matt Brost) - Introduce device 'wedged' state (Rodrigo) - Improve debug and info messages (Michal Wajdeczko, Rodrigo, Nirmoy) - Adding or fixing workarounds (Tejas, Shekhar, Lucas, Bommu) - Check result of drmm_mutex_init (Michal Wajdeczko) - Enlarge the critical dma fence area for preempt fences (Matt Auld) - Prevent UAF in VM's rebind work (Matt Auld) - GuC submit related clean-ups and fixes (Matt Brost, Himal, Jonathan, Niranjana) - Prefer local helpers to perform dma reservation locking (Himal) - Spelling and typo fixes (Colin, Francois) - Prep patches for 1 job per VM bind IOCTL (no uapi change yet) (Matt Brost) - Remove uninitialized end var from xe_gt_tlb_invalidation_range (Nirmoy) - GSC related changes targeting LNL support (Daniele) - Fix assert in L3 bank mask generation (Francois) - Perform dma_map when moving system buffer objects to TT (Thomas) - Add helpers for manipulating macro arguments (Michal Wajdeczko) - Refactor default device atomic settings (Nirmoy) - Add debugfs node to dump mocs (Janga) - Use ordered WQ for G2H handler (Matt Brost) - Clean up and fixes in header includes (Michal Wajdeczko) - Prefer flexible-array over deprecated zero-lenght ones (Lucas) - Add Indirect Ring State support (Niranjana) - Fix UBSAN shift-out-of-bounds failure (Shuicheng) - HWMon fixes and additions (Karthik) - Clean-up refactor around probe init functions (Lucas, Michal Wajdeczko) - Fix PCODE init function (Himal) - Only use reserved BCS instances for usm migrate exec queue (Matt Brost) - Only zap PTEs as needed (Matt Brost) - Per client usage info (Lucas) - Core hotunplug improvements converting stuff towards devm (Matt Auld) - Don't emit false error if running in execlist mode (Michal Wajdeczko) - Remove unused struct (Dr. David) - Support/debug for slow GuC loads (John Harrison) - Decouple job seqno and lrc seqno (Matt Brost) - Allow migrate vm gpu submissions from reclaim context (Thomas) - Rename drm-client running time to run_ticks and fix a UAF (Umesh) - Check empty pinned BO list with lock held (Nirmoy) - Drop undesired prefix from the platform name (Michal Wajdeczko) - Remove unwanted mutex locking on xe file close (Niranjana) - Replace format-less snprintf() with strscpy() (Arnd) - Other general clean-ups on registers definitions and function names (Michal Wajdeczko) - Add kernel-doc to some xe_lrc interfaces (Niranajana) - Use missing lock in relay_needs_worker (Nirmoy) - Drop redundant W=1 warnings from Makefile (Jani) - Simplify if condition in preempt fences code (Thorsten) - Flush engine buffers before signalling user fence on all engines (Andrzej) - Don't overmap identity VRAM mapping (Matt Brost) - Do not dereference NULL job->fence in trace points (Matt Brost) - Add synchronous gt reset debugfs (Jonathan) - Xe gt_idle fixes (Riana) Signed-off-by: Dave Airlie <[email protected]> From: Rodrigo Vivi <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2024-06-10regulator: core: Fix modpost error "regulator_get_regmap" undefinedBiju Das1-0/+1
Fix the modpost error "regulator_get_regmap" undefined by adding export symbol. Fixes: 04eca28cde52 ("regulator: Add helpers for low-level register access") Reported-by: kernel test robot <[email protected]> Closes: https://lore.kernel.org/oe-kbuild-all/[email protected] Signed-off-by: Biju Das <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]>
2024-06-10PCI: switchtec: Make switchtec_class constantGreg Kroah-Hartman2-9/+9
Now that the driver core allows for struct class to be in read-only memory, we should make all 'class' structures declared at build time placing them into read-only memory, instead of having to be dynamically allocated at runtime. Link: https://lore.kernel.org/r/2024061053-online-unwound-b173@gregkh Signed-off-by: Greg Kroah-Hartman <[email protected]> Signed-off-by: Bjorn Helgaas <[email protected]> Reviewed-by: Dave Jiang <[email protected]> Reviewed-By: Logan Gunthorpe <[email protected]> Cc: Kurt Schwemmer <[email protected]> Cc: Jon Mason <[email protected]> Cc: Allen Hubbe <[email protected]>
2024-06-10md/raid1: don't free conf on raid0_run failureChristoph Hellwig1-11/+3
The core md code calls the ->free method which already frees conf. Fixes: 07f1a6850c5d ("md/raid1: fail run raid1 array when active disk less than one") Signed-off-by: Christoph Hellwig <[email protected]> Signed-off-by: Song Liu <[email protected]> Link: https://lore.kernel.org/r/[email protected]
2024-06-10md/raid0: don't free conf on raid0_run failureChristoph Hellwig1-16/+5
The core md code calls the ->free method which already frees conf. Fixes: 0c031fd37f69 ("md: Move alloc/free acct bioset in to personality") Signed-off-by: Christoph Hellwig <[email protected]> Reviewed-by: Yu Kuai <[email protected]> Signed-off-by: Song Liu <[email protected]> Link: https://lore.kernel.org/r/[email protected]
2024-06-10md: make md_flush_request() more readableLi Nan1-15/+13
Setting bio to NULL and checking 'if(!bio)' is redundant and looks strange, just consolidate them into one condition. There are no functional changes. Suggested-by: Christoph Hellwig <[email protected]> Signed-off-by: Li Nan <[email protected]> Reviewed-by: Christoph Hellwig <[email protected]> Signed-off-by: Song Liu <[email protected]> Link: https://lore.kernel.org/r/[email protected]
2024-06-10md: fix deadlock between mddev_suspend and flush bioLi Nan1-11/+15
Deadlock occurs when mddev is being suspended while some flush bio is in progress. It is a complex issue. T1. the first flush is at the ending stage, it clears 'mddev->flush_bio' and tries to submit data, but is blocked because mddev is suspended by T4. T2. the second flush sets 'mddev->flush_bio', and attempts to queue md_submit_flush_data(), which is already running (T1) and won't execute again if on the same CPU as T1. T3. the third flush inc active_io and tries to flush, but is blocked because 'mddev->flush_bio' is not NULL (set by T2). T4. mddev_suspend() is called and waits for active_io dec to 0 which is inc by T3. T1 T2 T3 T4 (flush 1) (flush 2) (third 3) (suspend) md_submit_flush_data mddev->flush_bio = NULL; . . md_flush_request . mddev->flush_bio = bio . queue submit_flushes . . . . md_handle_request . . active_io + 1 . . md_flush_request . . wait !mddev->flush_bio . . . . mddev_suspend . . wait !active_io . . . submit_flushes . queue_work md_submit_flush_data . //md_submit_flush_data is already running (T1) . md_handle_request wait resume The root issue is non-atomic inc/dec of active_io during flush process. active_io is dec before md_submit_flush_data is queued, and inc soon after md_submit_flush_data() run. md_flush_request active_io + 1 submit_flushes active_io - 1 md_submit_flush_data md_handle_request active_io + 1 make_request active_io - 1 If active_io is dec after md_handle_request() instead of within submit_flushes(), make_request() can be called directly intead of md_handle_request() in md_submit_flush_data(), and active_io will only inc and dec once in the whole flush process. Deadlock will be fixed. Additionally, the only difference between fixing the issue and before is that there is no return error handling of make_request(). But after previous patch cleaned md_write_start(), make_requst() only return error in raid5_make_request() by dm-raid, see commit 41425f96d7aa ("dm-raid456, md/raid456: fix a deadlock for dm-raid456 while io concurrent with reshape)". Since dm always splits data and flush operation into two separate io, io size of flush submitted by dm always is 0, make_request() will not be called in md_submit_flush_data(). To prevent future modifications from introducing issues, add WARN_ON to ensure make_request() no error is returned in this context. Fixes: fa2bbff7b0b4 ("md: synchronize flush io with array reconfiguration") Signed-off-by: Li Nan <[email protected]> Signed-off-by: Song Liu <[email protected]> Link: https://lore.kernel.org/r/[email protected]
2024-06-10md: change the return value type of md_write_start to voidLi Nan5-17/+8
Commit cc27b0c78c79 ("md: fix deadlock between mddev_suspend() and md_write_start()") aborted md_write_start() with false when mddev is suspended, which fixed a deadlock if calling mddev_suspend() with holding reconfig_mutex(). Since mddev_suspend() now includes lockdep_assert_not_held(), it no longer holds the reconfig_mutex. This makes previous abort unnecessary. Now, remove unnecessary abort and change function return value to void. Signed-off-by: Li Nan <[email protected]> Reviewed-by: Yu Kuai <[email protected]> Signed-off-by: Song Liu <[email protected]> Link: https://lore.kernel.org/r/[email protected]
2024-06-10drm/xe: Check valid domain is passed in xe_force_wake_refHimal Prasad Ghimiray1-1/+1
Assert domain is not XE_FORCEWAKE_ALL. v2 - use domain != XE_FORCEWAKE_ALL (Michal) v3 - Fix commit description. Cc: Michal Wajdeczko <[email protected]> Cc: Rodrigo Vivi <[email protected]> Cc: Lucas De Marchi <[email protected]> Cc: Badal Nilawar <[email protected]> Signed-off-by: Himal Prasad Ghimiray <[email protected]> Reviewed-by: Michal Wajdeczko <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected] Signed-off-by: Rodrigo Vivi <[email protected]>
2024-06-10drm/xe: Ensure caller uses sole domain for xe_force_wake_assert_heldHimal Prasad Ghimiray1-0/+11
xe_force_wake_assert_held() is designed to confirm a particular forcewake domain's wakefulness; it doesn't verify the wakefulness of multiple domains. Make sure the caller doesn't input multiple domains(XE_FORCEWAKE_ALL) as a parameter. v2 - use domain != XE_FORCEWAKE_ALL (Michal) v3 - Add kernel-doc Cc: Michal Wajdeczko <[email protected]> Cc: Rodrigo Vivi <[email protected]> Cc: Lucas De Marchi <[email protected]> Cc: Badal Nilawar <[email protected]> Signed-off-by: Himal Prasad Ghimiray <[email protected]> Reviewed-by: Michal Wajdeczko <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected] Signed-off-by: Rodrigo Vivi <[email protected]>
2024-06-10drm/amdgpu: Fix the BO release clear memory warningArunpravin Paneer Selvam2-2/+1
This happens when the amdgpu_bo_release_notify running before amdgpu_ttm_set_buffer_funcs_status set the buffer funcs to enabled. check the buffer funcs enablement before calling the fill buffer memory. v2:(Christian) - Apply it only for GEM buffers and since GEM buffers are only allocated/freed while the driver is loaded we never run into the issue to clear with buffer funcs disabled. v3:(Mario) - drop the stable tag as this will presumably go into a -fixes PR for 6.10 Log snip: *ERROR* Trying to clear memory with ring turned off. RIP: 0010:amdgpu_bo_release_notify+0x201/0x220 [amdgpu] Fixes: a68c7eaa7a8f ("drm/amdgpu: Enable clear page functionality") Signed-off-by: Arunpravin Paneer Selvam <[email protected]> Reviewed-by: Christian König <[email protected]> Tested-by: Mikhail Gavrilov <[email protected]> Tested-by: Richard Gong <[email protected]> Suggested-by: Christian König <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2024-06-10rpmsg: char: add missing MODULE_DESCRIPTION() macroJeff Johnson1-0/+1
make allmodconfig && make W=1 C=1 reports: WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/rpmsg/rpmsg_char.o Add the missing invocation of the MODULE_DESCRIPTION() macro. Signed-off-by: Jeff Johnson <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mathieu Poirier <[email protected]>
2024-06-10md: do not delete safemode_timer in mddev_suspendLi Nan1-1/+0
The deletion of safemode_timer in mddev_suspend() is redundant and potentially harmful now. If timer is about to be woken up but gets deleted, 'in_sync' will remain 0 until the next write, causing array to stay in the 'active' state instead of transitioning to 'clean'. Commit 0d9f4f135eb6 ("MD: Add del_timer_sync to mddev_suspend (fix nasty panic))" introduced this deletion for dm, because if timer fired after dm is destroyed, the resource which the timer depends on might have been freed. However, commit 0dd84b319352 ("md: call __md_stop_writes in md_stop") added __md_stop_writes() to md_stop(), which is called before freeing resource. Timer is deleted in __md_stop_writes(), and the origin issue is resolved. Therefore, delete safemode_timer can be removed safely now. Signed-off-by: Li Nan <[email protected]> Reviewed-by: Yu Kuai <[email protected]> Signed-off-by: Song Liu <[email protected]> Link: https://lore.kernel.org/r/[email protected]
2024-06-10hwmon: (asus-ec-sensors) add ProArt X670E-CREATOR WIFIEugene Shalygin1-0/+10
Provided and tested by a user in a GitHub PR [1]. [1] https://github.com/zeule/asus-ec-sensors/pull/56 Signed-off-by: Eugene Shalygin <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Guenter Roeck <[email protected]>
2024-06-10hwmon: (spd5118) Add configuration option for auto-detectionGuenter Roeck2-2/+21
With SPD5118 chip detection for the most part handled by the i2c-smbus core using DMI information, the spd5118 driver no longer needs to auto-detect spd5118 compliant chips. Auto-detection by the driver is still needed on systems with no DMI support or on systems with more than eight DIMMs and can not be removed entirely. However, it affects boot time and introduces the risk of mis-identifying chips. Add configuration option to be able to disable it on systems where chip detection is handled outside the driver. Cc: Wolfram Sang <[email protected]> Reviewed-by: Thomas Weißschuh <[email protected]> Tested-by: Armin Wolf <[email protected]> Signed-off-by: Guenter Roeck <[email protected]>
2024-06-10i2c: smbus: Support DDR5 and LPDDR5 SPD EEPROMsGuenter Roeck1-1/+5
Detect (LP)DDR5 memory and instantiate the SPD5118 driver automatically. Suggested-by: Thomas Weißschuh <[email protected]> Cc: Wolfram Sang <[email protected]> Acked-by: Wolfram Sang <[email protected]> Reviewed-by: Armin Wolf <[email protected]> Reviewed-by: Thomas Weißschuh <[email protected]> Signed-off-by: Guenter Roeck <[email protected]>
2024-06-10hwmon: (spd5118) Add support for reading SPD dataGuenter Roeck1-4/+142
Add support for reading SPD NVMEM data from SPD5118 (Jedec JESD300) compliant memory modules. NVMEM write operation is not supported. NVMEM support is optional. If CONFIG_NVMEM is disabled, the driver will still instantiate but not provide NVMEM attribute files. Reviewed-by: Thomas Weißschuh <[email protected]> Tested-by: Armin Wolf <[email protected]> Signed-off-by: Guenter Roeck <[email protected]>
2024-06-10hwmon: (spd5118) Add suspend/resume supportGuenter Roeck1-0/+39
Add suspend/resume support to ensure that limit and configuration registers are updated and synchronized after a suspend/resume cycle. Cc: Armin Wolf <[email protected]> Cc: Stephen Horvath <[email protected]> Reviewed-by: Thomas Weißschuh <[email protected]> Tested-by: Stephen Horvath <[email protected]> Tested-by: Armin Wolf <[email protected]> Signed-off-by: Guenter Roeck <[email protected]>
2024-06-10hwmon: Add support for SPD5118 compliant temperature sensorsGuenter Roeck3-0/+494
Add support for SPD5118 (Jedec JESD300) compliant temperature sensors. Such sensors are typically found on DDR5 memory modules. Cc: René Rebe <[email protected]> Cc: Thomas Weißschuh <[email protected]> Reviewed-by: Thomas Weißschuh <[email protected]> Tested-by: Thomas Weißschuh <[email protected]> Tested-by: Stephen Horvath <[email protected]> Tested-by: Armin Wolf <[email protected]> Signed-off-by: Guenter Roeck <[email protected]>
2024-06-10regulator: add missing MODULE_DESCRIPTION() macroJeff Johnson4-0/+4
On x86, make allmodconfig && make W=1 C=1 reports: WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/regulator/da9121-regulator.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/regulator/max20411-regulator.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/regulator/rt4831-regulator.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/regulator/tps6286x-regulator.o Add the missing invocations of the MODULE_DESCRIPTION() macro. Reviewed-by: AngeloGioacchino Del Regno <[email protected]> Signed-off-by: Jeff Johnson <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]>
2024-06-10drm/bridge: it6505: update usleep_range for RC circuit charge timeKuro Chung1-1/+1
The spec of timing between IVDD/OVDD and SYSRTEN is 10ms, but SYSRSTN RC circuit need at least 25ms for rising time, update for match spec Signed-off-by: Kuro Chung <[email protected]> Signed-off-by: Hermes Wu <[email protected]> Reviewed-by: Robert Foss <[email protected]> Signed-off-by: Robert Foss <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2024-06-10drm/bridge: samsung-dsim: Fix porch calcalcuation roundingAdam Ford1-0/+21
The VFP, HBP, and HSA are divided between the available lanes if there is more than one lane. For certain timings and lane configurations, the HFP may not be evenly divisible. If the HFP is rounded down, it ends up being too small which can cause some monitors to not sync properly. In these instances, adjust htotal and hsync to round the HFP up, and recalculate the htotal. This allows 720P-60 to operation on an i.MX8MP with a four-lane configuration. Tested-by: Frieder Schrempf <[email protected]> # Kontron BL i.MX8MM with HDMI monitor Signed-off-by: Adam Ford <[email protected]> Signed-off-by: Robert Foss <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2024-06-10drm/bridge: samsung-dsim: Set P divider based on min/max of fin pllAdam Ford1-2/+2
The P divider should be set based on the min and max values of the fin pll which may vary between different platforms. These ranges are defined per platform, but hard-coded values were used instead which resulted in a smaller range available on the i.MX8M[MNP] than what was possible. As noted by Frieder, there are descripencies between the reference manuals of the Mini, Nano and Plus, so I reached out to my NXP rep and got the following response regarding the varing notes in the documentation. "Yes it is definitely wrong, the one that is part of the NOTE in MIPI_DPHY_M_PLLPMS register table against PMS_P, PMS_M and PMS_S is not correct. I will report this to Doc team, the one customer should be take into account is the Table 13-40 DPHY PLL Parameters and the Note above." With this patch, the clock rates now match the values used in NXP's downstream kernel. Fixes: 846307185f0f ("drm/bridge: samsung-dsim: update PLL reference clock") Signed-off-by: Adam Ford <[email protected]> Reviewed-by: Frieder Schrempf <[email protected]> Tested-by: Frieder Schrempf <[email protected]> Reviewed-by: Marek Vasut <[email protected]> Tested-by: Marek Szyprowski <[email protected]> Signed-off-by: Robert Foss <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2024-06-10drm/bridge: tc358767: Check if fully initialized before signalling HPD event ↵Marek Vasut1-1/+1
via IRQ Make sure the connector is fully initialized before signalling any HPD events via drm_kms_helper_hotplug_event(), otherwise this may lead to NULL pointer dereference. Signed-off-by: Marek Vasut <[email protected]> Reviewed-by: Robert Foss <[email protected]> Signed-off-by: Robert Foss <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2024-06-10drm/bridge: tc358767: Fix comment in tc_edp_mode_validMarek Vasut1-1/+1
Fix comment copy-paste error in tc_edp_mode_valid(), this function is validating DP/eDP clock, not DPI clock frequency. Update the comment to match. No functional change. Signed-off-by: Marek Vasut <[email protected]> Reviewed-by: Robert Foss <[email protected]> Signed-off-by: Robert Foss <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2024-06-10net/mlx5e: Fix features validation check for tunneled UDP (non-VXLAN) packetsGal Pressman1-2/+1
Move the vxlan_features_check() call to after we verified the packet is a tunneled VXLAN packet. Without this, tunneled UDP non-VXLAN packets (for ex. GENENVE) might wrongly not get offloaded. In some cases, it worked by chance as GENEVE header is the same size as VXLAN, but it is obviously incorrect. Fixes: e3cfc7e6b7bd ("net/mlx5e: TX, Add geneve tunnel stateless offload support") Signed-off-by: Gal Pressman <[email protected]> Reviewed-by: Dragos Tatulea <[email protected]> Signed-off-by: Tariq Toukan <[email protected]> Reviewed-by: Wojciech Drewek <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2024-06-10geneve: Fix incorrect inner network header offset when innerprotoinherit is setGal Pressman1-4/+6
When innerprotoinherit is set, the tunneled packets do not have an inner Ethernet header. Change 'maclen' to not always assume the header length is ETH_HLEN, as there might not be a MAC header. This resolves issues with drivers (e.g. mlx5, in mlx5e_tx_tunnel_accel()) who rely on the skb inner network header offset to be correct, and use it for TX offloads. Fixes: d8a6213d70ac ("geneve: fix header validation in geneve[6]_xmit_skb") Signed-off-by: Gal Pressman <[email protected]> Signed-off-by: Tariq Toukan <[email protected]> Reviewed-by: Wojciech Drewek <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2024-06-10net: dsa: hellcreek: Replace kernel.h with what is usedAndy Shevchenko1-3/+5
kernel.h is included solely for some other existing headers. Include them directly and get rid of kernel.h. While at it, sort headers alphabetically for easier maintenance. Signed-off-by: Andy Shevchenko <[email protected]> Reviewed-by: Kurt Kanzenbach <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2024-06-10net dsa: qca8k: fix usages of device_get_named_child_node()Andy Shevchenko1-2/+10
The documentation for device_get_named_child_node() mentions this important point: " The caller is responsible for calling fwnode_handle_put() on the returned fwnode pointer. " Add fwnode_handle_put() to avoid leaked references. Fixes: 1e264f9d2918 ("net: dsa: qca8k: add LEDs basic support") Reviewed-by: Simon Horman <[email protected]> Signed-off-by: Andy Shevchenko <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2024-06-10drm/bridge: Drop drm_bridge_chain_mode_fixupSam Ravnborg1-37/+0
There are no users left of drm_bridge_chain_mode_fixup() and we do not want to have this function available, so drop it. Signed-off-by: Sam Ravnborg <[email protected]> Reviewed-by: Maxime Ripard <[email protected]> Reviewed-by: Laurent Pinchart <[email protected]> Cc: Laurent Pinchart <[email protected]> Cc: Maarten Lankhorst <[email protected]> Cc: Maxime Ripard <[email protected]> Cc: Thomas Zimmermann <[email protected]> Cc: David Airlie <[email protected]> Cc: Daniel Vetter <[email protected]> Signed-off-by: Robert Foss <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2024-06-10drm/mediatek: Drop chain_mode_fixup call in mode_valid()Sam Ravnborg1-11/+0
The mode_valid implementation had a call to drm_bridge_chain_mode_fixup() which would be wrong as the mode_valid is not allowed to change anything - only to validate the mode. As the next bridge is often/always a connector the call had no effect anyway. So drop it. From the git history I could see this call was included in the original version of the driver so there was no help there to find out why it was added in the first place. But a lot has changed since the initial driver were added and is seems safe to remove the call now. v4: - Link to v3: https://lore.kernel.org/dri-devel/[email protected]/ - Rebase, and added acks/rb v3: - Link to v2: https://lore.kernel.org/dri-devel/[email protected]/ v2: - Link to v1: https://lore.kernel.org/dri-devel/[email protected]/ Signed-off-by: Sam Ravnborg <[email protected]> Reviewed-by: Maxime Ripard <[email protected]> Reviewed-by: Laurent Pinchart <[email protected]> Acked-by: Chun-Kuang Hu <[email protected]> Cc: Chun-Kuang Hu <[email protected]> Cc: Philipp Zabel <[email protected]> Cc: Matthias Brugger <[email protected]> Cc: Dafna Hirschfeld <[email protected]> Cc: [email protected] Cc: [email protected] Signed-off-by: Robert Foss <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2024-06-10drm/panic: Add a kmsg panic screenJocelyn Falempe2-10/+112
Add a kmsg option, which will display the last lines of kmsg, and should be similar to fbcon. Add a drm.panic_screen module parameter, so you can choose between the different panic screens available. two options currently, but more will be added later: * "user": a short message telling the user to reboot the machine. * "kmsg": fill the screen with the last lines of kmsg. You can even change it at runtime by writing to /sys/module/drm/parameters/panic_screen v2: * Use module parameter instead of Kconfig choice (Javier Martinez Canillas) v3: * Add help for module parameter usage in Kconfig (Javier Martivez Canillas) * Fix use of font->height before checking it isn't null. (kernel test robot, Dan Carpenter) Signed-off-by: Jocelyn Falempe <[email protected]> Reviewed-by: Javier Martinez Canillas <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2024-06-10drm/panic: Add a set_pixel() callback to drm_scanout_bufferJocelyn Falempe1-44/+76
This allows drivers to draw the pixel, and handle tiling, or specific color formats. v2: * Use fg_color for blit() functions (Javier Martinez Canillas) Signed-off-by: Jocelyn Falempe <[email protected]> Reviewed-by: Javier Martinez Canillas <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2024-06-10drm/panic: only draw the foreground color in drm_panic_blit()Jocelyn Falempe1-36/+31
The whole framebuffer is cleared, so it's useless to rewrite the background colored pixels. It allows to simplify the drawing functions, and prepare the work for the set_pixel() callback. v2: * keep fg16/fg24/fg32 as variable name for the blit function. * add drm_panic_is_pixel_fg() to avoid code duplication. both suggested by Javier Martinez Canillas Signed-off-by: Jocelyn Falempe <[email protected]> Reviewed-by: Javier Martinez Canillas <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2024-06-10spi: add missing MODULE_DESCRIPTION() macrosJeff Johnson6-0/+6
make allmodconfig && make W=1 C=1 reports: WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/spi/spi-altera-core.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/spi/spi-fsl-lib.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/spi/spi-omap2-mcspi.o WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/spi/spi-qup.o Add the missing invocations of the MODULE_DESCRIPTION() macro. Signed-off-by: Jeff Johnson <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]>
2024-06-10spi: meson-spicc: set SPI clock flag CLK_SET_RATE_PARENTXianwei Zhao1-6/+10
Add SPI clock flag CLK_SET_RATE_PARENT for using pclk as parent clock. This gives SPI more flexibility in frequency selection. Signed-off-by: Xianwei Zhao <[email protected]> Signed-off-by: Sunny Luo <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]>
2024-06-10spi: Rework per message DMA mapped flag to be per transferAndy Shevchenko2-47/+28
The granularity of DMA mappings is transfer and moreover, the direction is also important as it can be unidirect. The current cur_msg_mapped flag doesn't fit well the DMA mapping and syncing calls and we have tons of checks around on top of it. So, instead of doing that rework the code to use per transfer per direction flag to show if it's DMA mapped or not. Signed-off-by: Andy Shevchenko <[email protected]> Tested-by: Neil Armstrong <[email protected]> # on SM8650-QRD Link: https://lore.kernel.org/r/[email protected] Reviewed-by: Serge Semin <[email protected]> Tested-by: Nícolas F. R. A. Prado <[email protected]> Signed-off-by: Mark Brown <[email protected]>
2024-06-10spi: qup: Use new spi_xfer_is_dma_mapped() helperAndy Shevchenko1-5/+4
Replace a few lines of code by calling a spi_xfer_is_dma_mapped() helper. Signed-off-by: Andy Shevchenko <[email protected]> Tested-by: Neil Armstrong <[email protected]> # on SM8650-QRD Link: https://lore.kernel.org/r/[email protected] Reviewed-by: Bryan O'Donoghue <[email protected]> Reviewed-by: Serge Semin <[email protected]> Tested-by: Nícolas F. R. A. Prado <[email protected]> Signed-off-by: Mark Brown <[email protected]>
2024-06-10spi: pci1xxxx: Use new spi_xfer_is_dma_mapped() helperAndy Shevchenko1-2/+3
Replace a few lines of code by calling a spi_xfer_is_dma_mapped() helper. Signed-off-by: Andy Shevchenko <[email protected]> Tested-by: Neil Armstrong <[email protected]> # on SM8650-QRD Link: https://lore.kernel.org/r/[email protected] Reviewed-by: Serge Semin <[email protected]> Tested-by: Nícolas F. R. A. Prado <[email protected]> Signed-off-by: Mark Brown <[email protected]>
2024-06-10spi: pxa2xx: Use new spi_xfer_is_dma_mapped() helperAndy Shevchenko1-4/+2
Replace a few lines of code by calling a spi_xfer_is_dma_mapped() helper. Signed-off-by: Andy Shevchenko <[email protected]> Tested-by: Neil Armstrong <[email protected]> # on SM8650-QRD Link: https://lore.kernel.org/r/[email protected] Reviewed-by: Serge Semin <[email protected]> Tested-by: Nícolas F. R. A. Prado <[email protected]> Signed-off-by: Mark Brown <[email protected]>
2024-06-10spi: omap2-mcspi: Use new spi_xfer_is_dma_mapped() helperAndy Shevchenko1-4/+4
Replace a few lines of code by calling a spi_xfer_is_dma_mapped() helper. Signed-off-by: Andy Shevchenko <[email protected]> Tested-by: Neil Armstrong <[email protected]> # on SM8650-QRD Link: https://lore.kernel.org/r/[email protected] Reviewed-by: Serge Semin <[email protected]> Tested-by: Nícolas F. R. A. Prado <[email protected]> Signed-off-by: Mark Brown <[email protected]>
2024-06-10spi: ingenic: Use new spi_xfer_is_dma_mapped() helperAndy Shevchenko1-2/+2
Replace a few lines of code by calling a spi_xfer_is_dma_mapped() helper. Signed-off-by: Andy Shevchenko <[email protected]> Tested-by: Neil Armstrong <[email protected]> # on SM8650-QRD Link: https://lore.kernel.org/r/[email protected] Reviewed-by: Serge Semin <[email protected]> Tested-by: Nícolas F. R. A. Prado <[email protected]> Signed-off-by: Mark Brown <[email protected]>
2024-06-10spi: dw: Use new spi_xfer_is_dma_mapped() helperAndy Shevchenko1-2/+2
Replace a few lines of code by calling a spi_xfer_is_dma_mapped() helper. Signed-off-by: Andy Shevchenko <[email protected]> Reviewed-by: Serge Semin <[email protected]> Tested-by: Neil Armstrong <[email protected]> # on SM8650-QRD Link: https://lore.kernel.org/r/[email protected] Tested-by: Nícolas F. R. A. Prado <[email protected]> Signed-off-by: Mark Brown <[email protected]>
2024-06-10spi: Introduce internal spi_xfer_is_dma_mapped() helperAndy Shevchenko1-0/+8
There are few drivers that use the same pattern to check if the transfer is DMA mapped or not. Provide a helper. Signed-off-by: Andy Shevchenko <[email protected]> Tested-by: Neil Armstrong <[email protected]> # on SM8650-QRD Link: https://lore.kernel.org/r/[email protected] Reviewed-by: Bryan O'Donoghue <[email protected]> Reviewed-by: Serge Semin <[email protected]> Tested-by: Nícolas F. R. A. Prado <[email protected]> Signed-off-by: Mark Brown <[email protected]>
2024-06-10soundwire: slave: simplify code with acpi_get_local_u64_address()Pierre-Louis Bossart1-9/+4
Now we have a helper so there's no need to open-code. Signed-off-by: Pierre-Louis Bossart <[email protected]> Reviewed-by: Péter Ujfalusi <[email protected]> Reviewed-by: Bard Liao <[email protected]> Acked-by: Vinod Koul <[email protected]> Reviewed-by: Takashi Iwai <[email protected]> Reviewed-by: Andy Shevchenko <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]>
2024-06-10ACPI: utils: introduce acpi_get_local_u64_address()Pierre-Louis Bossart1-3/+13
The ACPI _ADR is a 64-bit value. We changed the definitions in commit ca6f998cf9a2 ("ACPI: bus: change _ADR representation to 64 bits") but some helpers still assume the value is a 32-bit value. This patch adds a new helper to extract the full 64-bits. The existing 32-bit helper is kept for backwards-compatibility and cases where the _ADR is known to fit in a 32-bit value. Signed-off-by: Pierre-Louis Bossart <[email protected]> Reviewed-by: Péter Ujfalusi <[email protected]> Reviewed-by: Bard Liao <[email protected]> Acked-by: Rafael J. Wysocki <[email protected]> Reviewed-by: Takashi Iwai <[email protected]> Reviewed-by: Andy Shevchenko <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]>
2024-06-10drm/bridge/panel: Fix runtime warning on panel bridge releaseAdam Miotk1-2/+5
Device managed panel bridge wrappers are created by calling to drm_panel_bridge_add_typed() and registering a release handler for clean-up when the device gets unbound. Since the memory for this bridge is also managed and linked to the panel device, the release function should not try to free that memory. Moreover, the call to devm_kfree() inside drm_panel_bridge_remove() will fail in this case and emit a warning because the panel bridge resource is no longer on the device resources list (it has been removed from there before the call to release handlers). Fixes: 67022227ffb1 ("drm/bridge: Add a devm_ allocator for panel bridge.") Signed-off-by: Adam Miotk <[email protected]> Signed-off-by: Maxime Ripard <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2024-06-10drm/komeda: check for error-valued pointerAmjad Ouled-Ameur1-1/+1
komeda_pipeline_get_state() may return an error-valued pointer, thus check the pointer for negative or null value before dereferencing. Fixes: 502932a03fce ("drm/komeda: Add the initial scaler support for CORE") Signed-off-by: Amjad Ouled-Ameur <[email protected]> Signed-off-by: Maxime Ripard <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
2024-06-10Merge topic branches 'clkdev' and 'fixes' into for-linusRussell King (Oracle)8398-212332/+632808
2024-06-10ARM: 9404/1: arm32: enable HAVE_LD_DEAD_CODE_DATA_ELIMINATIONYuntao Liu1-0/+4
The current arm32 architecture does not yet support the HAVE_LD_DEAD_CODE_DATA_ELIMINATION feature. arm32 is widely used in embedded scenarios, and enabling this feature would be beneficial for reducing the size of the kernel image. In order to make this work, we keep the necessary tables by annotating them with KEEP, also it requires further changes to linker script to KEEP some tables and wildcard compiler generated sections into the right place. When using ld.lld for linking, KEEP is not recognized within the OVERLAY command, and Ard proposed a concise method to solve this problem. It boots normally with defconfig, vexpress_defconfig and tinyconfig. The size comparison of zImage is as follows: defconfig vexpress_defconfig tinyconfig 5137712 5138024 424192 no dce 5032560 4997824 298384 dce 2.0% 2.7% 29.7% shrink When using smaller config file, there is a significant reduction in the size of the zImage. We also tested this patch on a commercially available single-board computer, and the comparison is as follows: a15eb_config 2161384 no dce 2092240 dce 3.2% shrink The zImage size has been reduced by approximately 3.2%, which is 70KB on 2.1M. Signed-off-by: Yuntao Liu <[email protected]> Tested-by: Arnd Bergmann <[email protected]> Reviewed-by: Arnd Bergmann <[email protected]> Reviewed-by: Linus Walleij <[email protected]> Signed-off-by: Russell King (Oracle) <[email protected]>