Show a patch.

GET /api/patches/41059/
HTTP 200 OK
Allow: GET, PUT, PATCH, HEAD, OPTIONS
Content-Type: application/json
Vary: Accept

{
    "id": 41059,
    "url": "http://patches.dpdk.org/api/patches/41059/",
    "web_url": "http://patches.dpdk.org/patch/41059/",
    "project": {
        "id": 1,
        "url": "http://patches.dpdk.org/api/projects/1/",
        "name": "DPDK",
        "link_name": "dpdk",
        "list_id": "dev.dpdk.org",
        "list_email": "dev@dpdk.org",
        "web_url": "http://core.dpdk.org",
        "scm_url": "git://dpdk.org/dpdk",
        "webscm_url": "http://git.dpdk.org/dpdk"
    },
    "msgid": "<1528892062-4997-26-git-send-email-tomaszx.jozwiak@intel.com>",
    "date": "2018-06-13T12:14:09",
    "name": "[v3,25/38] crypto/qat: remove incorrect usage of bundle number",
    "commit_ref": null,
    "pull_url": null,
    "state": "accepted",
    "archived": true,
    "hash": "466e8ac307007f5a9a5c1b98a61cb0e859210d1f",
    "submitter": {
        "id": 949,
        "url": "http://patches.dpdk.org/api/people/949/",
        "name": "Tomasz Jozwiak",
        "email": "tomaszx.jozwiak@intel.com"
    },
    "delegate": {
        "id": 22,
        "url": "http://patches.dpdk.org/api/users/22/",
        "username": "pdelarag",
        "first_name": "Pablo",
        "last_name": "de Lara Guarch",
        "email": "pablo.de.lara.guarch@intel.com"
    },
    "mbox": "http://patches.dpdk.org/patch/41059/mbox/",
    "series": [
        {
            "id": 111,
            "url": "http://patches.dpdk.org/api/series/111/",
            "web_url": "http://patches.dpdk.org/project/dpdk/list/?series=111",
            "date": "2018-06-13T12:13:44",
            "name": "crypto/qat: refactor to support multiple services",
            "version": 3,
            "mbox": "http://patches.dpdk.org/series/111/mbox/"
        }
    ],
    "comments": "http://patches.dpdk.org/api/patches/41059/comments/",
    "check": "success",
    "checks": "http://patches.dpdk.org/api/patches/41059/checks/",
    "tags": {},
    "headers": {
        "X-Mailman-Version": "2.1.15",
        "X-ExtLoop1": "1",
        "Errors-To": "dev-bounces@dpdk.org",
        "X-Amp-Result": "SKIPPED(no attachment in message)",
        "X-Mailer": "git-send-email 2.7.4",
        "Received": [
            "from [92.243.14.124] (localhost [127.0.0.1])\n\tby dpdk.org (Postfix) with ESMTP id 005F31EFE7;\n\tWed, 13 Jun 2018 14:15:37 +0200 (CEST)",
            "from mga12.intel.com (mga12.intel.com [192.55.52.136])\n\tby dpdk.org (Postfix) with ESMTP id 5F7181EF7E\n\tfor <dev@dpdk.org>; Wed, 13 Jun 2018 14:15:03 +0200 (CEST)",
            "from fmsmga001.fm.intel.com ([10.253.24.23])\n\tby fmsmga106.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384;\n\t13 Jun 2018 05:15:01 -0700",
            "from tjozwiax-mobl.ger.corp.intel.com (HELO localhost.localdomain)\n\t([10.103.104.42])\n\tby fmsmga001.fm.intel.com with ESMTP; 13 Jun 2018 05:14:58 -0700"
        ],
        "References": "<1523040732-3290-1-git-send-email-fiona.trahe@intel.com>\n\t<1528892062-4997-1-git-send-email-tomaszx.jozwiak@intel.com>",
        "X-BeenThere": "dev@dpdk.org",
        "Message-Id": "<1528892062-4997-26-git-send-email-tomaszx.jozwiak@intel.com>",
        "X-IronPort-AV": "E=Sophos;i=\"5.51,218,1526367600\"; d=\"scan'208\";a=\"63727768\"",
        "List-Id": "DPDK patches and discussions <dev.dpdk.org>",
        "Precedence": "list",
        "From": "Tomasz Jozwiak <tomaszx.jozwiak@intel.com>",
        "X-Original-To": "patchwork@dpdk.org",
        "List-Post": "<mailto:dev@dpdk.org>",
        "Return-Path": "<dev-bounces@dpdk.org>",
        "Sender": "\"dev\" <dev-bounces@dpdk.org>",
        "List-Help": "<mailto:dev-request@dpdk.org?subject=help>",
        "In-Reply-To": "<1528892062-4997-1-git-send-email-tomaszx.jozwiak@intel.com>",
        "List-Subscribe": "<https://dpdk.org/ml/listinfo/dev>,\n\t<mailto:dev-request@dpdk.org?subject=subscribe>",
        "To": "fiona.trahe@intel.com,\n\ttomaszx.jozwiak@intel.com,\n\tdev@dpdk.org",
        "Delivered-To": "patchwork@dpdk.org",
        "List-Unsubscribe": "<https://dpdk.org/ml/options/dev>,\n\t<mailto:dev-request@dpdk.org?subject=unsubscribe>",
        "Date": "Wed, 13 Jun 2018 14:14:09 +0200",
        "X-Amp-File-Uploaded": "False",
        "List-Archive": "<http://dpdk.org/ml/archives/dev/>",
        "Subject": "[dpdk-dev] [PATCH v3 25/38] crypto/qat: remove incorrect usage of\n\tbundle number"
    },
    "content": "From: Fiona Trahe <fiona.trahe@intel.com>\n\nAs bundle_num is included in qat_gen1_qps static array\nthere shouldn't be a multiplier used in qat_qps_per_service()\nThen removed ADF_NUM_BUNDLES_PER_DEV as no longer used.\nAlso renamed ADF_MAX_QPS_PER_BUNDLE to ADF_MAX_QPS_ON_ANY_SERVICE\nand reduced from 4 to 2 which is enough for all current devices.\n\nSigned-off-by: Fiona Trahe <fiona.trahe@intel.com>\n---\n .../qat/qat_adf/adf_transport_access_macros.h |  5 ++---\n drivers/crypto/qat/qat_common.c               |  4 ++--\n drivers/crypto/qat/qat_device.h               |  4 ++--\n drivers/crypto/qat/qat_qp.c                   | 19 ++++---------------\n drivers/crypto/qat/qat_qp.h                   |  2 +-\n 5 files changed, 11 insertions(+), 23 deletions(-)",
    "diff": "diff --git a/drivers/crypto/qat/qat_adf/adf_transport_access_macros.h b/drivers/crypto/qat/qat_adf/adf_transport_access_macros.h\nindex 2136d54ab..1eef5513f 100644\n--- a/drivers/crypto/qat/qat_adf/adf_transport_access_macros.h\n+++ b/drivers/crypto/qat/qat_adf/adf_transport_access_macros.h\n@@ -50,9 +50,8 @@\n #define ADF_MAX_RING_SIZE ADF_RING_SIZE_4M\n #define ADF_DEFAULT_RING_SIZE ADF_RING_SIZE_16K\n \n-#define ADF_NUM_BUNDLES_PER_DEV         1\n-/* Maximum number of qps for any service type */\n-#define ADF_MAX_QPS_PER_BUNDLE\t\t4\n+/* Maximum number of qps on a device for any service type */\n+#define ADF_MAX_QPS_ON_ANY_SERVICE\t2\n #define ADF_RING_DIR_TX\t\t\t0\n #define ADF_RING_DIR_RX\t\t\t1\n \ndiff --git a/drivers/crypto/qat/qat_common.c b/drivers/crypto/qat/qat_common.c\nindex f1759ea76..5d6779757 100644\n--- a/drivers/crypto/qat/qat_common.c\n+++ b/drivers/crypto/qat/qat_common.c\n@@ -67,7 +67,7 @@ void qat_stats_get(struct qat_pci_device *dev,\n \t}\n \n \tqp = dev->qps_in_use[service];\n-\tfor (i = 0; i < ADF_MAX_QPS_PER_BUNDLE; i++) {\n+\tfor (i = 0; i < ADF_MAX_QPS_ON_ANY_SERVICE; i++) {\n \t\tif (qp[i] == NULL) {\n \t\t\tPMD_DRV_LOG(DEBUG, \"Service %d Uninitialised qp %d\",\n \t\t\t\t\tservice, i);\n@@ -94,7 +94,7 @@ void qat_stats_reset(struct qat_pci_device *dev,\n \t}\n \n \tqp = dev->qps_in_use[service];\n-\tfor (i = 0; i < ADF_MAX_QPS_PER_BUNDLE; i++) {\n+\tfor (i = 0; i < ADF_MAX_QPS_ON_ANY_SERVICE; i++) {\n \t\tif (qp[i] == NULL) {\n \t\t\tPMD_DRV_LOG(DEBUG, \"Service %d Uninitialised qp %d\",\n \t\t\t\t\tservice, i);\ndiff --git a/drivers/crypto/qat/qat_device.h b/drivers/crypto/qat/qat_device.h\nindex fd1819354..fd20a0147 100644\n--- a/drivers/crypto/qat/qat_device.h\n+++ b/drivers/crypto/qat/qat_device.h\n@@ -44,7 +44,7 @@ struct qat_pci_device {\n \tuint8_t attached : 1;\n \t/**< Flag indicating the device is attached */\n \n-\tstruct qat_qp *qps_in_use[QAT_MAX_SERVICES][ADF_MAX_QPS_PER_BUNDLE];\n+\tstruct qat_qp *qps_in_use[QAT_MAX_SERVICES][ADF_MAX_QPS_ON_ANY_SERVICE];\n \t/**< links to qps set up for each service, index same as on API */\n \n \t/* Data relating to symmetric crypto service */\n@@ -59,7 +59,7 @@ struct qat_pci_device {\n \n struct qat_gen_hw_data {\n \tenum qat_device_gen dev_gen;\n-\tconst struct qat_qp_hw_data (*qp_hw_data)[ADF_MAX_QPS_PER_BUNDLE];\n+\tconst struct qat_qp_hw_data (*qp_hw_data)[ADF_MAX_QPS_ON_ANY_SERVICE];\n };\n \n extern struct qat_gen_hw_data qp_gen_config[];\ndiff --git a/drivers/crypto/qat/qat_qp.c b/drivers/crypto/qat/qat_qp.c\nindex f26fd0900..9938c1493 100644\n--- a/drivers/crypto/qat/qat_qp.c\n+++ b/drivers/crypto/qat/qat_qp.c\n@@ -29,7 +29,7 @@\n \n __extension__\n const struct qat_qp_hw_data qat_gen1_qps[QAT_MAX_SERVICES]\n-\t\t\t\t\t [ADF_MAX_QPS_PER_BUNDLE] = {\n+\t\t\t\t\t [ADF_MAX_QPS_ON_ANY_SERVICE] = {\n \t/* queue pairs which provide an asymmetric crypto service */\n \t[QAT_SERVICE_ASYMMETRIC] = {\n \t\t{\n@@ -42,14 +42,11 @@ const struct qat_qp_hw_data qat_gen1_qps[QAT_MAX_SERVICES]\n \n \t\t}, {\n \t\t\t.service_type = QAT_SERVICE_ASYMMETRIC,\n+\t\t\t.hw_bundle_num = 0,\n \t\t\t.tx_ring_num = 1,\n \t\t\t.rx_ring_num = 9,\n \t\t\t.tx_msg_size = 64,\n \t\t\t.rx_msg_size = 32,\n-\t\t}, {\n-\t\t\t.service_type = QAT_SERVICE_INVALID,\n-\t\t}, {\n-\t\t\t.service_type = QAT_SERVICE_INVALID,\n \t\t}\n \t},\n \t/* queue pairs which provide a symmetric crypto service */\n@@ -69,10 +66,6 @@ const struct qat_qp_hw_data qat_gen1_qps[QAT_MAX_SERVICES]\n \t\t\t.rx_ring_num = 11,\n \t\t\t.tx_msg_size = 128,\n \t\t\t.rx_msg_size = 32,\n-\t\t}, {\n-\t\t\t.service_type = QAT_SERVICE_INVALID,\n-\t\t}, {\n-\t\t\t.service_type = QAT_SERVICE_INVALID,\n \t\t}\n \t},\n \t/* queue pairs which provide a compression service */\n@@ -91,10 +84,6 @@ const struct qat_qp_hw_data qat_gen1_qps[QAT_MAX_SERVICES]\n \t\t\t.rx_ring_num = 15,\n \t\t\t.tx_msg_size = 128,\n \t\t\t.rx_msg_size = 32,\n-\t\t}, {\n-\t\t\t.service_type = QAT_SERVICE_INVALID,\n-\t\t}, {\n-\t\t\t.service_type = QAT_SERVICE_INVALID,\n \t\t}\n \t}\n };\n@@ -118,10 +107,10 @@ int qat_qps_per_service(const struct qat_qp_hw_data *qp_hw_data,\n {\n \tint i, count;\n \n-\tfor (i = 0, count = 0; i < ADF_MAX_QPS_PER_BUNDLE; i++)\n+\tfor (i = 0, count = 0; i < ADF_MAX_QPS_ON_ANY_SERVICE; i++)\n \t\tif (qp_hw_data[i].service_type == service)\n \t\t\tcount++;\n-\treturn count * ADF_NUM_BUNDLES_PER_DEV;\n+\treturn count;\n }\n \n static const struct rte_memzone *\ndiff --git a/drivers/crypto/qat/qat_qp.h b/drivers/crypto/qat/qat_qp.h\nindex 73888b805..6f07bd67c 100644\n--- a/drivers/crypto/qat/qat_qp.h\n+++ b/drivers/crypto/qat/qat_qp.h\n@@ -90,7 +90,7 @@ struct qat_qp {\n \t/**< qat device this qp is on */\n } __rte_cache_aligned;\n \n-extern const struct qat_qp_hw_data qat_gen1_qps[][ADF_MAX_QPS_PER_BUNDLE];\n+extern const struct qat_qp_hw_data qat_gen1_qps[][ADF_MAX_QPS_ON_ANY_SERVICE];\n \n uint16_t\n qat_enqueue_op_burst(void *qp, void **ops, uint16_t nb_ops);\n",
    "prefixes": [
        "v3",
        "25/38"
    ]
}