I've lost a word: is there a name for a piece of hardware, that takes an address and amount of bytes to read, and streams those bytes back to you while managing the whole doing of the bus cycles, tracking when to stop and all that?
-
I've lost a word: is there a name for a piece of hardware, that takes an address and amount of bytes to read, and streams those bytes back to you while managing the whole doing of the bus cycles, tracking when to stop and all that?
It's not quite a blitter, it's not quite a DMA engine, ... Is it just not something that has a name because it's too simple?
-
Context being I have some memory ports, they already include the arbitration, bus access logic and all that, so each one is dedicated to one user and you submit a memory operation request and get a response back. I'm bolting an extra adapter onto that which takes that request/response API and changes it so the request is base+amount and the response is a stream of results, because I've been rewriting that same thing multiple times now.
-
@danderson I'd count that as a "DMA channel" if not a full DMA engine? Because what is a DMA engine but a collection of DMA channels?
Having a dedicated channel per peripheral isn't unprecedented either, since the PS1 and PS2 both do exactly that. They just happen to centralize the control logic in a big DMA controller block so it can share some common logic, rather than distributing it throughout the core.
-
@becomethewaifu Yeah, maybe? Sibling thread went in the same direction that this is maybe just a DMA engine in a shape I don't immediately recognize. Part of what's weirding me out is that in this particular design there is no CPU or entity that would be responsible for the alternative "indirect memory access", so calling something DMA is a bit odd because it's all DMA, in a sense...
-
@becomethewaifu Part of the difficulty I think, is that it's possible the name for this is "nothing, that's just a bit of a peripheral's memory access logic, why would it have a name". I'm factoring it out because in this codebase it can be pulled out into a handy helper for reuse, but maybe it doesn't have a specific name because it's just "a small pile of registers that stuff interacting with memory usually has", not worthy of a name. But I need one for my library module :neocat_sad:
-
@danderson I mean, most DMA engines are state machines, not CPUs, and the logic for converting from request-response to "request N->push N items whenever" sounds a lot like a DMA state machine to me.
-
@becomethewaifu Yeah that's very fair! When I think DMA engine I think "that specific shape of thing in a typical SoC", but I think I'm fixating on a specific implementation shape as the only "real" DMA engine.
And really if this were in a design that featured a more recognizable CPU component, then I think I'd have no problem calling this thing either a DMA engine or channel! I think I got hung up on the lack of CPU.
Thanks for the wisdom! Some name containing 'DMA' it is.
-
@becomethewaifu ok and actually as soon as I got over the name and started implementing it, I realized I need slightly fancy features like being able to wrap at a given memory addr, run reads forwards or back, and so on. And suddenly for whatever reason my brain's immediately "oh yeah this is definitely a DMA engine now!"
Thanks again!