[PATCH 2/2] Restore automated load of radeon kernel module.

Michel Dänzer michel at daenzer.net
Thu Dec 19 18:17:05 PST 2013


On Don, 2013-12-19 at 11:49 +0000, Robert Millan wrote:
> 
> diff --git a/src/radeon_probe.c b/src/radeon_probe.c
> index baca574..e37cfa1 100644
> --- a/src/radeon_probe.c
> +++ b/src/radeon_probe.c
> @@ -46,6 +46,7 @@
>  #include "atipcirename.h"
>  
>  #include "xf86.h"
> +#include <xf86_OSproc.h>
>  
>  #include "xf86drmMode.h"
>  #include "dri.h"
> @@ -92,6 +93,16 @@ static Bool radeon_kernel_mode_enabled(ScrnInfoPtr
> pScrn, struct pci_device *pci
>  
>      busIdString = DRICreatePCIBusID(pci_dev);
>      ret = drmCheckModesettingSupported(busIdString);
> +    if (ret) {
> +      if (xf86LoadKernelModule(
> +#if defined(__FreeBSD__) || defined(__FreeBSD_kernel__)
> +                              "radeonkms"
> +#else
> +                              "radeon"
> +#endif
> +                              ))
> +        ret = drmCheckModesettingSupported(busIdString);
> +    }
>      free(busIdString);
>      if (ret) {
>        xf86DrvMsgVerb(pScrn->scrnIndex, X_INFO, 0,

As Alex explained in your Debian bug report, there are several reasons
why the kernel driver should be loaded independently from X, e.g. to
enable power management or for running 3D or compute apps without X
(think Wayland e.g.).

Also, loading the kernel driver from X most definitely won't work
reliably at least on Linux, which is why it was effectively disabled.

So, I think it would be better in the long term if you made sure the
kernel driver is loaded independently from X on FreeBSD as well. In the
meantime, if loading the kernel driver from X works reliably on FreeBSD,
feel free to resend the patch with the kernel module loading added for
FreeBSD only (and with the Git commit log enhanced per your other
patch).


-- 
Earthling Michel Dänzer            |                  http://www.amd.com
Libre software enthusiast          |                Mesa and X developer



More information about the xorg-driver-ati mailing list