[PATCH 7/7] staging: lustre: remove container_of0 and __container_of

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



All uses of container_of0 have been replaced by container_of.
container_of0 and __container_of can be safely removed.

Signed-off-by: Aya Mahfouz <mahfouz.saif.elyazal@xxxxxxxxx>
---
 drivers/staging/lustre/include/linux/libcfs/libcfs.h | 11 -----------
 1 file changed, 11 deletions(-)

diff --git a/drivers/staging/lustre/include/linux/libcfs/libcfs.h b/drivers/staging/lustre/include/linux/libcfs/libcfs.h
index 385ced1..e4a0c40 100644
--- a/drivers/staging/lustre/include/linux/libcfs/libcfs.h
+++ b/drivers/staging/lustre/include/linux/libcfs/libcfs.h
@@ -128,17 +128,6 @@ void cfs_get_random_bytes(void *buf, int size);
 #include "libcfs_fail.h"
 #include "libcfs_crypto.h"
 
-/* container_of depends on "likely" which is defined in libcfs_private.h */
-static inline void *__container_of(void *ptr, unsigned long shift)
-{
-	if (IS_ERR_OR_NULL(ptr))
-		return ptr;
-	return (char *)ptr - shift;
-}
-
-#define container_of0(ptr, type, member) \
-	((type *)__container_of((void *)(ptr), offsetof(type, member)))
-
 #define _LIBCFS_H
 
 void *libcfs_kvzalloc(size_t size, gfp_t flags);
-- 
2.4.2


-- 
Kind Regards,
Aya Saif El-yazal Mahfouz
_______________________________________________
devel mailing list
devel@xxxxxxxxxxxxxxxxxxxxxx
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel



[Index of Archives]     [Linux Driver Backports]     [DMA Engine]     [Linux GPIO]     [Linux SPI]     [Video for Linux]     [Linux USB Devel]     [Linux Coverity]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]
  Powered by Linux