HomeFreeBSD

mana: fix misc minor handlding issues when error happens.

Description

mana: fix misc minor handlding issues when error happens.

  • In mana_create_txq(), if test fails we must free some resources as in all the other handling paths of this function.
  • In mana_gd_read_cqe(), add warning log in case of CQE read overflow, instead of failing silently.
  • Fix error handling in mana_create_rxq() when cq->gdma_id >= gc->max_num_cqs.
  • In mana_init_port(), use the correct port index rather than 0.
  • In mana_hwc_create_wq(), If allocating the DMA buffer fails, mana_hwc_destroy_wq was called without previously storing the pointer to the queue. In order to avoid leaking the pointer to the queue, store it as soon as it is allocated.

MFC after: 2 weeks
Sponsored by: Microsoft

Details

Provenance
whuAuthored on Jan 13 2022, 6:17 AM
Parents
rGb1ddfd080ac9: stress2: Updated the exclude list
Branches
Unknown
Tags
Unknown