From owner-freebsd-x11@freebsd.org Thu Jan 3 01:08:03 2019 Return-Path: Delivered-To: freebsd-x11@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id E403A14377C6 for ; Thu, 3 Jan 2019 01:08:02 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: from mailman.ysv.freebsd.org (mailman.ysv.freebsd.org [IPv6:2001:1900:2254:206a::50:5]) by mx1.freebsd.org (Postfix) with ESMTP id 31C9D81940 for ; Thu, 3 Jan 2019 01:08:02 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: by mailman.ysv.freebsd.org (Postfix) id E8ADF14377C5; Thu, 3 Jan 2019 01:08:01 +0000 (UTC) Delivered-To: x11@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 9710314377C4 for ; Thu, 3 Jan 2019 01:08:01 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: from mail-qt1-x82f.google.com (mail-qt1-x82f.google.com [IPv6:2607:f8b0:4864:20::82f]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 30DC98193D for ; Thu, 3 Jan 2019 01:08:01 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: by mail-qt1-x82f.google.com with SMTP id p17so35418961qtl.5 for ; Wed, 02 Jan 2019 17:08:01 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bsdimp-com.20150623.gappssmtp.com; s=20150623; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=zbgHs5kDVjEOIM3ESp7C4NDB7uK9r4a1+ksZtg0WEiY=; b=hCckVjNd1/nb5oKbfQnNbYv1+ciGxWtck7TU9BlceNwD+ySKSK5RLfKNgImdN1OUT+ lJfjhAOEwWRQvrZSibijlG4RFL3cP1rPXlI3Wv9AqMSdVX6qcb0mYHee5ZRx6vuK1AY4 eJnOyGczJQrY5RnT8gGcP2e/G8yX8XXfoiuFANuVrtHcv7Q3yZO+yc/adfrucGrKWWE/ ypsmIb4/2B/NwRSyXNmlp0lUb0WI5bytgZVPd0WWJCZOkikZtx4WoCeiQ7achoNFYOeM jbLjaU256Bh14ChbZCPJVCaVwLphJHRDBYRmvHtC2pU9YrAtFNOC4ubFJdLRfyWM9nyq BH8Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=zbgHs5kDVjEOIM3ESp7C4NDB7uK9r4a1+ksZtg0WEiY=; b=tujTxLUPb9RBHy8zxGfxkMug0CIui14TtivdxCxpA/bFlfq6rnaoVntHzyIXomxeO0 eDbBGxu47ZtDg9C7ZmO5ZRg5PPwEexdQwspxrTCQqTjHbqIg8H68IE2Pr5+dtQbLTdhI eMuSD3Qe85KRg5DKo7FWrRmLQnUr9+hMWwqaWTwjzknPNDGUEKN4XBk0relAKVfHkynp 22cviiT379hpov2FPWqvS44Lpf4uDmak1QI2lBD7h0WyK2iYi42CbRhOCYbpOXh0zOOQ 8aaY7QwBaT/DvaSudy2S9/MrzqndLT243rFp68MuZHFzS9sq0A/orPRJO5ikv0t9lYZT cNpg== X-Gm-Message-State: AJcUukfw0w1VcaCn2oaRVKUfs9hB1WDHIR0ks+gnD2xg2bCfj+8//S/p hJ8rQZ5K7vD6HTOw/Fr/HiqKfv4+5CecdZ8iiuYsWg== X-Google-Smtp-Source: ALg8bN4siSOO7TLBeBch1h8fbilXJfO5uDBIo83DLDOdrvBfYqV9PyzMEaoOHfQ51dJmfLrEYn+J7z+M8viNRqtVf3I= X-Received: by 2002:ac8:668c:: with SMTP id d12mr42930085qtp.242.1546477680544; Wed, 02 Jan 2019 17:08:00 -0800 (PST) MIME-Version: 1.0 References: <40291941-2aa9-2155-9cdc-85b482bd6f7d@borderworlds.dk> <37c9b510-c5ef-a8d6-d600-5d05285174ab@nomadlogic.org> In-Reply-To: From: Warner Losh Date: Wed, 2 Jan 2019 18:07:49 -0700 Message-ID: Subject: Re: Intel UHD Graphics 620 To: Jan Beich Cc: Pete Wright , x11@freebsd.org X-Rspamd-Queue-Id: 30DC98193D X-Spamd-Bar: ------ Authentication-Results: mx1.freebsd.org X-Spamd-Result: default: False [-6.98 / 15.00]; NEURAL_HAM_MEDIUM(-1.00)[-1.000,0]; NEURAL_HAM_SHORT(-0.98)[-0.980,0]; NEURAL_HAM_LONG(-1.00)[-1.000,0]; REPLY(-4.00)[] Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Content-Filtered-By: Mailman/MimeDel 2.1.29 X-BeenThere: freebsd-x11@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: X11 on FreeBSD -- maintaining and support List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 03 Jan 2019 01:08:03 -0000 On Wed, Jan 2, 2019 at 2:29 AM Jan Beich wrote: > Pete Wright writes: > > > On 12/8/18 11:49 AM, Jan Beich wrote: > > > >> Pete Wright writes: > >> > >>> On 12/8/18 11:19 AM, Jan Beich wrote: > >>> > >>>> Christian St=C3=A6rk 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