[plug] strange happenings - advice needed

Jason Nicholls jason at mindsocket.com.au
Fri Dec 1 09:33:05 WST 2000


G'day,

On Fri, Dec 01, 2000 at 08:47:08AM +0800, Anthony J. Breeds-Taurima wrote:
> IIRC correctly there are issues with Xfree 4.X and the Nvidia kernel module.
> I don't have the details at hand but if you setup matches then that may
> explain it.

My config is XFree86 3.3.6-20 (RH 6.2 package), Mesa 3.2.1 (src), and glx
2000-09-20 (cvs source). My vid card is a Matrox G400 16Mb (dual head).

> Also maybe you could do someting like:
> alias XM='strace -V -FF -o /tmp/xmame.strace xmame'
> then use XM to start xmame ... when it seg faults look for a reason.

I did a trace on X and quake3 and pretty much the same thing appeared:

4720  open("/usr/X11R6/lib/modules/glx.so", O_RDONLY) = 19
4720  fstat(19, {st_mode=S_IFREG|0755, st_size=2976660, ...}) = 0
4720  read(19, "\177ELF\1\1\1\0\0\0\0\0\0\0\0\0\3\0\3\0\1\0\0\0\200I\3"...,
4096) = 4096
4720  mmap(0, 3032460, PROT_READ|PROT_EXEC, MAP_PRIVATE, 19, 0) = 0x48c59000
4720  mprotect(0x48f18000, 152972, PROT_NONE) = 0
4720  mmap(0x48f18000, 86016, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED, 19,
0x2be000) = 0x48f18000
4720  mmap(0x48f2d000, 66956, PROT_READ|PROT_WRITE,
MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0x48f2d000
4720  close(19)                         = 0
4720  mprotect(0x48c59000, 2879488, PROT_READ|PROT_WRITE) = 0
4720  --- SIGSEGV (Segmentation fault) ---
4720  fstat(1, {st_mode=S_IFCHR|0620, st_rdev=makedev(136, 6), ...}) = 0
4720  mmap(0, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) =
0x48bed000
4720  ioctl(1, TCGETS, {B38400 opost isig icanon echo ...}) = 0
4720  write(1, "Received signal 11, exiting...\n", 31) = 31
4720  _exit(1)                          = ?


ie: open glx.so, do an mprotect, sigsegv and exit. The mprotect call seems to
work (man page)

	On success, mprotect returns zero. On error, -1 is
	returned, and errno is set appropriately.

On the other hand the man page also says:

	mprotect controls how a section of memory may be accessed.
	If an access is disallowed by the protection given it, the
	program receives a SIGSEGV.

So I don't actually know what is causing the SIGSEGV.



Later,

Jason Nicholls
--------------------------------------------------------------------
Jason Nicholls    icq: 11745841    email: <jason at mindsocket.com.au>
Proprietor                        mobile: 0417 410 811
Mind Socket [web services]          http://www.mindsocket.com.au/
--------------------------------------------------------------------



More information about the plug mailing list