diff options
| author | Tom Rini <[email protected]> | 2025-12-30 10:18:39 -0600 |
|---|---|---|
| committer | Tom Rini <[email protected]> | 2025-12-30 11:23:00 -0600 |
| commit | 5652ccc86a3272c2da568dda2d22abf4107e993a (patch) | |
| tree | 3de91858e8526929f6bfcc2df1aefb5e0986feaa /drivers | |
| parent | 4df43f4474dca5575666efbc2303c50ddbb3c689 (diff) | |
| parent | 5e9b0b56ad8c2a4289b2b506ad3d0f3acd0d20ba (diff) | |
Merge patch series "video: display: refactor display_read_timing to avoid code duplication"
Julien Stephan <[email protected]> says:
Commit 2dcf143398ad ("dm: video: Repurpose the 'displayport' uclass to 'display'")
left the display_read_edid() function unused by mistake.
This series addresses that oversight and introduces a new useful cmd.
Patch 1:
- Refactors display_read_timing() to use the existing
display_read_edid() function, eliminating redundant code.
- Marks display_read_edid() as static since it is not used outside of
the file.
Patch 2:
- Adds a new read_edid command, which can be very useful for debugging
or developing new display drivers.
- As this command uses display_read_edid(), the function is made
non-static again.
Link: https://lore.kernel.org/r/[email protected]
Diffstat (limited to 'drivers')
| -rw-r--r-- | drivers/video/display-uclass.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/video/display-uclass.c b/drivers/video/display-uclass.c index 61a73e1bc2a..85dac12a197 100644 --- a/drivers/video/display-uclass.c +++ b/drivers/video/display-uclass.c @@ -59,9 +59,7 @@ int display_read_timing(struct udevice *dev, struct display_timing *timing) if (ops && ops->read_timing) return ops->read_timing(dev, timing); - if (!ops || !ops->read_edid) - return -ENOSYS; - ret = ops->read_edid(dev, buf, sizeof(buf)); + ret = display_read_edid(dev, buf, sizeof(buf)); if (ret < 0) return ret; |
