From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id 03821A04BC; Mon, 28 Sep 2020 00:05:30 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 7FC751D5EA; Mon, 28 Sep 2020 00:05:28 +0200 (CEST) Received: from mail-pj1-f65.google.com (mail-pj1-f65.google.com [209.85.216.65]) by dpdk.org (Postfix) with ESMTP id 0DE991D5E9 for ; Mon, 28 Sep 2020 00:05:26 +0200 (CEST) Received: by mail-pj1-f65.google.com with SMTP id u3so2450586pjr.3 for ; Sun, 27 Sep 2020 15:05:25 -0700 (PDT) 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=wk+VQ/EOJy7+oSaMEq4HmoC+4dmuPcwrdi4Lg3vK1Q0=; b=UEIO00pwWpIBzo6vgn5rvo9xOuYXkRxbdAHjKBnT51YxTscERDHvi2RzehpUu7nYz3 uTvaWNsQmXu2TssmB/NMS/NuQjCT9gLBb8ZnFSWXL25xwWMDadZJQAjf4vGRLsma/hjj Rob7bV85kS7Eosj9Spw/eEDbx2woVuvsr4pIY+ZO9ExumpJ+4Y7RMnoj3GSysQFm3ybw eesEXf+NoBWm8NpOZDlLp9+ZUo+vJMsG+4EYcKm6VXJsjxnqH+u5PH9tsh0fQUJaLAWp hGrtPo6kVKWUPDB5HTE4IiG7EJ7malDOgAQRcweul6sojt5N01NzVF5KGKYstPbk0FJ4 KnBg== 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=wk+VQ/EOJy7+oSaMEq4HmoC+4dmuPcwrdi4Lg3vK1Q0=; b=bbL2SBBXBfh+LVkhZcg14t9zgxixAK0KX6X2BAkI3yvUgpfzxt7/nBhxR2Orq5Gx5y 7+BLHJMlREsFb/VCeMY6yjIDRCybomKIy7+T/fnLJvFBNS6S1qgbR6YrblFjaMG3eZ+n sQrhjlTSULOZFiOmpOsMQlycDBaNIH6Z7LhOWVV93lgA+Og6wLutpmhGADbHZMzDPDNp +t0o/K1EL2gw0MUCaDgjpoknAexgMyrrUHZHX9vjfXn1y2vwm42ZWwGS85+gIdtoHxBD g+BszuOtRBpVkUAjLViDSljAmgZjKMTGBIPLsiLvBjoHl9g1RRsLNFq+Tk/Er9rBba6q LSOA== X-Gm-Message-State: AOAM531A5rkv1fnJ6zagqk1Kw7vU+gwvHmf/6q4OsrdhK68a/JwJUKp8 gGJxX9Ieo7XiBzBQFasOVnhsJg== X-Google-Smtp-Source: ABdhPJwfiRvHIp/ePUAURoNjnoLq+hnu9ZtjMTGCHERCpLFcRQg+PdFwW2NEMeKHoF0x99V+42EDTA== X-Received: by 2002:a17:90a:d813:: with SMTP id a19mr6460315pjv.115.1601244324144; Sun, 27 Sep 2020 15:05:24 -0700 (PDT) Received: from hermes.local (204-195-22-127.wavecable.com. [204.195.22.127]) by smtp.gmail.com with ESMTPSA id z7sm7774926pgc.35.2020.09.27.15.05.23 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 27 Sep 2020 15:05:23 -0700 (PDT) Date: Sun, 27 Sep 2020 15:05:15 -0700 From: Stephen Hemminger To: Dmitry Kozlyuk Cc: dev@dpdk.org, Neil Horman Message-ID: <20200927150515.35f67fcc@hermes.local> In-Reply-To: <20200927214732.12783-2-dmitry.kozliuk@gmail.com> References: <20200708212335.25338-1-dmitry.kozliuk@gmail.com> <20200927214732.12783-1-dmitry.kozliuk@gmail.com> <20200927214732.12783-2-dmitry.kozliuk@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Subject: Re: [dpdk-dev] [PATCH v5 1/3] pmdinfogen: add Python implementation 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: , Errors-To: dev-bounces@dpdk.org Sender: "dev" On Mon, 28 Sep 2020 00:47:30 +0300 Dmitry Kozlyuk wrote: > Using a high-level, interpreted language simplifies maintenance and > build process. Furthermore, ELF handling is delegated to pyelftools > package. Original logic is kept, the copyright recognizes that. > > Signed-off-by: Dmitry Kozlyuk Looks good, a couple little nits. Yapf flags this as unnecessary spacing: + @property + def value(self): + data = self._image._image.get_section(self._symbol["st_shndx"]).data() + base = self._symbol["st_value"] + return data[base : base + self.size] ^^^ Python lint complains about missing docstrings, which doesn't matter but it also shows: $ pylint3 buildtools/pmdinfogen.py | grep -v docstring ************* Module pmdinfogen buildtools/pmdinfogen.py:27:15: W0212: Access to a protected member _image of a client class (protected-access) buildtools/pmdinfogen.py:34:11: C1801: Do not use `len(SEQUENCE)` to determine if a sequence is empty (len-as-condition) buildtools/pmdinfogen.py:50:4: R1710: Either all return statements in a function should return an expression, or none of them should. (inconsistent-return-statements) buildtools/pmdinfogen.py:107:12: W0212: Access to a protected member _load_pci_ids of a client class (protected-access) ------------------------------------------------------------------ Your code has been rated at 7.93/10 (previous run: 7.93/10, +0.00)