[637df35] | 1 | /* |
---|
| 2 | * Console IO Support Routines |
---|
| 3 | * |
---|
| 4 | * These provide UNIX-like read and write calls for the C library. |
---|
| 5 | * |
---|
[3a4ae6c] | 6 | * NOTE: For the most part, this is just a space holder. |
---|
| 7 | * |
---|
[637df35] | 8 | * COPYRIGHT (c) 1994 by Division Incorporated |
---|
| 9 | * |
---|
[98e4ebf5] | 10 | * The license and distribution terms for this file may be |
---|
| 11 | * found in the file LICENSE in this distribution or at |
---|
[e71ce071] | 12 | * http://www.OARcorp.com/rtems/license.html. |
---|
[637df35] | 13 | * |
---|
| 14 | * $Id$ |
---|
| 15 | */ |
---|
| 16 | |
---|
| 17 | #include <bsp.h> |
---|
| 18 | |
---|
| 19 | #include <unistd.h> |
---|
| 20 | #include <errno.h> |
---|
| 21 | |
---|
| 22 | rtems_device_driver |
---|
| 23 | console_initialize(rtems_device_major_number major, |
---|
| 24 | rtems_device_minor_number minor, |
---|
[b06e68ef] | 25 | void * arg |
---|
| 26 | ) |
---|
[637df35] | 27 | { |
---|
[3a4ae6c] | 28 | return 0; |
---|
| 29 | } |
---|
| 30 | |
---|
| 31 | |
---|
| 32 | /* |
---|
| 33 | * Open entry point |
---|
| 34 | */ |
---|
| 35 | |
---|
| 36 | rtems_device_driver console_open( |
---|
| 37 | rtems_device_major_number major, |
---|
| 38 | rtems_device_minor_number minor, |
---|
| 39 | void * arg |
---|
| 40 | ) |
---|
| 41 | { |
---|
| 42 | return RTEMS_SUCCESSFUL; |
---|
[637df35] | 43 | } |
---|
[3a4ae6c] | 44 | |
---|
| 45 | /* |
---|
| 46 | * Close entry point |
---|
| 47 | */ |
---|
| 48 | |
---|
| 49 | rtems_device_driver console_close( |
---|
| 50 | rtems_device_major_number major, |
---|
| 51 | rtems_device_minor_number minor, |
---|
| 52 | void * arg |
---|
| 53 | ) |
---|
| 54 | { |
---|
| 55 | return RTEMS_SUCCESSFUL; |
---|
| 56 | } |
---|
| 57 | |
---|
| 58 | /* |
---|
| 59 | * read bytes from the serial port. We only have stdin. |
---|
| 60 | */ |
---|
[637df35] | 61 | |
---|
[3a4ae6c] | 62 | rtems_device_driver console_read( |
---|
| 63 | rtems_device_major_number major, |
---|
| 64 | rtems_device_minor_number minor, |
---|
| 65 | void * arg |
---|
| 66 | ) |
---|
| 67 | { |
---|
| 68 | return RTEMS_UNSATISFIED; |
---|
| 69 | } |
---|
| 70 | |
---|
| 71 | /* |
---|
| 72 | * write bytes to the serial port. Stdout and stderr are the same. |
---|
| 73 | */ |
---|
| 74 | |
---|
| 75 | rtems_device_driver console_write( |
---|
| 76 | rtems_device_major_number major, |
---|
| 77 | rtems_device_minor_number minor, |
---|
| 78 | void * arg |
---|
| 79 | ) |
---|
| 80 | { |
---|
| 81 | return -1; |
---|
| 82 | } |
---|
| 83 | |
---|
| 84 | /* |
---|
| 85 | * IO Control entry point |
---|
| 86 | */ |
---|
| 87 | |
---|
| 88 | rtems_device_driver console_control( |
---|
| 89 | rtems_device_major_number major, |
---|
| 90 | rtems_device_minor_number minor, |
---|
| 91 | void * arg |
---|
| 92 | ) |
---|
| 93 | { |
---|
| 94 | return RTEMS_SUCCESSFUL; |
---|
| 95 | } |
---|