# kld_list="i915kms" does not stick on /etc/rc.conf at all.



## ziomario (Jul 24, 2021)

Hello.

I've added this parameter to /etc/rc.conf :

       kld_list="i915kms"

adding it on the rc.conf file should make the setting permanently,right ? But why,everytime I reboot the PC and I come back to FreeBSD,I should write "kldload i915kms",otherwise Xorg does not start,causing the error "cannot run in framebuffer mode. Please specify busIDs" ?


----------



## Vull (Jul 24, 2021)

I'm looking at this post for cross-reference. You have several syntax problems in your configuration files. I can help with some of these problems - maybe not all, but at least some of them.

In /etc/sysctl.conf delete the line that says `kld_list="i915kms"` and add the lines `net.link.tap.up_on_open=1` and `net.inet.ip.forwarding=1`
In /etc/rc.conf keep the line kld_list="i915kms"[/cmd] - this is the correct file for this line.
In /boot/loader.conf change `fuse_load="YES"` to `fusefs_load="YES"`
In /boot/loader.conf delete the lines `net.link.tap.up_on_open: 1 -> 1` and `net.inet.ip.forwarding: 1 -> 1`
Then reboot and see if that helps.


----------



## ziomario (Jul 24, 2021)

1) SirDice told me to remove net.inet.ip.forwarding=1 from /etc/sysctl.conf and I haven't the parameter kld_list="i915kms" there. it was a typo.

2) ok

3) in my case on /boot/loader.conf fuse_load="YES" works great

4) in /boot/loader.conf I haven't any net.* and so on. It was a typo. sorry for these typos.

as a result the problem persists.


----------



## Geezer (Jul 24, 2021)

Do you have any other kld_list lines in your rc.conf?

Why don't you post the whole thing?


----------



## Deleted member 30996 (Jul 24, 2021)

Vull said:


> I'm looking at this post for cross-reference. You have several syntax problems in your configuration files. I can help with some of these problems...


I consolidated my post in that thread, where he does have his /etc/rc.conf posted.


----------



## Vull (Jul 24, 2021)

Trihexagonal said:


> I consolidated my post in that thread, where he does have his /etc/rc.conf posted.


He states above that his post in that thread contains typos. Frankly I'm more than a little bit baffled; perhaps things work differently on his arm64 system than they do on my amd64 system? For example, I can no longer use fuse_load="YES" and for some time now have had to use fusefs_load="YES" instead.

Edited to add reference: https://forums.freebsd.org/threads/how-do-i-load-fuse-properly-and-persistently.79738/


----------



## Deleted member 30996 (Jul 24, 2021)

He's got more than typos going on in his /etc/rc.conf, but I wasn't aware til you mentioned it that it was an arm64 system.


----------



## Vull (Jul 24, 2021)

Trihexagonal said:


> He's got more than typos going on in his /etc/rc.conf, but I wasn't aware til you mentioned it that it was an arm64 system.


He stated previously he's running arm64 on a Jetson Nano. I'm unfamiliar with arm64 and starting to think that, without doing more research, might not be knowledgeable enough to troubleshoot.


----------



## kpedersen (Jul 24, 2021)

Vull said:


> He stated previously he's running arm64 on a Jetson Nano.


I am not entirely convinced that is possible yet. There is too much NVIDIA weirdness.

Happy to be proven otherwise though. I have a drawer full of these things


----------



## ziomario (Jul 24, 2021)

In the recent past I made two kinds of questions. The first one is related to arm64 and the second one to amd64. I've been able to emulate freebsd arm64 on the jetson nano,even if not totally. Xorg and the desktop manager don't work,but I have configured X + ssh forwarding and I can run the Freebsd applications that need the graphical interface on the host system,even the whole desktop manager can be forwarded as u know. At the moment I have some problems to configure correctly Freebsd on amd64. Two problems. The first one is that kld_list="i915kms" seem to be not recognized by the rc.conf file and Xorg does not work if I don't write kldload i915kms before to write "startx" ; and the second one is related to Linux emulated with bhyve (without vm-bhyve) ; in short terms Linux can't connect to internet. It worked for sometime when SirDice suggested to remove the line "net.inet.ip.forwarding=1" from the file /etc/sysctl.conf and to add "gateway_enable="YES" to /etc/rc.conf ; but when I have rebooted,the problem comes out again. This is the rc.conf file that works (except for the ntpd ; the i915kms problem and the linux / bhyve problems)

