[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <YdZwigIn6IG3a4h4@yorlov.ow.s>
Date: Thu, 6 Jan 2022 06:31:06 +0200
From: Yevhen Orlov <yevhen.orlov@...ision.eu>
To: Ido Schimmel <idosch@...sch.org>
Cc: netdev@...r.kernel.org, stephen@...workplumber.org, andrew@...n.ch,
Volodymyr Mytnyk <volodymyr.mytnyk@...ision.eu>,
Taras Chornyi <taras.chornyi@...ision.eu>,
Mickey Rachamim <mickeyr@...vell.com>,
Serhiy Pshyk <serhiy.pshyk@...ision.eu>,
Taras Chornyi <tchornyi@...vell.com>,
Oleksandr Mazur <oleksandr.mazur@...ision.eu>,
"David S. Miller" <davem@...emloft.net>,
Jakub Kicinski <kuba@...nel.org>, linux-kernel@...r.kernel.org
Subject: Re: [PATCH net-next v2 6/6] net: marvell: prestera: Implement
initial inetaddr notifiers
On Thu, Dec 30, 2021 at 04:39:23PM +0200, Ido Schimmel wrote:
> > + return -EEXIST;
> > + }
> > + re = prestera_rif_entry_create(port->sw, &re_key,
> > + prestera_fix_tb_id(kern_tb_id),
> > + port_dev->dev_addr);
> > + if (!re) {
> > + NL_SET_ERR_MSG_MOD(extack, "Can't create rif_entry");
> > + return -EINVAL;
> > + }
> > + dev_hold(port_dev);
>
> What is the purpose of this dev_hold()?
>
To make sure the port_dev is not freed before rif destroyed.
Powered by blists - more mailing lists