Skip to content

Commit

Permalink
drm/amd/display: Fix for outbox1 ring buffer typecasting issue
Browse files Browse the repository at this point in the history
[WHY]
Compiler warning "pointer to integer of different size" reported on
outbox1 ring buffer address typecasting.

Reported-by: kernel test robot <lkp@intel.com>

[HOW]
Fixed the issue by typecasting with character pointer.

Tested-by: Daniel Wheeler <daniel.wheeler@amd.com>
Signed-off-by: Meenakshikumar Somasundaram <meenakshikumar.somasundaram@amd.com>
Reviewed-by: Jun Lei <Jun.Lei@amd.com>
Acked-by: Solomon Chiu <solomon.chiu@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
  • Loading branch information
Meenakshikumar Somasundaram authored and Alex Deucher committed Mar 24, 2021
1 parent 6a30a92 commit 45150cd
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/gpu/drm/amd/display/dmub/src/dmub_srv.c
Original file line number Diff line number Diff line change
Expand Up @@ -508,7 +508,7 @@ enum dmub_status dmub_srv_hw_init(struct dmub_srv *dmub,

// Initialize outbox1 ring buffer
rb_params.ctx = dmub;
rb_params.base_address = (void *) ((uint64_t) (mail_fb->cpu_addr) + DMUB_RB_SIZE);
rb_params.base_address = (void *) ((uint8_t *) (mail_fb->cpu_addr) + DMUB_RB_SIZE);
rb_params.capacity = DMUB_RB_SIZE;
dmub_rb_init(&dmub->outbox1_rb, &rb_params);

Expand Down

0 comments on commit 45150cd

Please sign in to comment.