diff -Nrup linux-2.6.9/include/linux/list.h linux/include/linux/list.h --- linux-2.6.9/include/linux/list.h 2004-10-18 21:54:31.000000000 +0000 +++ linux/include/linux/list.h 2004-11-20 18:55:12.373654048 +0000 @@ -166,6 +166,21 @@ static inline void list_del(struct list_ } /** + * list_del_head - deletes first entry from list. + * @entry: return parameter; will contain former head of list on return. + * @head: head of list from which to delete. + * + * This function is useful for implementing queues. Caller must ensure + * the list is not empty before calling this function. On return, entry + * will point to the former head of the list. + */ +static inline void list_del_head(struct list_head **entry, struct list_head *head) +{ + *entry = head->next; + list_del(head->next); +} + +/** * list_del_rcu - deletes entry from list without re-initialization * @entry: the element to delete from the list. *