<whitequark>
in libio. and the implementations, awkwardly, in sched.rs
<whitequark>
but i think now that rust has native async support, that's what should be used instead
<whitequark>
the whole artiq scheduler is a hack working around lack of nice async
<whitequark>
rjo: regarding peek. i don't feel comfortable providing you with two slices. that binds me hard to one specific internal representation.
<whitequark>
but i think i can give you a slice of slices.
<whitequark>
it's not currently possible to allocate a variable length slice in stable rust, but it will be, soon
<whitequark>
rjo: regarding DMA. i don't think that's possible.
<whitequark>
poll() takes a &mut SocketSet. if your code is running when the handler fires (which is very likely) you are probably borrowing a socket
<whitequark>
the ownership on that is kinda sketchy anyhow, the main problem being that access to any socket excludes all others
<whitequark>
so it might be possible to enable the DMA interrupt iff you have released the socket set
<whitequark>
that'd be easy. i can make an example for it, i think. but the ergonomics of using smoltcp without something like artiq's sched layer are unfortunate.
rohitksingh has quit [Ping timeout: 252 seconds]
cr1901_modern1 has joined #m-labs
cr1901_modern has quit [Ping timeout: 268 seconds]