Skip to contentSkip to conversation

drm/amdgpu: don't check the default value for vm size

PATCH In review Alex Deucher 3 participants 3 messages Jun 15, 2017 – Jun 16, 2017 2 messages not in the archive

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 drm/amdgpu: don't check the default value for vm size

Avoids printing spurious messages like this:

[    3.102059] amdgpu 0000:01:00.0: VM size (-1) must be a power of 2
---
 drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 4 ++++
 1 file changed, 4 insertions(+)
drivers/gpu/drm/amd/amdgpu/amdgpu_device.c +4 -0
index 50001bf..ff90f78 100644
@@ -1074,6 +1074,10 @@ static void amdgpu_check_block_size(struct amdgpu_device *adev)
 
 static void amdgpu_check_vm_size(struct amdgpu_device *adev)
 {
+	/* no need to check the default value */
+	if (amdgpu_vm_size == -1)
+		return;
+
 	if (!amdgpu_check_pot_argument(amdgpu_vm_size)) {
 		dev_warn(adev->dev, "VM size (%d) must be a power of 2\n",
 			 amdgpu_vm_size);
Signature · 6 lines
2.5.5

_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

A message that is not in the archive (sent off-list or not yet received): 1497565284-22459-1-git-send-email-alexander.deucher-5C7GfCeVMHo@public.gmane.org

Reviewed-by
#2 lore raw
Quoted 14 lines · Alex Deucher

Avoids printing spurious messages like this:

[    3.102059] amdgpu 0000:01:00.0: VM size (-1) must be a power of 2
---
 drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 4 ++++
 1 file changed, 4 insertions(+)
drivers/gpu/drm/amd/amdgpu/amdgpu_device.c +0 -0
index 50001bf..ff90f78 100644

drivers/gpu/drm/amd/amdgpu/amdgpu_device.c static void amdgpu_check_block_size(struct amdgpu_device *adev) · line 1083

Quoted 10 lines
drivers/gpu/drm/amd/amdgpu/amdgpu_device.c +4 -0
@@ -1074,6 +1074,10 @@ static void amdgpu_check_block_size(struct amdgpu_device *adev)
 
 static void amdgpu_check_vm_size(struct amdgpu_device *adev)
 {
+	/* no need to check the default value */
+	if (amdgpu_vm_size == -1)
+		return;
+
 	if (!amdgpu_check_pot_argument(amdgpu_vm_size)) {
 		dev_warn(adev->dev, "VM size (%d) must be a power of 2\n",
 			 amdgpu_vm_size);
Signature · 6 lines
Earthling Michel Dänzer               |               http://www.amd.com
Libre software enthusiast             |             Mesa and X developer
_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

A message that is not in the archive (sent off-list or not yet received): c930dae8-3704-81df-4911-1842aefa1cc0-otUistvHUpPR7s880joybQ@public.gmane.org

Reviewed-by Christian Köig
#4 lore raw

Am 16.06.2017 um 04:36 schrieb Michel Dänzer:

Quoted 15 lines · Alex Deucher
Quoted 14 lines

Avoids printing spurious messages like this:

[    3.102059] amdgpu 0000:01:00.0: VM size (-1) must be a power of 2
---
  drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 4 ++++
  1 file changed, 4 insertions(+)
drivers/gpu/drm/amd/amdgpu/amdgpu_device.c +0 -0
index 50001bf..ff90f78 100644
@@ -1074,6 +1074,10 @@ static void amdgpu_check_block_size(struct amdgpu_device *adev)
 
Quoted 13 lines

drivers/gpu/drm/amd/amdgpu/amdgpu_device.c static void amdgpu_check_block_size(struct amdgpu_device *adev) · line 1083

Quoted 10 lines
drivers/gpu/drm/amd/amdgpu/amdgpu_device.c +4 -0
  static void amdgpu_check_vm_size(struct amdgpu_device *adev)
  {
+	/* no need to check the default value */
+	if (amdgpu_vm_size == -1)
+		return;
+
  	if (!amdgpu_check_pot_argument(amdgpu_vm_size)) {
  		dev_warn(adev->dev, "VM size (%d) must be a power of 2\n",
  			 amdgpu_vm_size);

And one more item removed from my todo list :)

Thanks,

Christian.

_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx