Changeset 619 for trunk/kernel/devices
- Timestamp:
- Feb 12, 2019, 1:15:47 PM (6 years ago)
- Location:
- trunk/kernel/devices
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/kernel/devices/dev_dma.c
r565 r619 63 63 error = thread_kernel_create( &new_thread, 64 64 THREAD_DEV, 65 &chdev_se quencial_server,65 &chdev_server_func, 66 66 dma, 67 67 cluster_select_local_core() ); -
trunk/kernel/devices/dev_ioc.c
r614 r619 71 71 error = thread_kernel_create( &new_thread, 72 72 THREAD_DEV, 73 &chdev_se quencial_server,73 &chdev_server_func, 74 74 ioc, 75 75 lid ); -
trunk/kernel/devices/dev_nic.c
r565 r619 70 70 error = thread_kernel_create( &new_thread, 71 71 THREAD_DEV, 72 &chdev_se quencial_server,72 &chdev_server_func, 73 73 nic, 74 74 lid ); -
trunk/kernel/devices/dev_txt.c
r565 r619 53 53 const char * dev_txt_type_str( dev_txt_cmd_t type ) 54 54 { 55 switch (type) { 56 case (TXT_SYNC_WRITE): return "TXT_SYNC_WRITE"; 57 case (TXT_READ): return "TXT_READ"; 58 case (TXT_WRITE): return "TXT_WRITE"; 59 default: return "undefined"; 60 } 55 switch (type) 56 { 57 case (TXT_SYNC_WRITE): return "TXT_SYNC_WRITE"; 58 case (TXT_READ): return "TXT_READ"; 59 case (TXT_WRITE): return "TXT_WRITE"; 60 default: return "undefined"; 61 } 61 62 } 62 63 … … 115 116 error = thread_kernel_create( &new_thread, 116 117 THREAD_DEV, 117 &chdev_se quencial_server,118 &chdev_server_func, 118 119 txt, 119 120 lid ); … … 178 179 179 180 #if DEBUG_DEV_TXT_TX 180 uint32_t cycle = (uint32_t)hal_get_cycles(); 181 thread_t * this = CURRENT_THREAD; 182 uint32_t cycle = (uint32_t)hal_get_cycles(); 181 183 if( DEBUG_DEV_TXT_TX < cycle ) 182 printk("\n[DBG] %s : thread %x enters / cycle %d\n", __FUNCTION__, CURRENT_THREAD, cycle ); 184 printk("\n[%s] thread[%x,%x] enters / cycle %d\n", 185 __FUNCTION__, this->process->pid, this->trdid, cycle ); 183 186 #endif 184 187 … … 194 197 195 198 // If we use MTTYs (vci_multi_tty), we perform only sync writes 199 // Otherwise, we use vci_tty_tsar so we can use async writes 200 196 201 if( dev_ptr->impl == IMPL_TXT_MTY ) 197 202 { … … 212 217 } 213 218 214 // Otherwise, we use vci_tty_tsar so we can use async writes215 219 else 216 220 { 217 return dev_txt_access( TXT_WRITE , channel , buffer , count );221 return dev_txt_access( TXT_WRITE , channel , buffer , count ); 218 222 } 219 223 … … 221 225 cycle = (uint32_t)hal_get_cycles(); 222 226 if( DEBUG_DEV_TXT_TX < cycle ) 223 printk("\n[DBG] %s : thread %x exit / cycle %d\n", __FUNCTION__, CURRENT_THREAD, cycle ); 227 printk("\n[%s] thread[%x,%x] exit / cycle %d\n", 228 __FUNCTION__, this->process->pid, this->trdid, cycle ); 224 229 #endif 225 230 … … 240 245 241 246 #if DEBUG_DEV_TXT_RX 242 uint32_t cycle = (uint32_t)hal_get_cycles(); 247 thread_t * this = CURRENT_THREAD; 248 uint32_t cycle = (uint32_t)hal_get_cycles(); 243 249 if( DEBUG_DEV_TXT_RX < cycle ) 244 printk("\n[DBG] %s : thread %x enters / cycle %d\n", __FUNCTION__, CURRENT_THREAD, cycle ); 250 printk("\n[%s] thread[%x,%x] enters / cycle %d\n", 251 __FUNCTION__, this->process->pid, this->trdid, cycle ); 245 252 #endif 246 253 … … 250 257 cycle = (uint32_t)hal_get_cycles(); 251 258 if( DEBUG_DEV_TXT_RX < cycle ) 252 printk("\n[DBG] %s : thread %x exit / cycle %d\n", __FUNCTION__, CURRENT_THREAD, cycle ); 259 printk("\n[%s] thread[%x,%x] exit / cycle %d\n", 260 __FUNCTION__, this->process->pid, this->trdid, cycle ); 253 261 #endif 254 262
Note: See TracChangeset
for help on using the changeset viewer.