/etc/rc.conf

sendmail_enable="NO"
hostname="marietto"
keymap="it.kbd"
ifconfig_em0="DHCP"
local_unbound_enable="YES"
sshd_enable="YES"
moused_enable="YES"
ntpdate_enable="YES"
ntpd_enable="YES"
powerd_enable="YES"
dumpdev="AUTO"
dbus_enable="YES"
hald_enable="YES"
slim_enable="YES"
sound_load="YES"
snd_hda_load="YES"
kld_list="i915kms"
libvirt_enable="YES"
linux_enable="YES"
zfs_enable="YES"
linux_mounts_enable="YES"
gateway_enable="YES"

/etc/sysctl.conf :

net.link.tap.up_on_open=1

/boot/loader.conf

vmm_load="YES"
nmdm_load="YES"
if_tap_load="YES"
if_bridge_load="YES"
fuse_load="YES"


/etc/resolv.conf
search homenet.telecomitalia.it
#nameserver 192.168.1.1
nameserver 127.0.0.1
options edns0

I've fixed the ntpd problem removing my lines and adding these :

ntpd_enable="YES"
ntpd_sync_on_start="YES"

I can start Xorg by writing kldload i915kms before to write "startx" ; but it's annoying ; the linux / bhyve problem is unresolved.


----------



## Vull (Jul 24, 2021)

Much of this is beyond my experience. I would try running `dmesg -a > dmesg.txt` as root and then search the text file dmesg.txt for some indication of why the system fails to load i915kms.ko - your /etc/rc.conf looks okay to me as far as I can see. Thanks.


----------



## ziomario (Jul 24, 2021)

do u want to give a look at this log ? https://pastebin.ubuntu.com/p/6Pxt8KWKk8/


----------



## grahamperrin@ (Jul 24, 2021)

ziomario said:


> `fuse_load="YES"`



You can remove that from /boot/loader.conf, or comment out the line.



ziomario said:


> `hald_enable="YES"`



You should remove this, it's redundant.



ziomario said:


> `kld_list="i915kms"`



Instead, try:

`kld_list="drm fusefs"`

– then restart the system. You might find that the start of SLiM will trigger a load of the Intel-specific module.


----------



## Vull (Jul 24, 2021)

Could you please also post output of `pciconf -lv > pciconf.txt` and /var/log/Xorg.0.log, and also /var/log/Xorg.1.log if that file exists? Thanks.


----------



## Vull (Jul 24, 2021)

grahamperrin said:


> -snip-
> 
> ... You might find that the start of SLiM will trigger a load of the Intel-specific module.


His system is starting lightdm at line 395 in his dmesg.txt log / Pastebin link, but for some reason I don't see lightdm_enable="YES" in his /etc/rc.conf file?

Please notice that everything in dmesg.txt after line 400 happens after lightdm starts, and everything before line 401 does not.

Edited to add:

@ grahamperrin - My amd64 13.0-RELEASE-p3 system has /boot/modules/fusefs.ko but does not have fuse.ko anywhere. Very strange.

@ ziomario - You might benefit from `freebsd-update fetch && freebsd-update install`


----------



## free-and-bsd (Jul 24, 2021)

I'm using kld_list="zfs i915kms" in /etc/rc.conf and it works fine! So it _is_ supposed to work for him as well. Since it works to load the module manually. 
Though I boot that laptop using GRUB, not UEFI (old model there). And I don't boot into X directly but start X after login. But yes, in the middle of the booting process i915kms is loaded and fb is started (shows up in the boot message feed).


----------



## ziomario (Jul 24, 2021)

Unfortunately these parameters don't fix the problem : xorg starts only loading the i915kms driver manually.

