[PATCH rdma-core 6/7] libhns: The content of the header file should be protected with #define

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

 



From: Xinhao Liu <liuxinhao5@xxxxxxxxxxxxx>

Header files should be protected with #define to prevent repeated
inclusion.

Signed-off-by: Xinhao Liu <liuxinhao5@xxxxxxxxxxxxx>
Signed-off-by: Wenpeng Liang <liangwenpeng@xxxxxxxxxx>
---
 providers/hns/hns_roce_u_db.h | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/providers/hns/hns_roce_u_db.h b/providers/hns/hns_roce_u_db.h
index b44e64d4..c3dd583a 100644
--- a/providers/hns/hns_roce_u_db.h
+++ b/providers/hns/hns_roce_u_db.h
@@ -30,13 +30,13 @@
  * SOFTWARE.
  */
 
+#ifndef _HNS_ROCE_U_DB_H
+#define _HNS_ROCE_U_DB_H
+
 #include <linux/types.h>
 
 #include "hns_roce_u.h"
 
-#ifndef _HNS_ROCE_U_DB_H
-#define _HNS_ROCE_U_DB_H
-
 #if __BYTE_ORDER == __LITTLE_ENDIAN
 #define HNS_ROCE_PAIR_TO_64(val) ((uint64_t) val[1] << 32 | val[0])
 #elif __BYTE_ORDER == __BIG_ENDIAN
-- 
2.33.0




[Index of Archives]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Photo]     [Yosemite News]     [Yosemite Photos]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux