Changeset 633 for trunk/hal/tsar_mips32/core/hal_gpt.c
- Timestamp:
- May 28, 2019, 6:10:15 PM (5 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/hal/tsar_mips32/core/hal_gpt.c
r632 r633 346 346 347 347 #if GPT_LOCK_WATCHDOG 348 uint32_t count ;348 uint32_t count = 0; 349 349 #endif 350 350 … … 391 391 page_xp = ppm_remote_alloc_pages( gpt_cxy , 0 ); 392 392 393 if( page_xp == NULL )393 if( page_xp == XPTR_NULL ) 394 394 { 395 395 printk("\n[ERROR] in %s : cannot allocate memory for PT2\n", __FUNCTION__ ); … … 445 445 446 446 // get pointer on PT2 base from PTD1 447 448 447 pt2_ppn = TSAR_MMU_PTBA_FROM_PTE1( ptd1 ); 448 pt2_ptr = GET_PTR( ppm_ppn2base( pt2_ppn ) ); 449 449 450 450 // build extended pointers on PT2[ix2].attr … … 461 461 // wait until PTE lock released by the current owner 462 462 do 463 464 463 { 464 pte2_attr = hal_remote_l32( pte2_xp ); 465 465 466 466 #if GPT_LOCK_WATCHDOG … … 475 475 #endif 476 476 477 477 } 478 478 while( (pte2_attr & TSAR_PTE_LOCKED) != 0 ); 479 479 … … 482 482 pte2_attr, 483 483 (pte2_attr | TSAR_PTE_LOCKED) ); 484 484 } 485 485 while( atomic == 0 ); 486 486 … … 498 498 *ppn = pte2_ppn & ((1<<TSAR_MMU_PPN_WIDTH)-1); 499 499 *attr = tsar2gpt( pte2_attr ); 500 500 return 0; 501 501 502 502 } // end hal_gpt_lock_pte()
Note: See TracChangeset
for help on using the changeset viewer.