[dpdk-dev] [PATCH v2 19/25] drivers/net: check process type in close operation

Stephen Hemminger stephen at networkplumber.org
Mon Sep 28 20:51:39 CEST 2020


On Mon, 28 Sep 2020 01:42:43 +0200
Thomas Monjalon <thomas at monjalon.net> wrote:

> The secondary processes are not allowed to release shared resources.
> Only process-private ressources should be freed in a secondary process.
> Most of the time, there is no process-private ressource,
> so the close operation is just forbidden in a secondary process.
> 
> After adding proper check in the port close functions,
> some redundant checks in the device remove functions are dropped.
> 
> Signed-off-by: Thomas Monjalon <thomas at monjalon.net>

Since this is a common issue across many drivers, my preference would be that the
check should be in common code of eth_dev_close.  It looks like only a few drivers
would allow close from secondary, and that would not be that helpful to a user.


More information about the dev mailing list