Bugzilla – Attachment 62179 Details for
Bug 137374
xsload cannot load load _drv.so drivers
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
IDP Log In
|
Forgot Password
[patch]
Xorg dif
xf86.dif (text/plain), 5.11 KB, created by
Marcus Schaefer
on 2006-01-06 15:09:17 UTC
(
hide
)
Description:
Xorg dif
Filename:
MIME Type:
Creator:
Marcus Schaefer
Created:
2006-01-06 15:09:17 UTC
Size:
5.11 KB
patch
obsolete
>? Makefile >? modedefs >? xf86DefModeSet.c >Index: xf86.h >=================================================================== >RCS file: /cvs/xorg/xc/programs/Xserver/hw/xfree86/common/xf86.h,v >retrieving revision 1.10 >diff -u -r1.10 xf86.h >--- xf86.h 29 Oct 2005 21:31:23 -0000 1.10 >+++ xf86.h 6 Jan 2006 14:57:23 -0000 >@@ -53,6 +53,7 @@ > > /* General parameters */ > extern int xf86DoConfigure; >+extern int xf86DoShowOptions; > extern Bool xf86DoConfigurePass1; > extern int xf86ScreenIndex; /* Index into pScreen.devPrivates */ > extern int xf86CreateRootWindowIndex; /* Index into pScreen.devPrivates */ >Index: xf86Configure.c >=================================================================== >RCS file: /cvs/xorg/xc/programs/Xserver/hw/xfree86/common/xf86Configure.c,v >retrieving revision 1.16 >diff -u -r1.16 xf86Configure.c >--- xf86Configure.c 14 Nov 2005 18:49:30 -0000 1.16 >+++ xf86Configure.c 6 Jan 2006 14:57:23 -0000 >@@ -771,6 +771,57 @@ > return ptr; > } > >+void DoShowOptions (void) { >+ int i = 0; >+ char **vlist = 0; >+ char *pSymbol = 0; >+ XF86ModuleData *initData = 0; >+ if (! (vlist = xf86DriverlistFromCompile())) { >+ ErrorF("Missing output drivers\n"); >+ goto bail; >+ } >+ xf86LoadModules (vlist,0); >+ xfree (vlist); >+ for (i = 0; i < xf86NumDrivers; i++) { >+ if (xf86DriverList[i]->AvailableOptions) { >+ OptionInfoPtr pOption = (OptionInfoPtr)(*xf86DriverList[i]->AvailableOptions)(0,0); >+ if (! pOption) { >+ ErrorF ("(EE) Couldn't read option table for %s driver\n", >+ xf86DriverList[i]->driverName >+ ); >+ continue; >+ } >+ pSymbol = xalloc ( >+ strlen(xf86DriverList[i]->driverName) + strlen("ModuleData") + 1 >+ ); >+ strcpy (pSymbol, xf86DriverList[i]->driverName); >+ strcat (pSymbol, "ModuleData"); >+ initData = LoaderSymbol (pSymbol); >+ if (initData) { >+ XF86ModuleVersionInfo *vers = initData->vers; >+ ErrorF ("Driver: %d:%s [%s]\n", >+ i,xf86DriverList[i]->driverName,vers->vendor >+ ); >+ OptionInfoPtr p; >+ for (p = pOption; p->name != NULL; p++) { >+ const char *opttype = optionTypeToSting(p->type); >+ char *optname = xalloc(strlen(p->name) + 2 + 1); >+ if (!optname) { >+ continue; >+ } >+ sprintf(optname, "\"%s\"", p->name); >+ ErrorF ("\t%s %s\n", optname,opttype); >+ } >+ } >+ } >+ } >+ bail: >+ OsCleanup (TRUE); >+ AbortDDX (); >+ fflush (stderr); >+ exit (0); >+} >+ > void > DoConfigure() > { >Index: xf86Globals.c >=================================================================== >RCS file: /cvs/xorg/xc/programs/Xserver/hw/xfree86/common/xf86Globals.c,v >retrieving revision 1.9 >diff -u -r1.9 xf86Globals.c >--- xf86Globals.c 14 Dec 2005 20:12:00 -0000 1.9 >+++ xf86Globals.c 6 Jan 2006 14:57:23 -0000 >@@ -189,6 +189,7 @@ > Bool xf86ProbeFailed = FALSE; > Bool xf86DoProbe = FALSE; > Bool xf86DoConfigure = FALSE; >+Bool xf86DoShowOptions = FALSE; > #ifdef XFree86LOADER > DriverPtr *xf86DriverList = NULL; > int xf86NumDrivers = 0; >Index: xf86Init.c >=================================================================== >RCS file: /cvs/xorg/xc/programs/Xserver/hw/xfree86/common/xf86Init.c,v >retrieving revision 1.29 >diff -u -r1.29 xf86Init.c >--- xf86Init.c 14 Dec 2005 20:12:00 -0000 1.29 >+++ xf86Init.c 6 Jan 2006 14:57:24 -0000 >@@ -323,7 +323,7 @@ > } > > /* Read and parse the config file */ >- if (!xf86DoProbe && !xf86DoConfigure) { >+ if (!xf86DoProbe && !xf86DoConfigure && !xf86DoShowOptions) { > switch (xf86HandleConfigFile(FALSE)) { > case CONFIG_OK: > break; >@@ -385,6 +385,9 @@ > > #endif > >+ if (xf86DoShowOptions) >+ DoShowOptions(); >+ > xf86OpenConsole(); > > /* Do a general bus probe. This will be a PCI probe for x86 platforms */ >@@ -1687,6 +1690,15 @@ > xf86AllowMouseOpenFail = TRUE; > return 1; > } >+ if (!strcmp(argv[i], "-showopts")) >+ { >+ if (getuid() != 0 && geteuid == 0) { >+ ErrorF("The '-showopts' option can only be used by root.\n"); >+ exit(1); >+ } >+ xf86DoShowOptions = TRUE; >+ return 1; >+ } > if (!strcmp(argv[i], "-isolateDevice")) > { > int bus, device, func; >@@ -1729,6 +1741,7 @@ > ErrorF("-modulepath paths specify the module search path\n"); > ErrorF("-logfile file specify a log file name\n"); > ErrorF("-configure probe for devices and write an "__XCONFIGFILE__"\n"); >+ ErrorF("-showopts print available options for all installed drivers\n"); > } > ErrorF("-config file specify a configuration file, relative to the\n"); > ErrorF(" "__XCONFIGFILE__" search path, only root can use absolute\n"); >Index: xf86Priv.h >=================================================================== >RCS file: /cvs/xorg/xc/programs/Xserver/hw/xfree86/common/xf86Priv.h,v >retrieving revision 1.7 >diff -u -r1.7 xf86Priv.h >--- xf86Priv.h 14 Dec 2005 20:12:00 -0000 1.7 >+++ xf86Priv.h 6 Jan 2006 14:57:24 -0000 >@@ -174,6 +174,7 @@ > void DoProbeArgs(int argc, char **argv, int i); > void DoProbe(void); > void DoConfigure(void); >+void DoShowOptions(void); > > /* xf86Events.c */ >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
Actions:
View
|
Diff
Attachments on
bug 137374
: 62179 |
62425