Re: X11 + i915kms

Jan Beich <[email protected]>
Newsgroups gmane.os.freebsd.devel.x11
Message-ID <[email protected]>
Hans Petter Selasky <[email protected]> writes:

> On 2020-02-04 13:33, Jan Beich wrote:
>
>> Hans Petter Selasky <[email protected]> writes:
>> 
>>> On 2019-12-27 12:12, Jan Beich wrote:
>>>
>>>> Hans Petter Selasky <[email protected]> writes:
>>>>
>>>>> Hi,
>>>>>
>>>>> Just did a fresh install of X11 and stuff. I noticed the
>>>>> xf86-video-intel is very sluggish unless SNA acceleration mode is
>>>>> selected. Do you know anything about this? Maybe make it the default?
>>>>> Or should I have used another driver?
>>>> FreeBSD disabled SNA by default for compatibility with
>>>> pre-SandyBridge
>>>> on drm-legacy-kmod (previously, in-base drm2), see bug 214593.
>>>> SNA is also unstable due to I915_USERPTR_UNSYNCHRONIZED, so you may
>>>> need the patch in bug 236003.
>>>
>>> Does this fix the issue?
>>> https://github.com/FreeBSDDesktop/kms-drm/pull/205
>> Yes but it needs to be applied to drm-v4.11 and drm-v4.16 as well.
>> drm-v4.9 works fine as is. I've originally reported the issue
>> in https://github.com/FreeBSDDesktop/kms-drm/issues/32.
>> However, the way you've handled LinuxKPI changes won't help on
>> already
>> released FreeBSD versions e.g.,
>> graphics/drm-fbsd12.0-kmod on FreeBSD 12.1:
>>    drivers/gpu/drm/i915/i915_gem_userptr.c:514:7: error: implicit declaration of function 'mmget_not_zero' is invalid in C99 [-Werror,-Wimplicit-function-declaration]
>>                    if (mmget_not_zero(mm)) {
>>                        ^
>>    drivers/gpu/drm/i915/i915_gem_userptr.c:514:7: error: this function declaration is not a prototype [-Werror,-Wstrict-prototypes]
>> graphics/drm-fbsd11.2-kmod on FreeBSD 11.3:
>>    i915_gem_userptr.c:511:7: error: implicit declaration of function 'mmget_not_zero' is invalid in C99 [-Werror,-Wimplicit-function-declaration]
>>                    if (mmget_not_zero(mm)) {
>>                        ^
>>    i915_gem_userptr.c:511:7: error: this function declaration is not a prototype [-Werror,-Wstrict-prototypes]
>> 
>
> I can MFC to the release branch too if that helps.

AFAIK, pushing to /releng/11.3 and /releng/12.1 would require an errata
notice to freebsd-announce@ list and populating the fix via freebsd-update.

> Do you know which branch you are using for 11 and 12 ports?

My setup is similar to the package cluster to facilitate debugging.
poudriere calls freebsd-update on jail creation or if manually
requested. According to https://pkg-status.freebsd.org/ -RELEASE jails
are updated before each build. When such an update changes
__FreeBSD_version or newvers.sh poudriere obsoletes every package,
causing a massive rebuild.

Steps to reproduce:

$ poudriere jail -cj 113amd64 -a amd64 -v 11.3-RELEASE
$ poudriere testport -j 113amd64 graphics/drm-fbsd11.2-kmod

$ poudriere jail -cj 121amd64 -a amd64 -v 12.1-RELEASE
$ poudriere testport -j 121amd64 graphics/drm-fbsd12.0-kmod

diff --git graphics/drm-fbsd11.2-kmod/Makefile graphics/drm-fbsd11.2-kmod/Makefile
index 455bef5dff15..ea046242cd11 100644
--- graphics/drm-fbsd11.2-kmod/Makefile
+++ graphics/drm-fbsd11.2-kmod/Makefile
@@ -5,6 +5,9 @@ PORTNAME=	drm-fbsd11.2-kmod
 PORTVERSION=	4.11g20200115
 CATEGORIES=	graphics
 
+PATCH_SITES=	https://github.com/${GH_ACCOUNT}/${GH_PROJECT}/commit/
+PATCHFILES+=	3fe3ed9e272c.patch:-p4 c93c0dd5b807.patch:-p4 # https://github.com/FreeBSDDesktop/kms-drm/pull/205
+
 MAINTAINER=	[email protected]
 COMMENT=	DRM modules for the linuxkpi-based KMS components
 
diff --git graphics/drm-fbsd11.2-kmod/distinfo graphics/drm-fbsd11.2-kmod/distinfo
index 0d19b0cfc40d..a12393a729e8 100644
--- graphics/drm-fbsd11.2-kmod/distinfo
+++ graphics/drm-fbsd11.2-kmod/distinfo
@@ -1,3 +1,7 @@
 TIMESTAMP = 1579089030
 SHA256 (FreeBSDDesktop-kms-drm-4.11g20200115-d49bde3_GH0.tar.gz) = 7eb13021c4d9835787b2a6447be7d4090eef5d35611745bd2efffeef33e659a9
 SIZE (FreeBSDDesktop-kms-drm-4.11g20200115-d49bde3_GH0.tar.gz) = 7361755
+SHA256 (3fe3ed9e272c.patch) = 8388e94394762e0527fba3ac8912a425e6e2f5677cd262b6cf190fbe893f4e40
+SIZE (3fe3ed9e272c.patch) = 2453
+SHA256 (c93c0dd5b807.patch) = ad0e12418f00c7dc1fe9f062b351d9cd9bc2418c25ba549a0d844778b977e5a8
+SIZE (c93c0dd5b807.patch) = 1069
diff --git graphics/drm-fbsd12.0-kmod/Makefile graphics/drm-fbsd12.0-kmod/Makefile
index f6632a1b3e3b..2a5bd726f529 100644
--- graphics/drm-fbsd12.0-kmod/Makefile
+++ graphics/drm-fbsd12.0-kmod/Makefile
@@ -5,6 +5,9 @@ PORTNAME=	drm-fbsd12.0-kmod
 PORTVERSION=	4.16.g20200115
 CATEGORIES=	graphics
 
+PATCH_SITES=	https://github.com/${GH_ACCOUNT}/${GH_PROJECT}/commit/
+PATCHFILES+=	3fe3ed9e272c.patch:-p1 c93c0dd5b807.patch:-p1 # https://github.com/FreeBSDDesktop/kms-drm/pull/205
+
 MAINTAINER=	[email protected]
 COMMENT=	DRM modules for the linuxkpi-based KMS components
 
diff --git graphics/drm-fbsd12.0-kmod/distinfo graphics/drm-fbsd12.0-kmod/distinfo
index df20430ed8d1..a1bd3f27a94e 100644
--- graphics/drm-fbsd12.0-kmod/distinfo
+++ graphics/drm-fbsd12.0-kmod/distinfo
@@ -1,3 +1,7 @@
 TIMESTAMP = 1579088993
 SHA256 (FreeBSDDesktop-kms-drm-4.16.g20200115-f3206bf_GH0.tar.gz) = 6f7fa77d4f30d575ae8a2c51ec33c2ac811f84bd5abf6632e2c9becdd0c22c94
 SIZE (FreeBSDDesktop-kms-drm-4.16.g20200115-f3206bf_GH0.tar.gz) = 13093677
+SHA256 (3fe3ed9e272c.patch) = 8388e94394762e0527fba3ac8912a425e6e2f5677cd262b6cf190fbe893f4e40
+SIZE (3fe3ed9e272c.patch) = 2453
+SHA256 (c93c0dd5b807.patch) = ad0e12418f00c7dc1fe9f062b351d9cd9bc2418c25ba549a0d844778b977e5a8
+SIZE (c93c0dd5b807.patch) = 1069
_______________________________________________
[email protected] mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-x11
To unsubscribe, send any mail to "[email protected]"
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.