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


Ignore:
Timestamp:
2018-05-13T15:19:32Z (7 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/ipc/ipc.c

    r13db2044 r11b285d  
    118118        if (!call)
    119119                return NULL;
    120         kobject_t *kobj = (kobject_t *) malloc(sizeof(kobject_t), flags);
     120
     121        kobject_t *kobj;
     122        if (flags & FRAME_ATOMIC)
     123                kobj = (kobject_t *) malloc(sizeof(kobject_t));
     124        else
     125                kobj = (kobject_t *) nfmalloc(sizeof(kobject_t));
     126
    121127        if (!kobj) {
    122128                slab_free(call_cache, call);
Note: See TracChangeset for help on using the changeset viewer.