Changeset 68 for trunk/kernel/kern/kernel_init.c
- Timestamp:
- Jun 27, 2017, 10:24:13 AM (6 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/kernel/kern/kernel_init.c
r50 r68 32 32 #include <core.h> 33 33 #include <list.h> 34 #include <xlist.h> 34 35 #include <thread.h> 35 36 #include <scheduler.h> … … 54 55 #include <soclib_tty.h> 55 56 #include <devfs.h> 57 #include <mapper.h> 56 58 57 59 … … 659 661 if( core_lid == 0 ) local_cxy = info->cxy; 660 662 663 // each core get pointer on its private idle thread descriptor 664 thread = (thread_t *)( idle_threads + (core_lid * CONFIG_THREAD_DESC_SIZE) ); 665 666 // each core register this thread pointer in hardware register 667 hal_set_current_thread( thread ); 668 661 669 // CP0 in I/O cluster initialises TXT0 chdev descriptor 662 670 if( (core_lid == 0) && (core_cxy == info->io_cxy) ) txt0_device_init( info ); … … 755 763 __FUNCTION__ , core_cxy , core_lid , hal_time_stamp() ); 756 764 757 // all cores initialize the private idle thread descriptor758 thread = (thread_t *)( idle_threads + (core_lid * CONFIG_THREAD_DESC_SIZE) );759 765 760 766 error = thread_kernel_init( thread, … … 763 769 NULL, 764 770 core_lid ); 765 766 771 if( error ) 767 772 { … … 775 780 core->scheduler.idle = thread; 776 781 777 // register idle thread pointer in core register778 hal_set_current_thread( thread );779 780 782 // activate the idle thread 781 783 thread_unblock( XPTR( local_cxy , thread ) , THREAD_BLOCKED_GLOBAL ); … … 816 818 { 817 819 print_banner( (info->x_size * info->y_size) , info->cores_nr ); 820 821 kinit_dmsg("\n\n*** memory fooprint of main kernet objects ***\n" 822 " - thread descriptor : %d bytes\n" 823 " - process descriptor : %d bytes\n" 824 " - cluster manager : %d bytes\n" 825 " - chdev descriptor : %d bytes\n" 826 " - core descriptor : %d bytes\n" 827 " - scheduler : %d bytes\n" 828 " - rpc fifo : %d bytes\n" 829 " - page descriptor : %d bytes\n" 830 " - mapper root : %d bytes\n" 831 " - ppm manager : %d bytes\n" 832 " - kcm manager : %d bytes\n" 833 " - khm manager : %d bytes\n" 834 " - vmm manager : %d bytes\n" 835 " - gpt root : %d bytes\n" 836 " - list item : %d bytes\n" 837 " - xlist item : %d bytes\n" 838 " - spinlock : %d bytes\n" 839 " - remote spinlock : %d bytes\n" 840 " - rwlock : %d bytes\n" 841 " - remote rwlock : %d bytes\n", 842 sizeof( thread_t ), 843 sizeof( process_t ), 844 sizeof( cluster_t ), 845 sizeof( chdev_t ), 846 sizeof( core_t ), 847 sizeof( scheduler_t ), 848 sizeof( rpc_fifo_t ), 849 sizeof( page_t ), 850 sizeof( mapper_t ), 851 sizeof( ppm_t ), 852 sizeof( kcm_t ), 853 sizeof( khm_t ), 854 sizeof( vmm_t ), 855 sizeof( gpt_t ), 856 sizeof( list_entry_t ), 857 sizeof( xlist_entry_t ), 858 sizeof( spinlock_t ), 859 sizeof( remote_spinlock_t ), 860 sizeof( rwlock_t ), 861 sizeof( remote_rwlock_t )); 818 862 } 819 863
Note: See TracChangeset
for help on using the changeset viewer.