Changeset 610 for trunk/kernel/mm/vmm.c


Ignore:
Timestamp:
Dec 27, 2018, 7:38:58 PM (5 years ago)
Author:
alain
Message:

Fix several bugs in VFS to support the following
ksh commandis : cp, mv, rm, mkdir, cd, pwd

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/kernel/mm/vmm.c

    r606 r610  
    14441444#endif
    14451445
    1446     // compute target cluster
    14471446    page_t     * page_ptr;
    14481447    cxy_t        page_cxy;
     
    16111610#if (DEBUG_VMM_GET_ONE_PPN & 0x1)
    16121611if( DEBUG_VMM_GET_ONE_PPN < (uint32_t)hal_get_cycles() )
    1613 printk("\n[%s] thread[%x,%x] for vpn  %x / both mapper & BSS\n",
     1612printk("\n[%s] thread[%x,%x] for vpn  %x / both mapper & BSS\n"
    16141613"      %d bytes from mapper / %d bytes from BSS\n",
    16151614__FUNCTION__, this->process->pid, this->trdid, vpn,
     
    16741673                          (intptr_t)vpn<<CONFIG_PPM_PAGE_SHIFT,
    16751674                          &vseg );
    1676 
    16771675    if( error )
    16781676    {
     
    19331931#endif
    19341932
     1933    // access local GPT to get GPT_COW flag
     1934    bool_t cow = hal_gpt_pte_is_cow( &(process->vmm.gpt), vpn );
     1935
     1936    if( cow == false ) return EXCP_USER_ERROR;
     1937
    19351938    // get local vseg
    19361939    error = vmm_get_vseg( process,
    19371940                          (intptr_t)vpn<<CONFIG_PPM_PAGE_SHIFT,
    19381941                          &vseg );
    1939 
    19401942    if( error )
    19411943    {
     
    19501952    ref_ptr = GET_PTR( process->ref_xp );
    19511953
    1952     // build relevant extended pointers on  GPT and  GPT lock
     1954    // build relevant extended pointers on  relevant GPT and  GPT lock
    19531955    // - access local GPT for a private vseg 
    19541956    // - access reference GPT for a public vseg
Note: See TracChangeset for help on using the changeset viewer.