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

60 Commits

Author SHA1 Message Date
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
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
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
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
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
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
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
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
623b758598 Print PCIe bridge information during driver load 2022-03-15 17:55:29 -07: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
Alex Forencich
0b7cbe5b05 Peel off ID management code 2021-12-23 23:48:57 -08:00
Joachim Foerster
508b4cf39b modules/mqnic/: Make number of allocated queue entries configurable via module parameters
This may be complemented or replaced by making use of the appropriate ethtool
API in the future, of course.

Signed-off-by: Joachim Foerster <joachim.foerster@missinglinkelectronics.com>
2021-12-15 23:29:02 -08:00
Joachim Foerster
f5f40297e3 modules/mqnic/: Fix, need to initialize per instance mutex before netdev registration
struct mqnic::state_lock is used in netdev callbacks, which go "live"
after a netdev has been registered (via mqnic_init_netdev()).

Signed-off-by: Joachim Foerster <joachim.foerster@missinglinkelectronics.com>
2021-12-15 23:29:02 -08:00
Alex Forencich
11f31c896c Split interface from net_device 2021-12-12 17:28:43 -08:00
Alex Forencich
413238f81c Refactor interrupt handling 2021-12-12 13:34:33 -08:00
Alex Forencich
b340d2aed0 Use min_t for range enforcement 2021-12-11 01:37:59 -08:00
Alex Forencich
53dfd68338 Use MQNIC_MAX_IRQ define when allocating MSI IRQs 2021-12-11 01:27:44 -08:00
Alex Forencich
ddeb8bad94 Use atomic notifier chain for interrupt handling 2021-12-10 21:05:31 -08:00
Alex Forencich
32a82929c6 Normalize create/destroy methods 2021-12-10 21:02:57 -08:00
Alex Forencich
c739b05b69 Remove unnecessary priv parameters 2021-12-10 20:59:44 -08:00
Alex Forencich
d2663fd711 Print PCIe subsytem IDs 2021-11-02 14:40:32 -07:00
Alex Forencich
27c9241a69 Update header comment, add SPDX license identifiers 2021-10-21 14:55:48 -07:00
Alex Forencich
79f778d85a Remove out of memory messages; kernel should print stack trace when allocation fails 2021-10-21 14:01:29 -07:00
Alex Forencich
2adaf820b5 More kernel module coding style updates 2021-10-21 13:54:00 -07:00
Alex Forencich
5b49f09baa Fix kernel module coding style 2021-10-08 18:31:53 -07:00
Alex Forencich
c249081dd2 Use DRIVER_NAME define 2021-10-01 23:45:06 -07:00
Alex Forencich
0965c77b8e Remove MODULE_SUPPORTED_DEVICE, which was never implemented and was removed in kernel version 5.12 2021-10-01 17:31:15 -07:00
Alex Forencich
c8dd50b051 pcie_print_link_status was added in kernel version 4.17 2021-09-24 17:05:35 -07:00
Alex Forencich
2442ff65c5 Support application and RAM bars 2021-09-09 17:50:44 -07:00
Alex Forencich
d0976f193b Use correct type 2021-09-09 17:49:11 -07:00
Alex Forencich
5f7b0292fc Print more PCIe information 2021-08-30 01:27:25 -07:00
Alex Forencich
9c8e8430ab Include misc device name in debug output 2021-03-30 15:05:54 -07:00
Alex Forencich
6b142d36c2 Pull board-specific code into mqnic_board.c and refactor I2C code 2021-02-01 20:10:48 -08:00
Alex Forencich
df32217dc8 Use MAC list instead of base MAC for more flexibility 2021-01-31 22:25:24 -08:00
Alex Forencich
9ceacea0e0 Fix types 2021-01-13 20:18:01 -08:00
Alex Forencich
945b2d3206 Add ethtool support for reading module EEPROMs 2020-09-19 17:25:58 -07:00
Alex Forencich
ac9dac0365 Use ARRAY_SIZE macro 2020-08-26 01:40:31 -07:00
Alex Forencich
e1456fb03b Use correct helper function 2020-08-18 23:23:52 -07:00
Alex Forencich
39e55a1499 Rename PCI driver struct 2020-08-18 23:22:55 -07:00
Alex Forencich
5cc5aea95e Rename PCI-related functions 2020-08-18 01:21:06 -07:00
Alex Forencich
b6e5216ab4 Add IRQ mapping 2020-08-17 23:53:31 -07:00
Alex Forencich
907bb68a99 Use misc device properly 2020-07-31 00:47:43 -07:00
Alex Forencich
6edce8c984 Add BAR size check 2020-07-30 23:48:52 -07:00
Alex Forencich
ae57fc941c Add missing error code 2020-07-30 23:48:26 -07:00
Alex Forencich
5a9117cf8b Remove unused code 2020-07-30 23:32:16 -07:00