Home
last modified time | relevance | path

Searched refs:mbox_chan (Results 1 – 25 of 92) sorted by relevance

1234

/openbmc/linux/include/linux/
H A Dmailbox_controller.h12 struct mbox_chan;
47 int (*send_data)(struct mbox_chan *chan, void *data);
48 int (*flush)(struct mbox_chan *chan, unsigned long timeout);
49 int (*startup)(struct mbox_chan *chan);
50 void (*shutdown)(struct mbox_chan *chan);
51 bool (*last_tx_done)(struct mbox_chan *chan);
52 bool (*peek_data)(struct mbox_chan *chan);
77 struct mbox_chan *chans;
82 struct mbox_chan *(*of_xlate)(struct mbox_controller *mbox,
118 struct mbox_chan { struct
[all …]
H A Dmailbox_client.h13 struct mbox_chan;
40 int mbox_bind_client(struct mbox_chan *chan, struct mbox_client *cl);
41 struct mbox_chan *mbox_request_channel_byname(struct mbox_client *cl,
43 struct mbox_chan *mbox_request_channel(struct mbox_client *cl, int index);
44 int mbox_send_message(struct mbox_chan *chan, void *mssg);
45 int mbox_flush(struct mbox_chan *chan, unsigned long timeout);
46 void mbox_client_txdone(struct mbox_chan *chan, int r); /* atomic */
47 bool mbox_client_peek_data(struct mbox_chan *chan); /* atomic */
48 void mbox_free_channel(struct mbox_chan *chan); /* may sleep */
H A Domap-mailbox.h17 struct mbox_chan;
20 struct mbox_chan *omap_mbox_request_channel(struct mbox_client *cl,
23 void omap_mbox_enable_irq(struct mbox_chan *chan, omap_mbox_irq_t irq);
24 void omap_mbox_disable_irq(struct mbox_chan *chan, omap_mbox_irq_t irq);
/openbmc/u-boot/include/
H A Dmailbox.h58 struct mbox_chan { struct
81 int mbox_get_by_index(struct udevice *dev, int index, struct mbox_chan *chan); argument
100 struct mbox_chan *chan);
109 int mbox_free(struct mbox_chan *chan);
125 int mbox_send(struct mbox_chan *chan, const void *data);
145 int mbox_recv(struct mbox_chan *chan, void *data, ulong timeout_us);
H A Dmailbox-uclass.h37 int (*of_xlate)(struct mbox_chan *chan,
50 int (*request)(struct mbox_chan *chan);
59 int (*free)(struct mbox_chan *chan);
67 int (*send)(struct mbox_chan *chan, const void *data);
79 int (*recv)(struct mbox_chan *chan, void *data);
/openbmc/linux/drivers/mailbox/
H A Dmailbox-altera.c49 struct mbox_chan *chan;
52 static struct altera_mbox *mbox_chan_to_altera_mbox(struct mbox_chan *chan) in mbox_chan_to_altera_mbox()
117 static void altera_mbox_rx_data(struct mbox_chan *chan) in altera_mbox_rx_data()
143 struct mbox_chan *chan = (struct mbox_chan *)p; in altera_mbox_tx_interrupt()
154 struct mbox_chan *chan = (struct mbox_chan *)p; in altera_mbox_rx_interrupt()
160 static int altera_mbox_startup_sender(struct mbox_chan *chan) in altera_mbox_startup_sender()
179 static int altera_mbox_startup_receiver(struct mbox_chan *chan) in altera_mbox_startup_receiver()
206 static int altera_mbox_send_data(struct mbox_chan *chan, void *data) in altera_mbox_send_data()
233 static bool altera_mbox_last_tx_done(struct mbox_chan *chan) in altera_mbox_last_tx_done()
241 static bool altera_mbox_peek_data(struct mbox_chan *chan) in altera_mbox_peek_data()
[all …]
H A Darm_mhuv2.c207 int (*rx_startup)(struct mhuv2 *mhu, struct mbox_chan *chan);
208 void (*rx_shutdown)(struct mhuv2 *mhu, struct mbox_chan *chan);
209 void *(*read_data)(struct mhuv2 *mhu, struct mbox_chan *chan);
211 void (*tx_startup)(struct mhuv2 *mhu, struct mbox_chan *chan);
212 void (*tx_shutdown)(struct mhuv2 *mhu, struct mbox_chan *chan);
213 int (*last_tx_done)(struct mhuv2 *mhu, struct mbox_chan *chan);
214 int (*send_data)(struct mhuv2 *mhu, struct mbox_chan *chan, void *arg);
261 static int mhuv2_doorbell_rx_startup(struct mhuv2 *mhu, struct mbox_chan *chan) in mhuv2_doorbell_rx_startup()
271 struct mbox_chan *chan) in mhuv2_doorbell_rx_shutdown()
279 static void *mhuv2_doorbell_read_data(struct mhuv2 *mhu, struct mbox_chan *chan) in mhuv2_doorbell_read_data()
[all …]
H A Dmailbox.c27 static int add_to_rbuf(struct mbox_chan *chan, void *mssg) in add_to_rbuf()
54 static void msg_submit(struct mbox_chan *chan) in msg_submit()
94 static void tx_tick(struct mbox_chan *chan, int r) in tx_tick()
127 struct mbox_chan *chan = &mbox->chans[i]; in txdone_hrtimer()
159 void mbox_chan_received_data(struct mbox_chan *chan, void *mssg) in mbox_chan_received_data()
177 void mbox_chan_txdone(struct mbox_chan *chan, int r) in mbox_chan_txdone()
198 void mbox_client_txdone(struct mbox_chan *chan, int r) in mbox_client_txdone()
224 bool mbox_client_peek_data(struct mbox_chan *chan) in mbox_client_peek_data()
257 int mbox_send_message(struct mbox_chan *chan, void *mssg) in mbox_send_message()
306 int mbox_flush(struct mbox_chan *chan, unsigned long timeout) in mbox_flush()
[all …]
H A Dmailbox-sti.c86 static inline bool sti_mbox_channel_is_enabled(struct mbox_chan *chan) in sti_mbox_channel_is_enabled()
97 struct mbox_chan *sti_mbox_to_channel(struct mbox_controller *mbox, in sti_mbox_to_channel()
119 static void sti_mbox_enable_channel(struct mbox_chan *chan) in sti_mbox_enable_channel()
134 static void sti_mbox_disable_channel(struct mbox_chan *chan) in sti_mbox_disable_channel()
149 static void sti_mbox_clear_irq(struct mbox_chan *chan) in sti_mbox_clear_irq()
160 static struct mbox_chan *sti_mbox_irq_to_channel(struct sti_mbox_device *mdev, in sti_mbox_irq_to_channel()
164 struct mbox_chan *chan = NULL; in sti_mbox_irq_to_channel()
195 struct mbox_chan *chan; in sti_mbox_thread_handler()
218 struct mbox_chan *chan; in sti_mbox_irq_handler()
251 static bool sti_mbox_tx_is_ready(struct mbox_chan *chan) in sti_mbox_tx_is_ready()
[all …]
H A Darm_mhu_db.c58 static inline struct mbox_chan *
75 static void mhu_db_mbox_clear_irq(struct mbox_chan *chan) in mhu_db_mbox_clear_irq()
93 static struct mbox_chan *
98 struct mbox_chan *chan = NULL; in mhu_db_mbox_irq_to_channel()
125 struct mbox_chan *chan; in mhu_db_mbox_rx_handler()
137 static bool mhu_db_last_tx_done(struct mbox_chan *chan) in mhu_db_last_tx_done()
148 static int mhu_db_send_data(struct mbox_chan *chan, void *data) in mhu_db_send_data()
159 static int mhu_db_startup(struct mbox_chan *chan) in mhu_db_startup()
165 static void mhu_db_shutdown(struct mbox_chan *chan) in mhu_db_shutdown()
186 static struct mbox_chan *mhu_db_mbox_xlate(struct mbox_controller *mbox, in mhu_db_mbox_xlate()
[all …]
H A Dsun6i-msgbox.c53 static bool sun6i_msgbox_last_tx_done(struct mbox_chan *chan);
54 static bool sun6i_msgbox_peek_data(struct mbox_chan *chan);
56 static inline int channel_number(struct mbox_chan *chan) in channel_number()
61 static inline struct sun6i_msgbox *to_sun6i_msgbox(struct mbox_chan *chan) in to_sun6i_msgbox()
80 struct mbox_chan *chan = &mbox->controller.chans[n]; in sun6i_msgbox_irq()
99 static int sun6i_msgbox_send_data(struct mbox_chan *chan, void *data) in sun6i_msgbox_send_data()
115 static int sun6i_msgbox_startup(struct mbox_chan *chan) in sun6i_msgbox_startup()
139 static void sun6i_msgbox_shutdown(struct mbox_chan *chan) in sun6i_msgbox_shutdown()
162 static bool sun6i_msgbox_last_tx_done(struct mbox_chan *chan) in sun6i_msgbox_last_tx_done()
179 static bool sun6i_msgbox_peek_data(struct mbox_chan *chan) in sun6i_msgbox_peek_data()
[all …]
H A Dmtk-adsp-mailbox.c38 struct mbox_chan *chan = data; in mtk_adsp_mbox_irq()
49 struct mbox_chan *chan = data; in mtk_adsp_mbox_isr()
56 static struct mbox_chan *mtk_adsp_mbox_xlate(struct mbox_controller *mbox, in mtk_adsp_mbox_xlate()
62 static int mtk_adsp_mbox_startup(struct mbox_chan *chan) in mtk_adsp_mbox_startup()
73 static void mtk_adsp_mbox_shutdown(struct mbox_chan *chan) in mtk_adsp_mbox_shutdown()
82 static int mtk_adsp_mbox_send_data(struct mbox_chan *chan, void *data) in mtk_adsp_mbox_send_data()
92 static bool mtk_adsp_mbox_last_tx_done(struct mbox_chan *chan) in mtk_adsp_mbox_last_tx_done()
H A Dbcm2835-mailbox.c61 static struct bcm2835_mbox *bcm2835_link_mbox(struct mbox_chan *link) in bcm2835_link_mbox()
70 struct mbox_chan *link = &mbox->controller.chans[0]; in bcm2835_mbox_irq()
80 static int bcm2835_send_data(struct mbox_chan *link, void *data) in bcm2835_send_data()
92 static int bcm2835_startup(struct mbox_chan *link) in bcm2835_startup()
102 static void bcm2835_shutdown(struct mbox_chan *link) in bcm2835_shutdown()
109 static bool bcm2835_last_tx_done(struct mbox_chan *link) in bcm2835_last_tx_done()
127 static struct mbox_chan *bcm2835_mbox_index_xlate(struct mbox_controller *mbox, in bcm2835_mbox_index_xlate()
H A Dhi3660-mailbox.c75 struct mbox_chan chan[MBOX_CHAN_MAX];
85 static int hi3660_mbox_check_state(struct mbox_chan *chan) in hi3660_mbox_check_state()
112 static int hi3660_mbox_unlock(struct mbox_chan *chan) in hi3660_mbox_unlock()
133 static int hi3660_mbox_acquire_channel(struct mbox_chan *chan) in hi3660_mbox_acquire_channel()
159 static int hi3660_mbox_startup(struct mbox_chan *chan) in hi3660_mbox_startup()
174 static int hi3660_mbox_send_data(struct mbox_chan *chan, void *msg) in hi3660_mbox_send_data()
211 static struct mbox_chan *hi3660_mbox_xlate(struct mbox_controller *controller, in hi3660_mbox_xlate()
241 struct mbox_chan *chan; in hi3660_mbox_probe()
H A Darm_mhu.c37 struct mbox_chan chan[MHU_CHANS];
43 struct mbox_chan *chan = p; in mhu_rx_interrupt()
58 static bool mhu_last_tx_done(struct mbox_chan *chan) in mhu_last_tx_done()
66 static int mhu_send_data(struct mbox_chan *chan, void *data) in mhu_send_data()
76 static int mhu_startup(struct mbox_chan *chan) in mhu_startup()
96 static void mhu_shutdown(struct mbox_chan *chan) in mhu_shutdown()
H A Dplatform_mhu.c43 struct mbox_chan chan[MHU_CHANS];
49 struct mbox_chan *chan = p; in platform_mhu_rx_interrupt()
64 static bool platform_mhu_last_tx_done(struct mbox_chan *chan) in platform_mhu_last_tx_done()
72 static int platform_mhu_send_data(struct mbox_chan *chan, void *data) in platform_mhu_send_data()
82 static int platform_mhu_startup(struct mbox_chan *chan) in platform_mhu_startup()
102 static void platform_mhu_shutdown(struct mbox_chan *chan) in platform_mhu_shutdown()
H A Darmada-37xx-rwtm-mailbox.c43 static void a37xx_mbox_receive(struct mbox_chan *chan) in a37xx_mbox_receive()
58 struct mbox_chan *chan = data; in a37xx_mbox_irq_handler()
77 static int a37xx_mbox_send_data(struct mbox_chan *chan, void *data) in a37xx_mbox_send_data()
103 static int a37xx_mbox_startup(struct mbox_chan *chan) in a37xx_mbox_startup()
124 static void a37xx_mbox_shutdown(struct mbox_chan *chan) in a37xx_mbox_shutdown()
146 struct mbox_chan *chans; in armada_37xx_mbox_probe()
H A Dti-msgmgr.c116 struct mbox_chan *chan;
144 struct mbox_chan *chans;
196 static int ti_msgmgr_queue_rx_data(struct mbox_chan *chan, struct ti_queue_inst *qinst, in ti_msgmgr_queue_rx_data()
243 static int ti_msgmgr_queue_rx_poll_timeout(struct mbox_chan *chan, int timeout_us) in ti_msgmgr_queue_rx_poll_timeout()
274 struct mbox_chan *chan = p; in ti_msgmgr_queue_rx_interrupt()
318 static bool ti_msgmgr_queue_peek_data(struct mbox_chan *chan) in ti_msgmgr_queue_peek_data()
345 static bool ti_msgmgr_last_tx_done(struct mbox_chan *chan) in ti_msgmgr_last_tx_done()
372 static bool ti_msgmgr_chan_has_polled_queue_rx(struct mbox_chan *chan) in ti_msgmgr_chan_has_polled_queue_rx()
390 static int ti_msgmgr_send_data(struct mbox_chan *chan, void *data) in ti_msgmgr_send_data()
466 struct mbox_chan *chan) in ti_msgmgr_queue_rx_irq_req()
[all …]
H A Dmailbox-mpfs.c69 struct mbox_chan chans[1];
83 static bool mpfs_mbox_last_tx_done(struct mbox_chan *chan) in mpfs_mbox_last_tx_done()
104 static int mpfs_mbox_send_data(struct mbox_chan *chan, void *data) in mpfs_mbox_send_data()
151 static void mpfs_mbox_rx_data(struct mbox_chan *chan) in mpfs_mbox_rx_data()
185 struct mbox_chan *chan = data; in mpfs_mbox_inbox_isr()
195 static int mpfs_mbox_startup(struct mbox_chan *chan) in mpfs_mbox_startup()
210 static void mpfs_mbox_shutdown(struct mbox_chan *chan) in mpfs_mbox_shutdown()
/openbmc/u-boot/drivers/mailbox/
H A Dmailbox-uclass.c16 static int mbox_of_xlate_default(struct mbox_chan *chan, in mbox_of_xlate_default()
31 int mbox_get_by_index(struct udevice *dev, int index, struct mbox_chan *chan) in mbox_get_by_index()
76 struct mbox_chan *chan) in mbox_get_by_name()
91 int mbox_free(struct mbox_chan *chan) in mbox_free()
100 int mbox_send(struct mbox_chan *chan, const void *data) in mbox_send()
109 int mbox_recv(struct mbox_chan *chan, void *data, ulong timeout_us) in mbox_recv()
H A Dsandbox-mbox.c23 static int sandbox_mbox_request(struct mbox_chan *chan) in sandbox_mbox_request()
33 static int sandbox_mbox_free(struct mbox_chan *chan) in sandbox_mbox_free()
40 static int sandbox_mbox_send(struct mbox_chan *chan, const void *data) in sandbox_mbox_send()
53 static int sandbox_mbox_recv(struct mbox_chan *chan, void *data) in sandbox_mbox_recv()
H A Dtegra-hsp.c71 static int tegra_hsp_of_xlate(struct mbox_chan *chan, in tegra_hsp_of_xlate()
86 static int tegra_hsp_request(struct mbox_chan *chan) in tegra_hsp_request()
101 static int tegra_hsp_free(struct mbox_chan *chan) in tegra_hsp_free()
108 static int tegra_hsp_send(struct mbox_chan *chan, const void *data) in tegra_hsp_send()
121 static int tegra_hsp_recv(struct mbox_chan *chan, void *data) in tegra_hsp_recv()
/openbmc/linux/drivers/rpmsg/
H A Dqcom_glink_smem.c45 struct mbox_chan *mbox_chan; member
200 mbox_send_message(smem->mbox_chan, NULL); in glink_smem_tx_kick()
201 mbox_client_txdone(smem->mbox_chan, 0); in glink_smem_tx_kick()
318 smem->mbox_chan = mbox_request_channel(&smem->mbox_client, 0); in qcom_glink_smem_register()
319 if (IS_ERR(smem->mbox_chan)) { in qcom_glink_smem_register()
320 ret = dev_err_probe(&smem->dev, PTR_ERR(smem->mbox_chan), in qcom_glink_smem_register()
354 mbox_free_channel(smem->mbox_chan); in qcom_glink_smem_register()
371 mbox_free_channel(smem->mbox_chan); in qcom_glink_smem_unregister()
/openbmc/linux/drivers/soc/qcom/
H A Dsmp2p.c157 struct mbox_chan *mbox_chan; member
168 if (smp2p->mbox_chan) { in qcom_smp2p_kick()
169 mbox_send_message(smp2p->mbox_chan, NULL); in qcom_smp2p_kick()
170 mbox_client_txdone(smp2p->mbox_chan, 0); in qcom_smp2p_kick()
560 smp2p->mbox_chan = mbox_request_channel(&smp2p->mbox_client, 0); in qcom_smp2p_probe()
561 if (IS_ERR(smp2p->mbox_chan)) { in qcom_smp2p_probe()
562 if (PTR_ERR(smp2p->mbox_chan) != -ENODEV) in qcom_smp2p_probe()
563 return PTR_ERR(smp2p->mbox_chan); in qcom_smp2p_probe()
565 smp2p->mbox_chan = NULL; in qcom_smp2p_probe()
654 mbox_free_channel(smp2p->mbox_chan); in qcom_smp2p_probe()
[all …]
/openbmc/linux/drivers/remoteproc/
H A Dst_remoteproc.c51 struct mbox_chan *mbox_chan[ST_RPROC_MAX_VRING * MBOX_MAX]; member
86 ret = mbox_send_message(ddata->mbox_chan[vqid * MBOX_MAX + MBOX_TX], in st_rproc_kick()
348 struct mbox_chan *chan; in st_rproc_probe()
408 ddata->mbox_chan[ST_RPROC_VQ0 * MBOX_MAX + MBOX_RX] = chan; in st_rproc_probe()
416 ddata->mbox_chan[ST_RPROC_VQ0 * MBOX_MAX + MBOX_TX] = chan; in st_rproc_probe()
424 ddata->mbox_chan[ST_RPROC_VQ1 * MBOX_MAX + MBOX_RX] = chan; in st_rproc_probe()
432 ddata->mbox_chan[ST_RPROC_VQ1 * MBOX_MAX + MBOX_TX] = chan; in st_rproc_probe()
443 mbox_free_channel(ddata->mbox_chan[i]); in st_rproc_probe()
462 mbox_free_channel(ddata->mbox_chan[i]); in st_rproc_remove()

1234