Changeset 11b285d in mainline for kernel/generic/src/lib/ra.c


Ignore:
Timestamp:
2018-05-13T15:19:32Z (6 years ago)
Author:
Jiří Zárevúcky <jiri.zarevucky@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
ad896eb
Parents:
13db2044
git-author:
Jiří Zárevúcky <jiri.zarevucky@…> (2018-05-13 14:59:01)
git-committer:
Jiří Zárevúcky <jiri.zarevucky@…> (2018-05-13 15:19:32)
Message:

Use standard signature for malloc() in kernel.

The remaining instances of blocking allocation are replaced with
a new separate function named nfmalloc (short for non-failing malloc).

File:
1 edited

Legend:

Unmodified
Added
Removed
  • kernel/generic/src/lib/ra.c

    r13db2044 r11b285d  
    124124        unsigned int i;
    125125
    126         span = (ra_span_t *) malloc(sizeof(ra_span_t), FRAME_ATOMIC);
     126        span = (ra_span_t *) malloc(sizeof(ra_span_t));
    127127        if (!span)
    128128                return NULL;
     
    132132        span->size = size;
    133133
    134         span->free = (list_t *) malloc((span->max_order + 1) * sizeof(list_t),
    135             FRAME_ATOMIC);
     134        span->free = (list_t *) malloc((span->max_order + 1) * sizeof(list_t));
    136135        if (!span->free) {
    137136                free(span);
     
    205204        ra_arena_t *arena;
    206205
    207         arena = (ra_arena_t *) malloc(sizeof(ra_arena_t), FRAME_ATOMIC);
     206        arena = (ra_arena_t *) malloc(sizeof(ra_arena_t));
    208207        if (!arena)
    209208                return NULL;
Note: See TracChangeset for help on using the changeset viewer.