Changeset 01029fc in mainline for kernel/generic/src/mm/as.c


Ignore:
Timestamp:
2012-11-07T21:30:44Z (13 years ago)
Author:
Jakub Jermar <jakub@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
3b8a990
Parents:
c387838
Message:

Define two new as area backend callbacks.

  • Add is_resizable(as_area_t *)
  • Add is_shareable(as_area_t *)
  • Remove special knowledge of the phys backend from as_area_resize()
File:
1 edited

Legend:

Unmodified
Added
Removed
  • kernel/generic/src/mm/as.c

    rc387838 r01029fc  
    696696                return ENOENT;
    697697        }
    698        
    699         if (area->backend == &phys_backend) {
    700                 /*
    701                  * Remapping of address space areas associated
    702                  * with memory mapped devices is not supported.
     698
     699        if (!area->backend->is_resizable(area)) {
     700                /*
     701                 * The backend does not support resizing for this area.
    703702                 */
    704703                mutex_unlock(&area->lock);
     
    10571056        }
    10581057       
    1059         if ((!src_area->backend) || (!src_area->backend->share)) {
    1060                 /*
    1061                  * There is no backend or the backend does not
    1062                  * know how to share the area.
     1058        if (!src_area->backend->is_shareable(src_area)) {
     1059                /*
     1060                 * The backend does not permit sharing of this area.
    10631061                 */
    10641062                mutex_unlock(&src_area->lock);
Note: See TracChangeset for help on using the changeset viewer.