[PATCH xf86-video-cirrus 1/3] Fix for Laguna I2C bus code compilation error

2019-04-17 Thread Kevin Brace
When commit 9a5e19597be4f5ee4c1030e4a716207789e78668 (cirrus: convert
to compat server API.) updated the code, it did not update Laguna I2C
bus code to handle newer X Servers.

Signed-off-by: Kevin Brace 
---
 src/lg_driver.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/lg_driver.c b/src/lg_driver.c
index daaf4f9..be8963a 100644
--- a/src/lg_driver.c
+++ b/src/lg_driver.c
@@ -359,7 +359,7 @@ LgDoDDC(ScrnInfoPtr pScrn)
 /*
  * Read and output monitor info using DDC2 over I2C bus.
  */
-MonInfo = xf86DoEDID_DDC2(pScrn->scrnIndex, pCir->I2CPtr1);
+MonInfo = xf86DoEDID_DDC2(XF86_SCRN_ARG(pScrn), pCir->I2CPtr1);
 xf86DrvMsg(pScrn->scrnIndex, X_INFO,
 "I2C Monitor info: %p\n", (void *)MonInfo);
 xf86PrintEDID(MonInfo);
--
2.17.1

___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: https://lists.x.org/mailman/listinfo/xorg-devel

[PATCH xf86-video-cirrus 2/3] Check for a successful transmission of EDID for Laguna I2C bus code

2019-04-17 Thread Kevin Brace
The existing code can potentially cause a null pointer crash if EDID
was not obtained successfully.

Signed-off-by: Kevin Brace 
---
 src/lg_driver.c | 6 ++
 1 file changed, 6 insertions(+)

diff --git a/src/lg_driver.c b/src/lg_driver.c
index be8963a..1042030 100644
--- a/src/lg_driver.c
+++ b/src/lg_driver.c
@@ -360,6 +360,12 @@ LgDoDDC(ScrnInfoPtr pScrn)
  * Read and output monitor info using DDC2 over I2C bus.
  */
 MonInfo = xf86DoEDID_DDC2(XF86_SCRN_ARG(pScrn), pCir->I2CPtr1);
+if (!MonInfo) {
+xf86DrvMsg(pScrn->scrnIndex, X_ERROR,
+"Failed to obtain EDID.\n");
+goto unmap_out;
+}
+
 xf86DrvMsg(pScrn->scrnIndex, X_INFO,
 "I2C Monitor info: %p\n", (void *)MonInfo);
 xf86PrintEDID(MonInfo);
--
2.17.1

___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: https://lists.x.org/mailman/listinfo/xorg-devel

[PATCH xf86-video-cirrus 3/3] Activate I2C bus for Laguna based devices

2019-04-17 Thread Kevin Brace
There is really no good reason for I2C bus based automatic display
detection to not be turned on by default.

Signed-off-by: Kevin Brace 
---
 src/lg_driver.c | 6 +-
 1 file changed, 1 insertion(+), 5 deletions(-)

diff --git a/src/lg_driver.c b/src/lg_driver.c
index 1042030..95886b0 100644
--- a/src/lg_driver.c
+++ b/src/lg_driver.c
@@ -349,7 +349,6 @@ LgDoDDC(ScrnInfoPtr pScrn)
 if (!CirMapMem(pCir, pScrn->scrnIndex))
 return FALSE;

