21#define NX_SPI_MEMORY_TX_FIXED 1U
22#define NX_SPI_MEMORY_RX_FIXED 2U
51 uint8_t syscall_ceiling);
78 uint8_t memory_flags);
116 const uint8_t* tx, uint8_t* rx,
118 size_t* transferred);
149 uint8_t* rx,
size_t length,
187 uint8_t memory_flags);
274 uint8_t syscall_ceiling);
Caller-owned admission, borrow, settlement and stable cancellation.
nx_result_t nx_spi_endpoint_start_admitted(const nx_spi_endpoint_t *endpoint, nx_spi_request_t *request)
Start an adapter-admitted QUEUED request without readmission.
struct nx_spi_port nx_spi_port_t
struct nx_spi_endpoint nx_spi_endpoint_t
nx_result_t nx_spi_port_attach_wake(const nx_spi_port_t *port, const nx_irq_wake_t *wake, uint8_t syscall_ceiling)
Attach an optional hint sink to asynchronous bus IRQ publishers.
nx_result_t nx_spi_endpoint_submit(const nx_spi_endpoint_t *endpoint, nx_spi_request_t *request)
Submit one finite asynchronous whole-CS transaction.
nx_result_t nx_spi_port_recover(const nx_spi_port_t *port)
Recover an idle SPI controller after its retained fault.
nx_result_t nx_spi_endpoint_transfer(const nx_spi_endpoint_t *endpoint, const uint8_t *tx, uint8_t *rx, size_t length, nx_time_us_t deadline, size_t *transferred)
Execute one bounded full-duplex 8-bit polling transaction.
nx_result_t nx_spi_request_prepare(nx_spi_request_t *request, const uint8_t *tx, uint8_t *rx, size_t length, nx_time_us_t deadline)
Prepare an unborrowed finite request without copying buffers.
nx_result_t nx_spi_endpoint_submit_memory(const nx_spi_endpoint_t *endpoint, nx_spi_request_t *request, uint8_t memory_flags)
Submit explicit incrementing or single-cell DMA memory.
nx_result_t nx_spi_port_cancel(const nx_spi_port_t *port, nx_spi_request_t *request)
Request cancellation without revoking DMA/CS buffer loans.
void nx_spi_port_service(const nx_spi_port_t *port)
Advance one asynchronous bus under its single task executor.
nx_result_t nx_spi_port_stop(const nx_spi_port_t *port)
Close admission and retain active sources until full drain.
bool nx_spi_endpoint_on_port(const nx_spi_endpoint_t *endpoint, const nx_spi_port_t *port)
Verify an endpoint belongs to the serviced bus.
nx_result_t
Operation result; success at submission means admission only.
Optional immutable wake target borrowed by an IRQ provider.
Caller-owned request metadata, without payload or callbacks.
Shared read-only methods using one provider state.
nx_result_t(* start_admitted)(void *context, nx_spi_request_t *request)
nx_result_t(* transfer)(void *context, const uint8_t *tx, uint8_t *rx, size_t length, nx_time_us_t deadline, size_t *transferred)
nx_result_t(* submit)(void *context, nx_spi_request_t *request)
bool(* on_port)(const void *context, const nx_spi_port_t *port)
nx_result_t(* submit_memory)(void *context, nx_spi_request_t *request, uint8_t memory_flags)
Immutable interface pointing to caller-owned state.
const nx_spi_endpoint_ops_t * ops
Shared read-only methods using one provider state.
nx_result_t(* attach_wake)(void *context, const nx_irq_wake_t *wake, uint8_t syscall_ceiling)
nx_result_t(* stop)(void *context)
nx_result_t(* cancel)(void *context, nx_spi_request_t *request)
void(* service)(void *context)
nx_result_t(* recover)(void *context)
Immutable interface pointing to caller-owned state.
Caller-owned finite SPI request with one whole-CS interval.
uint64_t nx_time_us_t
Microseconds in one boot/clock domain; no wall-clock semantics.
Explicit borrowed IRQ wake target and syscall-ceiling check.