Merge pull request #3814 from cesanta/spi

Rename mg_tcpip_spi to mg_spi and move it to periph.h
This commit is contained in:
Sergey Lyubka authored and GitHub committed 2026-12-03 09:45:53 +00:00
commit 9ac1106e74
23 files changed
+104 -106

No files matched your search

-13
View File
@@ -166,19 +166,6 @@ extern const uint8_t mcast_addr[6]; // Multicast MAC address programmed by driv
#include "drivers/xmc.h"
#include "drivers/xmc7.h"
// SPI bus abstraction for SPI-attached network chips (e.g. W5500).
// Populate and assign to the driver's driver_data field.
struct mg_tcpip_spi {
void *spi; // Opaque SPI bus handle passed to all callbacks
void (*begin)(void *); // Assert chip-select (start of transaction)
void (*end)(void *); // Deassert chip-select (end of transaction)
void (*txn)(void *, uint8_t *write, uint8_t *read, size_t); // Full-duplex transfer: write and read len bytes simultaneously
};
// SPI bus for SPI-attached network chips, defined by the application.
// Used by the drivers' INIT macros, e.g. MG_TCPIP_DRIVER_W5500_INIT
extern struct mg_tcpip_spi mg_spi;
// Alignment attributes for DMA-capable Ethernet descriptor buffers.
// Use these on driver RX/TX descriptor arrays where the hardware requires
// specific alignment.