Name of failed tests ====================
master ------
* checkpatch ./net/batman-adv/debugfs.c * checkpatch ./net/batman-adv/icmp_socket.c * checkpatch ./net/batman-adv/log.c * checkpatch ./net/batman-adv/log.h * checkpatch ./net/batman-adv/main.h * checkpatch ./net/batman-adv/network-coding.c * checkpatch ./net/batman-adv/packet.h * checkpatch ./net/batman-adv/sysfs.c * cppcheck
next ----
* checkpatch ./net/batman-adv/debugfs.c * checkpatch ./net/batman-adv/icmp_socket.c * checkpatch ./net/batman-adv/log.c * checkpatch ./net/batman-adv/log.h * checkpatch ./net/batman-adv/main.h * checkpatch ./net/batman-adv/network-coding.c * checkpatch ./net/batman-adv/packet.h * checkpatch ./net/batman-adv/sysfs.c * difference between net-next and batadv next
Output of different failed tests ================================
next: checkpatch ./net/batman-adv/debugfs.c -------------------------------------------
WARNING: Symbolic permissions 'S_IRUGO' are not preferred. Consider using octal permissions '0444'. #189: FILE: ./net/batman-adv/debugfs.c:189: +static BATADV_DEBUGINFO(routing_algos, S_IRUGO, batadv_algorithms_open);
WARNING: Symbolic permissions 'S_IRUGO' are not preferred. Consider using octal permissions '0444'. #197: FILE: ./net/batman-adv/debugfs.c:197: +static BATADV_DEBUGINFO(neighbors, S_IRUGO, neighbors_open);
WARNING: Symbolic permissions 'S_IRUGO' are not preferred. Consider using octal permissions '0444'. #198: FILE: ./net/batman-adv/debugfs.c:198: +static BATADV_DEBUGINFO(originators, S_IRUGO, batadv_originators_open);
WARNING: Symbolic permissions 'S_IRUGO' are not preferred. Consider using octal permissions '0444'. #199: FILE: ./net/batman-adv/debugfs.c:199: +static BATADV_DEBUGINFO(gateways, S_IRUGO, batadv_gateways_open);
WARNING: Symbolic permissions 'S_IRUGO' are not preferred. Consider using octal permissions '0444'. #200: FILE: ./net/batman-adv/debugfs.c:200: +static BATADV_DEBUGINFO(transtable_global, S_IRUGO,
WARNING: Symbolic permissions 'S_IRUGO' are not preferred. Consider using octal permissions '0444'. #203: FILE: ./net/batman-adv/debugfs.c:203: +static BATADV_DEBUGINFO(bla_claim_table, S_IRUGO, batadv_bla_claim_table_open);
WARNING: Symbolic permissions 'S_IRUGO' are not preferred. Consider using octal permissions '0444'. #204: FILE: ./net/batman-adv/debugfs.c:204: +static BATADV_DEBUGINFO(bla_backbone_table, S_IRUGO,
WARNING: Symbolic permissions 'S_IRUGO' are not preferred. Consider using octal permissions '0444'. #208: FILE: ./net/batman-adv/debugfs.c:208: +static BATADV_DEBUGINFO(dat_cache, S_IRUGO, batadv_dat_cache_open);
WARNING: Symbolic permissions 'S_IRUGO' are not preferred. Consider using octal permissions '0444'. #210: FILE: ./net/batman-adv/debugfs.c:210: +static BATADV_DEBUGINFO(transtable_local, S_IRUGO,
WARNING: Symbolic permissions 'S_IRUGO' are not preferred. Consider using octal permissions '0444'. #213: FILE: ./net/batman-adv/debugfs.c:213: +static BATADV_DEBUGINFO(nc_nodes, S_IRUGO, batadv_nc_nodes_open);
WARNING: Symbolic permissions 'S_IRUGO' are not preferred. Consider using octal permissions '0444'. #216: FILE: ./net/batman-adv/debugfs.c:216: +static BATADV_DEBUGINFO(mcast_flags, S_IRUGO, batadv_mcast_flags_open);
WARNING: Symbolic permissions 'S_IRUGO' are not preferred. Consider using octal permissions '0444'. #256: FILE: ./net/batman-adv/debugfs.c:256: +static BATADV_HARDIF_DEBUGINFO(originators, S_IRUGO,
total: 0 errors, 12 warnings, 0 checks, 420 lines checked
next: checkpatch ./net/batman-adv/icmp_socket.c -----------------------------------------------
WARNING: Symbolic permissions 'S_IWUSR | S_IRUSR' are not preferred. Consider using octal permissions '0600'. #325: FILE: ./net/batman-adv/icmp_socket.c:325: + d = debugfs_create_file(BATADV_ICMP_SOCKET, S_IFREG | S_IWUSR | S_IRUSR,
total: 0 errors, 1 warnings, 0 checks, 407 lines checked
next: checkpatch ./net/batman-adv/log.c ---------------------------------------
WARNING: Symbolic permissions 'S_IRUSR' are not preferred. Consider using octal permissions '0400'. #215: FILE: ./net/batman-adv/log.c:215: + d = debugfs_create_file("log", S_IFREG | S_IRUSR,
total: 0 errors, 1 warnings, 0 checks, 231 lines checked
next: checkpatch ./net/batman-adv/log.h ---------------------------------------
CHECK: Macro argument reuse 'bat_priv' - possible side-effects? #74: FILE: ./net/batman-adv/log.h:74: +#define _batadv_dbg(type, bat_priv, ratelimited, fmt, arg...) \ + do { \ + if (atomic_read(&bat_priv->log_level) & type && \ + (!ratelimited || net_ratelimit())) \ + batadv_debug_log(bat_priv, fmt, ## arg);\ + } \ + while (0)
CHECK: Macro argument 'bat_priv' may be better as '(bat_priv)' to avoid precedence issues #74: FILE: ./net/batman-adv/log.h:74: +#define _batadv_dbg(type, bat_priv, ratelimited, fmt, arg...) \ + do { \ + if (atomic_read(&bat_priv->log_level) & type && \ + (!ratelimited || net_ratelimit())) \ + batadv_debug_log(bat_priv, fmt, ## arg);\ + } \ + while (0)
CHECK: Macro argument 'ratelimited' may be better as '(ratelimited)' to avoid precedence issues #74: FILE: ./net/batman-adv/log.h:74: +#define _batadv_dbg(type, bat_priv, ratelimited, fmt, arg...) \ + do { \ + if (atomic_read(&bat_priv->log_level) & type && \ + (!ratelimited || net_ratelimit())) \ + batadv_debug_log(bat_priv, fmt, ## arg);\ + } \ + while (0)
CHECK: Macro argument reuse 'fmt' - possible side-effects? #96: FILE: ./net/batman-adv/log.h:96: +#define batadv_info(net_dev, fmt, arg...) \ + do { \ + struct net_device *_netdev = (net_dev); \ + struct batadv_priv *_batpriv = netdev_priv(_netdev); \ + batadv_dbg(BATADV_DBG_ALL, _batpriv, fmt, ## arg); \ + pr_info("%s: " fmt, _netdev->name, ## arg); \ + } while (0)
CHECK: Macro argument reuse 'fmt' - possible side-effects? #103: FILE: ./net/batman-adv/log.h:103: +#define batadv_err(net_dev, fmt, arg...) \ + do { \ + struct net_device *_netdev = (net_dev); \ + struct batadv_priv *_batpriv = netdev_priv(_netdev); \ + batadv_dbg(BATADV_DBG_ALL, _batpriv, fmt, ## arg); \ + pr_err("%s: " fmt, _netdev->name, ## arg); \ + } while (0)
total: 0 errors, 0 warnings, 5 checks, 111 lines checked
next: checkpatch ./net/batman-adv/main.h ----------------------------------------
CHECK: Macro argument reuse 'vid' - possible side-effects? #203: FILE: ./net/batman-adv/main.h:203: +#define BATADV_PRINT_VID(vid) ((vid & BATADV_VLAN_HAS_TAG) ? \ + (int)(vid & VLAN_VID_MASK) : -1)
CHECK: Macro argument 'vid' may be better as '(vid)' to avoid precedence issues #203: FILE: ./net/batman-adv/main.h:203: +#define BATADV_PRINT_VID(vid) ((vid & BATADV_VLAN_HAS_TAG) ? \ + (int)(vid & VLAN_VID_MASK) : -1)
total: 0 errors, 0 warnings, 2 checks, 316 lines checked
next: checkpatch ./net/batman-adv/network-coding.c --------------------------------------------------
WARNING: Symbolic permissions 'S_IRUGO | S_IWUSR' are not preferred. Consider using octal permissions '0644'. #1964: FILE: ./net/batman-adv/network-coding.c:1964: + file = debugfs_create_u8("min_tq", S_IRUGO | S_IWUSR, nc_dir,
WARNING: Symbolic permissions 'S_IRUGO | S_IWUSR' are not preferred. Consider using octal permissions '0644'. #1969: FILE: ./net/batman-adv/network-coding.c:1969: + file = debugfs_create_u32("max_fwd_delay", S_IRUGO | S_IWUSR, nc_dir,
WARNING: Symbolic permissions 'S_IRUGO | S_IWUSR' are not preferred. Consider using octal permissions '0644'. #1974: FILE: ./net/batman-adv/network-coding.c:1974: + file = debugfs_create_u32("max_buffer_time", S_IRUGO | S_IWUSR, nc_dir,
total: 0 errors, 3 warnings, 0 checks, 1984 lines checked
next: checkpatch ./net/batman-adv/packet.h ------------------------------------------
CHECK: Macro argument 'n' may be better as '(n)' to avoid precedence issues #24: FILE: ./net/batman-adv/packet.h:24: +#define batadv_tp_is_error(n) ((u8)n > 127 ? 1 : 0)
total: 0 errors, 0 warnings, 1 checks, 631 lines checked
next: checkpatch ./net/batman-adv/sysfs.c -----------------------------------------
CHECK: Macro argument reuse '_name' - possible side-effects? #174: FILE: ./net/batman-adv/sysfs.c:174: +#define BATADV_ATTR_SIF_BOOL(_name, _mode, _post_func) \ + static BATADV_ATTR_SIF_STORE_BOOL(_name, _post_func) \ + static BATADV_ATTR_SIF_SHOW_BOOL(_name) \ + static BATADV_ATTR(_name, _mode, batadv_show_##_name, \ + batadv_store_##_name)
CHECK: Macro argument '_var' may be better as '(_var)' to avoid precedence issues #180: FILE: ./net/batman-adv/sysfs.c:180: +#define BATADV_ATTR_SIF_STORE_UINT(_name, _var, _min, _max, _post_func) \ +ssize_t batadv_store_##_name(struct kobject *kobj, \ + struct attribute *attr, char *buff, \ + size_t count) \ +{ \ + struct net_device *net_dev = batadv_kobj_to_netdev(kobj); \ + struct batadv_priv *bat_priv = netdev_priv(net_dev); \ + \ + return __batadv_store_uint_attr(buff, count, _min, _max, \ + _post_func, attr, \ + &bat_priv->_var, net_dev); \ +}
CHECK: Macro argument '_var' may be better as '(_var)' to avoid precedence issues #193: FILE: ./net/batman-adv/sysfs.c:193: +#define BATADV_ATTR_SIF_SHOW_UINT(_name, _var) \ +ssize_t batadv_show_##_name(struct kobject *kobj, \ + struct attribute *attr, char *buff) \ +{ \ + struct batadv_priv *bat_priv = batadv_kobj_to_batpriv(kobj); \ + \ + return sprintf(buff, "%i\n", atomic_read(&bat_priv->_var)); \ +} \ +
CHECK: Macro argument reuse '_name' - possible side-effects? #205: FILE: ./net/batman-adv/sysfs.c:205: +#define BATADV_ATTR_SIF_UINT(_name, _var, _mode, _min, _max, _post_func)\ + static BATADV_ATTR_SIF_STORE_UINT(_name, _var, _min, _max, _post_func)\ + static BATADV_ATTR_SIF_SHOW_UINT(_name, _var) \ + static BATADV_ATTR(_name, _mode, batadv_show_##_name, \ + batadv_store_##_name)
CHECK: Macro argument reuse '_var' - possible side-effects? #205: FILE: ./net/batman-adv/sysfs.c:205: +#define BATADV_ATTR_SIF_UINT(_name, _var, _mode, _min, _max, _post_func)\ + static BATADV_ATTR_SIF_STORE_UINT(_name, _var, _min, _max, _post_func)\ + static BATADV_ATTR_SIF_SHOW_UINT(_name, _var) \ + static BATADV_ATTR(_name, _mode, batadv_show_##_name, \ + batadv_store_##_name)
CHECK: Macro argument reuse '_name' - possible side-effects? #243: FILE: ./net/batman-adv/sysfs.c:243: +#define BATADV_ATTR_VLAN_BOOL(_name, _mode, _post_func) \ + static BATADV_ATTR_VLAN_STORE_BOOL(_name, _post_func) \ + static BATADV_ATTR_VLAN_SHOW_BOOL(_name) \ + static BATADV_ATTR_VLAN(_name, _mode, batadv_show_vlan_##_name, \ + batadv_store_vlan_##_name)
CHECK: Macro argument '_var' may be better as '(_var)' to avoid precedence issues #249: FILE: ./net/batman-adv/sysfs.c:249: +#define BATADV_ATTR_HIF_STORE_UINT(_name, _var, _min, _max, _post_func) \ +ssize_t batadv_store_##_name(struct kobject *kobj, \ + struct attribute *attr, char *buff, \ + size_t count) \ +{ \ + struct net_device *net_dev = batadv_kobj_to_netdev(kobj); \ + struct batadv_hard_iface *hard_iface; \ + ssize_t length; \ + \ + hard_iface = batadv_hardif_get_by_netdev(net_dev); \ + if (!hard_iface) \ + return 0; \ + \ + length = __batadv_store_uint_attr(buff, count, _min, _max, \ + _post_func, attr, \ + &hard_iface->_var, net_dev); \ + \ + batadv_hardif_put(hard_iface); \ + return length; \ +}
CHECK: Macro argument '_var' may be better as '(_var)' to avoid precedence issues #270: FILE: ./net/batman-adv/sysfs.c:270: +#define BATADV_ATTR_HIF_SHOW_UINT(_name, _var) \ +ssize_t batadv_show_##_name(struct kobject *kobj, \ + struct attribute *attr, char *buff) \ +{ \ + struct net_device *net_dev = batadv_kobj_to_netdev(kobj); \ + struct batadv_hard_iface *hard_iface; \ + ssize_t length; \ + \ + hard_iface = batadv_hardif_get_by_netdev(net_dev); \ + if (!hard_iface) \ + return 0; \ + \ + length = sprintf(buff, "%i\n", atomic_read(&hard_iface->_var)); \ + \ + batadv_hardif_put(hard_iface); \ + return length; \ +}
CHECK: Macro argument reuse '_name' - possible side-effects? #291: FILE: ./net/batman-adv/sysfs.c:291: +#define BATADV_ATTR_HIF_UINT(_name, _var, _mode, _min, _max, _post_func)\ + static BATADV_ATTR_HIF_STORE_UINT(_name, _var, _min, \ + _max, _post_func) \ + static BATADV_ATTR_HIF_SHOW_UINT(_name, _var) \ + static BATADV_ATTR(_name, _mode, batadv_show_##_name, \ + batadv_store_##_name)
CHECK: Macro argument reuse '_var' - possible side-effects? #291: FILE: ./net/batman-adv/sysfs.c:291: +#define BATADV_ATTR_HIF_UINT(_name, _var, _mode, _min, _max, _post_func)\ + static BATADV_ATTR_HIF_STORE_UINT(_name, _var, _min, \ + _max, _post_func) \ + static BATADV_ATTR_HIF_SHOW_UINT(_name, _var) \ + static BATADV_ATTR(_name, _mode, batadv_show_##_name, \ + batadv_store_##_name)
WARNING: Symbolic permissions 'S_IRUGO | S_IWUSR' are not preferred. Consider using octal permissions '0644'. #669: FILE: ./net/batman-adv/sysfs.c:669: +BATADV_ATTR_SIF_BOOL(aggregated_ogms, S_IRUGO | S_IWUSR, NULL);
WARNING: Symbolic permissions 'S_IRUGO | S_IWUSR' are not preferred. Consider using octal permissions '0644'. #670: FILE: ./net/batman-adv/sysfs.c:670: +BATADV_ATTR_SIF_BOOL(bonding, S_IRUGO | S_IWUSR, NULL);
WARNING: Symbolic permissions 'S_IRUGO | S_IWUSR' are not preferred. Consider using octal permissions '0644'. #672: FILE: ./net/batman-adv/sysfs.c:672: +BATADV_ATTR_SIF_BOOL(bridge_loop_avoidance, S_IRUGO | S_IWUSR,
WARNING: Symbolic permissions 'S_IRUGO | S_IWUSR' are not preferred. Consider using octal permissions '0644'. #676: FILE: ./net/batman-adv/sysfs.c:676: +BATADV_ATTR_SIF_BOOL(distributed_arp_table, S_IRUGO | S_IWUSR,
WARNING: Symbolic permissions 'S_IRUGO | S_IWUSR' are not preferred. Consider using octal permissions '0644'. #679: FILE: ./net/batman-adv/sysfs.c:679: +BATADV_ATTR_SIF_BOOL(fragmentation, S_IRUGO | S_IWUSR, batadv_update_min_mtu);
WARNING: Symbolic permissions 'S_IRUGO' are not preferred. Consider using octal permissions '0444'. #680: FILE: ./net/batman-adv/sysfs.c:680: +static BATADV_ATTR(routing_algo, S_IRUGO, batadv_show_bat_algo, NULL);
WARNING: Symbolic permissions 'S_IRUGO | S_IWUSR' are not preferred. Consider using octal permissions '0644'. #681: FILE: ./net/batman-adv/sysfs.c:681: +static BATADV_ATTR(gw_mode, S_IRUGO | S_IWUSR, batadv_show_gw_mode,
WARNING: Symbolic permissions 'S_IRUGO | S_IWUSR' are not preferred. Consider using octal permissions '0644'. #683: FILE: ./net/batman-adv/sysfs.c:683: +BATADV_ATTR_SIF_UINT(orig_interval, orig_interval, S_IRUGO | S_IWUSR,
WARNING: Symbolic permissions 'S_IRUGO | S_IWUSR' are not preferred. Consider using octal permissions '0644'. #685: FILE: ./net/batman-adv/sysfs.c:685: +BATADV_ATTR_SIF_UINT(hop_penalty, hop_penalty, S_IRUGO | S_IWUSR, 0,
WARNING: Symbolic permissions 'S_IRUGO | S_IWUSR' are not preferred. Consider using octal permissions '0644'. #687: FILE: ./net/batman-adv/sysfs.c:687: +static BATADV_ATTR(gw_sel_class, S_IRUGO | S_IWUSR, batadv_show_gw_sel_class,
WARNING: Symbolic permissions 'S_IRUGO | S_IWUSR' are not preferred. Consider using octal permissions '0644'. #689: FILE: ./net/batman-adv/sysfs.c:689: +static BATADV_ATTR(gw_bandwidth, S_IRUGO | S_IWUSR, batadv_show_gw_bwidth,
WARNING: Symbolic permissions 'S_IRUGO | S_IWUSR' are not preferred. Consider using octal permissions '0644'. #692: FILE: ./net/batman-adv/sysfs.c:692: +BATADV_ATTR_SIF_BOOL(multicast_mode, S_IRUGO | S_IWUSR, NULL);
WARNING: Symbolic permissions 'S_IRUGO | S_IWUSR' are not preferred. Consider using octal permissions '0644'. #695: FILE: ./net/batman-adv/sysfs.c:695: +BATADV_ATTR_SIF_UINT(log_level, log_level, S_IRUGO | S_IWUSR, 0,
WARNING: Symbolic permissions 'S_IRUGO | S_IWUSR' are not preferred. Consider using octal permissions '0644'. #699: FILE: ./net/batman-adv/sysfs.c:699: +BATADV_ATTR_SIF_BOOL(network_coding, S_IRUGO | S_IWUSR,
WARNING: Symbolic permissions 'S_IRUGO | S_IWUSR' are not preferred. Consider using octal permissions '0644'. #702: FILE: ./net/batman-adv/sysfs.c:702: +static BATADV_ATTR(isolation_mark, S_IRUGO | S_IWUSR,
WARNING: Symbolic permissions 'S_IRUGO | S_IWUSR' are not preferred. Consider using octal permissions '0644'. #734: FILE: ./net/batman-adv/sysfs.c:734: +BATADV_ATTR_VLAN_BOOL(ap_isolation, S_IRUGO | S_IWUSR, NULL);
WARNING: Symbolic permissions 'S_IRUGO | S_IWUSR' are not preferred. Consider using octal permissions '0644'. #1119: FILE: ./net/batman-adv/sysfs.c:1119: +static BATADV_ATTR(mesh_iface, S_IRUGO | S_IWUSR, batadv_show_mesh_iface,
WARNING: Symbolic permissions 'S_IRUGO' are not preferred. Consider using octal permissions '0444'. #1121: FILE: ./net/batman-adv/sysfs.c:1121: +static BATADV_ATTR(iface_status, S_IRUGO, batadv_show_iface_status, NULL);
WARNING: Symbolic permissions 'S_IRUGO | S_IWUSR' are not preferred. Consider using octal permissions '0644'. #1123: FILE: ./net/batman-adv/sysfs.c:1123: +BATADV_ATTR_HIF_UINT(elp_interval, bat_v.elp_interval, S_IRUGO | S_IWUSR,
WARNING: Symbolic permissions 'S_IRUGO | S_IWUSR' are not preferred. Consider using octal permissions '0644'. #1125: FILE: ./net/batman-adv/sysfs.c:1125: +static BATADV_ATTR(throughput_override, S_IRUGO | S_IWUSR,
total: 0 errors, 20 warnings, 10 checks, 1224 lines checked
master: cppcheck ----------------
[net/batman-adv/bat_v.c:790] -> [net/batman-adv/bat_v.c:796]: (style) Variable 'curr_gw' is reassigned a value before the old one has been used. [net/batman-adv/bat_v_ogm.c:404] -> [net/batman-adv/bat_v_ogm.c:411]: (style) Variable 'orig_ifinfo' is reassigned a value before the old one has been used. [net/batman-adv/bat_v_ogm.c:489] -> [net/batman-adv/bat_v_ogm.c:498]: (style) Variable 'orig_neigh_node' is reassigned a value before the old one has been used. [net/batman-adv/fragmentation.c:255] -> [net/batman-adv/fragmentation.c:263]: (style) Variable 'skb_out' is reassigned a value before the old one has been used. [net/batman-adv/fragmentation.c:355] -> [net/batman-adv/fragmentation.c:362]: (style) Variable 'orig_node_dst' is reassigned a value before the old one has been used. [net/batman-adv/gateway_client.c:707] -> [net/batman-adv/gateway_client.c:718]: (style) Variable 'orig_dst_node' is reassigned a value before the old one has been used. [net/batman-adv/originator.c:367] -> [net/batman-adv/originator.c:372]: (style) Variable 'orig_ifinfo' is reassigned a value before the old one has been used. [net/batman-adv/originator.c:523] -> [net/batman-adv/originator.c:528]: (style) Variable 'hardif_neigh' is reassigned a value before the old one has been used. [net/batman-adv/originator.c:566] -> [net/batman-adv/originator.c:569]: (style) Variable 'hardif_neigh' is reassigned a value before the old one has been used. [net/batman-adv/originator.c:686] -> [net/batman-adv/originator.c:689]: (style) Variable 'neigh_node' is reassigned a value before the old one has been used. [net/batman-adv/send.c:565] -> [net/batman-adv/send.c:570]: (style) Variable 'primary_if' is reassigned a value before the old one has been used.
next: difference between net-next and batadv next -------------------------------------------------
netnext/net/batman-adv/debugfs.h | 2 -- netnext/net/batman-adv/netlink.c | 4 ++-- 2 files changed, 2 insertions(+), 4 deletions(-)
Statistics ==========
master ------
Failed tests: 9 Started build tests: 107 Tested Linux versions: 27 Tested configs: 76
next ----
Failed tests: 9 Started build tests: 125 Tested Linux versions: 25 Tested configs: 84