Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 25 Oct 1997 07:30:01 -0700 (PDT)
From:      KATO Takenori <kato@migmatite.eps.nagoya-u.ac.jp>
To:        freebsd-bugs
Subject:   Re: kern/4355: Executor does not work with sound configured into kernel, must use 'nosound' (other sound apps work) 
Message-ID:  <199710251430.HAA05066@hub.freebsd.org>

next in thread | raw e-mail | index | archive | help
The following reply was made to PR kern/4355; it has been noted by GNATS.

From: KATO Takenori <kato@migmatite.eps.nagoya-u.ac.jp>
To: freebsd-gnats-submit@freebsd.org, dburr@donaldburr.dyn.ml.org
Cc:  Subject: Re: kern/4355: Executor does not work with sound configured into kernel,
	 must use 'nosound' (other sound apps work) 
Date: Sat, 25 Oct 1997 23:19:26 +0900

 > Executor crashes and burns when FreeBSD sound support is compiled in,
 > unless you use the -nosound flag.  Other Linux binaries that use sound
 > (e.g. MAME arcade machine emulator, etc.) work fine.
 > 
 > Errors that appear on the terminal:
 > linux-sound.c:339; fatal error in `sound_linux_init': Couldn't get semaphore
 > Segmentation fault
 
 Executor cannot get SysV semaphore because linux_semget is not
 implemented.  Patch included adds SysV semaphore support in linux
 emulator, and executor works without -nosound option.  But, sound
 stuff of executor doesn't work because `clone' systemcall is not
 implemented.
 
 ---------- BEGIN ----------
 *** linux_ipc.c.ORIG	Sat Oct 25 23:18:43 1997
 --- linux_ipc.c	Sat Oct 25 22:20:00 1997
 ***************
 *** 130,148 ****
   static int
   linux_semop(struct proc *p, struct linux_ipc_args *args, int *retval)
   {
 !     return ENOSYS;
   }
   
   static int
   linux_semget(struct proc *p, struct linux_ipc_args *args, int *retval)
   {
 !     return ENOSYS;
   }
   
   static int
   linux_semctl(struct proc *p, struct linux_ipc_args *args, int *retval)
   {
 !     return ENOSYS;
   }
   
   static int
 --- 130,180 ----
   static int
   linux_semop(struct proc *p, struct linux_ipc_args *args, int *retval)
   {
 ! 	struct semop_args /* {
 ! 	int	semid;
 ! 	struct	sembuf *sops;
 ! 	int		nsops;
 ! 	} */ bsd_args;
 ! 
 ! 	bsd_args.semid = args->arg1;
 ! 	bsd_args.sops = (struct sembuf *)args->ptr;
 ! 	bsd_args.nsops = args->arg2;
 ! 	return semop(p, &bsd_args, retval);
   }
   
   static int
   linux_semget(struct proc *p, struct linux_ipc_args *args, int *retval)
   {
 ! 	struct semget_args /* {
 ! 	key_t	key;
 ! 	int		nsems;
 ! 	int		semflg;
 ! 	} */ bsd_args;
 ! 
 ! 	bsd_args.key = args->arg1;
 ! 	bsd_args.nsems = args->arg2;
 ! 	bsd_args.semflg = args->arg3;
 ! 	return semget(p, &bsd_args, retval);
   }
   
   static int
   linux_semctl(struct proc *p, struct linux_ipc_args *args, int *retval)
   {
 ! 	struct __semctl_args /* {
 ! 	int		semid;
 ! 	int		semnum;
 ! 	int		cmd;
 ! 	union	semun *arg;
 ! 	} */ bsd_args;
 ! 	int	error;
 ! 
 ! 	bsd_args.semid = args->arg1;
 ! 	bsd_args.semnum = args->arg2;
 ! 	bsd_args.cmd = args->arg3;
 ! 	error = copyin(args->ptr, (caddr_t)bsd_args.arg, sizeof(bsd_args.arg));
 ! 	if (error)
 ! 		return error;
 ! 	return __semctl(p, &bsd_args, retval);
   }
   
   static int
 ---------- END ----------
 
 
 ----
 KATO Takenori <kato@ganko.eps.nagoya-u.ac.jp>
 Dept. Earth Planet. Sci., Nagoya Univ.,  Nagoya, 464-01, Japan
 PGP public key: finger kato@eclogite.eps.nagoya-u.ac.jp
 ------------------- Powered by FreeBSD(98) -------------------



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199710251430.HAA05066>