Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 28 Sep 2018 15:13:52 -0700
From:      Johannes Lundberg <johalun0@gmail.com>
To:        Steve Kargl <sgk@troutmask.apl.washington.edu>
Cc:        Niclas Zeising <zeising+freebsd@daemonic.se>, x11-list freebsd <freebsd-x11@freebsd.org>
Subject:   Re: fence_wait returned with error -512
Message-ID:  <CAECmPwvO0N%2B_L7Keyq_XvgB%2BRcZGRoN90e_Qja-yahPKaPpv5g@mail.gmail.com>
In-Reply-To: <20180928183720.GA1371@troutmask.apl.washington.edu>
References:  <20180927190409.GA27756@troutmask.apl.washington.edu> <b8e08aee-c532-b92c-26d8-0f82f586cb2e@daemonic.se> <20180927201928.GA86166@troutmask.apl.washington.edu> <ed292bb9-5e5a-7de8-1440-7da718e3f6c8@daemonic.se> <20180927211815.GB89730@troutmask.apl.washington.edu> <CAECmPwtt5RGf7uuZcWgD4t_07QqPTb0WZEf6mQJ8aK3XTOFBRw@mail.gmail.com> <20180927233955.GA918@troutmask.apl.washington.edu> <CAECmPwugK_npMO4gOZKvZ6=J=Kq0m4EebupsACjvB%2B39znWxMQ@mail.gmail.com> <20180928173627.GA1082@troutmask.apl.washington.edu> <CAECmPwsJemzi%2BtUP-EkZ8JNq56GsOcne-F77H85q5ZtR-PN=gw@mail.gmail.com> <20180928183720.GA1371@troutmask.apl.washington.edu>

next in thread | previous in thread | raw e-mail | index | archive | help
Hi Steve

Sorry for the many trial and errors.. I found some more renamed firmware
names and have updated the repo on github.
I tested with a hello world module.

static int hello_handler(module_t _mod, int event, void *_arg) {
    switch(event) {
    case MOD_LOAD:
        printf("MOD_LOAD: \n");
        fw = drm_firmware_get("radeon/CAICOS_pfp.bin", NULL);
        firmware_put(fw, FIRMWARE_UNLOAD);

        fw = drm_firmware_get("radeon/CAICOS_me.bin", NULL);
        firmware_put(fw, FIRMWARE_UNLOAD);

        fw = drm_firmware_get("radeon/CAICOS_mc.bin", NULL);
        firmware_put(fw, FIRMWARE_UNLOAD);

        fw = drm_firmware_get("radeon/CAICOS_smc.bin", NULL);
        firmware_put(fw, FIRMWARE_UNLOAD);

        fw = drm_firmware_get("radeon/VERDE_rlc.bin", NULL);
        firmware_put(fw, FIRMWARE_UNLOAD);

        fw = drm_firmware_get("radeon/R100_cp.bin", NULL);
        firmware_put(fw, FIRMWARE_UNLOAD);

    break;
    case MOD_UNLOAD:
        printf("MOD_UNLOAD: \n");
        break;
    default:
        break;
    }
    return 0;
}

output:

MOD_LOAD:
unknown: Successfully loaded firmware image with name: radeon/CAICOS_pfp.bin
radeon/CAICOS_me.bin: could not load firmware image, error 2
radeon/CAICOS_me.bin: could not load firmware image, error 2
unknown: Successfully loaded firmware image with name (mapped name):
radeon/CAICOS_me.bin (radeon_CAICOS_me_bin)
radeon/CAICOS_mc.bin: could not load firmware image, error 2
radeon/CAICOS_mc.bin: could not load firmware image, error 2
unknown: Successfully loaded firmware image with name (mapped name):
radeon/CAICOS_mc.bin (radeon_CAICOS_mc_bin)
radeon/CAICOS_smc.bin: could not load firmware image, error 2
radeon/CAICOS_smc.bin: could not load firmware image, error 2
unknown: Successfully loaded firmware image with name (mapped name):
radeon/CAICOS_smc.bin (radeon_CAICOS_smc_bin)
radeon/VERDE_rlc.bin: could not load firmware image, error 2
radeon/VERDE_rlc.bin: could not load firmware image, error 2
unknown: Successfully loaded firmware image with name (mapped name):
radeon/VERDE_rlc.bin (radeon_VERDE_rlc_bin)
radeon/R100_cp.bin: could not load firmware image, error 2
radeon/R100_cp.bin: could not load firmware image, error 2
unknown: Successfully loaded firmware image with name (mapped name):
radeon/R100_cp.bin (radeon_R100_cp_bin)

