Re: [PATCH] drm/amdgpu: Reorder to read EFI exported ROM first

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, Aug 12, 2024 at 12:50 AM Lijo Lazar <lijo.lazar@xxxxxxx> wrote:
>
> On EFI BIOSes, PCI ROM may be exported through EFI_PCI_IO_PROTOCOL and
> expansion ROM BARs may not be enabled. Choose to read from EFI exported
> ROM data before reading PCI Expansion ROM BAR.
>
> Signed-off-by: Lijo Lazar <lijo.lazar@xxxxxxx>

Reviewed-by: Alex Deucher <alexander.deucher@xxxxxxx>

> ---
>  drivers/gpu/drm/amd/amdgpu/amdgpu_bios.c | 10 +++++-----
>  1 file changed, 5 insertions(+), 5 deletions(-)
>
> diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_bios.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_bios.c
> index 618e469e3622..42e64bce661e 100644
> --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_bios.c
> +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_bios.c
> @@ -431,6 +431,11 @@ bool amdgpu_get_bios(struct amdgpu_device *adev)
>                 goto success;
>         }
>
> +       if (amdgpu_read_platform_bios(adev)) {
> +               dev_info(adev->dev, "Fetched VBIOS from platform\n");
> +               goto success;
> +       }
> +
>         if (amdgpu_read_bios(adev)) {
>                 dev_info(adev->dev, "Fetched VBIOS from ROM BAR\n");
>                 goto success;
> @@ -446,11 +451,6 @@ bool amdgpu_get_bios(struct amdgpu_device *adev)
>                 goto success;
>         }
>
> -       if (amdgpu_read_platform_bios(adev)) {
> -               dev_info(adev->dev, "Fetched VBIOS from platform\n");
> -               goto success;
> -       }
> -
>         dev_err(adev->dev, "Unable to locate a BIOS ROM\n");
>         return false;
>
> --
> 2.25.1
>




[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux