projects
/
openwrt
/
staging
/
blogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
b9a8be9
)
drm/amd/amdgpu: change pptable output format from ASCII to binary
author
Eric Huang
<
[email protected]
>
Thu, 28 Jul 2016 21:25:01 +0000
(17:25 -0400)
committer
Alex Deucher
<
[email protected]
>
Mon, 8 Aug 2016 15:32:57 +0000
(11:32 -0400)
Reviewed-by: Edward O'Callaghan <
[email protected]
>
Reviewed-by: Alex Deucher <
[email protected]
>
Signed-off-by: Eric Huang <
[email protected]
>
Signed-off-by: Alex Deucher <
[email protected]
>
drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c
patch
|
blob
|
history
diff --git
a/drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c
b/drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c
index 411965f12c0143057d57057b8401c87a0098b299..d4ec3cb187a5bdb903c41c28ffecd61d596df2e7 100644
(file)
--- a/
drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c
+++ b/
drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c
@@
-305,7
+305,7
@@
static ssize_t amdgpu_get_pp_table(struct device *dev,
struct drm_device *ddev = dev_get_drvdata(dev);
struct amdgpu_device *adev = ddev->dev_private;
char *table = NULL;
- int size
, i
;
+ int size;
if (adev->pp_enabled)
size = amdgpu_dpm_get_pp_table(adev, &table);
@@
-315,10
+315,7
@@
static ssize_t amdgpu_get_pp_table(struct device *dev,
if (size >= PAGE_SIZE)
size = PAGE_SIZE - 1;
- for (i = 0; i < size; i++) {
- sprintf(buf + i, "%02x", table[i]);
- }
- sprintf(buf + i, "\n");
+ memcpy(buf, table, size);
return size;
}