Patch Detail
get:
Show a patch.
patch:
Update a patch.
put:
Update a patch.
GET /api/patches/73773/?format=api
http://patchwork.dpdk.org/api/patches/73773/?format=api", "web_url": "http://patchwork.dpdk.org/project/dpdk/patch/20200710171946.23246-6-hemant.agrawal@nxp.com/", "project": { "id": 1, "url": "http://patchwork.dpdk.org/api/projects/1/?format=api", "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", "list_archive_url": "https://inbox.dpdk.org/dev", "list_archive_url_format": "https://inbox.dpdk.org/dev/{}", "commit_url_format": "" }, "msgid": "<20200710171946.23246-6-hemant.agrawal@nxp.com>", "list_archive_url": "https://inbox.dpdk.org/dev/20200710171946.23246-6-hemant.agrawal@nxp.com", "date": "2020-07-10T17:19:43", "name": "[v2,6/9] bus/dpaa: add Virtual Storage Profile port init", "commit_ref": null, "pull_url": null, "state": "superseded", "archived": true, "hash": "9e991130fbc8a157838e90b9a0b190407909fb5a", "submitter": { "id": 477, "url": "http://patchwork.dpdk.org/api/people/477/?format=api", "name": "Hemant Agrawal", "email": "hemant.agrawal@nxp.com" }, "delegate": { "id": 319, "url": "http://patchwork.dpdk.org/api/users/319/?format=api", "username": "fyigit", "first_name": "Ferruh", "last_name": "Yigit", "email": "ferruh.yigit@amd.com" }, "mbox": "http://patchwork.dpdk.org/project/dpdk/patch/20200710171946.23246-6-hemant.agrawal@nxp.com/mbox/", "series": [ { "id": 10958, "url": "http://patchwork.dpdk.org/api/series/10958/?format=api", "web_url": "http://patchwork.dpdk.org/project/dpdk/list/?series=10958", "date": "2020-07-10T17:19:38", "name": "[v2,1/9] net/dpaa: support Rxq and Txq info routines", "version": 2, "mbox": "http://patchwork.dpdk.org/series/10958/mbox/" } ], "comments": "http://patchwork.dpdk.org/api/patches/73773/comments/", "check": "fail", "checks": "http://patchwork.dpdk.org/api/patches/73773/checks/", "tags": {}, "related": [], "headers": { "Return-Path": "<dev-bounces@dpdk.org>", "X-Original-To": "patchwork@inbox.dpdk.org", "Delivered-To": "patchwork@inbox.dpdk.org", "Received": [ "from dpdk.org (dpdk.org [92.243.14.124])\n\tby inbox.dpdk.org (Postfix) with ESMTP id 4ACDBA052A;\n\tFri, 10 Jul 2020 19:24:25 +0200 (CEST)", "from [92.243.14.124] (localhost [127.0.0.1])\n\tby dpdk.org (Postfix) with ESMTP id 906901DDCC;\n\tFri, 10 Jul 2020 19:24:14 +0200 (CEST)", "from inva020.nxp.com (inva020.nxp.com [92.121.34.13])\n by dpdk.org (Postfix) with ESMTP id 6355B1DDB1\n for <dev@dpdk.org>; Fri, 10 Jul 2020 19:24:13 +0200 (CEST)", "from inva020.nxp.com (localhost [127.0.0.1])\n by inva020.eu-rdc02.nxp.com (Postfix) with ESMTP id 2A8F11A0489;\n Fri, 10 Jul 2020 19:24:13 +0200 (CEST)", "from invc005.ap-rdc01.nxp.com (invc005.ap-rdc01.nxp.com\n [165.114.16.14])\n by inva020.eu-rdc02.nxp.com (Postfix) with ESMTP id 7724C1A04A5;\n Fri, 10 Jul 2020 19:24:11 +0200 (CEST)", "from bf-netperf1.ap.freescale.net (bf-netperf1.ap.freescale.net\n [10.232.133.63])\n by invc005.ap-rdc01.nxp.com (Postfix) with ESMTP id 41598402D3;\n Sat, 11 Jul 2020 01:24:09 +0800 (SGT)" ], "From": "Hemant Agrawal <hemant.agrawal@nxp.com>", "To": "dev@dpdk.org", "Cc": "ferruh.yigit@intel.com,\n\tHemant Agrawal <hemant.agrawal@nxp.com>", "Date": "Fri, 10 Jul 2020 22:49:43 +0530", "Message-Id": "<20200710171946.23246-6-hemant.agrawal@nxp.com>", "X-Mailer": "git-send-email 2.17.1", "In-Reply-To": "<20200710171946.23246-1-hemant.agrawal@nxp.com>", "References": "<20200710171946.23246-1-hemant.agrawal@nxp.com>", "X-Virus-Scanned": "ClamAV using ClamSMTP", "Subject": "[dpdk-dev] [PATCH v2 6/9] bus/dpaa: add Virtual Storage Profile\n\tport init", "X-BeenThere": "dev@dpdk.org", "X-Mailman-Version": "2.1.15", "Precedence": "list", "List-Id": "DPDK patches and discussions <dev.dpdk.org>", "List-Unsubscribe": "<https://mails.dpdk.org/options/dev>,\n <mailto:dev-request@dpdk.org?subject=unsubscribe>", "List-Archive": "<http://mails.dpdk.org/archives/dev/>", "List-Post": "<mailto:dev@dpdk.org>", "List-Help": "<mailto:dev-request@dpdk.org?subject=help>", "List-Subscribe": "<https://mails.dpdk.org/listinfo/dev>,\n <mailto:dev-request@dpdk.org?subject=subscribe>", "Errors-To": "dev-bounces@dpdk.org", "Sender": "\"dev\" <dev-bounces@dpdk.org>" }, "content": "This patch add support to initialize the VSP ports\nin the FMAN library.\n\nSigned-off-by: Hemant Agrawal <hemant.agrawal@nxp.com>\n---\n drivers/bus/dpaa/base/fman/fman.c | 57 +++++++++++++++++++++++++++++++\n drivers/bus/dpaa/include/fman.h | 3 ++\n 2 files changed, 60 insertions(+)", "diff": "diff --git a/drivers/bus/dpaa/base/fman/fman.c b/drivers/bus/dpaa/base/fman/fman.c\nindex 3ae29bf06..39102bc1f 100644\n--- a/drivers/bus/dpaa/base/fman/fman.c\n+++ b/drivers/bus/dpaa/base/fman/fman.c\n@@ -145,6 +145,61 @@ fman_get_mac_index(uint64_t regs_addr_host, uint8_t *mac_idx)\n \treturn ret;\n }\n \n+static void fman_if_vsp_init(struct __fman_if *__if)\n+{\n+\tconst phandle *prop;\n+\tint cell_index;\n+\tconst struct device_node *dev;\n+\tsize_t lenp;\n+\tconst uint8_t mac_idx[] = {-1, 0, 1, 2, 3, 4, 5, 6, 7, 0, 1};\n+\n+\tif (__if->__if.mac_type == fman_mac_1g) {\n+\t\tfor_each_compatible_node(dev, NULL,\n+\t\t\t\"fsl,fman-port-1g-rx-extended-args\") {\n+\t\t\tprop = of_get_property(dev, \"cell-index\", &lenp);\n+\t\t\tif (prop) {\n+\t\t\t\tcell_index = of_read_number(\n+\t\t\t\t\t\t&prop[0],\n+\t\t\t\t\t\tlenp / sizeof(phandle));\n+\t\t\t\tif (cell_index == mac_idx[__if->__if.mac_idx]) {\n+\t\t\t\t\tprop = of_get_property(\n+\t\t\t\t\t\t\tdev,\n+\t\t\t\t\t\t\t\"vsp-window\", &lenp);\n+\t\t\t\t\tif (prop) {\n+\t\t\t\t\t\t__if->__if.num_profiles =\n+\t\t\t\t\t\t\tof_read_number(\n+\t\t\t\t\t\t\t\t&prop[0], 1);\n+\t\t\t\t\t\t__if->__if.base_profile_id =\n+\t\t\t\t\t\t\tof_read_number(\n+\t\t\t\t\t\t\t\t&prop[1], 1);\n+\t\t\t\t\t}\n+\t\t\t\t}\n+\t\t\t}\n+\t\t}\n+\t} else if (__if->__if.mac_type == fman_mac_10g) {\n+\t\tfor_each_compatible_node(dev, NULL,\n+\t\t\t\"fsl,fman-port-10g-rx-extended-args\") {\n+\t\t\tprop = of_get_property(dev, \"cell-index\", &lenp);\n+\t\t\tif (prop) {\n+\t\t\t\tcell_index = of_read_number(\n+\t\t\t\t\t&prop[0], lenp / sizeof(phandle));\n+\t\t\t\tif (cell_index == mac_idx[__if->__if.mac_idx]) {\n+\t\t\t\t\tprop = of_get_property(\n+\t\t\t\t\t\tdev, \"vsp-window\", &lenp);\n+\t\t\t\t\tif (prop) {\n+\t\t\t\t\t\t__if->__if.num_profiles =\n+\t\t\t\t\t\t\tof_read_number(\n+\t\t\t\t\t\t\t\t&prop[0], 1);\n+\t\t\t\t\t\t__if->__if.base_profile_id =\n+\t\t\t\t\t\t\tof_read_number(\n+\t\t\t\t\t\t\t\t&prop[1], 1);\n+\t\t\t\t\t}\n+\t\t\t\t}\n+\t\t\t}\n+\t\t}\n+\t}\n+}\n+\n static int\n fman_if_init(const struct device_node *dpa_node)\n {\n@@ -519,6 +574,8 @@ fman_if_init(const struct device_node *dpa_node)\n \tif (is_shared)\n \t\t__if->__if.is_shared_mac = 1;\n \n+\tfman_if_vsp_init(__if);\n+\n \t/* Parsing of the network interface is complete, add it to the list */\n \tDPAA_BUS_LOG(DEBUG, \"Found %s, Tx Channel = %x, FMAN = %x,\"\n \t\t \"Port ID = %x\",\ndiff --git a/drivers/bus/dpaa/include/fman.h b/drivers/bus/dpaa/include/fman.h\nindex cb7f18ca2..dcf408372 100644\n--- a/drivers/bus/dpaa/include/fman.h\n+++ b/drivers/bus/dpaa/include/fman.h\n@@ -321,6 +321,9 @@ struct fman_if {\n \t/* The Qman channel to schedule Tx FQs to */\n \tu16 tx_channel_id;\n \n+\tuint8_t base_profile_id;\n+\tuint8_t num_profiles;\n+\n \tuint8_t is_shared_mac;\n \t/* The hard-coded FQIDs for this interface. Note: this doesn't cover\n \t * the PCD nor the \"Rx default\" FQIDs, which are configured via FMC\n", "prefixes": [ "v2", "6/9" ] }{ "id": 73773, "url": "