RPi SPI Driver initial commit
Merge pull request #2 from kinsamanka/hal_spi

Hal spi
rtapi: add rtapi_shmem_exists() acessor

just need to go through the rtapi_switch
shmdrv API: correct sign of return value on mmap() failure

this lead to mmap() fails going undetected.
shmdrv: IOC_SHM_ATTACH return full status of existing segment

in particular the size argument is important to make mmap() succeed
in shmdrv API:shmdrv_attach()
rtapi_shmem_getptr(): fail with -ENOENT if shm segment not mapped

The wholesale use of -EINVAL is not a good idea - no way to discern
causes.
rtapi_shmem_new_inst: return -EEXIST on mapping a shm segment again

This is a valid situation one should be able to test against.
kdetect: sync with syndrome used in rtapi_compat.c