tty_register_driver: only allocate tty instances when defined