]> asedeno.scripts.mit.edu Git - linux.git/commit
Staging: rtl8188eu: core: Use list_entry instead of container_of
authorSrishti Sharma <srishtishar@gmail.com>
Sat, 30 Sep 2017 00:56:55 +0000 (06:26 +0530)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 3 Oct 2017 16:22:23 +0000 (18:22 +0200)
commitac5f9de6d95e36f7373dbd4db45a4508dc57571d
tree7f5a96f78f68804cda2935af551f7fa393bcfdd5
parentf3139e62142999e5dd98c7201cf66b804d3989ed
Staging: rtl8188eu: core: Use list_entry instead of container_of

For variables that have type struct list_head* use list_entry to
access current list element instead of using container_of.
Done using the following semantic patch by coccinelle.

@r@
identifier e;
struct list_head* l;
@@

<... when != l == NULL
l;
...>

(
e=
-container_of
+list_entry
    (
     ...)
)

Signed-off-by: Srishti Sharma <srishtishar@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/rtl8188eu/core/rtw_recv.c