drm/amdgpu: Implement new guest side VF2PF message transaction (v2)
authorBokun Zhang <Bokun.Zhang@amd.com>
Tue, 28 Jul 2020 19:29:12 +0000 (15:29 -0400)
committerAlex Deucher <alexander.deucher@amd.com>
Fri, 25 Sep 2020 21:03:22 +0000 (17:03 -0400)
commit519b8b76f0b62a0be0d9fcee39819d2461fc3cb0
tree1ba2cb07d2e6c71c5366fb57db9c06e5b58c2228
parent1721bc1b2afaefbd880b4606f5147b4ff487904c
drm/amdgpu: Implement new guest side VF2PF message transaction (v2)

- Refactor the driver code to use amdgpu_virt_read_pf2vf_data
  and amdgpu_virt_write_vf2pf_data instead of writing all code in
  one function (which is the old amdgpu_virt_init_data_exchange)

- Adding a new transaction method for VF2PF message between host
  and guest driver. Guest side will periodically update VF2PF
  message in the framebuffer.

  In the new header, we include guest ucode information, guest
  framebuffer usage, and engine usage

- Clean up the old macros since they will cause compile error if
  the new transaction method is used

v2: squash in build fix

Signed-off-by: Bokun Zhang <Bokun.Zhang@amd.com>
Reviewed-by: Monk Liu <monk.liu@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/amdgpu/amdgpu_device.c
drivers/gpu/drm/amd/amdgpu/amdgpu_virt.c
drivers/gpu/drm/amd/amdgpu/amdgpu_virt.h