• Home
  • Raw
  • Download

Lines Matching refs:sdev

27 	struct snd_sof_dev *sdev;  member
34 static void imx8m_get_reply(struct snd_sof_dev *sdev) in imx8m_get_reply() argument
36 struct snd_sof_ipc_msg *msg = sdev->msg; in imx8m_get_reply()
41 dev_warn(sdev->dev, "unexpected ipc interrupt\n"); in imx8m_get_reply()
46 sof_mailbox_read(sdev, sdev->host_box.offset, &reply, sizeof(reply)); in imx8m_get_reply()
54 dev_err(sdev->dev, "error: reply expected %zu got %u bytes\n", in imx8m_get_reply()
61 sof_mailbox_read(sdev, sdev->host_box.offset, in imx8m_get_reply()
68 static int imx8m_get_mailbox_offset(struct snd_sof_dev *sdev) in imx8m_get_mailbox_offset() argument
73 static int imx8m_get_window_offset(struct snd_sof_dev *sdev, u32 id) in imx8m_get_window_offset() argument
83 spin_lock_irqsave(&priv->sdev->ipc_lock, flags); in imx8m_dsp_handle_reply()
84 imx8m_get_reply(priv->sdev); in imx8m_dsp_handle_reply()
85 snd_sof_ipc_reply(priv->sdev, 0); in imx8m_dsp_handle_reply()
86 spin_unlock_irqrestore(&priv->sdev->ipc_lock, flags); in imx8m_dsp_handle_reply()
95 sof_mailbox_read(priv->sdev, priv->sdev->debug_box.offset + 4, &p, sizeof(p)); in imx8m_dsp_handle_request()
99 snd_sof_dsp_panic(priv->sdev, p); in imx8m_dsp_handle_request()
101 snd_sof_ipc_msgs_rx(priv->sdev); in imx8m_dsp_handle_request()
109 static int imx8m_send_msg(struct snd_sof_dev *sdev, struct snd_sof_ipc_msg *msg) in imx8m_send_msg() argument
111 struct imx8m_priv *priv = sdev->pdata->hw_pdata; in imx8m_send_msg()
113 sof_mailbox_write(sdev, sdev->host_box.offset, msg->msg_data, in imx8m_send_msg()
123 static int imx8m_run(struct snd_sof_dev *sdev) in imx8m_run() argument
129 static int imx8m_probe(struct snd_sof_dev *sdev) in imx8m_probe() argument
132 container_of(sdev->dev, struct platform_device, dev); in imx8m_probe()
145 sdev->pdata->hw_pdata = priv; in imx8m_probe()
146 priv->dev = sdev->dev; in imx8m_probe()
147 priv->sdev = sdev; in imx8m_probe()
149 priv->ipc_dev = platform_device_register_data(sdev->dev, "imx-dsp", in imx8m_probe()
159 dev_err(sdev->dev, "Failed to get drvdata\n"); in imx8m_probe()
172 dev_err(sdev->dev, "error: failed to get DSP base at idx 0\n"); in imx8m_probe()
177 sdev->bar[SOF_FW_BLK_TYPE_IRAM] = devm_ioremap(sdev->dev, base, size); in imx8m_probe()
178 if (!sdev->bar[SOF_FW_BLK_TYPE_IRAM]) { in imx8m_probe()
179 dev_err(sdev->dev, "failed to ioremap base 0x%x size 0x%x\n", in imx8m_probe()
184 sdev->mmio_bar = SOF_FW_BLK_TYPE_IRAM; in imx8m_probe()
200 sdev->bar[SOF_FW_BLK_TYPE_SRAM] = devm_ioremap_wc(sdev->dev, res.start, in imx8m_probe()
202 if (!sdev->bar[SOF_FW_BLK_TYPE_SRAM]) { in imx8m_probe()
203 dev_err(sdev->dev, "failed to ioremap mem 0x%x size 0x%x\n", in imx8m_probe()
208 sdev->mailbox_bar = SOF_FW_BLK_TYPE_SRAM; in imx8m_probe()
211 sdev->dsp_box.offset = MBOX_OFFSET; in imx8m_probe()
220 static int imx8m_remove(struct snd_sof_dev *sdev) in imx8m_remove() argument
222 struct imx8m_priv *priv = sdev->pdata->hw_pdata; in imx8m_remove()
230 static int imx8m_get_bar_index(struct snd_sof_dev *sdev, u32 type) in imx8m_get_bar_index() argument
235 static void imx8m_ipc_msg_data(struct snd_sof_dev *sdev, in imx8m_ipc_msg_data() argument
239 sof_mailbox_read(sdev, sdev->dsp_box.offset, p, sz); in imx8m_ipc_msg_data()
242 static int imx8m_ipc_pcm_params(struct snd_sof_dev *sdev, in imx8m_ipc_pcm_params() argument