Lines Matching defs:mesg
153 static int spi_sh_send(struct spi_sh_data *ss, struct spi_message *mesg,
200 if (list_is_last(&t->transfer_list, &mesg->transfers)) {
218 static int spi_sh_receive(struct spi_sh_data *ss, struct spi_message *mesg,
277 struct spi_message *mesg;
286 mesg = list_entry(ss->queue.next, struct spi_message, queue);
287 list_del_init(&mesg->queue);
290 list_for_each_entry(t, &mesg->transfers, transfer_list) {
297 ret = spi_sh_send(ss, mesg, t);
302 ret = spi_sh_receive(ss, mesg, t);
306 mesg->actual_length += t->len;
310 mesg->status = 0;
311 if (mesg->complete)
312 mesg->complete(mesg->context);
329 mesg->status = ret;
330 if (mesg->complete)
331 mesg->complete(mesg->context);
358 static int spi_sh_transfer(struct spi_device *spi, struct spi_message *mesg)
368 mesg->actual_length = 0;
369 mesg->status = -EINPROGRESS;
373 list_add_tail(&mesg->queue, &ss->queue);