From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by dpdk.org (Postfix, from userid 33) id 3C9D94C93; Thu, 31 May 2018 13:19:05 +0200 (CEST) From: bugzilla@dpdk.org To: dev@dpdk.org Date: Thu, 31 May 2018 11:19:05 +0000 X-Bugzilla-Reason: AssignedTo X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: DPDK X-Bugzilla-Component: core X-Bugzilla-Version: 18.05 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: ferruh.yigit@intel.com X-Bugzilla-Status: CONFIRMED X-Bugzilla-Resolution: X-Bugzilla-Priority: Normal X-Bugzilla-Assigned-To: dev@dpdk.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: bug_id short_desc product version rep_platform op_sys bug_status bug_severity priority component assigned_to reporter target_milestone Message-ID: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://dpdk.org/tracker/ Auto-Submitted: auto-generated X-Auto-Response-Suppress: All MIME-Version: 1.0 Subject: [dpdk-dev] [Bug 58] cppcheck static analyzer warnings X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 31 May 2018 11:19:05 -0000 https://dpdk.org/tracker/show_bug.cgi?id=3D58 Bug ID: 58 Summary: cppcheck static analyzer warnings Product: DPDK Version: 18.05 Hardware: All OS: All Status: CONFIRMED Severity: normal Priority: Normal Component: core Assignee: dev@dpdk.org Reporter: ferruh.yigit@intel.com Target Milestone: --- There was already a mail in mail list to report this issue: https://dpdk.org/ml/archives/dev/2018-May/101961.html Some of the issues fixed in v18.05, but some still remain. Following is the list of the remaining issues: [app/test-pmd/cmdline_mtr.c:115]: (error) Memory leak: dscp_table [app/test-pmd/flowgen.c:160]: (error) Uninitialized variable: ol_flags [app/test-pmd/tm.c:594]: (error) Memory leak: tnp.shared_shaper_id [drivers/bus/dpaa/base/fman/fman.c:557]: (error) Uninitialized variable: __= if [drivers/bus/dpaa/base/qbman/qman.c:1220]: (error) Address of auto-variable 'p->shadow_dqrr[DQRR_PTR2IDX(dq)]' returned [drivers/bus/ifpga/ifpga_bus.c:436]: (warning) Possible null pointer dereference: c2 [drivers/crypto/ccp/ccp_pci.c:41]: (error) Resource leak: fp [drivers/crypto/dpaa_sec/dpaa_sec.c:662]: (error) Address of auto-variable 'ctx->job' returned [drivers/crypto/dpaa_sec/dpaa_sec.c:731]: (error) Address of auto-variable 'ctx->job' returned [drivers/crypto/dpaa_sec/dpaa_sec.c:826]: (error) Address of auto-variable 'ctx->job' returned [drivers/crypto/dpaa_sec/dpaa_sec.c:881]: (error) Address of auto-variable 'ctx->job' returned [drivers/crypto/dpaa_sec/dpaa_sec.c:1020]: (error) Address of auto-variable 'ctx->job' returned [drivers/crypto/dpaa_sec/dpaa_sec.c:1132]: (error) Address of auto-variable 'ctx->job' returned [drivers/crypto/dpaa_sec/dpaa_sec.c:1258]: (error) Address of auto-variable 'ctx->job' returned [drivers/crypto/dpaa_sec/dpaa_sec.c:1353]: (error) Address of auto-variable 'ctx->job' returned [drivers/crypto/dpaa_sec/dpaa_sec.c:1392]: (error) Address of auto-variable 'ctx->job' returned [drivers/net/avf/base/avf_adminq.c:301]: (error) Shifting signed 32-bit val= ue by 31 bits is undefined behaviour [drivers/net/avf/base/avf_adminq.c:336]: (error) Shifting signed 32-bit val= ue by 31 bits is undefined behaviour [drivers/net/avf/base/avf_adminq.c:298]: (error) Shifting signed 32-bit val= ue by 31 bits is undefined behaviour [drivers/net/avf/base/avf_adminq.c:333]: (error) Shifting signed 32-bit val= ue by 31 bits is undefined behaviour [drivers/net/avf/base/avf_common.c:367]: (error) Shifting signed 32-bit val= ue by 31 bits is undefined behaviour [drivers/net/avf/base/avf_common.c:364]: (error) Shifting signed 32-bit val= ue by 31 bits is undefined behaviour [drivers/net/axgbe/axgbe_dev.c:808]: (error) Shifting signed 32-bit value b= y 31 bits is undefined behaviour [drivers/net/axgbe/axgbe_dev.c] -> [drivers/net/axgbe/axgbe_dev.c]: (error) Invalid value: 0x0204_BUSY_WIDTH [drivers/net/axgbe/axgbe_ethdev.c] -> [drivers/net/axgbe/axgbe_ethdev.c]: (error) Invalid value: 0x0008_PR_WIDTH [drivers/net/axgbe/axgbe_i2c.c] -> [drivers/net/axgbe/axgbe_i2c.c]: (error) Invalid value: 0x006c_EN_WIDTH [drivers/net/axgbe/axgbe_phy_impl.c] -> [drivers/net/axgbe/axgbe_phy_impl.c= ]: (error) Invalid value: 0x0080_ID_WIDTH [drivers/net/axgbe/axgbe_rxtx.c:292]: (error) Shifting signed 32-bit value = by 31 bits is undefined behaviour [drivers/net/axgbe/axgbe_rxtx.c:592]: (error) Shifting signed 32-bit value = by 31 bits is undefined behaviour [drivers/net/axgbe/axgbe_rxtx.c] -> [drivers/net/axgbe/axgbe_rxtx.c]: (erro= r) Invalid value: 0x48_PRXQ_WIDTH [drivers/net/bnx2x/bnx2x.c:3995]: (error) Shifting signed 32-bit value by 31 bits is undefined behaviour [drivers/net/bnx2x/bnx2x.c:4000]: (error) Shifting signed 32-bit value by 31 bits is undefined behaviour [drivers/net/bnx2x/bnx2x.c:8729]: (error) Shifting signed 32-bit value by 31 bits is undefined behaviour [drivers/net/bnx2x/bnx2x.c:9765]: (error) Shifting signed 32-bit value by 31 bits is undefined behaviour [drivers/net/bnx2x/elink.c:1042]: (error) Shifting signed 32-bit value by 31 bits is undefined behaviour [drivers/net/bnx2x/elink.c:2711]: (error) Shifting signed 32-bit value by 31 bits is undefined behaviour [drivers/net/bnx2x/elink.c:9662]: (error) Shifting signed 32-bit value by 31 bits is undefined behaviour [drivers/net/bnx2x/elink.c:10295]: (error) Shifting signed 32-bit value by = 31 bits is undefined behaviour [drivers/net/bnxt/bnxt_ethdev.c:598]: (error) Shifting signed 32-bit value = by 31 bits is undefined behaviour [drivers/net/bnxt/bnxt_ethdev.c:638]: (error) Shifting signed 32-bit value = by 31 bits is undefined behaviour [drivers/net/bnxt/bnxt_rxr.c:486]: (error) Uninitialized variable: ag_cons [drivers/net/bnxt/bnxt_stats.c:211]: (error) Shifting signed 32-bit value b= y 31 bits is undefined behaviour [drivers/net/bnxt/bnxt_stats.c:248]: (error) Shifting signed 32-bit value b= y 31 bits is undefined behaviour [drivers/net/e1000/base/e1000_82575.c:2324]: (error) Shifting signed 32-bit value by 31 bits is undefined behaviour [drivers/net/e1000/base/e1000_82575.c:2326]: (error) Shifting signed 32-bit value by 31 bits is undefined behaviour [drivers/net/e1000/base/e1000_82575.c:2333]: (error) Shifting signed 32-bit value by 31 bits is undefined behaviour [drivers/net/e1000/base/e1000_82575.c:2335]: (error) Shifting signed 32-bit value by 31 bits is undefined behaviour [drivers/net/e1000/base/e1000_ich8lan.c:5169]: (error) Shifting signed 32-b= it value by 31 bits is undefined behaviour [drivers/net/e1000/igb_ethdev.c:4721]: (error) Shifting signed 32-bit value= by 31 bits is undefined behaviour [drivers/net/e1000/igb_pf.c:154]: (error) Shifting signed 32-bit value by 31 bits is undefined behaviour [drivers/net/e1000/igb_pf.c:156]: (error) Shifting signed 32-bit value by 31 bits is undefined behaviour [drivers/net/enic/base/vnic_dev.c:757]: (warning) Possible null pointer dereference: notify_addr [drivers/net/i40e/base/i40e_adminq.c:1094]: (error) Uninitialized variable:= ntu [drivers/net/i40e/base/i40e_adminq.c:1149]: (error) Uninitialized variable:= ntu [drivers/net/i40e/base/i40e_adminq.c:1157]: (error) Uninitialized variable:= ntu [drivers/net/i40e/i40e_ethdev.c:2070]: (error) Shifting 32-bit value by 36 = bits is undefined behaviour [drivers/net/i40e/i40e_ethdev.c:2070]: (error) Signed integer overflow for expression '1<bits[32]' accessed at index 9998, which is out of bounds. [drivers/net/qede/base/ecore_int.c:1079]: (error) Array 'sb_attn_sw->p_aeu_desc[i].bits[32]' accessed at index 9998, which is out of bounds. [drivers/net/qede/base/ecore_int.c:1387]: (error) Array 'aeu_descs[i].bits[= 32]' accessed at index 9998, which is out of bounds. [drivers/net/qede/base/ecore_int.c:1986]: (error) Shifting signed 32-bit va= lue by 31 bits is undefined behaviour [drivers/net/qede/base/ecore_int.c:1991]: (error) Shifting signed 32-bit va= lue by 31 bits is undefined behaviour [drivers/net/qede/base/ecore_l2.c:80]: (error) syntax error [drivers/net/qede/base/ecore_mcp.c:253]: (error) syntax error [drivers/net/qede/base/ecore_mng_tlv.c:1458]: (error) failed to expand 'OSAL_WARN', Wrong number of parameters for macro 'OSAL_WARN'. [drivers/net/qede/base/ecore_spq.c:590]: (error) syntax error [drivers/net/sfc/base/efx_ev.c:158]: (error) Uninitialized variable: eevop [drivers/net/sfc/base/efx_ev.c:161]: (error) Uninitialized variable: eevop [drivers/net/sfc/base/efx_intr.c:147]: (error) Uninitialized variable: eiop [drivers/net/sfc/base/efx_intr.c:150]: (error) Uninitialized variable: eiop [drivers/net/sfc/base/efx_mac.c:870]: (error) Uninitialized variable: emop [drivers/net/sfc/base/efx_mon.c:82]: (error) Uninitialized variable: emop [drivers/net/sfc/base/efx_phy.c:94]: (error) Uninitialized variable: epop [drivers/net/sfc/base/efx_rx.c:235]: (error) Uninitialized variable: erxop [drivers/net/sfc/base/efx_rx.c:238]: (error) Uninitialized variable: erxop [drivers/net/sfc/base/efx_tx.c:262]: (error) Uninitialized variable: etxop [drivers/net/sfc/base/efx_tx.c:265]: (error) Uninitialized variable: etxop [drivers/net/softnic/rte_eth_softnic_tm.c:2450]: (error) syntax error [drivers/net/tap/tap_bpf_program.c:109]: (error) Shifting signed 32-bit val= ue by 31 bits is undefined behaviour [drivers/net/tap/tap_netlink.c:233]: (warning) Possible null pointer dereference: data [drivers/net/tap/tap_tcmsgs.c:127]: (error) Uninitialized variable: opt [examples/bbdev_app/main.c:597]: (error) Memory pointed to by 'xstats' is f= reed twice. [examples/bbdev_app/main.c:604]: (error) Memory pointed to by 'xstats' is f= reed twice. [examples/flow_filtering/main.c:237]: (error) Signed integer overflow for expression '(192<<24)+(168<<16)'. [examples/flow_filtering/main.c:237]: (error) Signed integer overflow for expression '(192<<24)+(168<<16)+(1<<8)'. [examples/flow_filtering/main.c:237]: (error) Signed integer overflow for expression '(192<<24)+(168<<16)+(1<<8)+1'. [examples/vhost/main.c:388]: (error) Common realloc mistake: 'socket_files' nulled but not freed upon failure [kernel/linux/kni/ethtool/igb/e1000_82575.c:2270]: (error) Shifting signed 32-bit value by 31 bits is undefined behaviour [kernel/linux/kni/ethtool/igb/e1000_82575.c:2272]: (error) Shifting signed 32-bit value by 31 bits is undefined behaviour [kernel/linux/kni/ethtool/igb/e1000_82575.c:2279]: (error) Shifting signed 32-bit value by 31 bits is undefined behaviour [kernel/linux/kni/ethtool/igb/e1000_82575.c:2281]: (error) Shifting signed 32-bit value by 31 bits is undefined behaviour [kernel/linux/kni/ethtool/ixgbe/ixgbe_82599.c:1487]: (error) Shifting signed 32-bit value by 31 bits is undefined behaviour [lib/librte_acl/acl_gen.c:166]: (error) Shifting signed 32-bit value by 31 = bits is undefined behaviour [lib/librte_eal/common/rte_reciprocal.c:105]: (error) Shifting signed 32-bit value by 31 bits is undefined behaviour [lib/librte_eal/common/rte_service.c:750]: (warning) Possible null pointer dereference: f [lib/librte_eal/linuxapp/eal/eal_interrupts.c:423]: (error) syntax error [lib/librte_eal/linuxapp/eal/eal_memory.c:79]: (error) Uninitialized variab= le: tmp [lib/librte_eal/linuxapp/eal/eal_vfio.c:1803]: (error) Uninitialized variab= le: cur_grp [lib/librte_net/rte_net_crc.c:72]: (error) Shifting signed 32-bit value by = 31 bits is undefined behaviour [lib/librte_vhost/vdpa.c:74]: (error, inconclusive) Array 'vdpa_devices[102= 4]' accessed at index 1024, which is out of bounds. [test/test/test_reorder.c:272]: (error) Array 'robufs[8]' accessed at index= 8, which is out of bounds. --=20 You are receiving this mail because: You are the assignee for the bug.=