Commit Graph

21632 Commits

Author SHA1 Message Date
Enrico Weigelt, metux IT consult
342ba5d4ab xquartz: replace _mesa_free by free()
It's always defined to free(), so we don't need it anymore.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-09-10 14:05:51 +02:00
Enrico Weigelt, metux IT consult
dba30c6810 xquartz: replace _mesa_memset macro by memset
It's alway defined to memset() anyways, so not needed anymore.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-09-10 14:05:51 +02:00
Enrico Weigelt, metux IT consult
a01baf51ed [PR #996] xquartz: replace malloc() by calloc()
PR: https://github.com/X11Libre/xserver/pull/996
2025-09-10 14:05:51 +02:00
Enrico Weigelt, metux IT consult
b9b43e92eb xf86bigfont: drop obsolete SProcXF86BigfontQueryVersion()
It's doing nothing but calling ProcXF86BigfontQueryVersion(), so
we can call that function directly in the swapped dispatcher and
get rid of SProcXF86BigfontQueryVersion() entirely.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-09-10 13:45:29 +02:00
Enrico Weigelt, metux IT consult
6bc438ab5a treewide: use inline helper for accessing first screen
Instead of everybody directly accessing the (internal) screenInfo struct,
let those consumers only interested in first screen use a little helper.

Also caching the value if it's needed several times.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-09-10 13:45:05 +02:00
Enrico Weigelt, metux IT consult
d0a155c824 panoramix: drop unnecessary extern declarations
functions declarations are extern by default, no need to write it
explicitly.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-09-10 13:43:29 +02:00
Enrico Weigelt, metux IT consult
5a8da5bdc3 damage: consolidate damageextint.h
* move the stuff only used in .c file there
* drop unnecessary include files

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-09-10 13:42:53 +02:00
Enrico Weigelt, metux IT consult
006f0ec78c Xi: move VPC define into the only source using it
Only used inside listdev.c, so no need to have it within a header.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-09-10 13:42:31 +02:00
Enrico Weigelt, metux IT consult
b5210be9eb Xi: helper for private structure retrieval
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-09-10 13:41:47 +02:00
Enrico Weigelt, metux IT consult
c349470433 Xext: geext: drop GEClientPrivateKey
Don't need actually need that extra macro, we can just write
&GEClientPrivateKeyRec in those few places.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-09-10 13:41:29 +02:00
sesankm
3e610c5fc5 xkb: XKBMisc: use C99 style declarations in XKBMisc functions 2025-09-10 13:40:15 +02:00
Enrico Weigelt, metux IT consult
9c6577cfcc render: drop obsolete SProc*()'s
Several of the SProcRender*() functions aren't actually needed, because
they're doing exactly the same as their ProcRender*() counterparts.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-09-10 13:39:42 +02:00
Enrico Weigelt, metux IT consult
87fc0a2521 render: let SProcRender*()'s directly call corresponding ProcRender*()'s.
Since Xinerama stuff doesn't tweak the call tables anymore, there's no need
to use them anymore - instead call the corresponding handlers directly.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-09-10 13:39:42 +02:00
Enrico Weigelt, metux IT consult
e4aae06a2d render: untwist xinerama part I
In order to consolidate protocol parsing (eg. byte-swapping) and dispatch
(eg. getting rid of the ugly call tables), we first need to untwist the
horribly complicated Xinerama machinery: it's using call tables which are
dynamically tweaked (when Xinerama is switched on/off), and even more call
tables for the byte-swap functions.

Simplifying the code flow by adding trivial demux handlers, which are calling
either into classic/single-mode or xinerama handlers, depending on whether
Xinerama is active.

Follow-up commits can now move the byte-wapping into here and drop the call tables.
After that, the currently duplicated parsing can also be moved in here, and
finally split off the classic/single-mode functions into protocol handling vs.
business logic, so we can finally stop faking requests from Xinerama side into
the classic handlers.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-09-10 13:39:23 +02:00
Enrico Weigelt, metux IT consult
c0beda902a Xext: xf86bigfont: use retval of X_SEND_REPLY_SIMPLE()
In ProcXF86BigfontQueryVersion(), return the retval of the
X_SEND_REPLY_SIMPLE() call.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-09-10 10:37:56 +02:00
Enrico Weigelt, metux IT consult
cdbf824d70 kdrive: use screenInfo insead of pointer passed to InitOutput()
We only have one global screenInfo struct ever, and many other parts of the
Xserver can only operate on global screenInfo, so it's time to phase out
this extra pointer. Once the same has done on the other DDXes, it will
be dropped from InitOutput()'s parameter list.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-09-10 10:37:45 +02:00
Enrico Weigelt, metux IT consult
143fafad24 glx: fix wrong swapped encoding in __glXDisp_QueryExtensionsString()
The name string is supposed to be transmitted as-is, not swapped in
4-byte chunks.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-09-10 10:27:34 +02:00
Enrico Weigelt, metux IT consult
4e842b2382 ci: fix freetype2 URL
savannah doesn't seem to work anymore, so use f.d.o

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-09-10 10:14:34 +02:00
RotaryBoot58
8574eecaa5 exa: exaOpReadsDestination(): Updated switch case formatting and reverted the use of tabs for indentation 2025-09-09 16:56:58 +02:00
Enrico Weigelt, metux IT consult
a324351f67 treewide: drop unnecessary includes of Xi/eglobals.h
Dropping include by sources that don't use anything from this header.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-09-09 14:41:10 +02:00
Enrico Weigelt, metux IT consult
eb17b34362 Xinerama: lambda-esque macro for walking Xinerama screens
Move the walking loops on Xinerama screens into lambda-esque macros:
the callers look quite like we've been using lambda functions and
closures, but actually are just fancy macro trickery.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-09-09 14:12:40 +02:00
Enrico Weigelt, metux IT consult
e3d9f4c3ef xfree86: dga: use canonical loop index in DGAClientStateChange()
Naming all index variables on looping over screens `walkScreenIdx`,
in order to make transition to upcoming generic screen walk macros easier.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-09-09 10:01:18 +02:00
stefan11111
7d48a9a41e modesetting: Fix memory leak
Signed-off-by: stefan11111 <stefan11111@shitposting.expert>
2025-09-09 09:46:05 +02:00
sesankm
4c71d77d08 glx: glxcmds.c: use x_rpcbuf_t in DoQueryContext
Signed-off-by: sesankm <26676400+sesankm@users.noreply.github.com>
2025-09-09 09:44:49 +02:00
Enrico Weigelt, metux IT consult
f58b56a79f Xext: dpms: use return value of X_SEND_REPLY_SIMPLE()
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-09-08 19:25:24 +02:00
Enrico Weigelt, metux IT consult
f598186c0d Xext: canonical walkScreenIdx variable on screen list iterations
When iterating screen lists, consistently use the same variable name
`walkScreenIdx` for holding current screen index everywhere.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-09-08 17:40:42 +02:00
Enrico Weigelt, metux IT consult
b97378b3b5 Xext: security: inline SProc*()'s
No need to have a hole bunch of extra functions, if we can just easily
inline the few relevant lines.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-09-08 17:40:23 +02:00
Enrico Weigelt, metux IT consult
025227a113 glx: __glXDisp_RenderMode(): use x_rpcbuf_t
Use x_rpcbuf_t for payload assembly and X_SEND_REPLY_WITH_RPCBUF()
for sending it all out.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-09-08 17:40:01 +02:00
b-aaz
8d4c9270ea xf86AutoConfig: Enabled autoselction of the scfb driver for DragonFlyBSD.
scfb driver is the native frame-buffer driver used on both FreeBSD and DragonFlyBSD,
It was not enabled as a fallback on DragonFlyBSD, so enabled it.

The driver:
https://github.com/rayddteam/xf86-video-scfb
Signed-off-by: b-aaz <b-aazbsd@proton.me>
2025-09-08 17:39:48 +02:00
stefan11111
6415fdf2db kdrive: bring back Xfbdev
Signed-off-by: stefan11111 <stefan11111@shitposting.expert>
2025-09-08 17:35:36 +02:00
b-aaz
99bc9e7800 Fixed the check for __builtin_popcountl for old compilers.
Old compilers used on some platforms (e.g. DragonFlyBSD) do not support __has_builtin, so now we fall back to #if define if __has_builtin is not found.

Signed-off-by: b-aaz <b-aazbsd@proton.me>
2025-09-08 17:29:45 +02:00
sesankm
af8b69b710 xkb: XKBMisc: scoped declaration in loops and use int instead of register ints
Signed-off-by: sesankm <26676400+sesankm@users.noreply.github.com>
2025-09-08 17:28:13 +02:00
sesankm
e3ae087bc7 xkb: XKBMisc: simple refactoring to declare variables where needed in XkbKeyTypesForCoreSymbols
Signed-off-by: sesankm <26676400+sesankm@users.noreply.github.com>
2025-09-08 17:28:13 +02:00
Enrico Weigelt, metux IT consult
49ddc8b3ec Xext: shape: inline request swapping
It's so trivial that those few lines can easily be inlined into
the actual request handler.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-09-08 10:20:56 +02:00
Enrico Weigelt, metux IT consult
e3122e411c xfree86: dga: simplify DGAClientStateChange()
Simply do the action on matched screen inside the loop instead of
saving the found client and acting on it later (if found).

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-09-08 09:59:11 +02:00
Enrico Weigelt, metux IT consult
93d1a2681f dix: enterleave: split out big looped code into separate functions
* make the code easier to read
* preparation for moving the looping into lambda-esque macros
  (the code inside the loops doesn't compile in here, but does when
  moved to separate functions)

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-09-08 09:58:58 +02:00
Enrico Weigelt, metux IT consult
638f8e16ac dix: PrintWindowTree(): move locally-used variabes into local scope
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-09-08 09:58:47 +02:00
Enrico Weigelt, metux IT consult
7f4bef0174 Xext: GE: inline request swapping
It's so trivial that those few lines can easily be inlined into
the actual request handler.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-09-08 09:58:35 +02:00
Enrico Weigelt, metux IT consult
470cca48d3 Xext: saver: inline request swapping
It's so trivial that those few lines can easily be inlined into
the actual request handler.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-09-08 09:57:38 +02:00
Enrico Weigelt, metux IT consult
f76fc2607d Xext: sync: inline request swapping
It's so trivial that those few lines can easily be inlined into
the actual request handler.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-09-08 09:57:26 +02:00
Enrico Weigelt, metux IT consult
0d5cf8f610 Xext: shm: drop useless byte-swapping
SHM can *only* be used locally by definition, so the case of having
a byte-swapped client doesn't exist at all.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-09-08 09:57:14 +02:00
Enrico Weigelt, metux IT consult
8336ad8e6f xfixes: inline request swapping
It's so trivial that those few lines can easily be inlined into
the actual request handler.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-09-08 09:57:03 +02:00
Enrico Weigelt, metux IT consult
bdaa1f7a69 render: untwist Xinerama - call orig functions directly
When a xinerama-enabled handler is calling into the plain one, there's
no need to go through extra call table - we can call them directly.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-09-08 09:56:51 +02:00
Enrico Weigelt, metux IT consult
9449df5896 glx: __glXSendReply(): use x_rpcbuf_t
Use x_rpcbuf_t for payload assembly and X_SEND_REPLY_WITH_RPCBUF()
for sending it all out.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-09-08 09:48:56 +02:00
Enrico Weigelt, metux IT consult
9feb398a7c config: fix inttype mismatches on device major/minor numbers
System headers define them as unsigned.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-09-05 20:31:59 +02:00
Enrico Weigelt, metux IT consult
8ac6a39c7f xkb: move WriteToClient() calls on Events into DIX macro
WriteToClient() shouldn't be called directly anymore, unless there's
no other way.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-09-05 20:25:02 +02:00
Varad Dixit
2a4a36aa58 fix minor spelling mistake in contributing guidelines 2025-09-05 15:05:37 +02:00
Enrico Weigelt, metux IT consult
55e70f1110 Xext: xvmc: use x_rpcbuf_t
Use x_rpcbuf_t for reply payload assembly.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-09-05 14:39:17 +02:00
Enrico Weigelt, metux IT consult
904acca6c8 .github: win32: fix pulling libxcb-render-util and libxcb-keysyms
Their latest releases have still configured wrong submodule URLs,
so we need to use master here.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-09-05 13:49:45 +02:00
Enrico Weigelt, metux IT consult
110830b4de dbe: use canonical screen iterator index variable
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-09-05 08:49:38 +02:00