Changeset 9700578 in rtems for c/src/lib/libbsp/unix/posix
- Timestamp:
- 10/30/95 21:54:45 (28 years ago)
- Branches:
- 4.10, 4.11, 4.8, 4.9, 5, master
- Children:
- c4808ca
- Parents:
- ea74482
- Location:
- c/src/lib/libbsp/unix/posix
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
c/src/lib/libbsp/unix/posix/clock/clock.c
rea74482 r9700578 32 32 rtems_device_minor_number rtems_clock_minor; 33 33 34 void 35 Install_clock(rtems_isr_entry clock_isr) 34 void Install_clock(rtems_isr_entry clock_isr) 36 35 { 37 36 Clock_driver_ticks = 0; 38 37 39 (void) set_vector(clock_isr, Clock_driver_vector, 1);38 (void) set_vector( clock_isr, Clock_driver_vector, 1 ); 40 39 41 40 _CPU_Start_clock( BSP_Configuration.microseconds_per_tick ); … … 44 43 } 45 44 46 void 47 ReInstall_clock(rtems_isr_entry new_clock_isr) 48 { 49 rtems_unsigned32 isrlevel = 0; 50 51 rtems_interrupt_disable(isrlevel); 52 (void)set_vector(new_clock_isr, Clock_driver_vector, 1); 53 rtems_interrupt_enable(isrlevel); 54 } 55 56 void 57 Clock_isr(int vector) 45 void Clock_isr(int vector) 58 46 { 59 47 Clock_driver_ticks++; … … 66 54 */ 67 55 68 void 69 Clock_exit(void) 56 void Clock_exit(void) 70 57 { 71 58 _CPU_Stop_clock(); 72 59 73 (void) set_vector(0, Clock_driver_vector, 1);60 (void) set_vector( 0, Clock_driver_vector, 1 ); 74 61 } 75 62 76 rtems_device_driver 77 Clock_initialize( 63 rtems_device_driver Clock_initialize( 78 64 rtems_device_major_number major, 79 65 rtems_device_minor_number minor, … … 100 86 ) 101 87 { 88 rtems_unsigned32 isrlevel; 102 89 rtems_libio_ioctl_args_t *args = pargp; 103 90 … … 116 103 else if (args->command == rtems_build_name('N', 'E', 'W', ' ')) 117 104 { 118 ReInstall_clock(args->buffer); 105 rtems_interrupt_disable( isrlevel ); 106 (void) set_vector( args->buffer, Clock_driver_vector, 1 ); 107 rtems_interrupt_enable( isrlevel ); 119 108 } 120 109 -
c/src/lib/libbsp/unix/posix/startup/bspstart.c
rea74482 r9700578 183 183 #if 0 184 184 int stdin_fd, stdout_fd, stderr_fd; 185 int error_code; 186 187 error_code = 'S' << 24 | 'T' << 16; 185 188 186 189 if ((stdin_fd = __open("/dev/console", O_RDONLY, 0)) == -1) 187 rtems_fatal_error_occurred( 'STD0');190 rtems_fatal_error_occurred( error_code | 'D' << 8 | '0' ); 188 191 189 192 if ((stdout_fd = __open("/dev/console", O_WRONLY, 0)) == -1) 190 rtems_fatal_error_occurred( 'STD1');193 rtems_fatal_error_occurred( error_code | 'D' << 8 | '1' ); 191 194 192 195 if ((stderr_fd = __open("/dev/console", O_WRONLY, 0)) == -1) 193 rtems_fatal_error_occurred( 'STD2');196 rtems_fatal_error_occurred( error_code | 'D' << 8 | '2' ); 194 197 195 198 if ((stdin_fd != 0) || (stdout_fd != 1) || (stderr_fd != 2)) 196 rtems_fatal_error_occurred( 'STIO');199 rtems_fatal_error_occurred( error_code | 'I' << 8 | 'O' ); 197 200 #endif 198 201
Note: See TracChangeset
for help on using the changeset viewer.