On Mon, Aug 7, 2023 at 11:18 PM <jiadong.zhu@xxxxxxx> wrote: > > From: Jiadong Zhu <Jiadong.Zhu@xxxxxxx> > > The parameter amdgpu_mcbp shall have priority against the default value > calculated from the chip version. > User could disable mcbp by setting the parameter mcbp as zero. > > Signed-off-by: Jiadong Zhu <Jiadong.Zhu@xxxxxxx> I think this should be expanded to disable the sw rings as well since they presumably won't work correctly without MCBP. Alex > --- > drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 9 +++++---- > 1 file changed, 5 insertions(+), 4 deletions(-) > > diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c > index 7314529553f6..615669dcabc2 100644 > --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c > +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c > @@ -3699,10 +3699,11 @@ static void amdgpu_device_set_mcbp(struct amdgpu_device *adev) > { > if (amdgpu_mcbp == 1) > adev->gfx.mcbp = true; > - > - if ((adev->ip_versions[GC_HWIP][0] >= IP_VERSION(9, 0, 0)) && > - (adev->ip_versions[GC_HWIP][0] < IP_VERSION(10, 0, 0)) && > - adev->gfx.num_gfx_rings) > + else if (amdgpu_mcbp == 0) > + adev->gfx.mcbp = false; > + else if ((adev->ip_versions[GC_HWIP][0] >= IP_VERSION(9, 0, 0)) && > + (adev->ip_versions[GC_HWIP][0] < IP_VERSION(10, 0, 0)) && > + adev->gfx.num_gfx_rings) > adev->gfx.mcbp = true; > > if (amdgpu_sriov_vf(adev)) > -- > 2.25.1 >