xserver: Branch 'master' - 14 commits

GitLab Mirror gitlab-mirror at kemper.freedesktop.org
Mon Feb 17 19:47:53 UTC 2025


 glamor/glamor_eglmodule.c                           |   24 +++++++------
 hw/xfree86/common/xf86Configure.c                   |    2 -
 hw/xfree86/dixmods/fbmodule.c                       |   25 +++++++-------
 hw/xfree86/dixmods/glxmodule.c                      |   25 ++++++++------
 hw/xfree86/dixmods/shmodule.c                       |   24 +++++++------
 hw/xfree86/doc/ddxDesign.xml                        |    2 -
 hw/xfree86/drivers/inputtest/xf86-input-inputtest.c |   24 ++++++-------
 hw/xfree86/drivers/modesetting/driver.c             |   28 ++++++++--------
 hw/xfree86/exa/examodule.c                          |   24 +++++++------
 hw/xfree86/fbdevhw/fbdevhw.c                        |   24 ++++++-------
 hw/xfree86/int10/xf86int10module.c                  |   35 ++++++++------------
 hw/xfree86/shadowfb/sfbmodule.c                     |   24 +++++++------
 hw/xfree86/vgahw/vgaHWmodule.c                      |   24 +++++++------
 13 files changed, 146 insertions(+), 139 deletions(-)

New commits:
commit 80f5d29c84b584beb219a47225215cbc7f8e4963
Author: Enrico Weigelt, metux IT consult <info at metux.net>
Date:   Wed Feb 12 11:24:02 2025 +0100

    xfree86: doc: update docs on XF86ModuleData
    
    Even though the order of these fields shouldn't change anytime
    soon, it's still better programming style to name'em explicitly.
    
    Signed-off-by: Enrico Weigelt, metux IT consult <info at metux.net>
    Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/1788>