-#if LGuseI2C
 if (!LgI2CInit(pScrn)) {
 xf86DrvMsg(pScrn->scrnIndex, X_ERROR,
 "I2C initialization failed\n");
@@ -371,13 +370,10 @@ LgDoDDC(ScrnInfoPtr pScrn)
 xf86PrintEDID(MonInfo);
 xf86DrvMsg(pScrn->scrnIndex, X_INFO,
 "end of I2C Monitor info\n\n");
-#endif /* LGuseI2C */

 xf86SetDDCproperties(pScrn, MonInfo);

-#if LGuseI2C
-unmap_out:
-#endif /* LGuseI2C */
+unmap_out:
 CirUnmapMem(pCir, pScrn->scrnIndex);

 return MonInfo;
--
2.17.1

___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: https://lists.x.org/mailman/listinfo/xorg-devel

[PATCH xf86-video-cirrus 0/3] Laguna I2C bus fix and activation

2019-04-17 Thread Kevin Brace
--
Kevin Brace (3):
  Fix for Laguna I2C bus code compilation error
  Check for a successful transmission of EDID for Laguna I2C bus code
  Activate I2C bus for Laguna based devices

 src/lg_driver.c | 14 --
 1 file changed, 8 insertions(+), 6 deletions(-)

--
2.17.1

___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: https://lists.x.org/mailman/listinfo/xorg-devel

[PATCH xf86-video-cirrus 3/3] Make adjustments to code comments of lg_driver.c

2019-04-17 Thread Kevin Brace
Signed-off-by: Kevin Brace 
---
 src/lg_driver.c | 198 
 1 file changed, 97 insertions(+), 101 deletions(-)

diff --git a/src/lg_driver.c b/src/lg_driver.c
index 67815a5..daaf4f9 100644
--- a/src/lg_driver.c
+++ b/src/lg_driver.c
@@ -21,28 +21,26 @@
 #define EXPERIMENTAL

 /*
- * All drivers should typically include these
+ * All drivers should typically include these.
  */
 #include "xf86.h"
 #include "xf86_OSproc.h"

 /*
- * All drivers need this
+ * All drivers need this.
  */

 #include "compiler.h"

 /*
- * Drivers that need to access the PCI config space directly need this
+ * Drivers that need to access the PCI config space directly need
+ * this.
  */
 #include "xf86Pci.h"

 /*
- * All drivers using the vgahw module need this
- */
-/*
- * This driver needs to be modified to not use vgaHW for multihead
- * operation
+ * All drivers using the vgahw module need this.  This driver needs
+ * to be modified to not use vgaHW for multihead operation.
  */
 #include "vgaHW.h"

@@ -52,19 +50,19 @@
 #endif

 /*
- * All drivers initialising the SW cursor need this
+ * All drivers initialising the SW cursor need this.
  */
 #include "mipointer.h"

 /*
- * need this for inputInfo
+ * Need this for inputInfo.
  */
 #include "inputstr.h"

 #include "micmap.h"

 /*
- * Needed by the Shadow Framebuffer
+ * Needed by the shadowfb.
  */
 #include "shadowfb.h"

@@ -98,11 +96,11 @@ static Bool LgCloseScreen(CLOSE_SCREEN_ARGS_DECL);
 static Bool LgSaveScreen(ScreenPtr pScreen, Bool mode);

 /*
- * Required if the driver supports mode switching
+ * Required if the driver supports mode switching.
  */
 Bool LgSwitchMode(SWITCH_MODE_ARGS_DECL);
 /*
- * Required if the driver supports moving the viewport
+ * Required if the driver supports moving the viewport.
  */
 void LgAdjustFrame(ADJUST_FRAME_ARGS_DECL);

@@ -114,7 +112,7 @@ ModeStatus LgValidMode(SCRN_ARG_TYPE arg, DisplayModePtr 
mode,
 Bool verbose, int flags);

 /*
- * Internally used functions
+ * Internal functions
  */
 static void LgRestoreLgRegs(ScrnInfoPtr pScrn, LgRegPtr lgReg);
 static int LgFindLineData(int displayWidth, int bpp);
@@ -159,7 +157,7 @@ static const OptionInfoRec LgOptions[] = {
 };

 /*
- *   1/4bpp   8bpp   15/16bpp  24bpp  32bpp
+ *   1/4 bpp  8 bpp 15/16 bpp 24 bpp  32 bpp
  */
 static int gd5462_MaxClocks[] =
 { 17, 17, 135100, 135100,  85500 };
@@ -170,7 +168,7 @@ static int gd5465_MaxClocks[] =

 /*
  * We're rather use skinny tiles, so put all of them at the head of
- * the table
+ * the table.
  */
 LgLineDataRec LgLineData[] = {
 { 5,  640, 0},
@@ -188,26 +186,26 @@ LgLineDataRec LgLineData[] = {
 {20, 5120, 1},
 {26, 6656, 1},
 /*
- * Sentinal to indicate end of table
+ * Sentinal to indicate end of table.
  */
 {-1, -1,   -1}
 };

 static int LgLinePitches[4][11] = {
 /*
- * 8
+ *  8 bpp
  */
 { 640, 1024, 1280, 1664, 2048, 2560, 3328, 4096, 5120, 6656, 0 },
 /*
- * 16
+ * 16 bpp
  */
 { 320,  512,  640,  832, 1024, 1280, 1664, 2048, 2560, 3328, 0 },
 /*
- * 24
+ * 24 bpp
  */
 { 213,  341,  426,  554,  682,  853, 1109, 1365, 1706, 2218, 0 },
 /*
- * 32
+ * 32 bpp
  */
 { 160,  256,  320,  416,  512,  640,  832, 1024, 1280, 1664, 0 }
 };
@@ -227,7 +225,7 @@ static XF86ModuleVersionInfo lgVersRec =
 XORG_VERSION_CURRENT,
 LG_MAJOR_VERSION, LG_MINOR_VERSION, LG_PATCHLEVEL,
 /*
- * This is a video driver
+ * This is a video driver.
  */
 ABI_CLASS_VIDEODRV,
 ABI_VIDEODRV_VERSION,
@@ -285,7 +283,7 @@ LgGetRec(ScrnInfoPtr pScrn)
 xnfcalloc(sizeof(LgRec), 1);

 /*
- * Initialize it
+ * Initialize it.
  */
 pCir = CIRPTR(pScrn);
 pCir->chip.lg->oldBitmask = 0x;
@@ -319,8 +317,8 @@ LgCountRam(ScrnInfoPtr pScrn)
 vgaHWProtect(pScrn, TRUE);

 /*
- * The ROM BIOS scratchpad registers contain, among other things,
- * the amount of installed RDRAM on the laguna chip.
+ * The ROM BIOS scratch pad registers contain, among other things,
+ * the amount of installed RDRAM for the Laguna chip.
  */
 SR14 = hwp->readSeq(hwp, 0x14);

@@ -346,7 +344,7 @@ LgDoDDC(ScrnInfoPtr pScrn)
 xf86MonPtr MonInfo = NULL;

 /*
- * Map the CIR memory and MMIO areas
+ * Map the CIR memory and MMIO areas.
  */
 if (!CirMapMem(pCir, pScrn->scrnIndex))
 return FALSE;
@@ -359,7 +357,7 @@ LgDoDDC(ScrnInfoPtr pScrn)
 }

 /*
- * Read and output monitor info using DDC2 over I2C bus
+ * Read and output monitor info using DDC2 over I2C bus.
  */
 MonInfo = xf86DoEDID_DDC2(pScrn->scrnIndex, pCir->I2CPtr1);
 xf86DrvMsg(pScrn->scrnIndex, X_INFO,
@@ -410,13 +408,13 @@ LgPreInit(ScrnInfoPtr pScrn, int flags)
 return FALSE;

 /*
- * The vgahw module should be loaded here when needed
+ * The vgahw module should be lo

[PATCH xf86-video-cirrus 2/3] Fix indentation of lg_driver.c

2019-04-17 Thread Kevin Brace
Signed-off-by: Kevin Brace 
---
 src/lg_driver.c | 1451 +++
 1 file changed, 977 insertions(+), 474 deletions(-)

diff --git a/src/lg_driver.c b/src/lg_driver.c
index 6bbbc15..67815a5 100644
--- a/src/lg_driver.c
+++ b/src/lg_driver.c
@@ -20,19 +20,30 @@

 #define EXPERIMENTAL

-/* All drivers should typically include these */
+/*
+ * All drivers should typically include these
+ */
 #include "xf86.h"
 #include "xf86_OSproc.h"

-/* All drivers need this */
+/*
+ * All drivers need this
+ */

 #include "compiler.h"

-/* Drivers that need to access the PCI config space directly need this */
+/*
+ * Drivers that need to access the PCI config space directly need this
+ */
 #include "xf86Pci.h"

-/* All drivers using the vgahw module need this */
-/* This driver needs to be modified to not use vgaHW for multihead operation */
+/*
+ * All drivers using the vgahw module need this
+ */
+/*
+ * This driver needs to be modified to not use vgaHW for multihead
+ * operation
+ */
 #include "vgaHW.h"

 #if GET_ABI_MAJOR(ABI_VIDEODRV_VERSION) < 6
@@ -40,15 +51,21 @@
 #include "xf86Resources.h"
 #endif

-/* All drivers initialising the SW cursor need this */
+/*
+ * All drivers initialising the SW cursor need this
+ */
 #include "mipointer.h"

-/* need this for inputInfo */
+/*
+ * need this for inputInfo
+ */
 #include "inputstr.h"

 #include "micmap.h"

-/* Needed by the Shadow Framebuffer */
+/*
+ * Needed by the Shadow Framebuffer
+ */
 #include "shadowfb.h"

 #include "xf86int10.h"
@@ -70,7 +87,9 @@
  * Forward definitions for the functions that make up the driver.
  */

-/* Mandatory functions */
+/*
+ * Mandatory functions
+ */
 Bool LgPreInit(ScrnInfoPtr pScrn, int flags);
 Bool LgScreenInit(SCREEN_INIT_ARGS_DECL);
 Bool LgEnterVT(VT_FUNC_ARGS_DECL);
@@ -78,24 +97,33 @@ void LgLeaveVT(VT_FUNC_ARGS_DECL);
 static Bool LgCloseScreen(CLOSE_SCREEN_ARGS_DECL);
 static Bool LgSaveScreen(ScreenPtr pScreen, Bool mode);

-/* Required if the driver supports mode switching */
+/*
+ * Required if the driver supports mode switching
+ */
 Bool LgSwitchMode(SWITCH_MODE_ARGS_DECL);
-/* Required if the driver supports moving the viewport */
+/*
+ * Required if the driver supports moving the viewport
+ */
 void LgAdjustFrame(ADJUST_FRAME_ARGS_DECL);

-/* Optional functions */
+/*
+ * Optional functions
+ */
 void LgFreeScreen(FREE_SCREEN_ARGS_DECL);
 ModeStatus LgValidMode(SCRN_ARG_TYPE arg, DisplayModePtr mode,
 Bool verbose, int flags);

-/* Internally used functions */
+/*
+ * Internally used functions
+ */
 static void LgRestoreLgRegs(ScrnInfoPtr pScrn, LgRegPtr lgReg);
 static int LgFindLineData(int displayWidth, int bpp);
 static CARD16 LgSetClock(CirPtr pCir, vgaHWPtr hwp, int freq);
 static void lg_vgaHWSetMmioFunc(vgaHWPtr hwp, CARD8 *base);

 static void LgDisplayPowerManagementSet(ScrnInfoPtr pScrn,
-int PowerManagementMode, int flags);
+int PowerManagementMode,
+int flags);

 /*
  * This is intentionally screen-independent.  It indicates the binding
@@ -105,10 +133,10 @@ static int pix24bpp = 0;

 /*
  * This contains the functions needed by the server after loading the
- * driver module.  It must be supplied, and gets added the driver list by
- * the Module Setup funtion in the dynamic case.  In the static case a
- * reference to this is compiled in, and this requires that the name of
- * this DriverRec be an upper-case version of the driver name.
+ * driver module.  It must be supplied, and gets added the driver list
+ * by the Module Setup funtion in the dynamic case.  In the static
+ * case a reference to this is compiled in, and this requires that the
+ * name of this DriverRec be an upper-case version of the driver name.
  */

 typedef enum {
@@ -124,18 +152,29 @@ static const OptionInfoRec LgOptions[] = {
 { OPTION_NOACCEL,   "NoAccel",  OPTV_BOOLEAN,   {0},FALSE },
 { OPTION_SHADOW_FB, "ShadowFB", OPTV_BOOLEAN,   {0},FALSE },
 { OPTION_ROTATE,"Rotate",   OPTV_ANYSTR,{0},FALSE },
-/* fifo_conservative/aggressive; fast/med/slow_dram; ... */
+/*
+ * fifo_conservative/aggressive; fast/med/slow_dram; ...
+ */
 { -1,   NULL,   OPTV_NONE,  {0},FALSE }
 };

-/*1/4bpp   8bpp   15/16bpp  24bpp  32bpp */
-static int gd5462_MaxClocks[] = { 17, 17, 135100, 135100,  85500 };
-static int gd5464_MaxClocks[] = { 17, 25, 17, 17, 135100 };
-static int gd5465_MaxClocks[] = { 17, 25, 17, 17, 135100 };
+/*
+ *   1/4bpp   8bpp   15/16bpp  24bpp  32bpp
+ */
+static int gd5462_MaxClocks[] =
+{ 17, 17, 135100, 135100,  85500 };
+static int gd5464_MaxClocks[] =
+{ 17, 25, 17, 17, 135100 };
+static int gd5465_MaxClocks[] =
+

[PATCH xf86-video-cirrus 1/3] Tab to spaces conversion for lg_driver.c

2019-04-17 Thread Kevin Brace
Signed-off-by: Kevin Brace 
---
 src/lg_driver.c | 2712 +++
 1 file changed, 1338 insertions(+), 1374 deletions(-)

diff --git a/src/lg_driver.c b/src/lg_driver.c
index 60280df..6bbbc15 100644
--- a/src/lg_driver.c
+++ b/src/lg_driver.c
@@ -9,9 +9,9 @@
  *
  * This driver is derived from the cir_driver.c module.
  * Original authors and contributors list include:
- * Radoslaw Kapitan, Andrew Vanderstock, Dirk Hohndel,
- * David Dawes, Andrew E. Mileski, Leonard N. Zubkoff,
- * Guy DESBIEF, Itai Nahshon.
+ *  Radoslaw Kapitan, Andrew Vanderstock, Dirk Hohndel,
+ *  David Dawes, Andrew E. Mileski, Leonard N. Zubkoff,
+ *  Guy DESBIEF, Itai Nahshon.
  */

 #ifdef HAVE_CONFIG_H
@@ -75,8 +75,8 @@ Bool LgPreInit(ScrnInfoPtr pScrn, int flags);
 Bool LgScreenInit(SCREEN_INIT_ARGS_DECL);
 Bool LgEnterVT(VT_FUNC_ARGS_DECL);
 void LgLeaveVT(VT_FUNC_ARGS_DECL);
-static BoolLgCloseScreen(CLOSE_SCREEN_ARGS_DECL);
-static BoolLgSaveScreen(ScreenPtr pScreen, Bool mode);
+static Bool LgCloseScreen(CLOSE_SCREEN_ARGS_DECL);
+static Bool LgSaveScreen(ScreenPtr pScreen, Bool mode);

 /* Required if the driver supports mode switching */
 Bool LgSwitchMode(SWITCH_MODE_ARGS_DECL);
@@ -86,7 +86,7 @@ void LgAdjustFrame(ADJUST_FRAME_ARGS_DECL);
 /* Optional functions */
 void LgFreeScreen(FREE_SCREEN_ARGS_DECL);
 ModeStatus LgValidMode(SCRN_ARG_TYPE arg, DisplayModePtr mode,
-  Bool verbose, int flags);
+Bool verbose, int flags);

 /* Internally used functions */
 static void LgRestoreLgRegs(ScrnInfoPtr pScrn, LgRegPtr lgReg);
@@ -95,7 +95,7 @@ static CARD16 LgSetClock(CirPtr pCir, vgaHWPtr hwp, int freq);
 static void lg_vgaHWSetMmioFunc(vgaHWPtr hwp, CARD8 *base);

 static void LgDisplayPowerManagementSet(ScrnInfoPtr pScrn,
-   int PowerManagementMode, int flags);
+int PowerManagementMode, int flags);

 /*
  * This is intentionally screen-independent.  It indicates the binding
@@ -112,51 +112,50 @@ static int pix24bpp = 0;
  */

 typedef enum {
-   OPTION_HW_CURSOR,
-   OPTION_PCI_RETRY,
-   OPTION_ROTATE,
-   OPTION_SHADOW_FB,
-   OPTION_NOACCEL
+OPTION_HW_CURSOR,
+OPTION_PCI_RETRY,
+OPTION_ROTATE,
+OPTION_SHADOW_FB,
+OPTION_NOACCEL
 } LgOpts;

 static const OptionInfoRec LgOptions[] = {
-{ OPTION_HW_CURSOR,"HWcursor", OPTV_BOOLEAN,   {0}, 
FALSE },
-{ OPTION_NOACCEL,  "NoAccel",  OPTV_BOOLEAN,   {0}, FALSE },
-{ OPTION_SHADOW_FB, "ShadowFB",OPTV_BOOLEAN,   {0}, FALSE },
-{ OPTION_ROTATE,   "Rotate",   OPTV_ANYSTR,{0}, FALSE },
+{ OPTION_HW_CURSOR, "HWcursor", OPTV_BOOLEAN,   {0},FALSE },
+{ OPTION_NOACCEL,   "NoAccel",  OPTV_BOOLEAN,   {0},FALSE },
+{ OPTION_SHADOW_FB, "ShadowFB", OPTV_BOOLEAN,   {0},FALSE },
+{ OPTION_ROTATE,"Rotate",   OPTV_ANYSTR,{0},FALSE },
 /* fifo_conservative/aggressive; fast/med/slow_dram; ... */
-{ -1,  NULL,   OPTV_NONE,  
{0}, FALSE }
+{ -1,   NULL,   OPTV_NONE,  {0},FALSE }
 };

