Lines Matching refs:bsq

860 int bsq_audit(int where, struct host_bsq* bsq, int scheme, int magn)  in bsq_audit()  argument
865 buffer = bsq->freebuf; in bsq_audit()
892 if (count != bsq->freebuf_count) { in bsq_audit()
894 where, scheme, magn, count, bsq->freebuf_count); in bsq_audit()
906 struct host_bsq* bsq; in fore200e_supply() local
913 bsq = &fore200e->host_bsq[ scheme ][ magn ]; in fore200e_supply()
916 bsq_audit(1, bsq, scheme, magn); in fore200e_supply()
918 while (bsq->freebuf_count >= RBD_BLK_SIZE) { in fore200e_supply()
921 RBD_BLK_SIZE, scheme, magn, bsq->freebuf_count); in fore200e_supply()
923 entry = &bsq->host_entry[ bsq->head ]; in fore200e_supply()
928 buffer = bsq->freebuf; in fore200e_supply()
931 scheme, magn, bsq->freebuf_count); in fore200e_supply()
934 bsq->freebuf = buffer->next; in fore200e_supply()
946 FORE200E_NEXT_ENTRY(bsq->head, QUEUE_SIZE_BS); in fore200e_supply()
949 bsq->freebuf_count -= RBD_BLK_SIZE; in fore200e_supply()
1054 struct host_bsq* bsq; in fore200e_collect_rpd() local
1063 bsq = &fore200e->host_bsq[ buffer->scheme ][ buffer->magn ]; in fore200e_collect_rpd()
1066 bsq_audit(2, bsq, buffer->scheme, buffer->magn); in fore200e_collect_rpd()
1075 buffer->next = bsq->freebuf; in fore200e_collect_rpd()
1076 bsq->freebuf = buffer; in fore200e_collect_rpd()
1079 bsq->freebuf_count++; in fore200e_collect_rpd()
1986 struct host_bsq* bsq; in fore200e_alloc_rx_buf() local
1992 bsq = &fore200e->host_bsq[ scheme ][ magn ]; in fore200e_alloc_rx_buf()
2000 buffer = bsq->buffer = kcalloc(nbr, sizeof(struct buffer), in fore200e_alloc_rx_buf()
2006 bsq->freebuf = NULL; in fore200e_alloc_rx_buf()
2030 buffer[ i ].next = bsq->freebuf; in fore200e_alloc_rx_buf()
2031 bsq->freebuf = &buffer[ i ]; in fore200e_alloc_rx_buf()
2034 bsq->freebuf_count = nbr; in fore200e_alloc_rx_buf()
2037 bsq_audit(3, bsq, scheme, magn); in fore200e_alloc_rx_buf()
2051 struct host_bsq* bsq; in fore200e_init_bs_queue() local
2059 bsq = &fore200e->host_bsq[ scheme ][ magn ]; in fore200e_init_bs_queue()
2063 &bsq->status, in fore200e_init_bs_queue()
2072 &bsq->rbd_block, in fore200e_init_bs_queue()
2077 fore200e_dma_chunk_free(fore200e, &bsq->status); in fore200e_init_bs_queue()
2088 bsq->host_entry[ i ].status = in fore200e_init_bs_queue()
2089 FORE200E_INDEX(bsq->status.align_addr, enum status, i); in fore200e_init_bs_queue()
2090 bsq->host_entry[ i ].rbd_block = in fore200e_init_bs_queue()
2091 FORE200E_INDEX(bsq->rbd_block.align_addr, struct rbd_block, i); in fore200e_init_bs_queue()
2092 bsq->host_entry[ i ].rbd_block_dma = in fore200e_init_bs_queue()
2093 FORE200E_DMA_INDEX(bsq->rbd_block.dma_addr, struct rbd_block, i); in fore200e_init_bs_queue()
2094 bsq->host_entry[ i ].cp_entry = &cp_entry[ i ]; in fore200e_init_bs_queue()
2096 *bsq->host_entry[ i ].status = STATUS_FREE; in fore200e_init_bs_queue()
2098 fore200e->bus->write(FORE200E_DMA_INDEX(bsq->status.dma_addr, enum status, i), in fore200e_init_bs_queue()