it is normal that is fails two times because it first tries to load with
unmapped filename.


On Fri, Sep 28, 2018 at 11:37 AM Steve Kargl <
sgk@troutmask.apl.washington.edu> wrote:

> OK.  Thanks for looking into this.  If you're trying to go
> with the upstream naming convention (probably a good thing),
> then you'll need to update the gpu-firmware-kmod port.  It
> is the one that mangles names, and AFAIU  wraps the firmware
> into a *.ko file.
>
> % pkg which /boot/modules/radeon_CAICOS_pfp_bin.ko
> /boot/modules/radeon_CAICOS_pfp_bin.ko was installed by package
> gpu-firmware-kmod-g20180825
>
> Again, thanks.
>

As far as I understand, the filename has to be mangled for the kernel to
load the .ko file. The internal firmware name is same as upstream.

>
> --
> steve
>
>
> On Fri, Sep 28, 2018 at 11:14:56AM -0700, Johannes Lundberg wrote:
> > Hi
> >
> > radeon/%s_mc.bin etc is correct because that is the "internal" name of
> the
> > firmware that is registered when the .ko file is loaded. by using the
> > upstream name we don't have to patch and rename every time a new firmware
> > comes out.
> >
> > A custom function, drm_firmware_get, will translate this into the correct
> > filename, as is done in the linuxkpi drm drivers.
> >
> > I will check further what is missing today or tomorrow.
> >
> >
> >
> > On Fri, Sep 28, 2018 at 10:36 AM Steve Kargl <
> > sgk@troutmask.apl.washington.edu> wrote:
> >
> > > On Thu, Sep 27, 2018 at 05:48:35PM -0700, Johannes Lundberg wrote:
> > > >
> > > > I pushed a fix for firmware names. Please run git pull and try again.
> > > >
> > >
> > > The semi-obvious diff to git code (see patch following .sig)
> > > allows at least the loading of one module.
> > >
> > > % kldstat | grep radeon
> > > 11    1 0xffffffff81622000    db810 radeonkms.ko
> > > 14    1 0xffffffff81748000     12f7 radeon_CAICOS_pfp_bin.ko
> > >
> > > Upon trying to start Xorg, I now see
> > >
> > > info: [drm] Loading CAICOS Microcode
> > > error: [drm:pid919:ni_init_microcode] *ERROR* ni_cp: Failed to load
> > > firmware "radeon_CAICOS_pfp_bin"
> > > error: [drm:pid919:evergreen_startup] *ERROR* Failed to load firmware!
> > > drmn0: error: disabling GPU acceleration
> > > drmn0: warning: 0xfffff800029ec400 unpin not necessary
> > > drmn0: warning: 0xfffff800029ec400 unpin not necessary
> > > error: [drm:pid919:evergreen_init] *ERROR* radeon: MC ucode required
> for
> > > NI+.
> > > drmn0: error: Fatal error during GPU init
> > > info: [drm] radeon: finishing device.
> > > info: [drm] radeon: ttm finalized
> > > device_attach: drmn0 attach returned 22
> > >
> > > --
> > > Steve
> > >
> > >
> > > diff --git a/src/dev/drm2/radeon/ni.c b/src/dev/drm2/radeon/ni.c
> > > index e254c83..09b63e7 100644
> > > --- a/src/dev/drm2/radeon/ni.c
> > > +++ b/src/dev/drm2/radeon/ni.c
> > > @@ -63,23 +63,23 @@ extern int si_rlc_init(struct radeon_device *rdev);
> > >
> > >  #ifdef __linux__
> > >  /* Firmware Names */
> > > -MODULE_FIRMWARE("radeon/BARTS_pfp.bin");
> > > -MODULE_FIRMWARE("radeon/BARTS_me.bin");
> > > -MODULE_FIRMWARE("radeon/BARTS_mc.bin");
> > > -MODULE_FIRMWARE("radeon/BTC_rlc.bin");
> > > -MODULE_FIRMWARE("radeon/TURKS_pfp.bin");
> > > -MODULE_FIRMWARE("radeon/TURKS_me.bin");
> > > -MODULE_FIRMWARE("radeon/TURKS_mc.bin");
> > > -MODULE_FIRMWARE("radeon/CAICOS_pfp.bin");
> > > -MODULE_FIRMWARE("radeon/CAICOS_me.bin");
> > > -MODULE_FIRMWARE("radeon/CAICOS_mc.bin");
> > > -MODULE_FIRMWARE("radeon/CAYMAN_pfp.bin");
> > > -MODULE_FIRMWARE("radeon/CAYMAN_me.bin");
> > > -MODULE_FIRMWARE("radeon/CAYMAN_mc.bin");
> > > -MODULE_FIRMWARE("radeon/CAYMAN_rlc.bin");
> > > -MODULE_FIRMWARE("radeon/ARUBA_pfp.bin");
> > > -MODULE_FIRMWARE("radeon/ARUBA_me.bin");
> > > -MODULE_FIRMWARE("radeon/ARUBA_rlc.bin");
> > > +MODULE_FIRMWARE("radeon_BARTS_pfp_bin");
> > > +MODULE_FIRMWARE("radeon_BARTS_me_bin");
> > > +MODULE_FIRMWARE("radeon_BARTS_mc_bin");
> > > +MODULE_FIRMWARE("radeon_BTC_rlc_bin");
> > > +MODULE_FIRMWARE("radeon_TURKS_pfp_bin");
> > > +MODULE_FIRMWARE("radeon_TURKS_me_bin");
> > > +MODULE_FIRMWARE("radeon_TURKS_mc_bin");
> > > +MODULE_FIRMWARE("radeon_CAICOS_pfp_bin");
> > > +MODULE_FIRMWARE("radeon_CAICOS_me_bin");
> > > +MODULE_FIRMWARE("radeon_CAICOS_mc_bin");
> > > +MODULE_FIRMWARE("radeon_CAYMAN_pfp_bin");
> > > +MODULE_FIRMWARE("radeon_CAYMAN_me_bin");
> > > +MODULE_FIRMWARE("radeon_CAYMAN_mc_bin");
> > > +MODULE_FIRMWARE("radeon_CAYMAN_rlc_bin");
> > > +MODULE_FIRMWARE("radeon_ARUBA_pfp_bin");
> > > +MODULE_FIRMWARE("radeon_ARUBA_me_bin");
> > > +MODULE_FIRMWARE("radeon_ARUBA_rlc_bin");
> > >  #endif
> > >
> > >  #define BTC_IO_MC_REGS_SIZE 29
> > > @@ -346,7 +346,7 @@ int ni_init_microcode(struct radeon_device *rdev)
> > >         DRM_INFO("Loading %s Microcode\n", chip_name);
> > >         err = 0;
> > >
> > > -       snprintf(fw_name, sizeof(fw_name), "radeon/%s_pfp.bin",
> chip_name);
> > > +       snprintf(fw_name, sizeof(fw_name), "radeon_%s_pfp_bin",
> chip_name);
> > >         rdev->pfp_fw = firmware_get(fw_name);
> > >         if (rdev->pfp_fw == NULL) {
> > >                 err = -ENOENT;
> > > @@ -360,7 +360,7 @@ int ni_init_microcode(struct radeon_device *rdev)
> > >                 goto out;
> > >         }
> > >
> > > -       snprintf(fw_name, sizeof(fw_name), "radeon/%s_me.bin",
> chip_name);
> > > +       snprintf(fw_name, sizeof(fw_name), "radeon_%s_me_bin",
> chip_name);
> > >         rdev->me_fw = firmware_get(fw_name);
> > >         if (rdev->me_fw == NULL) {
> > >                 err = -ENOENT;
> > > @@ -373,7 +373,7 @@ int ni_init_microcode(struct radeon_device *rdev)
> > >                 err = -EINVAL;
> > >         }
> > >
> > > -       snprintf(fw_name, sizeof(fw_name), "radeon/%s_rlc.bin",
> > > rlc_chip_name);
> > > +       snprintf(fw_name, sizeof(fw_name), "radeon_%s_rlc_bin",
> > > rlc_chip_name);
> > >         rdev->rlc_fw = firmware_get(fw_name);
> > >         if (rdev->rlc_fw == NULL) {
> > >                 err = -ENOENT;
> > > @@ -388,7 +388,7 @@ int ni_init_microcode(struct radeon_device *rdev)
> > >
> > >         /* no MC ucode on TN */
> > >         if (!(rdev->flags & RADEON_IS_IGP)) {
> > > -               snprintf(fw_name, sizeof(fw_name), "radeon/%s_mc.bin",
> > > chip_name);
> > > +               snprintf(fw_name, sizeof(fw_name), "radeon_%s_mc_bin",
> > > chip_name);
> > >                 rdev->mc_fw = firmware_get(fw_name);
> > >                 if (rdev->mc_fw == NULL) {
> > >                         err = -ENOENT;
> > > diff --git a/src/dev/drm2/radeon/r600.c b/src/dev/drm2/radeon/r600.c
> > > index d9b0322..30a7aca 100644
> > > --- a/src/dev/drm2/radeon/r600.c
> > > +++ b/src/dev/drm2/radeon/r600.c
> > > @@ -52,47 +52,47 @@ __FBSDID("$FreeBSD$");
> > >
> > >  #ifdef __linux__
> > >  /* Firmware Names */
> > > -MODULE_FIRMWARE("radeon/R600_pfp.bin");
> > > -MODULE_FIRMWARE("radeon/R600_me.bin");
> > > -MODULE_FIRMWARE("radeon/RV610_pfp.bin");
> > > -MODULE_FIRMWARE("radeon/RV610_me.bin");
> > > -MODULE_FIRMWARE("radeon/RV630_pfp.bin");
> > > -MODULE_FIRMWARE("radeon/RV630_me.bin");
> > > -MODULE_FIRMWARE("radeon/RV620_pfp.bin");
> > > -MODULE_FIRMWARE("radeon/RV620_me.bin");
> > > -MODULE_FIRMWARE("radeon/RV635_pfp.bin");
> > > -MODULE_FIRMWARE("radeon/RV635_me.bin");
> > > -MODULE_FIRMWARE("radeon/RV670_pfp.bin");
> > > -MODULE_FIRMWARE("radeon/RV670_me.bin");
> > > -MODULE_FIRMWARE("radeon/RS780_pfp.bin");
> > > -MODULE_FIRMWARE("radeon/RS780_me.bin");
> > > -MODULE_FIRMWARE("radeon/RV770_pfp.bin");
> > > -MODULE_FIRMWARE("radeon/RV770_me.bin");
> > > -MODULE_FIRMWARE("radeon/RV730_pfp.bin");
> > > -MODULE_FIRMWARE("radeon/RV730_me.bin");
> > > -MODULE_FIRMWARE("radeon/RV710_pfp.bin");
> > > -MODULE_FIRMWARE("radeon/RV710_me.bin");
> > > -MODULE_FIRMWARE("radeon/R600_rlc.bin");
> > > -MODULE_FIRMWARE("radeon/R700_rlc.bin");
> > > -MODULE_FIRMWARE("radeon/CEDAR_pfp.bin");
> > > -MODULE_FIRMWARE("radeon/CEDAR_me.bin");
> > > -MODULE_FIRMWARE("radeon/CEDAR_rlc.bin");
> > > -MODULE_FIRMWARE("radeon/REDWOOD_pfp.bin");
> > > -MODULE_FIRMWARE("radeon/REDWOOD_me.bin");
> > > -MODULE_FIRMWARE("radeon/REDWOOD_rlc.bin");
> > > -MODULE_FIRMWARE("radeon/JUNIPER_pfp.bin");
> > > -MODULE_FIRMWARE("radeon/JUNIPER_me.bin");
> > > -MODULE_FIRMWARE("radeon/JUNIPER_rlc.bin");
> > > -MODULE_FIRMWARE("radeon/CYPRESS_pfp.bin");
> > > -MODULE_FIRMWARE("radeon/CYPRESS_me.bin");
> > > -MODULE_FIRMWARE("radeon/CYPRESS_rlc.bin");
> > > -MODULE_FIRMWARE("radeon/PALM_pfp.bin");
> > > -MODULE_FIRMWARE("radeon/PALM_me.bin");
> > > -MODULE_FIRMWARE("radeon/SUMO_rlc.bin");
> > > -MODULE_FIRMWARE("radeon/SUMO_pfp.bin");
> > > -MODULE_FIRMWARE("radeon/SUMO_me.bin");
> > > -MODULE_FIRMWARE("radeon/SUMO2_pfp.bin");
> > > -MODULE_FIRMWARE("radeon/SUMO2_me.bin");
> > > +MODULE_FIRMWARE("radeon_R600_pfp_bin");
> > > +MODULE_FIRMWARE("radeon_R600_me_bin");
> > > +MODULE_FIRMWARE("radeon_RV610_pfp_bin");
> > > +MODULE_FIRMWARE("radeon_RV610_me_bin");
> > > +MODULE_FIRMWARE("radeon_RV630_pfp_bin");
> > > +MODULE_FIRMWARE("radeon_RV630_me_bin");
> > > +MODULE_FIRMWARE("radeon_RV620_pfp_bin");
> > > +MODULE_FIRMWARE("radeon_RV620_me_bin");
> > > +MODULE_FIRMWARE("radeon_RV635_pfp_bin");
> > > +MODULE_FIRMWARE("radeon_RV635_me_bin");
> > > +MODULE_FIRMWARE("radeon_RV670_pfp_bin");
> > > +MODULE_FIRMWARE("radeon_RV670_me_bin");
> > > +MODULE_FIRMWARE("radeon_RS780_pfp_bin");
> > > +MODULE_FIRMWARE("radeon_RS780_me_bin");
> > > +MODULE_FIRMWARE("radeon_RV770_pfp_bin");
> > > +MODULE_FIRMWARE("radeon_RV770_me_bin");
> > > +MODULE_FIRMWARE("radeon_RV730_pfp_bin");
> > > +MODULE_FIRMWARE("radeon_RV730_me_bin");
> > > +MODULE_FIRMWARE("radeon_RV710_pfp_bin");
> > > +MODULE_FIRMWARE("radeon_RV710_me_bin");
> > > +MODULE_FIRMWARE("radeon_R600_rlc_bin");
> > > +MODULE_FIRMWARE("radeon_R700_rlc_bin");
> > > +MODULE_FIRMWARE("radeon_CEDAR_pfp_bin");
> > > +MODULE_FIRMWARE("radeon_CEDAR_me_bin");
> > > +MODULE_FIRMWARE("radeon_CEDAR_rlc_bin");
> > > +MODULE_FIRMWARE("radeon_REDWOOD_pfp_bin");
> > > +MODULE_FIRMWARE("radeon_REDWOOD_me_bin");
> > > +MODULE_FIRMWARE("radeon_REDWOOD_rlc_bin");
> > > +MODULE_FIRMWARE("radeon_JUNIPER_pfp_bin");
> > > +MODULE_FIRMWARE("radeon_JUNIPER_me_bin");
> > > +MODULE_FIRMWARE("radeon_JUNIPER_rlc_bin");
> > > +MODULE_FIRMWARE("radeon_CYPRESS_pfp_bin");
> > > +MODULE_FIRMWARE("radeon_CYPRESS_me_bin");
> > > +MODULE_FIRMWARE("radeon_CYPRESS_rlc_bin");
> > > +MODULE_FIRMWARE("radeon_PALM_pfp_bin");
> > > +MODULE_FIRMWARE("radeon_PALM_me_bin");
> > > +MODULE_FIRMWARE("radeon_SUMO_rlc_bin");
> > > +MODULE_FIRMWARE("radeon_SUMO_pfp_bin");
> > > +MODULE_FIRMWARE("radeon_SUMO_me_bin");
> > > +MODULE_FIRMWARE("radeon_SUMO2_pfp_bin");
> > > +MODULE_FIRMWARE("radeon_SUMO2_me_bin");
> > >  #endif
> > >
> > >  int r600_debugfs_mc_info_init(struct radeon_device *rdev);
> > > @@ -2066,7 +2066,7 @@ int r600_init_microcode(struct radeon_device
> *rdev)
> > >         DRM_INFO("Loading %s Microcode\n", chip_name);
> > >         err = 0;
> > >
> > > -       snprintf(fw_name, sizeof(fw_name), "radeon/%s_pfp.bin",
> chip_name);
> > > +       snprintf(fw_name, sizeof(fw_name), "radeon_%s_pfp_bin",
> chip_name);
> > >         rdev->pfp_fw = firmware_get(fw_name);
> > >         if (rdev->pfp_fw == NULL) {
> > >                 err = -ENOENT;
> > > @@ -2080,7 +2080,7 @@ int r600_init_microcode(struct radeon_device
> *rdev)
> > >                 goto out;
> > >         }
> > >
> > > -       snprintf(fw_name, sizeof(fw_name), "radeon/%s_me.bin",
> chip_name);
> > > +       snprintf(fw_name, sizeof(fw_name), "radeon_%s_me_bin",
> chip_name);
> > >         rdev->me_fw = firmware_get(fw_name);
> > >         if (rdev->me_fw == NULL) {
> > >                 err = -ENOENT;
> > > @@ -2093,7 +2093,7 @@ int r600_init_microcode(struct radeon_device
> *rdev)
> > >                 err = -EINVAL;
> > >         }
> > >
> > > -       snprintf(fw_name, sizeof(fw_name), "radeon/%s_rlc.bin",
> > > rlc_chip_name);
> > > +       snprintf(fw_name, sizeof(fw_name), "radeon_%s_rlc_bin",
> > > rlc_chip_name);
> > >         rdev->rlc_fw = firmware_get(fw_name);
> > >         if (rdev->rlc_fw == NULL) {
> > >                 err = -ENOENT;
> > > diff --git a/src/dev/drm2/radeon/r600_cp.c
> b/src/dev/drm2/radeon/r600_cp.c
> > > index 3c6462e..9382cb5 100644
> > > --- a/src/dev/drm2/radeon/r600_cp.c
> > > +++ b/src/dev/drm2/radeon/r600_cp.c
> > > @@ -46,26 +46,26 @@ __FBSDID("$FreeBSD$");
> > >
> > >  #ifdef __linux__
> > >  /* Firmware Names */
> > > -MODULE_FIRMWARE("radeon/R600_pfp.bin");
> > > -MODULE_FIRMWARE("radeon/R600_me.bin");
> > > -MODULE_FIRMWARE("radeon/RV610_pfp.bin");
> > > -MODULE_FIRMWARE("radeon/RV610_me.bin");
> > > -MODULE_FIRMWARE("radeon/RV630_pfp.bin");
> > > -MODULE_FIRMWARE("radeon/RV630_me.bin");
> > > -MODULE_FIRMWARE("radeon/RV620_pfp.bin");
> > > -MODULE_FIRMWARE("radeon/RV620_me.bin");
> > > -MODULE_FIRMWARE("radeon/RV635_pfp.bin");
> > > -MODULE_FIRMWARE("radeon/RV635_me.bin");
> > > -MODULE_FIRMWARE("radeon/RV670_pfp.bin");
> > > -MODULE_FIRMWARE("radeon/RV670_me.bin");
> > > -MODULE_FIRMWARE("radeon/RS780_pfp.bin");
> > > -MODULE_FIRMWARE("radeon/RS780_me.bin");
> > > -MODULE_FIRMWARE("radeon/RV770_pfp.bin");
> > > -MODULE_FIRMWARE("radeon/RV770_me.bin");
> > > -MODULE_FIRMWARE("radeon/RV730_pfp.bin");
> > > -MODULE_FIRMWARE("radeon/RV730_me.bin");
> > > -MODULE_FIRMWARE("radeon/RV710_pfp.bin");
> > > -MODULE_FIRMWARE("radeon/RV710_me.bin");
> > > +MODULE_FIRMWARE("radeon_R600_pfp.bin");
> > > +MODULE_FIRMWARE("radeon_R600_me.bin");
> > > +MODULE_FIRMWARE("radeon_RV610_pfp.bin");
> > > +MODULE_FIRMWARE("radeon_RV610_me.bin");
> > > +MODULE_FIRMWARE("radeon_RV630_pfp.bin");
> > > +MODULE_FIRMWARE("radeon_RV630_me.bin");
> > > +MODULE_FIRMWARE("radeon_RV620_pfp.bin");
> > > +MODULE_FIRMWARE("radeon_RV620_me.bin");
> > > +MODULE_FIRMWARE("radeon_RV635_pfp.bin");
> > > +MODULE_FIRMWARE("radeon_RV635_me.bin");
> > > +MODULE_FIRMWARE("radeon_RV670_pfp.bin");
> > > +MODULE_FIRMWARE("radeon_RV670_me.bin");
> > > +MODULE_FIRMWARE("radeon_RS780_pfp.bin");
> > > +MODULE_FIRMWARE("radeon_RS780_me.bin");
> > > +MODULE_FIRMWARE("radeon_RV770_pfp.bin");
> > > +MODULE_FIRMWARE("radeon_RV770_me.bin");
> > > +MODULE_FIRMWARE("radeon_RV730_pfp.bin");
> > > +MODULE_FIRMWARE("radeon_RV730_me.bin");
> > > +MODULE_FIRMWARE("radeon_RV710_pfp.bin");
> > > +MODULE_FIRMWARE("radeon_RV710_me.bin");
> > >  #endif
> > >
> > >
> > > @@ -359,7 +359,7 @@ static int
> r600_cp_init_microcode(drm_radeon_private_t
> > > *dev_priv)
> > >         DRM_INFO("Loading %s CP Microcode\n", chip_name);
> > >         err = 0;
> > >
> > > -       snprintf(fw_name, sizeof(fw_name), "radeon/%s_pfp.bin",
> chip_name);
> > > +       snprintf(fw_name, sizeof(fw_name), "radeon_%s_pfp.bin",
> chip_name);
> > >         dev_priv->pfp_fw = firmware_get(fw_name);
> > >         if (dev_priv->pfp_fw == NULL) {
> > >                 err = -ENOENT;
> > > @@ -373,7 +373,7 @@ static int
> r600_cp_init_microcode(drm_radeon_private_t
> > > *dev_priv)
> > >                 goto out;
> > >         }
> > >
> > > -       snprintf(fw_name, sizeof(fw_name), "radeon/%s_me.bin",
> chip_name);
> > > +       snprintf(fw_name, sizeof(fw_name), "radeon_%s_me.bin",
> chip_name);
> > >         dev_priv->me_fw = firmware_get(fw_name);
> > >         if (dev_priv->me_fw == NULL) {
> > >                 err = -ENOENT;
> > > diff --git a/src/dev/drm2/radeon/si.c b/src/dev/drm2/radeon/si.c
> > > index 394b93a..1ac5d78 100644
> > > --- a/src/dev/drm2/radeon/si.c
> > > +++ b/src/dev/drm2/radeon/si.c
> > > @@ -41,21 +41,21 @@ __FBSDID("$FreeBSD$");
> > >  #define SI_MC_UCODE_SIZE 7769
> > >
> > >  #ifdef __linux__
> > > -MODULE_FIRMWARE("radeon/TAHITI_pfp.bin");
> > > -MODULE_FIRMWARE("radeon/TAHITI_me.bin");
> > > -MODULE_FIRMWARE("radeon/TAHITI_ce.bin");
> > > -MODULE_FIRMWARE("radeon/TAHITI_mc.bin");
> > > -MODULE_FIRMWARE("radeon/TAHITI_rlc.bin");
> > > -MODULE_FIRMWARE("radeon/PITCAIRN_pfp.bin");
> > > -MODULE_FIRMWARE("radeon/PITCAIRN_me.bin");
> > > -MODULE_FIRMWARE("radeon/PITCAIRN_ce.bin");
> > > -MODULE_FIRMWARE("radeon/PITCAIRN_mc.bin");
> > > -MODULE_FIRMWARE("radeon/PITCAIRN_rlc.bin");
> > > -MODULE_FIRMWARE("radeon/VERDE_pfp.bin");
> > > -MODULE_FIRMWARE("radeon/VERDE_me.bin");
> > > -MODULE_FIRMWARE("radeon/VERDE_ce.bin");
> > > -MODULE_FIRMWARE("radeon/VERDE_mc.bin");
> > > -MODULE_FIRMWARE("radeon/VERDE_rlc.bin");
> > > +MODULE_FIRMWARE("radeon_TAHITI_pfp_bin");
> > > +MODULE_FIRMWARE("radeon_TAHITI_me_bin");
> > > +MODULE_FIRMWARE("radeon_TAHITI_ce_bin");
> > > +MODULE_FIRMWARE("radeon_TAHITI_mc_bin");
> > > +MODULE_FIRMWARE("radeon_TAHITI_rlc_bin");
> > > +MODULE_FIRMWARE("radeon_PITCAIRN_pfp_bin");
> > > +MODULE_FIRMWARE("radeon_PITCAIRN_me_bin");
> > > +MODULE_FIRMWARE("radeon_PITCAIRN_ce_bin");
> > > +MODULE_FIRMWARE("radeon_PITCAIRN_mc_bin");
> > > +MODULE_FIRMWARE("radeon_PITCAIRN_rlc_bin");
> > > +MODULE_FIRMWARE("radeon_VERDE_pfp_bin");
> > > +MODULE_FIRMWARE("radeon_VERDE_me_bin");
> > > +MODULE_FIRMWARE("radeon_VERDE_ce_bin");
> > > +MODULE_FIRMWARE("radeon_VERDE_mc_bin");
> > > +MODULE_FIRMWARE("radeon_VERDE_rlc_bin");
> > >  #endif
> > >
> > >  #ifdef FREEBSD_WIP /* FreeBSD: to please GCC 4.2. */
> > > @@ -325,7 +325,7 @@ static int si_init_microcode(struct radeon_device
> > > *rdev)
> > >         DRM_INFO("Loading %s Microcode\n", chip_name);
> > >         err = 0;
> > >
> > > -       snprintf(fw_name, sizeof(fw_name), "radeon/%s_pfp.bin",
> chip_name);
> > > +       snprintf(fw_name, sizeof(fw_name), "radeon_%s_pfp_bin",
> chip_name);
> > >         rdev->pfp_fw = drm_firmware_get(fw_name, rdev->dev);
> > >         if (rdev->pfp_fw == NULL) {
> > >                 err = -ENOENT;
> > > @@ -339,7 +339,7 @@ static int si_init_microcode(struct radeon_device
> > > *rdev)
> > >                 goto out;
> > >         }
> > >
> > > -       snprintf(fw_name, sizeof(fw_name), "radeon/%s_me.bin",
> chip_name);
> > > +       snprintf(fw_name, sizeof(fw_name), "radeon_%s_me_bin",
> chip_name);
> > >         rdev->me_fw = drm_firmware_get(fw_name, rdev->dev);
> > >         if (rdev->me_fw == NULL) {
> > >                 err = -ENOENT;
> > > @@ -352,7 +352,7 @@ static int si_init_microcode(struct radeon_device
> > > *rdev)
> > >                 err = -EINVAL;
> > >         }
> > >
> > > -       snprintf(fw_name, sizeof(fw_name), "radeon/%s_ce.bin",
> chip_name);
> > > +       snprintf(fw_name, sizeof(fw_name), "radeon_%s_ce_bin",
> chip_name);
> > >         rdev->ce_fw = drm_firmware_get(fw_name, rdev->dev);
> > >         if (rdev->ce_fw == NULL) {
> > >                 err = -ENOENT;
> > > @@ -365,7 +365,7 @@ static int si_init_microcode(struct radeon_device
> > > *rdev)
> > >                 err = -EINVAL;
> > >         }
> > >
> > > -       snprintf(fw_name, sizeof(fw_name), "radeon/%s_rlc.bin",
> > > rlc_chip_name);
> > > +       snprintf(fw_name, sizeof(fw_name), "radeon_%s_rlc_bin",
> > > rlc_chip_name);
> > >         rdev->rlc_fw = drm_firmware_get(fw_name, rdev->dev);
> > >         if (rdev->rlc_fw == NULL) {
> > >                 err = -ENOENT;
> > > @@ -378,7 +378,7 @@ static int si_init_microcode(struct radeon_device
> > > *rdev)
> > >                 err = -EINVAL;
> > >         }
> > >
> > > -       snprintf(fw_name, sizeof(fw_name), "radeon/%s_mc.bin",
> chip_name);
> > > +       snprintf(fw_name, sizeof(fw_name), "radeon_%s_mc_bin",
> chip_name);
> > >         rdev->mc_fw = drm_firmware_get(fw_name, rdev->dev);
> > >         if (rdev->mc_fw == NULL) {
> > >                 err = -ENOENT;
> > >
>
> --
> Steve
> 20170425 https://www.youtube.com/watch?v=VWUpyCsUKR4
> 20161221 https://www.youtube.com/watch?v=IbCHE-hONow
>



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CAECmPwvO0N%2B_L7Keyq_XvgB%2BRcZGRoN90e_Qja-yahPKaPpv5g>