1
0
mirror of https://github.com/corundum/corundum.git synced 2025-01-16 08:12:53 +08:00

187 Commits

Author SHA1 Message Date
Joachim Foerster
d6b2a38a92 modules/mqnic: Fix link status monitoring, initialize stored link status on start to "down"
Assume that the hardware link status is "down" when a netdev is brought "up"
administratively ("ip link set dev ... up"). This way a change of link status is
always occuring, in case hardware link status is indeed still "up" at that point
in time.

Otherwise bringing a netdev administratively "down" and "up" again, while the
hardware was "up" before and stays "up" during the administrative "down" period,
results in no netif_carrier_on() being called, because struct
mqnic_priv::link_status does not change.

Signed-off-by: Joachim Foerster <joachim.foerster@missinglinkelectronics.com>
2022-05-30 13:08:10 -07:00
Joachim Foerster
0d2e794b74 modules/mqnic: Add link status monitoring
This solution is based on the assumption that, if there are multiple
(mqnic-)ports per (mqnic-)interface, the single netdev, which is currently
associated with one (mqnic-)interface, is assumed to be up, when all ports' TX
and RX status bits are asserted. As soon as one of these bits is deasserted for
any of the involved ports the netdev is assumed to be down.

Module parameter "link_status_poll" specifies the polling interval in
milliseconds. Setting it to 0, disables any form of monitoring. By default we
check once per second, which is a totally arbitrary choice - no special
reasoning.

Signed-off-by: Joachim Foerster <joachim.foerster@missinglinkelectronics.com>
2022-05-23 13:59:46 -07:00
Joachim Foerster
db1bb30745 modules/mqnic: Export link status via ethtool
Makes ethtool show the usual "Link detected" line.

