8839 Commits

Author SHA1 Message Date
Tautvis
4bbc49597c sna and uxa: build *_present.c files
Partially revert #56, because driver refers to *_present_open
symbols and they needed for functionality.

Signed-off-by: Tautvis <gtautvis@gmail.com>
2026-01-28 15:23:48 +01:00
callmetango
1f236e69b8 meson.build: fix missing config.h include
Add include_directory arguments to the meson.build files in src and
tools so the config.h include can be found.

Fixes: #57
Signed-off-by: callmetango <callmetango@users.noreply.github.com>
2026-01-28 15:22:50 +01:00
artist
497585a4e0 Drop has_present from sna and uxa
Signed-off-by: artist <artist@artixlinux.org>
2026-01-27 20:21:39 +00:00
Enrico Weigelt, metux IT consult
38f859ccc9 sna: move sna_gc() from header to sna_accel.c
It's only used in this source file, so no need for having it
within the header.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2026-01-26 20:22:47 +01:00
Enrico Weigelt, metux IT consult
d885dfaf54 uxa: fix const char* issue on XvAttributeRec
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2026-01-26 20:22:39 +01:00
Enrico Weigelt, metux IT consult
acb6d651ed sna: sna_poly_line() clear priv pointer before it becomes invalid
The field get assigned a pointer onto function stack, so we really
should clear it before leaving, so we don't risk any dangling pointers.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2026-01-26 19:37:23 +01:00
Enrico Weigelt, metux IT consult
0482464f07 sna: copy over xf86 internal EDID parser defines
Copy over those defines so we're not depending on these internal defintions
(which will be removed soon) being present in SDK header anymore.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2026-01-26 19:33:43 +01:00
Enrico Weigelt, metux IT consult
e9ca302258 disable build-time option for present
present is always present in modern Xservers.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2026-01-12 19:27:54 +01:00
Enrico Weigelt, metux IT consult
81f512e355 drop #ifdef RANDR_12_INTERFACE
All (non-ancient) Xservers have it.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2026-01-12 19:11:27 +01:00
Enrico Weigelt, metux IT consult
9e5ef5d1a6 sna: sna_accel: fix type of sigjmp
Needs to be sigjmp_buf instead of jmp_buf.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2026-01-12 17:14:52 +01:00
Enrico Weigelt, metux IT consult
4e62fdb39c replace obsolete "pointer" typedef by plain void*
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2026-01-05 18:57:20 +01:00
Enrico Weigelt, metux IT consult
46c0cf7242 drop obsolete ifdef XF86_CRTC_VERSION
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2026-01-02 17:40:29 +01:00
Enrico Weigelt, metux IT consult
1529636407 drop obsolete isGPU() compat macro
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2026-01-02 17:16:49 +01:00
Enrico Weigelt, metux IT consult
7180f97566 drop obsolete xf86ScrnToScreen() compat macro
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2026-01-02 17:15:13 +01:00
Enrico Weigelt, metux IT consult
1438f973e4 drop dead code pathes for ancient Xv version 1
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-12-31 16:09:12 +01:00
Enrico Weigelt, metux IT consult
7a01d44b26 replace XF86AttributeRec by XvAttributeRec
XF86AttributeRec has been renamed to XvAttributeRec over a decade
ago, and XF86AttributeRec now just an alias to XvAttributeRec.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-12-31 15:55:23 +01:00
Enrico Weigelt, metux IT consult
dd35e10a7f drop unused variables
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-12-31 15:46:44 +01:00
Enrico Weigelt, metux IT consult
4b1b29f3db replace ddGetPortAttribute_ARGS
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-12-31 15:43:02 +01:00
Enrico Weigelt, metux IT consult
668a2355fc compat-api.h: replace ddSetPortAttribute_ARGS
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-12-31 15:43:02 +01:00
Enrico Weigelt, metux IT consult
4a45c56630 compat-api.h: replace ddStopVideo_ARGS
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-12-31 15:43:02 +01:00
Enrico Weigelt, metux IT consult
bc506c8f42 compat-api.h: drop DamageUnregister() compat hack for ancient Xservers
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-12-31 15:43:00 +01:00
Enrico Weigelt, metux IT consult
22a4c164bb compat-api: drop miHandleExposures() call hack for ancient Xservers
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-12-31 14:10:01 +01:00
Enrico Weigelt, metux IT consult
255366573e compat-api.h: drop compat for ancient Xservers
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-12-31 14:07:32 +01:00
Enrico Weigelt, metux IT consult
322b48c9fd compat-api: drop support for old Xserver video ABI
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-12-31 14:06:49 +01:00
Enrico Weigelt, metux IT consult
3876ef4213 compat-api.h: drop unused region_nil()
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-12-31 14:05:51 +01:00
Enrico Weigelt, metux IT consult
a8f32f6cf6 compat-api.h: drop Region* macros for ancient Xservers
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-12-31 14:04:22 +01:00
Enrico Weigelt, metux IT consult
46e15a7813 compat-api.h: drop unused Region* macros
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-12-31 14:03:53 +01:00
Enrico Weigelt, metux IT consult
f22f1f0bec drop HAVE_NOTIFY_FD
Drop old code pathes for ancient Xservers that didn't have
fd notification yet.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-12-31 13:57:57 +01:00
Enrico Weigelt, metux IT consult
c594e6cd7d drop obsolete compat macros 2025-12-31 10:44:55 +01:00
b-aaz
4651664587 meson.build: Fixed meson errors.
Replaced the deprecated get_pkgconfig_variable with get_variable.

