[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID:
<CH0PR18MB4339625085013AAC5E89B16ECDCE2@CH0PR18MB4339.namprd18.prod.outlook.com>
Date: Tue, 18 Jun 2024 09:03:55 +0000
From: Geethasowjanya Akula <gakula@...vell.com>
To: Markus Elfring <Markus.Elfring@....de>,
"netdev@...r.kernel.org"
<netdev@...r.kernel.org>,
"David S. Miller" <davem@...emloft.net>,
Eric
Dumazet <edumazet@...gle.com>, Jakub Kicinski <kuba@...nel.org>,
Paolo Abeni
<pabeni@...hat.com>
CC: LKML <linux-kernel@...r.kernel.org>,
Hariprasad Kelam
<hkelam@...vell.com>,
Subbaraya Sundeep Bhatta <sbhatta@...vell.com>,
Sunil
Kovvuri Goutham <sgoutham@...vell.com>
Subject: Re: [EXTERNAL] Re: [net-next PATCH v5 01/10] octeontx2-pf:
Refactoring RVU driver
________________________________________
>From: Markus Elfring <Markus.Elfring@....de>
>Sent: Saturday, June 15, 2024 4:45 PM
>To: Geethasowjanya Akula; netdev@...r.kernel.org; David S. Miller; Eric Dumazet; Jakub Kicinski; Paolo Abeni
>Cc: LKML; Hariprasad Kelam; Subbaraya Sundeep Bhatta; Sunil Kovvuri Goutham
>Subject: [EXTERNAL] Re: [net-next PATCH v5 01/10] octeontx2-pf: Refactoring RVU driver
…
>> +++ b/drivers/net/ethernet/marvell/octeontx2/nic/otx2_pf.c
…
>> +void otx2_disable_napi(struct otx2_nic *pf)
>> {
…
>> - cancel_work_sync(&cq_poll->dim.work);
>> + work = &cq_poll->dim.work;
>> + if (work->func)
> + cancel_work_sync(&cq_poll->dim.work);
…
>I suggest to use the shown local variable once more.
>+ cancel_work_sync(work);
Will fix in the next version.
…
>> +int otx2_init_rsrc(struct pci_dev *pdev, struct otx2_nic *pf)
>> +{
…
>> + return 0;
>> +
>> +err_detach_rsrc:
>> + if (pf->hw.lmt_info)
>> + free_percpu(pf->hw.lmt_info);
>> + if (test_bit(CN10K_LMTST, &pf->hw.cap_flag))
>> + qmem_free(pf->dev, pf->dync_lmt);
>> + otx2_detach_resources(&pf->mbox);
>> +err_disable_mbox_intr:
>> + otx2_disable_mbox_intr(pf);
>> +err_mbox_destroy:
>>+ otx2_pfaf_mbox_destroy(pf);
>> +err_free_irq_vectors:
>> + pci_free_irq_vectors(hw->pdev);
>> +
>> + return err;
>> +}
…
>Would you become interested to convert any usages of goto chains
>into applications of scope-based resource management?
>https://urldefense.proofpoint.com/v2/url?u=https-3A__elixir.bootlin.com_linux_v6.10->2Drc3_source_include_linux_cleanup.h->23L8&d=DwIFaQ&c=nKjWec2b6R0mOyPaz7xtfQ&r=UiEt_nUeYFctu7JVLXVlXDhTmq_EAfooaZEYInfGuEQ&m=Wq9YJ>y75Hspwe2mx3fN8YFPaAxSUtmgM0Q8XVmIg9whiPwJenparsxf0LX9-xCkV&s=Rv72FUI-wGHavNlkfj->jThXTxMciifdWbwE9njT5PtY&e=
Regards,
Markus
Powered by blists - more mailing lists