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  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]
Date:   Fri, 24 Jan 2020 22:42:43 +0000
From:   Saeed Mahameed <saeedm@...lanox.com>
To:     "joe@...ches.com" <joe@...ches.com>,
        "davem@...emloft.net" <davem@...emloft.net>
CC:     "netdev@...r.kernel.org" <netdev@...r.kernel.org>
Subject: Re: [net-next 06/14] mlx5: Use proper logging and tracing line
 terminations

On Fri, 2020-01-24 at 14:15 -0800, Joe Perches wrote:
> On Fri, 2020-01-24 at 21:55 +0000, Saeed Mahameed wrote:
> > From: Joe Perches <joe@...ches.com>
> 
> Not really from me.
> 
> > netdev_err should use newline termination but mlx5_health_report
> > is used in a trace output function devlink_health_report where
> > no newline should be used.
> > 
> > Remove the newlines from a couple formats and add a format string
> > of "%s\n" to the netdev_err call to not directly output the
> > logging string.
> > 
> > Also use snprintf to avoid any possible output string overrun.
> []
> > diff --git
> > a/drivers/net/ethernet/mellanox/mlx5/core/en/reporter_tx.c
> > b/drivers/net/ethernet/mellanox/mlx5/core/en/reporter_tx.c
> []
> > @@ -389,10 +389,10 @@ int mlx5e_reporter_tx_timeout(struct
> > mlx5e_txqsq *sq)
> >  	err_ctx.ctx = sq;
> >  	err_ctx.recover = mlx5e_tx_reporter_timeout_recover;
> >  	err_ctx.dump = mlx5e_tx_reporter_dump_sq;
> > -	sprintf(err_str,
> > -		"TX timeout on queue: %d, SQ: 0x%x, CQ: 0x%x, SQ Cons:
> > 0x%x SQ Prod: 0x%x, usecs since last trans: %u\n",
> > -		sq->channel->ix, sq->sqn, sq->cq.mcq.cqn, sq->cc, sq-
> > >pc,
> > -		jiffies_to_usecs(jiffies - sq->txq->trans_start));
> > +	snprintf(err_str, sizeof(err_str),
> > +		 "TX timeout on queue: %d, SQ: 0x%x, CQ: 0x%x, SQ Cons:
> > 0x%x SQ Prod: 0x%x, usecs since last trans: %u\n",
> > +		 sq->channel->ix, sq->sqn, sq->cq.mcq.cqn, sq->cc, sq-
> > >pc,
> > +		 jiffies_to_usecs(jiffies - sq->txq->trans_start));
> 
> This is not the patch I sent.
> There should not be a newline here and
> there was no newline in the patch I sent.
> 

Hi Joe,

Your patch didn't apply cleanly on top of net-next-mlx5, since there
were some already accepted patches touching the same places, so i took
the liberty to make the necessary changes for it to apply..

you make the call:

1) I can re-arrange things in order to make your patch appear as it
was, Although don't see any reason of doing this, since it will be a
lot of work for nothing.. 

2) keep it as is, and fix whatever you don't like about the current
state of the patch. (remove the newline).. 

Thanks,
Saeed.

Powered by blists - more mailing lists