All of lore.kernel.org
 help / color / mirror / Atom feed
* Fixing Direct firmware load for amdgpu/polaris12_mc.bin failed with error -2
@ 2017-07-21  9:20 Stuart Longland
       [not found] ` <708ff3f0-8bd8-b2f9-b993-5bfdb97fa16d-3e+Fe6x+DsgJbe36r25VNhCuuivNXqWP@public.gmane.org>
  0 siblings, 1 reply; 7+ messages in thread
From: Stuart Longland @ 2017-07-21  9:20 UTC (permalink / raw)
  To: amd-gfx-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW


[-- Attachment #1.1.1: Type: text/plain, Size: 1220 bytes --]

Hi all,

I have a silly question, hopefully with a very easy answer.  I'm getting
the following error in my kernel `dmesg` at boot:

> [    1.663664] amdgpu 0000:23:00.0: Direct firmware load for amdgpu/polaris12_mc.bin failed with error -2
> [    1.663747] mc: Failed to load firmware "amdgpu/polaris12_mc.bin"
> [    1.663812] [drm:gmc_v8_0_sw_init] *ERROR* Failed to load mc firmware!
> [    1.663878] [drm:amdgpu_device_init] *ERROR* sw_init of IP block <gmc_v8_0> failed -2

This is on kernel 4.12.3, video card is a Asus-branded Radeon RX 550,
and I have tried Gentoo's `sys-kernel/linux-firmware` package, the
firmware installed by `make firmware_install` and downloading firmware
blobs from: https://people.freedesktop.org/~agd5f/radeon_ucode/polaris/

I have also tried the drm-next branch of the kernel, commit
a26307ced13c6f1ad82593964e303b053586b064, with the same effect.

I can confirm that /lib/firmware/amdgpu/polaris12_mc.bin exists.  So I
have no idea why I am getting -ENOENT (aka error -2).  If the file isn't
to go in /lib/firmware, then where do I put it?
-- 
Stuart Longland (aka Redhatter, VK4MSL)

I haven't lost my mind...
  ...it's backed up on a tape somewhere.



[-- Attachment #1.2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

[-- Attachment #2: Type: text/plain, Size: 154 bytes --]

_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Fixing Direct firmware load for amdgpu/polaris12_mc.bin failed with error -2
       [not found] ` <708ff3f0-8bd8-b2f9-b993-5bfdb97fa16d-3e+Fe6x+DsgJbe36r25VNhCuuivNXqWP@public.gmane.org>
@ 2017-07-21  9:44   ` Stuart Longland
  2017-07-21 17:18   ` Deucher, Alexander
  1 sibling, 0 replies; 7+ messages in thread
From: Stuart Longland @ 2017-07-21  9:44 UTC (permalink / raw)
  To: amd-gfx-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW


[-- Attachment #1.1.1: Type: text/plain, Size: 1350 bytes --]

On 21/07/17 19:20, Stuart Longland wrote:
> I have also tried the drm-next branch of the kernel, commit
> a26307ced13c6f1ad82593964e303b053586b064, with the same effect.
> 
> I can confirm that /lib/firmware/amdgpu/polaris12_mc.bin exists.  So I
> have no idea why I am getting -ENOENT (aka error -2).  If the file isn't
> to go in /lib/firmware, then where do I put it?

The following .config options in the kernel have worked around the issue
I think:

> CONFIG_FW_LOADER=y
> # CONFIG_FIRMWARE_IN_KERNEL is not set
> CONFIG_EXTRA_FIRMWARE="amdgpu/polaris12_ce.bin amdgpu/polaris12_mc.bin amdgpu/polaris12_me.bin amdgpu/polaris12_mec2.bin amdgpu/polaris12_mec.bin amdgpu/polaris12_pfp.bin amdgpu/polaris12_rlc.bin amdgpu/polaris12_sdma1.bin amdgpu/polaris12_sdma.bin amdgpu/polaris12_smc.bin amdgpu/polaris12_uvd.bin amdgpu/polaris12_vce.bin"
> CONFIG_EXTRA_FIRMWARE_DIR="/lib/firmware"

Testing with some of the OpenGL screensavers in xscreensaver seems to
show reasonable performance (well, good enough for my needs: this is a
work PC).

I'm not sure that's the proper solution though.  It at least confirms my
firmware binaries are good though, otherwise I'm certain it wouldn't be
working there either.
-- 
Stuart Longland (aka Redhatter, VK4MSL)

I haven't lost my mind...
  ...it's backed up on a tape somewhere.


[-- Attachment #1.2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

[-- Attachment #2: Type: text/plain, Size: 154 bytes --]

_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply	[flat|nested] 7+ messages in thread

* RE: Fixing Direct firmware load for amdgpu/polaris12_mc.bin failed with error -2
       [not found] ` <708ff3f0-8bd8-b2f9-b993-5bfdb97fa16d-3e+Fe6x+DsgJbe36r25VNhCuuivNXqWP@public.gmane.org>
  2017-07-21  9:44   ` Stuart Longland
@ 2017-07-21 17:18   ` Deucher, Alexander
       [not found]     ` <BN6PR12MB1652A30FBDA855022E317794F7A40-/b2+HYfkarQqUD6E6FAiowdYzm3356FpvxpqHgZTriW3zl9H0oFU5g@public.gmane.org>
  1 sibling, 1 reply; 7+ messages in thread
From: Deucher, Alexander @ 2017-07-21 17:18 UTC (permalink / raw)
  To: 'Stuart Longland', amd-gfx-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW

> -----Original Message-----
> From: amd-gfx [mailto:amd-gfx-bounces@lists.freedesktop.org] On Behalf
> Of Stuart Longland
> Sent: Friday, July 21, 2017 5:21 AM
> To: amd-gfx@lists.freedesktop.org
> Subject: Fixing Direct firmware load for amdgpu/polaris12_mc.bin failed with
> error -2
> 
> Hi all,
> 
> I have a silly question, hopefully with a very easy answer.  I'm getting
> the following error in my kernel `dmesg` at boot:
> 
> > [    1.663664] amdgpu 0000:23:00.0: Direct firmware load for
> amdgpu/polaris12_mc.bin failed with error -2
> > [    1.663747] mc: Failed to load firmware "amdgpu/polaris12_mc.bin"
> > [    1.663812] [drm:gmc_v8_0_sw_init] *ERROR* Failed to load mc
> firmware!
> > [    1.663878] [drm:amdgpu_device_init] *ERROR* sw_init of IP block
> <gmc_v8_0> failed -2
> 
> This is on kernel 4.12.3, video card is a Asus-branded Radeon RX 550,
> and I have tried Gentoo's `sys-kernel/linux-firmware` package, the
> firmware installed by `make firmware_install` and downloading firmware
> blobs from: https://people.freedesktop.org/~agd5f/radeon_ucode/polaris/
> 
> I have also tried the drm-next branch of the kernel, commit
> a26307ced13c6f1ad82593964e303b053586b064, with the same effect.
> 
> I can confirm that /lib/firmware/amdgpu/polaris12_mc.bin exists.  So I
> have no idea why I am getting -ENOENT (aka error -2).  If the file isn't
> to go in /lib/firmware, then where do I put it?

You need to make sure the firmware is also included in your initrd if you are using one.

Alex

> --
> Stuart Longland (aka Redhatter, VK4MSL)
> 
> I haven't lost my mind...
>   ...it's backed up on a tape somewhere.
> 

_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Fixing Direct firmware load for amdgpu/polaris12_mc.bin failed with error -2
       [not found]     ` <BN6PR12MB1652A30FBDA855022E317794F7A40-/b2+HYfkarQqUD6E6FAiowdYzm3356FpvxpqHgZTriW3zl9H0oFU5g@public.gmane.org>
@ 2017-07-21 22:55       ` Stuart Longland
       [not found]         ` <2837c5da-a62c-2f3f-5392-8be270adf8cd-3e+Fe6x+DsgJbe36r25VNhCuuivNXqWP@public.gmane.org>
  0 siblings, 1 reply; 7+ messages in thread
From: Stuart Longland @ 2017-07-21 22:55 UTC (permalink / raw)
  To: Deucher, Alexander, amd-gfx-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW

On 22/07/17 03:18, Deucher, Alexander wrote:
>> I can confirm that /lib/firmware/amdgpu/polaris12_mc.bin exists.  So I
>> have no idea why I am getting -ENOENT (aka error -2).  If the file isn't
>> to go in /lib/firmware, then where do I put it?
> You need to make sure the firmware is also included in your initrd if you are using one.

Yeah, I don't use an initrd: I find it's too much of a pain to maintain
one (had that situation years ago with a machine that needed one for
software/BIOS RAID), so I ensure the drivers needed for mounting / are
baked into the kernel.

I understand why distributions use them though: they want to make a
kernel that works for possibly thousands of (incompatible) different
configurations.  I just need to make a kernel for my machine, so don't
need the complexity.

I should have mentioned that I wasn't using an initrd, my apologies for
leaving that out. :-)
-- 
Stuart Longland (aka Redhatter, VK4MSL)

I haven't lost my mind...
  ...it's backed up on a tape somewhere.
_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Fixing Direct firmware load for amdgpu/polaris12_mc.bin failed with error -2
       [not found]         ` <2837c5da-a62c-2f3f-5392-8be270adf8cd-3e+Fe6x+DsgJbe36r25VNhCuuivNXqWP@public.gmane.org>
@ 2017-07-24  1:02           ` Michel Dänzer
       [not found]             ` <bc8f3c17-6152-4000-801c-9a3fc9e4044e-otUistvHUpPR7s880joybQ@public.gmane.org>
  0 siblings, 1 reply; 7+ messages in thread
From: Michel Dänzer @ 2017-07-24  1:02 UTC (permalink / raw)
  To: Stuart Longland, Deucher, Alexander
  Cc: amd-gfx-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW

On 22/07/17 07:55 AM, Stuart Longland wrote:
> On 22/07/17 03:18, Deucher, Alexander wrote:
>>> I can confirm that /lib/firmware/amdgpu/polaris12_mc.bin exists.  So I
>>> have no idea why I am getting -ENOENT (aka error -2).  If the file isn't
>>> to go in /lib/firmware, then where do I put it?
>> You need to make sure the firmware is also included in your initrd if you are using one.
> 
> Yeah, I don't use an initrd: I find it's too much of a pain to maintain
> one (had that situation years ago with a machine that needed one for
> software/BIOS RAID), so I ensure the drivers needed for mounting / are
> baked into the kernel.
> 
> I understand why distributions use them though: they want to make a
> kernel that works for possibly thousands of (incompatible) different
> configurations.  I just need to make a kernel for my machine, so don't
> need the complexity.
> 
> I should have mentioned that I wasn't using an initrd, my apologies for
> leaving that out. :-)

If you compile the amdgpu driver into the kernel as well (not
recommended), you need to make sure all firmware files it needs for your
GPU(s) are included in the kernel as well.


-- 
Earthling Michel Dänzer               |               http://www.amd.com
Libre software enthusiast             |             Mesa and X developer
_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Fixing Direct firmware load for amdgpu/polaris12_mc.bin failed with error -2
       [not found]             ` <bc8f3c17-6152-4000-801c-9a3fc9e4044e-otUistvHUpPR7s880joybQ@public.gmane.org>
@ 2017-07-24  1:55               ` Stuart Longland
       [not found]                 ` <e918c9db-116b-8045-36e4-5d9581575ad2-3e+Fe6x+DsgJbe36r25VNhCuuivNXqWP@public.gmane.org>
  0 siblings, 1 reply; 7+ messages in thread
From: Stuart Longland @ 2017-07-24  1:55 UTC (permalink / raw)
  To: amd-gfx-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW


[-- Attachment #1.1.1: Type: text/plain, Size: 800 bytes --]

On 24/07/17 11:02, Michel Dänzer wrote:
>> Yeah, I don't use an initrd: I find it's too much of a pain to maintain
>> one (had that situation years ago with a machine that needed one for
>> software/BIOS RAID), so I ensure the drivers needed for mounting / are
>> baked into the kernel.
>>
> If you compile the amdgpu driver into the kernel as well (not
> recommended), you need to make sure all firmware files it needs for your
> GPU(s) are included in the kernel as well.

Ahh okay, so it's a quirk of having it built into the kernel: it races
mounting /.  If I get a moment later today I'll try making `amdgpu` a
module and see how I go.

Many thanks.
Regards,
-- 
Stuart Longland (aka Redhatter, VK4MSL)

I haven't lost my mind...
  ...it's backed up on a tape somewhere.


[-- Attachment #1.2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

[-- Attachment #2: Type: text/plain, Size: 154 bytes --]

_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Fixing Direct firmware load for amdgpu/polaris12_mc.bin failed with error -2 [RESOLVED]
       [not found]                 ` <e918c9db-116b-8045-36e4-5d9581575ad2-3e+Fe6x+DsgJbe36r25VNhCuuivNXqWP@public.gmane.org>
@ 2017-07-24  3:25                   ` Stuart Longland
  0 siblings, 0 replies; 7+ messages in thread
From: Stuart Longland @ 2017-07-24  3:25 UTC (permalink / raw)
  To: amd-gfx-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW


[-- Attachment #1.1.1: Type: text/plain, Size: 2191 bytes --]

On 24/07/17 11:55, Stuart Longland wrote:
> Ahh okay, so it's a quirk of having it built into the kernel: it races
> mounting /.  If I get a moment later today I'll try making `amdgpu` a
> module and see how I go.

Right, that fixed it.  Downside with the module loading later is that I
don't get the rookery of penguins (16 of them) showing up on initial
boot, but big deal, it works. :-)

The changes, for anyone else that might strike this issue:
> vk4msl-ws /home/stuartl # diff -u /boot/config-4.13.0-rc1+.old /boot/config-4.13.0-rc1+
> --- /boot/config-4.13.0-rc1+.old	2017-07-21 19:25:06.000000000 +1000
> +++ /boot/config-4.13.0-rc1+	2017-07-24 12:40:14.000000000 +1000
> @@ -1712,8 +1712,7 @@
>  CONFIG_PREVENT_FIRMWARE_BUILD=y
>  CONFIG_FW_LOADER=y
>  # CONFIG_FIRMWARE_IN_KERNEL is not set
> -CONFIG_EXTRA_FIRMWARE="amdgpu/polaris12_ce.bin amdgpu/polaris12_mc.bin amdgpu/polaris12_me.bin amdgpu/polaris12_mec2.bin amdgpu/polaris12_mec.bin amdgpu/polaris12_pfp.bin amdgpu/polaris12_rlc.bin amdgpu/polaris12_sdma1.bin amdgpu/polaris12_sdma.bin amdgpu/polaris12_smc.bin amdgpu/polaris12_uvd.bin amdgpu/polaris12_vce.bin"
> -CONFIG_EXTRA_FIRMWARE_DIR="/lib/firmware"
> +CONFIG_EXTRA_FIRMWARE=""
>  CONFIG_FW_LOADER_USER_HELPER=y
>  # CONFIG_FW_LOADER_USER_HELPER_FALLBACK is not set
>  CONFIG_ALLOW_DEV_COREDUMP=y
> @@ -3576,7 +3575,7 @@
>  #
>  # Multifunction device drivers
>  #
> -CONFIG_MFD_CORE=y
> +CONFIG_MFD_CORE=m
>  # CONFIG_MFD_AS3711 is not set
>  # CONFIG_PMIC_ADP5520 is not set
>  # CONFIG_MFD_AAT2870_CORE is not set
> @@ -4339,7 +4338,7 @@
>  CONFIG_DRM_FBDEV_EMULATION=y
>  CONFIG_DRM_FBDEV_OVERALLOC=100
>  CONFIG_DRM_LOAD_EDID_FIRMWARE=y
> -CONFIG_DRM_TTM=y
> +CONFIG_DRM_TTM=m
>  CONFIG_DRM_VM=y
>  
>  #
> @@ -4349,7 +4348,7 @@
>  CONFIG_DRM_I2C_SIL164=m
>  # CONFIG_DRM_I2C_NXP_TDA998X is not set
>  # CONFIG_DRM_RADEON is not set
> -CONFIG_DRM_AMDGPU=y
> +CONFIG_DRM_AMDGPU=m
>  CONFIG_DRM_AMDGPU_SI=y
>  CONFIG_DRM_AMDGPU_CIK=y
>  CONFIG_DRM_AMDGPU_USERPTR=y

Many thanks. :-)
Regards,
-- 
Stuart Longland (aka Redhatter, VK4MSL)

I haven't lost my mind...
  ...it's backed up on a tape somewhere.


[-- Attachment #1.2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

[-- Attachment #2: Type: text/plain, Size: 154 bytes --]

_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2017-07-24  3:25 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-07-21  9:20 Fixing Direct firmware load for amdgpu/polaris12_mc.bin failed with error -2 Stuart Longland
     [not found] ` <708ff3f0-8bd8-b2f9-b993-5bfdb97fa16d-3e+Fe6x+DsgJbe36r25VNhCuuivNXqWP@public.gmane.org>
2017-07-21  9:44   ` Stuart Longland
2017-07-21 17:18   ` Deucher, Alexander
     [not found]     ` <BN6PR12MB1652A30FBDA855022E317794F7A40-/b2+HYfkarQqUD6E6FAiowdYzm3356FpvxpqHgZTriW3zl9H0oFU5g@public.gmane.org>
2017-07-21 22:55       ` Stuart Longland
     [not found]         ` <2837c5da-a62c-2f3f-5392-8be270adf8cd-3e+Fe6x+DsgJbe36r25VNhCuuivNXqWP@public.gmane.org>
2017-07-24  1:02           ` Michel Dänzer
     [not found]             ` <bc8f3c17-6152-4000-801c-9a3fc9e4044e-otUistvHUpPR7s880joybQ@public.gmane.org>
2017-07-24  1:55               ` Stuart Longland
     [not found]                 ` <e918c9db-116b-8045-36e4-5d9581575ad2-3e+Fe6x+DsgJbe36r25VNhCuuivNXqWP@public.gmane.org>
2017-07-24  3:25                   ` Fixing Direct firmware load for amdgpu/polaris12_mc.bin failed with error -2 [RESOLVED] Stuart Longland

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.