ioctl fixes, fix netbsd ifup, ifdown