On Wed, 17 Jun 2026 11:19:43 +0530 Rakesh Kudurumalla <[email protected]> wrote:
>
> +#define NIX_RQ_BULK_ENA_DIS_LOOP(REQ_TYPE, ALLOC_FN)
> \
> + do {
> \
> + for (i = 0; i < nb_rx_queues; i++) {
> \
> + REQ_TYPE *aq;
> \
> + if (rqs[i].qid == UINT16_MAX)
> \
> + continue;
> \
> + struct roc_nix_rq *rq = &rqs[i];
> \
> + aq = ALLOC_FN(mbox);
> \
> + if (!aq) {
> \
> + rc = mbox_process(mbox);
> \
> + if (rc)
> \
> + goto exit;
> \
> + aq = ALLOC_FN(mbox);
> \
> + if (!aq) {
> \
> + rc = -ENOSPC;
> \
> + goto exit;
> \
> + }
> \
> + }
> \
> + aq->qidx = rq->qid;
> \
> + aq->ctype = NIX_AQ_CTYPE_RQ;
> \
> + aq->op = NIX_AQ_INSTOP_WRITE;
> \
> + aq->rq.ena = enable;
> \
> + aq->rq_mask.ena = ~(aq->rq_mask.ena);
> \
> + }
> \
> + } while (0)
> +
Why can't this be an inline function? large macros are a bad idea.

