Re: sem_open

2013-10-25 Thread Vadim Zhukov
> This may or may not be a working implementation of sem_open. This is a bit improved version of Ted's diff: * Add support of shared=1 for sem_init() * Less memory leaks in error paths * More strong checks where applicable This is RFC/FYI status only, still under testing. -- zhuk@ Index:

Re: sem_open

2013-10-25 Thread Vadim Zhukov
2013/10/26 Ted Unangst : > This may or may not be a working implementation of sem_open. > > Using tricks similar to those used in shm_open, we create a semaphore > in a tmp file shared by mmap. This lets other processes share the > spinlock and counter. Our thrsleep and thrwakeup syscalls don't rea

Re: sem_open

2013-10-25 Thread Theo de Raadt
> On Sat, Oct 26, 2013 at 00:54, Vadim Zhukov wrote: > >> +/* SHA256_DIGEST_STRING_LENGTH includes nul */ > >> +/* "/tmp/" + sha256 + ".sem" */ > > > > Shouldn't this respect the TMPDIR envvar? > > No, it's an internal artifact of the implementation. And furthermore, making additional library fu

Re: sem_open

2013-10-25 Thread Ted Unangst
On Sat, Oct 26, 2013 at 00:54, Vadim Zhukov wrote: >> +/* SHA256_DIGEST_STRING_LENGTH includes nul */ >> +/* "/tmp/" + sha256 + ".sem" */ > > Shouldn't this respect the TMPDIR envvar? No, it's an internal artifact of the implementation.

Re: sem_open

2013-10-25 Thread Vadim Zhukov
2013/10/26 Ted Unangst : > This may or may not be a working implementation of sem_open. > > Using tricks similar to those used in shm_open, we create a semaphore > in a tmp file shared by mmap. This lets other processes share the > spinlock and counter. Our thrsleep and thrwakeup syscalls don't rea

sem_open

2013-10-25 Thread Ted Unangst
This may or may not be a working implementation of sem_open. Using tricks similar to those used in shm_open, we create a semaphore in a tmp file shared by mmap. This lets other processes share the spinlock and counter. Our thrsleep and thrwakeup syscalls don't really work between processes, so we

Genesys Logic GL620USB-A, USB PC-to-PC link cable

2013-10-25 Thread SASANO Takayoshi
Hello, I wrote a driver for Genesys Logic's GL620USB-A to test my USB PC-to-PC link cable. This controller is old (USB 1.1 age!) but GL620USB-A based link cable is still sold at eBay. To support GL620USB-A, I modified sys/dev/usb/if_upl.c (Prolific PL-2301/2302 driver) and added some stuffs. Thes

Re: Stairstep mouse motion

2013-10-25 Thread Edd Barrett
On Thu, Oct 24, 2013 at 10:33:22PM +0300, Henri Kemppainen wrote: > What happens when priv->swap_axes is set, and the ax && ay branch is > taken along with the wsWheelEmuFilterMotion() branch. Following > continue another event is processed and now the axes are swapped again > (ax and ay were not