add naive ioctl support