Implement shmem_create and shmem_lock