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 9E273A0588; Thu, 16 Apr 2020 16:31:46 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 81F3C1DB2E; Thu, 16 Apr 2020 16:31:46 +0200 (CEST) Received: from mga06.intel.com (mga06.intel.com [134.134.136.31]) by dpdk.org (Postfix) with ESMTP id 8A7C51DB2D for ; Thu, 16 Apr 2020 16:31:44 +0200 (CEST) IronPort-SDR: bsZUilm1o3GUbQgortEwVhS5zZfuaHYdVeKI/CSAKqxEJE6phkdG0uZd2I6SZUFGM3mLyE8ffz t4DLbFAqJZzg== X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga005.jf.intel.com ([10.7.209.41]) by orsmga104.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 16 Apr 2020 07:31:43 -0700 IronPort-SDR: inh9QsIQXoB2/aiEddGD18e4UhhfJyKE1lE4arm8TPLrhr8Ctaid3fmsy1mnS0AoW2s/+YZlBA ZhYbK+uLo8pg== X-IronPort-AV: E=Sophos;i="5.72,391,1580803200"; d="scan'208";a="427850216" Received: from bricha3-mobl.ger.corp.intel.com ([10.251.93.194]) by orsmga005-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-SHA; 16 Apr 2020 07:31:41 -0700 Date: Thu, 16 Apr 2020 15:31:38 +0100 From: Bruce Richardson To: "Trahe, Fiona" Cc: Akhil Goyal , "Dybkowski, AdamX" , "dev@dpdk.org" , Shally Verma Message-ID: <20200416143138.GA1695@bricha3-MOBL.ger.corp.intel.com> References: <20200408125101.25764-1-adamx.dybkowski@intel.com> <20200408125101.25764-3-adamx.dybkowski@intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Subject: Re: [dpdk-dev] [PATCH v2 2/2] test/compress: im buffer too small - add unit tests 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 Thu, Apr 16, 2020 at 11:26:46AM +0000, Trahe, Fiona wrote: > > > > -----Original Message----- > > From: Akhil Goyal > > Sent: Thursday, April 16, 2020 11:25 AM > > To: Trahe, Fiona ; Dybkowski, AdamX ; > > dev@dpdk.org > > Cc: Shally Verma > > Subject: RE: [PATCH v2 2/2] test/compress: im buffer too small - add unit tests > > > > Hi Fiona, > > > > > > Hi Akhil, > > > > > > > > > > > Hi Fiona/Adam, > > > > > > > > > This patch adds a new test suite for verification of the "internal > > > > > QAT IM buffer too small" case handling. These unit tests are > > > > > specific to the QAT PMD only - that's why they are contained in > > > > > a separate test suite. > > > > > > > > > > Signed-off-by: Adam Dybkowski > > > > > --- > > > > > > > > Why do we need to have separate testsuite for QAT? > > > > Can't we have a single one and based on capability of the driver, > > > > Determine which tests need to be skipped in case they are not supported. > > > > This would create a mess in the longer run just like cryptodev. > > > > > > > > Please fix this, we cannot take this patch as is. > > > > > > [Fiona] Yes, I understand your concern and we considered including in the main > > > suite. > > > However these tests are not based on something that can be > > > checked in capabilities. They are tests to hone in on a specific corner case > > > based on a QAT limitation in its intermediate buffer size. So some of the > > > tests are to validate that the recent changes we made in the PMD correctly > > > work around that limitation, but other tests are negative and expected to fail > > > as provoking a corner-case that still exists. Other devices would probably not fail > > > the same tests. > > > > Does that mean that all PMDs will pass with the newly added testcase which is for > > A corner case in QAT. If that is the case what is the issue in adding that in the main > > Test suite. It will get passed in all PMDs, isn't it? Am I missing something? > > > > I believe we should not have PMD specific test suites, rather it should be based on > > Capabilities to identify the cases which should be run for that particular PMD. > [Fiona] yes, several of the cases should pass on all PMDs. > So we could move those into the main suite. > But what to do about the negative tests? > Example: If a very large data buffer is passed to QAT to compress with dyn compression, it will get > split in the PMD into many smaller requests to the hardware. However if the number > of requests is bigger than can fit on the qp then this will never succeed. The test > validates that the PMD behaves appropriately in this expected error case. That same > case would probably not have an error on another device. Maybe we should just leave out > such negative tests, but I find them useful as they validate the known behaviour. > The buffer size used in the test is based on the known size QAT can handle and the > corner case in which QAT will return an error. > > I see 4 options to handle this: > 1. Leave out those tests > 2. Use a qat-specific test suite only for negative cases which are constructed based on specific qat internal meta-data. > 3. Include the negative tests in the main suite, but only run them on QAT (by checking driver type) > 4. include the negative tests in the main suite, run them on all, expecting a FAIL from QAT and a PASS from other devices. > > My preference is for 2. > But up to you. > While not something for this release, perhaps in future cryptodev could implement a "selftest()" callback API like rawdev does [1], which allows drivers to implement their own specific test cases too. [1] http://doc.dpdk.org/api-20.02/rte__rawdev_8h.html#a776edaa7060fc6a9d66e00f84132e140