hostname="marietto"
keymap="it.kbd"
ifconfig_em0="DHCP"
local_unbound_enable="YES"
sshd_enable="YES"
powerd_enable="YES"
ntpdate_enable="YES"
ntpd_enable="YES"
ntpd_sync_on_start="YES"
dumpdev="NO"
dbus_enable="YES"
#hald_enable="YES"
slim_enable="YES"
sound_load="YES"
snd_hda_load="YES"
#kld_list="i915kms"
kld_list="drm"
#moused_enable="YES"
libvirt_enable="YES"
linux_enable="YES"
#zfs_enable="YES"
linux_mounts_enable="YES"
gateway_enable="YES"
kld_list="fusefs"
vm_enable="YES"
vm_dir="/vms/os/linux"
lightdm_enable="YES"
sendmail_enable="NO"
microcode_update_enable="YES"

pciconf -lv > pciconf.txt ---> https://pastebin.ubuntu.com/p/swthzwFCrB/
var/log/Xorg.0.log ---> https://pastebin.ubuntu.com/p/CMJyTStn7F/
/var/log/Xorg.1.log = 1


----------



## kpedersen (Jul 24, 2021)

ziomario said:


> #kld_list="i915kms"
> kld_list="drm"
> [...]
> kld_list="fusefs"


You have a lot in there so it is hard to notice but can you see you set kld_list twice? The second one replaces the original one.

So make sure you only have *one* `kld_list` line:


```
kld_list="fusefs i915kms"
```

Note, I am not sure what the `drm` module is. None of the docs mention it so I am inclined to believe it is a typo.


----------



## Vull (Jul 24, 2021)

kpedersen said:


> You have a lot in there so it is hard to notice but can you see you set kld_list twice? The second one replaces the original one.
> 
> So make sure you only have *one* `kld_list` line:
> 
> ...


My system has /boot/kernel/drm.ko which I believe probably comes from the drm-kmod port.

Good spotting - you're right, there must be only one `kld_list` statement in /etc/rc.conf, thanks.


----------



## Vull (Jul 25, 2021)

According to `pciconf -lv` output, and this thread: Thread no-devices-detected.80899, OP has a built-in "Intel Corporation CoffeeLake-S GT2 [UHD Graphics 630] (rev 02)" onboard video controller, but, in June, was trying to configure it to work with an NVIDEA card, and installed this proprietary closed-source Nvidia driver, which, according to SirDice in this post, may have overwritten some of the xorg libraries.

I recommend that ziomario should:

Double-check his BIOS setting to make sure that it is NOT using the Nvidia setting, and IS using the Intel setting.
Re-install the xorg libraries.
I'm not at all sure how complicated reinstalling the xorg libraries might be. It might be as simple as `pkg install -f xorg` but then again, it might be as complicated as:
`pkg delete xorg`
`pkg autoremove`
`pkg install xorg`

The way I normally do things, I would probably do a complete reinstall of the system, just to be sure I had removed all traces of the NIVIDEA configuration, but that might not be the best option for OP - it's his decision whether or not he might want to do that. First I would probably try the less drastic `pkg install -f xorg` just to see if it worked.


----------



## Deleted member 30996 (Jul 25, 2021)

I have to set this one to "Discreet" in the BIOS to get it to use Nivida on Optimus. Intel would be the other choice for a set driver on mine.



free-and-bsd said:


> And I don't boot into X directly but start X after login


I always use `startx`, too.


----------



## sidetone (Jul 25, 2021)

When you type df -g on the command line, is there anything particular about the partition that holds the directory /etc or /?


----------



## grahamperrin@ (Jul 25, 2021)

free-and-bsd said:


> kld_list="zfs i915kms"



ziomario instead please try:

`kld_list="drm fusefs"`

– and have *no more than one* _kld_list_ line.



kpedersen said:


> … `drm` … inclined to believe it is a typo.



Not a typo. Intentional.


----------



## grahamperrin@ (Jul 25, 2021)

From <https://forums.FreeBSD.org/threads/81340/post-524303> under another post, I assume that it's *FreeBSD 13.0-RELEASE-p3* in this post.



