get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 130850,
    "url": "http://patchwork.dpdk.org/api/patches/130850/?format=api",
    "web_url": "http://patchwork.dpdk.org/project/dpdk/patch/20230830021457.2064750-13-chaoyong.he@corigine.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": "<20230830021457.2064750-13-chaoyong.he@corigine.com>",
    "list_archive_url": "https://inbox.dpdk.org/dev/20230830021457.2064750-13-chaoyong.he@corigine.com",
    "date": "2023-08-30T02:14:42",
    "name": "[v2,12/27] net/nfp: refact the hwinfo module",
    "commit_ref": null,
    "pull_url": null,
    "state": "superseded",
    "archived": true,
    "hash": "f0da8b71e0f0f903ecaf14ad44d0b722c432d773",
    "submitter": {
        "id": 2554,
        "url": "http://patchwork.dpdk.org/api/people/2554/?format=api",
        "name": "Chaoyong He",
        "email": "chaoyong.he@corigine.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/20230830021457.2064750-13-chaoyong.he@corigine.com/mbox/",
    "series": [
        {
            "id": 29363,
            "url": "http://patchwork.dpdk.org/api/series/29363/?format=api",
            "web_url": "http://patchwork.dpdk.org/project/dpdk/list/?series=29363",
            "date": "2023-08-30T02:14:30",
            "name": "refact the nfpcore module",
            "version": 2,
            "mbox": "http://patchwork.dpdk.org/series/29363/mbox/"
        }
    ],
    "comments": "http://patchwork.dpdk.org/api/patches/130850/comments/",
    "check": "success",
    "checks": "http://patchwork.dpdk.org/api/patches/130850/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 mails.dpdk.org (mails.dpdk.org [217.70.189.124])\n\tby inbox.dpdk.org (Postfix) with ESMTP id 31D4141FC8;\n\tWed, 30 Aug 2023 04:17:22 +0200 (CEST)",
            "from mails.dpdk.org (localhost [127.0.0.1])\n\tby mails.dpdk.org (Postfix) with ESMTP id F07F0402C5;\n\tWed, 30 Aug 2023 04:15:52 +0200 (CEST)",
            "from NAM10-DM6-obe.outbound.protection.outlook.com\n (mail-dm6nam10on2096.outbound.protection.outlook.com [40.107.93.96])\n by mails.dpdk.org (Postfix) with ESMTP id 76C70402CA\n for <dev@dpdk.org>; Wed, 30 Aug 2023 04:15:48 +0200 (CEST)",
            "from SJ0PR13MB5545.namprd13.prod.outlook.com (2603:10b6:a03:424::5)\n by DM6PR13MB3786.namprd13.prod.outlook.com (2603:10b6:5:229::11) with\n Microsoft SMTP Server (version=TLS1_2,\n cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6745.18; Wed, 30 Aug\n 2023 02:15:47 +0000",
            "from SJ0PR13MB5545.namprd13.prod.outlook.com\n ([fe80::c0f3:c2cc:b5bb:4192]) by SJ0PR13MB5545.namprd13.prod.outlook.com\n ([fe80::c0f3:c2cc:b5bb:4192%4]) with mapi id 15.20.6699.034; Wed, 30 Aug 2023\n 02:15:47 +0000"
        ],
        "ARC-Seal": "i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none;\n b=lngFgjetmXKo996Y7dofg9GHA43ZvG9uDLXCQawQhLew2aAH58wQ0wQZLTZZMUKwivgwzdmfi90KQcmnVlMsyH/g1P7CpVRjQnejhAA83BC+/0ssoB+KCmRppT/6L9uG/q2skHzZ0AmY8c/2gHp/T5AI4pkmu9ryt3/HiixcTl8HmfYTF/RPl0Xi+VxpqzkwEtQK+bTbN5BBVsLfZ/HxQqFzV5JxOD70N4X2+IzH2rna0E6abAcYKWiolNdF+wWaK3WazD+CL1bcmc9SHAz6767UyXGpHuI0rcv5OQdQSdUq55GoERT12OtAKtjomt8ya2IiL1fXUfbxRFr6cy1qtg==",
        "ARC-Message-Signature": "i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com;\n s=arcselector9901;\n h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1;\n bh=+yvZDG2HDEPnYtWF1Wkl+yal9KI7LdfqgZhh7PgB9Zg=;\n b=FFjhXF35i7I8kQNURGAf7HtwWS5aG1T3iCXeJPu1O6OhdhJVRvaeA020eV+D6XEhSCOmgsJ6oEyOPYB3pGHG1oP2ZKPU1JHkfoPrpNb4/WdO4/yaul4WVN+Cw8djpytLA2E9Fi57TbPdB9FpQlYJC3HwhKxOjc1WgrxWjV1Sk0sgk0IFw+EIEmhOiIZR/Lviu1zowFRP0JfO+xAqLZV1kIhDeq0rSgUM1ql2CxjPyKqY9Kwi3/AZKuCXXyh7yYsgWlfzrQDzhFrjHHuMqDt9VwBaN4h2OKw5uGOyG0o2ccitNRpEK6V0/oFhmRQ2BA+QrbEqFNNC82Wtyhh5HPrF1g==",
        "ARC-Authentication-Results": "i=1; mx.microsoft.com 1; spf=pass\n smtp.mailfrom=corigine.com; dmarc=pass action=none header.from=corigine.com;\n dkim=pass header.d=corigine.com; arc=none",
        "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n d=corigine.onmicrosoft.com; s=selector2-corigine-onmicrosoft-com;\n h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck;\n bh=+yvZDG2HDEPnYtWF1Wkl+yal9KI7LdfqgZhh7PgB9Zg=;\n b=h3UyX4Fal5J3nyfqVDvhznh5FUNQp4jll4cmFTM+mtU+L76Xd3/9HlNvHfC29t7Ke6DwSxOTEaYALFeXvNXpYxLtqd6qFrdxy0GoLUcRofG9BbeSxBwMI8qzscxfxzFy9oim4i+IPzOXORFpX70M0grHGF0ZHUI0moKcBRuIPcg=",
        "Authentication-Results": "dkim=none (message not signed)\n header.d=none;dmarc=none action=none header.from=corigine.com;",
        "From": "Chaoyong He <chaoyong.he@corigine.com>",
        "To": "dev@dpdk.org",
        "Cc": "oss-drivers@corigine.com, niklas.soderlund@corigine.com,\n Chaoyong He <chaoyong.he@corigine.com>",
        "Subject": "[PATCH v2 12/27] net/nfp: refact the hwinfo module",
        "Date": "Wed, 30 Aug 2023 10:14:42 +0800",
        "Message-Id": "<20230830021457.2064750-13-chaoyong.he@corigine.com>",
        "X-Mailer": "git-send-email 2.39.1",
        "In-Reply-To": "<20230830021457.2064750-1-chaoyong.he@corigine.com>",
        "References": "<20230824110956.1943559-1-chaoyong.he@corigine.com>\n <20230830021457.2064750-1-chaoyong.he@corigine.com>",
        "Content-Type": "text/plain; charset=UTF-8",
        "Content-Transfer-Encoding": "8bit",
        "X-ClientProxiedBy": "PH0PR07CA0113.namprd07.prod.outlook.com\n (2603:10b6:510:4::28) To SJ0PR13MB5545.namprd13.prod.outlook.com\n (2603:10b6:a03:424::5)",
        "MIME-Version": "1.0",
        "X-MS-PublicTrafficType": "Email",
        "X-MS-TrafficTypeDiagnostic": "SJ0PR13MB5545:EE_|DM6PR13MB3786:EE_",
        "X-MS-Office365-Filtering-Correlation-Id": "f811d3b5-2c6f-4fa2-63f3-08dba8ff0590",
        "X-MS-Exchange-SenderADCheck": "1",
        "X-MS-Exchange-AntiSpam-Relay": "0",
        "X-Microsoft-Antispam": "BCL:0;",
        "X-Microsoft-Antispam-Message-Info": "\n KJANt8gkajdyEbMoixt9+I23mhaz2WUBnrwe1W/sxoM/KII1u40bwKcxXZICpWzG0oslqE3uWF5dOTsWKuqeljB8e917hDW8vouqtLg2ojsFUo79u8PJLrcmMI3IuZQRc4IdrY4G72qvkMhvV1yxQUXKpXfd/MeanHi4V1FewcAKUyPQPt3MfowgpJwL1ttKctej3CklvitKeUKrrgVyTt/62MRzgdPD8rwc478sIdKVSQcAyFgF5hb+pLW2FCfNdCZMaNU4vYdiKYNZsW/AF79gFUqCR6sgF34E93xsIx1UqoKIayC7fGFNpKp2zBVo6MOmABny01SziYAnaAjMR9qCPyVYi0gxlpEw34INv/PMweM4/5jhwGx+MhseR8k6IpoWuE6MWsH2zLGQHN66BzBourHGA+odoHV4u2O5lJtBfVi2d1AKE0B7OUoFhTQTcBkkg0BPTV+N7nLLWDZ1LsDJItnXzQkqEuzZS1OwwOvTPo8t3Nr4ApRzddGsCV7nSZYt8a2FJdsRe6/H5ZWk6Og8z8YI7kNZYBBBBK+tdJKQrcH6+GGxwRQfLKmv6OQFkVh42YIcMoSDirFrQGf8DFyTWGcbfYgy7cx2Wy7URYiLBv8XqEfUxKz0qoUsqbZYJiOoIHO+YYFSNLI/DiNDsUatdCQ1RGJxRkCZJkTI+nA=",
        "X-Forefront-Antispam-Report": "CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:;\n IPV:NLI; SFV:NSPM; H:SJ0PR13MB5545.namprd13.prod.outlook.com; PTR:; CAT:NONE;\n SFS:(13230031)(136003)(366004)(376002)(346002)(396003)(39830400003)(451199024)(186009)(1800799009)(6512007)(6916009)(316002)(38100700002)(41300700001)(38350700002)(2906002)(4326008)(66574015)(83380400001)(2616005)(86362001)(44832011)(26005)(36756003)(1076003)(8676002)(5660300002)(107886003)(8936002)(6666004)(6506007)(6486002)(66556008)(66946007)(66476007)(52116002)(478600001);\n DIR:OUT; SFP:1102;",
        "X-MS-Exchange-AntiSpam-MessageData-ChunkCount": "1",
        "X-MS-Exchange-AntiSpam-MessageData-0": "=?utf-8?q?iLGuBtuXiA/ERVe/OMJuWOtDjV5C?=\n\t=?utf-8?q?HQOoV0dxAxRL44S0BEWhFmnObjORKlI2spqbFHm8Ob+IbO5YlNq89jUHZ+0zJdzrK?=\n\t=?utf-8?q?7oYcs/AvvTOYu1s/XX7gIUlfuLMViD7isf3DJkll+/bAcH81pRRL0XYc1vS9jL/zL?=\n\t=?utf-8?q?38Wml9ip3OS0X81ltVT+w/pZGHIdOld6nUFWdC1KWcYBPN0BnP9UwwnLmxALQWPCo?=\n\t=?utf-8?q?VS3Vgd9HWg81pa0VFQ9ZsSTUYzjYKrEm9AXtQmaFm1/ETohXIiowWRAXTENRO+tP4?=\n\t=?utf-8?q?Ur1TwFBO28e3Xhb7WOps98UyNdLWzkcFBhczxXKEyT/z/92gz2CxMJYfbM6Z4yJof?=\n\t=?utf-8?q?R5W3C708HQ6i2sKPwH4Tm9iU9esa6mN0mpgyKjj9IBmT8c9siOiBpHnz+odU1AuyH?=\n\t=?utf-8?q?covym8YAFjs7GSrnE1TaWNxkfUaAkOQvz7FA5y2dwLWBGx4qZb80uBFfxdooM7a+S?=\n\t=?utf-8?q?Pd2pzVIICu7qV8+JPalSqExB0PEdXE8V+cWBgjeMPf/NIWsw9paBMK91ZeVLbMy8p?=\n\t=?utf-8?q?ZLivnDInFhJUf9KsJ8MJ83F6b8S0VnpqhxTkk7o87UdAZmZffkGfySI/hpBc4+VWx?=\n\t=?utf-8?q?pr7Zql9RQbh2LtYRwrdlMvK3xIiC02N+9YUbKxU4kAC9O6tsKgwhaVl5SjLKotvgy?=\n\t=?utf-8?q?9X7MpILUwRHQDk02b9h4UrRJ6NWWQbCjI+Qrz/lOryco7hH4GuZnZvMLEP+kOOOBj?=\n\t=?utf-8?q?6QtmqYyuSrbPlLxdwBdTQ7znpjsRXVVGqZQUWUmFhCu8Jt7nOmoiWaBaanNqxyMmH?=\n\t=?utf-8?q?uTBtVcjisQm6pv3Yqp8qCd+nhTEWj21hdnSYZr+cCoS9K+zSQw9r35Z3BhtYTGRWq?=\n\t=?utf-8?q?Olv7jWNMbTo0OMtthoANdWfYXcDkNkVXkm3Z5yJ+BI63/zgGNOVvdMM99dKsv/tO5?=\n\t=?utf-8?q?iumYRgq+4q8u4meWsbZnzbC112ZflZ+OAMZYb71cx+M5YiJPIufXftbK1Q7axVa4C?=\n\t=?utf-8?q?HgX5sVBwbdNwndrYJCdg3GBu3zxMMXzCltMSuIWMBPMRYU8mCjwaZHTbVPPkAUFdA?=\n\t=?utf-8?q?X9u9zS4whsXex63fenvMJn+aS4H56EKWzlVsYsiI+DLWolov4fD+rZSE73HxnGHlP?=\n\t=?utf-8?q?llsA3cA8jRprNRRNfFZbEqkR/K833Xz7gG00xkPjFo50L+jlTggyP3PhFTQE6q83H?=\n\t=?utf-8?q?QfSbX/MaeOsSGsfgaYxIwxwHlzfv6hW0yQWn8x8dvBJOq3zyMasNEYRMKAg2XBQLe?=\n\t=?utf-8?q?nyu03C9AE7Rpamdy4BccYHhI8WkHuqmJmTtjyTmFa4LA286RGKAxyF0soTN/89ZWt?=\n\t=?utf-8?q?sgrkUuy/3pxmZg5WS+PqYbrj/hXxkX3bfy12OcQUxawhpBfn/Q/vjvI+hEwWmKW3U?=\n\t=?utf-8?q?uHkQVa6fUa+hsgGwodqUI5JUGvTWXzugv3BJF324tKyN1c6qRFcHRrtKAwnzkbrxs?=\n\t=?utf-8?q?mc7OFoQLnbWqhrKQ5n2bjMHsGHepwlrifFMfmuEaM9PfZl0q/vJLBUZ60ljmEzL/N?=\n\t=?utf-8?q?ThvfwEbXKf/6kevmmi0SqGn03vq3JsuigdKnxJtbuUMrSxLBL9MuD4G6dorUm3oRc?=\n\t=?utf-8?q?zf9fYKenRSwyW8YvmFa9nhckf05Bi0RaVA=3D=3D?=",
        "X-OriginatorOrg": "corigine.com",
        "X-MS-Exchange-CrossTenant-Network-Message-Id": "\n f811d3b5-2c6f-4fa2-63f3-08dba8ff0590",
        "X-MS-Exchange-CrossTenant-AuthSource": "SJ0PR13MB5545.namprd13.prod.outlook.com",
        "X-MS-Exchange-CrossTenant-AuthAs": "Internal",
        "X-MS-Exchange-CrossTenant-OriginalArrivalTime": "30 Aug 2023 02:15:47.0120 (UTC)",
        "X-MS-Exchange-CrossTenant-FromEntityHeader": "Hosted",
        "X-MS-Exchange-CrossTenant-Id": "fe128f2c-073b-4c20-818e-7246a585940c",
        "X-MS-Exchange-CrossTenant-MailboxType": "HOSTED",
        "X-MS-Exchange-CrossTenant-UserPrincipalName": "\n ua1LldqW6cH2pl4zj2ceqllXX1pF27Yzk/V0b2hdAqjeOkDMW2B1y0oAXYAfDMXtRQwep2zckbFK8n/tdhMe6PZwxwXsW1eRCk23eNeSCnU=",
        "X-MS-Exchange-Transport-CrossTenantHeadersStamped": "DM6PR13MB3786",
        "X-BeenThere": "dev@dpdk.org",
        "X-Mailman-Version": "2.1.29",
        "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"
    },
    "content": "Move the definition of data structure and macro into the implement file.\nAlso remove the unneeded header file include statements.\n\nSigned-off-by: Chaoyong He <chaoyong.he@corigine.com>\nReviewed-by: Niklas Söderlund <niklas.soderlund@corigine.com>\n---\n drivers/net/nfp/nfpcore/nfp_hwinfo.c | 84 +++++++++++++++++++++++++---\n drivers/net/nfp/nfpcore/nfp_hwinfo.h | 71 +----------------------\n 2 files changed, 77 insertions(+), 78 deletions(-)",
    "diff": "diff --git a/drivers/net/nfp/nfpcore/nfp_hwinfo.c b/drivers/net/nfp/nfpcore/nfp_hwinfo.c\nindex cee37210b0..25c2262dfc 100644\n--- a/drivers/net/nfp/nfpcore/nfp_hwinfo.c\n+++ b/drivers/net/nfp/nfpcore/nfp_hwinfo.c\n@@ -17,17 +17,82 @@\n  *   (ie, in this example, ME 39 has been reserved by boardconfig.)\n  */\n \n-#include <stdio.h>\n-#include <time.h>\n+#include \"nfp_hwinfo.h\"\n \n-#include \"nfp_cpp.h\"\n+#include \"nfp_crc.h\"\n #include \"nfp_logs.h\"\n-#include \"nfp6000/nfp6000.h\"\n #include \"nfp_resource.h\"\n-#include \"nfp_hwinfo.h\"\n-#include \"nfp_crc.h\"\n \n-static int\n+#define HWINFO_SIZE_MIN    0x100\n+\n+/*\n+ * The Hardware Info Table defines the properties of the system.\n+ *\n+ * HWInfo v1 Table (fixed size)\n+ *\n+ * 0x0000: uint32_t version        Hardware Info Table version (1.0)\n+ * 0x0004: uint32_t size           Total size of the table, including the\n+ *                                     CRC32 (IEEE 802.3)\n+ * 0x0008: uint32_t jumptab        Offset of key/value table\n+ * 0x000c: uint32_t keys           Total number of keys in the key/value table\n+ * NNNNNN:                         Key/value jump table and string data\n+ * (size - 4): uint32_t crc32      CRC32 (same as IEEE 802.3, POSIX csum, etc)\n+ *                                     CRC32(\"\",0) = ~0, CRC32(\"a\",1) = 0x48C279FE\n+ *\n+ * HWInfo v2 Table (variable size)\n+ *\n+ * 0x0000: uint32_t version        Hardware Info Table version (2.0)\n+ * 0x0004: uint32_t size           Current size of the data area, excluding CRC32\n+ * 0x0008: uint32_t limit          Maximum size of the table\n+ * 0x000c: uint32_t reserved       Unused, set to zero\n+ * NNNNNN:                         Key/value data\n+ * (size - 4): uint32_t crc32      CRC32 (same as IEEE 802.3, POSIX csum, etc)\n+ *                                     CRC32(\"\",0) = ~0, CRC32(\"a\",1) = 0x48C279FE\n+ *\n+ * If the HWInfo table is in the process of being updated, the low bit of\n+ * version will be set.\n+ *\n+ * HWInfo v1 Key/Value Table\n+ * -------------------------\n+ *\n+ *  The key/value table is a set of offsets to ASCIIZ strings which have\n+ *  been strcmp(3) sorted (yes, please use bsearch(3) on the table).\n+ *\n+ *  All keys are guaranteed to be unique.\n+ *\n+ * N+0: uint32_t key_1        Offset to the first key\n+ * N+4: uint32_t val_1        Offset to the first value\n+ * N+8: uint32_t key_2        Offset to the second key\n+ * N+c: uint32_t val_2        Offset to the second value\n+ * ...\n+ *\n+ * HWInfo v2 Key/Value Table\n+ * -------------------------\n+ *\n+ * Packed UTF8Z strings, ie 'key1\\000value1\\000key2\\000value2\\000'\n+ * Unsorted.\n+ *\n+ * Note: Only the HwInfo v2 Table be supported now.\n+ */\n+\n+#define NFP_HWINFO_VERSION_1 ('H' << 24 | 'I' << 16 | 1 << 8 | 0 << 1 | 0)\n+#define NFP_HWINFO_VERSION_2 ('H' << 24 | 'I' << 16 | 2 << 8 | 0 << 1 | 0)\n+#define NFP_HWINFO_VERSION_UPDATING    RTE_BIT32(0)\n+\n+struct nfp_hwinfo {\n+\tuint8_t start[0];\n+\n+\tuint32_t version;\n+\tuint32_t size;\n+\n+\t/* V2 specific fields */\n+\tuint32_t limit;\n+\tuint32_t resv;\n+\n+\tchar data[];\n+};\n+\n+static bool\n nfp_hwinfo_is_updating(struct nfp_hwinfo *hwinfo)\n {\n \treturn hwinfo->version & NFP_HWINFO_VERSION_UPDATING;\n@@ -120,7 +185,7 @@ nfp_hwinfo_try_fetch(struct nfp_cpp *cpp,\n \t\tgoto exit_free;\n \t}\n \n-\theader = (void *)db;\n+\theader = (struct nfp_hwinfo *)db;\n \tif (nfp_hwinfo_is_updating(header))\n \t\tgoto exit_free;\n \n@@ -133,7 +198,8 @@ nfp_hwinfo_try_fetch(struct nfp_cpp *cpp,\n \t/* NULL-terminate for safety */\n \tdb[*cpp_size] = '\\0';\n \n-\treturn (void *)db;\n+\treturn (struct nfp_hwinfo *)db;\n+\n exit_free:\n \trte_free(db);\n \treturn NULL;\ndiff --git a/drivers/net/nfp/nfpcore/nfp_hwinfo.h b/drivers/net/nfp/nfpcore/nfp_hwinfo.h\nindex 543562779a..c812f10076 100644\n--- a/drivers/net/nfp/nfpcore/nfp_hwinfo.h\n+++ b/drivers/net/nfp/nfpcore/nfp_hwinfo.h\n@@ -6,76 +6,9 @@\n #ifndef __NFP_HWINFO_H__\n #define __NFP_HWINFO_H__\n \n-#include <inttypes.h>\n+#include \"nfp_cpp.h\"\n \n-#define HWINFO_SIZE_MIN    0x100\n-\n-/*\n- * The Hardware Info Table defines the properties of the system.\n- *\n- * HWInfo v1 Table (fixed size)\n- *\n- * 0x0000: uint32_t version        Hardware Info Table version (1.0)\n- * 0x0004: uint32_t size           Total size of the table, including the\n- *                                     CRC32 (IEEE 802.3)\n- * 0x0008: uint32_t jumptab        Offset of key/value table\n- * 0x000c: uint32_t keys           Total number of keys in the key/value table\n- * NNNNNN:                         Key/value jump table and string data\n- * (size - 4): uint32_t crc32      CRC32 (same as IEEE 802.3, POSIX csum, etc)\n- *                                     CRC32(\"\",0) = ~0, CRC32(\"a\",1) = 0x48C279FE\n- *\n- * HWInfo v2 Table (variable size)\n- *\n- * 0x0000: uint32_t version        Hardware Info Table version (2.0)\n- * 0x0004: uint32_t size           Current size of the data area, excluding CRC32\n- * 0x0008: uint32_t limit          Maximum size of the table\n- * 0x000c: uint32_t reserved       Unused, set to zero\n- * NNNNNN:                         Key/value data\n- * (size - 4): uint32_t crc32      CRC32 (same as IEEE 802.3, POSIX csum, etc)\n- *                                     CRC32(\"\",0) = ~0, CRC32(\"a\",1) = 0x48C279FE\n- *\n- * If the HWInfo table is in the process of being updated, the low bit of\n- * version will be set.\n- *\n- * HWInfo v1 Key/Value Table\n- * -------------------------\n- *\n- *  The key/value table is a set of offsets to ASCIIZ strings which have\n- *  been strcmp(3) sorted (yes, please use bsearch(3) on the table).\n- *\n- *  All keys are guaranteed to be unique.\n- *\n- * N+0: uint32_t key_1        Offset to the first key\n- * N+4: uint32_t val_1        Offset to the first value\n- * N+8: uint32_t key_2        Offset to the second key\n- * N+c: uint32_t val_2        Offset to the second value\n- * ...\n- *\n- * HWInfo v2 Key/Value Table\n- * -------------------------\n- *\n- * Packed UTF8Z strings, ie 'key1\\000value1\\000key2\\000value2\\000'\n- * Unsorted.\n- *\n- * Note: Only the HwInfo v2 Table be supported now.\n- */\n-\n-#define NFP_HWINFO_VERSION_1 ('H' << 24 | 'I' << 16 | 1 << 8 | 0 << 1 | 0)\n-#define NFP_HWINFO_VERSION_2 ('H' << 24 | 'I' << 16 | 2 << 8 | 0 << 1 | 0)\n-#define NFP_HWINFO_VERSION_UPDATING    RTE_BIT32(0)\n-\n-struct nfp_hwinfo {\n-\tuint8_t start[0];\n-\n-\tuint32_t version;\n-\tuint32_t size;\n-\n-\t/* v2 specific fields */\n-\tuint32_t limit;\n-\tuint32_t resv;\n-\n-\tchar data[];\n-};\n+struct nfp_hwinfo;\n \n struct nfp_hwinfo *nfp_hwinfo_read(struct nfp_cpp *cpp);\n \n",
    "prefixes": [
        "v2",
        "12/27"
    ]
}