nfp: report manufacturing info on load
authorJakub Kicinski <jakub.kicinski@netronome.com>
Sun, 19 Feb 2017 19:58:09 +0000 (11:58 -0800)
committerDavid S. Miller <davem@davemloft.net>
Mon, 20 Feb 2017 16:18:49 +0000 (11:18 -0500)
Report card manufacturing information when driver loads.  These
identify the version of the board and its subcomponents.

Signed-off-by: Jakub Kicinski <jakub.kicinski@netronome.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/netronome/nfp/nfp_main.c

index ca2c464c15df2496aa5cdb02efa5459fe1c0330b..8cda6b0e7e32739ee78b8c2e1d70c65959397392 100644 (file)
@@ -322,6 +322,13 @@ static int nfp_pci_probe(struct pci_dev *pdev,
                goto err_disable_msix;
        }
 
+       dev_info(&pdev->dev, "Assembly: %s%s%s-%s CPLD: %s\n",
+                nfp_hwinfo_lookup(pf->cpp, "assembly.vendor"),
+                nfp_hwinfo_lookup(pf->cpp, "assembly.partno"),
+                nfp_hwinfo_lookup(pf->cpp, "assembly.serial"),
+                nfp_hwinfo_lookup(pf->cpp, "assembly.revision"),
+                nfp_hwinfo_lookup(pf->cpp, "cpld.version"));
+
        err = nfp_nsp_init(pdev, pf);
        if (err)
                goto err_cpp_free;