get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 59699,
    "url": "http://patches.dpdk.org/api/patches/59699/?format=api",
    "web_url": "http://patches.dpdk.org/project/dpdk/patch/1569398015-6027-3-git-send-email-viacheslavo@mellanox.com/",
    "project": {
        "id": 1,
        "url": "http://patches.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": "<1569398015-6027-3-git-send-email-viacheslavo@mellanox.com>",
    "list_archive_url": "https://inbox.dpdk.org/dev/1569398015-6027-3-git-send-email-viacheslavo@mellanox.com",
    "date": "2019-09-25T07:53:25",
    "name": "[02/12] net/mlx5: update PCI address retrieving routine",
    "commit_ref": null,
    "pull_url": null,
    "state": "accepted",
    "archived": true,
    "hash": "c436bf1d4a9a780bb788b2d89ef2d400e015c996",
    "submitter": {
        "id": 1102,
        "url": "http://patches.dpdk.org/api/people/1102/?format=api",
        "name": "Slava Ovsiienko",
        "email": "viacheslavo@mellanox.com"
    },
    "delegate": {
        "id": 3268,
        "url": "http://patches.dpdk.org/api/users/3268/?format=api",
        "username": "rasland",
        "first_name": "Raslan",
        "last_name": "Darawsheh",
        "email": "rasland@nvidia.com"
    },
    "mbox": "http://patches.dpdk.org/project/dpdk/patch/1569398015-6027-3-git-send-email-viacheslavo@mellanox.com/mbox/",
    "series": [
        {
            "id": 6519,
            "url": "http://patches.dpdk.org/api/series/6519/?format=api",
            "web_url": "http://patches.dpdk.org/project/dpdk/list/?series=6519",
            "date": "2019-09-25T07:53:23",
            "name": "net/mlx5: add bonding configuration support",
            "version": 1,
            "mbox": "http://patches.dpdk.org/series/6519/mbox/"
        }
    ],
    "comments": "http://patches.dpdk.org/api/patches/59699/comments/",
    "check": "success",
    "checks": "http://patches.dpdk.org/api/patches/59699/checks/",
    "tags": {},
    "related": [],
    "headers": {
        "Return-Path": "<dev-bounces@dpdk.org>",
        "X-Original-To": "patchwork@dpdk.org",
        "Delivered-To": "patchwork@dpdk.org",
        "Received": [
            "from [92.243.14.124] (localhost [127.0.0.1])\n\tby dpdk.org (Postfix) with ESMTP id 32D3D2C57;\n\tWed, 25 Sep 2019 09:53:57 +0200 (CEST)",
            "from mellanox.co.il (mail-il-dmz.mellanox.com [193.47.165.129])\n\tby dpdk.org (Postfix) with ESMTP id 4C2302D13\n\tfor <dev@dpdk.org>; Wed, 25 Sep 2019 09:53:55 +0200 (CEST)",
            "from Internal Mail-Server by MTLPINE1 (envelope-from\n\tviacheslavo@mellanox.com)\n\twith ESMTPS (AES256-SHA encrypted); 25 Sep 2019 10:53:51 +0300",
            "from pegasus12.mtr.labs.mlnx (pegasus12.mtr.labs.mlnx\n\t[10.210.17.40])\n\tby labmailer.mlnx (8.13.8/8.13.8) with ESMTP id x8P7rpcu030206;\n\tWed, 25 Sep 2019 10:53:51 +0300",
            "from pegasus12.mtr.labs.mlnx (localhost [127.0.0.1])\n\tby pegasus12.mtr.labs.mlnx (8.14.7/8.14.7) with ESMTP id\n\tx8P7rpVU006856; Wed, 25 Sep 2019 07:53:51 GMT",
            "(from viacheslavo@localhost)\n\tby pegasus12.mtr.labs.mlnx (8.14.7/8.14.7/Submit) id x8P7rpgB006855; \n\tWed, 25 Sep 2019 07:53:51 GMT"
        ],
        "X-Authentication-Warning": "pegasus12.mtr.labs.mlnx: viacheslavo set sender to\n\tviacheslavo@mellanox.com using -f",
        "From": "Viacheslav Ovsiienko <viacheslavo@mellanox.com>",
        "To": "dev@dpdk.org",
        "Cc": "matan@mellanox.com, rasland@mellanox.com",
        "Date": "Wed, 25 Sep 2019 07:53:25 +0000",
        "Message-Id": "<1569398015-6027-3-git-send-email-viacheslavo@mellanox.com>",
        "X-Mailer": "git-send-email 1.8.3.1",
        "In-Reply-To": "<1569398015-6027-1-git-send-email-viacheslavo@mellanox.com>",
        "References": "<1569398015-6027-1-git-send-email-viacheslavo@mellanox.com>",
        "Subject": "[dpdk-dev] [PATCH 02/12] net/mlx5: update PCI address retrieving\n\troutine",
        "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\t<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\t<mailto:dev-request@dpdk.org?subject=subscribe>",
        "Errors-To": "dev-bounces@dpdk.org",
        "Sender": "\"dev\" <dev-bounces@dpdk.org>"
    },
    "content": "The routine mlx5_ibv_device_to_pci_addr() takes Infiniband\ndevice list object, takes the device sysfs path from there\nand retrieves PCI address. The routine may be implemented\nin more generic way by taking sysfs path directly as parameter\nand can be used for getting PCI address of netdevs.\n\nThe generic routine is renamed to mlx5_dev_to_pci_addr()\n\nSigned-off-by: Viacheslav Ovsiienko <viacheslavo@mellanox.com>\n---\n drivers/net/mlx5/mlx5.c        |  3 ++-\n drivers/net/mlx5/mlx5.h        |  4 ++--\n drivers/net/mlx5/mlx5_ethdev.c | 12 ++++++------\n 3 files changed, 10 insertions(+), 9 deletions(-)",
    "diff": "diff --git a/drivers/net/mlx5/mlx5.c b/drivers/net/mlx5/mlx5.c\nindex b4096a4..dd8159c 100644\n--- a/drivers/net/mlx5/mlx5.c\n+++ b/drivers/net/mlx5/mlx5.c\n@@ -2184,7 +2184,8 @@ struct mlx5_dev_spawn_data {\n \t\tstruct rte_pci_addr pci_addr;\n \n \t\tDRV_LOG(DEBUG, \"checking device \\\"%s\\\"\", ibv_list[ret]->name);\n-\t\tif (mlx5_ibv_device_to_pci_addr(ibv_list[ret], &pci_addr))\n+\t\tif (mlx5_dev_to_pci_addr\n+\t\t\t(ibv_list[ret]->ibdev_path, &pci_addr))\n \t\t\tcontinue;\n \t\tif (pci_dev->addr.domain != pci_addr.domain ||\n \t\t    pci_dev->addr.bus != pci_addr.bus ||\ndiff --git a/drivers/net/mlx5/mlx5.h b/drivers/net/mlx5/mlx5.h\nindex f45d627..9a3fd36 100644\n--- a/drivers/net/mlx5/mlx5.h\n+++ b/drivers/net/mlx5/mlx5.h\n@@ -701,8 +701,8 @@ int mlx5_dev_get_flow_ctrl(struct rte_eth_dev *dev,\n \t\t\t   struct rte_eth_fc_conf *fc_conf);\n int mlx5_dev_set_flow_ctrl(struct rte_eth_dev *dev,\n \t\t\t   struct rte_eth_fc_conf *fc_conf);\n-int mlx5_ibv_device_to_pci_addr(const struct ibv_device *device,\n-\t\t\t\tstruct rte_pci_addr *pci_addr);\n+int mlx5_dev_to_pci_addr(const char *dev_path,\n+\t\t\t struct rte_pci_addr *pci_addr);\n void mlx5_dev_link_status_handler(void *arg);\n void mlx5_dev_interrupt_handler(void *arg);\n void mlx5_dev_interrupt_handler_devx(void *arg);\ndiff --git a/drivers/net/mlx5/mlx5_ethdev.c b/drivers/net/mlx5/mlx5_ethdev.c\nindex ad53721..71f63ac 100644\n--- a/drivers/net/mlx5/mlx5_ethdev.c\n+++ b/drivers/net/mlx5/mlx5_ethdev.c\n@@ -1131,10 +1131,10 @@ int mlx5_fw_version_get(struct rte_eth_dev *dev, char *fw_ver, size_t fw_size)\n }\n \n /**\n- * Get PCI information from struct ibv_device.\n+ * Get PCI information by sysfs device path.\n  *\n- * @param device\n- *   Pointer to Ethernet device structure.\n+ * @param dev_path\n+ *   Pointer to device sysfs folder name.\n  * @param[out] pci_addr\n  *   PCI bus address output buffer.\n  *\n@@ -1142,12 +1142,12 @@ int mlx5_fw_version_get(struct rte_eth_dev *dev, char *fw_ver, size_t fw_size)\n  *   0 on success, a negative errno value otherwise and rte_errno is set.\n  */\n int\n-mlx5_ibv_device_to_pci_addr(const struct ibv_device *device,\n-\t\t\t    struct rte_pci_addr *pci_addr)\n+mlx5_dev_to_pci_addr(const char *dev_path,\n+\t\t     struct rte_pci_addr *pci_addr)\n {\n \tFILE *file;\n \tchar line[32];\n-\tMKSTR(path, \"%s/device/uevent\", device->ibdev_path);\n+\tMKSTR(path, \"%s/device/uevent\", dev_path);\n \n \tfile = fopen(path, \"rb\");\n \tif (file == NULL) {\n",
    "prefixes": [
        "02/12"
    ]
}