From nobody Mon Jul 25 21:59:13 2022 X-Original-To: dev-commits-ports-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4LsDTZ2Wc6z4WvJ0; Mon, 25 Jul 2022 21:59:14 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4LsDTZ1kxMz3wYh; Mon, 25 Jul 2022 21:59:14 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1658786354; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=pfHi+qpQ92x7zknorDMpdX0Kj94dtsJ7Vi+R6eaG5XE=; b=tpUqzzR1wPAsnAoGk7qdijkXoTyvrql3c3oMG/krtn9EZy5uzXPBvn3mV3oMzgVy65v1Yq o19+Ptexf+x76SwAQ29LF+XTdXogjzaJPG2ZSkxs4/0ijW+JxwjSVezWr2lxUurRylCuqb 6/HPOPROYx3jd75TGB2FAo9CTv9w9ZZrtyYqMag1xl0oG6lTKidx3phgYLBpq66a1TBY1l NdBB5caZRQJGCo8egqHidiWLbdj6IhLCN4TmwliKpgf+srmNknTBgDPZRHFuM+HQpy6qkK 4l1o0KhNQhdrFQv3D/8Iu36vX8GntJmbtgQu+l4KalwWj7ZFuEIaJmAinbG6EA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4LsDTZ075kz1CgX; Mon, 25 Jul 2022 21:59:14 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 26PLxDWe071629; Mon, 25 Jul 2022 21:59:13 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 26PLxDL4071628; Mon, 25 Jul 2022 21:59:13 GMT (envelope-from git) Date: Mon, 25 Jul 2022 21:59:13 GMT Message-Id: <202207252159.26PLxDL4071628@gitrepo.freebsd.org> To: ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-main@FreeBSD.org From: Christoph Moench-Tegeder Subject: git: e9cf87dba5ea - main - www/firefox: uplift patch for bmo#1779425 List-Id: Commits to the main branch of the FreeBSD ports repository List-Archive: https://lists.freebsd.org/archives/dev-commits-ports-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-ports-main@freebsd.org X-BeenThere: dev-commits-ports-main@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: cmt X-Git-Repository: ports X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: e9cf87dba5ea6097da725e6184c17462dc1ee75d Auto-Submitted: auto-generated ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1658786354; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=pfHi+qpQ92x7zknorDMpdX0Kj94dtsJ7Vi+R6eaG5XE=; b=QpmrvhCmetseuxL/klfdIl0/xkolfMissNFduxu4824B17ijfvXWbgDWnmUF6Z7KyqGB/1 R58ml6EIqdHRWYWsEufWVlJSi0s1HcVoYruqHfAGXZ35Z4dc12lEWbTvrPI9n3ebE+Oxfq 2jkd5lhXbX4h+Li37ZOkyoCEeLNcsvAEX8G6MOeFYIxc8cn3RESua2J3oAvld17DYGdVe1 Ig6el4yd3wXCZ8jwaUZGSbmZuRM4moufp0ELRNS1rhyARQ2la8x7Zav+nhOx5gSb4mcyTt S0rtQQffcB892stH6Qx6VBqfJxjXPBCzWi4sEkIB3TDzOq0aq67Ubqqs/4N0FQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1658786354; a=rsa-sha256; cv=none; b=WOx4i+NqxKOdiHOayiuIlGaHcRrUlylrS8zgXxYBqsuuyR7+eVMhVtiU8fAO5K1m8/28Zh rXSt6IN9HKu8yOUHIU7exYOL4CZ55byWUr0LcTt8i5GypHZuxhT8laDPhZrzWJfz8/BsKA DV3fWYqKuaklMThk/q/w/jMSndssws0dihu3/HcuLU3Vmm5jhY1oaykhdpBuIe7asLjis5 hwOrGcstE7lIgW6y5qGNTjrkKWVpsbIY+S5IPY7xp2O0flsCC8fr5cdKadYmxDDElyPOjl dM8IzTzG5y9nvr/TpP2U2BwuEbCUVM857ybA7+GcwZ+xJCYbKzejFu/GpRl/dA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none X-ThisMailContainsUnwantedMimeParts: N The branch main has been updated by cmt: URL: https://cgit.FreeBSD.org/ports/commit/?id=e9cf87dba5ea6097da725e6184c17462dc1ee75d commit e9cf87dba5ea6097da725e6184c17462dc1ee75d Author: Christoph Moench-Tegeder AuthorDate: 2022-07-25 21:55:37 +0000 Commit: Christoph Moench-Tegeder CommitDate: 2022-07-25 21:55:37 +0000 www/firefox: uplift patch for bmo#1779425 at least with some video cards (I only have one) but not with software rendering, tabs supposed to display WebGL things may crash instead. With this patch I can at least watch the cube spin and the fishys swim, fwiw. --- www/firefox/Makefile | 1 + www/firefox/files/patch-bug1779425 | 48 ++++++++++++++++++++++++++++++++++++++ 2 files changed, 49 insertions(+) diff --git a/www/firefox/Makefile b/www/firefox/Makefile index d0d94900e46d..2d5a94f92db5 100644 --- a/www/firefox/Makefile +++ b/www/firefox/Makefile @@ -1,5 +1,6 @@ PORTNAME= firefox DISTVERSION= 103.0 +PORTREVISION= 1 PORTEPOCH= 2 CATEGORIES= www wayland MASTER_SITES= MOZILLA/${PORTNAME}/releases/${DISTVERSION}${DISTVERSIONSUFFIX}/source \ diff --git a/www/firefox/files/patch-bug1779425 b/www/firefox/files/patch-bug1779425 new file mode 100644 index 000000000000..9ab5f99d3b6d --- /dev/null +++ b/www/firefox/files/patch-bug1779425 @@ -0,0 +1,48 @@ +commit 9583d02e454318568191e5c31c51c34fd1332182 +Author: Robert Mader +Date: Tue Jul 19 21:52:04 2022 +0000 + + Bug 1779425 - Check for GbmDevice before using it, r=stransky,jgilbert + + In some non-standard configurations we unexpectedly end up in this paths + without a GBM device - one example being the GPU process. Fail cleanly + instead of crashing in those cases, triggering fallback paths. + + Context: in the past DMABuf usage was tightly coupled to GBM. Since the + introduction of the surfaceless and device EGL platforms that is not + longer the case, thus we can't make checks like `IsDMABufWebGLEnabled()` + depend on the presence of a GBM device. + + Optimally all affected cases get fixed eventually. Until then and also + for future cases it makes sense to fail softly. + + Differential Revision: https://phabricator.services.mozilla.com/D152173 + +diff --git widget/gtk/DMABufSurface.cpp widget/gtk/DMABufSurface.cpp +index 92c8e75218f8..7fddb32c7cda 100644 +--- widget/gtk/DMABufSurface.cpp ++++ widget/gtk/DMABufSurface.cpp +@@ -382,6 +382,11 @@ bool DMABufSurfaceRGBA::Create(int aWidth, int aHeight, + LOGDMABUF(("DMABufSurfaceRGBA::Create() UID %d size %d x %d\n", mUID, mWidth, + mHeight)); + ++ if (!GetDMABufDevice()->GetGbmDevice()) { ++ LOGDMABUF((" Missing GbmDevice!")); ++ return false; ++ } ++ + mGmbFormat = GetDMABufDevice()->GetGbmFormat(mSurfaceFlags & DMABUF_ALPHA); + if (!mGmbFormat) { + // Requested DRM format is not supported. +@@ -1025,6 +1030,11 @@ bool DMABufSurfaceYUV::CreateYUVPlane(int aPlane, int aWidth, int aHeight, + LOGDMABUF(("DMABufSurfaceYUV::CreateYUVPlane() UID %d size %d x %d", mUID, + aWidth, aHeight)); + ++ if (!GetDMABufDevice()->GetGbmDevice()) { ++ LOGDMABUF((" Missing GbmDevice!")); ++ return false; ++ } ++ + mWidth[aPlane] = aWidth; + mHeight[aPlane] = aHeight; + mDrmFormats[aPlane] = aDrmFormat;