| .. | .. |
|---|
| 1 | +/* SPDX-License-Identifier: GPL-2.0-only */ |
|---|
| 1 | 2 | /* |
|---|
| 2 | 3 | * kref.h - library routines for handling generic reference counted objects |
|---|
| 3 | 4 | * |
|---|
| .. | .. |
|---|
| 7 | 8 | * based on kobject.h which was: |
|---|
| 8 | 9 | * Copyright (C) 2002-2003 Patrick Mochel <mochel@osdl.org> |
|---|
| 9 | 10 | * Copyright (C) 2002-2003 Open Source Development Labs |
|---|
| 10 | | - * |
|---|
| 11 | | - * This file is released under the GPLv2. |
|---|
| 12 | | - * |
|---|
| 13 | 11 | */ |
|---|
| 14 | 12 | |
|---|
| 15 | 13 | #ifndef _KREF_H_ |
|---|
| .. | .. |
|---|
| 53 | 51 | * @release: pointer to the function that will clean up the object when the |
|---|
| 54 | 52 | * last reference to the object is released. |
|---|
| 55 | 53 | * This pointer is required, and it is not acceptable to pass kfree |
|---|
| 56 | | - * in as this function. If the caller does pass kfree to this |
|---|
| 57 | | - * function, you will be publicly mocked mercilessly by the kref |
|---|
| 58 | | - * maintainer, and anyone else who happens to notice it. You have |
|---|
| 59 | | - * been warned. |
|---|
| 54 | + * in as this function. |
|---|
| 60 | 55 | * |
|---|
| 61 | 56 | * Decrement the refcount, and if 0, call release(). |
|---|
| 62 | 57 | * Return 1 if the object was removed, otherwise return 0. Beware, if this |
|---|