drm/radeon/uvd: Fix forgotten unmap buffer objects
Subsystems (2)
PATCH v4 2/2 drm/radeon/uvd: Fix forgotten unmap buffer objects
after the buffer object is successfully mapped, call radeon_bo_kunmap before the function returns.
drivers/gpu/drm/radeon/radeon_uvd.c +2 -3
@@ -497,6 +497,7 @@ static int radeon_uvd_cs_msg(struct radeon_cs_parser *p, struct radeon_bo *bo, handle = msg[2 ];if (handle ==0 ) { +radeon_bo_kunmap (bo);DRM_ERROR ("Invalid UVD handle!\n" );return -EINVAL ; }
@@ -559,12 +560,10 @@ static int radeon_uvd_cs_msg(struct radeon_cs_parser *p, struct radeon_bo *bo,return 0 ;default : -DRM_ERROR ("Illegal UVD message type (%d)!\n" , msg_type); -return -EINVAL ; } -BUG (); +radeon_bo_kunmap (bo);return -EINVAL ; }
--
2.20.1
Christian König
maintainerI'm scratching my head what you are doing here?
That's the fives time you send out the same patch, so something is going wrong here :)
Please double check why that lands in your outbox over and over again.
Regards,
Christian.
Am 08.02.22 um 09:14 schrieb zhanglianjie:
Quoted 36 lines
after the buffer object is successfully mapped, call
radeon_bo_kunmapbefore the function returns.Signed-off-by zhanglianjie <[email protected]>Reviewed-by Christian König <[email protected]>drivers/gpu/drm/radeon/radeon_uvd.c +2
-4@@ -497,6 +497,7 @@ static int radeon_uvd_cs_msg(struct radeon_cs_parser *p, struct radeon_bo *bo, handle = msg[2 ];if (handle ==0 ) { +radeon_bo_kunmap (bo);DRM_ERROR ("Invalid UVD handle!\n" );return -EINVAL ; }@@ -559,12 +560,10 @@ static int radeon_uvd_cs_msg(struct radeon_cs_parser *p, struct radeon_bo *bo,return 0 ;default : -DRM_ERROR ("Illegal UVD message type (%d)!\n" , msg_type); -return -EINVAL ; } -BUG (); +radeon_bo_kunmap (bo);return -EINVAL ; } --2.20.1
I am very sorry that I submitted many times due to the character coding problem. Can PATCH V4 be used?
Quoted 50 lines
I'm scratching my head what you are doing here?
That's the fives time you send out the same patch, so something is going wrong here :)
Please double check why that lands in your outbox over and over again.
Regards,
Christian.Am 08.02.22 um 09:14 schrieb zhanglianjie:
Quoted 38 lines
after the buffer object is successfully mapped, call
radeon_bo_kunmapbefore the function returns.Signed-off-by zhanglianjie <[email protected]>Reviewed-by Christian König <[email protected]>drivers/gpu/drm/radeon/radeon_uvd.c +1
-0@@ -497,6 +497,7 @@ static int radeon_uvd_cs_msg(struct radeon_cs_parser *p, struct radeon_bo *bo, handle = msg[2]; if (handle == 0) { + radeon_bo_kunmap(bo); DRM_ERROR("Invalid UVD handle!\n"); return -EINVAL;}
drivers/gpu/drm/radeon/radeon_uvd.c +0
-0@@ -559,12 +560,10 @@ static int radeon_uvd_cs_msg(struct radeon_cs_parser *p, struct radeon_bo *bo, return 0;default:
-
DRM_ERROR("Illegal UVD message type (%d)!\n", msg_type); - return-EINVAL;
}-
BUG();
+radeon_bo_kunmap(bo);
return-EINVAL;
}Signature · 1 line
2.20.1
Christian König
maintainerI think so, Alex will probably pick that up.
Thanks,
Christian.
Am 08.02.22 um 09:28 schrieb zhanglianjie:
Quoted 55 lines
I am very sorry that I submitted many times due to the character coding problem. Can PATCH V4 be used?
Quoted 50 lines
I'm scratching my head what you are doing here?
That's the fives time you send out the same patch, so something is going wrong here :)
Please double check why that lands in your outbox over and over again.
Regards,
Christian.Am 08.02.22 um 09:14 schrieb zhanglianjie:
Quoted 38 lines
after the buffer object is successfully mapped, call
radeon_bo_kunmapbefore the function returns.Signed-off-by zhanglianjie <[email protected]>Reviewed-by Christian König <[email protected]>drivers/gpu/drm/radeon/radeon_uvd.c +1
-0@@ -497,6 +497,7 @@ static int radeon_uvd_cs_msg(struct radeon_cs_parser *p, struct radeon_bo *bo, handle = msg[2]; if (handle == 0) { + radeon_bo_kunmap(bo); DRM_ERROR("Invalid UVD handle!\n"); return -EINVAL;}
drivers/gpu/drm/radeon/radeon_uvd.c +0
-0@@ -559,12 +560,10 @@ static int radeon_uvd_cs_msg(struct radeon_cs_parser *p, struct radeon_bo *bo, return 0;default:
-
DRM_ERROR("Illegal UVD message type (%d)!\n", msg_type); - return-EINVAL;
}-
BUG();
+radeon_bo_kunmap(bo);
return-EINVAL;
}Signature · 1 line
2.20.1
Thank you very much for your review.
Quoted 63 lines
I think so, Alex will probably pick that up.
Thanks,
Christian.Am 08.02.22 um 09:28 schrieb zhanglianjie:
Quoted 55 lines
I am very sorry that I submitted many times due to the character coding problem. Can PATCH V4 be used?
Quoted 50 lines
I'm scratching my head what you are doing here?
That's the fives time you send out the same patch, so something is going wrong here :)
Please double check why that lands in your outbox over and over again.
Regards,
Christian.Am 08.02.22 um 09:14 schrieb zhanglianjie:
Quoted 38 lines
after the buffer object is successfully mapped, call
radeon_bo_kunmapbefore the function returns.Signed-off-by zhanglianjie <[email protected]>Reviewed-by Christian König <[email protected]>drivers/gpu/drm/radeon/radeon_uvd.c +1
-0@@ -497,6 +497,7 @@ static int radeon_uvd_cs_msg(struct radeon_cs_parser *p, struct radeon_bo *bo, handle = msg[2]; if (handle == 0) { + radeon_bo_kunmap(bo); DRM_ERROR("Invalid UVD handle!\n"); return -EINVAL;}
drivers/gpu/drm/radeon/radeon_uvd.c +0
-0@@ -559,12 +560,10 @@ static int radeon_uvd_cs_msg(struct radeon_cs_parser *p, struct radeon_bo *bo, return 0;default:
-
DRM_ERROR("Illegal UVD message type (%d)!\n", msg_type); - return-EINVAL;
}-
BUG();
+radeon_bo_kunmap(bo);
return-EINVAL;
}Signature · 1 line
2.20.1
.
Alex Deucher
AppliedApplied the series. Thanks!
Alex
Quoted 67 lines · Christian König
I think so, Alex will probably pick that up.
Thanks,
Christian.Am 08.02.22 um 09:28 schrieb zhanglianjie:
Quoted 59 lines
I am very sorry that I submitted many times due to the character coding problem. Can PATCH V4 be used?
Quoted 53 lines
I'm scratching my head what you are doing here?
That's the fives time you send out the same patch, so something is going wrong here :)
Please double check why that lands in your outbox over and over again.
Regards,
Christian.Am 08.02.22 um 09:14 schrieb zhanglianjie:
Quoted 40 lines
after the buffer object is successfully mapped, call
radeon_bo_kunmapbefore the function returns.Signed-off-by zhanglianjie <[email protected]>Reviewed-by Christian König <[email protected]>drivers/gpu/drm/radeon/radeon_uvd.c +1
-0@@ -497,6 +497,7 @@ static int radeon_uvd_cs_msg(struct radeon_cs_parser *p, struct radeon_bo *bo, handle = msg[2 ];if (handle ==0 ) { +radeon_bo_kunmap (bo);DRM_ERROR ("Invalid UVD handle!\n" );return -EINVAL ;}drivers/gpu/drm/radeon/radeon_uvd.c +1
-4@@ -559,12 +560,10 @@ static int radeon_uvd_cs_msg(struct radeon_cs_parser *p, struct radeon_bo *bo, return 0;default : -DRM_ERROR ("Illegal UVD message type (%d)!\n" , msg_type); -return -EINVAL ; } -BUG (); +radeon_bo_kunmap (bo);return -EINVAL ; } --2.20.1