1. NAME

idr_replace - replace pointer for given id

2. SYNOPSIS

void * idr_replace(struct idr *  idp , void *  ptr , int  id );

3. ARGUMENTS

idp
    idr handle

ptr
    pointer you want associated with the id

id
    lookup key

4. DESCRIPTION

Replace the pointer registered with an id and return the old value. A -ENOENT return indicates that id was not found. A -EINVAL return indicates that id was not within valid constraints.

The caller must serialize with writers.

5. COPYRIGHT