CIRC_CNT
(CIRC_CNT((circ)->head, (circ)->tail, ACPI_AML_BUF_SIZE))
cnt_w = CIRC_CNT(drvdata->circ.head,
for (i = 0; CIRC_CNT(head, tail + i, JOBR_DEPTH) >= 1; i++) {
BUG_ON(CIRC_CNT(head, tail + i, JOBR_DEPTH) <= 0);
} while (CIRC_CNT(head, tail, JOBR_DEPTH) >= 1 &&
return CIRC_CNT(ioat_chan->head, ioat_chan->tail,
return CIRC_CNT(ioat_chan->head, ioat_chan->issued,
avail = CIRC_CNT(offset, bchan->head, MAX_DESCRIPTORS + 1);
while (CIRC_CNT(ocx->com_ring_head, ocx->com_ring_tail,
while (CIRC_CNT(ocx->link_ring_head, ocx->link_ring_tail,
while (CIRC_CNT(l2c->ring_head, l2c->ring_tail,
while (CIRC_CNT(lmc->ring_head, lmc->ring_tail,
return CIRC_CNT(crc->head, crc->tail, DRM_CRC_ENTRIES_NR);
(CIRC_CNT((circ)->head, (circ)->tail, BUF_SZ))
to_read = CIRC_CNT(write_ptr, read_ptr, drvdata->buffer_depth);
to_read = CIRC_CNT(write_ptr, read_ptr, drvdata->size);
sdb->data_size = CIRC_CNT(buf_wrptr, sdb->buf_rdptr,
CIRC_CNT(head, tail, tx_ring->max_items));
CIRC_CNT(req->setup_head, clear_tail, MAX_FLOWS) >=
if (!CIRC_CNT(req->setup_head, req->clear_tail, MAX_FLOWS))
while (CIRC_CNT(req->setup_head, req->clear_tail, MAX_FLOWS)) {
for ( ; CIRC_CNT(head, tail, MAX_FLOWS);
if (CIRC_CNT(req->flow_idx, req->clear_tail, MAX_FLOWS)) {
CIRC_CNT(req->flow_idx, req->clear_tail,
if (CIRC_CNT(req->setup_head, req->flow_idx,
CIRC_CNT(req->flow_idx,
for (; CIRC_CNT(req->setup_head, fidx, MAX_FLOWS);
if (!CIRC_CNT(req->setup_head, req->flow_idx, MAX_FLOWS))
CIRC_CNT(rptr->setup_head, fidx,
CIRC_CNT(req->setup_head, flow_idx,
if (!CIRC_CNT(req->setup_head, req->clear_tail,
CIRC_CNT(req->clear_tail, req->acked_tail,
CIRC_CNT(queue->tx_head, queue->tx_tail,
count = CIRC_CNT(head, tail, ring_size);
#define dma_ring_cnt(h, t, s) CIRC_CNT(h, t, s)
num = CIRC_CNT(end, start, RX_DESC_NUM);
num = CIRC_CNT(end, start, TX_DESC_NUM);
return CIRC_CNT(wr_idx, rd_idx, prestera_fw_evtq_len(fw, qid));
while (CIRC_CNT(tx_done_index, i, priv->tx_bd_num)) {
CIRC_CNT(priv->tx_bd_w_index, priv->tx_bd_r_index,
if (CIRC_CNT(priv->tx_bd_w_index, tx_done_index, priv->tx_bd_num))
while (CIRC_CNT(tx_done_index, i, priv->tx_bd_num)) {
CIRC_CNT(priv->tx_bd_w_index, priv->tx_bd_r_index,
CIRC_CNT(tx_done_index, priv->tx_bd_r_index,
CIRC_CNT(priv->tx_bd_w_index, tx_done_index,
while (!CIRC_CNT(cb->head, cb->tail, LOG_SIZE)) {
CIRC_CNT(cb->head, cb->tail, LOG_SIZE));
if (CIRC_CNT(debug_info->log_buffer.head,
size = CIRC_CNT(cons->tx_buf.head, cons->tx_buf.tail,
if (CIRC_CNT(rb->head, rb->tail, CUSTOM_BIOS_INPUT_RING_ENTRIES) == 0)
allxfer_len = CIRC_CNT(head, tail, ARCMSR_MAX_QBUFFER);
allxfer_len = CIRC_CNT(head, tail, ARCMSR_MAX_QBUFFER);
return CIRC_CNT(ihost->tci_head, ihost->tci_tail, SCI_MAX_IO_REQUESTS);
if (CIRC_CNT(info->xmit.head,
return CIRC_CNT(info->xmit.head, info->xmit.tail, UART_XMIT_SIZE);
count = CIRC_CNT(bc->head, bc->tail, BUF_SIZE);
if (CIRC_CNT(bc->head, bc->tail, BUF_SIZE))
count = CIRC_CNT(ring->head, ring->tail, sport->rx_sgl.length);
count = CIRC_CNT(ring->head, ring->tail, sport->rx_sgl.length);
#define CIRC_SPACE(head,tail,size) CIRC_CNT((tail),((head)+1),(size))
while (CIRC_CNT(head, tail, size) > 0) {
while (CIRC_CNT(head, tail, size) > 0) {
while (CIRC_CNT(head, tail, size) > 0) {
call_count = CIRC_CNT(call_head, call_tail, RXRPC_BACKLOG_MAX);
conn_count = CIRC_CNT(conn_head, conn_tail, RXRPC_BACKLOG_MAX);
ASSERTCMP(CIRC_CNT(peer_head, peer_tail, RXRPC_BACKLOG_MAX), >=,
tmp = CIRC_CNT(call_head, call_tail, size);
if (CIRC_CNT(head, tail, size) < max) {
if (CIRC_CNT(head, tail, size) < max) {
(CIRC_CNT((circ)->head, (circ)->tail, ACPI_AML_BUF_SIZE))