NetBSD-Users archive

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

Re: X on 10.0 RC1 is unusable on my laptop



On Wed, Nov 15, 2023 at 10:46:13PM +0100, Rhialto wrote:
> On Wed 15 Nov 2023 at 18:36:10 +0100, tlaronde%kergis.com@localhost wrote:
> > After disabling i915drmkms*, you could modload i915drm (the old
> > module).
> 
> Ah, interesting idea! Unfortunately this leads to double definitions of
> some symbols:
> 
[...]
> [     1.000000] kobj_checksyms, 1036: [i915drm]: linker error: global symbol `i915_enable_pipestat' redefined
> [     1.000000] kobj_checksyms, 1036: [i915drm]: linker error: global symbol `i915_save_state' redefined 
> [     1.000000] kobj_checksyms, 1036: [i915drm]: linker error: global symbol `i915_get_vblank_counter' redefined
> [     1.000000] kobj_checksyms, 1036: [i915drm]: linker error: global symbol `i915_restore_state' redefined 
> [     1.000000] kobj_checksyms, 1036: [i915drm]: linker error: global symbol `i915_disable_pipestat' redefined
> [     1.000000] WARNING: module error: unable to load `i915drm' pushed by boot loader, error 8
> 
> so I built (tried, at least) a kernel without i915drmkms:
> 
> include "arch/amd64/conf/GENERIC"
> 
> no i915drmkms*
> no radeon*
> no nouveau*
> 
> i915drm*        at drm?         # Intel i915, i945 DRM driver
> 
> That resulted in both undefined and double defined symbols...
> so I tried the more oldfashioned way of editing a copy of GENERIC and
> removing stuff (like the above). Still the same kind of linking errors..
> 
> example of double definition:
> 
> /home/rhialto/NetBSD-10/usr/src/sys/arch/amd64/compile/GENERIC_NOKMS/../../../../external/bsd/drm2/drm/drm_agp_hook.c:140:
> multiple definition of `drm_agp_init';
> drm_agpsupport.o:/home/rhialto/NetBSD-10/usr/src/sys/arch/amd64/compile/GENERIC_NOKMS/../../../../external/bsd/drm/dist/bsd-core/drm_agpsupport.c:404:
> first defined here
> 
> It looks like drm_agp_hook.c should not be included, but how do I find
> out what pulls it in?
> 
> Further removing "genfb*" seemed helpful, after grepping a lot through
> all files.* files, but that didn't do the trick.
> 
> Example of undefined symbol:
> 
> ld: i915_drv.o: in function `i915drm_detach':
> /home/rhialto/NetBSD-10/usr/src/sys/arch/amd64/compile/GENERIC_NOKMS/../../../../external/bsd/drm/dist/bsd-core/i915_drv.c:212: undefined reference to `drm_detach'
> 
> I've been stripping down the kernel config more and more, but still the
> same problems remain. "config -ddddddd" isn't too helpful, in the end;
> it leaves out crucial information of "why is this thing included". It
> seems like most of the output isn't even related to the actually
> configured devices, but all of the possible ones, which makes it hard to
> find the relevant parts.
> 

It was worth the try since the question has been raised whether it
was worth still including the old drm drivers as loadable modules
since the developers having worked on drmkms (drm2) were not sure if
the modules would still work or not.

I fear that a significant work would have to be done to disentangle
things so that drm could be a fallback if drmkms is failing.

But for this, only the developers having worked on the code could give an
authoritative answer.

I think you should make a PR of the whole story.

Thanks for taking the time to test the suggestion and to report!
-- 
        Thierry Laronde <tlaronde +AT+ kergis +dot+ com>
                     http://www.kergis.com/
                    http://kertex.kergis.com/
Key fingerprint = 0FF7 E906 FBAF FE95 FD89  250D 52B1 AE95 6006 F40C


Home | Main Index | Thread Index | Old Index