From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from NAM02-BL2-obe.outbound.protection.outlook.com (mail-bl2nam02on0065.outbound.protection.outlook.com [104.47.38.65]) by dpdk.org (Postfix) with ESMTP id E43E91B1A6 for ; Wed, 11 Oct 2017 07:05:06 +0200 (CEST) Received: from BN6PR03CA0066.namprd03.prod.outlook.com (10.173.137.28) by CY1PR03MB2364.namprd03.prod.outlook.com (10.166.207.151) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P256) id 15.20.77.7; Wed, 11 Oct 2017 05:05:05 +0000 Received: from BN1BFFO11FD021.protection.gbl (2a01:111:f400:7c10::1:109) by BN6PR03CA0066.outlook.office365.com (2603:10b6:404:4c::28) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P256) id 15.20.77.7 via Frontend Transport; Wed, 11 Oct 2017 05:05:05 +0000 Authentication-Results: spf=fail (sender IP is 192.88.158.2) smtp.mailfrom=nxp.com; caviumnetworks.com; dkim=none (message not signed) header.d=none; caviumnetworks.com; dmarc=fail action=none header.from=nxp.com; Received-SPF: Fail (protection.outlook.com: domain of nxp.com does not designate 192.88.158.2 as permitted sender) receiver=protection.outlook.com; client-ip=192.88.158.2; helo=az84smr01.freescale.net; Received: from az84smr01.freescale.net (192.88.158.2) by BN1BFFO11FD021.mail.protection.outlook.com (10.58.144.84) with Microsoft SMTP Server (version=TLS1_0, cipher=TLS_RSA_WITH_AES_256_CBC_SHA) id 15.20.77.10 via Frontend Transport; Wed, 11 Oct 2017 05:05:04 +0000 Received: from [10.232.14.39] ([10.232.14.39]) by az84smr01.freescale.net (8.14.3/8.14.0) with ESMTP id v9B54wEM003542; Tue, 10 Oct 2017 22:05:01 -0700 To: santosh , Thomas Monjalon CC: , , References: <20171010070155.17412-1-shreyansh.jain@nxp.com> <2102754.igz1rhL23C@xps> <7387c315-fd0f-a5a2-fdd9-1ae9aed69e9b@caviumnetworks.com> <1821646.02OIGBtUFx@xps> From: Shreyansh Jain Message-ID: <421a112e-69f1-b8bc-c863-cd08dad5cc7f@nxp.com> Date: Wed, 11 Oct 2017 10:47:11 +0530 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.3.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset="windows-1252"; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit X-EOPAttributedMessage: 0 X-Matching-Connectors: 131521719050917801; (91ab9b29-cfa4-454e-5278-08d120cd25b8); () X-Forefront-Antispam-Report: CIP:192.88.158.2; IPV:NLI; CTRY:US; EFV:NLI; SFV:NSPM; SFS:(10009020)(6009001)(336005)(39380400002)(346002)(376002)(2980300002)(1110001)(1109001)(339900001)(24454002)(189002)(377454003)(199003)(36756003)(93886005)(58126008)(230700001)(31696002)(316002)(31686004)(54906003)(69596002)(189998001)(65826007)(8936002)(5660300001)(65956001)(65806001)(81156014)(105606002)(6306002)(104016004)(97736004)(81166006)(106466001)(110136005)(2950100002)(8656003)(77096006)(76176999)(53376002)(2906002)(33646002)(6246003)(53936002)(4326008)(23746002)(54356999)(6666003)(64126003)(50986999)(966005)(85426001)(498600001)(47776003)(8676002)(229853002)(50466002)(86362001)(83506001)(356003)(68736007)(305945005); DIR:OUT; SFP:1101; SCL:1; SRVR:CY1PR03MB2364; H:az84smr01.freescale.net; FPR:; SPF:Fail; PTR:InfoDomainNonexistent; MX:1; A:1; LANG:en; X-Microsoft-Exchange-Diagnostics: 1; BN1BFFO11FD021; 1:ICfyBpu0iuOxR+pNUy41/qNRSow5/ZOOOQMQgHBB+XD7RQZOsUzH41a/JxbGUO/dJZoZFdLeYnSBcpvby8yLxf3Bl26PfXRVjUF7qQgRwVQqzYx2+ycell7PEw3OgzOr X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 47daf5ae-3029-4e7c-f648-08d51065a2bb X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(22001)(2017052603199)(201703131430075)(201703131517081); SRVR:CY1PR03MB2364; X-Microsoft-Exchange-Diagnostics: 1; CY1PR03MB2364; 3:GfDiSEa6BLwx0ULwMfQBxdH94wB0FFVcFYY7usIDXrpwJmXWEChTYyahtWtb//pFn2Vy2eYgQb9htq9GjbGIPL57eTZLs1pxOi7OxIZijIlajpncG+C77yNCxgcZLcANRYSyzdqp0KK0ZJN6pIG262Fs+5IT4H0aTsZns6PyUKSYybnE3YZl/9NgPMJl4zl1RNgHAok466OayJp8uPHVulp+CIj3GGQLY10eUmvf9cesKEtsJsnZ2n/2qaAyG5neokxoznAHBp1LgHoVZFrrZfuVyFZwUJYfyjJL7bPV54NmSiKPwVO9jpiXKjCXp8Qp/TdqreoaJpwx+UvK1nFuNg==; 25:DJQ9td2/6nyOEeOG8hy1XHFr6LpQlPggSlfTKsCCaSherLf39sWWp+9xvd+AWltmAQS2hzoLUc0Yen3H8GQuEay+XRISaWt7Isw5+IdWH90GMs8MjIutkNXWH6R0t5tcNL/1nVROmS5hW5mXiSgFXqe6IQ5oOqrzabzFDD/o07L50y3WFZyA0W0oPrXMT0H1aNY/t/Ea15djvMe3+Ooy1HVu+srN7gk2MfOTg22FBql2E3IcEup2EkEzcuH/urOo/Ug6+gIgLvuezZ6eIwwVVTKTCFdi93UJw4GDoBUud+Bn2nMpzHQOkfIAERRM259bikp/csoIkaKF43OD+F6j8w==; 31:XiAastsOBEoPDl0OWOcfmOBmk4D/8gfz7qk8RT4C5sIp8NyckHFjPGY+JND+Fv8okaOjHrNXWkLzqbkr5K4PqweYrPdH5Onn7ryWjZPD7wmZMO8RZgkjiZVoT5cXvn6HBRyrAn0VH0JsmLMUV4AubqNCP3HW1MeJIH87xsmUdW/7ZWJRyAiLflVk4gJ0iIRT46qoR7THkKMGMKTub+DZequ2i6IvYnpKYnA1SEr/NRY= X-MS-TrafficTypeDiagnostic: CY1PR03MB2364: X-Exchange-Antispam-Report-Test: UriScan:(185117386973197); X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(100000700101)(100105000095)(100000701101)(100105300095)(100000702101)(100105100095)(6095135)(2401047)(5005006)(8121501046)(10201501046)(93006095)(93001095)(3002001)(100000703101)(100105400095)(6055026)(6096035)(20161123565025)(20161123561025)(20161123556025)(20161123563025)(20161123559100)(201703131430075)(201703131448075)(201703131433075)(201703161259150)(201703151042153)(201708071742011)(100000704101)(100105200095)(100000705101)(100105500095); SRVR:CY1PR03MB2364; BCL:0; PCL:0; RULEID:(100000800101)(100110000095)(100000801101)(100110300095)(100000802101)(100110100095)(100000803101)(100110400095)(400006)(100000804101)(100110200095)(100000805101)(100110500095); SRVR:CY1PR03MB2364; X-Microsoft-Exchange-Diagnostics: 1; CY1PR03MB2364; 4:hqeZryZIdhOJls8qfhv+4nk8o9v1V+TF3isDgaWSM57YZt1yQA+nkjm0hyT0WgtBph4Kvgd2OIVDFsNjlAczugiyMWfvJ2dbauSyP2PxiABm9+vgwXoPKgC+s4HCXgsB8MFbB9zv0HBYZfC27HuVKxjbvXtJyEgQhZyDUaUiAL7GLwQpcgNmJccaNnvgyNQkZmYGS4AUtlCZ7uqPorJhdbd3dIbhjJdobM6SjgTu1cd0GgZZUCGzrwPmItSvtLQzsNJJ83gC8e17OteHH4W/sxJokQUXhos4MwzHP/p4KAI= X-Forefront-PRVS: 0457F11EAF X-Microsoft-Exchange-Diagnostics: =?Windows-1252?Q?1; CY1PR03MB2364; 23:JnhY8JUQoQSrzOpNjeyTIBbW+iY/F8+ezGcYG?= =?Windows-1252?Q?G0Gg5tox5rcysDUsbv2szTxikkH3ttUgKnByIRHNwUGW/VtDxn8PMfEj?= =?Windows-1252?Q?dAhZgbypJ3wcebWkccqrgX0YYMk9W61xLlNHfDqfmYKDrZ9L2lURthzj?= =?Windows-1252?Q?G2ZgpolYtJgzlZbJw6rtDOUKOuFXZR5YjNNMzvEKnycbL51PMtR+jwQU?= =?Windows-1252?Q?26rXPSsb217En34k2q9Sk4wbbOzr4HmI2OaQBtwWQq80Kjr6THRu00kI?= =?Windows-1252?Q?P29tVhxUKdr/K+h2KBkV4u2MRcicMj6uxuy33bv19W8Rr7D2yQNxKN9L?= =?Windows-1252?Q?iTJzNUHnFV2OnBYjwAqsrukOihIYBi7QP6/iu5D3Ct96m5FDdUbbqAiO?= =?Windows-1252?Q?ULFWREA0ledYQahpHj+/BfaJc7MTXDnGF4fYyvolTQoDGI0wm6tIe9WQ?= =?Windows-1252?Q?qDUmkUYTrtEmwuLxVqpNOG8AzBd3rDtJFECp7+G6CLXBkRlcYWm5k3Wh?= =?Windows-1252?Q?FLNl+3J4NW6reaccOZIKxpe1BkFoJzCyM0HDcBzk4Qjgi0WLsPLjU2Vh?= =?Windows-1252?Q?nejkT+uOWLTkeJ9/KAvH6OmT9pa4yFVo4tn5b54AAJcrmVfxB1tLzhKf?= =?Windows-1252?Q?WJa1i2OcRyRFmU04ivBFCoeQzE42VHUjKD9rG6NOG9l/buutixaKWktT?= =?Windows-1252?Q?ABpbLjQkSuyGgsYItydPDqz08cTWnL0gnDC/CjgbO/aBT2qjs6f8Stvd?= =?Windows-1252?Q?9CoZBl6AFRhNMIYph2ly258e/ijeZt0QtepHyu4U6kLo20bZzUTQAFpZ?= =?Windows-1252?Q?WYTk9i2XJeOL5AICKaL7d8PgQN/MRqZyurIDI6wEsN45oJGWqcLaMmRJ?= =?Windows-1252?Q?9DA0XZ3eXWVHqY5doXAtNtEiku1bXnP3DNNVvIRF0tbznm9mlQZCoL97?= =?Windows-1252?Q?E44mym7VlaBnmENqJxyZh5EeUzvpcpsADgFj/AbZEitXKQnubS95A1Tu?= =?Windows-1252?Q?ztaU2/E7HD+e/pG6UXhf81zhKCdRXBoWWvk4+kDFCrLPFDJE/hi2CqKr?= =?Windows-1252?Q?nEXfQvuM0539nwTeVGQS21dGkEJYDEsyErq9actG7jtRh470TVuu1ZpE?= =?Windows-1252?Q?HSG8Bdl2xUZhu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aW97fUbg4iyoOEZrRiU9JTvEFeiVpjPoob/2GjWr7Scc91pR469agaN52oMMJUGiKv1cgD7VUe7kHifLI=; 7:pN3jSCWm+w2pK0OTcBT2x2QEKsKxlizzYsEKaxYUXTr2pJQFsmy3eL9pmADQGMeLCZgJJeLT6pficGCxpYoGD5g8newoMFwgHuQTSTjdzGjXyK6/dbQShsPdAqDi6DivbgjyszXKQ7RGwAm1nfbB/aF+c6Qjf0hEx02/6P6TGSfkB01vWhYMDo8qAA/LhK3EhDPJCp8oQ5eOoJ/eNmNl0Hz7yFTf5kz8VI71QYmXAGg= SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-MS-Exchange-CrossTenant-OriginalArrivalTime: 11 Oct 2017 05:05:04.7797 (UTC) X-MS-Exchange-CrossTenant-Id: 5afe0b00-7697-4969-b663-5eab37d5f47e X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=5afe0b00-7697-4969-b663-5eab37d5f47e; Ip=[192.88.158.2]; Helo=[az84smr01.freescale.net] X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: CY1PR03MB2364 Subject: Re: [dpdk-dev] [PATCH] bus/dpaa: fix memory allocation during bus scan 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: Wed, 11 Oct 2017 05:05:07 -0000 On Tuesday 10 October 2017 10:25 PM, santosh wrote: > > On Tuesday 10 October 2017 09:47 PM, Thomas Monjalon wrote: >> 10/10/2017 16:05, santosh: >>> Hi Thomas, >>> >>> On Tuesday 10 October 2017 01:09 PM, Thomas Monjalon wrote: >>>> 10/10/2017 09:01, Shreyansh Jain: >>>>> Fixes: 5b22cf744689 ("bus/dpaa: introducing FMan configurations") >>>>> Fixes: 37f9b54bd3cf ("net/dpaa: support Tx and Rx queue setup") >>>> These lines should appear after the explanation. >>>> >>>>> Cc: shreyansh.jain@nxp.com >>>>> >>>>> With the IOVA auto detection changes, bus scan is performed before >>>>> memory initialization. DPAA bus scan must not use rte_malloc in >>>>> its path. >>>> If the scan has been broken by IOVA detection, you should reference >>>> IOVA in Fixes line, not DPAA. >>>> >>> hmm.. IOVA not breaking scanning!, Refer this [1]. >> It is breaking. A break is a behaviour or interface change. >> When moving init order, you break behaviour. >> I don't say it is bad. >> I say only it is the primary cause of this change. > > disagree!. Why so: Legacy PCI/bus scan implementation don't > use rte_ lib as they don;t need to.. Refer [1] for detailing. > However, dpaa is and that we agree to align with legacy. > So its a open question : Who fixes who? Just because PCI/bus-scan didn't use rte_malloc didn't mean that no one else can use it. For DPAA, the case was different and ideally I shouldn't have used rte_malloc. [1] was a discussion based on FSLMC and that was incorrect implementation. But, that is not a general case. If we go by pre-IOVA patch era: -> Subsystem A initialized -> Subsystem B initialized -> bus scan `-> implementation free to use all initialized subsystem post-IOVA era -> Subsystem A initialized -> bus scan `-> implementation free to use all initialized subsystem -> Subsystem B initialized Essentially, it means IOVA made a change in the expected behavior of the implementation. For case of DPAA, as that was still in development, it certainly can be said that it should have been fixed within dev cycle itself. That was the prime reason I used 'Fixes' to my own patches in v1 of this patch. But that said, I agree with what Thomas is saying. Fixes is only indicative of which patched changed the status-quo. And it helps maintainers know dependency tree. In this case, DPAA patches came *before* IOVA was added and hence the mistake in committed version came out *after* IOVA patches. > >> The Fixes: line is also a help when backporting patches. >> This patch needs to be backported only if IOVA patch is also backported. > > IMO, would prefer backport: rather fixes: tag in above case, more verbose I guess. > >>> We(me/hemant) has discussed about same on thread[1] and agreed to >>> do respective changes and remove rte_ memory dependency from code base >>> at scan time.. >>> >>> Thanks. >>> >>> [1] http://dpdk.org/dev/patchwork/patch/26764/ >> You already discussed about this issue, fine. >> >> Santosh, as you insist to talk again about it, one more comment: >> >> It is very good to have discussions on the mailing list. > > Thanks, That makes me think that I didn't break, indeed did what was needed in agnostic way. Again, IOVA patch changes status quo, but that was a known fact and it was missed by DPAA patches. Now, for maintenance reasons, "Fixes" should actually be IOVA patch. I am not sure why you disagree with that. > >> It would be perfect if all these informations were explicitly given >> in the commit messages. >> For instance, saying that the scan cannot use rte_malloc anymore is >> a valuable tip for other developpers. > > Agree, but scan wasn;t using for PCI/bus case.. so one can;t be sure whether to > mention or not.. >