23 Commits

Author SHA1 Message Date
Sebastian Huber
9e87868ec2 if_atsam: Recover from receive freezes
Under unknown conditions the receive path ended up in a frozen state.
In this state, the DMA and driver descriptor head were equal and all
receive descriptors had the used bit set.  So, the DMA was unable to
store received frames.  However, the receive daemon was never woken up
to refill the receive buffers.  It seems that the RXUBR interrupt can be
used to recover from this state.

Update #4652.
2022-06-01 09:59:10 +02:00
Sebastian Huber
eea3f0eec3 if_atsam: Shorten sysctl names
Update #4652.
2022-06-01 09:59:10 +02:00
Sebastian Huber
1ed12b8af7 if_atsam: Add tx/rx desc sysctls
Update #4652.
2022-06-01 09:59:10 +02:00
Sebastian Huber
eb58e82197 if_atsam: Add register sysctls
Update #4652.
2022-06-01 09:59:10 +02:00
Sebastian Huber
5650e92685 if_atsam: Allow stats reset via sysctl
Update #4652.
2022-06-01 09:59:09 +02:00
Sebastian Huber
38e1610af2 if_atsam: Fix interface stop
Close #4652.
2022-05-11 16:05:46 +02:00
Sebastian Huber
8039d70d94 if_atsam: Support transmit bpf
Update #4652.
2022-05-11 16:05:26 +02:00
Sebastian Huber
5c4ac7a917 if_atsam: Do not use rtems_bsdnet_newproc()
Update #4652.
2022-05-11 16:05:26 +02:00
Sebastian Huber
202502a397 if_atsam: Support IFCAP_VLAN_HWTAGGING
This is required to enable checksum offload for vlan interfaces.

Update #4652.
2022-05-11 16:05:26 +02:00
Sebastian Huber
62fc2b6a03 if_atsam: Optimize receive
Do not use the interface mutex in the receive loop.  Avoid multiple
reads of DMA descriptor words.  Use a compile-time constant for the
receive DMA descriptor count to simplify calculations.

Update #4652.
2022-05-11 16:05:26 +02:00
Sebastian Huber
6be24bd16a if_atsam: Optimize transmit
Use the transmit interface handler to avoid a transmit task/interrupt.
Use a compile-time constant for the transmit DMA descriptor count to
simplify calculations.

Update #4652.
2022-05-11 16:05:26 +02:00
Sebastian Huber
3150b37022 if_atsam: Add multicast support
Update #4652.
2022-05-11 16:05:26 +02:00
Sebastian Huber
f4efcbfda5 if_atsam: Fix start/stop of interface
Update #4652.
2022-05-11 16:05:26 +02:00
Sebastian Huber
339ba3dd9f if_atsam: Fix interrupt setup
The interrupt is enabled by rtems_interrupt_handler_install().

Update #4652.
2022-05-11 16:05:26 +02:00
Sebastian Huber
5b62a8bfa1 if_atsam: Do not disable the Ethernet CRC
The Ethernet CRC and padding must be always generated by the MAC.

Update #4652.
2022-05-11 16:05:26 +02:00
Sebastian Huber
c58bb6095a if_atsam: Enable all capabilities
Update #4652.
2022-05-11 16:05:25 +02:00
Sebastian Huber
73c764a70e if_atsam: Fix warnings
Update #4652.
2022-05-11 16:05:25 +02:00
Sebastian Huber
1e989998de if_atsam: Remove WDT_Disable()
The watchdog timer (WDT) can be configure only once.  Do not touch it in
the BSP since the application may want to use it.
2019-06-13 08:54:53 +02:00
Christian Mauderer
b2a210ca3e if_atsam: Add checksum offload. 2018-03-21 09:14:25 +01:00
Christian Mauderer
c6f4aa65ff if_atsam: Allow fixed MII settings. 2017-09-22 10:19:25 +02:00
Christian Mauderer
0190cfdd55 if_atsam: Move statistics to sysctl. 2017-09-22 10:17:26 +02:00
Christian Mauderer
80a7fe68a1 if-atsam: Port to rtems-libbsd. 2017-09-22 10:17:24 +02:00
Christian Mauderer
b16eca96c3 rtemsbsd/if-atsam: Copy from RTEMS.
Copied from RTEMS commit 146adb1edf from 17.07.2017.
2017-09-22 10:15:52 +02:00