Changeset 396555aa in rtems
- Timestamp:
- 10/20/00 16:01:13 (23 years ago)
- Branches:
- 4.10, 4.11, 4.8, 4.9, 5, master
- Children:
- 6bb5260
- Parents:
- 772f2243
- Location:
- c/src/lib/libbsp/i386/pc386
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
c/src/lib/libbsp/i386/pc386/ChangeLog
r772f2243 r396555aa 1 2000-10-20 Rosimildo da Silva <rdasilva@connecttel.com> 2 3 * console/serial_mouse.c: Added support for changing serial parameters. 4 1 5 2000-10-20 Joel Sherrill <joel@OARcorp.com> 2 6 -
c/src/lib/libbsp/i386/pc386/console/serial_mouse.c
r772f2243 r396555aa 19 19 * 20 20 * $Log$ 21 * Revision 1.1 2000/08/30 08:15:30 joel22 * 2000-08-26 Rosimildo da Silva <rdasilva@connecttel.com>23 *24 * * Major rework of the "/dev/console" driver.25 * * Added termios support for stdin ( keyboard ).26 * * Added ioctls() to support modes similar to Linux( XLATE,27 * RAW, MEDIUMRAW ).28 * * Added Keyboard mapping and handling of the keyboard's leds.29 * * Added Micro FrameBuffer driver ( "/dev/fb0" ) for bare VGA30 * controller ( 16 colors ).31 * * Added PS/2 and Serial mouse support for PC386 BSP.32 * * console/defkeymap.c: New file.33 * * console/fb_vga.c: New file.34 * * console/fb_vga.h: New file.35 * * console/i386kbd.h: New file.36 * * console/kd.h: New file.37 * * console/keyboard.c: New file.38 * * console/keyboard.h: New file.39 * * console/mouse_parser.c: New file.40 * * console/mouse_parser.h: New file.41 * * console/pc_keyb.c: New file.42 * * console/ps2_drv.h: New file.43 * * console/ps2_mouse.c: New file.44 * * console/ps2_mouse.h: New file.45 * * console/serial_mouse.c: New file.46 * * console/serial_mouse.h: New file.47 * * console/vgainit.c: New file.48 * * console/vt.c: New file.49 * * console/Makefile.am: Reflect new files.50 * * console/console.c, console/inch.c, console/outch.c: Console51 * functionality modifications.52 * * startup/Makefile.am: Pick up tty_drv.c and gdb_glue.c53 *54 21 ****************************************************************************/ 55 22 … … 304 271 } 305 272 273 274 306 275 static int 307 276 conSetAttr(int port, int minor, const struct termios *t) 308 277 { 309 int baud;278 unsigned long baud, databits, parity, stopbits; 310 279 311 280 switch (t->c_cflag & CBAUD) … … 363 332 break; 364 333 default: 365 baud = 0;366 334 rtems_fatal_error_occurred (RTEMS_INTERNAL_ERROR); 367 335 return 0; 368 336 } 337 338 if (t->c_cflag & PARENB) { 339 /* Parity is enabled */ 340 if (t->c_cflag & PARODD) { 341 /* Parity is odd */ 342 parity = PEN; 343 } 344 else { 345 /* Parity is even */ 346 parity = PEN | EPS; 347 } 348 } 349 else { 350 /* No parity */ 351 parity = 0; 352 } 353 354 switch (t->c_cflag & CSIZE) { 355 case CS5: databits = CHR_5_BITS; break; 356 case CS6: databits = CHR_6_BITS; break; 357 case CS7: databits = CHR_7_BITS; break; 358 case CS8: databits = CHR_8_BITS; break; 359 } 360 361 if (t->c_cflag & CSTOPB) { 362 /* 2 stop bits */ 363 stopbits = STB; 364 } 365 else { 366 /* 1 stop bit */ 367 stopbits = 0; 368 } 369 369 printk("Mouse baud, port=%X, baud=%d\n", port, baud ); 370 BSP_uart_set_baud( port, baud ); 370 BSP_uart_set_attributes(port, baud, databits, parity, stopbits) 371 371 372 return 0; 372 } 373 373 374 374 375 /*
Note: See TracChangeset
for help on using the changeset viewer.