diff --git a/hw/xfree86/doc/ddxDesign.xml b/hw/xfree86/doc/ddxDesign.xml
index eb0bb03bb..237d1719a 100644
--- a/hw/xfree86/doc/ddxDesign.xml
+++ b/hw/xfree86/doc/ddxDesign.xml
@@ -7721,7 +7721,7 @@ static const OptionInfoRec ZZZOptions[] = {
 	<programlisting>
 static MODULESETUPPROTO(zzzSetup);
 
-XF86ModuleData zzzModuleData = { &zzzVersRec, zzzSetup, NULL };
+XF86ModuleData zzzModuleData = { .vers = &zzzVersRec, .setup = zzzSetup, .teardown = NULL };
 
 static pointer
 zzzSetup(pointer module, pointer opts, int *errmaj, int *errmin)
commit e88762896e99069138773cd22d8c24516d54d7c5
Author: Enrico Weigelt, metux IT consult <info at metux.net>
Date:   Wed Feb 12 11:24:02 2025 +0100

    xfree86: inputtest: use explicit field initializers for XF86ModuleData
    
    Even though the order of these fields shouldn't change anytime
    soon, it's still better programming style to name'em explicitly.
    
    Signed-off-by: Enrico Weigelt, metux IT consult <info at metux.net>
    Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/1788>

diff --git a/hw/xfree86/drivers/inputtest/xf86-input-inputtest.c b/hw/xfree86/drivers/inputtest/xf86-input-inputtest.c
index 8feca9428..52e58f13b 100644
--- a/hw/xfree86/drivers/inputtest/xf86-input-inputtest.c
+++ b/hw/xfree86/drivers/inputtest/xf86-input-inputtest.c
@@ -1107,18 +1107,17 @@ InputDriverRec driver = {
 };
 
 static XF86ModuleVersionInfo version_info = {
-    "inputtest",
-    MODULEVENDORSTRING,
-    MODINFOSTRING1,
-    MODINFOSTRING2,
-    XORG_VERSION_CURRENT,
-    XORG_VERSION_MAJOR,
-    XORG_VERSION_MINOR,
-    XORG_VERSION_PATCH,
-    ABI_CLASS_XINPUT,
-    ABI_XINPUT_VERSION,
-    MOD_CLASS_XINPUT,
-    {0, 0, 0, 0}
+    .modname      = "inputtest",
+    .vendor       = MODULEVENDORSTRING,
+    ._modinfo1_   = MODINFOSTRING1,
+    ._modinfo2_   = MODINFOSTRING2,
+    .xf86version  = XORG_VERSION_CURRENT,
+    .majorversion = XORG_VERSION_MAJOR,
+    .minorversion = XORG_VERSION_MINOR,
+    .patchlevel   = XORG_VERSION_PATCH,
+    .abiclass     = ABI_CLASS_XINPUT,
+    .abiversion   = ABI_XINPUT_VERSION,
+    .moduleclass  = MOD_CLASS_XINPUT,
 };
 
 static void*
@@ -1131,5 +1130,4 @@ setup_proc(void *module, void *options, int *errmaj, int *errmin)
 _X_EXPORT XF86ModuleData inputtestModuleData = {
     .vers = &version_info,
     .setup = &setup_proc,
-    .teardown = NULL
 };
commit 2a10eff6c5217ecff6414237d5d498d8a75ec0ab
Author: Enrico Weigelt, metux IT consult <info at metux.net>
Date:   Wed Feb 12 11:24:02 2025 +0100

    xfree86: modsetting: use explicit field initializers for XF86ModuleData
    
    Even though the order of these fields shouldn't change anytime
    soon, it's still better programming style to name'em explicitly.
    
    Signed-off-by: Enrico Weigelt, metux IT consult <info at metux.net>
    Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/1788>

diff --git a/hw/xfree86/drivers/modesetting/driver.c b/hw/xfree86/drivers/modesetting/driver.c
index 21358d9d5..264c6fe33 100644
--- a/hw/xfree86/drivers/modesetting/driver.c
+++ b/hw/xfree86/drivers/modesetting/driver.c
@@ -157,21 +157,23 @@ int ms_entity_index = -1;
 static MODULESETUPPROTO(Setup);
 
 static XF86ModuleVersionInfo VersRec = {
-    "modesetting",
-    MODULEVENDORSTRING,
-    MODINFOSTRING1,
-    MODINFOSTRING2,
-    XORG_VERSION_CURRENT,
-    XORG_VERSION_MAJOR,
-    XORG_VERSION_MINOR,
-    XORG_VERSION_PATCH,
-    ABI_CLASS_VIDEODRV,
-    ABI_VIDEODRV_VERSION,
-    MOD_CLASS_VIDEODRV,
-    {0, 0, 0, 0}
+    .modname      = "modesetting",
+    .vendor       = MODULEVENDORSTRING,
+    ._modinfo1_   = MODINFOSTRING1,
+    ._modinfo1_   = MODINFOSTRING2,
+    .xf86version  = XORG_VERSION_CURRENT,
+    .majorversion = XORG_VERSION_MAJOR,
+    .minorversion = XORG_VERSION_MINOR,
+    .patchlevel   = XORG_VERSION_PATCH,
+    .abiclass     = ABI_CLASS_VIDEODRV,
+    .abiversion   = ABI_VIDEODRV_VERSION,
+    .moduleclass  = MOD_CLASS_VIDEODRV,
 };
 
-_X_EXPORT XF86ModuleData modesettingModuleData = { &VersRec, Setup, NULL };
+_X_EXPORT XF86ModuleData modesettingModuleData = {
+    .vers = &VersRec,
+    .setup = Setup
+};
 
 static void *
 Setup(void *module, void *opts, int *errmaj, int *errmin)
commit c8ad9c65672458da2cf5b2f4d298267a16188e8a
Author: Enrico Weigelt, metux IT consult <info at metux.net>
Date:   Wed Feb 12 11:24:02 2025 +0100

    xfree86: exa: use explicit field initializers for XF86ModuleData
    
    Even though the order of these fields shouldn't change anytime
    soon, it's still better programming style to name'em explicitly.
    
    Signed-off-by: Enrico Weigelt, metux IT consult <info at metux.net>
    Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/1788>

diff --git a/hw/xfree86/exa/examodule.c b/hw/xfree86/exa/examodule.c
index 8cb6a7aa4..0b0bf8118 100644
--- a/hw/xfree86/exa/examodule.c
+++ b/hw/xfree86/exa/examodule.c
@@ -182,16 +182,18 @@ exaDDXDriverInit(ScreenPtr pScreen)
 }
 
 static XF86ModuleVersionInfo exaVersRec = {
-    "exa",
-    MODULEVENDORSTRING,
-    MODINFOSTRING1,
-    MODINFOSTRING2,
-    XORG_VERSION_CURRENT,
-    EXA_VERSION_MAJOR, EXA_VERSION_MINOR, EXA_VERSION_RELEASE,
-    ABI_CLASS_VIDEODRV,         /* requires the video driver ABI */
-    ABI_VIDEODRV_VERSION,
-    MOD_CLASS_NONE,
-    {0, 0, 0, 0}
+    .modname      = "exa",
+    .vendor       = MODULEVENDORSTRING,
+    ._modinfo1_   = MODINFOSTRING1,
+    ._modinfo2_   = MODINFOSTRING2,
+    .xf86version  = XORG_VERSION_CURRENT,
+    .majorversion = EXA_VERSION_MAJOR,
+    .minorversion = EXA_VERSION_MINOR,
+    .patchlevel   = EXA_VERSION_RELEASE,
+    .abiclass     = ABI_CLASS_VIDEODRV,
+    .abiversion   = ABI_VIDEODRV_VERSION,
 };
 
-_X_EXPORT XF86ModuleData exaModuleData = { &exaVersRec, NULL, NULL };
+_X_EXPORT XF86ModuleData exaModuleData = {
+    .vers = &exaVersRec
+};
commit c862cf3c3a83a84ea3648fa9108feeb6c865ee78
Author: Enrico Weigelt, metux IT consult <info at metux.net>
Date:   Wed Feb 12 11:24:02 2025 +0100

    xfree86: fbdevhw: use explicit field initializers for XF86ModuleData
    
    Even though the order of these fields shouldn't change anytime
    soon, it's still better programming style to name'em explicitly.
    
    Signed-off-by: Enrico Weigelt, metux IT consult <info at metux.net>
    Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/1788>

diff --git a/hw/xfree86/fbdevhw/fbdevhw.c b/hw/xfree86/fbdevhw/fbdevhw.c
index 92cac3f4a..74336087a 100644
--- a/hw/xfree86/fbdevhw/fbdevhw.c
+++ b/hw/xfree86/fbdevhw/fbdevhw.c
@@ -23,22 +23,20 @@
 #define PAGE_MASK               (~(getpagesize() - 1))
 
 static XF86ModuleVersionInfo fbdevHWVersRec = {
-    "fbdevhw",
-    MODULEVENDORSTRING,
-    MODINFOSTRING1,
-    MODINFOSTRING2,
-    XORG_VERSION_CURRENT,
-    0, 0, 2,
-    ABI_CLASS_VIDEODRV,
-    ABI_VIDEODRV_VERSION,
-    MOD_CLASS_NONE,
-    {0, 0, 0, 0}
+    .modname      = "fbdevhw",
+    .vendor       = MODULEVENDORSTRING,
+    ._modinfo1_   = MODINFOSTRING1,
+    ._modinfo2_   = MODINFOSTRING2,
+    .xf86version  = XORG_VERSION_CURRENT,
+    .majorversion = 0,
+    .minorversion = 0,
+    .patchlevel   = 2,
+    .abiclass     = ABI_CLASS_VIDEODRV,
+    .abiversion   = ABI_VIDEODRV_VERSION,
 };
 
 _X_EXPORT XF86ModuleData fbdevhwModuleData = {
-    &fbdevHWVersRec,
-    NULL,
-    NULL
+    .vers = &fbdevHWVersRec
 };
 
 #include <fcntl.h>
commit d87e93bf40ad1e8e0cd71fa7bca1d4dd1ad9b14c
Author: Enrico Weigelt, metux IT consult <info at metux.net>
Date:   Wed Feb 12 11:24:02 2025 +0100

    xfree86: xf86int10module: use explicit field initializers for XF86ModuleData
    
    Even though the order of these fields shouldn't change anytime
    soon, it's still better programming style to name'em explicitly.
    
    Signed-off-by: Enrico Weigelt, metux IT consult <info at metux.net>
    Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/1788>

