Changeset 625 for trunk/kernel/kern/rpc.c
- Timestamp:
- Apr 10, 2019, 10:09:39 AM (5 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/kernel/kern/rpc.c
r624 r625 24 24 #include <kernel_config.h> 25 25 #include <hal_kernel_types.h> 26 #include <hal_vmm.h> 26 27 #include <hal_atomic.h> 27 28 #include <hal_remote.h> … … 52 53 &rpc_pmem_get_pages_server, // 0 53 54 &rpc_pmem_release_pages_server, // 1 54 &rpc_ undefined, // 2 unused slot55 &rpc_ppm_display_server, // 2 55 56 &rpc_process_make_fork_server, // 3 56 57 &rpc_user_dir_create_server, // 4 … … 81 82 &rpc_vmm_create_vseg_server, // 27 82 83 &rpc_vmm_set_cow_server, // 28 83 &rpc_hal_vmm_display_server, 84 &rpc_hal_vmm_display_server, // 29 84 85 }; 85 86 … … 88 89 "PMEM_GET_PAGES", // 0 89 90 "PMEM_RELEASE_PAGES", // 1 90 " undefined",// 291 "PPM_DISPLAY", // 2 91 92 "PROCESS_MAKE_FORK", // 3 92 93 "USER_DIR_CREATE", // 4 … … 566 567 567 568 ///////////////////////////////////////////////////////////////////////////////////////// 568 // [2] undefined slot 569 ///////////////////////////////////////////////////////////////////////////////////////// 569 // [2] Marshaling functions attached to RPC_PPM_DISPLAY 570 ///////////////////////////////////////////////////////////////////////////////////////// 571 572 ///////////////////////////////////////// 573 void rpc_ppm_display_client( cxy_t cxy ) 574 { 575 #if DEBUG_RPC_PPM_DISPLAY 576 thread_t * this = CURRENT_THREAD; 577 uint32_t cycle = (uint32_t)hal_get_cycles(); 578 if( cycle > DEBUG_RPC_PPM_DISPLAY ) 579 printk("\n[%s] thread[%x,%x] on core %d enter / cycle %d\n", 580 __FUNCTION__, this->process->pid, this->trdid, this->core->lid , cycle ); 581 #endif 582 583 uint32_t responses = 1; 584 585 // initialise RPC descriptor header 586 rpc_desc_t rpc; 587 rpc.index = RPC_PPM_DISPLAY; 588 rpc.blocking = true; 589 rpc.rsp = &responses; 590 591 // register RPC request in remote RPC fifo 592 rpc_send( cxy , &rpc ); 593 594 #if DEBUG_RPC_PPM_DISPLAY 595 cycle = (uint32_t)hal_get_cycles(); 596 if( cycle > DEBUG_RPC_PPM_DISPLAY ) 597 printk("\n[%s] thread[%x,%x] on core %d exit / cycle %d\n", 598 __FUNCTION__, this->process->pid, this->trdid, this->core->lid, cycle ); 599 #endif 600 } 601 602 //////////////////////////////////////////////////////////////////// 603 void rpc_ppm_display_server( xptr_t __attribute__((__unused__)) xp ) 604 { 605 #if DEBUG_RPC_PPM_DISPLAY 606 thread_t * this = CURRENT_THREAD; 607 uint32_t cycle = (uint32_t)hal_get_cycles(); 608 if( cycle > DEBUG_RPC_PPM_DISPLAY ) 609 printk("\n[%s] thread[%x,%x] on core %d enter / cycle %d\n", 610 __FUNCTION__, this->process->pid, this->trdid, this->core->lid , cycle ); 611 #endif 612 613 // call local kernel function 614 ppm_display(); 615 616 #if DEBUG_RPC_PPM_DISPLAY 617 cycle = (uint32_t)hal_get_cycles(); 618 if( cycle > DEBUG_RPC_PPM_DISPLAY ) 619 printk("\n[%s] thread[%x,%x] on core %d exit / cycle %d\n", 620 __FUNCTION__, this->process->pid, this->trdid, this->core->lid, cycle ); 621 #endif 622 } 570 623 571 624 /////////////////////////////////////////////////////////////////////////////////////////
Note: See TracChangeset
for help on using the changeset viewer.