Lines Matching refs:nsgs
220 int nsgs, int len, int sglen) in mt76u_fill_rx_sg() argument
225 for (i = 0; i < nsgs; i++) { in mt76u_fill_rx_sg()
239 if (i < nsgs) { in mt76u_fill_rx_sg()
242 for (j = nsgs; j < urb->num_sgs; j++) in mt76u_fill_rx_sg()
255 int nsgs, int len, int sglen, gfp_t gfp) in mt76u_buf_alloc() argument
261 buf->urb->sg = devm_kcalloc(dev->dev, nsgs, sizeof(*buf->urb->sg), in mt76u_buf_alloc()
266 sg_init_table(buf->urb->sg, nsgs); in mt76u_buf_alloc()
269 return mt76u_fill_rx_sg(dev, buf, nsgs, len, sglen); in mt76u_buf_alloc()
341 int data_len, len, nsgs = 1; in mt76u_process_rx_entry() local
366 data_len = min_t(int, len, urb->sg[nsgs].length); in mt76u_process_rx_entry()
368 sg_page(&urb->sg[nsgs]), in mt76u_process_rx_entry()
369 urb->sg[nsgs].offset, in mt76u_process_rx_entry()
372 nsgs++; in mt76u_process_rx_entry()
376 return nsgs; in mt76u_process_rx_entry()
412 int err, nsgs, buf_len = q->buf_size; in mt76u_rx_tasklet() local
422 nsgs = mt76u_process_rx_entry(dev, buf->urb); in mt76u_rx_tasklet()
423 if (nsgs > 0) { in mt76u_rx_tasklet()
424 err = mt76u_fill_rx_sg(dev, buf, nsgs, in mt76u_rx_tasklet()
464 int i, err, nsgs; in mt76u_alloc_rx() local
475 nsgs = MT_SG_MAX_SIZE; in mt76u_alloc_rx()
478 nsgs = 1; in mt76u_alloc_rx()
483 nsgs, q->buf_size, in mt76u_alloc_rx()
633 int nsgs = 1 + skb_shinfo(skb)->nr_frags; in mt76u_tx_build_sg() local
637 nsgs += 1 + skb_shinfo(iter)->nr_frags; in mt76u_tx_build_sg()
641 nsgs = min_t(int, MT_SG_MAX_SIZE, nsgs); in mt76u_tx_build_sg()
642 sg_init_marker(urb->sg, nsgs); in mt76u_tx_build_sg()
643 urb->num_sgs = nsgs; in mt76u_tx_build_sg()