Changeset 2840
- Timestamp:
- Oct 29, 2006, 2:32:25 AM (19 years ago)
- Location:
- trunk/kLdr
- Files:
-
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/kLdr/kLdr.h
r2837 r2840 54 54 * @{ */ 55 55 56 /** 57 * Memory Mapping Protections. 58 * 59 * @remark Shared segments can be mapped using the non copy-on-write variant. 60 * (Normally the copy-on-write variant is used because changes must 61 * be private and not shared with other processes mapping the file.) 62 */ 56 63 typedef enum KLDRPROT 57 64 { -
trunk/kLdr/kLdrInternal.h
r2837 r2840 65 65 /** 66 66 * The state of a dynamic loader module. 67 * @image html KLDRSTATE.gif "The state diagram" 67 68 */ 68 69 typedef enum KLDRSTATE … … 70 71 /** The usual invalid 0 enum. */ 71 72 KLDRSTATE_INVALID = 0, 72 /** The module has just been opened and has no references. 73 74 /** The module has just been opened and linked into the load list. 75 * 73 76 * Prev state: - 74 * Next state: MAPPED, DESTROYED77 * Next state: MAPPED, PENDING_DESTROY 75 78 */ 76 79 KLDRSTATE_OPEN, 77 /** The module been mapped. 80 81 /** The module segments has been mapped into the process memory. 82 * 78 83 * Prev state: OPEN 79 * Next state: LOADED_PREREQUISITES, DESTROYED84 * Next state: LOADED_PREREQUISITES, PENDING_DESTROY 80 85 */ 81 86 KLDRSTATE_MAPPED, 82 87 /** The module has been reloaded and needs to be fixed up again. 83 * (The loader can still be in a re-entrant mode.) 88 * This can occure when the loader is called recursivly. 89 * 90 * The reason RELOADED modules must go back to the PENDING_GC state is 91 * because we want to guard against uninit order issues, and therefore 92 * doesn't unmap modules untill all pending termintation callbacks has 93 * been executed. 94 * 84 95 * Prev state: PENDING_GC 85 * Next state: LOADED_PREREQUISITES, PENDING_GC96 * Next state: RELOADED_LOADED_PREREQUISITES, PENDING_GC 86 97 */ 87 98 KLDRSTATE_RELOADED, 99 88 100 /** The immediate prerequisites have been loaded. 89 * Prev state: MAPPED, RELOADED 90 * Next state: FIXED_UP, DESTROYED 101 * 102 * Prev state: MAPPED 103 * Next state: FIXED_UP, PENDING_DESTROY 91 104 */ 92 105 KLDRSTATE_LOADED_PREREQUISITES, 106 /** The immediate prerequisites have been loaded for a reloaded module. 107 * 108 * Prev state: RELOADED 109 * Next state: RELOADED_FIXED_UP, PENDING_GC 110 */ 111 KLDRSTATE_RELOADED_LOADED_PREREQUISITES, 112 93 113 /** Fixups has been applied. 114 * 94 115 * Prev state: LOADED_PREREQUISITES 95 * Next state: PENDING_INIT , DESTROYED116 * Next state: PENDING_INITIALIZATION, PENDING_DESTROY 96 117 */ 97 118 KLDRSTATE_FIXED_UP, 119 /** Fixups has been applied. 120 * 121 * Prev state: RELOADED_LOADED_PREREQUISITES 122 * Next state: PENDING_INITIALIZATION, PENDING_GC 123 */ 124 KLDRSTATE_RELOADED_FIXED_UP, 125 98 126 /** Pending initialization. 99 * (The loader can now be in a re-entrant mode.) 100 * Prev state: FIXED_UP 101 * Next state: PENDING_INITIALIZATION, PENDING_GC 127 * While the module is in this state the loader is in reentrant mode. 128 * 129 * Prev state: FIXED_UP, RELOADED_FIXED_UP 130 * Next state: INITIALIZATION, PENDING_GC 102 131 */ 103 132 KLDRSTATE_PENDING_INITIALIZATION, 133 104 134 /** Initializing. 105 * (The loader is now in a re-entrant mode.) 135 * While the module is in this state the loader is in reentrant mode. 136 * 106 137 * Prev state: PENDING_INITIALIZATION 107 138 * Next state: GOOD, PENDING_GC 108 139 */ 109 140 KLDRSTATE_INITIALIZING, 141 142 /** Initialization failed. 143 * 144 * This is somewhat similar to PENDING_GC except that, a module 145 * in this state cannot be reloaded untill we've done GC. This ensures 146 * that a init failure during recursive loading is propagated up. 147 * 148 * While the module is in this state the loader is in reentrant mode. 149 * 150 * Prev state: INITIALIZING 151 * Next state: GC 152 */ 153 KLDRSTATE_INITIALIZATION_FAILED, 154 110 155 /** The module has been successfully loaded and initialized. 111 * (The loader can still be in a re-entrant mode.) 156 * While the module is in this state the loader can be in reentrant 157 * or 'unused' mode. 158 * 112 159 * Prev state: INITIALIZING 113 160 * Next state: PENDING_TERMINATION 114 * Re-entrant.115 161 */ 116 162 KLDRSTATE_GOOD, 163 117 164 /** Pending termination, reference count is 0. 118 * (The loader can now be in a re-entrant mode.) 165 * While the module is in this state the loader is in reentrant mode. 166 * 119 167 * Prev state: GOOD 120 168 * Next state: TERMINATING, GOOD 121 169 */ 122 170 KLDRSTATE_PENDING_TERMINATION, 171 123 172 /** Terminating, reference count is still 0. 124 * (The loader is now in a re-entrant mode, but loading is a bit restricted.) 173 * While the module is in this state the loader is in reentrant mode. 174 * 125 175 * Prev state: PENDING_TERMINATION 126 176 * Next state: PENDING_GC 127 177 */ 128 178 KLDRSTATE_TERMINATING, 179 129 180 /** Pending garbage collection. 130 * (The loader can still be in a re-entrant mode.)131 * Prev state: TERMINATING, INITIALIZING, PENDING_INITIALIZATION181 * 182 * Prev state: TERMINATING, PENDING_INITIALIZATION, INITIALIZATION_FAILED 132 183 * Next state: GC, RELOADED 133 184 */ 134 185 KLDRSTATE_PENDING_GC, 186 135 187 /** Being garbage collected. 136 * Prev state: PENDING_GC 188 * 189 * Prev state: PENDING_GC, INITIALIZATION_FAILED 137 190 * Next state: PENDING_DESTROY, DESTROYED 138 191 */ 139 192 KLDRSTATE_GC, 193 140 194 /** The module has be unlinked, but there are still stack references to it. 141 * Prev state: GC 195 * 196 * Prev state: GC, FIXED_UP, LOADED_PREREQUISITES, MAPPED, OPEN 142 197 * Next state: DESTROYED 143 198 */ 144 199 KLDRSTATE_PENDING_DESTROY, 200 145 201 /** The module has been destroyed and is no longer valid. 202 * 146 203 * Prev state: GC, PENDING_DESTROY 147 204 */ 148 205 KLDRSTATE_DESTROYED, 206 149 207 /** The end of valid states (exclusive) */ 150 208 KLDRSTATE_END = KLDRSTATE_DESTROYED, … … 194 252 struct KLDRDYLDMOD *pPrev; 195 253 } Load; 196 /** The termination list linkage. */ 254 /** The termination list linkage. 255 * A module will be linked into the termination list upon a successful 256 * return from module initialization. */ 197 257 struct 198 258 { -
trunk/kLdr/tg/KLDRSTATE.txvstc
r2838 r2840 15 15 <reference referencedUin="design:link:::id83t9setug73fpetug74ah.nodeid4wa62etug73fpetug7hpd.linkid14j0oetug73fpetugbmyx:id83t9setug73fpetug74ah.nodeid4wa62etug73fpetug7hpd"> 16 16 <property name="sourceAnchor" value="90,70"/> 17 <property name="bendpoints" value="30,70,30, 980"/>18 <property name="targetAnchor" value="150, 980"/>17 <property name="bendpoints" value="30,70,30,1000"/> 18 <property name="targetAnchor" value="150,1000"/> 19 19 <property name="bounds_setted_by_user" value="true"/> 20 20 <reference referencedUin="linklabel:$transitionInplaceEditing:design:link:::id83t9setug73fpetug74ah.nodeid4wa62etug73fpetug7hpd.linkid14j0oetug73fpetugbmyx:id83t9setug73fpetug74ah.nodeid4wa62etug73fpetug7hpd"> 21 <property name="bounds" value=" 0,50,81,15"/>21 <property name="bounds" value="10,50,77,16"/> 22 22 </reference> 23 23 </reference> … … 64 64 <property name="bounds_setted_by_user" value="true"/> 65 65 <reference referencedUin="linklabel:$transitionInplaceEditing:design:link:::id83t9setug73fpetug74ah.nodeidq28metug73fpetug8uf9.linkid2yl8cetug73fpetugl74g:id83t9setug73fpetug74ah.nodeidq28metug73fpetug8uf9"> 66 <property name="bounds" value="470,120, 81,15"/>66 <property name="bounds" value="470,120,77,16"/> 67 67 </reference> 68 68 </reference> … … 70 70 <reference df-class-name="reference4" referencedUin="design:node:::id83t9setug73fpetug74ah.nodeid7et8etug73fpetug938l"> 71 71 <property name="$shortcutReference" value="true"/> 72 <property name="bounds" value="80,190,13 7,40"/>72 <property name="bounds" value="80,190,135,40"/> 73 73 <reference referencedUin="design:link:::id83t9setug73fpetug74ah.nodeid7et8etug73fpetug938l.linkidr4phetug73fpetugcezv:id83t9setug73fpetug74ah.nodeid7et8etug73fpetug938l"> 74 74 <property name="sourceAnchor" value="130,230"/> … … 78 78 <reference referencedUin="design:link:::id83t9setug73fpetug74ah.nodeid7et8etug73fpetug938l.linkid82puetug73fpetugbwui:id83t9setug73fpetug74ah.nodeid7et8etug73fpetug938l"> 79 79 <property name="sourceAnchor" value="80,220"/> 80 <property name="bendpoints" value="30,220,30,9 70"/>81 <property name="targetAnchor" value="150,9 70"/>80 <property name="bendpoints" value="30,220,30,980"/> 81 <property name="targetAnchor" value="150,980"/> 82 82 <property name="bounds_setted_by_user" value="true"/> 83 83 </reference> … … 89 89 <reference referencedUin="design:link:::id83t9setug73fpetug74ah.nodeid71qrcetug73fpetuga3zj.linkid4fiuhetug73fpetugbs4x:id83t9setug73fpetug74ah.nodeid71qrcetug73fpetuga3zj"> 90 90 <property name="sourceAnchor" value="90,300"/> 91 <property name="bendpoints" value="30,300,30, 1000"/>92 <property name="targetAnchor" value="150, 1000"/>91 <property name="bendpoints" value="30,300,30,970"/> 92 <property name="targetAnchor" value="150,970"/> 93 93 <property name="bounds_setted_by_user" value="true"/> 94 94 </reference> … … 145 145 <property name="bounds_setted_by_user" value="true"/> 146 146 <reference referencedUin="linklabel:$transitionInplaceEditing:design:link:::id83t9setug73fpetug74ah.nodeid7q41getug73fpetugejq5.linkid1izxmetug73fpetugesem:id83t9setug73fpetug74ah.nodeid7q41getug73fpetugejq5"> 147 <property name="bounds" value="290,750, 71,15"/>147 <property name="bounds" value="290,750,84,16"/> 148 148 </reference> 149 149 </reference> … … 156 156 <reference df-class-name="reference11" referencedUin="design:node:::id83t9setug73fpetug74ah.nodeid6b4f8etug73fpetugfa3i"> 157 157 <property name="$shortcutReference" value="true"/> 158 <property name="bounds" value="150,380,1 33,40"/>158 <property name="bounds" value="150,380,129,40"/> 159 159 <reference referencedUin="design:link:::id83t9setug73fpetug74ah.nodeid6b4f8etug73fpetugfa3i.linkidy5coetug73fpetughmwy:id83t9setug73fpetug74ah.nodeid6b4f8etug73fpetugfa3i"> 160 160 <property name="sourceAnchor" value="210,420"/> … … 163 163 </reference> 164 164 <reference referencedUin="design:link:::id83t9setug73fpetug74ah.nodeid6b4f8etug73fpetugfa3i.linkid989qmetug73fpetugi623:id83t9setug73fpetug74ah.nodeid6b4f8etug73fpetugfa3i"> 165 <property name="sourceAnchor" value="150,390"/> 166 <property name="bendpoints" value="100,390,100,820"/> 167 <property name="targetAnchor" value="150,820"/> 168 <property name="bounds_setted_by_user" value="true"/> 165 <property name="sourceAnchor" value="150,410"/> 166 <property name="bendpoints" value="60,410,60,810"/> 167 <property name="targetAnchor" value="150,810"/> 168 <property name="bounds_setted_by_user" value="true"/> 169 <reference referencedUin="linklabel:$transitionInplaceEditing:design:link:::id83t9setug73fpetug74ah.nodeid6b4f8etug73fpetugfa3i.linkid989qmetug73fpetugi623:id83t9setug73fpetug74ah.nodeid6b4f8etug73fpetugfa3i"> 170 <property name="bounds" value="50,390,94,16"/> 171 </reference> 169 172 </reference> 170 173 </reference> … … 179 182 <property name="bounds_setted_by_user" value="true"/> 180 183 <reference referencedUin="linklabel:$transitionInplaceEditing:design:link:::id83t9setug73fpetug74ah.nodeid2vt9ietug73fpetugfjhj.linkid7b0d0etug73fpetughibe:id83t9setug73fpetug74ah.nodeid2vt9ietug73fpetugfjhj"> 181 <property name="bounds" value=" 351,500,42,15"/>184 <property name="bounds" value="290,490,42,16"/> 182 185 </reference> 183 186 </reference> … … 200 203 <reference df-class-name="reference14" referencedUin="design:node:::id83t9setug73fpetug74ah.nodeidswftetug73fpetugfwd3"> 201 204 <property name="$shortcutReference" value="true"/> 202 <property name="bounds" value="150,630,134,40"/> 205 <property name="bounds" value="150,630,131,40"/> 206 <reference referencedUin="design:link:::id83t9setug73fpetug74ah.nodeidswftetug73fpetugfwd3.linkid7ockpetuqdc66etuqdq4c:id83t9setug73fpetug74ah.nodeidswftetug73fpetugfwd3"> 207 <property name="sourceAnchor" value="281,650"/> 208 <property name="bendpoints" value="310,650,310,570"/> 209 <property name="targetAnchor" value="284,570"/> 210 <property name="bounds_setted_by_user" value="true"/> 211 <reference referencedUin="linklabel:$transitionInplaceEditing:design:link:::id83t9setug73fpetug74ah.nodeidswftetug73fpetugfwd3.linkid7ockpetuqdc66etuqdq4c:id83t9setug73fpetug74ah.nodeidswftetug73fpetugfwd3"> 212 <property name="bounds" value="290,650,84,16"/> 213 </reference> 214 </reference> 203 215 <reference referencedUin="design:link:::id83t9setug73fpetug74ah.nodeidswftetug73fpetugfwd3.linkid3jvhdetug73fpetugiz5h:id83t9setug73fpetug74ah.nodeidswftetug73fpetugfwd3"> 204 216 <property name="sourceAnchor" value="210,670"/> … … 217 229 <property name="bounds_setted_by_user" value="true"/> 218 230 <reference referencedUin="linklabel:$transitionInplaceEditing:design:link:::id83t9setug73fpetug74ah.nodeid3z4oketug73fpetuggjl4.linkidotudetug73fpetugilak:id83t9setug73fpetug74ah.nodeid3z4oketug73fpetuggjl4"> 219 <property name="bounds" value="470,600,45,1 5"/>231 <property name="bounds" value="470,600,45,16"/> 220 232 </reference> 221 233 </reference> … … 233 245 <reference df-class-name="reference17" referencedUin="design:node:::id83t9setug73fpetug74ah.nodeid6t6upetug73fpetugj6k4"> 234 246 <property name="$shortcutReference" value="true"/> 235 <property name="bounds" value="290,190,1 92,40"/>247 <property name="bounds" value="290,190,189,40"/> 236 248 <reference referencedUin="design:link:::id83t9setug73fpetug74ah.nodeid6t6upetug73fpetugj6k4.linkid529snetug73fpetuglmq0:id83t9setug73fpetug74ah.nodeid6t6upetug73fpetugj6k4"> 237 <property name="sourceAnchor" value="4 82,220"/>249 <property name="sourceAnchor" value="479,220"/> 238 250 <property name="bendpoints" value="550,220,550,830"/> 239 251 <property name="targetAnchor" value="284,830"/> … … 248 260 <reference df-class-name="reference18" referencedUin="design:node:::id83t9setug73fpetug74ah.nodeid5e0mxetug73fpetugjk65"> 249 261 <property name="$shortcutReference" value="true"/> 250 <property name="bounds" value="320,270,1 21,40"/>262 <property name="bounds" value="320,270,118,40"/> 251 263 <reference referencedUin="design:link:::id83t9setug73fpetug74ah.nodeid5e0mxetug73fpetugjk65.linkidcf8yetug73fpetuglj2g:id83t9setug73fpetug74ah.nodeid5e0mxetug73fpetugjk65"> 252 <property name="sourceAnchor" value="4 41,300"/>264 <property name="sourceAnchor" value="438,300"/> 253 265 <property name="bendpoints" value="550,300,550,820"/> 254 266 <property name="targetAnchor" value="284,820"/> … … 271 283 <property name="targetAnchor" value="210,380"/> 272 284 <reference referencedUin="linklabel:$transitionInplaceEditing:design:link:::id83t9setug73fpetug74ah.nodeid6yrvpetui3nn8etui62p3.linkid4uffpetui3nn8etui6xmx:id83t9setug73fpetug74ah.nodeid6yrvpetui3nn8etui62p3"> 273 <property name="bounds" value="220,360,12 8,15"/>285 <property name="bounds" value="220,360,122,16"/> 274 286 </reference> 275 287 </reference> … … 396 408 <participant role="Client" referencedUin="design:node:::id83t9setug73fpetug74ah.nodeid7q41getug73fpetugejq5"/> 397 409 <property name="$metaclass" value="Transition"/> 398 <property name="$event_name" value="Load again"/>410 <property name="$event_name" value="Loaded again"/> 399 411 </link> 400 412 </node> … … 415 427 <participant role="Client" referencedUin="design:node:::id83t9setug73fpetug74ah.nodeid6b4f8etug73fpetugfa3i"/> 416 428 <property name="$metaclass" value="Transition"/> 429 <property name="$event_name" value="Other init failure"/> 417 430 </link> 418 431 </node> … … 448 461 <participant role="Client" referencedUin="design:node:::id83t9setug73fpetug74ah.nodeidswftetug73fpetugfwd3"/> 449 462 <property name="$metaclass" value="Transition"/> 463 </link> 464 <link uin="id83t9setug73fpetug74ah.nodeidswftetug73fpetugfwd3.linkid7ockpetuqdc66etuqdq4c"> 465 <property name="$metaclass" value="Transition"/> 466 <participant role="Supplier" referencedUin="design:node:::id83t9setug73fpetug74ah.nodeid8048etug73fpetugfpwv"/> 467 <participant role="Client" referencedUin="design:node:::id83t9setug73fpetug74ah.nodeidswftetug73fpetugfwd3"/> 468 <property name="$event_name" value="Loaded again"/> 450 469 </link> 451 470 </node> … … 502 521 <property name="$name" value="SyncBar1"/> 503 522 <link uin="id83t9setug73fpetug74ah.nodeid6yrvpetui3nn8etui62p3.linkid4uffpetui3nn8etui6xmx"> 504 <property name="$metaclass" value="Transition"/>505 523 <participant role="Supplier" referencedUin="design:node:::id83t9setug73fpetug74ah.nodeid6b4f8etug73fpetugfa3i"/> 506 524 <participant role="Client" referencedUin="design:node:::id83t9setug73fpetug74ah.nodeid6yrvpetui3nn8etui62p3"/> 525 <property name="$metaclass" value="Transition"/> 507 526 <property name="$event_name" value="Fixed up all modules"/> 508 527 </link> -
trunk/kLdr/tg/kLdr.tpr
r2838 r2840 6 6 Root.0.package_prefix= 7 7 Version=3.0 8 projectfile.encoding=MacRoman 8 projectfile.encoding=MS932 9 Root.1=$TGH$/jdk/jre/lib/rt.jar 10 Root.1.access=import 11 Root.1.non_removable= 9 12 [workspace] 10 13 Developer.CodingWorkspace={{0,2,-1,0,0,0,0,0,0,1,0,50,75,25,-1,-1,-1,-1}${0,1,-1,0,0,0,0,1,0,1,0,50,75,25,-1,-1,-1,-1}${0,3,-1,0,0,0,0,1,0,1,0,66,50,25,-1,-1,-1,-1}${0,3,-1,0,0,0,0,1,0,1,0,66,50,25,-1,-1,-1,-1}${0,-1,-1,0,0,0,0,0,0,1,0,5,5,5,-1,-1,-1,-1}${0,5,-1,0,0,0,0,0,0,1,0,50,50,25,-1,-1,-1,-1}${0,4,-1,0,0,0,0,1,0,1,1,66,50,25,-1,-1,-1,-1}${0,7,-1,0,0,0,0,0,0,1,0,50,50,75,-1,-1,-1,-1}}
Note:
See TracChangeset
for help on using the changeset viewer.