# intel i915 from 12.1 on 13



## eaosfu (Oct 4, 2021)

Hello,

Since upgrading from 12.2 to 13 I've been experiencing the following issue with the i915 driver:









						[i915kms] broken suspend/resume on MacbookPro15/13.0-RC3 · Issue #67 · freebsd/drm-kmod
					

After upgrade to 13.0-RC3 from 12.2-RELEASE, suspend/resume is not working any more: % pkg info -x drm drm-fbsd13-kmod-5.4.92.g20210202 drm-kmod-g20190710_1 libdrm-2.4.104,1 before suspend: #dmesg|...




					github.com
				




I never had this issue with 12.1 or 12.2. I'm wondering if:

A) Is there a way to get the 12.1 version of the i915 driver running on 13
B) I'd like to help debug the issue so I don't mind checkout different versions of the code and testing to see at what point the bug is introduced. But I don't how to match the driver sources to the kernel sources. If someone could point me to the documentation on how this is done I'd be glad to dig through this.
Thanks in advance.


----------



## grahamperrin@ (Oct 16, 2021)

<https://github.com/freebsd/drm-kmod/issues/67#issuecomment-944861102>



eaosfu said:


> … get the 12.1 version of the i915 driver running on 13 …



Gut feeling: the end result, if it's possible, will not be pleasing.


----------



## eaosfu (Oct 18, 2021)

grahamperrin said:


> <https://github.com/freebsd/drm-kmod/issues/67#issuecomment-944861102>
> 
> 
> 
> Gut feeling: the end result, if it's possible, will not be pleasing.


Yeah, I think this is also pretty heavily tied into the linuxkpi, trying to get the 12.1 driver would likely require making changes in linuxkpi as well? Which would likely break more things


----------



## mer (Oct 18, 2021)

pkg upgrade from earlier today showed update to drm-fbsd13-kmod-5.4.144.g20211013
I would give that a try first before anything else


----------



## eaosfu (Oct 23, 2021)

mer said:


> pkg upgrade from earlier today showed update to drm-fbsd13-kmod-5.4.144.g20211013
> I would give that a try first before anything else


Thanks for the suggestion.  Just installed the package, rebooted, and ran a suspend/resume cycle. Still got wedged.


```
pkg info | grep drm
drm-fbsd13-kmod-5.4.144.g20211013 DRM modules for the linuxkpi-based KMS components
libdrm-2.4.106,1               Userspace interface to kernel Direct Rendering Module services
```


----------



## grahamperrin@ (Oct 23, 2021)

Is x11-drivers/xf86-video-intel installed?


----------



## eaosfu (Oct 24, 2021)

grahamperrin said:


> Is x11-drivers/xf86-video-intel installed?


No I thought this was no longer required since 12.0?


----------



## eaosfu (Oct 24, 2021)

Is there a way to unload and then reload the i915 driver? I tried the naive way of doing this, mainly just writing a script that would do:

kldunload i915.ko

sleep 5

kldload i915.ko

But that didn't seem to work. Is such a thing even possible? Right now the I'm just stuck rebooting the machine whenever the driver is wedged. I try not locking my screen before closing the lid, but its pretty hardwired behavior at this point.


----------



## grahamperrin@ (Oct 24, 2021)

eaosfu said:


> … unload … the i915 driver? …



I don't know about `i915`, but generally: it's advisable to *not* attempt to unload kernel modules for DRM. Expect a kernel panic.



eaosfu said:


> … no longer required since 12.0?



<https://www.freshports.org/x11-drivers/xf86-video-intel/#packages> packages are available for FreeBSD:12:amd64, FreeBSD:13:amd64, FreeBSD:14:amd64 and more.

I don't know why it's _legacy_, sorry

Side note: 









						FreeBSD:11:⋯ end of life · Issue #341 · FreshPorts/freshports
					

Since FreeBSD 11.4-RELEASE reached the end of its life (2021-09-30), we no longer need to see FreeBSD:11: in tables of packages … and so on. Thanks https://www.freebsd.org/releases/#_production_rel...




					github.com


----------



## the3ajm (Nov 14, 2021)

You can try booting into single user mode and login to your profile, then you can load i915 and start X to test.


----------



## grahamperrin@ (Nov 15, 2021)

the3ajm said:


> single user mode and login to your profile



Is that possible? 

I mean, there should be an `exit` (from single user mode, to multi-user mode) before a login prompt can appear …


----------



## the3ajm (Nov 15, 2021)

grahamperrin said:


> Is that possible?
> 
> I mean, there should be an `exit` (from single user mode, to multi-user mode) before a login prompt can appear …



When you enter that mode, it'll jump you into a console with the chance to load i915 driver, if it works then it'll refresh your resolution but if not then hopefully it shows on the logs. You need to login with the profile so it'll ask for a username and password but I would just use this for a test to see if the driver is working.


----------



## grahamperrin@ (Nov 15, 2021)

the3ajm said:


> the chance to load i915 driver,



Yep, _that type of thing_ is possible in single user mode. Load a kernel module.



eaosfu said:


> kldload i915.ko



There's no such module.

Instead – taking a hint from the title quoted in the opening post:

*i915kms*


----------