Moved the meson_version to 0.51.0 for get_variable.

Replaced the incorrect version comparison with the correct
.version_compare method.
2025-12-29 19:59:53 +01:00
Enrico Weigelt, metux IT consult
6233691861 drop obsolete #ifdef XFree86LOADER
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-12-18 13:45:08 +01:00
Enrico Weigelt, metux IT consult
969be9e43e drop obsolete #ifdef HAVE_CONFIG_H
the config.h file is always present

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-12-18 11:40:22 +01:00
Enrico Weigelt, metux IT consult
9b5c988b7b drop unnecessary git revision printing
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-12-16 14:10:30 +01:00
Enrico Weigelt, metux IT consult
8247368935 drop dead code
There's a dead code that ifdef'ed-out. Probably not really needed anymore.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-12-08 15:07:23 +01:00
b-aaz
d4c894c8a6 meson: Automatically detect the default xorg-module-dir.
The module directory has changed to a per ABI folder in the xlibre-xserver.
Now the default value of `xorg-module-dir` will be detected from the `moduledir` variable in xorg-server.pc.

Signed-off-by: b-aaz <b-aazbsd.proton.me>
2025-12-06 20:06:17 +00:00
Enrico Weigelt, metux IT consult
91b7822654 drop obsolete check for HAS_DEVPRIVATEKEYREC
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-11-27 18:30:14 +01:00
Enrico Weigelt, metux IT consult
e676c71504 drop obsolete check for videdrv abi > 10
xserver >= 1.18 has videdrv abi version 20.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-11-27 18:30:01 +01:00
Enrico Weigelt, metux IT consult
2960036ed3 drop obsolete XAA support
Since recent commits require xserver-1.18.0 or later to build against,
there's no reason leaving behind big chunks of code that can only build
against the XAA support removed in xserver-1.13.0 (released in 2012).

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-11-27 18:29:50 +01:00
Enrico Weigelt, metux IT consult
9c4282c396 drop obsolete check for HAS_DIXREGISTERPRIVATEKEY
It's present since xserver 1.18

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-11-27 18:27:11 +01:00
Enrico Weigelt, metux IT consult
85494bf879 drop obsolete check for HAS_DIRTYTRACKING2
This had been long gone, before our olderst supported relase 1.18

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-11-27 18:25:24 +01:00
Enrico Weigelt, metux IT consult
37134bb03f drop unused _MSC_VER check
Probably a copy+paste bug: this driver doesn't work at all under Windows.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-11-27 18:23:46 +01:00
Enrico Weigelt, metux IT consult
4af8592df4 drop compat with ancient xserver versions
We're relying on at least 1.18 now.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-11-27 18:21:27 +01:00
Enrico Weigelt, metux IT consult
935c612524 sna: declare the macros from micoord.h on our own
The <micoord.h> file is deprecated and this is the only driver actually
using it, so define them on our own.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-11-27 18:18:38 +01:00
Enrico Weigelt, metux IT consult
25f4892b66 sna: drop compile-time check for GLYPHPADBYTES == 4
It's always defined to 4, so extra check necessary.

See: xserver commit 17c3347f14822b9f7da4253c71f6ed51be2b38d1
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-11-06 15:53:00 +01:00
Enrico Weigelt, metux IT consult
65469c32fd sna: sna_damage: fix missing include of extinit.h
> sna_video.c: In function 'sna_video_init':
> sna_video.c:956:13: error: 'noXvExtension' undeclared (first use in this function); did you mean 'XvExtension'?
>   956 |         if (noXvExtension)
>       |             ^~~~~~~~~~~~~
>       |             XvExtension

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-09-24 15:31:42 +02:00
Enrico Weigelt, metux IT consult
4ef542eb13 drop fd_move_cloexec()
There's really no need to duplicate fd to a trivial sysfs file, neither
any need to explicitly mark it as close-on-exec. There's no locking
whatsoever involved, even parallel writes are fully supported for
sysfs attribute files.

And the way it was done was really weird and fragile: it just brutely
overwrote fd # MAXCLIENTS. The MAXCLIENTS define is internal to the
Xserver, outside of individual driver's concern, and drivers really
shouldn't directly mess with the fd table that way - they have no way
to make sure it's really done right.

Therefore, just drop this all and leave the fd as it is.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-09-24 15:00:26 +02:00
callmetango
5e1e6554ed sna: fix missing include of <sys/select.h>
Include <sys/select.h> to provide timer_tv. Fixes the missing definition
when sna is enabled and udev is disabled in configure.

Fixes: #10
Signed-off-by: callmetango <callmetango@users.noreply.github.com>
2025-08-07 17:27:45 -04:00
Enrico Weigelt, metux IT consult
a90192a5b1 fd: fix missing include of <xorg-server.h>
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-07-25 16:06:47 +02:00
Enrico Weigelt, metux IT consult
524563666c sna: fix abuse of ancient AllocateFontPrivateIndex()
The AllocateFontPrivateIndex() is gone from Xserver since about a decade
ago, but the driver doensn't correctly detect it. Since there's really
no need to support an over a decade old Xserver anymore, just drop the
whole detection logic and use xfont2_allocate_font_private_index()

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-06-17 20:00:30 +02:00
Enrico Weigelt, metux IT consult
03e0296572 use xf86NameCmp() instead of xf86nameCompare()
This driver is the only one still using xf86nameCompare() and so
blocking it's removal from Xserver module ABI.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-05-27 11:44:19 +02:00