Skip to content

Commit

Permalink
drm/amdgpu: add init support for GFX11 (v2)
Browse files Browse the repository at this point in the history
Add initial support for GC version 11.  GC is
the graphics and compute block on the GPU.

v1: add initial gfx11 support (Wenhui)
v2: switch to new amdgpu_gfx_is_high_priority_compute_queue
    interface (Hawking)
v3: fix num_mec (Alex)

Signed-off-by: Wenhui Sheng <Wenhui.Sheng@amd.com>
Reviewed-by: Hawking Zhang <Hawking.Zhang@amd.com>
Signed-off-by: Hawking Zhang <Hawking.Zhang@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
  • Loading branch information
Hawking Zhang authored and Alex Deucher committed May 4, 2022
1 parent 028c3fb commit 3d879e8
Show file tree
Hide file tree
Showing 4 changed files with 6,364 additions and 1 deletion.
3 changes: 2 additions & 1 deletion drivers/gpu/drm/amd/amdgpu/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,8 @@ amdgpu-y += \
gfx_v9_4.o \
gfx_v9_4_2.o \
gfx_v10_0.o \
imu_v11_0.o
imu_v11_0.o \
gfx_v11_0.o

# add async DMA block
amdgpu-y += \
Expand Down
13 changes: 13 additions & 0 deletions drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.h
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,9 @@ struct amdgpu_mec {
u64 hpd_eop_gpu_addr;
struct amdgpu_bo *mec_fw_obj;
u64 mec_fw_gpu_addr;
struct amdgpu_bo *mec_fw_data_obj;
u64 mec_fw_data_gpu_addr;

u32 num_mec;
u32 num_pipe_per_mec;
u32 num_queue_per_pipe;
Expand Down Expand Up @@ -245,6 +248,10 @@ struct amdgpu_pfp {
struct amdgpu_bo *pfp_fw_obj;
uint64_t pfp_fw_gpu_addr;
uint32_t *pfp_fw_ptr;

struct amdgpu_bo *pfp_fw_data_obj;
uint64_t pfp_fw_data_gpu_addr;
uint32_t *pfp_fw_data_ptr;
};

struct amdgpu_ce {
Expand All @@ -257,6 +264,11 @@ struct amdgpu_me {
struct amdgpu_bo *me_fw_obj;
uint64_t me_fw_gpu_addr;
uint32_t *me_fw_ptr;

struct amdgpu_bo *me_fw_data_obj;
uint64_t me_fw_data_gpu_addr;
uint32_t *me_fw_data_ptr;

uint32_t num_me;
uint32_t num_pipe_per_me;
uint32_t num_queue_per_pipe;
Expand All @@ -277,6 +289,7 @@ struct amdgpu_gfx {
struct amdgpu_kiq kiq;
struct amdgpu_imu imu;
struct amdgpu_scratch scratch;
bool rs64_enable; /* firmware format */
const struct firmware *me_fw; /* ME firmware */
uint32_t me_fw_version;
const struct firmware *pfp_fw; /* PFP firmware */
Expand Down
Loading

0 comments on commit 3d879e8

Please sign in to comment.