Lines Matching refs:mod
35 struct rsnd_mod mod; member
54 #define rsnd_mod_to_dma(_mod) container_of((_mod), struct rsnd_dma, mod)
69 static void __rsnd_dmaen_complete(struct rsnd_mod *mod, in __rsnd_dmaen_complete() argument
78 struct rsnd_mod *mod = data; in rsnd_dmaen_complete() local
80 rsnd_mod_interrupt(mod, __rsnd_dmaen_complete); in rsnd_dmaen_complete()
97 static int rsnd_dmaen_stop(struct rsnd_mod *mod, in rsnd_dmaen_stop() argument
101 struct rsnd_dma *dma = rsnd_mod_to_dma(mod); in rsnd_dmaen_stop()
110 static int rsnd_dmaen_cleanup(struct rsnd_mod *mod, in rsnd_dmaen_cleanup() argument
114 struct rsnd_dma *dma = rsnd_mod_to_dma(mod); in rsnd_dmaen_cleanup()
130 static int rsnd_dmaen_prepare(struct rsnd_mod *mod, in rsnd_dmaen_prepare() argument
134 struct rsnd_dma *dma = rsnd_mod_to_dma(mod); in rsnd_dmaen_prepare()
159 static int rsnd_dmaen_start(struct rsnd_mod *mod, in rsnd_dmaen_start() argument
163 struct rsnd_dma *dma = rsnd_mod_to_dma(mod); in rsnd_dmaen_start()
205 rsnd_mod_name(mod), in rsnd_dmaen_start()
241 struct rsnd_mod *mod, char *x) in rsnd_dma_request_channel() argument
250 if (i == rsnd_mod_id_raw(mod) && (!chan)) in rsnd_dma_request_channel()
299 static int rsnd_dmaen_pointer(struct rsnd_mod *mod, in rsnd_dmaen_pointer() argument
304 struct rsnd_dma *dma = rsnd_mod_to_dma(mod); in rsnd_dmaen_pointer()
373 struct rsnd_mod *mod) in rsnd_dmapp_get_id() argument
383 if ((mod == ssi) || in rsnd_dmapp_get_id()
384 (mod == ssiu)) { in rsnd_dmapp_get_id()
389 id = (rsnd_mod_id(mod) * 8) + busif; in rsnd_dmapp_get_id()
390 } else if (mod == src) { in rsnd_dmapp_get_id()
393 id = rsnd_mod_id(mod); in rsnd_dmapp_get_id()
394 } else if (mod == dvc) { in rsnd_dmapp_get_id()
397 id = rsnd_mod_id(mod); in rsnd_dmapp_get_id()
403 dev_err(dev, "unknown connection (%s)\n", rsnd_mod_name(mod)); in rsnd_dmapp_get_id()
425 struct rsnd_mod *mod = rsnd_mod_get(dma); in rsnd_dmapp_write() local
426 struct rsnd_priv *priv = rsnd_mod_to_priv(mod); in rsnd_dmapp_write()
437 struct rsnd_mod *mod = rsnd_mod_get(dma); in rsnd_dmapp_read() local
438 struct rsnd_priv *priv = rsnd_mod_to_priv(mod); in rsnd_dmapp_read()
446 struct rsnd_mod *mod = rsnd_mod_get(dma); in rsnd_dmapp_bset() local
447 struct rsnd_priv *priv = rsnd_mod_to_priv(mod); in rsnd_dmapp_bset()
458 static int rsnd_dmapp_stop(struct rsnd_mod *mod, in rsnd_dmapp_stop() argument
462 struct rsnd_dma *dma = rsnd_mod_to_dma(mod); in rsnd_dmapp_stop()
476 static int rsnd_dmapp_start(struct rsnd_mod *mod, in rsnd_dmapp_start() argument
480 struct rsnd_dma *dma = rsnd_mod_to_dma(mod); in rsnd_dmapp_start()
513 struct rsnd_mod *mod) in rsnd_dmapp_debug_info() argument
515 struct rsnd_priv *priv = rsnd_mod_to_priv(mod); in rsnd_dmapp_debug_info()
517 struct rsnd_dma *dma = rsnd_mod_to_dma(mod); in rsnd_dmapp_debug_info()
576 struct rsnd_mod *mod, in rsnd_gen2_dma_addr() argument
583 int is_ssi = !!(rsnd_io_to_mod_ssi(io) == mod) || in rsnd_gen2_dma_addr()
584 !!(rsnd_io_to_mod_ssiu(io) == mod); in rsnd_gen2_dma_addr()
589 int id = rsnd_mod_id(mod); in rsnd_gen2_dma_addr()
650 struct rsnd_mod *mod, in rsnd_dma_addr() argument
661 if (!mod) in rsnd_dma_addr()
664 return rsnd_gen2_dma_addr(io, mod, is_play, is_from); in rsnd_dma_addr()
679 struct rsnd_mod *mod[MOD_MAX]; in rsnd_dma_of_path() local
712 mod[i] = NULL; in rsnd_dma_of_path()
735 mod[idx++] = mod_start; in rsnd_dma_of_path()
738 mod[idx++] = src; in rsnd_dma_of_path()
741 mod[idx++] = ctu; in rsnd_dma_of_path()
744 mod[idx++] = mix; in rsnd_dma_of_path()
747 mod[idx++] = dvc; in rsnd_dma_of_path()
751 mod[idx] = mod_end; in rsnd_dma_of_path()
760 *mod_from = mod[idx - 1]; in rsnd_dma_of_path()
761 *mod_to = mod[idx]; in rsnd_dma_of_path()
763 *mod_from = mod[0]; in rsnd_dma_of_path()
764 *mod_to = mod[1]; in rsnd_dma_of_path()
770 rsnd_mod_name(mod[i] ? mod[i] : &mem), in rsnd_dma_of_path()
771 (mod[i] == *mod_from) ? " from" : in rsnd_dma_of_path()
772 (mod[i] == *mod_to) ? " to" : ""); in rsnd_dma_of_path()
776 static int rsnd_dma_alloc(struct rsnd_dai_stream *io, struct rsnd_mod *mod, in rsnd_dma_alloc() argument
801 rsnd_dma_of_path(mod, io, is_play, &mod_from, &mod_to); in rsnd_dma_alloc()
852 int rsnd_dma_attach(struct rsnd_dai_stream *io, struct rsnd_mod *mod, in rsnd_dma_attach() argument
856 int ret = rsnd_dma_alloc(io, mod, dma_mod); in rsnd_dma_attach()