[v3,3/7] net/vmxnet3: remove 'typedef int bool'
Checks
Commit Message
Replace 'typedef int bool' with 'stdbool.h' to avoid possible
multiple definitions of 'bool'.
Remove 'typedef char Bool' and use 'bool' instead.
Signed-off-by: Dharmik Thakkar <dharmik.thakkar@arm.com>
Reviewed-by: Phil Yang <phil.yang@arm.com>
Reviewed-by: Ruifeng Wang <ruifeng.wang@arm.com>
Acked-by: Yong Wang <yongwang@vmware.com>
---
drivers/net/vmxnet3/base/vmxnet3_defs.h | 6 +++---
drivers/net/vmxnet3/base/vmxnet3_osdep.h | 4 ++--
2 files changed, 5 insertions(+), 5 deletions(-)
@@ -577,7 +577,7 @@ enum vmxnet3_intr_type {
typedef
#include "vmware_pack_begin.h"
struct Vmxnet3_IntrConf {
- Bool autoMask;
+ bool autoMask;
uint8 numIntrs; /* # of interrupts */
uint8 eventIntrIdx;
uint8 modLevels[VMXNET3_MAX_INTRS]; /* moderation level for each intr */
@@ -593,7 +593,7 @@ Vmxnet3_IntrConf;
typedef
#include "vmware_pack_begin.h"
struct Vmxnet3_QueueStatus {
- Bool stopped;
+ bool stopped;
uint8 _pad[3];
__le32 error;
}
@@ -613,7 +613,7 @@ Vmxnet3_TxQueueCtrl;
typedef
#include "vmware_pack_begin.h"
struct Vmxnet3_RxQueueCtrl {
- Bool updateRxProd;
+ bool updateRxProd;
uint8 _pad[7];
__le64 reserved;
}
@@ -5,12 +5,12 @@
#ifndef _VMXNET3_OSDEP_H
#define _VMXNET3_OSDEP_H
+#include <stdbool.h>
+
typedef uint64_t uint64;
typedef uint32_t uint32;
typedef uint16_t uint16;
typedef uint8_t uint8;
-typedef int bool;
-typedef char Bool;
#ifndef UNLIKELY
#define UNLIKELY(x) __builtin_expect((x),0)