diff --git a/hw/xfree86/int10/xf86int10module.c b/hw/xfree86/int10/xf86int10module.c
index 1eb5a0783..00e4ce34a 100644
--- a/hw/xfree86/int10/xf86int10module.c
+++ b/hw/xfree86/int10/xf86int10module.c
@@ -7,26 +7,21 @@
 #include <xorg-config.h>
 #endif
 
-#include "xf86.h"
-#include "xf86str.h"
-#include "xf86Pci.h"
-#include "xf86int10.h"
+#include "xf86Module.h"
 
-#ifndef MOD_NAME
-#define MOD_NAME int10
-#endif
-
-#define stringify(x) #x
-#define STRING(x) stringify(x)
-#define concat(x,y) x ## y
-#define combine(a,b) concat(a,b)
-#define NAME(x) combine(MOD_NAME,x)
-
-static XF86ModuleVersionInfo NAME(VersRec) = {
-    STRING(NAME()), MODULEVENDORSTRING, MODINFOSTRING1, MODINFOSTRING2, XORG_VERSION_CURRENT, 1, 0, 0, ABI_CLASS_VIDEODRV,      /* needs the video driver ABI */
-        ABI_VIDEODRV_VERSION, MOD_CLASS_NONE, {
-    0, 0, 0, 0}
+static XF86ModuleVersionInfo VersRec = {
+    .modname      = "int10",
+    .vendor       = MODULEVENDORSTRING,
+    ._modinfo1_   = MODINFOSTRING1,
+    ._modinfo2_   = MODINFOSTRING2,
+    .xf86version  = XORG_VERSION_CURRENT,
+    .majorversion = 1,
+    .minorversion = 0,
+    .patchlevel   = 0,
+    .abiclass     = ABI_CLASS_VIDEODRV,
+    .abiversion   = ABI_VIDEODRV_VERSION,
 };
 
-_X_EXPORT XF86ModuleData NAME(ModuleData) = {
-&NAME(VersRec), NULL, NULL};
+_X_EXPORT XF86ModuleData int10ModuleData = {
+    .vers = &VersRec
+};
commit f54993a222dc48b9126fa14f646e218c45bf1917
Author: Enrico Weigelt, metux IT consult <info at metux.net>
Date:   Wed Feb 12 11:24:02 2025 +0100

    xfree86: xfbmodule: use explicit field initializers for XF86ModuleData
    
    Even though the order of these fields shouldn't change anytime
    soon, it's still better programming style to name'em explicitly.
    
    Signed-off-by: Enrico Weigelt, metux IT consult <info at metux.net>
    Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/1788>

diff --git a/hw/xfree86/shadowfb/sfbmodule.c b/hw/xfree86/shadowfb/sfbmodule.c
index 62c183f60..4c770a7fd 100644
--- a/hw/xfree86/shadowfb/sfbmodule.c
+++ b/hw/xfree86/shadowfb/sfbmodule.c
@@ -5,16 +5,16 @@
 #include "xf86Module.h"
 
 static XF86ModuleVersionInfo VersRec = {
-    "shadowfb",
-    MODULEVENDORSTRING,
-    MODINFOSTRING1,
-    MODINFOSTRING2,
-    XORG_VERSION_CURRENT,
-    1, 0, 0,
-    ABI_CLASS_ANSIC,            /* Only need the ansic layer */
-    ABI_ANSIC_VERSION,
-    MOD_CLASS_NONE,
-    {0, 0, 0, 0}                /* signature, to be patched into the file by a tool */
+    .modname      = "shadowfb",
+    .vendor       = MODULEVENDORSTRING,
+    ._modinfo1_   = MODINFOSTRING1,
+    ._modinfo2_   = MODINFOSTRING2,
+    .xf86version  = XORG_VERSION_CURRENT,
+    .majorversion = 1,
+    .minorversion = 0,
+    .patchlevel   = 0,
+    .abiclass     = ABI_CLASS_ANSIC,
+    .abiversion   = ABI_ANSIC_VERSION,
 };
 
 _X_EXPORT XF86ModuleData shadowfbModuleData = {
commit a2e20304e0faf1af107ab0700420955e1f09e054
Author: Enrico Weigelt, metux IT consult <info at metux.net>
Date:   Wed Feb 12 11:24:02 2025 +0100

    xfree86: vgaHWmodule: use explicit field initializers for XF86ModuleData
    
    Even though the order of these fields shouldn't change anytime
    soon, it's still better programming style to name'em explicitly.
    
    Signed-off-by: Enrico Weigelt, metux IT consult <info at metux.net>
    Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/1788>

diff --git a/hw/xfree86/vgahw/vgaHWmodule.c b/hw/xfree86/vgahw/vgaHWmodule.c
index 0c5a43aa6..5559e3741 100644
--- a/hw/xfree86/vgahw/vgaHWmodule.c
+++ b/hw/xfree86/vgahw/vgaHWmodule.c
@@ -9,16 +9,18 @@
 #include "xf86Module.h"
 
 static XF86ModuleVersionInfo VersRec = {
-    "vgahw",
-    MODULEVENDORSTRING,
-    MODINFOSTRING1,
-    MODINFOSTRING2,
-    XORG_VERSION_CURRENT,
-    0, 1, 0,
-    ABI_CLASS_VIDEODRV,
-    ABI_VIDEODRV_VERSION,
-    MOD_CLASS_NONE,
-    {0, 0, 0, 0}
+    .modname      = "vgahw",
+    .vendor       = MODULEVENDORSTRING,
+    ._modinfo1_   = MODINFOSTRING1,
+    ._modinfo2_   = MODINFOSTRING2,
+    .xf86version  = XORG_VERSION_CURRENT,
+    .majorversion = 0,
+    .minorversion = 1,
+    .patchlevel   = 0,
+    .abiclass     = ABI_CLASS_VIDEODRV,
+    .abiversion   = ABI_VIDEODRV_VERSION,
 };
 
-_X_EXPORT XF86ModuleData vgahwModuleData = { &VersRec, NULL, NULL };
+_X_EXPORT XF86ModuleData vgahwModuleData = {
+    .vers = &VersRec
+};
commit 3066125bec20830d14771960ece3289e1df0c026
Author: Enrico Weigelt, metux IT consult <info at metux.net>
Date:   Wed Feb 12 11:24:02 2025 +0100

    xfree86: shmodule: use explicit field initializers for XF86ModuleData
    
    Even though the order of these fields shouldn't change anytime
    soon, it's still better programming style to name'em explicitly.
    
    Signed-off-by: Enrico Weigelt, metux IT consult <info at metux.net>
    Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/1788>

diff --git a/hw/xfree86/dixmods/shmodule.c b/hw/xfree86/dixmods/shmodule.c
index 0cbb9df71..655b7826e 100644
--- a/hw/xfree86/dixmods/shmodule.c
+++ b/hw/xfree86/dixmods/shmodule.c
@@ -38,16 +38,18 @@
 #include "shadow.h"
 
 static XF86ModuleVersionInfo VersRec = {
-    "shadow",
-    MODULEVENDORSTRING,
-    MODINFOSTRING1,
-    MODINFOSTRING2,
-    XORG_VERSION_CURRENT,
-    1, 1, 0,
-    ABI_CLASS_ANSIC,            /* Only need the ansic layer */
-    ABI_ANSIC_VERSION,
-    MOD_CLASS_NONE,
-    {0, 0, 0, 0}                /* signature, to be patched into the file by a tool */
+    .modname      = "shadow",
+    .vendor       = MODULEVENDORSTRING,
+    ._modinfo1_   = MODINFOSTRING1,
+    ._modinfo2_   = MODINFOSTRING2,
+    .xf86version  = XORG_VERSION_CURRENT,
+    .majorversion = 1,
+    .minorversion = 1,
+    .patchlevel   = 0,
+    .abiclass     = ABI_CLASS_ANSIC,
+    .abiversion   = ABI_ANSIC_VERSION,
 };
 
-_X_EXPORT XF86ModuleData shadowModuleData = { &VersRec, NULL, NULL };
+_X_EXPORT XF86ModuleData shadowModuleData = {
+    .vers = &VersRec
+};
commit f0590decb61c4b8c8e380bd0e089dc453d4eb36e
Author: Enrico Weigelt, metux IT consult <info at metux.net>
Date:   Wed Feb 12 11:24:02 2025 +0100

    xfree86: sfbmodule: use explicit field initializers for XF86ModuleData
    
    Even though the order of these fields shouldn't change anytime
    soon, it's still better programming style to name'em explicitly.
    
    Signed-off-by: Enrico Weigelt, metux IT consult <info at metux.net>
    Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/1788>

diff --git a/hw/xfree86/shadowfb/sfbmodule.c b/hw/xfree86/shadowfb/sfbmodule.c
index c20efc071..62c183f60 100644
--- a/hw/xfree86/shadowfb/sfbmodule.c
+++ b/hw/xfree86/shadowfb/sfbmodule.c
@@ -17,4 +17,6 @@ static XF86ModuleVersionInfo VersRec = {
     {0, 0, 0, 0}                /* signature, to be patched into the file by a tool */
 };
 
-_X_EXPORT XF86ModuleData shadowfbModuleData = { &VersRec, NULL, NULL };
+_X_EXPORT XF86ModuleData shadowfbModuleData = {
+    .vers = &VersRec
+};
commit 03becba76b38534eeed9c2385ea44de619f0214e
Author: Enrico Weigelt, metux IT consult <info at metux.net>
Date:   Wed Feb 12 11:24:02 2025 +0100

    xfree86: glxmodule: use explicit field initializers for XF86ModuleData
    
    Even though the order of these fields shouldn't change anytime
    soon, it's still better programming style to name'em explicitly.
    
    Signed-off-by: Enrico Weigelt, metux IT consult <info at metux.net>
    Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/1788>

diff --git a/hw/xfree86/dixmods/glxmodule.c b/hw/xfree86/dixmods/glxmodule.c
index 2215c8867..b90e941d9 100644
--- a/hw/xfree86/dixmods/glxmodule.c
+++ b/hw/xfree86/dixmods/glxmodule.c
@@ -48,19 +48,22 @@ SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 static MODULESETUPPROTO(glxSetup);
 
 static XF86ModuleVersionInfo VersRec = {
-    "glx",
-    MODULEVENDORSTRING,
-    MODINFOSTRING1,
-    MODINFOSTRING2,
-    XORG_VERSION_CURRENT,
-    1, 0, 0,
-    ABI_CLASS_EXTENSION,
-    ABI_EXTENSION_VERSION,
-    MOD_CLASS_NONE,
-    {0, 0, 0, 0}
+    .modname      = "glx",
+    .vendor       = MODULEVENDORSTRING,
+    ._modinfo1_   = MODINFOSTRING1,
+    ._modinfo2_   = MODINFOSTRING2,
+    .xf86version  = XORG_VERSION_CURRENT,
+    .majorversion = 1,
+    .minorversion = 0,
+    .patchlevel   = 0,
+    .abiclass     = ABI_CLASS_EXTENSION,
+    .abiversion   = ABI_EXTENSION_VERSION,
 };
 
-_X_EXPORT XF86ModuleData glxModuleData = { &VersRec, glxSetup, NULL };
+_X_EXPORT XF86ModuleData glxModuleData = {
+    .vers = &VersRec,
+    .setup = glxSetup
+};
 
 static void *
 glxSetup(void *module, void *opts, int *errmaj, int *errmin)
commit 7dd8d0627cd1ceed6580198df10a4b13c226aa30
Author: Enrico Weigelt, metux IT consult <info at metux.net>
Date:   Wed Feb 12 11:24:02 2025 +0100

    xfree86: fbmodule: use explicit field initializers for XF86ModuleData
    
    Even though the order of these fields shouldn't change anytime
    soon, it's still better programming style to name'em explicitly.
    
    Signed-off-by: Enrico Weigelt, metux IT consult <info at metux.net>
    Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/1788>

diff --git a/hw/xfree86/dixmods/fbmodule.c b/hw/xfree86/dixmods/fbmodule.c
index 5895ba296..b3d98fb2d 100644
--- a/hw/xfree86/dixmods/fbmodule.c
+++ b/hw/xfree86/dixmods/fbmodule.c
@@ -33,20 +33,21 @@
 
 static XF86ModuleVersionInfo VersRec = {
 #ifdef FB_ACCESS_WRAPPER
-    "wfb",
+    .modname      = "wfb",
 #else
-    "fb",
+    .modname      = "fb",
 #endif
-    MODULEVENDORSTRING,
-    MODINFOSTRING1,
-    MODINFOSTRING2,
-    XORG_VERSION_CURRENT,
-    1, 0, 0,
-    ABI_CLASS_ANSIC,            /* Only need the ansic layer */
-    ABI_ANSIC_VERSION,
-    MOD_CLASS_NONE,
-    {0, 0, 0, 0}                /* signature, to be patched into the file by a tool */
+    .vendor       = MODULEVENDORSTRING,
+    ._modinfo1_   = MODINFOSTRING1,
+    ._modinfo2_   = MODINFOSTRING2,
+    .xf86version  = XORG_VERSION_CURRENT,
+    .majorversion = 1,
+    .minorversion = 0,
+    .patchlevel   = 0,
+    .abiclass     = ABI_CLASS_ANSIC,
+    .abiversion   = ABI_ANSIC_VERSION,
 };
 
 _X_EXPORT XF86ModuleData FBPREFIX(ModuleData) = {
-&VersRec, NULL, NULL};
+    .vers = &VersRec
+};
commit c46e645bad6e66559e674acba2904ec1cb3f99a6
Author: Enrico Weigelt, metux IT consult <info at metux.net>
Date:   Wed Feb 12 11:24:02 2025 +0100

    glamor: use explicit field initializers for XF86ModuleData
    
    Even though the order of these fields shouldn't change anytime
    soon, it's still better programming style to name'em explicitly.
    
    Signed-off-by: Enrico Weigelt, metux IT consult <info at metux.net>
    Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/1788>

diff --git a/glamor/glamor_eglmodule.c b/glamor/glamor_eglmodule.c
index 326af3aa6..8ba9ba037 100644
--- a/glamor/glamor_eglmodule.c
+++ b/glamor/glamor_eglmodule.c
@@ -35,16 +35,18 @@
 #include "glamor.h"
 
 static XF86ModuleVersionInfo VersRec = {
-    GLAMOR_EGL_MODULE_NAME,
-    MODULEVENDORSTRING,
-    MODINFOSTRING1,
-    MODINFOSTRING2,
-    XORG_VERSION_CURRENT,
-    1, 0, 1, /* version */
-    ABI_CLASS_ANSIC,            /* Only need the ansic layer */
-    ABI_ANSIC_VERSION,
-    MOD_CLASS_NONE,
-    {0, 0, 0, 0}                /* signature, to be patched into the file by a tool */
+    .modname      = GLAMOR_EGL_MODULE_NAME,
+    .vendor       = MODULEVENDORSTRING,
+    ._modinfo1_   = MODINFOSTRING1,
+    ._modinfo2_   = MODINFOSTRING2,
+    .xf86version  = XORG_VERSION_CURRENT,
+    .majorversion = 1,
+    .minorversion = 0,
+    .patchlevel   = 1,
+    .abiclass     = ABI_CLASS_ANSIC,
+    .abiversion   = ABI_ANSIC_VERSION,
 };
 
-_X_EXPORT XF86ModuleData glamoreglModuleData = { &VersRec, NULL, NULL };
+_X_EXPORT XF86ModuleData glamoreglModuleData = {
+    .vers = &VersRec
+};
commit 18480278921746c16628dcc9efde2ae4dc467d4a
Author: Enrico Weigelt, metux IT consult <info at metux.net>
Date:   Wed Feb 12 11:13:15 2025 +0100

    xfree86: xf86configure: use NULL instead of 0
    
    Zero pointers should be initialized w/ NULL instead of raw 0.
    
    Signed-off-by: Enrico Weigelt, metux IT consult <info at metux.net>
    Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/1788>

diff --git a/hw/xfree86/common/xf86Configure.c b/hw/xfree86/common/xf86Configure.c
index 33e244ccd..74936a5bd 100644
--- a/hw/xfree86/common/xf86Configure.c
+++ b/hw/xfree86/common/xf86Configure.c
@@ -848,7 +848,7 @@ DoShowOptions(void)
     int i = 0;
     const char **vlist = NULL;
     char *pSymbol = 0;
-    XF86ModuleData *initData = 0;
+    XF86ModuleData *initData = NULL;
 
     if (!(vlist = GenerateDriverList())) {
         ErrorF("Missing output drivers\n");


More information about the xorg-commit mailing list