ziomario said:


> `zfs_enable="YES"`



This is correct. From rc.conf(5):


```
zfs_enable  (bool) If set to “YES”, /etc/rc.d/zfs will attempt to
                 automatically mount ZFS file systems and initialize ZFS
                 volumes (ZVOLs).
```



free-and-bsd said:


> `kld_list="zfs i915kms"`



It's unusual to have _zfs_ in that context (instead of `zfs_enable`), any special reason?


```
kld_list    (str) A whitespace-separated list of kernel modules to load
                 right after the local disks are mounted, without any .ko
                 extension or path.  Loading modules at this point in the boot
                 process is much faster than doing it via /boot/loader.conf
                 for those modules not necessary for mounting local disks.
```


----------



## grahamperrin@ (Jul 25, 2021)

Vull said:


> My system has /boot/kernel/drm.ko which I believe probably comes from the drm-kmod port.



Not directly.

For your AMD64 13.0-RELEASE-p3:

<https://cgit.freebsd.org/ports/tree...d=a7c4491bdcd6398146b8c05a361f02c6ac93c5c7#n2>

Here:


```
% uname -KorU
FreeBSD 14.0-CURRENT 1400026 1400026
% file /boot/kernel/drm.ko
/boot/kernel/drm.ko: cannot open `/boot/kernel/drm.ko' (No such file or directory)
% pkg provides boot/kernel/drm.ko
% pkg provides drm.ko
Name    : drm-devel-kmod-5.5.19.g20210709
Desc    : DRM modules for the linuxkpi-based KMS components (development version)
Repo    : FreeBSD
Filename: boot/modules/drm.ko

