Date: Wed, 2 Jan 2019 18:07:49 -0700 From: Warner Losh <imp@bsdimp.com> To: Jan Beich <jbeich@freebsd.org> Cc: Pete Wright <pete@nomadlogic.org>, x11@freebsd.org Subject: Re: Intel UHD Graphics 620 Message-ID: <CANCZdfo1gyeJowaqqyWES1eQNKa4_Yiahkf3Pwxxb6SUpDQ9oA@mail.gmail.com> In-Reply-To: <tvir-z9uv-wny@FreeBSD.org> References: <40291941-2aa9-2155-9cdc-85b482bd6f7d@borderworlds.dk> <wooj-zv0g-wny@FreeBSD.org> <fd1b6cd5-3ae1-e607-8ec4-831f143cdddc@nomadlogic.org> <d0qb-yf2c-wny@FreeBSD.org> <37c9b510-c5ef-a8d6-d600-5d05285174ab@nomadlogic.org> <tvir-z9uv-wny@FreeBSD.org>
next in thread | previous in thread | raw e-mail | index | archive | help
On Wed, Jan 2, 2019 at 2:29 AM Jan Beich <jbeich@freebsd.org> wrote: > Pete Wright <pete@nomadlogic.org> writes: > > > On 12/8/18 11:49 AM, Jan Beich wrote: > > > >> Pete Wright <pete@nomadlogic.org> writes: > >> > >>> On 12/8/18 11:19 AM, Jan Beich wrote: > >>> > >>>> Christian St=C3=A6rk <xi@borderworlds.dk> writes: > >>>> > >>>>> Hello, > >>>>> > >>>>> I am trying to get graphics working properly on my laptop but has > had no luck so far. > >>>>> > >>>>> I have Intel UHD Graphics 620. From pciconf: > >>>>> > >>>>> vgapci0@pci0:0:2:0: class=3D0x030000 card=3D0x08a51028 > chip=3D0x3ea08086 rev=3D0x00 hdr=3D0x00 > >>>>> vendor =3D 'Intel Corporation' > >>>>> device =3D 'UHD Graphics 620 (Whiskey Lake)' > >>>>> class =3D display > >>>>> subclass =3D VGA > >>>>> > >>>>> I have installed drm-stable-kmod and added to ny rc.conf: > >>>>> kld_list=3D"/boot/modules/i915kms.ko" > >>>> chip=3D0x3ea08086 is only supported by graphics/drm-devel-kmod. > >>> > >>> there is a "drm-kmod" meta-port which you can install. it should > >>> auto-detect the appropriate package to install, which in this case > >>> should be the drm-devel-kmod. > >> drm-kmod selects drm-devel-kmod only on 13.0-CURRENT atm. Are you sure > >> regular users are gonna run that? > > > > > > yes I believe that is intended for people on CURRENT. It should also > > select the appropriate version for users on RELEASE builds as well > > which is assumed what most regular users will be running. Niclas or > > someone else can correct me if that is not currently the case tho! :) > > As you've noticed the approach of selecting kernel DRM driver based > solely on FreeBSD version is flawed. It's not guaranteed a given PCI ID > (or "chip") would be supported by the selected drm-*-kmod version. > In the quote above the user was on FreeBSD 11.2 and probably installed > drm-stable-kmod via drm-kmod which would be "appropriate" iff the driver > actually attached. Since then drm-stable-kmod was renamed to > drm-fbsd11.2-kmod > and updated to drm-v4.11 branch but still no Whiskey Lake support. > While flawed, it selects the best version of the driver for the FreeBSD version you are running, in general. It was never designed to look at the hardware on the system, nor should it. There are edge cases that we cannot handle within the package system (which is 100% independent of the kernel). Unfortunately, we have different versions of the drivers for different releases of FreeBSD because the driver necessarily has to know about internal interfaces that change from release to release. This means that while the metaport generally selects the right drivers, there are occasions, like this one, where a different package needs to be selected, or where driver support is simply unavailable at that release / branch due to missing features in the OS. That usually means that people in this situation will need to upgrade to a newer version of FreeBSD to get the required support. > Here's another example: > > https://forums.freebsd.org/threads/new-to-freebsd-cant-get-integrated-gra= phics-driver-to-work.68948/ > > https://github.com/FreeBSDDesktop/kms-drm/blob/drm-v4.20-rc6/include/drm/= i915_pciids.h#L389 These are further examples of this general issue. Unfortunately, there's little that can be done about this due to the velocity of upstream. There's new base-OS features that are needed by the port, and those simply don't exist in older kernels unless someone back ports them. While less than ideal, I'll grant, it's a lot better than the situation a year ago where the coverage of hardware was even worse and the lag time from Linux release to inclusion in FreeBSD was even longer than what we have today. 11.2 (release June 2018) was released with a 4.9 Linux level of drivers (which itself was released December 2016, a lag of 18 months). Intel didn't release patches until June 2018, and they weren't included upstream until Linux v4.18 (if I'm reading the release notes correctly and git blame correctly). v4.18 support isn't even in the latest and greatest drm branches in the graphics repo. The whiskey lake gpu apparent just need coffeelake support, which itself wasn't merged until the past june (4.16 or 4.17 I think, I didn't do the full dumpster-dive to find the exact versions). So even with the latest and greatest code from the freebsd-graphics repo, it's unclear if the whiskey lake devices would work. I know some may find this unsatisfying. It's because we wanted to reduce the lag between Linux release and freebsd-graphics release that we've pushed these devices out of the /usr/src tree and moved to a shim / compatibility later approach for porting. I think everyone will agree this has lead to faster releases. And I think most will agree we want to decrease the lag ~18 months as well. That's being actively worked on (the next target is 4.18, which is only 8 months old). I hope that 2019 will continue to see this lag narrow. Warner
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CANCZdfo1gyeJowaqqyWES1eQNKa4_Yiahkf3Pwxxb6SUpDQ9oA>