X-Git-Url: https://scm.lunaixsky.com/lunaix-os.git/blobdiff_plain/8fce4520de1f257819b16f9253fa28dcdae743f4..7b8a1bcad75628f9add4590db2bb9b8e418ee8eb:/lunaix-os/kernel/tty/lxconsole.c diff --git a/lunaix-os/kernel/tty/lxconsole.c b/lunaix-os/kernel/tty/lxconsole.c index 46f4dd2..cf2d43c 100644 --- a/lunaix-os/kernel/tty/lxconsole.c +++ b/lunaix-os/kernel/tty/lxconsole.c @@ -343,7 +343,7 @@ console_start_flushing() static int lxconsole_spawn_ttydev(struct device_def* devdef) { - struct device* tty_dev = device_addseq(NULL, &lx_console, "tty"); + struct device* tty_dev = device_allocseq(NULL, &lx_console); tty_dev->ops.write = __tty_write; tty_dev->ops.write_page = __tty_write_pg; tty_dev->ops.read = __tty_read; @@ -353,12 +353,15 @@ lxconsole_spawn_ttydev(struct device_def* devdef) waitq_init(&lx_reader); input_add_listener(__lxconsole_listener); + register_device(tty_dev, &devdef->class, "vcon"); + return 0; } static struct device_def lxconsole_def = { .name = "Lunaix Virtual Console", - .class = DEVCLASS(DEVIF_NON, DEVFN_TTY, DEV_BUILTIN, 0), + .class = DEVCLASSV(DEVIF_NON, DEVFN_TTY, DEV_BUILTIN, 12), .init = lxconsole_spawn_ttydev }; -EXPORT_DEVICE(lxconsole, &lxconsole_def, load_earlystage); \ No newline at end of file +// FIXME +EXPORT_DEVICE(lxconsole, &lxconsole_def, load_onboot); \ No newline at end of file