From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from NAM03-CO1-obe.outbound.protection.outlook.com (mail-co1nam03on0054.outbound.protection.outlook.com [104.47.40.54]) by dpdk.org (Postfix) with ESMTP id 99BF01DBF; Mon, 18 Dec 2017 08:57:54 +0100 (CET) Received: from BN6PR03CA0059.namprd03.prod.outlook.com (10.173.137.21) by CY1PR0301MB0729.namprd03.prod.outlook.com (10.160.159.147) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P256) id 15.20.302.9; Mon, 18 Dec 2017 07:57:52 +0000 Received: from BN1BFFO11OLC001.protection.gbl (2a01:111:f400:7c10::1:145) by BN6PR03CA0059.outlook.office365.com (2603:10b6:404:4c::21) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384) id 15.20.323.15 via Frontend Transport; Mon, 18 Dec 2017 07:57:52 +0000 Authentication-Results: spf=fail (sender IP is 192.88.168.50) smtp.mailfrom=nxp.com; nxp.com; dkim=none (message not signed) header.d=none;nxp.com; dmarc=fail action=none header.from=nxp.com; Received-SPF: Fail (protection.outlook.com: domain of nxp.com does not designate 192.88.168.50 as permitted sender) receiver=protection.outlook.com; client-ip=192.88.168.50; helo=tx30smr01.am.freescale.net; Received: from tx30smr01.am.freescale.net (192.88.168.50) by BN1BFFO11OLC001.mail.protection.outlook.com (10.58.145.12) with Microsoft SMTP Server (version=TLS1_0, cipher=TLS_RSA_WITH_AES_256_CBC_SHA) id 15.20.302.6 via Frontend Transport; Mon, 18 Dec 2017 07:57:40 +0000 Received: from bf-netperf1.ap.freescale.net (bf-netperf1.ap.freescale.net [10.232.134.28]) by tx30smr01.am.freescale.net (8.14.3/8.14.0) with ESMTP id vBI7vl6E011541; Mon, 18 Dec 2017 00:57:48 -0700 From: Hemant Agrawal To: CC: , , , , Jun Yang Date: Mon, 18 Dec 2017 13:26:45 +0530 Message-ID: <1513583809-3926-1-git-send-email-hemant.agrawal@nxp.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1513169578-28440-1-git-send-email-hemant.agrawal@nxp.com> References: <1513169578-28440-1-git-send-email-hemant.agrawal@nxp.com> X-EOPAttributedMessage: 0 X-Matching-Connectors: 131580574609984214; (91ab9b29-cfa4-454e-5278-08d120cd25b8); () X-Forefront-Antispam-Report: CIP:192.88.168.50; IPV:NLI; CTRY:US; EFV:NLI; SFV:NSPM; SFS:(10009020)(336005)(396003)(376002)(39860400002)(39380400002)(346002)(2980300002)(1110001)(1109001)(339900001)(189003)(199004)(16586007)(316002)(8936002)(50226002)(68736007)(48376002)(85426001)(51416003)(4326008)(54906003)(77096006)(498600001)(53936002)(86362001)(97736004)(8656006)(575784001)(6666003)(105606002)(5660300001)(8676002)(47776003)(81156014)(104016004)(81166006)(36756003)(2906002)(2351001)(106466001)(50466002)(305945005)(356003)(6916009)(2950100002)(76176011); DIR:OUT; SFP:1101; SCL:1; SRVR:CY1PR0301MB0729; H:tx30smr01.am.freescale.net; FPR:; SPF:Fail; PTR:InfoDomainNonexistent; MX:1; A:1; LANG:en; X-Microsoft-Exchange-Diagnostics: 1; BN1BFFO11OLC001; 1:5YyTWPCk2xef/2Bb+MbOSLzUVl2xtqUkaWQPpNpLZ9wlHnkM/q0ZMuPTxB+HSfkh438dnmvaqfj/uAdfKI8kQV13E1fmv95UtiiGW+yUpY+keY2vGAKu3bcApirYdWBC MIME-Version: 1.0 Content-Type: text/plain X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 3fc11f5b-3350-411a-4ad6-08d545ed036f X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(5600026)(4604075)(4534020)(4628075)(201703131517081)(2017052603307); SRVR:CY1PR0301MB0729; X-Microsoft-Exchange-Diagnostics: 1; CY1PR0301MB0729; 3:KO6Ekdki0Mf/e6mYlTYX8nrROPSl5nnKIhn/DQVmCpT1AQkQHnOJ5fqfOH0syq1vnyafZsKCoJ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X5r39v+T1m+evX9bchMxPYKo7l8bWlbmi2SOPdgwZRYJtybCEEk6rwgQeTGA184LMWW5rreQhT00//LLw5ZExWRSGg/MNNneqOCSxHUW+RJ4fmdw+9DKY3lyLF/uCVghnzwvw0f987el6ygNL7hCjnLJTI+DxRoyegdcdyAt4L4ga0zbTGlwDc5MdcKgzvNaaSpXP66WWCjXiqceVeDPy6BoxSOM/2dmwSq0Uu1w9ZYhAFGE5b516sa1p8Q28ASW0i4a3Iq7ah X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:(185117386973197)(275809806118684)(228905959029699); X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(6095135)(2401047)(5005006)(8121501046)(3231023)(3002001)(93006095)(93001095)(10201501046)(6055026)(6096035)(20161123561025)(20161123565025)(20161123556025)(20161123559100)(201703131430075)(201703131433075)(201703131448075)(201703161259150)(201703151042153)(20161123563025)(201708071742011); SRVR:CY1PR0301MB0729; BCL:0; PCL:0; RULEID:(100000803101)(100110400095)(400006); SRVR:CY1PR0301MB0729; X-Forefront-PRVS: 0525BB0ADF X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; CY1PR0301MB0729; 23:g7Fzxp2T1MxBP4AT1FEzKd8/Egv4gzu1xywLgSZ?= =?us-ascii?Q?1nruLOfTzwgAzOha7aQVITAWYyM+R8dAcP4gbYWNfGRIWRdbJyUwN7VnsYqP?= =?us-ascii?Q?m4D74eY4qbv5woIWQdCgU8y6c9HdSp1jGTcXNGVZXHN7XIZgu30m9GwijT3f?= =?us-ascii?Q?niT/o0ALsonEM7lRYpMh3dqimK5lB63A/XlCVw1q53cu43+A0cls62JPXzej?= =?us-ascii?Q?BWzZtjou78ikBk5PnYHr9tO50Nd4+h8w/DgJH/8m4K9TPwpmXhmbL/fAkjfw?= =?us-ascii?Q?I3G1KMuq7yUVqzCKR1HgKyDlV1+/OvnOHSpFWqL1Mdi19JYK1e0181qj86z1?= =?us-ascii?Q?nSv02G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UZl3sVnw5P7oLqz5F8LeCeUHRzeIRgfM58SEHs0Z4t4jCAWYUGwJO3mbFh4aKxLhKr+UEjhe3iOox/St8NJptm2eb/jdE2LDhfJYPVc0xLNyX6pX256u4giHpo/HszVMuFIyrLHe0vsxnv0Ut+nXkrDjSLqTmfaP7v5YUgxvfFwVv0FrfphxZilS4RS1x054ndMhh0nCDqNDRc9vE7m0YSAPcQGxjd9eY5GNUJd2WMMRsFwYe0Eys/jvIoBT8w+1z34DT4=; 5:7uFWl7TT1FZTZEeb7FiHPSRIfKPm59/EzxHlEtR4d3xJUoLYtNza2LkcQRsx6D6h7lAxABmUH7MMB8VwnRU05cvGlzEPOb78IuH8vTFJ6/W6PkREr3H86DPPGm9qI5cvkbO1n7XD+fKJAQtmbc6gkiqbTX3xWusbL3ko44GFIec=; 24:HaftvP5HHiKWRvN9OYHHumGK5D5K0LeZ9J/rfPUOpchZLAS7qCqgC2iLLkTTHqIlQsjGklYb0DXZNtcrWZy1jeAyQjTklUVyvc4RM2esTdA=; 7:ZZrd7oLEXJWiw5fMZ+weAnGaUI7nWiXkzdp6+AfnvIAXYY31/VGf758ru7ualHI+LygDKnELJSM25CuX3M97QMzHNvlW2WhIPH5GJ7MbmLUSanHb8EnMZ8xgTPN5ewfxks1RR4S6tcKQgkLvqPokP9B+a3/yBJrGYSsyZGzJUIsvYOQ4WboDerUJ/aspt/TyK7z2JR7trbfFmnPxj2jevEQkCVZB4rfudND9PTXe330VsjWTbfwnxd2Kn3LNskfi SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-MS-Exchange-CrossTenant-OriginalArrivalTime: 18 Dec 2017 07:57:40.8268 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 3fc11f5b-3350-411a-4ad6-08d545ed036f X-MS-Exchange-CrossTenant-Id: 5afe0b00-7697-4969-b663-5eab37d5f47e X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=5afe0b00-7697-4969-b663-5eab37d5f47e; Ip=[192.88.168.50]; Helo=[tx30smr01.am.freescale.net] X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: CY1PR0301MB0729 Subject: [dpdk-stable] [PATCH v3 1/5] pmdinfogen: fix cross compilation for ARM BE X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches for DPDK stable branches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 18 Dec 2017 07:57:55 -0000 Cross compiling DPDK for BE mode on ARM results into errors "PMDINFO portal/dpaa2_hw_dpio.o.pmd.c No drivers registered" The original code assumes the sh_size to be 32 bit, while it can be Elf32_Word or Elf64_Xword based on 32bit or 64 bit systems. This patches replaces the sh_size conversion routines to use ADDR_SIZE Fixes: 98b0fdb0ffc6 ("pmdinfogen: add buildtools and pmdinfogen utility") Cc: Neil Horman Cc: stable@dpdk.org Signed-off-by: Jun Yang Signed-off-by: Hemant Agrawal Acked-by: Bruce Richardson Acked-by: Neil Horman --- buildtools/pmdinfogen/pmdinfogen.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/buildtools/pmdinfogen/pmdinfogen.c b/buildtools/pmdinfogen/pmdinfogen.c index 96ccbf3..b07dbcf 100644 --- a/buildtools/pmdinfogen/pmdinfogen.c +++ b/buildtools/pmdinfogen/pmdinfogen.c @@ -158,7 +158,8 @@ static int parse_elf(struct elf_info *info, const char *filename) * There are more than 64k sections, * read count from .sh_size. */ - info->num_sections = TO_NATIVE(endian, 32, sechdrs[0].sh_size); + info->num_sections = + TO_NATIVE(endian, ADDR_SIZE, sechdrs[0].sh_size); } else { info->num_sections = hdr->e_shnum; } @@ -181,7 +182,7 @@ static int parse_elf(struct elf_info *info, const char *filename) sechdrs[i].sh_offset = TO_NATIVE(endian, ADDR_SIZE, sechdrs[i].sh_offset); sechdrs[i].sh_size = - TO_NATIVE(endian, 32, sechdrs[i].sh_size); + TO_NATIVE(endian, ADDR_SIZE, sechdrs[i].sh_size); sechdrs[i].sh_link = TO_NATIVE(endian, 32, sechdrs[i].sh_link); sechdrs[i].sh_info = -- 2.7.4