sound: fix check for error condition of register_chrdev()