Changeset aaceebc4 in mainline for kernel/generic/include/mm/frame.h


Ignore:
Timestamp:
2013-03-12T23:10:57Z (11 years ago)
Author:
Jan Vesely <jano.vesely@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
cf39b2e
Parents:
428bd07
Message:

Create DMA zone.

use dma zone for dma_map_anonymous calls.
create non-available zone if all pages in that zone are used.
make occupying pages in non-available zones a no-op

This enables ISA DMA on configurations with more than 16 MB of ram

File:
1 edited

Legend:

Unmodified
Added
Removed
  • kernel/generic/include/mm/frame.h

    r428bd07 raaceebc4  
    6363/** Allocate a frame which cannot be identity-mapped. */
    6464#define FRAME_HIGHMEM     0x20
     65/** Allocate a frame which needs to be from DMA zone. */
     66#define FRAME_DMA         0x40
    6567
    6668typedef uint8_t zone_flags_t;
     
    7779/** Zone contains memory that cannot be identity-mapped */
    7880#define ZONE_HIGHMEM    0x10
     81/** Zone contains memory suitable for old ISA DMA */
     82#define ZONE_DMA        0x20
    7983
    8084/** Mask of zone bits that must be matched exactly. */
     
    8286
    8387#define FRAME_TO_ZONE_FLAGS(ff) \
    84         ((((ff) & FRAME_LOWMEM) ? ZONE_LOWMEM : \
     88        ((((ff) & FRAME_DMA) ? ZONE_DMA : \
     89            (((ff) & FRAME_LOWMEM) ? ZONE_LOWMEM : \
    8590            (((ff) & FRAME_HIGHMEM) ? ZONE_HIGHMEM : \
    86             ZONE_LOWMEM /* | ZONE_HIGHMEM */)) | \
    87             ZONE_AVAILABLE) 
     91            ZONE_LOWMEM /* | ZONE_HIGHMEM */))) | \
     92            ZONE_AVAILABLE)
    8893
    8994#define ZONE_FLAGS_MATCH(zf, f) \
Note: See TracChangeset for help on using the changeset viewer.