Netdev List
 help / color / mirror / Atom feed
* [RFC] Appropriate subsystem/UAPI for Semtech SX126x packet radio support
@ 2026-09-20 21:15 i.n.a
  2026-09-20 21:38 ` Andrew Lunn
  0 siblings, 1 reply; 6+ messages in thread
From: i.n.a @ 2026-09-20 21:15 UTC (permalink / raw)
  To: netdev@vger.kernel.org; +Cc: linux-wpan@vger.kernel.org

Hi,

I'm working on a general-purpose Linux driver for the Semtech SX126x family of sub-GHz radio transceivers, initially targeting the SX1262.

Semtech provides a portable C driver for the radio, with the platform-specific interface abstracted behind read, write, reset and wakeup operations:

https://github.com/Lora-net/sx126x_driver

I'm currently implementing the Linux side using SPI, GPIO and IRQ infrastructure.

The SX126x supports LoRa and (G)FSK packet modes, but isn't inherently tied to a particular higher-level protocol. My intention is therefore to keep protocols such as LoRaWAN, AX.25 and Reticulum outside the hardware driver and expose generic packet TX/RX, PHY configuration, radio state and receive metadata such as RSSI/SNR.

I was considering exposing the radio as a character device, for example `/dev/sx126x0`, with a small userspace API for configuration and packet I/O. However, before defining an out-of-tree UAPI that may turn out to be the wrong abstraction, I'd appreciate some guidance:

1.  Is there an existing Linux subsystem suitable for this class of packet radio?
2.  If not, would a character device be an appropriate interface, or is there another abstraction I should investigate?
3.  Would it make sense for the hardware driver to remain protocol-agnostic, with networking/protocol interfaces implemented above it?

The aim is for the driver to be generic across SX1261/SX1262/SX1268 hardware rather than tied to a particular board. I'm also interested in supporting different transports where practical; my initial hardware is SPI-connected.

I wanted to ask about the architecture early, before too much code or a userspace ABI becomes established.

Thanks,
Ina

^ permalink raw reply	[flat|nested] 6+ messages in thread
* Re: [RFC] Appropriate subsystem/UAPI for Semtech SX126x packet radio support
@ 2026-09-20 21:50 i.n.a
  2026-09-20 22:15 ` Andrew Lunn
  0 siblings, 1 reply; 6+ messages in thread
From: i.n.a @ 2026-09-20 21:50 UTC (permalink / raw)
  To: andrew@lunn.ch; +Cc: linux-wpan@vger.kernel.org, netdev@vger.kernel.org

> You want to make whatever API you design vendor independent.

Thanks, that's a good point. I'll keep the API vendor-independent. Is there an existing kernel abstraction you'd suggest as a starting point?

Thanks,
Ina

^ permalink raw reply	[flat|nested] 6+ messages in thread
* Re: [RFC] Appropriate subsystem/UAPI for Semtech SX126x packet radio support
@ 2026-09-20 23:06 i.n.a
  2026-09-24  1:32 ` Jakub Kicinski
  0 siblings, 1 reply; 6+ messages in thread
From: i.n.a @ 2026-09-20 23:06 UTC (permalink / raw)
  To: andrew@lunn.ch; +Cc: linux-wpan@vger.kernel.org, netdev@vger.kernel.org

>Is stacking protocols on top of the MAC that different to IEEE
802.15.4?

Had a look through `mac802154` and `ieee802154_ops`, the hardware boundary does look quite similar, particularly packet TX/RX, start/stop, TX power and energy detection.

The main differences seem to be the 802.15.4-specific parts such as channel/page addressing, CSMA parameters and address filtering, versus PHY-specific configuration for LoRa/GFSK.

Would it make sense to investigate factoring out a small generic packet-radio layer beneath the MAC-specific interfaces?

Thanks,
Ina

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2026-09-24  1:32 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-09-20 21:15 [RFC] Appropriate subsystem/UAPI for Semtech SX126x packet radio support i.n.a
2026-09-20 21:38 ` Andrew Lunn
  -- strict thread matches above, loose matches on Subject: below --
2026-09-20 21:50 i.n.a
2026-09-20 22:15 ` Andrew Lunn
2026-09-20 23:06 i.n.a
2026-09-24  1:32 ` Jakub Kicinski

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox