Commit graph

19563 commits

Author SHA1 Message Date
Alan Coopersmith
cb285e18c0 Revert "xkb: unexport XkbRF_Create()"
This reverts commit 89475cbed4.

Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/2046>
2025-07-12 11:47:06 -07:00
Alan Coopersmith
dafa74fa1b Revert "xkb: unexport XkbRF_Free()"
This reverts commit 34372cb3da.

Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/2046>
2025-07-12 11:47:06 -07:00
Alan Coopersmith
01fa00fb90 Revert "xkb: unexport XkbRF_RulesRec struct"
This reverts commit 043dc8041c.

Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/2046>
2025-07-12 11:47:06 -07:00
Alan Coopersmith
396e3e7a54 Revert "xkb: unexport XkbRF_GroupRec struct"
This reverts commit 83c8a90a61.

Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/2046>
2025-07-12 11:47:06 -07:00
Alan Coopersmith
033936539b Revert "xkb: unexport XkbRF_RuleRec struct"
This reverts commit a82fa00835.

Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/2046>
2025-07-12 11:47:06 -07:00
Alan Coopersmith
950462f6e6 Revert "xkb: make XkbRF_Create() static inline"
This reverts commit 60d37d0158.

Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/2046>
2025-07-12 11:47:06 -07:00
Alan Coopersmith
03b1d94dc3 Revert "xkb: maprules: put some loop counters into local scope"
This reverts commit ffd7ca8af2.

Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/2046>
2025-07-12 11:47:06 -07:00
Alan Coopersmith
1598978df2 Revert "xkb: maprules: use static struct init instead of memset()"
This reverts commit a88b17565b.

Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/2046>
2025-07-12 11:47:06 -07:00
Alan Coopersmith
8f184bb6ca Revert "xkb: drop obsolete parameter from XkbRF_Free()"
This reverts commit abfbc76824.

Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/2046>
2025-07-12 11:47:06 -07:00
Alan Coopersmith
239b212c65 Revert "xkb: simplify loops in XkbRF_Free()"
This reverts commit a0c1eeea98.

Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/2046>
2025-07-12 11:47:06 -07:00
Faith Ekstrand
376cef6710 glamor: Enable dma-buf on Zink
Zink badly needs dma-buf and modifiers as it can't handle BO import of
tiled buffers without modifiers.

Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/1857>
2025-07-03 10:29:33 +00:00
Nathan Kidd
a4df686888 glx: Don't blindly write 8 bytes in GLX single replies
Previously we leaked stack when invalid enum parameters were
specified and caused __glGet*_size functions to return a 0 size.

Further, we read out-of-bounds (and leaked) when the input data was less
than 8 bytes (__glXDispSwap_GetFramebufferAttachmentParameteriv and
__glXDisp_GetRenderbufferParameteriv).

Now we only write a single element in the reply padding, and only when there
is a single element. This is what the Mesa client-side libGL expects, and
restores original GLX server behaviour, matching both pre-public (1996) SGI GLX
and XFree86 4.

The main risk of this change is if we have any error in element count or size;
previously it may not have mattered but now it does.

There are no piglit result changes from this modification using either mesa
libGLX or NVIDIA libGLX.

For performance considerations, an extra conditional and variable-length
memcpy has no meaningful impact on the indirect rendering pipeline cost.

There is still the possiblity to leak if our size checks allow an enum that
the GL implemention does not. Guarding against that requires zero-initializing
all temp storage, which wants re-evaluation of the blind 200-byte buffers
used for many calls and thus is a much bigger change.

Signed-off-by: Nathan Kidd <nkidd@rocketsoftware.com>
Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/1647>
2025-07-02 13:00:47 -04:00
Nathan Kidd
29cfcf5259 glx: Fix out-of-bounds reads from negative return
The callers of these functions were casting -1 to unsigned and then
using 4GB indexes. By returning 0 we match all the other size functions.

GLX size functions return -1 to indicate error, but GL size functions return 0.

Signed-off-by: Nathan Kidd <nkidd@rocketsoftware.com>
Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/1647>
2025-07-02 12:54:39 -04:00
Icenowy Zheng
eba15f1ba7 glamor: Fix dual blend on GLES3
The EXT_blend_func_extended extension on ESSL always requires explicit
request to allow two FS out variables because of limitations of the ESSL
language, which is mentioned as the No.6 issue of the extension's
specification.

Fix this by adding the extension request.

The original behavior on GLES3 is slightly against the specification of
GL_EXT_blend_func_extended extension, however Mesa and older version of
PowerVR closed drivers will just ignore this issue. Newest PowerVR
closed driver will bail out on this problem, so it deems a fix now.

Fixes: ee107cd491 ("glamor: support GLES3 shaders")
Signed-off-by: Icenowy Zheng <uwu@icenowy.me>
Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/1750>
2025-06-25 17:24:43 +00:00
Vlad Zahorodnii
60f0bfe852 xwayland: Dispatch tablet tool tip events after frame events
Xwayland dispatches tablet tool tip events immediately when they arrive.

With compositors such as mutter and sway, it is not an issue because
their libinput backends synthetize axis events before tip events. In
other words, axis data and the tip status belong to different frames.

On the other hand, kwin sends axis and tip events in a single frame
(its libinput backend generates a single tip event with axis data
attached to it). Since the tip events are dispatched immediately,
they can have wrong information associated with them, for example tool
position or pressure. It results in undesired "streaks" when the user
presses the tablet tool against the tablet.

See also https://bugs.kde.org/show_bug.cgi?id=479856.

Signed-off-by: Vlad Zahorodnii <vlad.zahorodnii@kde.org>
Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/2032>
2025-06-25 11:44:07 +00:00
Marge Bot
c1a3e99ce0 Merge branch 'revert-1691' into 'master'
Revert !1691 ("os: log: consolidate sigsafe and non-sigsafe logging paths")

See merge request xorg/xserver!2036
2025-06-24 23:46:29 +00:00
Alan Coopersmith
fc4fd8f2a9 Revert "os: log: drop unused variables"
This reverts commit f5fe8a6379.

Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/2036>
2025-06-24 23:40:52 +00:00
Alan Coopersmith
f421a33bb7 Revert "os: log: consolidate log formatting functions"
This reverts commit 71b8953597.

Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/2036>
2025-06-24 23:40:52 +00:00
Alan Coopersmith
4916da381b Revert "os: log: make LogVMessageVerb() signal safe"
This reverts commit 5962211612.

Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/2036>
2025-06-24 23:40:51 +00:00
Alan Coopersmith
6a9b2f37bb Revert "os: log: replace LogMessageVerbSigSafe() by LogMessageVerb()"
This reverts commit dd37cc4855.

Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/2036>
2025-06-24 23:40:51 +00:00
Alan Coopersmith
8ff12a8e53 Revert "os: log: replace ErrorFSigSafe() by ErrorF()"
This reverts commit 2d18c353b4.

Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/2036>
2025-06-24 23:40:50 +00:00
Alan Coopersmith
6dc94cb934 Revert "os: log: replace VErrorFSigSafe() by VErrorF()"
This reverts commit da22bc9ae0.

Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/2036>
2025-06-24 23:40:50 +00:00
Alan Coopersmith
523409ca2c Revert "xwin: drop duplicate OsVendorVErrorF()"
This reverts commit 9652bc73e2.

Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/2036>
2025-06-24 23:40:49 +00:00
Alan Coopersmith
ebcec3629c Revert "os: log: replace VErrorF() by LogVMessageVerb()"
This reverts commit f4eb217f11.

Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/2036>
2025-06-24 23:40:49 +00:00
Alan Coopersmith
6a49a358e3 Revert "xfree86: common: unexport UnloadModule() and UnloadSubModule()"
This reverts commit 00f69564c5.

Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/2037>
2025-06-24 23:23:50 +00:00
Aaron Plattner
1bec46dda1 Revert "os: unexport SetCriticalOutputPending()"
The NVIDIA driver uses this function.

This reverts commit d973c43810.

Signed-off-by: Aaron Plattner <aplattner@nvidia.com>
2025-06-24 11:23:14 -07:00
Aaron Plattner
c4470c3dca Revert "os: drop unused TimerCheck()"
The NVIDIA driver uses this function.

This reverts commit 1dc648b1b7.

Signed-off-by: Aaron Plattner <aplattner@nvidia.com>
2025-06-24 11:23:14 -07:00
Aaron Plattner
3fb85ab045 Revert "Xext: geext: drop unused GEInitEvent()"
The NVIDIA GLX extension module (libglxserver_nvidia.so) uses this
function.

This reverts commit 6fa340c578.

Signed-off-by: Aaron Plattner <aplattner@nvidia.com>
2025-06-24 11:23:14 -07:00
Aaron Plattner
d258c26626 Revert "panoramix: don't install panoramiX.h and panoramiXsrv.h"
The NVIDIA driver still supports GLX across physical screens in Xinerama
configurations, and uses the definitions in these headers to do that.

This reverts commit 3f469acb96.

Signed-off-by: Aaron Plattner <aplattner@nvidia.com>
2025-06-24 11:23:14 -07:00
Aaron Plattner
3d05f2b8a8 Revert "dix: unexport AllocColor()"
libwfb.so has a reference to this function:

 $ nm -D ./build.debug/hw/xfree86/dixmods/libwfb.so | grep AllocColor
                  U AllocColor

This reverts commit b48e4a9cb7.

Signed-off-by: Aaron Plattner <aplattner@nvidia.com>
2025-06-24 11:23:10 -07:00
Aaron Plattner
15ca09904a Revert "mi: unexport miWindowExposures()"
libwfb.so has a reference to this function:

 $ nm -D ./build.debug/hw/xfree86/dixmods/libwfb.so | grep miWindowExposures
                  U miWindowExposures

This reverts commit e424f49cdb.

Signed-off-by: Aaron Plattner <aplattner@nvidia.com>
2025-06-24 10:52:53 -07:00
Aaron Plattner
946ff9eac6 Revert "mi: unexport miExpandDirectColors()"
libwfb.so has a reference to this function:

 $ nm -D ./build.debug/hw/xfree86/dixmods/libwfb.so | grep miExpandDirectColors
                  U miExpandDirectColors

This reverts commit c3c538784a.

Signed-off-by: Aaron Plattner <aplattner@nvidia.com>
2025-06-24 10:52:27 -07:00
Aaron Plattner
d1ea5a6090 Revert "mi: unexport miCreateScreenResources()"
libwfb.so has a reference to this function:

 $ nm -D build.debug/hw/xfree86/dixmods/libwfb.so | grep miCreateScreenResources
                  U miCreateScreenResources

This reverts commit d14ae53e1f.

Signed-off-by: Aaron Plattner <aplattner@nvidia.com>
2025-06-24 10:52:27 -07:00
Olivier Fourdan
c34f59ee15 randr: Do not leak the provider property
When changing the RandR provider property, if the property does not
already exists, it is created.

In case of error, however, it doesn't get freed, leading to a leak of
the allocated property.

Make sure to free the RandR property in case of error if was to be
added.

Found by OpenScanHub.

Fixes: 3c3a4b767 - randr: Check for overflow in RRChangeProviderProperty()
Signed-off-by: Olivier Fourdan <ofourdan@redhat.com>
Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/2035>
2025-06-24 06:32:54 +00:00
Alan Coopersmith
bfd15d6e5a Revert "xvmc: move over protocol version defines into xvmc.c"
This reverts commit a33639f975

Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/2034>
2025-06-22 09:17:25 -07:00
Alan Coopersmith
8006778970 Revert "xfree86: common: move private defs out of xf86sbusBus.h"
This reverts commit 50d1a98c6a.

Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/2027>
2025-06-19 16:03:01 +00:00
Alan Coopersmith
4e315f0b94 Revert "xfree86: int10: move private defs out of xf86int10.h"
This reverts commit a0eea4e0ec.

Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/2027>
2025-06-19 16:03:01 +00:00
Alan Coopersmith
711fdc51f1 Revert "xfree86: common: move private defs from xf86Xinput.h to xf86Xinput_priv.h"
This reverts commit df33e1c51b.

Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/2027>
2025-06-19 16:03:01 +00:00
Alan Coopersmith
c692580d74 Revert "xfree86: common: move private defs out of xf86VGAarbiter.h"
This reverts commit 013eaacdd0.

Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/2027>
2025-06-19 16:03:01 +00:00
Alan Coopersmith
d13ba4a9e5 Revert "xfree86: modes: move private definitions out of from xf86RandR12.h"
This reverts commit ac5e95be49.

Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/2027>
2025-06-19 16:03:01 +00:00
Alan Coopersmith
58f469947b Revert "xfree86: parser: move private defs from xf86Parser.h to xf86Parser_priv.h"
This reverts commit d4724009ce.

Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/2027>
2025-06-19 16:03:01 +00:00
Alan Coopersmith
98e082ffe4 Revert "xfree86: ddc: move private definitions from xf86DDC.h to xf86DDC_priv.h"
This reverts commit 00c2a8fb0a.

Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/2027>
2025-06-19 16:03:01 +00:00
Alan Coopersmith
781a12fb8d Revert "xfree86: move private definitions out of dri2.h"
This reverts commit 1d3c26446d.

Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/2027>
2025-06-19 16:03:01 +00:00
Alan Coopersmith
41a55b1e2a Revert "xfree86: move private definitions out of dri.h"
This reverts commit cf03948572.

Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/2027>
2025-06-19 16:03:01 +00:00
Alan Coopersmith
44c89ebf32 Revert "xfree86: sdksyms.sh: add more headers"
This reverts commit 1efb2151e3.

Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/2027>
2025-06-19 16:03:01 +00:00
Olivier Fourdan
4fc4d76b2c os: Check for integer overflow on BigRequest length
Check for another possible integer overflow once we get a complete xReq
with BigRequest.

Related to CVE-2025-49176

Signed-off-by: Olivier Fourdan <ofourdan@redhat.com>
Suggested-by: Peter Harris <pharris2@rocketsoftware.com>
Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/2028>
2025-06-18 11:40:54 +02:00
Marge Bot
2a0f6ec920 Merge branch 'revert-1591' into 'master'
Revert parts of !1591 ("Xext: saver: misc cleanups & tiny bugfix (#1704)")

See merge request xorg/xserver!2023
2025-06-17 21:06:02 +00:00
Alan Coopersmith
5ad38ac585 Revert "Xext: saver: skip unneeded zero init and zero-swapping"
This reverts commit 40469a9d51.

Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/2023>
2025-06-17 21:02:03 +00:00
Alan Coopersmith
74182c52e9 Revert "Xext: saver: use explicit switch/case for dispatching"
This reverts commit 8236ef3b56.

Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/2023>
2025-06-17 21:02:03 +00:00
Marge Bot
3e168d8e6a Merge branch 'revert-1519' into 'master'
Revert !1519 ("refactor no*Extension flags")

See merge request xorg/xserver!2022
2025-06-17 21:00:16 +00:00