diff options
author | Hinko Kocevar <hinko.kocevar@cetrtapot.si> | 2008-06-06 08:12:26 -0400 |
---|---|---|
committer | Jesper Nilsson <jesper@jni.nu> | 2008-06-29 16:48:14 -0400 |
commit | 3aa30df3d0d78f568cff9d6a98ae01ae55494f10 (patch) | |
tree | 25d4edead5dafb03697cc088202bd72d325cba22 /arch/cris | |
parent | 543cf4cb3fe6f6cae3651ba918b9c56200b257d0 (diff) |
cris: compile fixes for 2.6.26-rc5
Add dummy ops for serial debug port.
Add setting of c_ispeed/c_ospeed as suggested by Alan Cox.
Signed-off-by: Hinko Kocevar <hinko.kocevar@cetrtapot.si>
Acked-by: Alan Cox <alan@redhat.com>
Signed-off-by: Jesper Nilsson <jesper.nilsson@axis.com>
Diffstat (limited to 'arch/cris')
-rw-r--r-- | arch/cris/arch-v10/kernel/debugport.c | 20 |
1 files changed, 13 insertions, 7 deletions
diff --git a/arch/cris/arch-v10/kernel/debugport.c b/arch/cris/arch-v10/kernel/debugport.c index 04d5eee2c90c..162730eb887b 100644 --- a/arch/cris/arch-v10/kernel/debugport.c +++ b/arch/cris/arch-v10/kernel/debugport.c | |||
@@ -426,12 +426,18 @@ static int dummy_write(struct tty_struct * tty, | |||
426 | return count; | 426 | return count; |
427 | } | 427 | } |
428 | 428 | ||
429 | static int | 429 | static int dummy_write_room(struct tty_struct *tty) |
430 | dummy_write_room(struct tty_struct *tty) | ||
431 | { | 430 | { |
432 | return 8192; | 431 | return 8192; |
433 | } | 432 | } |
434 | 433 | ||
434 | static const struct tty_operations dummy_ops = { | ||
435 | .open = dummy_open, | ||
436 | .close = dummy_close, | ||
437 | .write = dummy_write, | ||
438 | .write_room = dummy_write_room, | ||
439 | }; | ||
440 | |||
435 | void __init | 441 | void __init |
436 | init_dummy_console(void) | 442 | init_dummy_console(void) |
437 | { | 443 | { |
@@ -444,14 +450,14 @@ init_dummy_console(void) | |||
444 | dummy_driver.type = TTY_DRIVER_TYPE_SERIAL; | 450 | dummy_driver.type = TTY_DRIVER_TYPE_SERIAL; |
445 | dummy_driver.subtype = SERIAL_TYPE_NORMAL; | 451 | dummy_driver.subtype = SERIAL_TYPE_NORMAL; |
446 | dummy_driver.init_termios = tty_std_termios; | 452 | dummy_driver.init_termios = tty_std_termios; |
453 | /* Normally B9600 default... */ | ||
447 | dummy_driver.init_termios.c_cflag = | 454 | dummy_driver.init_termios.c_cflag = |
448 | B115200 | CS8 | CREAD | HUPCL | CLOCAL; /* is normally B9600 default... */ | 455 | B115200 | CS8 | CREAD | HUPCL | CLOCAL; |
449 | dummy_driver.flags = TTY_DRIVER_REAL_RAW | TTY_DRIVER_DYNAMIC_DEV; | 456 | dummy_driver.flags = TTY_DRIVER_REAL_RAW | TTY_DRIVER_DYNAMIC_DEV; |
457 | dummy_driver.init_termios.c_ispeed = 115200; | ||
458 | dummy_driver.init_termios.c_ospeed = 115200; | ||
450 | 459 | ||
451 | dummy_driver.open = dummy_open; | 460 | dummy_driver.ops = &dummy_ops; |
452 | dummy_driver.close = dummy_close; | ||
453 | dummy_driver.write = dummy_write; | ||
454 | dummy_driver.write_room = dummy_write_room; | ||
455 | if (tty_register_driver(&dummy_driver)) | 461 | if (tty_register_driver(&dummy_driver)) |
456 | panic("Couldn't register dummy serial driver\n"); | 462 | panic("Couldn't register dummy serial driver\n"); |
457 | } | 463 | } |