diff options
| author | Qiang Yu <Qiang.Yu@amd.com> | 2026-05-26 14:45:48 +0800 |
|---|---|---|
| committer | Alex Deucher <alexander.deucher@amd.com> | 2026-06-17 18:06:53 -0400 |
| commit | 1c2d7a656655a50bd1b7227fb26d173959a1955d (patch) | |
| tree | 14233e09750229ea4cb5022666950bfe1c3c2878 /include/linux/device-id/git@git.tavy.me:linux-stable.git | |
| parent | 3f0cc1735273a57c5116710cf0202e12152f59cc (diff) | |
drm/amdgpu: initialize iter.start in amdgpu_devcoredump_format
This fixes read /sys/class/drm/cardN/device/devcoredump/data
return empty content sometimes.
amdgpu_devcoredump_format() leaves struct drm_print_iterator's
.start field uninitialized on the stack before passing it to
drm_coredump_printer(). __drm_puts_coredump() compares the running
.offset against .start to decide whether to skip or copy each
chunk:
if (iterator->offset < iterator->start) {
if (iterator->offset + len <= iterator->start) {
iterator->offset += len;
return;
}
...
}
Fixes: 4bbba79a7f1d ("drm/amdgpu: move devcoredump generation to a worker")
Acked-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Qiang Yu <Qiang.Yu@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
(cherry picked from commit cd6397b7af8262a380e188dc32e9de11ff897ed2)
Diffstat (limited to 'include/linux/device-id/git@git.tavy.me:linux-stable.git')
0 files changed, 0 insertions, 0 deletions