Signed-off-by: Joachim Foerster <joachim.foerster@missinglinkelectronics.com>
2022-05-23 13:59:46 -07:00
Joachim Foerster
2697ec93e9 modules/mqnic: Minor, fix warning, when CONFIG_AUXILIARY_BUS is not available
Signed-off-by: Joachim Foerster <joachim.foerster@missinglinkelectronics.com>
2022-05-23 13:59:46 -07:00
Alex Forencich
b3c93b5ac7 Fix MAC address EEPROM offsets for Xilinx dev boards
Signed-off-by: Alex Forencich <alex@alexforencich.com>
2022-05-18 19:36:12 -07:00
Alex Forencich
d575230c27 Fix race condition while taking down port
Signed-off-by: Alex Forencich <alex@alexforencich.com>
2022-05-13 15:56:26 -07:00
Alex Forencich
9653caf09b Add 25G mqnic design for Cisco Nexus K3P-Q 2022-05-09 14:02:13 -07:00
Alex Forencich
ba9ef590b7 Use Cisco Nexus part numbers for Cisco Nexus boards
Signed-off-by: Alex Forencich <alex@alexforencich.com>
2022-05-09 13:43:47 -07:00
Alex Forencich
7ee0a661bd modules/mqnic: Add kernel version check for ndetdev ioctl change
Signed-off-by: Alex Forencich <alex@alexforencich.com>
2022-05-05 11:19:53 -07:00
Alex Forencich
c2fea3a616 Add port register blocks with support for PHY link status reporting
Signed-off-by: Alex Forencich <alex@alexforencich.com>
2022-05-04 09:03:37 -07:00
Alex Forencich
56641b3471 modules/mqnic: Export symbols
Signed-off-by: Alex Forencich <alex@alexforencich.com>
2022-04-25 00:47:37 -07:00
Alex Forencich
e4de3c2fb5 modules/mqnic: Consistent naming of driver functions and structs
Signed-off-by: Alex Forencich <alex@alexforencich.com>
2022-04-24 23:01:15 -07:00
Alex Forencich
cc9d445005 Move driver-specific code out of mqnic_hw.h
Signed-off-by: Alex Forencich <alex@alexforencich.com>
2022-04-24 22:54:04 -07:00
Alex Forencich
2bd8350276 Add RX queue mapping module
Signed-off-by: Alex Forencich <alex@alexforencich.com>
2022-04-23 00:12:22 -07:00
Alex Forencich
1b3caa1f0f Fix reg block enumeration to properly handle NULL register blocks
Signed-off-by: Alex Forencich <alex@alexforencich.com>
2022-04-22 23:27:15 -07:00
Alex Forencich
f4d2662dff Fix find_reg_block handling of NULL register blocks
Signed-off-by: Alex Forencich <alex@alexforencich.com>
2022-04-22 23:25:15 -07:00
Alex Forencich
5ae58e751f modules/mqnic: Use eth_hw_addr_set when available
Signed-off-by: Alex Forencich <alex@alexforencich.com>
2022-04-22 18:46:40 -07:00
Alex Forencich
65a986cc89 modules/mqnic: Add support for extension kernel modules using the auxiliary bus
Signed-off-by: Alex Forencich <alex@alexforencich.com>
2022-04-21 13:18:00 -07:00
Alex Forencich
7f8bbe30de Add application ID
Signed-off-by: Alex Forencich <alex@alexforencich.com>
2022-04-21 13:15:45 -07:00
Alex Forencich
dbe0dc70ee modules/mqnic: Remove obsolete PHC entries
Signed-off-by: Alex Forencich <alex@alexforencich.com>
2022-04-20 21:29:56 -07:00
Alex Forencich
030281b7fc modules/mqnic: Simplify kernel module makefile
Signed-off-by: Alex Forencich <alex@alexforencich.com>
2022-04-18 22:55:07 -07:00
Alex Forencich
69201fbf82 modules/mqnic: Clean up error handling in common probe; do not fail probe if interface creation fails so userspace tools will still be usable via driver
Signed-off-by: Alex Forencich <alex@alexforencich.com>
2022-04-16 23:30:39 -07:00
Alex Forencich
5133bf5d27 modules/mqnic: Clear board_ops after deinit
Signed-off-by: Alex Forencich <alex@alexforencich.com>
2022-04-16 23:25:07 -07:00
Alex Forencich
2cf8a910b2 modules/mqnic: Clean-up and error handling improvements in PHC registration
Signed-off-by: Alex Forencich <alex@alexforencich.com>
2022-04-16 23:23:20 -07:00
Alex Forencich
a6affe4190 modules/mqnic: Add driver support for XUP-P3R board
Signed-off-by: Alex Forencich <alex@alexforencich.com>
2022-04-16 15:21:11 -07:00
Alex Forencich
58bcea2114 modules/mqnic: Add driver support for DNPCIe_40G_KU_LL_2QSFP board
Signed-off-by: Alex Forencich <alex@alexforencich.com>
2022-04-16 15:20:44 -07:00
Alex Forencich
07f3924b75 modules/mqnic: Add missing request_module
Signed-off-by: Alex Forencich <alex@alexforencich.com>
2022-04-16 15:20:04 -07:00
Alex Forencich
e167423ed4 modules/mqnic: Include proper indices in messages
Signed-off-by: Alex Forencich <alex@alexforencich.com>
2022-04-16 15:19:20 -07:00
Alex Forencich
eb530475fb More expressive flash format register
Signed-off-by: Alex Forencich <alex@alexforencich.com>
2022-04-15 18:38:01 -07:00
Alex Forencich
e9b62594c0 modules/mqnic: Fix typo in reading nominal clock period registers
Signed-off-by: Alex Forencich <alex@alexforencich.com>
2022-04-11 10:55:07 -07:00
Joachim Foerster
26c70bbb8a modules/mqnic/: Add platform driver support
Signed-off-by: Joachim Foerster <joachim.foerster@missinglinkelectronics.com>
2022-04-07 17:14:25 +02:00
Alex Forencich
cbd9d0dfc6 Expose port and scheduler block counts in IF control block; update driver model, driver, and userspace tools to handle scheduler blocks separately from ports 2022-03-28 17:23:27 -07:00
Alex Forencich
6daf1171b5 Improve ioctl implementation to support arbitrary number of regions 2022-03-26 00:24:02 -07:00
Alex Forencich
2babcdd16e Fix indentation 2022-03-26 00:18:07 -07:00
Alex Forencich
8fbe46aa31 Update ethtool API implementation 2022-03-22 23:48:13 -07:00
Alex Forencich
c118565d21 Fix EEPROM-related error handling in ethtool interface code 2022-03-20 23:07:45 -07:00
Alex Forencich
623b758598 Print PCIe bridge information during driver load 2022-03-15 17:55:29 -07:00
Alex Forencich
2ca96463fe Add driver debug print for number of configured IRQs 2022-03-04 23:55:51 -08:00
Alex Forencich
6e716af299 Set PTP clock name 2022-02-02 18:41:19 -08:00
Alex Forencich
d506c9305a Fix pointer updating for correct teardown behavior 2022-01-16 00:04:53 -08:00
Alex Forencich
137a6778da Combine interface control blocks 2022-01-15 21:53:13 -08:00
Alex Forencich
0f82e0c5f3 Fix ethtool firmware version number reporting 2022-01-10 11:18:58 -08:00
Alex Forencich
136b0ee6ae Increase init delay for Alveo BMC 2022-01-05 22:42:36 -08:00
Alex Forencich
a4a26e7bc4 Fix register accesses 2022-01-05 19:38:56 -08:00
Alex Forencich
335a5e890b Initial implementation of shared interface datapath 2021-12-31 14:33:31 -08:00
Alex Forencich
ce21774f06 Register space reorganization 2021-12-29 22:31:46 -08:00
Alex Forencich
2091ef8c42 Fix dev_port assignment 2021-12-29 14:29:55 -08:00
Alex Forencich
8b219d3cad Fix I2C client forwarding to netdevs 2021-12-25 01:40:08 -08:00
Alex Forencich
fb258467e7 Unwrap short lines 2021-12-24 00:02:20 -08:00
Alex Forencich
a7cb23da62 Separate common probe/remove implementation from PCI-specific probe/remove 2021-12-24 00:02:08 -08:00