* [dpdk-test-report] |WARNING| [PATCH 09/56] net/sfc: import libefx 5xxx/6xxx family support
[not found] <1479740470-6723-10-git-send-email-arybchenko@solarflare.com>
@ 2016-11-21 15:13 ` checkpatch
0 siblings, 0 replies; only message in thread
From: checkpatch @ 2016-11-21 15:13 UTC (permalink / raw)
To: test-report; +Cc: Andrew Rybchenko
Test-Label: checkpatch
Test-Status: WARNING
http://dpdk.org/patch/17138
_coding style issues_
CHECK:CAMELCASE: Avoid CamelCase: <__checkReturn>
#155: FILE: drivers/net/sfc/efx/base/efx_ev.c:44:
+static __checkReturn efx_rc_t
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#243: FILE: drivers/net/sfc/efx/base/efx_ev.c:519:
+ return (0);
CHECK:BRACES: Blank lines aren't necessary before a close brace '}'
#245: FILE: drivers/net/sfc/efx/base/efx_ev.c:521:
+
+}
CHECK:BRACES: Blank lines aren't necessary before a close brace '}'
#273: FILE: drivers/net/sfc/efx/base/efx_ev.c:549:
+
+ }
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#318: FILE: drivers/net/sfc/efx/base/efx_ev.c:594:
+ return (ignore);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#405: FILE: drivers/net/sfc/efx/base/efx_ev.c:681:
+ return (B_FALSE);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#455: FILE: drivers/net/sfc/efx/base/efx_ev.c:731:
+ return (should_abort);
CHECK:BRACES: Blank lines aren't necessary after an open brace '{'
#475: FILE: drivers/net/sfc/efx/base/efx_ev.c:751:
+ EFX_QWORD_FIELD(*eqp, FSF_AZ_TX_EV_WQ_FF_FULL) == 0) {
+
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#484: FILE: drivers/net/sfc/efx/base/efx_ev.c:760:
+ return (should_abort);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#502: FILE: drivers/net/sfc/efx/base/efx_ev.c:778:
+ return (B_FALSE);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#516: FILE: drivers/net/sfc/efx/base/efx_ev.c:792:
+ return (B_FALSE);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#645: FILE: drivers/net/sfc/efx/base/efx_ev.c:921:
+ return (should_abort);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#665: FILE: drivers/net/sfc/efx/base/efx_ev.c:941:
+ return (B_TRUE);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#671: FILE: drivers/net/sfc/efx/base/efx_ev.c:947:
+ return (should_abort);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#752: FILE: drivers/net/sfc/efx/base/efx_ev.c:1028:
+ return (should_abort);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#773: FILE: drivers/net/sfc/efx/base/efx_ev.c:1049:
+ return (0);
CHECK:UNNECESSARY_PARENTHESES: Unnecessary parentheses around enp->en_nic_cfg
#801: FILE: drivers/net/sfc/efx/base/efx_ev.c:1077:
+ efx_nic_cfg_t *encp = &(enp->en_nic_cfg);
ERROR:ASSIGN_IN_IF: do not use assignment in if condition
#819: FILE: drivers/net/sfc/efx/base/efx_ev.c:1095:
+ if ((rc = efx_ev_usecs_to_ticks(enp, us, &ticks)) != 0)
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#833: FILE: drivers/net/sfc/efx/base/efx_ev.c:1109:
+ return (0);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#840: FILE: drivers/net/sfc/efx/base/efx_ev.c:1116:
+ return (rc);
CHECK:UNNECESSARY_PARENTHESES: Unnecessary parentheses around enp->en_nic_cfg
#854: FILE: drivers/net/sfc/efx/base/efx_ev.c:1130:
+ efx_nic_cfg_t *encp = &(enp->en_nic_cfg);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#909: FILE: drivers/net/sfc/efx/base/efx_ev.c:1185:
+ return (0);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#918: FILE: drivers/net/sfc/efx/base/efx_ev.c:1194:
+ return (rc);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#1179: FILE: drivers/net/sfc/efx/base/efx_filter.c:539:
+ return (0);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#1192: FILE: drivers/net/sfc/efx/base/efx_filter.c:552:
+ return (rc);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#1215: FILE: drivers/net/sfc/efx/base/efx_filter.c:575:
+ return (tmp);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#1297: FILE: drivers/net/sfc/efx/base/efx_filter.c:657:
+ return (tbl_id);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#1486: FILE: drivers/net/sfc/efx/base/efx_filter.c:846:
+ return (0);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#1495: FILE: drivers/net/sfc/efx/base/efx_filter.c:855:
+ return (key);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#1541: FILE: drivers/net/sfc/efx/base/efx_filter.c:901:
+ return (0);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#1544: FILE: drivers/net/sfc/efx/base/efx_filter.c:904:
+ return (rc);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#1559: FILE: drivers/net/sfc/efx/base/efx_filter.c:919:
+ return (B_FALSE);
WARNING:SPACING: space prohibited between function name and open parenthesis '('
#1562: FILE: drivers/net/sfc/efx/base/efx_filter.c:922:
+ sizeof (left->sfs_dword)))
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#1563: FILE: drivers/net/sfc/efx/base/efx_filter.c:923:
+ return (B_FALSE);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#1568: FILE: drivers/net/sfc/efx/base/efx_filter.c:928:
+ return (B_FALSE);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#1570: FILE: drivers/net/sfc/efx/base/efx_filter.c:930:
+ return (B_TRUE);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#1601: FILE: drivers/net/sfc/efx/base/efx_filter.c:961:
+ return (0);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#1606: FILE: drivers/net/sfc/efx/base/efx_filter.c:966:
+ return (for_insert ? EBUSY : ENOENT);
WARNING:SPACING: space prohibited between function name and open parenthesis '('
#1630: FILE: drivers/net/sfc/efx/base/efx_filter.c:990:
+ 0, sizeof (sftp->sft_spec[0]));
WARNING:BRACES: braces {} are not necessary for single statement blocks
#1646: FILE: drivers/net/sfc/efx/base/efx_filter.c:1006:
+ for (index = 0; index < sftp->sft_size; ++index) {
+ siena_filter_clear_entry(enp, sftp, index);
+ }
WARNING:SPACING: space prohibited between function name and open parenthesis '('
#1665: FILE: drivers/net/sfc/efx/base/efx_filter.c:1025:
+ EFSYS_KMEM_ALLOC(enp->en_esip, sizeof (siena_filter_t), sfp);
WARNING:SPACING: space prohibited between function name and open parenthesis '('
#1701: FILE: drivers/net/sfc/efx/base/efx_filter.c:1061:
+ EFX_STATIC_ASSERT(sizeof (sftp->sft_bitmap[0]) ==
WARNING:SPACING: space prohibited between function name and open parenthesis '('
#1702: FILE: drivers/net/sfc/efx/base/efx_filter.c:1062:
+ sizeof (uint32_t));
WARNING:SPACING: space prohibited between function name and open parenthesis '('
#1704: FILE: drivers/net/sfc/efx/base/efx_filter.c:1064:
+ (sftp->sft_size + (sizeof (uint32_t) * 8) - 1) / 8;
WARNING:SPACING: space prohibited between function name and open parenthesis '('
#1713: FILE: drivers/net/sfc/efx/base/efx_filter.c:1073:
+ sftp->sft_size * sizeof (*sftp->sft_spec),
WARNING:SPACING: space prohibited between function name and open parenthesis '('
#1720: FILE: drivers/net/sfc/efx/base/efx_filter.c:1080:
+ sftp->sft_size * sizeof (*sftp->sft_spec));
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#1723: FILE: drivers/net/sfc/efx/base/efx_filter.c:1083:
+ return (0);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#1737: FILE: drivers/net/sfc/efx/base/efx_filter.c:1097:
+ return (rc);
WARNING:SPACING: space prohibited between function name and open parenthesis '('
#1757: FILE: drivers/net/sfc/efx/base/efx_filter.c:1117:
+ EFX_STATIC_ASSERT(sizeof (sftp->sft_bitmap[0]) ==
WARNING:SPACING: space prohibited between function name and open parenthesis '('
#1758: FILE: drivers/net/sfc/efx/base/efx_filter.c:1118:
+ sizeof (uint32_t));
WARNING:SPACING: space prohibited between function name and open parenthesis '('
#1760: FILE: drivers/net/sfc/efx/base/efx_filter.c:1120:
+ (sftp->sft_size + (sizeof (uint32_t) * 8) - 1) / 8;
WARNING:SPACING: space prohibited between function name and open parenthesis '('
#1770: FILE: drivers/net/sfc/efx/base/efx_filter.c:1130:
+ sizeof (*sftp->sft_spec), sftp->sft_spec);
WARNING:SPACING: space prohibited between function name and open parenthesis '('
#1775: FILE: drivers/net/sfc/efx/base/efx_filter.c:1135:
+ EFSYS_KMEM_FREE(enp->en_esip, sizeof (siena_filter_t),
ERROR:ASSIGN_IN_IF: do not use assignment in if condition
#1805: FILE: drivers/net/sfc/efx/base/efx_filter.c:1165:
+ if ((key = siena_filter_build(&filter, spec)) == 0) {
ERROR:ASSIGN_IN_IF: do not use assignment in if condition
#1809: FILE: drivers/net/sfc/efx/base/efx_filter.c:1169:
+ if ((rc = siena_filter_push_entry(enp,
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#1820: FILE: drivers/net/sfc/efx/base/efx_filter.c:1180:
+ return (0);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#1830: FILE: drivers/net/sfc/efx/base/efx_filter.c:1190:
+ return (rc);
ERROR:ASSIGN_IN_IF: do not use assignment in if condition
#1854: FILE: drivers/net/sfc/efx/base/efx_filter.c:1214:
+ if ((rc = siena_filter_spec_from_gen_spec(&sf_spec, spec)) != 0)
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#1899: FILE: drivers/net/sfc/efx/base/efx_filter.c:1259:
+ return (0);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#1913: FILE: drivers/net/sfc/efx/base/efx_filter.c:1273:
+ return (rc);
ERROR:ASSIGN_IN_IF: do not use assignment in if condition
#1934: FILE: drivers/net/sfc/efx/base/efx_filter.c:1294:
+ if ((rc = siena_filter_spec_from_gen_spec(&sf_spec, spec)) != 0)
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#1954: FILE: drivers/net/sfc/efx/base/efx_filter.c:1314:
+ return (0);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#1962: FILE: drivers/net/sfc/efx/base/efx_filter.c:1322:
+ return (rc);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#2003: FILE: drivers/net/sfc/efx/base/efx_filter.c:1363:
+ return (0);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#2007: FILE: drivers/net/sfc/efx/base/efx_filter.c:1367:
+ return (rc);
CHECK:UNNECESSARY_PARENTHESES: Unnecessary parentheses around enp->en_intr
#2215: FILE: drivers/net/sfc/efx/base/efx_intr.c:282:
+ efx_intr_t *eip = &(enp->en_intr);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#2247: FILE: drivers/net/sfc/efx/base/efx_intr.c:314:
+ return (0);
CHECK:UNNECESSARY_PARENTHESES: Unnecessary parentheses around enp->en_intr
#2254: FILE: drivers/net/sfc/efx/base/efx_intr.c:321:
+ efx_intr_t *eip = &(enp->en_intr);
CHECK:UNNECESSARY_PARENTHESES: Unnecessary parentheses around enp->en_intr
#2295: FILE: drivers/net/sfc/efx/base/efx_intr.c:362:
+ efx_intr_t *eip = &(enp->en_intr);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#2310: FILE: drivers/net/sfc/efx/base/efx_intr.c:377:
+ return (ENOTSUP); /* avoid EFSYS_PROBE() */
WARNING:USE_NEGATIVE_ERRNO: return of an errno should typically be negative (ie: return -ENOTSUP)
#2310: FILE: drivers/net/sfc/efx/base/efx_intr.c:377:
+ return (ENOTSUP); /* avoid EFSYS_PROBE() */
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#2335: FILE: drivers/net/sfc/efx/base/efx_intr.c:402:
+ return (0);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#2340: FILE: drivers/net/sfc/efx/base/efx_intr.c:407:
+ return (rc);
CHECK:UNNECESSARY_PARENTHESES: Unnecessary parentheses around enp->en_intr
#2347: FILE: drivers/net/sfc/efx/base/efx_intr.c:414:
+ efx_intr_t *eip = &(enp->en_intr);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#2361: FILE: drivers/net/sfc/efx/base/efx_intr.c:428:
+ return (B_TRUE);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#2364: FILE: drivers/net/sfc/efx/base/efx_intr.c:431:
+ return (B_FALSE);
CHECK:UNNECESSARY_PARENTHESES: Unnecessary parentheses around enp->en_intr
#2373: FILE: drivers/net/sfc/efx/base/efx_intr.c:440:
+ efx_intr_t *eip = &(enp->en_intr);
CHECK:UNNECESSARY_PARENTHESES: Unnecessary parentheses around enp->en_intr
#2400: FILE: drivers/net/sfc/efx/base/efx_intr.c:467:
+ efx_intr_t *eip = &(enp->en_intr);
CHECK:SPACING: spaces preferred around that '*' (ctx:VxV)
#2537: FILE: drivers/net/sfc/efx/base/efx_mac.c:525:
+ __in_ecount(6*count) uint8_t const *addrs,
^
WARNING:BRACES: braces {} are not necessary for any arm of this statement
#2555: FILE: drivers/net/sfc/efx/base/efx_mac.c:543:
+ if (index < 128) {
[...]
+ } else {
[...]
CHECK:UNNECESSARY_PARENTHESES: Unnecessary parentheses around enp->en_port
#2569: FILE: drivers/net/sfc/efx/base/efx_mac.c:557:
+ efx_port_t *epp = &(enp->en_port);
WARNING:SPACING: space prohibited between function name and open parenthesis '('
#2577: FILE: drivers/net/sfc/efx/base/efx_mac.c:565:
+ memcpy(old_hash, epp->ep_multicst_hash, sizeof (old_hash));
ERROR:ASSIGN_IN_IF: do not use assignment in if condition
#2585: FILE: drivers/net/sfc/efx/base/efx_mac.c:573:
+ if ((rc = emop->emo_reconfigure(enp)) != 0)
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#2588: FILE: drivers/net/sfc/efx/base/efx_mac.c:576:
+ return (0);
WARNING:SPACING: space prohibited between function name and open parenthesis '('
#2593: FILE: drivers/net/sfc/efx/base/efx_mac.c:581:
+ memcpy(epp->ep_multicst_hash, old_hash, sizeof (old_hash));
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#2595: FILE: drivers/net/sfc/efx/base/efx_mac.c:583:
+ return (rc);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#2654: FILE: drivers/net/sfc/efx/base/efx_nic.c:49:
+ return (0);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#2659: FILE: drivers/net/sfc/efx/base/efx_nic.c:54:
+ return (0);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#2868: FILE: drivers/net/sfc/efx/base/efx_rx.c:348:
+ return (0);
CHECK:MACRO_ARG_REUSE: Macro argument reuse '_enp' - possible side-effects?
#2872: FILE: drivers/net/sfc/efx/base/efx_rx.c:352:
+#define EFX_RX_LFSR_HASH(_enp, _insert) \
+ do { \
+ efx_oword_t oword; \
+ \
+ EFX_BAR_READO((_enp), FR_AZ_RX_CFG_REG, &oword); \
+ EFX_SET_OWORD_FIELD(oword, FRF_BZ_RX_HASH_ALG, 0); \
+ EFX_SET_OWORD_FIELD(oword, FRF_BZ_RX_IP_HASH, 0); \
+ EFX_SET_OWORD_FIELD(oword, FRF_BZ_RX_TCP_SUP, 0); \
+ EFX_SET_OWORD_FIELD(oword, FRF_BZ_RX_HASH_INSRT_HDR, \
+ (_insert) ? 1 : 0); \
+ EFX_BAR_WRITEO((_enp), FR_AZ_RX_CFG_REG, &oword); \
+ \
+ if ((_enp)->en_family == EFX_FAMILY_SIENA) { \
+ EFX_BAR_READO((_enp), FR_CZ_RX_RSS_IPV6_REG3, \
+ &oword); \
+ EFX_SET_OWORD_FIELD(oword, \
+ FRF_CZ_RX_RSS_IPV6_THASH_ENABLE, 0); \
+ EFX_BAR_WRITEO((_enp), FR_CZ_RX_RSS_IPV6_REG3, \
+ &oword); \
+ } \
+ \
+ _NOTE(CONSTANTCONDITION) \
+ } while (B_FALSE)
CHECK:MACRO_ARG_REUSE: Macro argument reuse '_enp' - possible side-effects?
#2896: FILE: drivers/net/sfc/efx/base/efx_rx.c:376:
+#define EFX_RX_TOEPLITZ_IPV4_HASH(_enp, _insert, _ip, _tcp) \
+ do { \
+ efx_oword_t oword; \
+ \
+ EFX_BAR_READO((_enp), FR_AZ_RX_CFG_REG, &oword); \
+ EFX_SET_OWORD_FIELD(oword, FRF_BZ_RX_HASH_ALG, 1); \
+ EFX_SET_OWORD_FIELD(oword, FRF_BZ_RX_IP_HASH, \
+ (_ip) ? 1 : 0); \
+ EFX_SET_OWORD_FIELD(oword, FRF_BZ_RX_TCP_SUP, \
+ (_tcp) ? 0 : 1); \
+ EFX_SET_OWORD_FIELD(oword, FRF_BZ_RX_HASH_INSRT_HDR, \
+ (_insert) ? 1 : 0); \
+ EFX_BAR_WRITEO((_enp), FR_AZ_RX_CFG_REG, &oword); \
+ \
+ _NOTE(CONSTANTCONDITION) \
+ } while (B_FALSE)
CHECK:MACRO_ARG_REUSE: Macro argument reuse '_enp' - possible side-effects?
#2913: FILE: drivers/net/sfc/efx/base/efx_rx.c:393:
+#define EFX_RX_TOEPLITZ_IPV6_HASH(_enp, _ip, _tcp, _rc) \
+ do { \
+ efx_oword_t oword; \
+ \
+ EFX_BAR_READO((_enp), FR_CZ_RX_RSS_IPV6_REG3, &oword); \
+ EFX_SET_OWORD_FIELD(oword, \
+ FRF_CZ_RX_RSS_IPV6_THASH_ENABLE, 1); \
+ EFX_SET_OWORD_FIELD(oword, \
+ FRF_CZ_RX_RSS_IPV6_IP_THASH_ENABLE, (_ip) ? 1 : 0); \
+ EFX_SET_OWORD_FIELD(oword, \
+ FRF_CZ_RX_RSS_IPV6_TCP_SUPPRESS, (_tcp) ? 0 : 1); \
+ EFX_BAR_WRITEO((_enp), FR_CZ_RX_RSS_IPV6_REG3, &oword); \
+ \
+ (_rc) = 0; \
+ \
+ _NOTE(CONSTANTCONDITION) \
+ } while (B_FALSE)
WARNING:TYPO_SPELLING: 'psuedo' may be misspelled - perhaps 'pseudo'?
#2933: FILE: drivers/net/sfc/efx/base/efx_rx.c:413:
+ * Falcon/Siena psuedo-header
WARNING:TYPO_SPELLING: 'psuedo' may be misspelled - perhaps 'pseudo'?
#2937: FILE: drivers/net/sfc/efx/base/efx_rx.c:417:
+ * The psuedo-header is a byte array of one of the forms:
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#2958: FILE: drivers/net/sfc/efx/base/efx_rx.c:438:
+ return (ENOTSUP);
WARNING:USE_NEGATIVE_ERRNO: return of an errno should typically be negative (ie: return -ENOTSUP)
#2958: FILE: drivers/net/sfc/efx/base/efx_rx.c:438:
+ return (ENOTSUP);
CHECK:UNNECESSARY_PARENTHESES: Unnecessary parentheses around erp->er_mask
#2980: FILE: drivers/net/sfc/efx/base/efx_rx.c:460:
+ id = added & (erp->er_mask);
WARNING:SPACING: space prohibited between function name and open parenthesis '('
#2993: FILE: drivers/net/sfc/efx/base/efx_rx.c:473:
+ offset = id * sizeof (efx_qword_t);
CHECK:UNNECESSARY_PARENTHESES: Unnecessary parentheses around erp->er_mask
#2996: FILE: drivers/net/sfc/efx/base/efx_rx.c:476:
+ id = (id + 1) & (erp->er_mask);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#3047: FILE: drivers/net/sfc/efx/base/efx_rx.c:527:
+ return (0);
CHECK:UNNECESSARY_PARENTHESES: Unnecessary parentheses around enp->en_nic_cfg
#3082: FILE: drivers/net/sfc/efx/base/efx_rx.c:562:
+ efx_nic_cfg_t *encp = &(enp->en_nic_cfg);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#3138: FILE: drivers/net/sfc/efx/base/efx_rx.c:618:
+ return (0);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#3149: FILE: drivers/net/sfc/efx/base/efx_rx.c:629:
+ return (rc);
WARNING:SPACING: space prohibited between function name and open parenthesis '('
#3169: FILE: drivers/net/sfc/efx/base/efx_rx.c:649:
+ EFSYS_KMEM_FREE(enp->en_esip, sizeof (efx_rxq_t), erp);
WARNING:AVOID_EXTERNS: externs should be avoided in .c files
#3242: FILE: drivers/net/sfc/efx/base/efx_tx.c:90:
+ __checkReturn efx_rc_t
WARNING:AVOID_EXTERNS: externs should be avoided in .c files
#3250: FILE: drivers/net/sfc/efx/base/efx_tx.c:98:
+ void
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#3339: FILE: drivers/net/sfc/efx/base/efx_tx.c:601:
+ return (0);
CHECK:MACRO_ARG_REUSE: Macro argument reuse '_etp' - possible side-effects?
#3342: FILE: drivers/net/sfc/efx/base/efx_tx.c:604:
+#define EFX_TX_DESC(_etp, _addr, _size, _eop, _added) \
+ do { \
+ unsigned int id; \
+ size_t offset; \
+ efx_qword_t qword; \
+ \
+ id = (_added)++ & (_etp)->et_mask; \
+ offset = id * sizeof (efx_qword_t); \
+ \
+ EFSYS_PROBE5(tx_post, unsigned int, (_etp)->et_index, \
+ unsigned int, id, efsys_dma_addr_t, (_addr), \
+ size_t, (_size), boolean_t, (_eop)); \
+ \
+ EFX_POPULATE_QWORD_4(qword, \
+ FSF_AZ_TX_KER_CONT, (_eop) ? 0 : 1, \
+ FSF_AZ_TX_KER_BYTE_COUNT, (uint32_t)(_size), \
+ FSF_AZ_TX_KER_BUF_ADDR_DW0, \
+ (uint32_t)((_addr) & 0xffffffff), \
+ FSF_AZ_TX_KER_BUF_ADDR_DW1, \
+ (uint32_t)((_addr) >> 32)); \
+ EFSYS_MEM_WRITEQ((_etp)->et_esmp, offset, &qword); \
+ \
+ _NOTE(CONSTANTCONDITION) \
+ } while (B_FALSE)
CHECK:MACRO_ARG_REUSE: Macro argument reuse '_addr' - possible side-effects?
#3342: FILE: drivers/net/sfc/efx/base/efx_tx.c:604:
+#define EFX_TX_DESC(_etp, _addr, _size, _eop, _added) \
+ do { \
+ unsigned int id; \
+ size_t offset; \
+ efx_qword_t qword; \
+ \
+ id = (_added)++ & (_etp)->et_mask; \
+ offset = id * sizeof (efx_qword_t); \
+ \
+ EFSYS_PROBE5(tx_post, unsigned int, (_etp)->et_index, \
+ unsigned int, id, efsys_dma_addr_t, (_addr), \
+ size_t, (_size), boolean_t, (_eop)); \
+ \
+ EFX_POPULATE_QWORD_4(qword, \
+ FSF_AZ_TX_KER_CONT, (_eop) ? 0 : 1, \
+ FSF_AZ_TX_KER_BYTE_COUNT, (uint32_t)(_size), \
+ FSF_AZ_TX_KER_BUF_ADDR_DW0, \
+ (uint32_t)((_addr) & 0xffffffff), \
+ FSF_AZ_TX_KER_BUF_ADDR_DW1, \
+ (uint32_t)((_addr) >> 32)); \
+ EFSYS_MEM_WRITEQ((_etp)->et_esmp, offset, &qword); \
+ \
+ _NOTE(CONSTANTCONDITION) \
+ } while (B_FALSE)
CHECK:MACRO_ARG_REUSE: Macro argument reuse '_size' - possible side-effects?
#3342: FILE: drivers/net/sfc/efx/base/efx_tx.c:604:
+#define EFX_TX_DESC(_etp, _addr, _size, _eop, _added) \
+ do { \
+ unsigned int id; \
+ size_t offset; \
+ efx_qword_t qword; \
+ \
+ id = (_added)++ & (_etp)->et_mask; \
+ offset = id * sizeof (efx_qword_t); \
+ \
+ EFSYS_PROBE5(tx_post, unsigned int, (_etp)->et_index, \
+ unsigned int, id, efsys_dma_addr_t, (_addr), \
+ size_t, (_size), boolean_t, (_eop)); \
+ \
+ EFX_POPULATE_QWORD_4(qword, \
+ FSF_AZ_TX_KER_CONT, (_eop) ? 0 : 1, \
+ FSF_AZ_TX_KER_BYTE_COUNT, (uint32_t)(_size), \
+ FSF_AZ_TX_KER_BUF_ADDR_DW0, \
+ (uint32_t)((_addr) & 0xffffffff), \
+ FSF_AZ_TX_KER_BUF_ADDR_DW1, \
+ (uint32_t)((_addr) >> 32)); \
+ EFSYS_MEM_WRITEQ((_etp)->et_esmp, offset, &qword); \
+ \
+ _NOTE(CONSTANTCONDITION) \
+ } while (B_FALSE)
CHECK:MACRO_ARG_REUSE: Macro argument reuse '_eop' - possible side-effects?
#3342: FILE: drivers/net/sfc/efx/base/efx_tx.c:604:
+#define EFX_TX_DESC(_etp, _addr, _size, _eop, _added) \
+ do { \
+ unsigned int id; \
+ size_t offset; \
+ efx_qword_t qword; \
+ \
+ id = (_added)++ & (_etp)->et_mask; \
+ offset = id * sizeof (efx_qword_t); \
+ \
+ EFSYS_PROBE5(tx_post, unsigned int, (_etp)->et_index, \
+ unsigned int, id, efsys_dma_addr_t, (_addr), \
+ size_t, (_size), boolean_t, (_eop)); \
+ \
+ EFX_POPULATE_QWORD_4(qword, \
+ FSF_AZ_TX_KER_CONT, (_eop) ? 0 : 1, \
+ FSF_AZ_TX_KER_BYTE_COUNT, (uint32_t)(_size), \
+ FSF_AZ_TX_KER_BUF_ADDR_DW0, \
+ (uint32_t)((_addr) & 0xffffffff), \
+ FSF_AZ_TX_KER_BUF_ADDR_DW1, \
+ (uint32_t)((_addr) >> 32)); \
+ EFSYS_MEM_WRITEQ((_etp)->et_esmp, offset, &qword); \
+ \
+ _NOTE(CONSTANTCONDITION) \
+ } while (B_FALSE)
WARNING:SPACING: space prohibited between function name and open parenthesis '('
#3349: FILE: drivers/net/sfc/efx/base/efx_tx.c:611:
+ offset = id * sizeof (efx_qword_t); \
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#3397: FILE: drivers/net/sfc/efx/base/efx_tx.c:659:
+ return (0);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#3402: FILE: drivers/net/sfc/efx/base/efx_tx.c:664:
+ return (rc);
CHECK:UNNECESSARY_PARENTHESES: Unnecessary parentheses around enp->en_nic_cfg
#3441: FILE: drivers/net/sfc/efx/base/efx_tx.c:703:
+ efx_nic_cfg_t *encp = &(enp->en_nic_cfg);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#3470: FILE: drivers/net/sfc/efx/base/efx_tx.c:732:
+ return (0);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#3475: FILE: drivers/net/sfc/efx/base/efx_tx.c:737:
+ return (rc);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#3495: FILE: drivers/net/sfc/efx/base/efx_tx.c:757:
+ return (0);
CHECK:UNNECESSARY_PARENTHESES: Unnecessary parentheses around enp->en_nic_cfg
#3535: FILE: drivers/net/sfc/efx/base/efx_tx.c:797:
+ efx_nic_cfg_t *encp = &(enp->en_nic_cfg);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#3587: FILE: drivers/net/sfc/efx/base/efx_tx.c:849:
+ return (0);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#3596: FILE: drivers/net/sfc/efx/base/efx_tx.c:858:
+ return (rc);
WARNING:SPACING: space prohibited between function name and open parenthesis '('
#3622: FILE: drivers/net/sfc/efx/base/efx_tx.c:884:
+ offset = id * sizeof (efx_desc_t);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#3633: FILE: drivers/net/sfc/efx/base/efx_tx.c:895:
+ return (0);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#3637: FILE: drivers/net/sfc/efx/base/efx_tx.c:899:
+ return (rc);
WARNING:BLOCK_COMMENT_STYLE: Block comments use * on subsequent lines
#3751: FILE: drivers/net/sfc/efx/base/siena_flash.h:56:
+/*Structures supporting an arbitrary number of binary blobs in the flash image
+ intended to house code and tables for the satellite cpus*/
WARNING:BLOCK_COMMENT_STYLE: Block comments use a trailing */ on a separate line
#3751: FILE: drivers/net/sfc/efx/base/siena_flash.h:56:
+ intended to house code and tables for the satellite cpus*/
WARNING:LONG_LINE_COMMENT: line over 90 characters
#3803: FILE: drivers/net/sfc/efx/base/siena_flash.h:108:
+ efx_word_t hdr_version; /* this structure definition is version 1 */
WARNING:LONG_LINE_COMMENT: line over 90 characters
#3808: FILE: drivers/net/sfc/efx/base/siena_flash.h:113:
+ efx_word_t checksum; /* of whole header area + firmware image */
WARNING:LONG_LINE_COMMENT: line over 90 characters
#3811: FILE: drivers/net/sfc/efx/base/siena_flash.h:116:
+ efx_byte_t generation; /* Valid for medford, SBZ for earlier chips */
WARNING:LONG_LINE_COMMENT: line over 90 characters
#3816: FILE: drivers/net/sfc/efx/base/siena_flash.h:121:
+ efx_byte_t spi_rate; /* SPI rate for reading image, 0 is BootROM default */
WARNING:LONG_LINE_COMMENT: line over 90 characters
#3817: FILE: drivers/net/sfc/efx/base/siena_flash.h:122:
+ efx_byte_t spi_phase_adj; /* SPI SDO/SCL phase adjustment, 0 is default (no adj) */
WARNING:LONG_LINE_COMMENT: line over 90 characters
#3818: FILE: drivers/net/sfc/efx/base/siena_flash.h:123:
+ efx_word_t xpm_sector; /* The sector that contains the key, or 0xffff if unsigned (medford) SBZ (earlier) */
WARNING:LONG_LINE_COMMENT: line over 90 characters
#3830: FILE: drivers/net/sfc/efx/base/siena_flash.h:135:
+ efx_word_t length; /* of header area (i.e. not including VPD) */
WARNING:LONG_LINE_COMMENT: line over 90 characters
#3832: FILE: drivers/net/sfc/efx/base/siena_flash.h:137:
+ efx_byte_t csum; /* over header area (i.e. not including VPD) */
WARNING:LONG_LINE_COMMENT: line over 90 characters
#3868: FILE: drivers/net/sfc/efx/base/siena_flash.h:173:
+ efx_word_t length; /* of header area (i.e. not including VPD) */
WARNING:LONG_LINE_COMMENT: line over 90 characters
#3870: FILE: drivers/net/sfc/efx/base/siena_flash.h:175:
+ efx_byte_t csum; /* over header area (i.e. not including VPD) */
WARNING:LONG_LINE_COMMENT: line over 90 characters
#3883: FILE: drivers/net/sfc/efx/base/siena_flash.h:188:
+ efx_dword_t magic; /* = SIENA_MC_EXPROM_COMBO_MAGIC or SIENA_MC_EXPROM_COMBO_V2_MAGIC */
WARNING:LONG_LINE_COMMENT: line over 90 characters
#3888: FILE: drivers/net/sfc/efx/base/siena_flash.h:193:
+ efx_dword_t off1; /* offset of first byte to edit to combine images */
WARNING:LONG_LINE_COMMENT: line over 90 characters
#3889: FILE: drivers/net/sfc/efx/base/siena_flash.h:194:
+ efx_dword_t off2; /* offset of second byte to edit to combine images */
WARNING:LONG_LINE_COMMENT: line over 90 characters
#3892: FILE: drivers/net/sfc/efx/base/siena_flash.h:197:
+ efx_byte_t infoblk_len;/* length of space reserved for one infoblk structure */
WARNING:LONG_LINE_COMMENT: line over 90 characters
#3898: FILE: drivers/net/sfc/efx/base/siena_flash.h:203:
+ efx_dword_t off1; /* offset of first byte to edit to combine images */
WARNING:LONG_LINE_COMMENT: line over 90 characters
#3899: FILE: drivers/net/sfc/efx/base/siena_flash.h:204:
+ efx_dword_t off2; /* offset of second byte to edit to combine images */
WARNING:LONG_LINE_COMMENT: line over 90 characters
#3902: FILE: drivers/net/sfc/efx/base/siena_flash.h:207:
+ efx_byte_t infoblk_len;/* length of space reserved for one infoblk structure */
CHECK:UNNECESSARY_PARENTHESES: Unnecessary parentheses around enp->en_port
#4142: FILE: drivers/net/sfc/efx/base/siena_mac.c:41:
+ efx_port_t *epp = &(enp->en_port);
ERROR:ASSIGN_IN_IF: do not use assignment in if condition
#4146: FILE: drivers/net/sfc/efx/base/siena_mac.c:45:
+ if ((rc = siena_phy_get_link(enp, &sls)) != 0)
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#4154: FILE: drivers/net/sfc/efx/base/siena_mac.c:53:
+ return (0);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#4161: FILE: drivers/net/sfc/efx/base/siena_mac.c:60:
+ return (rc);
ERROR:ASSIGN_IN_IF: do not use assignment in if condition
#4176: FILE: drivers/net/sfc/efx/base/siena_mac.c:75:
+ if ((rc = siena_phy_get_link(enp, &sls)) != 0)
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#4181: FILE: drivers/net/sfc/efx/base/siena_mac.c:80:
+ return (0);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#4186: FILE: drivers/net/sfc/efx/base/siena_mac.c:85:
+ return (rc);
CHECK:UNNECESSARY_PARENTHESES: Unnecessary parentheses around enp->en_port
#4193: FILE: drivers/net/sfc/efx/base/siena_mac.c:92:
+ efx_port_t *epp = &(enp->en_port);
CHECK:SPACING: No space is necessary after a cast
#4203: FILE: drivers/net/sfc/efx/base/siena_mac.c:102:
+ (void) memset(payload, 0, sizeof (payload));
WARNING:SPACING: space prohibited between function name and open parenthesis '('
#4203: FILE: drivers/net/sfc/efx/base/siena_mac.c:102:
+ (void) memset(payload, 0, sizeof (payload));
CHECK:SPACING: No space is necessary after a cast
#4271: FILE: drivers/net/sfc/efx/base/siena_mac.c:170:
+ (void) memset(payload, 0, sizeof (payload));
WARNING:SPACING: space prohibited between function name and open parenthesis '('
#4271: FILE: drivers/net/sfc/efx/base/siena_mac.c:170:
+ (void) memset(payload, 0, sizeof (payload));
WARNING:SPACING: space prohibited between function name and open parenthesis '('
#4279: FILE: drivers/net/sfc/efx/base/siena_mac.c:178:
+ multicast_hash, sizeof (multicast_hash));
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#4288: FILE: drivers/net/sfc/efx/base/siena_mac.c:187:
+ return (0);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#4295: FILE: drivers/net/sfc/efx/base/siena_mac.c:194:
+ return (rc);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#4303: FILE: drivers/net/sfc/efx/base/siena_mac.c:202:
+ return (ENOTSUP);
WARNING:USE_NEGATIVE_ERRNO: return of an errno should typically be negative (ie: return -ENOTSUP)
#4303: FILE: drivers/net/sfc/efx/base/siena_mac.c:202:
+ return (ENOTSUP);
CHECK:UNNECESSARY_PARENTHESES: Unnecessary parentheses around enp->en_mcdi.em_emip
#4372: FILE: drivers/net/sfc/efx/base/siena_mcdi.c:60:
+ efx_mcdi_iface_t *emip = &(enp->en_mcdi.em_emip);
WARNING:SPACING: space prohibited between function name and open parenthesis '('
#4385: FILE: drivers/net/sfc/efx/base/siena_mcdi.c:73:
+ EFSYS_ASSERT3U(hdr_len, ==, sizeof (efx_dword_t));
WARNING:SPACING: space prohibited between function name and open parenthesis '('
#4390: FILE: drivers/net/sfc/efx/base/siena_mcdi.c:78:
+ for (pos = 0; pos < sdu_len; pos += sizeof (efx_dword_t)) {
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#4412: FILE: drivers/net/sfc/efx/base/siena_mcdi.c:100:
+ return (0);
CHECK:UNNECESSARY_PARENTHESES: Unnecessary parentheses around enp->en_mcdi.em_emip
#4414: FILE: drivers/net/sfc/efx/base/siena_mcdi.c:102:
+ efx_mcdi_iface_t *emip = &(enp->en_mcdi.em_emip);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#4427: FILE: drivers/net/sfc/efx/base/siena_mcdi.c:115:
+ return (0);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#4433: FILE: drivers/net/sfc/efx/base/siena_mcdi.c:121:
+ return (EINTR);
WARNING:USE_NEGATIVE_ERRNO: return of an errno should typically be negative (ie: return -EINTR)
#4433: FILE: drivers/net/sfc/efx/base/siena_mcdi.c:121:
+ return (EINTR);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#4435: FILE: drivers/net/sfc/efx/base/siena_mcdi.c:123:
+ return (EIO);
WARNING:USE_NEGATIVE_ERRNO: return of an errno should typically be negative (ie: return -EIO)
#4435: FILE: drivers/net/sfc/efx/base/siena_mcdi.c:123:
+ return (EIO);
CHECK:UNNECESSARY_PARENTHESES: Unnecessary parentheses around enp->en_mcdi.em_emip
#4443: FILE: drivers/net/sfc/efx/base/siena_mcdi.c:131:
+ efx_mcdi_iface_t *emip = &(enp->en_mcdi.em_emip);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#4451: FILE: drivers/net/sfc/efx/base/siena_mcdi.c:139:
+ return (EFX_DWORD_FIELD(hdr, MCDI_HEADER_RESPONSE) ? B_TRUE : B_FALSE);
CHECK:UNNECESSARY_PARENTHESES: Unnecessary parentheses around enp->en_mcdi.em_emip
#4461: FILE: drivers/net/sfc/efx/base/siena_mcdi.c:149:
+ efx_mcdi_iface_t *emip = &(enp->en_mcdi.em_emip);
WARNING:SPACING: space prohibited between function name and open parenthesis '('
#4469: FILE: drivers/net/sfc/efx/base/siena_mcdi.c:157:
+ for (pos = 0; pos < length; pos += sizeof (efx_dword_t)) {
WARNING:SPACING: space prohibited between function name and open parenthesis '('
#4473: FILE: drivers/net/sfc/efx/base/siena_mcdi.c:161:
+ MIN(sizeof (data), length - pos));
CHECK:UNNECESSARY_PARENTHESES: Unnecessary parentheses around enp->en_mcdi.em_emip
#4482: FILE: drivers/net/sfc/efx/base/siena_mcdi.c:170:
+ efx_mcdi_iface_t *emip = &(enp->en_mcdi.em_emip);
CHECK:SPACING: No space is necessary after a cast
#4513: FILE: drivers/net/sfc/efx/base/siena_mcdi.c:201:
+ (void) siena_mcdi_poll_reboot(enp);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#4515: FILE: drivers/net/sfc/efx/base/siena_mcdi.c:203:
+ return (0);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#4520: FILE: drivers/net/sfc/efx/base/siena_mcdi.c:208:
+ return (rc);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#4552: FILE: drivers/net/sfc/efx/base/siena_mcdi.c:240:
+ return (0);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#4557: FILE: drivers/net/sfc/efx/base/siena_mcdi.c:245:
+ return (rc);
CHECK:SPACING: spaces preferred around that '*' (ctx:ExV)
#4571: FILE: drivers/net/sfc/efx/base/siena_mcdi.c:259:
+ *timeoutp = SIENA_MCDI_CMD_TIMEOUT_US;
^
CHECK:UNNECESSARY_PARENTHESES: Unnecessary parentheses around enp->en_nic_cfg
#4622: FILE: drivers/net/sfc/efx/base/siena_nic.c:41:
+ efx_nic_cfg_t *encp = &(enp->en_nic_cfg);
ERROR:ASSIGN_IN_IF: do not use assignment in if condition
#4633: FILE: drivers/net/sfc/efx/base/siena_nic.c:52:
+ if ((rc = efx_mcdi_get_board_cfg(enp, &board_type,
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#4708: FILE: drivers/net/sfc/efx/base/siena_nic.c:127:
+ return (0);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#4715: FILE: drivers/net/sfc/efx/base/siena_nic.c:134:
+ return (rc);
CHECK:UNNECESSARY_PARENTHESES: Unnecessary parentheses around enp->en_nic_cfg
#4722: FILE: drivers/net/sfc/efx/base/siena_nic.c:141:
+ efx_nic_cfg_t *encp = &(enp->en_nic_cfg);
ERROR:ASSIGN_IN_IF: do not use assignment in if condition
#4726: FILE: drivers/net/sfc/efx/base/siena_nic.c:145:
+ if ((rc = efx_mcdi_get_phy_cfg(enp)) != 0)
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#4729: FILE: drivers/net/sfc/efx/base/siena_nic.c:148:
+ return (0);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#4734: FILE: drivers/net/sfc/efx/base/siena_nic.c:153:
+ return (rc);
CHECK:UNNECESSARY_PARENTHESES: Unnecessary parentheses around enp->en_port
#4741: FILE: drivers/net/sfc/efx/base/siena_nic.c:160:
+ efx_port_t *epp = &(enp->en_port);
CHECK:UNNECESSARY_PARENTHESES: Unnecessary parentheses around enp->en_nic_cfg
#4742: FILE: drivers/net/sfc/efx/base/siena_nic.c:161:
+ efx_nic_cfg_t *encp = &(enp->en_nic_cfg);
ERROR:ASSIGN_IN_IF: do not use assignment in if condition
#4751: FILE: drivers/net/sfc/efx/base/siena_nic.c:170:
+ if ((rc = efx_nic_biu_test(enp)) != 0)
ERROR:ASSIGN_IN_IF: do not use assignment in if condition
#4763: FILE: drivers/net/sfc/efx/base/siena_nic.c:182:
+ if ((rc = efx_mcdi_read_assertion(enp)) != 0)
ERROR:ASSIGN_IN_IF: do not use assignment in if condition
#4767: FILE: drivers/net/sfc/efx/base/siena_nic.c:186:
+ if ((rc = efx_mcdi_exit_assertion_handler(enp)) != 0)
ERROR:ASSIGN_IN_IF: do not use assignment in if condition
#4771: FILE: drivers/net/sfc/efx/base/siena_nic.c:190:
+ if ((rc = efx_mcdi_drv_attach(enp, B_TRUE)) != 0)
ERROR:ASSIGN_IN_IF: do not use assignment in if condition
#4774: FILE: drivers/net/sfc/efx/base/siena_nic.c:193:
+ if ((rc = siena_board_cfg(enp)) != 0)
ERROR:ASSIGN_IN_IF: do not use assignment in if condition
#4777: FILE: drivers/net/sfc/efx/base/siena_nic.c:196:
+ if ((rc = siena_phy_cfg(enp)) != 0)
ERROR:ASSIGN_IN_IF: do not use assignment in if condition
#4781: FILE: drivers/net/sfc/efx/base/siena_nic.c:200:
+ if ((rc = siena_nic_reset(enp)) != 0)
ERROR:ASSIGN_IN_IF: do not use assignment in if condition
#4783: FILE: drivers/net/sfc/efx/base/siena_nic.c:202:
+ if ((rc = siena_phy_get_link(enp, &sls)) != 0)
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#4790: FILE: drivers/net/sfc/efx/base/siena_nic.c:209:
+ return (0);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#4809: FILE: drivers/net/sfc/efx/base/siena_nic.c:228:
+ return (rc);
ERROR:ASSIGN_IN_IF: do not use assignment in if condition
#4822: FILE: drivers/net/sfc/efx/base/siena_nic.c:241:
+ if ((rc = efx_mcdi_read_assertion(enp)) != 0)
ERROR:ASSIGN_IN_IF: do not use assignment in if condition
#4824: FILE: drivers/net/sfc/efx/base/siena_nic.c:243:
+ if ((rc = efx_mcdi_exit_assertion_handler(enp)) != 0)
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#4846: FILE: drivers/net/sfc/efx/base/siena_nic.c:265:
+ return (0);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#4855: FILE: drivers/net/sfc/efx/base/siena_nic.c:274:
+ return (0);
ERROR:ASSIGN_IN_IF: do not use assignment in if condition
#4897: FILE: drivers/net/sfc/efx/base/siena_nic.c:316:
+ if ((rc = efx_mcdi_log_ctrl(enp)) != 0)
ERROR:ASSIGN_IN_IF: do not use assignment in if condition
#4909: FILE: drivers/net/sfc/efx/base/siena_nic.c:328:
+ if ((rc = siena_phy_reconfigure(enp)) != 0)
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#4914: FILE: drivers/net/sfc/efx/base/siena_nic.c:333:
+ return (0);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#4921: FILE: drivers/net/sfc/efx/base/siena_nic.c:340:
+ return (rc);
CHECK:SPACING: No space is necessary after a cast
#4935: FILE: drivers/net/sfc/efx/base/siena_nic.c:354:
+ (void) efx_mcdi_drv_attach(enp, B_FALSE);
CHECK:BRACES: braces {} should be used on all arms of this statement
#5041: FILE: drivers/net/sfc/efx/base/siena_phy.c:97:
+ if (fcntl == MC_CMD_FCNTL_OFF)
[...]
+ else if (fcntl == MC_CMD_FCNTL_RESPOND)
[...]
+ else if (fcntl == MC_CMD_FCNTL_BIDIR)
[...]
+ else {
[...]
CHECK:UNNECESSARY_PARENTHESES: Unnecessary parentheses around enp->en_port
#5059: FILE: drivers/net/sfc/efx/base/siena_phy.c:115:
+ efx_port_t *epp = &(enp->en_port);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#5118: FILE: drivers/net/sfc/efx/base/siena_phy.c:174:
+ return (0);
ERROR:ASSIGN_IN_IF: do not use assignment in if condition
#5121: FILE: drivers/net/sfc/efx/base/siena_phy.c:177:
+ if ((rc = siena_phy_verify(enp)) != 0)
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#5126: FILE: drivers/net/sfc/efx/base/siena_phy.c:182:
+ return (0);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#5131: FILE: drivers/net/sfc/efx/base/siena_phy.c:187:
+ return (rc);
CHECK:SPACING: No space is necessary after a cast
#5144: FILE: drivers/net/sfc/efx/base/siena_phy.c:200:
+ (void) memset(payload, 0, sizeof (payload));
WARNING:SPACING: space prohibited between function name and open parenthesis '('
#5144: FILE: drivers/net/sfc/efx/base/siena_phy.c:200:
+ (void) memset(payload, 0, sizeof (payload));
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#5175: FILE: drivers/net/sfc/efx/base/siena_phy.c:231:
+ return (0);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#5182: FILE: drivers/net/sfc/efx/base/siena_phy.c:238:
+ return (rc);
CHECK:UNNECESSARY_PARENTHESES: Unnecessary parentheses around enp->en_port
#5189: FILE: drivers/net/sfc/efx/base/siena_phy.c:245:
+ efx_port_t *epp = &(enp->en_port);
CHECK:SPACING: No space is necessary after a cast
#5200: FILE: drivers/net/sfc/efx/base/siena_phy.c:256:
+ (void) memset(payload, 0, sizeof (payload));
WARNING:SPACING: space prohibited between function name and open parenthesis '('
#5200: FILE: drivers/net/sfc/efx/base/siena_phy.c:256:
+ (void) memset(payload, 0, sizeof (payload));
CHECK:SPACING: No space is necessary after a cast
#5234: FILE: drivers/net/sfc/efx/base/siena_phy.c:290:
+ (void) memset(payload, 0, sizeof (payload));
WARNING:SPACING: space prohibited between function name and open parenthesis '('
#5234: FILE: drivers/net/sfc/efx/base/siena_phy.c:290:
+ (void) memset(payload, 0, sizeof (payload));
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#5250: FILE: drivers/net/sfc/efx/base/siena_phy.c:306:
+ return (0);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#5257: FILE: drivers/net/sfc/efx/base/siena_phy.c:313:
+ return (rc);
CHECK:SPACING: No space is necessary after a cast
#5270: FILE: drivers/net/sfc/efx/base/siena_phy.c:326:
+ (void) memset(payload, 0, sizeof (payload));
WARNING:SPACING: space prohibited between function name and open parenthesis '('
#5270: FILE: drivers/net/sfc/efx/base/siena_phy.c:326:
+ (void) memset(payload, 0, sizeof (payload));
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#5297: FILE: drivers/net/sfc/efx/base/siena_phy.c:353:
+ return (0);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#5306: FILE: drivers/net/sfc/efx/base/siena_phy.c:362:
+ return (rc);
ERROR:RETURN_PARENTHESES: return is not a function, parentheses are not required
#5316: FILE: drivers/net/sfc/efx/base/siena_phy.c:372:
+ return (ENOTSUP);
WARNING:USE_NEGATIVE_ERRNO: return of an errno should typically be negative (ie: return -ENOTSUP)
#5316: FILE: drivers/net/sfc/efx/base/siena_phy.c:372:
+ return (ENOTSUP);
CHECK:UNNECESSARY_PARENTHESES: Unnecessary parentheses around enp->en_nic_cfg
#5365: FILE: drivers/net/sfc/efx/base/siena_sram.c:40:
+ efx_nic_cfg_t *encp = &(enp->en_nic_cfg);
total: 124 errors, 61 warnings, 50 checks, 5187 lines checked
^ permalink raw reply [flat|nested] only message in thread