Changeset 50 for trunk/kernel/kern/cluster.c
- Timestamp:
- Jun 26, 2017, 3:15:11 PM (7 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/kernel/kern/cluster.c
r23 r50 28 28 #include <hal_atomic.h> 29 29 #include <hal_special.h> 30 #include <hal_ppm.h> 30 31 #include <printk.h> 31 32 #include <errno.h> … … 43 44 #include <dqdt.h> 44 45 45 // TODO #include <sysfs.h>46 47 46 /////////////////////////////////////////////////////////////////////////////////////////// 48 47 // Extern global variables … … 62 61 error_t cluster_init( struct boot_info_s * info ) 63 62 { 63 error_t error; 64 64 lpid_t lpid; // local process_index 65 65 lid_t lid; // local core index … … 82 82 spinlock_init( &cluster->kcm_lock ); 83 83 84 cluster_dmsg("\n[INFO] %s for cluster %x enters\n", 85 __FUNCTION__ , local_cxy ); 86 84 87 // initialises DQDT 85 88 cluster->dqdt_root_level = dqdt_init( info->x_size, … … 90 93 91 94 // initialises embedded PPM 92 ppm_init( &cluster->ppm, 93 info->pages_nr, 94 info->pages_offset ); 95 error = hal_ppm_init( info ); 96 97 if( error ) 98 { 99 printk("\n[ERROR] in %s : cannot initialize PPM in cluster %x\n", 100 __FUNCTION__ , local_cxy ); 101 return ENOMEM; 102 } 103 104 cluster_dmsg("\n[INFO] %s : PPM initialized in cluster %x at cycle %d\n", 105 __FUNCTION__ , local_cxy , hal_time_stamp() ); 95 106 96 107 // initialises embedded KHM 97 108 khm_init( &cluster->khm ); 98 109 110 cluster_dmsg("\n[INFO] %s : KHM initialized in cluster %x at cycle %d\n", 111 __FUNCTION__ , local_cxy , hal_time_stamp() ); 112 99 113 // initialises embedded KCM 100 114 kcm_init( &cluster->kcm , KMEM_KCM ); 115 116 cluster_dmsg("\n[INFO] %s : KCM initialized in cluster %x at cycle %d\n", 117 __FUNCTION__ , local_cxy , hal_time_stamp() ); 101 118 102 119 // initialises all cores descriptors … … 108 125 } 109 126 127 cluster_dmsg("\n[INFO] %s : cores initialized in cluster %x at cycle %d\n", 128 __FUNCTION__ , local_cxy , hal_time_stamp() ); 129 110 130 // initialises RPC fifo 111 131 rpc_fifo_init( &cluster->rpc_fifo ); 132 133 cluster_dmsg("\n[INFO] %s : RPC fifo inialized in cluster %x at cycle %d\n", 134 __FUNCTION__ , local_cxy , hal_time_stamp() ); 112 135 113 136 // initialise pref_tbl[] in process manager … … 132 155 xlist_root_init( XPTR( local_cxy , &cluster->pmgr.copies_root[lpid] ) ); 133 156 } 157 158 cluster_dmsg("\n[INFO] %s Process Manager initialized in cluster %x at cycle %d\n", 159 __FUNCTION__ , local_cxy , hal_time_stamp() ); 134 160 135 161 hal_wbflush();
Note: See TracChangeset
for help on using the changeset viewer.