Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

octeon_ep: support Octeon device CNF95N

Add support for Octeon device CNF95N.
CNF95N is a Octeon Fusion family product with same PCI NIC
characteristics as CN93 which is currently supported by the driver.

update supported device list in Documentation.

Signed-off-by: Veerasenareddy Burru <vburru@marvell.com>
Link: https://lore.kernel.org/r/20221103060600.1858-1-vburru@marvell.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>

authored by

Veerasenareddy Burru and committed by
Jakub Kicinski
63d9e129 bcc8f44a

+20 -3
+1
Documentation/networking/device_drivers/ethernet/marvell/octeon_ep.rst
··· 23 23 ================= 24 24 Currently, this driver support following devices: 25 25 * Network controller: Cavium, Inc. Device b200 26 + * Network controller: Cavium, Inc. Device b400 26 27 27 28 Interface Control 28 29 =================
+17 -3
drivers/net/ethernet/marvell/octeon_ep/octep_main.c
··· 23 23 /* Supported Devices */ 24 24 static const struct pci_device_id octep_pci_id_tbl[] = { 25 25 {PCI_DEVICE(PCI_VENDOR_ID_CAVIUM, OCTEP_PCI_DEVICE_ID_CN93_PF)}, 26 + {PCI_DEVICE(PCI_VENDOR_ID_CAVIUM, OCTEP_PCI_DEVICE_ID_CNF95N_PF)}, 26 27 {0, }, 27 28 }; 28 29 MODULE_DEVICE_TABLE(pci, octep_pci_id_tbl); ··· 908 907 } 909 908 } 910 909 910 + static const char *octep_devid_to_str(struct octep_device *oct) 911 + { 912 + switch (oct->chip_id) { 913 + case OCTEP_PCI_DEVICE_ID_CN93_PF: 914 + return "CN93XX"; 915 + case OCTEP_PCI_DEVICE_ID_CNF95N_PF: 916 + return "CNF95N"; 917 + default: 918 + return "Unsupported"; 919 + } 920 + } 921 + 911 922 /** 912 923 * octep_device_setup() - Setup Octeon Device. 913 924 * ··· 952 939 953 940 switch (oct->chip_id) { 954 941 case OCTEP_PCI_DEVICE_ID_CN93_PF: 955 - dev_info(&pdev->dev, 956 - "Setting up OCTEON CN93XX PF PASS%d.%d\n", 957 - OCTEP_MAJOR_REV(oct), OCTEP_MINOR_REV(oct)); 942 + case OCTEP_PCI_DEVICE_ID_CNF95N_PF: 943 + dev_info(&pdev->dev, "Setting up OCTEON %s PF PASS%d.%d\n", 944 + octep_devid_to_str(oct), OCTEP_MAJOR_REV(oct), 945 + OCTEP_MINOR_REV(oct)); 958 946 octep_device_setup_cn93_pf(oct); 959 947 break; 960 948 default:
+2
drivers/net/ethernet/marvell/octeon_ep/octep_main.h
··· 21 21 #define OCTEP_PCI_DEVICE_ID_CN93_PF 0xB200 22 22 #define OCTEP_PCI_DEVICE_ID_CN93_VF 0xB203 23 23 24 + #define OCTEP_PCI_DEVICE_ID_CNF95N_PF 0xB400 //95N PF 25 + 24 26 #define OCTEP_MAX_QUEUES 63 25 27 #define OCTEP_MAX_IQ OCTEP_MAX_QUEUES 26 28 #define OCTEP_MAX_OQ OCTEP_MAX_QUEUES