diff --git a/glamor/glamor_egl.c b/glamor/glamor_egl.c index e508f9df0..59dd067b4 100644 --- a/glamor/glamor_egl.c +++ b/glamor/glamor_egl.c @@ -33,7 +33,7 @@ #include #include #include -#include +#include "xf86_priv.h" #include #include #define EGL_DISPLAY_NO_X_MESA diff --git a/hw/xfree86/common/xf86AutoConfig.c b/hw/xfree86/common/xf86AutoConfig.c index 7142c683d..df9377f8c 100644 --- a/hw/xfree86/common/xf86AutoConfig.c +++ b/hw/xfree86/common/xf86AutoConfig.c @@ -32,7 +32,7 @@ #include "os/osdep.h" -#include "xf86.h" +#include "xf86_priv.h" #include "xf86Parser_priv.h" #include "xf86tokens.h" #include "xf86Config.h" diff --git a/hw/xfree86/common/xf86Globals.c b/hw/xfree86/common/xf86Globals.c index 336e0897f..1aa247099 100644 --- a/hw/xfree86/common/xf86Globals.c +++ b/hw/xfree86/common/xf86Globals.c @@ -96,18 +96,14 @@ xf86InfoRec xf86Info = { .vtno = -1, .lastEventTime = -1, .vtRequestsPending = FALSE, -#ifdef __sun .vtPendingNum = -1, -#endif .dontVTSwitch = FALSE, .autoVTSwitch = TRUE, .ShareVTs = FALSE, .dontZap = FALSE, .dontZoom = FALSE, .currentScreen = NULL, -#ifdef CSRG_BASED .consType = -1, -#endif .allowMouseOpenFail = FALSE, .vidModeEnabled = TRUE, .vidModeAllowNonLocal = FALSE, diff --git a/hw/xfree86/common/xf86Priv.h b/hw/xfree86/common/xf86Priv.h index dfd834ff5..db214f7a8 100644 --- a/hw/xfree86/common/xf86Priv.h +++ b/hw/xfree86/common/xf86Priv.h @@ -43,7 +43,6 @@ extern _X_EXPORT int xf86Depth; /* Other parameters */ -extern _X_EXPORT xf86InfoRec xf86Info; extern _X_EXPORT serverLayoutRec xf86ConfigLayout; extern _X_EXPORT DriverPtr *xf86DriverList; diff --git a/hw/xfree86/common/xf86Privstr.h b/hw/xfree86/common/xf86Privstr.h index 38100c4db..8c7630aad 100644 --- a/hw/xfree86/common/xf86Privstr.h +++ b/hw/xfree86/common/xf86Privstr.h @@ -42,63 +42,6 @@ typedef enum { XF86_GlxVisualsAll, } XF86_GlxVisuals; -/* - * xf86InfoRec contains global parameters which the video drivers never - * need to access. Global parameters which the video drivers do need - * should be individual globals. - */ - -typedef struct { - int consoleFd; - int vtno; - - /* event handler part */ - int lastEventTime; - Bool vtRequestsPending; -#ifdef __sun - int vtPendingNum; -#endif - Bool dontVTSwitch; - Bool autoVTSwitch; - Bool ShareVTs; - Bool dontZap; - Bool dontZoom; - - /* graphics part */ - ScreenPtr currentScreen; -#if defined(CSRG_BASED) || defined(__FreeBSD_kernel__) - int consType; /* Which console driver? */ -#endif - - /* Other things */ - Bool allowMouseOpenFail; - Bool vidModeEnabled; /* VidMode extension enabled */ - Bool vidModeAllowNonLocal; /* allow non-local VidMode - * connections */ - Bool pmFlag; - MessageType iglxFrom; - XF86_GlxVisuals glxVisuals; - MessageType glxVisualsFrom; - - Bool useDefaultFontPath; - Bool ignoreABI; - - Bool forceInputDevices; /* force xorg.conf or built-in input devices */ - Bool autoAddDevices; /* Whether to succeed NIDR, or ignore. */ - Bool autoEnableDevices; /* Whether to enable, or let the client - * control. */ - - Bool dri2; - MessageType dri2From; - - Bool autoAddGPU; - const char *debug; - Bool autoBindGPU; - - Bool singleDriver; /* Only the first successfully probed driver adds primary screens, - * others may add GPU secondary screens only */ -} xf86InfoRec, *xf86InfoPtr; - /* ISC's cc can't handle ~ of UL constants, so explicitly type cast them. */ #define XLED1 ((unsigned long) 0x00000001) #define XLED2 ((unsigned long) 0x00000002) diff --git a/hw/xfree86/common/xf86_priv.h b/hw/xfree86/common/xf86_priv.h index bb62ee986..77fe4ddd0 100644 --- a/hw/xfree86/common/xf86_priv.h +++ b/hw/xfree86/common/xf86_priv.h @@ -8,6 +8,8 @@ #include "os/osdep.h" #include "xf86.h" +#include "xf86Privstr.h" + extern Bool xf86DoConfigure; extern Bool xf86DoConfigurePass1; extern Bool xf86ProbeIgnorePrimary; @@ -102,4 +104,43 @@ void xf86ExtensionInit(void); void DoConfigure(void) _X_NORETURN; void DoShowOptions(void) _X_NORETURN; +/* + * global parameters only inside DDX itself, not accessible by drivers + * (should split them out to separate fields) + */ +typedef struct { + int consoleFd; + int vtno; + int lastEventTime; + bool vtRequestsPending; + int vtPendingNum; + Bool dontVTSwitch; + bool autoVTSwitch; + bool ShareVTs; + Bool dontZap; + Bool dontZoom; + ScreenPtr currentScreen; + int consType; + bool allowMouseOpenFail; + bool vidModeEnabled; + bool vidModeAllowNonLocal; + bool pmFlag; + MessageType iglxFrom; + XF86_GlxVisuals glxVisuals; + MessageType glxVisualsFrom; + bool useDefaultFontPath; + Bool ignoreABI; + bool forceInputDevices; + Bool autoAddDevices; + Bool autoEnableDevices; + bool dri2; + MessageType dri2From; + Bool autoAddGPU; + const char *debug; + Bool autoBindGPU; + Bool singleDriver; +} xf86InfoRec; + +extern _X_EXPORT /* internal only */ xf86InfoRec xf86Info; + #endif /* _XSERVER_XF86_PRIV_H */ diff --git a/hw/xfree86/os-support/bsd/bsd_VTsw.c b/hw/xfree86/os-support/bsd/bsd_VTsw.c index faf7f96fa..8d1905179 100644 --- a/hw/xfree86/os-support/bsd/bsd_VTsw.c +++ b/hw/xfree86/os-support/bsd/bsd_VTsw.c @@ -26,7 +26,7 @@ #include -#include "xf86.h" +#include "xf86_priv.h" #include "xf86Priv.h" #include "xf86_os_support.h" #include "xf86_OSlib.h" diff --git a/hw/xfree86/os-support/bsd/bsd_bell.c b/hw/xfree86/os-support/bsd/bsd_bell.c index aaa73ef06..2f0dddd20 100644 --- a/hw/xfree86/os-support/bsd/bsd_bell.c +++ b/hw/xfree86/os-support/bsd/bsd_bell.c @@ -30,7 +30,7 @@ #include -#include "xf86.h" +#include "xf86_priv.h" #include "xf86Priv.h" #include "xf86_os_support.h" #include "xf86_OSlib.h" diff --git a/hw/xfree86/os-support/bsd/bsd_init.c b/hw/xfree86/os-support/bsd/bsd_init.c index ae7dc9f6c..5b1a9546f 100644 --- a/hw/xfree86/os-support/bsd/bsd_init.c +++ b/hw/xfree86/os-support/bsd/bsd_init.c @@ -29,7 +29,7 @@ #include "os/cmdline.h" #include "compiler.h" -#include "xf86.h" +#include "xf86_priv.h" #include "xf86Priv.h" #include "xf86_os_support.h" #include "xf86_OSlib.h" diff --git a/hw/xfree86/os-support/bsd/ppc_video.c b/hw/xfree86/os-support/bsd/ppc_video.c index 5eeb61516..22ab6362b 100644 --- a/hw/xfree86/os-support/bsd/ppc_video.c +++ b/hw/xfree86/os-support/bsd/ppc_video.c @@ -27,7 +27,7 @@ #include #include -#include "xf86.h" +#include "xf86_priv.h" #include "xf86Priv.h" #include "xf86_os_support.h" #include "xf86_OSlib.h" diff --git a/hw/xfree86/os-support/hurd/hurd_init.c b/hw/xfree86/os-support/hurd/hurd_init.c index f368331a8..a42de8917 100644 --- a/hw/xfree86/os-support/hurd/hurd_init.c +++ b/hw/xfree86/os-support/hurd/hurd_init.c @@ -29,7 +29,7 @@ #include "compiler.h" -#include "xf86.h" +#include "xf86_priv.h" #include "xf86Priv.h" #include "xf86_os_support.h" #include "xf86_OSlib.h" diff --git a/hw/xfree86/os-support/linux/lnx_bell.c b/hw/xfree86/os-support/linux/lnx_bell.c index e52e1b6e9..a9b984610 100644 --- a/hw/xfree86/os-support/linux/lnx_bell.c +++ b/hw/xfree86/os-support/linux/lnx_bell.c @@ -27,6 +27,7 @@ #include #include +#include "xf86_priv.h" #include "xf86Priv.h" #include "xf86_os_support.h" diff --git a/hw/xfree86/os-support/shared/VTsw_usl.c b/hw/xfree86/os-support/shared/VTsw_usl.c index 21ec884bb..bb969d43a 100644 --- a/hw/xfree86/os-support/shared/VTsw_usl.c +++ b/hw/xfree86/os-support/shared/VTsw_usl.c @@ -26,7 +26,7 @@ #include "os/osdep.h" -#include "xf86.h" +#include "xf86_priv.h" #include "xf86Priv.h" #include "xf86_os_support.h" #include "xf86_OSlib.h" diff --git a/hw/xfree86/os-support/solaris/sun_VTsw.c b/hw/xfree86/os-support/solaris/sun_VTsw.c index 1f14ed1fa..d501d9c85 100644 --- a/hw/xfree86/os-support/solaris/sun_VTsw.c +++ b/hw/xfree86/os-support/solaris/sun_VTsw.c @@ -24,7 +24,7 @@ #include -#include "xf86.h" +#include "xf86_priv.h" #include "xf86Priv.h" #include "xf86_os_support.h" #include "xf86_OSlib.h"