Lines Matching refs:cmd_len

488 	int cmd_len, resp_len, i;  in wilc_spi_single_read()  local
513 cmd_len = offsetof(struct wilc_spi_cmd, u.simple_cmd.crc); in wilc_spi_single_read()
517 c->u.simple_cmd.crc[0] = wilc_get_crc7(wb, cmd_len); in wilc_spi_single_read()
518 cmd_len += 1; in wilc_spi_single_read()
522 if (cmd_len + resp_len > ARRAY_SIZE(wb)) { in wilc_spi_single_read()
525 cmd_len, resp_len, ARRAY_SIZE(wb)); in wilc_spi_single_read()
529 if (wilc_spi_tx_rx(wilc, wb, rb, cmd_len + resp_len)) { in wilc_spi_single_read()
534 r = (struct wilc_spi_rsp_data *)&rb[cmd_len]; in wilc_spi_single_read()
583 int cmd_len, resp_len; in wilc_spi_write_cmd() local
598 cmd_len = offsetof(struct wilc_spi_cmd, u.internal_w_cmd.crc); in wilc_spi_write_cmd()
600 c->u.internal_w_cmd.crc[0] = wilc_get_crc7(wb, cmd_len); in wilc_spi_write_cmd()
606 cmd_len = offsetof(struct wilc_spi_cmd, u.w_cmd.crc); in wilc_spi_write_cmd()
608 c->u.w_cmd.crc[0] = wilc_get_crc7(wb, cmd_len); in wilc_spi_write_cmd()
615 cmd_len += 1; in wilc_spi_write_cmd()
619 if (cmd_len + resp_len > ARRAY_SIZE(wb)) { in wilc_spi_write_cmd()
622 cmd_len, resp_len, ARRAY_SIZE(wb)); in wilc_spi_write_cmd()
626 if (wilc_spi_tx_rx(wilc, wb, rb, cmd_len + resp_len)) { in wilc_spi_write_cmd()
631 r = (struct wilc_spi_rsp_data *)&rb[cmd_len]; in wilc_spi_write_cmd()
658 int cmd_len, resp_len; in wilc_spi_dma_rw() local
674 cmd_len = offsetof(struct wilc_spi_cmd, u.dma_cmd.crc); in wilc_spi_dma_rw()
676 c->u.dma_cmd.crc[0] = wilc_get_crc7(wb, cmd_len); in wilc_spi_dma_rw()
684 cmd_len = offsetof(struct wilc_spi_cmd, u.dma_cmd_ext.crc); in wilc_spi_dma_rw()
686 c->u.dma_cmd_ext.crc[0] = wilc_get_crc7(wb, cmd_len); in wilc_spi_dma_rw()
693 cmd_len += 1; in wilc_spi_dma_rw()
697 if (cmd_len + resp_len > ARRAY_SIZE(wb)) { in wilc_spi_dma_rw()
699 cmd_len, resp_len, ARRAY_SIZE(wb)); in wilc_spi_dma_rw()
703 if (wilc_spi_tx_rx(wilc, wb, rb, cmd_len + resp_len)) { in wilc_spi_dma_rw()
708 r = (struct wilc_spi_rsp_data *)&rb[cmd_len]; in wilc_spi_dma_rw()
784 int cmd_len, resp_len = 0; in wilc_spi_special_cmd() local
799 cmd_len = offsetof(struct wilc_spi_cmd, u.simple_cmd.crc); in wilc_spi_special_cmd()
803 c->u.simple_cmd.crc[0] = wilc_get_crc7(wb, cmd_len); in wilc_spi_special_cmd()
804 cmd_len += 1; in wilc_spi_special_cmd()
806 if (cmd_len + resp_len > ARRAY_SIZE(wb)) { in wilc_spi_special_cmd()
808 cmd_len, resp_len, ARRAY_SIZE(wb)); in wilc_spi_special_cmd()
812 if (wilc_spi_tx_rx(wilc, wb, rb, cmd_len + resp_len)) { in wilc_spi_special_cmd()
817 r = (struct wilc_spi_special_cmd_rsp *)&rb[cmd_len]; in wilc_spi_special_cmd()