Lines Matching refs:snd_sof_dev
115 struct snd_sof_dev;
147 int (*probe)(struct snd_sof_dev *sof_dev); /* mandatory */
148 int (*remove)(struct snd_sof_dev *sof_dev); /* optional */
149 int (*shutdown)(struct snd_sof_dev *sof_dev); /* optional */
152 int (*run)(struct snd_sof_dev *sof_dev); /* mandatory */
153 int (*stall)(struct snd_sof_dev *sof_dev, unsigned int core_mask); /* optional */
154 int (*reset)(struct snd_sof_dev *sof_dev); /* optional */
155 int (*core_get)(struct snd_sof_dev *sof_dev, int core); /* optional */
156 int (*core_put)(struct snd_sof_dev *sof_dev, int core); /* optional */
163 void (*write)(struct snd_sof_dev *sof_dev, void __iomem *addr,
165 u32 (*read)(struct snd_sof_dev *sof_dev,
167 void (*write64)(struct snd_sof_dev *sof_dev, void __iomem *addr,
169 u64 (*read64)(struct snd_sof_dev *sof_dev,
173 int (*block_read)(struct snd_sof_dev *sof_dev,
176 int (*block_write)(struct snd_sof_dev *sof_dev,
181 void (*mailbox_read)(struct snd_sof_dev *sof_dev,
184 void (*mailbox_write)(struct snd_sof_dev *sof_dev,
193 int (*send_msg)(struct snd_sof_dev *sof_dev,
197 int (*load_firmware)(struct snd_sof_dev *sof_dev); /* mandatory */
198 int (*load_module)(struct snd_sof_dev *sof_dev,
202 int (*pcm_open)(struct snd_sof_dev *sdev,
205 int (*pcm_close)(struct snd_sof_dev *sdev,
209 int (*pcm_hw_params)(struct snd_sof_dev *sdev,
215 int (*pcm_hw_free)(struct snd_sof_dev *sdev,
219 int (*pcm_trigger)(struct snd_sof_dev *sdev,
224 snd_pcm_uframes_t (*pcm_pointer)(struct snd_sof_dev *sdev,
228 int (*pcm_ack)(struct snd_sof_dev *sdev, struct snd_pcm_substream *substream); /* optional */
231 int (*ipc_msg_data)(struct snd_sof_dev *sdev,
236 int (*set_stream_data_offset)(struct snd_sof_dev *sdev,
241 int (*pre_fw_run)(struct snd_sof_dev *sof_dev); /* optional */
242 int (*post_fw_run)(struct snd_sof_dev *sof_dev); /* optional */
245 int (*parse_platform_ext_manifest)(struct snd_sof_dev *sof_dev,
249 int (*suspend)(struct snd_sof_dev *sof_dev,
251 int (*resume)(struct snd_sof_dev *sof_dev); /* optional */
252 int (*runtime_suspend)(struct snd_sof_dev *sof_dev); /* optional */
253 int (*runtime_resume)(struct snd_sof_dev *sof_dev); /* optional */
254 int (*runtime_idle)(struct snd_sof_dev *sof_dev); /* optional */
255 int (*set_hw_params_upon_resume)(struct snd_sof_dev *sdev); /* optional */
256 int (*set_power_state)(struct snd_sof_dev *sdev,
260 int (*set_clk)(struct snd_sof_dev *sof_dev, u32 freq); /* optional */
265 void (*dbg_dump)(struct snd_sof_dev *sof_dev,
267 void (*ipc_dump)(struct snd_sof_dev *sof_dev); /* optional */
268 int (*debugfs_add_region_item)(struct snd_sof_dev *sdev,
274 int (*trace_init)(struct snd_sof_dev *sdev,
277 int (*trace_release)(struct snd_sof_dev *sdev); /* optional */
278 int (*trace_trigger)(struct snd_sof_dev *sdev,
282 int (*get_bar_index)(struct snd_sof_dev *sdev,
284 int (*get_mailbox_offset)(struct snd_sof_dev *sdev);/* mandatory for common loader code */
285 int (*get_window_offset)(struct snd_sof_dev *sdev,
289 int (*machine_register)(struct snd_sof_dev *sdev,
291 void (*machine_unregister)(struct snd_sof_dev *sdev,
293 struct snd_soc_acpi_mach * (*machine_select)(struct snd_sof_dev *sdev); /* optional */
295 struct snd_sof_dev *sdev); /* optional */
298 int (*register_ipc_clients)(struct snd_sof_dev *sdev); /* optional */
299 void (*unregister_ipc_clients)(struct snd_sof_dev *sdev); /* optional */
313 void (*dsp_oops)(struct snd_sof_dev *sdev, const char *level, void *oops);
314 void (*dsp_stack)(struct snd_sof_dev *sdev, const char *level, void *oops,
334 struct snd_sof_dev *sdev;
386 int (*init)(struct snd_sof_dev *sdev);
387 void (*free)(struct snd_sof_dev *sdev);
388 void (*fw_crashed)(struct snd_sof_dev *sdev);
389 void (*suspend)(struct snd_sof_dev *sdev, pm_message_t pm_state);
390 int (*resume)(struct snd_sof_dev *sdev);
400 int (*ctx_save)(struct snd_sof_dev *sdev);
401 int (*ctx_restore)(struct snd_sof_dev *sdev);
402 int (*set_core_state)(struct snd_sof_dev *sdev, int core_idx, bool on);
418 int (*validate)(struct snd_sof_dev *sdev);
419 size_t (*parse_ext_manifest)(struct snd_sof_dev *sdev);
420 int (*load_fw_to_dsp)(struct snd_sof_dev *sdev);
421 int (*query_fw_configuration)(struct snd_sof_dev *sdev);
456 int (*tx_msg)(struct snd_sof_dev *sdev, void *msg_data, size_t msg_bytes,
458 int (*set_get_data)(struct snd_sof_dev *sdev, void *data, size_t data_bytes,
460 int (*get_reply)(struct snd_sof_dev *sdev);
461 void (*rx_msg)(struct snd_sof_dev *sdev);
466 struct snd_sof_dev *sdev;
485 struct snd_sof_dev { struct
625 int snd_sof_dsp_power_down_notify(struct snd_sof_dev *sdev); argument
629 void snd_sof_new_platform_drv(struct snd_sof_dev *sdev);
639 int snd_sof_load_firmware_raw(struct snd_sof_dev *sdev);
640 int snd_sof_load_firmware_memcpy(struct snd_sof_dev *sdev);
641 int snd_sof_run_firmware(struct snd_sof_dev *sdev);
642 void snd_sof_fw_unload(struct snd_sof_dev *sdev);
647 struct snd_sof_ipc *snd_sof_ipc_init(struct snd_sof_dev *sdev);
648 void snd_sof_ipc_free(struct snd_sof_dev *sdev);
649 void snd_sof_ipc_get_reply(struct snd_sof_dev *sdev);
650 void snd_sof_ipc_reply(struct snd_sof_dev *sdev, u32 msg_id);
651 static inline void snd_sof_ipc_msgs_rx(struct snd_sof_dev *sdev) in snd_sof_ipc_msgs_rx()
659 int sof_ipc_send_msg(struct snd_sof_dev *sdev, void *msg_data, size_t msg_bytes,
662 static inline void snd_sof_ipc_process_reply(struct snd_sof_dev *sdev, u32 msg_id) in snd_sof_ipc_process_reply()
671 int snd_sof_dbg_init(struct snd_sof_dev *sdev);
672 void snd_sof_free_debug(struct snd_sof_dev *sdev);
673 int snd_sof_debugfs_buf_item(struct snd_sof_dev *sdev,
676 void sof_print_oops_and_stack(struct snd_sof_dev *sdev, const char *level,
680 void snd_sof_handle_fw_exception(struct snd_sof_dev *sdev, const char *msg);
681 int snd_sof_dbg_memory_info_init(struct snd_sof_dev *sdev);
682 int snd_sof_debugfs_add_region_item_iomem(struct snd_sof_dev *sdev,
686 int sof_fw_trace_init(struct snd_sof_dev *sdev);
687 void sof_fw_trace_free(struct snd_sof_dev *sdev);
688 void sof_fw_trace_fw_crashed(struct snd_sof_dev *sdev);
689 void sof_fw_trace_suspend(struct snd_sof_dev *sdev, pm_message_t pm_state);
690 int sof_fw_trace_resume(struct snd_sof_dev *sdev);
695 static inline void sof_stack(struct snd_sof_dev *sdev, const char *level, in sof_stack()
702 static inline void sof_oops(struct snd_sof_dev *sdev, const char *level, void *oops) in sof_oops()
713 void sof_set_fw_state(struct snd_sof_dev *sdev, enum sof_fw_state new_state);
718 void sof_io_write(struct snd_sof_dev *sdev, void __iomem *addr, u32 value);
719 void sof_io_write64(struct snd_sof_dev *sdev, void __iomem *addr, u64 value);
720 u32 sof_io_read(struct snd_sof_dev *sdev, void __iomem *addr);
721 u64 sof_io_read64(struct snd_sof_dev *sdev, void __iomem *addr);
722 void sof_mailbox_write(struct snd_sof_dev *sdev, u32 offset,
724 void sof_mailbox_read(struct snd_sof_dev *sdev, u32 offset,
726 int sof_block_write(struct snd_sof_dev *sdev, enum snd_sof_fw_blk_type blk_type,
728 int sof_block_read(struct snd_sof_dev *sdev, enum snd_sof_fw_blk_type blk_type,
731 int sof_ipc_msg_data(struct snd_sof_dev *sdev,
734 int sof_set_stream_data_offset(struct snd_sof_dev *sdev,
738 int sof_stream_pcm_open(struct snd_sof_dev *sdev,
740 int sof_stream_pcm_close(struct snd_sof_dev *sdev,
743 int sof_machine_check(struct snd_sof_dev *sdev);
747 int sof_client_dev_register(struct snd_sof_dev *sdev, const char *name, u32 id,
749 void sof_client_dev_unregister(struct snd_sof_dev *sdev, const char *name, u32 id);
750 int sof_register_clients(struct snd_sof_dev *sdev);
751 void sof_unregister_clients(struct snd_sof_dev *sdev);
752 void sof_client_ipc_rx_dispatcher(struct snd_sof_dev *sdev, void *msg_buf);
753 void sof_client_fw_state_dispatcher(struct snd_sof_dev *sdev);
754 int sof_suspend_clients(struct snd_sof_dev *sdev, pm_message_t state);
755 int sof_resume_clients(struct snd_sof_dev *sdev);
757 static inline int sof_client_dev_register(struct snd_sof_dev *sdev, const char *name, in sof_client_dev_register()
763 static inline void sof_client_dev_unregister(struct snd_sof_dev *sdev, in sof_client_dev_unregister()
768 static inline int sof_register_clients(struct snd_sof_dev *sdev) in sof_register_clients()
773 static inline void sof_unregister_clients(struct snd_sof_dev *sdev) in sof_unregister_clients()
777 static inline void sof_client_ipc_rx_dispatcher(struct snd_sof_dev *sdev, void *msg_buf) in sof_client_ipc_rx_dispatcher()
781 static inline void sof_client_fw_state_dispatcher(struct snd_sof_dev *sdev) in sof_client_fw_state_dispatcher()
785 static inline int sof_suspend_clients(struct snd_sof_dev *sdev, pm_message_t state) in sof_suspend_clients()
790 static inline int sof_resume_clients(struct snd_sof_dev *sdev) in sof_resume_clients()