-
Notifications
You must be signed in to change notification settings - Fork 105
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
adding credit to @datdenkikniet (Johannes Draaijer)
- Loading branch information
Harishguna Satgunarajah
committed
Sep 21, 2023
1 parent
98597be
commit 0f0c47c
Showing
12 changed files
with
48 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,7 @@ | ||
//! This implementation is derived from 0BSD-relicensed work done by | ||
//! Johannes Draaijer <[email protected]> for the | ||
//! [`stm32-eth`](https://github.com/stm32-rs/stm32-eth) project | ||
#[cfg(feature = "ptp")] | ||
use crate::ptp::Timestamp; | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -19,6 +19,10 @@ | |
//! > want to enable the cache, the simplest method would be to mark SRAM3 | ||
//! > as uncacheable via the MPU. | ||
//! | ||
//! This implementation is derived from 0BSD-relicensed work done by | ||
//! Johannes Draaijer <[email protected]> for the | ||
//! [`stm32-eth`](https://github.com/stm32-rs/stm32-eth) project | ||
//! | ||
//! [quartiq/stabilizer]: https://github.com/quartiq/stabilizer | ||
//! [notes]: https://github.com/quartiq/stabilizer/commit/ab1735950b2108eaa8d51eb63efadcd2e25c35c4 | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,6 +5,10 @@ | |
//! - SMSC LAN8742a | ||
//! - Micrel KSZ8081R | ||
//! | ||
//! This implementation is derived from 0BSD-relicensed work done by | ||
//! Johannes Draaijer <[email protected]> for the | ||
//! [`stm32-eth`](https://github.com/stm32-rs/stm32-eth) project | ||
//! | ||
//! # Examples | ||
//! | ||
//! - [Simple link checker for the Nucleo-H743ZI2](https://github.com/stm32-rs/stm32h7xx-hal/blob/master/examples/ethernet-nucleo-h743zi2.rs) | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,6 +3,10 @@ | |
/// This packet ID can be used to obtain information about a specific | ||
/// ethernet frame (either sent or received) from the DMA. | ||
/// | ||
//! This implementation is derived from 0BSD-relicensed work done by | ||
//! Johannes Draaijer <[email protected]> for the | ||
//! [`stm32-eth`](https://github.com/stm32-rs/stm32-eth) project | ||
#[cfg_attr( | ||
feature = "ptp", | ||
doc = " | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,8 @@ | ||
//! This implementation is derived from 0BSD-relicensed work done by | ||
//! Johannes Draaijer <[email protected]> for the | ||
//! [`stm32-eth`](https://github.com/stm32-rs/stm32-eth) project | ||
|
||
//TODO remove | ||
// this is raw_descriptor | ||
use volatile_register::{RO, RW}; | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,7 @@ | ||
//! This implementation is derived from 0BSD-relicensed work done by | ||
//! Johannes Draaijer <[email protected]> for the | ||
//! [`stm32-eth`](https://github.com/stm32-rs/stm32-eth) project | ||
use core::sync::atomic::{self, Ordering}; | ||
|
||
use crate::ethernet::{raw_descriptor::RawDescriptor, Cache, PacketId}; | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,7 @@ | ||
//! This implementation is derived from 0BSD-relicensed work done by | ||
//! Johannes Draaijer <[email protected]> for the | ||
//! [`stm32-eth`](https://github.com/stm32-rs/stm32-eth) project | ||
pub use descriptor::RxDescriptor; | ||
|
||
use super::{raw_descriptor::DescriptorRing, PacketId}; | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,7 @@ | ||
//! This implementation is derived from 0BSD-relicensed work done by | ||
//! Johannes Draaijer <[email protected]> for the | ||
//! [`stm32-eth`](https://github.com/stm32-rs/stm32-eth) project | ||
use core::sync::atomic::{self, Ordering}; | ||
|
||
use crate::ethernet::{raw_descriptor::RawDescriptor, Cache, PacketId}; | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,7 @@ | ||
//! This implementation is derived from 0BSD-relicensed work done by | ||
//! Johannes Draaijer <[email protected]> for the | ||
//! [`stm32-eth`](https://github.com/stm32-rs/stm32-eth) project | ||
use super::{raw_descriptor::DescriptorRing, PacketId}; | ||
use crate::stm32::ETHERNET_DMA; | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,9 @@ | ||
//! PTP access and configuration. | ||
//! | ||
//! See [`EthernetPTP`] for a more details. | ||
//! This implementation is derived from 0BSD-relicensed work done by | ||
//! Johannes Draaijer <[email protected]> for the | ||
//! [`stm32-eth`](https://github.com/stm32-rs/stm32-eth) project | ||
use crate::ethernet::EthernetDMA; | ||
use crate::rcc::CoreClocks; | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,7 @@ | ||
//! This implementation is derived from 0BSD-relicensed work done by | ||
//! Johannes Draaijer <[email protected]> for the | ||
//! [`stm32-eth`](https://github.com/stm32-rs/stm32-eth) project | ||
/// The amount of nanoseconds per second. | ||
pub const NANOS_PER_SECOND: u32 = 1_000_000_000; | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,7 @@ | ||
//! This implementation is derived from 0BSD-relicensed work done by | ||
//! Johannes Draaijer <[email protected]> for the | ||
//! [`stm32-eth`](https://github.com/stm32-rs/stm32-eth) project | ||
use super::{Subseconds, NANOS_PER_SECOND}; | ||
|
||
/// A timestamp produced by the PTP periperhal | ||
|