From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-pg1-f169.google.com (mail-pg1-f169.google.com [209.85.215.169]) by dpdk.org (Postfix) with ESMTP id 6F5861B76F for ; Sun, 23 Dec 2018 08:43:58 +0100 (CET) Received: by mail-pg1-f169.google.com with SMTP id m1so4403601pgq.8 for ; Sat, 22 Dec 2018 23:43:58 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20150623.gappssmtp.com; s=20150623; h=date:from:to:cc:subject:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=ZM01U6tFkUHNgTHWNm6Dbb58ZTRr7Q1OFf90sIdR0DY=; b=njkBpeeItZpq4rQ0/XC2+I2jEG90xMLo+TWqwpQEjwA1Uobjz5tDe1vSvq2cFjP/BY zrBit8We9YqLOZwJFB7EtDAgZStmNZqmGYbofdC5Udh2DEJlqr9zLDFsD5mIE0dKHICj ScFW98wbI7jvvISUNb91j2Zx1+EEsUAnWUHAeJmiM2xNPU8rbsLu5W0EUvCJ8GWC0oAp +nchuar45cuX3I4tVYOGBB8kyohYtIEu9ezLi9jQRkuBMub+XkWbgrp5HmnaEqkFkO3G a4BfC4fliQ370B7A1wZEVSMgsbkax8rW5XGK9B+UzZhnwOBA0jdjF6ci7Qo0d2bl/lef G8Lw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=ZM01U6tFkUHNgTHWNm6Dbb58ZTRr7Q1OFf90sIdR0DY=; b=W2pmnvYy6+cAT9wc+nn8MHb1pRso/GiWNNs9aFxW2ilyD7/xRhEGFltQrAqow1cnCV G+Ymte4XGJ8kMNmWq8LkygFFElxCuuMT3UdXM7lpvkCTr3az8bF5dQNmjflWItRNKhnP 8PRnrlFQs511L6qBaxEdXdgu8O/jiiquOwt4WrtJHXd0uLML6DULS5OCkquOm2t45Vjw BC5Cyoqq8N2nP/KNJyBivbUqukUKaNiQ1Jv2YXHqchypnYItzzPjPPxur1FNzsBRPf0+ 9XgHptv8xE9FPmroP9qmMnO1XCfwPFTdkyqgOt3mtPsrrf5t62Rv4HEjRTx+OnPxIC73 dVVA== X-Gm-Message-State: AJcUukdQVvWbU5LQ8harLEAG2R3A/px4tER998kLN+HdRcAfJRrRwLb1 Q/EkZ6Rk3eY84cv3WWVDKtcuAw== X-Google-Smtp-Source: ALg8bN7nFLOLuydFJkSQY4B63fUCKhrpnv3RJq4d4HEJtkze2YWf4zl9+2tbFcylksYodGJWuttC9g== X-Received: by 2002:a63:9809:: with SMTP id q9mr8474350pgd.109.1545551037485; Sat, 22 Dec 2018 23:43:57 -0800 (PST) Received: from xeon-e3 (204-195-22-127.wavecable.com. [204.195.22.127]) by smtp.gmail.com with ESMTPSA id h8sm29027157pgv.27.2018.12.22.23.43.57 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Sat, 22 Dec 2018 23:43:57 -0800 (PST) Date: Sat, 22 Dec 2018 23:43:50 -0800 From: Stephen Hemminger To: Haiyang Tan Cc: Cristian Dumitrescu , dev@dpdk.org Message-ID: <20181222234350.789e2a28@xeon-e3> In-Reply-To: <20181222121100.52827-1-haiyangtan@tencent.com> References: <20181222121100.52827-1-haiyangtan@tencent.com> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Subject: Re: [dpdk-dev] [PATCH] hash: fix possible uninitialized variable 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: Sun, 23 Dec 2018 07:43:58 -0000 On Sat, 22 Dec 2018 04:10:59 -0800 Haiyang Tan wrote: > The uninitialized field 'extra_flag' of hash_cuckoo_params may enable > certain feature silently. Typically, if bit0 of 'extra_flag' set, the > hardware transactional memory support will be enabled unexpectedly. > > Signed-off-by: Haiyang Tan This is not necessary. Structure initializations will fill in the other elements with zero. https://gcc.gnu.org/onlinedocs/gcc-4.9.0/gcc/Designated-Inits.html Omitted field members are implicitly initialized the same as objects that have static storage duration.