Lines Matching refs:chan

62 static struct altera_mbox *mbox_chan_to_altera_mbox(struct mbox_chan *chan)  in mbox_chan_to_altera_mbox()  argument
64 if (!chan || !chan->con_priv) in mbox_chan_to_altera_mbox()
67 return (struct altera_mbox *)chan->con_priv; in mbox_chan_to_altera_mbox()
127 static void altera_mbox_rx_data(struct mbox_chan *chan) in altera_mbox_rx_data() argument
129 struct altera_mbox *mbox = mbox_chan_to_altera_mbox(chan); in altera_mbox_rx_data()
137 mbox_chan_received_data(chan, (void *)data); in altera_mbox_rx_data()
143 struct mbox_chan *chan = (struct mbox_chan *)data; in altera_mbox_poll_rx() local
144 struct altera_mbox *mbox = mbox_chan_to_altera_mbox(chan); in altera_mbox_poll_rx()
146 altera_mbox_rx_data(chan); in altera_mbox_poll_rx()
154 struct mbox_chan *chan = (struct mbox_chan *)p; in altera_mbox_tx_interrupt() local
155 struct altera_mbox *mbox = mbox_chan_to_altera_mbox(chan); in altera_mbox_tx_interrupt()
158 mbox_chan_txdone(chan, 0); in altera_mbox_tx_interrupt()
165 struct mbox_chan *chan = (struct mbox_chan *)p; in altera_mbox_rx_interrupt() local
167 altera_mbox_rx_data(chan); in altera_mbox_rx_interrupt()
171 static int altera_mbox_startup_sender(struct mbox_chan *chan) in altera_mbox_startup_sender() argument
174 struct altera_mbox *mbox = mbox_chan_to_altera_mbox(chan); in altera_mbox_startup_sender()
178 DRIVER_NAME, chan); in altera_mbox_startup_sender()
190 static int altera_mbox_startup_receiver(struct mbox_chan *chan) in altera_mbox_startup_receiver() argument
193 struct altera_mbox *mbox = mbox_chan_to_altera_mbox(chan); in altera_mbox_startup_receiver()
197 DRIVER_NAME, chan); in altera_mbox_startup_receiver()
210 (unsigned long)chan); in altera_mbox_startup_receiver()
217 static int altera_mbox_send_data(struct mbox_chan *chan, void *data) in altera_mbox_send_data() argument
219 struct altera_mbox *mbox = mbox_chan_to_altera_mbox(chan); in altera_mbox_send_data()
244 static bool altera_mbox_last_tx_done(struct mbox_chan *chan) in altera_mbox_last_tx_done() argument
246 struct altera_mbox *mbox = mbox_chan_to_altera_mbox(chan); in altera_mbox_last_tx_done()
252 static bool altera_mbox_peek_data(struct mbox_chan *chan) in altera_mbox_peek_data() argument
254 struct altera_mbox *mbox = mbox_chan_to_altera_mbox(chan); in altera_mbox_peek_data()
259 static int altera_mbox_startup(struct mbox_chan *chan) in altera_mbox_startup() argument
261 struct altera_mbox *mbox = mbox_chan_to_altera_mbox(chan); in altera_mbox_startup()
268 ret = altera_mbox_startup_sender(chan); in altera_mbox_startup()
270 ret = altera_mbox_startup_receiver(chan); in altera_mbox_startup()
275 static void altera_mbox_shutdown(struct mbox_chan *chan) in altera_mbox_shutdown() argument
277 struct altera_mbox *mbox = mbox_chan_to_altera_mbox(chan); in altera_mbox_shutdown()
282 free_irq(mbox->irq, chan); in altera_mbox_shutdown()