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


Ignore:
Timestamp:
2008-02-06T14:24:13Z (16 years ago)
Author:
Martin Decky <martin@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
7208b6c
Parents:
1b067315
Message:

remove config.memory_size, get_memory_size() and memory_init.{c|d}
the amount of available memory can be calculated from the sizes of the zones
add FRAMES2SIZE, SIZE2KB and SIZE2MB functions/macros (code readability)

File:
1 edited

Legend:

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

    r1b067315 r71eef11  
    8585}
    8686
     87static inline size_t FRAMES2SIZE(count_t frames)
     88{
     89        return (size_t) (frames << FRAME_WIDTH);
     90}
     91
    8792#define IS_BUDDY_ORDER_OK(index, order)         \
    8893        ((~(((unative_t) -1) << (order)) & (index)) == 0)
     
    105110
    106111extern int zone_create(pfn_t start, count_t count, pfn_t confframe, int flags);
    107 void *frame_get_parent(pfn_t frame, unsigned int hint);
    108 void frame_set_parent(pfn_t frame, void *data, unsigned int hint);
    109 void frame_mark_unavailable(pfn_t start, count_t count);
    110 uintptr_t zone_conf_size(count_t count);
    111 void zone_merge(unsigned int z1, unsigned int z2);
    112 void zone_merge_all(void);
     112extern void *frame_get_parent(pfn_t frame, unsigned int hint);
     113extern void frame_set_parent(pfn_t frame, void *data, unsigned int hint);
     114extern void frame_mark_unavailable(pfn_t start, count_t count);
     115extern uintptr_t zone_conf_size(count_t count);
     116extern void zone_merge(unsigned int z1, unsigned int z2);
     117extern void zone_merge_all(void);
     118extern uint64_t zone_total_size(void);
    113119
    114120/*
     
    116122 */
    117123extern void zone_print_list(void);
    118 void zone_print_one(unsigned int znum);
     124extern void zone_print_one(unsigned int znum);
    119125
    120126#endif
Note: See TracChangeset for help on using the changeset viewer.