On Fri, Apr 8, 2022 at 9:58 AM Yongqiang Sun <yongqiang.sun@xxxxxxx> wrote: > > Add CONFIG_X86 check to fix the build error. > > Fixes: 67c7a4b1ec6c > ("drm/amd/amdgpu: Only reserve vram for firmware with vega9 MS_HYPERV > host.") > > Reported-by: kernel test robot <lkp@xxxxxxxxx> > Signed-off-by: Yongqiang Sun <yongqiang.sun@xxxxxxx> Acked-by: Alex Deucher <alexander.deucher@xxxxxxx> > --- > drivers/gpu/drm/amd/amdgpu/amdgpu_gmc.c | 4 ++++ > 1 file changed, 4 insertions(+) > > diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_gmc.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_gmc.c > index c322daf9c734..569cc394e562 100644 > --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_gmc.c > +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_gmc.c > @@ -25,7 +25,9 @@ > */ > > #include <linux/io-64-nonatomic-lo-hi.h> > +#ifdef CONFIG_X86 > #include <asm/hypervisor.h> > +#endif > > #include "amdgpu.h" > #include "amdgpu_gmc.h" > @@ -671,10 +673,12 @@ void amdgpu_gmc_get_vbios_allocations(struct amdgpu_device *adev) > /* > * VEGA10 SRIOV VF with MS_HYPERV host needs some firmware reserved area. > */ > +#ifdef CONFIG_X86 > if (amdgpu_sriov_vf(adev) && hypervisor_is_type(X86_HYPER_MS_HYPERV)) { > adev->mman.stolen_reserved_offset = 0x500000; > adev->mman.stolen_reserved_size = 0x200000; > } > +#endif > break; > case CHIP_RAVEN: > case CHIP_RENOIR: > -- > 2.25.1 >