lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20130611131856.GA11888@obelix.rh>
Date:	Tue, 11 Jun 2013 10:18:56 -0300
From:	Flavio Leitner <fbl@...hat.com>
To:	Jiri Pirko <jiri@...nulli.us>
Cc:	netdev@...r.kernel.org, davem@...emloft.net, edumazet@...gle.com
Subject: Re: [patch net-next 1/3] team: remove synchronize_rcu() called
 during queue override change

On Tue, Jun 11, 2013 at 10:01:07AM +0200, Jiri Pirko wrote:
> Tue, Jun 11, 2013 at 07:40:46AM CEST, jiri@...nulli.us wrote:
> >Tue, Jun 11, 2013 at 02:48:45AM CEST, fbl@...hat.com wrote:
> >>On Mon, Jun 10, 2013 at 05:42:23PM +0200, Jiri Pirko wrote:
> >>> This patch removes synchronize_rcu() from function
> >>> __team_queue_override_port_del(). That can be done because it is ok to
> >>> do list_del_rcu() and list_add_tail_rcu() on the same list_head member
> >>> without calling synchronize_rcu() in between. A bit of refactoring
> >>> needed to be done because INIT_LIST_HEAD needed to be removed (to not
> >>> kill the forward pointer) as well.
> >>> 
> >>> Signed-off-by: Jiri Pirko <jiri@...nulli.us>
> >>> ---
> >>>  drivers/net/team/team.c | 63 ++++++++++++++++++++++++++++++++++++-------------
> >>>  1 file changed, 47 insertions(+), 16 deletions(-)
> >>> 
> >>[...]
> >>
> >>> @@ -1278,17 +1310,16 @@ static int team_queue_id_option_set(struct team *team,
> >>>  				    struct team_gsetter_ctx *ctx)
> >>>  {
> >>>  	struct team_port *port = ctx->info->port;
> >>> +	u16 new_queue_id = ctx->data.u32_val;
> >>>  
> >>> -	if (port->queue_id == ctx->data.u32_val)
> >>> +	if (port->queue_id == new_queue_id)
> >>
> >>Since you're passing new_queue_id to port->queue_id and
> >>in the other parts you test against !port->queue_id to see
> >>if it's enable or not, that means queue 0 can't be used.
> >>
> >>Maybe I am missing something, but wouldn't be better to
> >>initialize with -1 and allow 0 to be used as well?
> >
> >0 means default queue. It's done the same was as in bonding code.
> 
> + this patch does not change original behaviour...

Jiri explained this bits off list to me, so

Acked-by: Flavio Leitner <fbl@...hat.com>

Thanks,
-- 
fbl


--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