ida_get_new(9)

ida_get_new9

Allocate new id

Usage

int ida_get_new(struct ida * ida, int * p_id);

Arguments

ida

idr handle

p_id

pointer to the allocated handle

Overview

Allocate new ID. It should be called with any required locks.

If memory is required, it will return -EAGAIN, you should unlock and go back to the idr_pre_get call. If the idr is full, it will return -ENOSPC.

p_id returns a value in the range 0 ... 0x7fffffff.

From linux-manual-3.2 3.2.78-1 in Debian 7 (Wheezy). Parsed by carta from the page's man source.