Fork us on GitHub Follow us on Facebook Follow us on Twitter

Changeset 436a0a5 in mainline for kernel/generic/src/ipc/ipcrsc.c


Ignore:
Timestamp:
2018-11-09T22:04:01Z (3 years ago)
Author:
Jiří Zárevúcky <zarevucky.jiri@…>
Branches:
lfn, master
Children:
95d45482
Parents:
88e43bc (diff), abf6c01 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent.
Message:

(merge) Reduce the number of blocking allocations in the kernel

File:
1 edited

Legend:

Unmodified
Added
Removed
  • kernel/generic/src/ipc/ipcrsc.c

    r88e43bc r436a0a5  
    4646{
    4747        phone_t *phone = (phone_t *) arg;
     48        if (phone->hangup_call)
     49                kobject_put(phone->hangup_call->kobject);
    4850        slab_free(phone_cache, phone);
    4951}
     
    7981                        return ENOMEM;
    8082                }
     83                call_t *hcall = ipc_call_alloc();
     84                if (!hcall) {
     85                        cap_free(TASK, handle);
     86                        slab_free(phone_cache, phone);
     87                        free(kobj);
     88                        return ENOMEM;
     89                }
    8190
    8291                ipc_phone_init(phone, task);
    8392                phone->state = IPC_PHONE_CONNECTING;
     93                phone->hangup_call = hcall;
    8494
    8595                kobject_initialize(kobj, KOBJECT_TYPE_PHONE, phone,
Note: See TracChangeset for help on using the changeset viewer.