Skip to content

Commit 78a3613

Browse files
Dr. David Alan Gilbertkuba-moo
authored andcommitted
net/fungible: Remove unused fun_create_queue
fun_create_queue was added in 2022 by commit e1ffcc6 ("net/fungible: Add service module for Fungible drivers") but hasn't been used. Remove it. Also remove the static helper functions it was the only user of. Signed-off-by: Dr. David Alan Gilbert <[email protected]> Signed-off-by: Jakub Kicinski <[email protected]>
1 parent a537cfd commit 78a3613

File tree

2 files changed

+0
-66
lines changed

2 files changed

+0
-66
lines changed

drivers/net/ethernet/fungible/funcore/fun_queue.c

Lines changed: 0 additions & 65 deletions
Original file line numberDiff line numberDiff line change
@@ -482,43 +482,6 @@ struct fun_queue *fun_alloc_queue(struct fun_dev *fdev, int qid,
482482
return NULL;
483483
}
484484

485-
/* Create a funq's CQ on the device. */
486-
static int fun_create_cq(struct fun_queue *funq)
487-
{
488-
struct fun_dev *fdev = funq->fdev;
489-
unsigned int rqid;
490-
int rc;
491-
492-
rqid = funq->cq_flags & FUN_ADMIN_EPCQ_CREATE_FLAG_RQ ?
493-
funq->rqid : FUN_HCI_ID_INVALID;
494-
rc = fun_cq_create(fdev, funq->cq_flags, funq->cqid, rqid,
495-
funq->cqe_size_log2, funq->cq_depth,
496-
funq->cq_dma_addr, 0, 0, funq->cq_intcoal_nentries,
497-
funq->cq_intcoal_usec, funq->cq_vector, 0, 0,
498-
&funq->cqid, &funq->cq_db);
499-
if (!rc)
500-
dev_dbg(fdev->dev, "created CQ %u\n", funq->cqid);
501-
502-
return rc;
503-
}
504-
505-
/* Create a funq's SQ on the device. */
506-
static int fun_create_sq(struct fun_queue *funq)
507-
{
508-
struct fun_dev *fdev = funq->fdev;
509-
int rc;
510-
511-
rc = fun_sq_create(fdev, funq->sq_flags, funq->sqid, funq->cqid,
512-
funq->sqe_size_log2, funq->sq_depth,
513-
funq->sq_dma_addr, funq->sq_intcoal_nentries,
514-
funq->sq_intcoal_usec, funq->cq_vector, 0, 0,
515-
0, &funq->sqid, &funq->sq_db);
516-
if (!rc)
517-
dev_dbg(fdev->dev, "created SQ %u\n", funq->sqid);
518-
519-
return rc;
520-
}
521-
522485
/* Create a funq's RQ on the device. */
523486
int fun_create_rq(struct fun_queue *funq)
524487
{
@@ -561,34 +524,6 @@ int fun_request_irq(struct fun_queue *funq, const char *devname,
561524
return rc;
562525
}
563526

564-
/* Create all component queues of a funq on the device. */
565-
int fun_create_queue(struct fun_queue *funq)
566-
{
567-
int rc;
568-
569-
rc = fun_create_cq(funq);
570-
if (rc)
571-
return rc;
572-
573-
if (funq->rq_depth) {
574-
rc = fun_create_rq(funq);
575-
if (rc)
576-
goto release_cq;
577-
}
578-
579-
rc = fun_create_sq(funq);
580-
if (rc)
581-
goto release_rq;
582-
583-
return 0;
584-
585-
release_rq:
586-
fun_destroy_sq(funq->fdev, funq->rqid);
587-
release_cq:
588-
fun_destroy_cq(funq->fdev, funq->cqid);
589-
return rc;
590-
}
591-
592527
void fun_free_irq(struct fun_queue *funq)
593528
{
594529
if (funq->irq_handler) {

drivers/net/ethernet/fungible/funcore/fun_queue.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -163,7 +163,6 @@ static inline void fun_set_cq_callback(struct fun_queue *funq, cq_callback_t cb,
163163
}
164164

165165
int fun_create_rq(struct fun_queue *funq);
166-
int fun_create_queue(struct fun_queue *funq);
167166

168167
void fun_free_irq(struct fun_queue *funq);
169168
int fun_request_irq(struct fun_queue *funq, const char *devname,

0 commit comments

Comments
 (0)