Lines Matching refs:didx
328 int didx, bool is_tx) in qmspi_descr_alloc() argument
333 if (didx >= MCHP_QMSPI_MAX_DESCR) { in qmspi_descr_alloc()
338 return didx; /* nothing to do */ in qmspi_descr_alloc()
357 dn = didx + 1; in qmspi_descr_alloc()
368 descr_wr(regs, didx, descr); in qmspi_descr_alloc()
371 didx++; in qmspi_descr_alloc()
388 int didx; in qmspi_tx() local
399 didx = qmspi_descr_alloc(regs, tx_buf, 0, true); in qmspi_tx()
400 if (didx < 0) { in qmspi_tx()
401 return didx; in qmspi_tx()
405 __ASSERT(didx > 0, "QMSPI descriptor index=%d expected > 0\n", didx); in qmspi_tx()
406 didx--; in qmspi_tx()
408 descr = descr_rd(regs, didx) | MCHP_QMSPI_C_DESCR_LAST; in qmspi_tx()
412 descr_wr(regs, didx, descr); in qmspi_tx()
462 int didx; in qmspi_rx() local
469 didx = qmspi_descr_alloc(regs, rx_buf, 0, false); in qmspi_rx()
470 if (didx < 0) { in qmspi_rx()
471 return didx; in qmspi_rx()
475 __ASSERT_NO_MSG(didx > 0); in qmspi_rx()
476 didx--; in qmspi_rx()
478 descr = descr_rd(regs, didx) | MCHP_QMSPI_C_DESCR_LAST; in qmspi_rx()
482 descr_wr(regs, didx, descr); in qmspi_rx()