zephyr: replace zephyr integer types with C99 types
git grep -l 'u\(8\|16\|32\|64\)_t' | \ xargs sed -i "s/u\(8\|16\|32\|64\)_t/uint\1_t/g" git grep -l 's\(8\|16\|32\|64\)_t' | \ xargs sed -i "s/s\(8\|16\|32\|64\)_t/int\1_t/g" Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
This commit is contained in:
parent
ee6fa31af6
commit
a1b77fd589
2364 changed files with 32505 additions and 32505 deletions
|
@ -57,7 +57,7 @@ struct net_if_addr {
|
|||
#if defined(CONFIG_NET_IPV6_DAD) && defined(CONFIG_NET_NATIVE_IPV6)
|
||||
/** Duplicate address detection (DAD) timer */
|
||||
sys_snode_t dad_node;
|
||||
u32_t dad_start;
|
||||
uint32_t dad_start;
|
||||
#endif
|
||||
/** How the IP address was set */
|
||||
enum net_addr_type addr_type;
|
||||
|
@ -67,19 +67,19 @@ struct net_if_addr {
|
|||
|
||||
#if defined(CONFIG_NET_IPV6_DAD) && defined(CONFIG_NET_NATIVE_IPV6)
|
||||
/** How many times we have done DAD */
|
||||
u8_t dad_count;
|
||||
uint8_t dad_count;
|
||||
#endif
|
||||
|
||||
/** Is the IP address valid forever */
|
||||
u8_t is_infinite : 1;
|
||||
uint8_t is_infinite : 1;
|
||||
|
||||
/** Is this IP address used or not */
|
||||
u8_t is_used : 1;
|
||||
uint8_t is_used : 1;
|
||||
|
||||
/** Is this IP address usage limited to the subnet (mesh) or not */
|
||||
u8_t is_mesh_local : 1;
|
||||
uint8_t is_mesh_local : 1;
|
||||
|
||||
u8_t _unused : 5;
|
||||
uint8_t _unused : 5;
|
||||
};
|
||||
|
||||
/**
|
||||
|
@ -92,12 +92,12 @@ struct net_if_mcast_addr {
|
|||
struct net_addr address;
|
||||
|
||||
/** Is this multicast IP address used or not */
|
||||
u8_t is_used : 1;
|
||||
uint8_t is_used : 1;
|
||||
|
||||
/** Did we join to this group */
|
||||
u8_t is_joined : 1;
|
||||
uint8_t is_joined : 1;
|
||||
|
||||
u8_t _unused : 6;
|
||||
uint8_t _unused : 6;
|
||||
};
|
||||
|
||||
/**
|
||||
|
@ -116,15 +116,15 @@ struct net_if_ipv6_prefix {
|
|||
struct net_if *iface;
|
||||
|
||||
/** Prefix length */
|
||||
u8_t len;
|
||||
uint8_t len;
|
||||
|
||||
/** Is the IP prefix valid forever */
|
||||
u8_t is_infinite : 1;
|
||||
uint8_t is_infinite : 1;
|
||||
|
||||
/** Is this prefix used or not */
|
||||
u8_t is_used : 1;
|
||||
uint8_t is_used : 1;
|
||||
|
||||
u8_t _unused : 6;
|
||||
uint8_t _unused : 6;
|
||||
};
|
||||
|
||||
/**
|
||||
|
@ -143,21 +143,21 @@ struct net_if_router {
|
|||
struct net_if *iface;
|
||||
|
||||
/** Router life timer start */
|
||||
u32_t life_start;
|
||||
uint32_t life_start;
|
||||
|
||||
/** Router lifetime */
|
||||
u16_t lifetime;
|
||||
uint16_t lifetime;
|
||||
|
||||
/** Is this router used or not */
|
||||
u8_t is_used : 1;
|
||||
uint8_t is_used : 1;
|
||||
|
||||
/** Is default router */
|
||||
u8_t is_default : 1;
|
||||
uint8_t is_default : 1;
|
||||
|
||||
/** Is the router valid forever */
|
||||
u8_t is_infinite : 1;
|
||||
uint8_t is_infinite : 1;
|
||||
|
||||
u8_t _unused : 5;
|
||||
uint8_t _unused : 5;
|
||||
};
|
||||
|
||||
/*
|
||||
|
@ -230,26 +230,26 @@ struct net_if_ipv6 {
|
|||
struct net_if_ipv6_prefix prefix[NET_IF_MAX_IPV6_PREFIX];
|
||||
|
||||
/** Default reachable time (RFC 4861, page 52) */
|
||||
u32_t base_reachable_time;
|
||||
uint32_t base_reachable_time;
|
||||
|
||||
/** Reachable time (RFC 4861, page 20) */
|
||||
u32_t reachable_time;
|
||||
uint32_t reachable_time;
|
||||
|
||||
/** Retransmit timer (RFC 4861, page 52) */
|
||||
u32_t retrans_timer;
|
||||
uint32_t retrans_timer;
|
||||
#if defined(CONFIG_NET_IPV6_ND) && defined(CONFIG_NET_NATIVE_IPV6)
|
||||
/** Router solicitation timer node */
|
||||
sys_snode_t rs_node;
|
||||
|
||||
/* RS start time */
|
||||
u32_t rs_start;
|
||||
uint32_t rs_start;
|
||||
|
||||
/** RS count */
|
||||
u8_t rs_count;
|
||||
uint8_t rs_count;
|
||||
#endif
|
||||
|
||||
/** IPv6 hop limit */
|
||||
u8_t hop_limit;
|
||||
uint8_t hop_limit;
|
||||
};
|
||||
|
||||
/** @cond INTERNAL_HIDDEN */
|
||||
|
@ -276,7 +276,7 @@ struct net_if_ipv4 {
|
|||
struct in_addr netmask;
|
||||
|
||||
/** IPv4 time-to-live */
|
||||
u8_t ttl;
|
||||
uint8_t ttl;
|
||||
};
|
||||
|
||||
#if defined(CONFIG_NET_DHCPV4) && defined(CONFIG_NET_NATIVE_IPV4)
|
||||
|
@ -285,21 +285,21 @@ struct net_if_dhcpv4 {
|
|||
sys_snode_t node;
|
||||
|
||||
/** Timer start */
|
||||
s64_t timer_start;
|
||||
int64_t timer_start;
|
||||
|
||||
/** Time for INIT, DISCOVER, REQUESTING, RENEWAL */
|
||||
u32_t request_time;
|
||||
uint32_t request_time;
|
||||
|
||||
u32_t xid;
|
||||
uint32_t xid;
|
||||
|
||||
/** IP address Lease time */
|
||||
u32_t lease_time;
|
||||
uint32_t lease_time;
|
||||
|
||||
/** IP address Renewal time */
|
||||
u32_t renewal_time;
|
||||
uint32_t renewal_time;
|
||||
|
||||
/** IP address Rebinding time */
|
||||
u32_t rebinding_time;
|
||||
uint32_t rebinding_time;
|
||||
|
||||
/** Server ID */
|
||||
struct in_addr server_id;
|
||||
|
@ -314,7 +314,7 @@ struct net_if_dhcpv4 {
|
|||
enum net_dhcpv4_state state;
|
||||
|
||||
/** Number of attempts made for REQUEST and RENEWAL messages */
|
||||
u8_t attempts;
|
||||
uint8_t attempts;
|
||||
};
|
||||
#endif /* CONFIG_NET_DHCPV4 */
|
||||
|
||||
|
@ -327,10 +327,10 @@ struct net_if_ipv4_autoconf {
|
|||
struct net_if *iface;
|
||||
|
||||
/** Timer start */
|
||||
s64_t timer_start;
|
||||
int64_t timer_start;
|
||||
|
||||
/** Time for INIT, DISCOVER, REQUESTING, RENEWAL */
|
||||
u32_t timer_timeout;
|
||||
uint32_t timer_timeout;
|
||||
|
||||
/** Current IP addr */
|
||||
struct in_addr current_ip;
|
||||
|
@ -343,13 +343,13 @@ struct net_if_ipv4_autoconf {
|
|||
enum net_ipv4_autoconf_state state;
|
||||
|
||||
/** Number of sent probe requests */
|
||||
u8_t probe_cnt;
|
||||
uint8_t probe_cnt;
|
||||
|
||||
/** Number of sent announcements */
|
||||
u8_t announce_cnt;
|
||||
uint8_t announce_cnt;
|
||||
|
||||
/** Incoming conflict count */
|
||||
u8_t conflict_cnt;
|
||||
uint8_t conflict_cnt;
|
||||
};
|
||||
#endif /* CONFIG_NET_IPV4_AUTO */
|
||||
|
||||
|
@ -446,7 +446,7 @@ struct net_if_dev {
|
|||
#endif /* CONFIG_NET_OFFLOAD */
|
||||
|
||||
/** The hardware MTU */
|
||||
u16_t mtu;
|
||||
uint16_t mtu;
|
||||
|
||||
#if defined(CONFIG_NET_SOCKETS_OFFLOAD)
|
||||
/** Indicate whether interface is offloaded at socket level. */
|
||||
|
@ -726,7 +726,7 @@ static inline void net_if_stop_rs(struct net_if *iface)
|
|||
* @brief Set a network interface's link address
|
||||
*
|
||||
* @param iface Pointer to a network interface structure
|
||||
* @param addr A pointer to a u8_t buffer representing the address. The buffer
|
||||
* @param addr A pointer to a uint8_t buffer representing the address. The buffer
|
||||
* must remain valid throughout interface lifetime.
|
||||
* @param len length of the address buffer
|
||||
* @param type network bearer type of this link address
|
||||
|
@ -734,7 +734,7 @@ static inline void net_if_stop_rs(struct net_if *iface)
|
|||
* @return 0 on success
|
||||
*/
|
||||
static inline int net_if_set_link_addr(struct net_if *iface,
|
||||
u8_t *addr, u8_t len,
|
||||
uint8_t *addr, uint8_t len,
|
||||
enum net_link_type type)
|
||||
{
|
||||
if (net_if_flag_is_set(iface, NET_IF_UP)) {
|
||||
|
@ -757,7 +757,7 @@ static inline int net_if_set_link_addr(struct net_if *iface,
|
|||
*
|
||||
* @return the MTU
|
||||
*/
|
||||
static inline u16_t net_if_get_mtu(struct net_if *iface)
|
||||
static inline uint16_t net_if_get_mtu(struct net_if *iface)
|
||||
{
|
||||
return iface->if_dev->mtu;
|
||||
}
|
||||
|
@ -769,7 +769,7 @@ static inline u16_t net_if_get_mtu(struct net_if *iface)
|
|||
* @param mtu New MTU, note that we store only 16 bit mtu value.
|
||||
*/
|
||||
static inline void net_if_set_mtu(struct net_if *iface,
|
||||
u16_t mtu)
|
||||
uint16_t mtu)
|
||||
{
|
||||
iface->if_dev->mtu = mtu;
|
||||
}
|
||||
|
@ -925,7 +925,7 @@ __syscall int net_if_ipv6_addr_lookup_by_index(const struct in6_addr *addr);
|
|||
struct net_if_addr *net_if_ipv6_addr_add(struct net_if *iface,
|
||||
struct in6_addr *addr,
|
||||
enum net_addr_type addr_type,
|
||||
u32_t vlifetime);
|
||||
uint32_t vlifetime);
|
||||
|
||||
/**
|
||||
* @brief Add a IPv6 address to an interface by index
|
||||
|
@ -940,7 +940,7 @@ struct net_if_addr *net_if_ipv6_addr_add(struct net_if *iface,
|
|||
__syscall bool net_if_ipv6_addr_add_by_index(int index,
|
||||
struct in6_addr *addr,
|
||||
enum net_addr_type addr_type,
|
||||
u32_t vlifetime);
|
||||
uint32_t vlifetime);
|
||||
|
||||
/**
|
||||
* @brief Update validity lifetime time of an IPv6 address.
|
||||
|
@ -949,7 +949,7 @@ __syscall bool net_if_ipv6_addr_add_by_index(int index,
|
|||
* @param vlifetime Validity time for this address
|
||||
*/
|
||||
void net_if_ipv6_addr_update_lifetime(struct net_if_addr *ifaddr,
|
||||
u32_t vlifetime);
|
||||
uint32_t vlifetime);
|
||||
|
||||
/**
|
||||
* @brief Remove an IPv6 address from an interface
|
||||
|
@ -1129,7 +1129,7 @@ struct net_if_ipv6_prefix *net_if_ipv6_prefix_get(struct net_if *iface,
|
|||
*/
|
||||
struct net_if_ipv6_prefix *net_if_ipv6_prefix_lookup(struct net_if *iface,
|
||||
struct in6_addr *addr,
|
||||
u8_t len);
|
||||
uint8_t len);
|
||||
|
||||
/**
|
||||
* @brief Add a IPv6 prefix to an network interface.
|
||||
|
@ -1143,8 +1143,8 @@ struct net_if_ipv6_prefix *net_if_ipv6_prefix_lookup(struct net_if *iface,
|
|||
*/
|
||||
struct net_if_ipv6_prefix *net_if_ipv6_prefix_add(struct net_if *iface,
|
||||
struct in6_addr *prefix,
|
||||
u8_t len,
|
||||
u32_t lifetime);
|
||||
uint8_t len,
|
||||
uint32_t lifetime);
|
||||
|
||||
/**
|
||||
* @brief Remove an IPv6 prefix from an interface
|
||||
|
@ -1156,7 +1156,7 @@ struct net_if_ipv6_prefix *net_if_ipv6_prefix_add(struct net_if *iface,
|
|||
* @return True if successfully removed, false otherwise
|
||||
*/
|
||||
bool net_if_ipv6_prefix_rm(struct net_if *iface, struct in6_addr *addr,
|
||||
u8_t len);
|
||||
uint8_t len);
|
||||
|
||||
/**
|
||||
* @brief Set the infinite status of the prefix
|
||||
|
@ -1177,7 +1177,7 @@ static inline void net_if_ipv6_prefix_set_lf(struct net_if_ipv6_prefix *prefix,
|
|||
* @param lifetime Prefix lifetime in seconds
|
||||
*/
|
||||
void net_if_ipv6_prefix_set_timer(struct net_if_ipv6_prefix *prefix,
|
||||
u32_t lifetime);
|
||||
uint32_t lifetime);
|
||||
|
||||
/**
|
||||
* @brief Unset the prefix lifetime timer.
|
||||
|
@ -1251,7 +1251,7 @@ struct net_if_router *net_if_ipv6_router_find_default(struct net_if *iface,
|
|||
* @param lifetime Lifetime of this router.
|
||||
*/
|
||||
void net_if_ipv6_router_update_lifetime(struct net_if_router *router,
|
||||
u16_t lifetime);
|
||||
uint16_t lifetime);
|
||||
|
||||
/**
|
||||
* @brief Add IPv6 router to the system.
|
||||
|
@ -1264,7 +1264,7 @@ void net_if_ipv6_router_update_lifetime(struct net_if_router *router,
|
|||
*/
|
||||
struct net_if_router *net_if_ipv6_router_add(struct net_if *iface,
|
||||
struct in6_addr *addr,
|
||||
u16_t router_lifetime);
|
||||
uint16_t router_lifetime);
|
||||
|
||||
/**
|
||||
* @brief Remove IPv6 router from the system.
|
||||
|
@ -1283,7 +1283,7 @@ bool net_if_ipv6_router_rm(struct net_if_router *router);
|
|||
*
|
||||
* @return Hop limit
|
||||
*/
|
||||
static inline u8_t net_if_ipv6_get_hop_limit(struct net_if *iface)
|
||||
static inline uint8_t net_if_ipv6_get_hop_limit(struct net_if *iface)
|
||||
{
|
||||
#if defined(CONFIG_NET_NATIVE_IPV6)
|
||||
if (!iface->config.ip.ipv6) {
|
||||
|
@ -1303,7 +1303,7 @@ static inline u8_t net_if_ipv6_get_hop_limit(struct net_if *iface)
|
|||
* @param hop_limit New hop limit
|
||||
*/
|
||||
static inline void net_ipv6_set_hop_limit(struct net_if *iface,
|
||||
u8_t hop_limit)
|
||||
uint8_t hop_limit)
|
||||
{
|
||||
#if defined(CONFIG_NET_NATIVE_IPV6)
|
||||
if (!iface->config.ip.ipv6) {
|
||||
|
@ -1321,7 +1321,7 @@ static inline void net_ipv6_set_hop_limit(struct net_if *iface,
|
|||
* @param reachable_time New reachable time
|
||||
*/
|
||||
static inline void net_if_ipv6_set_base_reachable_time(struct net_if *iface,
|
||||
u32_t reachable_time)
|
||||
uint32_t reachable_time)
|
||||
{
|
||||
#if defined(CONFIG_NET_NATIVE_IPV6)
|
||||
if (!iface->config.ip.ipv6) {
|
||||
|
@ -1339,7 +1339,7 @@ static inline void net_if_ipv6_set_base_reachable_time(struct net_if *iface,
|
|||
*
|
||||
* @return Reachable timeout
|
||||
*/
|
||||
static inline u32_t net_if_ipv6_get_reachable_time(struct net_if *iface)
|
||||
static inline uint32_t net_if_ipv6_get_reachable_time(struct net_if *iface)
|
||||
{
|
||||
#if defined(CONFIG_NET_NATIVE_IPV6)
|
||||
if (!iface->config.ip.ipv6) {
|
||||
|
@ -1359,7 +1359,7 @@ static inline u32_t net_if_ipv6_get_reachable_time(struct net_if *iface)
|
|||
*
|
||||
* @return Reachable time
|
||||
*/
|
||||
u32_t net_if_ipv6_calc_reachable_time(struct net_if_ipv6 *ipv6);
|
||||
uint32_t net_if_ipv6_calc_reachable_time(struct net_if_ipv6 *ipv6);
|
||||
|
||||
/**
|
||||
* @brief Set IPv6 reachable time for a given interface. This requires
|
||||
|
@ -1381,7 +1381,7 @@ static inline void net_if_ipv6_set_reachable_time(struct net_if_ipv6 *ipv6)
|
|||
* @param retrans_timer New retransmit timer
|
||||
*/
|
||||
static inline void net_if_ipv6_set_retrans_timer(struct net_if *iface,
|
||||
u32_t retrans_timer)
|
||||
uint32_t retrans_timer)
|
||||
{
|
||||
#if defined(CONFIG_NET_NATIVE_IPV6)
|
||||
if (!iface->config.ip.ipv6) {
|
||||
|
@ -1399,7 +1399,7 @@ static inline void net_if_ipv6_set_retrans_timer(struct net_if *iface,
|
|||
*
|
||||
* @return Retransmit timer
|
||||
*/
|
||||
static inline u32_t net_if_ipv6_get_retrans_timer(struct net_if *iface)
|
||||
static inline uint32_t net_if_ipv6_get_retrans_timer(struct net_if *iface)
|
||||
{
|
||||
#if defined(CONFIG_NET_NATIVE_IPV6)
|
||||
if (!iface->config.ip.ipv6) {
|
||||
|
@ -1534,7 +1534,7 @@ int net_if_config_ipv4_put(struct net_if *iface);
|
|||
*
|
||||
* @return Time-to-live
|
||||
*/
|
||||
static inline u8_t net_if_ipv4_get_ttl(struct net_if *iface)
|
||||
static inline uint8_t net_if_ipv4_get_ttl(struct net_if *iface)
|
||||
{
|
||||
#if defined(CONFIG_NET_NATIVE_IPV4)
|
||||
if (!iface->config.ip.ipv4) {
|
||||
|
@ -1571,7 +1571,7 @@ struct net_if_addr *net_if_ipv4_addr_lookup(const struct in_addr *addr,
|
|||
struct net_if_addr *net_if_ipv4_addr_add(struct net_if *iface,
|
||||
struct in_addr *addr,
|
||||
enum net_addr_type addr_type,
|
||||
u32_t vlifetime);
|
||||
uint32_t vlifetime);
|
||||
|
||||
/**
|
||||
* @brief Remove a IPv4 address from an interface
|
||||
|
@ -1606,7 +1606,7 @@ __syscall int net_if_ipv4_addr_lookup_by_index(const struct in_addr *addr);
|
|||
__syscall bool net_if_ipv4_addr_add_by_index(int index,
|
||||
struct in_addr *addr,
|
||||
enum net_addr_type addr_type,
|
||||
u32_t vlifetime);
|
||||
uint32_t vlifetime);
|
||||
|
||||
/**
|
||||
* @brief Remove a IPv4 address from an interface by interface index
|
||||
|
@ -1711,7 +1711,7 @@ struct net_if_router *net_if_ipv4_router_find_default(struct net_if *iface,
|
|||
struct net_if_router *net_if_ipv4_router_add(struct net_if *iface,
|
||||
struct in_addr *addr,
|
||||
bool is_default,
|
||||
u16_t router_lifetime);
|
||||
uint16_t router_lifetime);
|
||||
|
||||
/**
|
||||
* @brief Remove IPv4 router from the system.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue