It should not panic, but instead fail the ioctl call. Why is the software you are using trying to set such tiny values? Does the real code at least initialize the encoding used? Your sample program does not do that. Martin