Name    : drm-current-kmod-5.4.92.g20210526
Desc    : DRM modules for the linuxkpi-based KMS components
Repo    : FreeBSD
Filename: boot/modules/drm.ko
%
```

Note to self:


```
% pkg query '%o %v %R' drm-current-kmod
graphics/drm-current-kmod 5.4.92.g20210526 FreeBSD
%
```

– more properly, I should have built and installed the module when I built the system. I'll build the module now.


----------



## Vull (Jul 25, 2021)

Sorry, meant to say /boot/modules/drm.ko My mistake


----------



## kpedersen (Jul 25, 2021)

grahamperrin said:


> Not a typo. Intentional.


Does just drm work on your machine rather than i915kms?

I suspect drm.ko is a dependency of i915kms.ko and gets automatically added. However the reverse is not true and i915kms *still* needs to be there explicitly.

The Linux kpi stuff has weak documentation. I don't suppose you can point towards anything?


----------



## grahamperrin@ (Jul 25, 2021)

kpedersen said:


> Does just `drm` work on your machine



Yes.

With FreeBSD 14.0-CURRENT on an HP EliteBook 8570p, necessarily *ignoring* the recommendation to specify `radeonkms`:


```
% sysrc kld_list sddm_enable
kld_list: fusefs usbhid drm
sddm_enable: YES
%
```

Result: 


```
% kldstat | grep -i radeon
58    1 0xffffffff83c44000   150c80 radeonkms.ko
60    1 0xffffffff83da4000     3258 radeon_TURKS_pfp_bin.ko
61    1 0xffffffff83da8000     3658 radeon_TURKS_me_bin.ko
62    1 0xffffffff83dac000     2cd8 radeon_BTC_rlc_bin.ko
63    1 0xffffffff83daf000     7ef8 radeon_TURKS_mc_bin.ko
64    1 0xffffffff83db7000     8138 radeon_TURKS_smc_bin.ko
65    1 0xffffffff83dc0000    341f0 radeon_SUMO_uvd_bin.ko
%
```



kpedersen said:


> … and `i915kms` *still* needs to be there explicitly. …



Yes and no. 

With FreeBSD 14.0-CURRENT on an HP ZBook 17 G2: 


```
% sysrc kld_list sddm_enable
kld_list: drm
sddm_enable: YES
%
```

Result: SDDM starts, albeit not at the resolution that's proper for the display. It does not tolerate a subsequent load of `i915kms` …

… however for now, for the purpose of diagnosing things for ziomario I'll be interested to know whether LightDM or SLiM – whatever is in his rc.conf at the time – can start automatically (compared to the opening post).


----------



## ziomario (Jul 25, 2021)

no. with LightDM or Slim declared as YES on the rc.conf file xorg does not start automatically. You gave me the idea to disable them and let's see if I have to load the i915kms driver manually or not this time.

UPDATE : with these changes,the problem is still present :


slim_enable="NO"
kld_list="i915kms"
lightdm_enable="NO"

Actually I launch Xorg invoking this little sh script :



> i915.sh
> 
> kldload i915kms
> startx



the previous installation of FreeBSD was done with GRUB and I didn't see this problem. Now I'm using EFI and I see it. Maybe this is the reason...


----------



## Vull (Jul 25, 2021)

According to both your dmesg log and your Xorg.0.log, your system detects 3 video devices, which seems to cause the system some confusion and conflict. You can see this in the dmesg log at lines 73, 82, and 84:
	
	



```
73 vgapci0: <VGA-compatible display> port 0x4000-0x407f mem 0x96000000-0x96ffffff,0x60000000-0x6fffffff,0x94000000-0x95ffffff irq 16 at device 0.0 on pci1
74 hdac0: <NVIDIA (0x10f7) HDA Controller> mem 0x97080000-0x97083fff irq 17 at device 0.1 on pci1
...
82 vgapci1: <VGA-compatible display> port 0x3000-0x307f mem 0x92000000-0x92ffffff,0x80000000-0x8fffffff,0x90000000-0x91ffffff irq 17 at device 0.0 on pci2
83 hdac1: <NVIDIA (0x10f1) HDA Controller> mem 0x93080000-0x93083fff irq 18 at device 0.1 on pci2
84 vgapci2: <VGA-compatible display> port 0x5000-0x503f mem 0x98000000-0x98ffffff,0x40000000-0x5fffffff irq 16 at device 2.0 on pci0
85 vgapci2: Boot video device
```
... and in Xorg.0.log at lines 43 through 47:
	
	



```
43 [   122.262] (!!) More than one possible primary device found
44 [   122.262] (!!) More than one possible primary device found
45 [   122.262] (--) PCI:*(0@0:2:0) 8086:3e98:1458:d000 rev 2, Mem @ 0x98000000/16777216, 0x40000000/536870912, I/O @ 0x00005000/64, BIOS @ 0x????????/65536
46 [   122.262] (--) PCI: (1@0:0:0) 10de:1e04:19da:2503 rev 161, Mem @ 0x96000000/16777216, 0x60000000/268435456, 0x94000000/33554432, I/O @ 0x00004000/128, BIOS @ 0x????????/65536
47 [   122.262] (--) PCI: (2@0:0:0) 10de:1c02:19da:2438 rev 161, Mem @ 0x92000000/16777216, 0x80000000/268435456, 0x90000000/33554432, I/O @ 0x00003000/128, BIOS @ 0x????????/65536
```
For comparison, my system only detects 1 video device, which dmesg reports as vgapci0.

My system uses the radeon video driver, from installed software xf86-video-ati, along with the radeonkms.ko kernel modesetting module, from installed software drm.kmod.

Your system is trying to use the intel video driver along with the i915kms.ko kernel modesetting module, but the intel driver is failing to load, which you can see in Xorg.0.log at lines 58 through 60:
	
	



```
58 [   122.263] (II) LoadModule: "intel"
59 [   122.263] (WW) Warning, couldn't open module intel
60 [   122.263] (EE) Failed to load module "intel" (module does not exist, 0)
```
I don't know exactly why this is failing. Your Xorg.log.0 appears to use modeset(0) (vgapci2) as its primary device, whereas mine uses RADEON(0) (vgapci0) as its primary device.

My system has an external monitor attached, which it configures as VGA-0, but I can find no similar external device configuration in your logs. My primary

Maybe someone using the intel driver can provide a better analysis by comparing your logs with their own system logs.


----------



## warbotz (Jul 26, 2021)

ziomario said:


> Hello.
> 
> I've added this parameter to /etc/rc.conf :
> 
> ...


for use intel driver you need install... kms pakage first... and make sure your graphic driver is intel not nvidia... or another


----------



## orhankur (Jul 28, 2021)

ziomario said:


> Hello.
> 
> I've added this parameter to /etc/rc.conf :
> 
> ...


Would the following in /etc/rc.conf be any help?
kld_list="boot/modules/i915kms.ko" 
I was told that sometimes freebsd requires the full path for i915kms.


----------



## SirDice (Jul 28, 2021)

orhankur said:


> I was told that sometimes freebsd requires the full path for i915kms.


Only on 11.x and 12.x because there's an existing module that comes with the OS. On 13.x and higher this isn't needed because the old i915kms driver that came with FreeBSD was removed. So there's no ambiguity anymore.


----------



## free-and-bsd (Aug 5, 2021)

grahamperrin said:


> From <https://forums.FreeBSD.org/threads/81340/post-524303> under another post, I assume that it's *FreeBSD 13.0-RELEASE-p3* in this post.
> 
> 
> 
> ...


Well, as I read in your own quotation of man, zfs_enable "will attempt to automatically mount" ZFS filesystems. That is, I suppose, such ZFS filesystems that are set to mount _automatically_ (zfs setting canmount=auto + have mountpoint other than legacy), right?. Mine, however, are all of legacy type, get mounted via /etc/fstab, so, this won't work. the module has to be preloaded, unless I'm very much mistaken.

Additionally, zfs.ko module must be loaded anyway. Now UEFI or other type of FreeBSD loader reads info about loaded modules from /boot/loader.conf. But since my system boots via GRUB (old laptop + dual-boot with other OSs), it doesn't know how to use that file (and GRUB cannot boot /boot/loader any more). However, booting modules via GRUB command line (i.e., `kFreeBSD_module_elf /boot/modules/zfs.ko`) doesn't work _well_ with all modules. Then again, with zfs.ko NOT loaded at boot time, zfs_eanble cannot possibly work at all.

And in particular, i915kms.ko ONLY works (last revisions, at least) when loaded using kld_list option in /etc/rc.conf. And, into the bargain, saves GRUB command line typing trouble )). I assume it to be good style to keep grub.cfg as short as possible where native OS mechanisms can be safely used instead.


----------



## free-and-bsd (Aug 5, 2021)

grahamperrin said:


> Yes.
> 
> With FreeBSD 14.0-CURRENT ...


The question is, does this apply to 13.0-RELEASE as well? Because, as I was given to understand, CURRENT is not discussed on this forum and its solutions may not apply...


----------



## grahamperrin@ (Aug 6, 2021)

free-and-bsd said:


> … as I was given to understand, CURRENT is not discussed on this forum …



Some misunderstanding, see for example: 

How do you test 13.0-CURRENT? | The FreeBSD Forums
Please create a -current forum | The FreeBSD Forums


----------



## grahamperrin@ (Aug 6, 2021)

free-and-bsd said:


> … i915kms.ko ONLY works (last revisions, at least) when loaded using `kld_list` option in /etc/rc.conf.



That was my experience, a few weeks ago. A few weeks previously someone found otherwise.


----------



## free-and-bsd (Aug 6, 2021)

grahamperrin said:


> Some misunderstanding, see for example:
> 
> How do you test 13.0-CURRENT? | The FreeBSD Forums
> Please create a -current forum | The FreeBSD Forums


Hm? How about Topics about unsupported FreeBSD versions? It says:


> Currently *supported* FreeBSD versions: http://www.freebsd.org/security/index.html#sup
> Currently *unsupported* FreeBSD versions: http://www.freebsd.org/security/unsupported.html
> The latter does not list -CURRENT, but that version is unsupported by definition.


----------



## free-and-bsd (Aug 6, 2021)

grahamperrin said:


> That was my experience, a few weeks ago. A few weeks previously someone found otherwise.


I can safely confirm that this thing started precisely when 13.0 changed its status from CURRENT to RC. I had no reason to switch over to 14.0-CURRENT on my laptop, so I stuck with 13.0... 
But then, the latest dev version of i915kms kmod I had used successfully (without kld_list stuff) could not  be used with an RC release. It failed to build and urged me to switch over to older version or to use CURRENT. 
And the older version only works though kld_list. 
Can't say I'm any worse for the change, though -- in fact, it is even more neat that way, excluding module loading from grub.cfg.
...So, I guess, whoever "found it otherwise" is using CURRENT -- and the latest dev version of i915kms kmod.


----------



## Vull (Aug 7, 2021)

FWIW I've been using 13.0-RELEASE using drm-kmod, from quarterly packages only, since Q2, and it unfailingly loads drm.ko automatically as soon as I start X. I'm presently on 13.0-RELEASE-p3 and Q3 quarterly packages. This has been its consistent behavior since April if I leave kld_list empty. I've made this point repeatedly several times since then, in several different threads.

On my Lenovo laptop with Radeon graphics, it also automatically loads radeonkms.ko after loading drm.ko.

On my HP Stream laptop with Intel graphics, it automatically loads i915kms.ko instead of the Radeon graphics modules.

I'm guessing that the x11/xorg package is doing this automatically whenever X starts, because these modules don't get loaded until the moment I start X, either with `startx`, or by starting the x11/lightdm display manager.


----------



## grahamperrin@ (Aug 7, 2021)

free-and-bsd said:


> … I guess, whoever "found it otherwise" is using CURRENT …



No, they wrote _13.0-RELEASE_: <https://lists.freebsd.org/pipermail/freebsd-questions/2021-May/294001.html>



free-and-bsd said:


> Hm?



Also <https://forums.FreeBSD.org/threads/79537/post-503223> (post 125 and others there) and so on.


----------



## free-and-bsd (Aug 9, 2021)

Vull said:


> FWIW I've been using 13.0-RELEASE using drm-kmod, from quarterly packages only, since Q2, and it unfailingly loads drm.ko automatically as soon as I start X. I'm presently on 13.0-RELEASE-p3 and Q3 quarterly packages. This has been its consistent behavior since April if I leave kld_list empty. I've made this point repeatedly several times since then, in several different threads.
> 
> On my Lenovo laptop with Radeon graphics, it also automatically loads radeonkms.ko after loading drm.ko.
> 
> ...


Glad for you, really 
And what I am NOT glad about is the fact that it works this way for you but does NOT work for me. Or do you have any "magic" settings that make this happen? C'mon, don't keep it secret from us friends here 

I mean, you're telling me that it "just works". And I have to reply that it doesn't. And I believe there MUST be a cause for the former and the latter.
Would be interesting to know how this is done.


----------



## Vull (Aug 9, 2021)

free-and-bsd said:


> Glad for you, really
> And what I am NOT glad about is the fact that it works this way for you but does NOT work for me. Or do you have any "magic" settings that make this happen? C'mon, don't keep it secret from us friends here
> 
> I mean, you're telling me that it "just works". And I have to reply that it doesn't. And I believe there MUST be a cause for the former and the latter.
> Would be interesting to know how this is done.


No magic settings, just plain vanilla configurations built from packages and the FreeBSD-13.0-RELEASE-amd64-memstick.img installer. Software configurations are as simple and straightforward as I can make them. Maybe it's specific to the hardware, I don't know, but maybe I finally just got lucky with my cheap hardware purchases. Lenovo G50-45 laptop and HP Stream 11-d010wm. I was not so lucky with my Acer Aspire a few years ago, and the HP Stream still has plenty of hardware glitches including an unsupported Realtek wifi chip. Two or three cheap laptops is not a statistically significant sample size but that's what I've got.

It's not really such a big deal is it? Would I sleep any better or worse if I had to put one extra token in my kld_list? I don't think so.


----------



## mer (Aug 9, 2021)

In another thread, there is some information from the OP that may change some of this.
The system in question, dmesg shows 3 vgapci devices, vgapci0 and vgapci1 being NVIDIA, vgapci2 being i915.  BIOS setting is 
such that the i915 is the default boot device but that does not explicitly disable the other 2 (pciconf -l and dmesg | grep vga shows 3 devices).  
It is likely that having these three devices visible to the kernel is affecting the kldload i915 somehow.


----------



## ziomario (Aug 9, 2021)

I can't disable the nvidia graphic cards,because my next goal is to try to passtrough one of them or both in the bhyve virtual machine.


----------



## free-and-bsd (Aug 9, 2021)

ziomario said:


> I can't disable the nvidia graphic cards,because my next goal is to try to passtrough one of them or both in the bhyve virtual machine.


But why would you need that, I wonder? It actually works fine via VLC + hda sound.


----------



## free-and-bsd (Aug 9, 2021)

Vull said:


> ... Maybe it's specific to the hardware, I don't know, but maybe I finally just got lucky with my cheap hardware purchases. ...


It is this maybe which is killing me. OS and its components MUST NOT make any such difference. 
It must be as simple as "I know this hardware, here is the driver for it. Let's load it then".


Vull said:


> It's not really such a big deal is it?


Not for YOU, I guess ...
But generally, yes it is. Software can hardly be considered 100% stable and reliable if its behaviour becomes unpredictable.
If, on the other hand, this is KNOWN behaviour, why is it not documented?


----------



## Vull (Aug 9, 2021)

free-and-bsd said:


> It is this maybe which is killing me. OS and its components MUST NOT make any such difference.
> It must be as simple as "I know this hardware, here is the driver for it. Let's load it then".
> 
> Not for YOU, I guess ...
> ...


Did not mean to be dismissive of your pain.  My machines have only one graphics device each, so that no doubt simplifies the problem for the software. Also I'm starting to guess that it might very well have something to do with:

xf86-video-intel -> i915kms.ko
xf86-video-ati -> radeonkms.ko


----------



## free-and-bsd (Aug 9, 2021)

Vull said:


> Did not mean to be dismissive of your pain.


MY pain?? You must be kidding 
OK, let me be more explicit. When you launch X, you can see in your Xorg.0.log something like this:

```
[    73.968] (II) NVIDIA dlloader X Driver  390.143  Fri Mar 12 07:22:21 UTC 2021
[    73.968] (II) NVIDIA Unified Driver for all Supported NVIDIA GPUs
............
```
Formerly it would give off a full list of GPUs... So, do you see any reason why Xorg software should make difference and recognize automatically some of them but not others?

This isn't my pain at all, but a suggested behaviour of software.
What is the big deal, as you say?
OK, this very forum is one illustration. The OP friend here is in trouble and doesn't know what to think of his system which doesn't behave in a documented way. Now, we who have some experience tell him this and that.
Now if we CAN BE SURE about things, how much trouble would it save us and him? But if, on the other hand, it is like "oh, I don't know... it works fine for me, but have no idea why it doesn't for you..." That isn't very reassuring, you know


----------



## Vull (Aug 9, 2021)

free-and-bsd said:


> MY pain?? You must be kidding
> OK, let me be more explicit. When you launch X, you can see in your Xorg.0.log something like this:
> 
> ```
> ...


I feel his pain too. Been there, done that. Wish I knew why software is still in its infancy after all of these decades of bitter struggle, disillusionment, and broken standards, but I don't. Skynet? The goddamn robots? "It's all about the money?" *sigh*


----------



## astyle (Aug 18, 2021)

Has anyone read this wiki page (https://wiki.freebsd.org/Graphics#Intel_Integrated_Graphics_.28aka_HD_Graphics.29). One tip that I'd like to add: Pick just *one* .conf file to stick that line into... I personally use /etc/rc.conf. Sticking the same line into more than one .conf file results in unpredictable mess.


----------



## grahamperrin@ (Aug 19, 2021)

astyle said:


> … Pick just *one* .conf file to stick that line into …



The wiki uses the word 'or' (does not imply addition to two files):


----------

