Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 23 Jan 1996 14:53:52 -0600
From:      Jim Lowe <james@miller.cs.uwm.edu>
To:        terry@lambert.org
Cc:        dufault@hda.com, hackers@FreeBSD.org, hasty@rah.star-gate.com, jkh@time.cdrom.com, luigi@labinfo.iet.unipi.it, multimedia@rah.star-gate.com
Subject:   Re: Amancio's tv program with capture!
Message-ID:  <199601232053.OAA14413@miller.cs.uwm.edu>

next in thread | raw e-mail | index | archive | help
> > How does one mark the driver/mmapped memory as shared memory
> > with the current utilities? It isn't real obvious that one can
> > actually do this without modifiying the shmat system call (or at
> > least to me).
> 
> 
> 	int	fd;
> 	caddr_t	mapaddr;
> 
> 	if( ( fd = open( DEV_NAME, O_RDWR)) == -1) {
> 		perror( "open");
> 		exit( 1);
> 	}
> 
> 	mapaddr =  mmap( 0,			/* map here, 0 = don't care*/
> 			 DEV_MEM_SIZE,		/* device memory window*/
> 			 PROT_READ|PROT_WRITE,	/* will be reading/writing*/
> 			 MAP_HASSEMAPHORE, 	/* (?) prevent caching*/
> 			 fd,			/* fd for device*/
> 			 (off_t)0		/* full window*/
> 			);
> 

I know how to mmap.  The question is once you have mapaddr how does
one attach that to X's shared memory functions through the Xshm 
utilities?  I don't beleive I have ever head of map_hassemaphore...

	-Jim



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