1 Jun 2009 04:16
[PATCH]Documentation/atomic_ops.txt:clean up sample code
Figo.zhang <figo1802 <at> gmail.com>
2009-06-01 02:16:53 GMT
2009-06-01 02:16:53 GMT
list_add() lost a parameter in sample code.
Signed-off-by: Figo.zhang <figo1802 <at> gmail.com>
---
Documentation/atomic_ops.txt | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/Documentation/atomic_ops.txt b/Documentation/atomic_ops.txt
index 4ef2450..396bec3 100644
--- a/Documentation/atomic_ops.txt
+++ b/Documentation/atomic_ops.txt
<at> <at> -229,10 +229,10 <at> <at> kernel. It is the use of atomic counters to implement reference
counting, and it works such that once the counter falls to zero it can
be guaranteed that no other entity can be accessing the object:
-static void obj_list_add(struct obj *obj)
+static void obj_list_add(struct obj *obj, struct list_head *head)
{
obj->active = 1;
- list_add(&obj->list);
+ list_add(&obj->list, head);
}
static void obj_list_del(struct obj *obj)
--
To unsubscribe from this list: send the line "unsubscribe linux-doc" in
the body of a message to majordomo <at> vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
(Continue reading)
RSS Feed