Using drm-next in 11.2
So, I was trying to switch to using this, as I realise its where things are heading, and I rather like the look of it. But I cant get it to see my multiple monitors. I install the port, set 'kld_list="amdgpu"' and it boots up with the new modules, and appears to find all my displays in dmesg. But when I start X it only uses the single display port, mirroring it to DVI. When I start X what I am seeing in dmesg is this: module_register: cannot register drmn from drm2.ko; already loaded from drm.ko Module drmn failed to register: 17 KLD radeonkms.ko: depends on drmn - not available or version mismatch linker_load_file: Unsupported file type Which make me think theres some clash with the old modules and thats why its not working properly. Also xrandr only lists a single screen, as default, unlike the list I get using the old drm, which lists all the outpus correctly. Anyone got any advice, or can point me to the coorrect place for this ? cheers, -pete. ___ freebsd-stable@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/freebsd-stable To unsubscribe, send any mail to "freebsd-stable-unsubscr...@freebsd.org"
Re: Using drm-next in 11.2
On Tue, Sep 11, 2018, 14:52 Pete French wrote: > So, I was trying to switch to using this, as I realise its where things > are heading, and I rather like the look of it. But I cant get it to see my > multiple monitors. I install the port, set 'kld_list="amdgpu"' and it boots > up with the new modules, and appears to find all my displays in dmesg. But > when I start X it only uses the single display port, mirroring it to DVI. > > > When I start X what I am seeing in dmesg is this: > > module_register: cannot register drmn from drm2.ko; already loaded from > drm.ko > Module drmn failed to register: 17 > KLD radeonkms.ko: depends on drmn - not available or version mismatch > linker_load_file: Unsupported file type > > Which make me think theres some clash with the old modules and thats why > its not > working properly. Also xrandr only lists a single screen, as default, > unlike > the list I get using the old drm, which lists all the outpus correctly. > > Anyone got any advice, or can point me to the coorrect place for this ? > > cheers, > > -pete. > I think you have to use kld_list="/boot/modules/amdgpu.ko" to get the new one. Best regards Andreas > > ___ freebsd-stable@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/freebsd-stable To unsubscribe, send any mail to "freebsd-stable-unsubscr...@freebsd.org"
Re: Using drm-next in 11.2
I think you have to use kld_list="/boot/modules/amdgpu.ko" to get the new one. Will give it a try - I think its unnecessary as the name doesnt clash, but worth a go... -pete. [quick reboot comming up] ___ freebsd-stable@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/freebsd-stable To unsubscribe, send any mail to "freebsd-stable-unsubscr...@freebsd.org"
Re: Using drm-next in 11.2
On 11/09/2018 14:42, Pete French wrote: I think you have to use kld_list="/boot/modules/amdgpu.ko" to get the new one. Will give it a try - I think its unnecessary as the name doesnt clash, but worth a go... -pete. [quick reboot comming up] I tired this, it doesnt help - I tink it alway was loading that one - but I also tried a few other things. Such as removing my ATI driver from Xorg and adding the amdgpu driver istead. Still no luck unfortunately. -pete. ___ freebsd-stable@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/freebsd-stable To unsubscribe, send any mail to "freebsd-stable-unsubscr...@freebsd.org"
Re: Using drm-next in 11.2
I agree it sounds like a clash with older modules. Did you have drm-stable-kmod installed or drm-legacy-kmod installed? If so, make sure you remove them before. Sounds to me like what is probably happening is you have modules from two different drm ports installed. So I'd try a make deinstall inside drm-stable-kmod and drm-legacy-kmod directories and see if that fixes anything. On Tue, 11 Sep 2018 13:50:24 +0100 Pete French wrote: > So, I was trying to switch to using this, as I realise its where > things are heading, and I rather like the look of it. But I cant get > it to see my multiple monitors. I install the port, set > 'kld_list="amdgpu"' and it boots up with the new modules, and appears > to find all my displays in dmesg. But when I start X it only uses the > single display port, mirroring it to DVI. > > > When I start X what I am seeing in dmesg is this: > > module_register: cannot register drmn from drm2.ko; already loaded > from drm.ko Module drmn failed to register: 17 > KLD radeonkms.ko: depends on drmn - not available or version mismatch > linker_load_file: Unsupported file type > > Which make me think theres some clash with the old modules and thats > why its not working properly. Also xrandr only lists a single screen, > as default, unlike the list I get using the old drm, which lists all > the outpus correctly. > > Anyone got any advice, or can point me to the coorrect place for > this ? > > cheers, > > -pete. > ___ > freebsd-stable@freebsd.org mailing list > https://lists.freebsd.org/mailman/listinfo/freebsd-stable > To unsubscribe, send any mail to > "freebsd-stable-unsubscr...@freebsd.org" ___ freebsd-stable@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/freebsd-stable To unsubscribe, send any mail to "freebsd-stable-unsubscr...@freebsd.org"
Re: Using drm-next in 11.2
I dont have any other drm ports installed though - I think te clash is with the ones which are part of the standard kernel build maybe ? Possibly I could try building a custom kernel without them, but first am going to go susbscribe to x11 amiling list and see what they say. -pete. On 11/09/2018 16:29, CL Moonriver wrote: I agree it sounds like a clash with older modules. Did you have drm-stable-kmod installed or drm-legacy-kmod installed? If so, make sure you remove them before. Sounds to me like what is probably happening is you have modules from two different drm ports installed. So I'd try a make deinstall inside drm-stable-kmod and drm-legacy-kmod directories and see if that fixes anything. On Tue, 11 Sep 2018 13:50:24 +0100 Pete French wrote: So, I was trying to switch to using this, as I realise its where things are heading, and I rather like the look of it. But I cant get it to see my multiple monitors. I install the port, set 'kld_list="amdgpu"' and it boots up with the new modules, and appears to find all my displays in dmesg. But when I start X it only uses the single display port, mirroring it to DVI. When I start X what I am seeing in dmesg is this: module_register: cannot register drmn from drm2.ko; already loaded from drm.ko Module drmn failed to register: 17 KLD radeonkms.ko: depends on drmn - not available or version mismatch linker_load_file: Unsupported file type Which make me think theres some clash with the old modules and thats why its not working properly. Also xrandr only lists a single screen, as default, unlike the list I get using the old drm, which lists all the outpus correctly. Anyone got any advice, or can point me to the coorrect place for this ? cheers, -pete. ___ freebsd-stable@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/freebsd-stable To unsubscribe, send any mail to "freebsd-stable-unsubscr...@freebsd.org" ___ freebsd-stable@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/freebsd-stable To unsubscribe, send any mail to "freebsd-stable-unsubscr...@freebsd.org"
Re: Using drm-next in 11.2
Well, I have one other suggestion, but this is just completely guesswork on my part. However, I ran into a problem where the "amdgpu" module did not work, though I can't remember the exact error messages I got. You mentioned you had the ATI driver installed in X. Given that, are you sure amdgpu is the right module you need in kld_list? Are you sure it's not radeonkms? Again. that's what nailed me the first time. I DO have an AMD GPU (A10 series). But it uses Radeon R7 graphics. So despite the fact that my GPU is build into the processor, I needed the radeonkms driver, not the amdgpu driver. On Tue, 11 Sep 2018 17:22:24 +0100 Pete French wrote: > I dont have any other drm ports installed though - I think te clash > is with the ones which are part of the standard kernel build maybe ? > Possibly I could try building a custom kernel without them, but first > am going to go susbscribe to x11 amiling list and see what they say. > > -pete. > > On 11/09/2018 16:29, CL Moonriver wrote: > > I agree it sounds like a clash with older modules. Did you have > > drm-stable-kmod installed or drm-legacy-kmod installed? If so, make > > sure you remove them before. Sounds to me like what is probably > > happening is you have modules from two different drm ports > > installed. So I'd try a make deinstall inside drm-stable-kmod and > > drm-legacy-kmod directories and see if that fixes anything. > > > > On Tue, 11 Sep 2018 13:50:24 +0100 > > Pete French wrote: > > > >> So, I was trying to switch to using this, as I realise its where > >> things are heading, and I rather like the look of it. But I cant > >> get it to see my multiple monitors. I install the port, set > >> 'kld_list="amdgpu"' and it boots up with the new modules, and > >> appears to find all my displays in dmesg. But when I start X it > >> only uses the single display port, mirroring it to DVI. > >> > >> > >> When I start X what I am seeing in dmesg is this: > >> > >> module_register: cannot register drmn from drm2.ko; already loaded > >> from drm.ko Module drmn failed to register: 17 > >> KLD radeonkms.ko: depends on drmn - not available or version > >> mismatch linker_load_file: Unsupported file type > >> > >> Which make me think theres some clash with the old modules and > >> thats why its not working properly. Also xrandr only lists a > >> single screen, as default, unlike the list I get using the old > >> drm, which lists all the outpus correctly. > >> > >> Anyone got any advice, or can point me to the coorrect place for > >> this ? > >> > >> cheers, > >> > >> -pete. > >> ___ > >> freebsd-stable@freebsd.org mailing list > >> https://lists.freebsd.org/mailman/listinfo/freebsd-stable > >> To unsubscribe, send any mail to > >> "freebsd-stable-unsubscr...@freebsd.org" > > ___ freebsd-stable@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/freebsd-stable To unsubscribe, send any mail to "freebsd-stable-unsubscr...@freebsd.org"
Re: Using drm-next in 11.2
P.S. I can pretty guarantee you that you do NOT need to build a custom kernel. I have an A10 series CPU with onboard Radeon R7 graphics. So again, if amdgpu isn't working, try radeonkms instead. Maybe that will fix your problem. Also, are you booting using UEFI or Legacy / BIOS mode? On Tue, 11 Sep 2018 17:22:24 +0100 Pete French wrote: > I dont have any other drm ports installed though - I think te clash > is with the ones which are part of the standard kernel build maybe ? > Possibly I could try building a custom kernel without them, but first > am going to go susbscribe to x11 amiling list and see what they say. > > -pete. > > On 11/09/2018 16:29, CL Moonriver wrote: > > I agree it sounds like a clash with older modules. Did you have > > drm-stable-kmod installed or drm-legacy-kmod installed? If so, make > > sure you remove them before. Sounds to me like what is probably > > happening is you have modules from two different drm ports > > installed. So I'd try a make deinstall inside drm-stable-kmod and > > drm-legacy-kmod directories and see if that fixes anything. > > > > On Tue, 11 Sep 2018 13:50:24 +0100 > > Pete French wrote: > > > >> So, I was trying to switch to using this, as I realise its where > >> things are heading, and I rather like the look of it. But I cant > >> get it to see my multiple monitors. I install the port, set > >> 'kld_list="amdgpu"' and it boots up with the new modules, and > >> appears to find all my displays in dmesg. But when I start X it > >> only uses the single display port, mirroring it to DVI. > >> > >> > >> When I start X what I am seeing in dmesg is this: > >> > >> module_register: cannot register drmn from drm2.ko; already loaded > >> from drm.ko Module drmn failed to register: 17 > >> KLD radeonkms.ko: depends on drmn - not available or version > >> mismatch linker_load_file: Unsupported file type > >> > >> Which make me think theres some clash with the old modules and > >> thats why its not working properly. Also xrandr only lists a > >> single screen, as default, unlike the list I get using the old > >> drm, which lists all the outpus correctly. > >> > >> Anyone got any advice, or can point me to the coorrect place for > >> this ? > >> > >> cheers, > >> > >> -pete. > >> ___ > >> freebsd-stable@freebsd.org mailing list > >> https://lists.freebsd.org/mailman/listinfo/freebsd-stable > >> To unsubscribe, send any mail to > >> "freebsd-stable-unsubscr...@freebsd.org" > > ___ freebsd-stable@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/freebsd-stable To unsubscribe, send any mail to "freebsd-stable-unsubscr...@freebsd.org"
Re: Using drm-next in 11.2
On 9/11/18 7:44 AM, Pete French wrote: On 11/09/2018 14:42, Pete French wrote: I think you have to use kld_list="/boot/modules/amdgpu.ko" to get the new one. Will give it a try - I think its unnecessary as the name doesnt clash, but worth a go... -pete. [quick reboot comming up] I tired this, it doesnt help - I tink it alway was loading that one - but I also tried a few other things. Such as removing my ATI driver from Xorg and adding the amdgpu driver istead. Still no luck unfortunately. can you post your dmesg output from when you've set kld_list="/boot/modules/amdgpu.ko"? also, please verify that your user is in the "video" group. but from what you've described it sounds like a conflict is popping up between the base amdgpu.ko and the one available in the ports tree. also, please ensure you are booting in "classic" BIOS mode and not UEFI, IIRC there are some issues surrounding amdgpu with UEFI - i don't have that hardware tho so can't elaborate. -p -- Pete Wright p...@nomadlogic.org @nomadlogicLA ___ freebsd-stable@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/freebsd-stable To unsubscribe, send any mail to "freebsd-stable-unsubscr...@freebsd.org"
Re: Using drm-next in 11.2
> also, please ensure you are booting in "classic" BIOS mode and not > UEFI, IIRC there are some issues surrounding amdgpu with UEFI - i > don't have that hardware tho so can't elaborate. Just to add to this, the conflicts involve kernel mode switching between the scfb driver and the AMD driver. However, there are work arounds for it. And in all honesty, with AMD A10 series CPU, I've actually found it easier to get things working properly in UEFI mode instead of classic / legacy / bios mode. The work around (as I learned from a thread in the x11 mailing lists) involves disabling the system console completely by adding hw.syscons.disable=1 to /boot/loader.conf. Obviously, this is not without some risk. But it does work for me. And I have had no problems at all with radeonkms.ko since doing this. (The only problem I had before adding this was the occasional X server hang where the GPU had to be restarted. But even that problem is gone now.) ___ freebsd-stable@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/freebsd-stable To unsubscribe, send any mail to "freebsd-stable-unsubscr...@freebsd.org"
Re: Constraints in libmap(32).conf do not work as expected, possible bug in rtld-elf
Thanks very much for answer ! Now I use the following libmap32.conf: ## php52 [/usr/local/php52/lib/php/20060613/mysql.so] /usr/local/lib/mysql/usr/local/lib32/mysql [/usr/local/php52/] /usr/local/lib /usr/local/lib32 > I am having problem understanding what do you mean by step1/step2. The > refobj reference that you cache in the patch, comes into load_object() > as the pointer to the object which initiate the load_object() call. It > is NULL for preloaded objects, otherwise it is not. > So, could you, please, explain where does it get passed as NULL in your > case ? Ok, I try to explain better: step1 means: call of lm_find() in rtld.c (line 1500) and first argument is refobj->path, which is used in libmap.c to find the correct entry in the lmp_list. step2 means: call of lm_findn() in rtld.c (line 2834) when called from search_library_path(). In this case the first argument is NULL and in libmap.c this means "$DEFAULT" entry in the lmp_list. Please notice that after reading libmap32.conf in lm_init() the entry $DEFAULT in the lmp_list does not exist, when all mappings are defined with constraints. > Also, your patch makes the ref_object stuck for all future invocations > of the load_object(), so it cannot be correct for this reason alone. I do not think so. The patch only caches refobj->path from step1 to use the same path in step2. I have updated my patch a little bit to clarify, that the patch only wants to change the call of lm_findn() in the case of search_library_path(): --- rtld.c.orig 2018-03-20 16:56:48.0 +0100 +++ rtld.c 2018-09-11 21:44:03.333739000 +0200 @@ -186,6 +186,7 @@ static Obj_Entry obj_rtld; /* The dynamic linker shared object */ static unsigned int obj_count; /* Number of objects in obj_list */ static unsigned int obj_loads; /* Number of loads of objects (gen count) */ +static char *lm_refobj_path = NULL; static Objlist list_global = /* Objects dlopened with RTLD_GLOBAL */ STAILQ_HEAD_INITIALIZER(list_global); @@ -1496,6 +1497,8 @@ __DECONST(char *, xname))); } +if (objgiven) + lm_refobj_path = refobj->path; if (libmap_disable || !objgiven || (name = lm_find(refobj->path, xname)) == NULL) name = (char *)xname; @@ -1513,8 +1516,10 @@ (refobj != NULL && (pathname = search_library_path(name, refobj->rpath)) != NULL) || (pathname = search_library_path(name, gethints(false))) != NULL || - (pathname = search_library_path(name, STANDARD_LIBRARY_PATH)) != NULL) + (pathname = search_library_path(name, STANDARD_LIBRARY_PATH)) != NULL) { + lm_refobj_path = NULL; return (pathname); + } } else { nodeflib = objgiven ? refobj->z_nodeflib : false; if ((objgiven && @@ -1526,10 +1531,13 @@ (pathname = search_library_path(name, refobj->runpath)) != NULL) || (pathname = search_library_path(name, gethints(nodeflib))) != NULL || (objgiven && !nodeflib && - (pathname = search_library_path(name, STANDARD_LIBRARY_PATH)) != NULL)) + (pathname = search_library_path(name, STANDARD_LIBRARY_PATH)) != NULL)) { + lm_refobj_path = NULL; return (pathname); + } } +lm_refobj_path = NULL; if (objgiven && refobj->path != NULL) { _rtld_error("Shared object \"%s\" not found, required by \"%s\"", name, basename(refobj->path)); @@ -2831,7 +2839,7 @@ char *res; len = strcspn(path, ":;"); - trans = lm_findn(NULL, path, len); + trans = lm_findn(lm_refobj_path, path, len); if (trans) res = callback(trans, strlen(trans), arg); else > Another note is that libmap.conf use that you put it for, is quite the > strengthen of the original purpose. You should just add the pathes > with your libraries to LD_32_LIBRARY_PATH or configure them into > /var/run/ld-elf32.so.hints using 'ldconfig -32'. I have tried this without success. With the original ld-elf32.so.1 and my constraints in libmap32.conf I got the following: -> /usr/local/php52/bin/php -v Shared object "libxml2.so.5" not found, required by "php" The error changed after setting LD_32_LIBRARY_PATH or (with same result) the file /var/run/ld-elf32.so.hints using 'ldconfig -32. -> export LD_32_LIBRARY_PATH="/usr/local/lib32:/usr/local/lib32/mysql" -> /usr/local/php52/bin/php -v /usr/local/lib/libiconv.so.3: unsupported file layout This error disappears when I move this 64-bit library libiconv.so away, but thats not a solution. For your information I append the beginning of the dynamic section from readelf output of /usr/local/php52/bin/php: TagType Name/Value 0x0001 (NEEDED) Shared library: [libcrypt.so.5] 0x0001 (NEEDED) Shared library: [librt.so.1] 0x0001 (NEEDED) Shared library: [libm.so.5] 0x0001 (NEEDED)