-
 /*1/4bpp   8bpp   15/16bpp  24bpp  32bpp */
 static int gd5462_MaxClocks[] = { 17, 17, 135100, 135100,  85500 };
 static int gd5464_MaxClocks[] = { 17, 25, 17, 17, 135100 };
 static int gd5465_MaxClocks[] = { 17, 25, 17, 17, 135100 };

 LgLineDataRec LgLineData[] = {
-   { 5,  640, 0},  /* We're rather use skinny tiles, so put all of 
*/
-   { 8, 1024, 0},  /* them at the head of the table */
-   {10, 1280, 0},
-   {13, 1664, 0},
-   {16, 2048, 0},
-   {20, 2560, 0},
-   {10, 2560, 1},
-   {26, 3328, 0},
-   { 5, 1280, 1},
-   { 8, 2048, 1},
-   {13, 3328, 1},
-   {16, 4096, 1},
-   {20, 5120, 1},
-   {26, 6656, 1},
-   {-1, -1, -1}/* Sentinal to indicate end of table */
+{ 5,  640, 0},  /* We're rather use skinny tiles, so put all of */
+{ 8, 1024, 0},  /* them at the head of the table */
+{10, 1280, 0},
+{13, 1664, 0},
+{16, 2048, 0},
+{20, 2560, 0},
+{10, 2560, 1},
+{26, 3328, 0},
+{ 5, 1280, 1},
+{ 8, 2048, 1},
+{13, 3328, 1},
+{16, 4096, 1},
+{20, 5120, 1},
+{26, 6656, 1},
+{-1, -1,   -1}  /* Sentinal to indicate end of table */
 };

 static int LgLinePitches[4][11] = {
-   /*  8 */ { 640, 1024, 1280, 1664, 2048, 2560, 3328, 4096, 5120, 6656, 0 
},
-   /* 16 */ { 320,  512,  640,  832, 1024, 1280, 1664, 2048, 2560, 3328, 0 
},
-   /* 24 */ { 213,  341,  426,  554,  682,  853, 1109, 1365, 1706, 2218, 0 
},
-   /* 32 */ { 160,  256,  320,  416,  512,  640,  832, 1024, 1280, 1664, 0 
}
+/*  8 */ { 640, 1024, 1280, 1664, 2048, 2560, 3328, 4096, 5120,

[PATCH xf86-video-cirrus 0/3] Clean up lg_driver.c

2019-04-17 Thread Kevin Brace
--

Kevin Brace (3):
  Tab to spaces conversion for lg_driver.c
  Fix indentation of lg_driver.c
  Make adjustments to code comments of lg_driver.c

 src/lg_driver.c | 3259 +++
 1 file changed, 1861 insertions(+), 1398 deletions(-)

--
2.17.1

___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: https://lists.x.org/mailman/listinfo/xorg-devel

RFC - GLX Extension to control GLXVND dispatching for PRIME GPU offloading

2019-04-17 Thread Kyle Brenneman
For GPU offloading in libglvnd, where individual clients can run with an 
alternate GPU and client-side vendor library, we'd need some way for 
that alternate vendor library to communicate with its server-side 
counterpart. Normally, the server's GLXVND layer would dispatch any GLX 
requests to whichever driver is running an X screen. This is a GLX 
extension that allows a client to tell the server to send GLX requests 
to a different driver instead.


The basic idea is that the server keeps a separate (screen -> 
GLXServerVendor) mapping for each client. The current global mapping is 
used as the default for each new client, but the client can send a 
request to change its own mapping. That way, if the client uses a 
different vendor library, then the client-side vendor can arrange for 
any GLX requests to go to the matching server-side driver.


The extension uses Atoms as an ID to identify each GLXServerVendor, 
using a string provided by the driver. That way, the client-side driver 
can know which Atom it needs to use without having to define an extra 
query. The client can send a request with a screen number and a vendor 
ID to tell the server to dispatch any GLX requests for that screen to 
the specified vendor. A client can also send None as a vendor ID to 
revert to whatever GLXServerVendor would handle that screen by default.


I also added a GLXVendorPrivate/GLXVendorPrivateWithReply-style request, 
which sends a request to a specific vendor based on a vendor ID, without 
having to worry about which vendor is assigned to a screen at the 
moment. Strictly speaking, a vendor library could get the same result by 
adding a regular GLXVendorPrivate request, and providing a dispatch 
function that always routes the request to itself, but that seems like 
it's more of an implementation detail of GLXVND.


Also, this extension doesn't define any errors or queries to check 
whether a GLXServerVendor can support a given screen. These requests 
would be sent by a client-side vendor library (not by libglvnd or an 
application), so each driver would be responsible for figuring out on 
its own which screens it can support.


Anyway, I've got a draft of the extension spec here, and I've written up 
a series of patches for the X server to implement it here:

https://gitlab.freedesktop.org/kbrenneman/xserver/tree/GLX_EXT_server_vendor_select

Comments and questions welcome.

-Kyle Brenneman


Name

EXT_server_vendor_select

Name Strings

GLX_EXT_server_vendor_select

Contact

Kyle Brenneman, NVIDIA, kbrenneman at nvidia.com

Contributors

Kyle Brenneman

Status

XXX - Not complete yet!!!

Version

Last Modified Date: April 11, 2019
Revision: 1

Number

OpenGL Extension #???

Dependencies

GLX version 1.2 is required.

This specification is written against the wording of the GLX 1.3
Protocol Encoding Specification.

Overview

In multi-GPU systems, a client may decide at runtime which device
and driver to use for GLX, for example to choose between a
high-performance and low-power device.

This extension defines a set of requests that allow a client to
specify which server-side driver should handle GLX requests from the
sending client for a particular screen.

IP Status

No known IP claims.

New Procedures and Functions

None

New Tokens

None

Additions to the GLX Specification

None. These requests are intended to be used by a client-side GLX
implementation, not by an application. Therefore, this extension
does not define any new functions or changes to the GLX
specification.

GLX Protocol

Get a List of Server-Side Drivers

Name: glXQueryServerVendorIDsEXT

Description:
This request fetches a list of available server-side
drivers, and the current vendor ID selected for each screen.
Each driver is identified by an Atom, with a string chosen
by the driver.

The reply contains a list of the currently selected vendors
first, with one Atom for each screen. This will be the
vendor selected with the glXSelectScreenServerVendorIDEXT
request, or the default vendor if the client has not sent a
glXSelectScreenServerVendorIDEXT request for a screen.

If a screen is using the default vendor, and the vendor does
not have a vendor ID, then the corresponding Atom in the
reply will be None.

After the currently selected vendors, the reply will contain
a list of all available vendor ID's.

Note that the list of available vendors is global, not
per-screen. The client-side driver is responsible for
determining which screens it can support.

Encoding:
1   CARD8   opcode (X assigned)
1   17  GLX opcode (glXVendorPrivateWithReply)
2   3   request 

Re: 2019 X.Org Foundation Elections Results... and a Redo

2019-04-17 Thread Wentland, Harry
The turnout for the first election and the vote on the bylaw changes was 80% 
(56/70).

Harry

On 2019-04-11 8:03 p.m., Harry Wentland wrote:
> To all X.Org Foundation Members:
> 
> The 2019 X.Org ballot closed yesterday. There is some good and some bad news.
> 
> The Good News:
> The vote on the bylaw changes passed with 53 for, 1 against, and 2 abstaining.
> 
> The Bad News:
> Due to some issues with our new members website all votes for new board 
> members were recorded incorrectly. Thankfully this was fairly obvious. We 
> believe we've found the bug and have a fix for it: 
> https://gitlab.freedesktop.org/xorgfoundation/xorg_membership/commit/15f27d45f1d9b1767377814835f2359f7f76c7e5
> 
> The Redo:
> To assure you and us that we've completely fixed the issues with our 
> elections site we have decided to run a brief mock election where you can 
> vote for your favorite pastry. This will run until Monday Apr 15 noon UTC 
> after which we'll tally and publish the results and confirm whether we fixed 
> the issue. Please leave your vote at https://members.x.org/ballot/3/admin
> 
> If this all looks good we will start the new election for board members a 
> week from today, on Apr 18, until May 2.
> 
> You can expect another email from me early-to-mid next week to confirm the 
> start of the new election for board members.
> 
> We received quite a few membership signups after the membership deadline. 
> We've decided to approve all currently pending signups.
> 
> Harry, on behalf of the X.Org elections committee
___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: https://lists.x.org/mailman/listinfo/xorg-devel

2019 X.Org Foundation Election Round 2 Starting Thursday

2019-04-17 Thread Wentland, Harry
To all X.Org Foundation Members:

as per my last email the election for X.Org board members was invalid due to a 
bug with the voting systems. We apologize for this and the inconvenience caused 
to you all. The bug has been fixed and tested with a mock election (see results 
at the end).

Round 2 of the election will therefore proceed starting Thursday, April 18, and 
close on Thursday May 2.

Please take the time to vote.

Updated Schedule:
   Nomination period Start: Jan 31 00:00 UTC
   Nomination period End: Feb 28 23:59 UTC
   Deadline of X.Org membership application or renewal: Mar 07 23:59 UTC
   Publication of Candidates & start of Candidate QA: Mar 11
   Election Start: Mar 21 00:00 UTC - Delayed to March 21, again delayed to 
March 27 at 02:00 UTC
   Election End: Apr 4 23:59 UTC - Extended to April 11, 02:00 UTC
   Round 2 Election Start: Apr 18 00:00:00 UTC
   Round 2 Election End: May 2 23:59:00 UTC

Harry, on behalf of the X.Org elections committee

---

Mock election results

Ballot Statistics
Turnout: 27.4% (23 / 84)

Select: How much do you like pastries?
Answer  Votes
42  47.8% (11 / 23)
A lot   34.8% (8 / 23)
To death17.4% (4 / 23)

Ranking: Rank the following lovely pastries!
Option  Rank 1  Rank 2  Rank 3  Rank 4  Rank 5  Rank 6  Final 
Score
Apple strudel   13  4   2   1   1   2   113
Cinnamon Roll   3   7   3   1   2   7   79
Gâteau Basque   3   4   4   1   8   3   76
Beaver Tails3   1   4   8   3   4   73
Trdelník0   5   3   6   7   2   71
Runeberg's torte1   2   7   6   2   5   71
___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: https://lists.x.org/mailman/listinfo/xorg-devel