ENOENT is not a valid error return from an ioctl. Never has been, never will be. ENOENT means “No such file and directory”, and is for path operations. ioctl’s are done on files that have already been opened, there’s no way in hell that ENOENT would ever be valid.