diff --git a/modules/mqnic/mqnic_board.c b/modules/mqnic/mqnic_board.c index ae659ce8f..62beeafa4 100644 --- a/modules/mqnic/mqnic_board.c +++ b/modules/mqnic/mqnic_board.c @@ -407,6 +407,34 @@ static int mqnic_generic_board_init(struct mqnic_dev *mqnic) // read MACs from EEPROM init_mac_list_from_eeprom_base(mqnic, mqnic->eeprom_i2c_client, 0, MQNIC_MAX_IF); + break; + case MQNIC_BOARD_ID_DNPCIE_40G_KU: + + request_module("at24"); + + // I2C adapter + adapter = mqnic_i2c_adapter_create(mqnic, 0); + + // QSFP0 + mqnic->mod_i2c_client[0] = create_i2c_client(adapter, "24c02", 0x50, NULL); + + // I2C adapter + adapter = mqnic_i2c_adapter_create(mqnic, 1); + + // QSFP1 + mqnic->mod_i2c_client[1] = create_i2c_client(adapter, "24c02", 0x50, NULL); + + mqnic->mod_i2c_client_count = 2; + + // I2C adapter + adapter = mqnic_i2c_adapter_create(mqnic, 2); + + // I2C EEPROM + mqnic->eeprom_i2c_client = create_i2c_client(adapter, "24c256", 0x50, NULL); + + // read MACs from EEPROM + // init_mac_list_from_eeprom(mqnic, mqnic->eeprom_i2c_client, 0x000E, MQNIC_MAX_IF); + break; default: dev_warn(mqnic->dev, "Unknown board ID, not performing any board-specific init"); diff --git a/modules/mqnic/mqnic_hw.h b/modules/mqnic/mqnic_hw.h index 380b45c9e..6c12e64d1 100644 --- a/modules/mqnic/mqnic_hw.h +++ b/modules/mqnic/mqnic_hw.h @@ -74,6 +74,7 @@ #define MQNIC_BOARD_ID_FB2CG_KU15P 0x1c2ca00e #define MQNIC_BOARD_ID_EXANIC_X10 0x1ce40003 #define MQNIC_BOARD_ID_EXANIC_X25 0x1ce40009 +#define MQNIC_BOARD_ID_DNPCIE_40G_KU 0x17df1a00 #define MQNIC_BOARD_ID_ADM_PCIE_9V3 0x41449003 // Register blocks