netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Giel van Schijndel <me@mortis.eu>
To: Johannes Berg <johannes@sipsolutions.net>,
	Andy Shevchenko <andy.shevchenko@gmail.com>
Cc: linux-kernel@vger.kernel.org, Kalle Valo <kvalo@codeaurora.org>,
	Eliad Peller <eliad@wizery.com>,
	"John W. Linville" <linville@tuxdriver.com>,
	Arik Nemtsov <arik@wizery.com>,
	"open list:TI WILINK WIRELES..." <linux-wireless@vger.kernel.org>,
	"open list:NETWORKING DRIVERS" <netdev@vger.kernel.org>
Subject: Re: [PATCH 2/2] Fix copy-paste bug: assign from src struct not dest
Date: Wed, 7 Jan 2015 20:18:36 +0100	[thread overview]
Message-ID: <20150107191836.GA18978@salidar.dom.custoft.eu> (raw)
In-Reply-To: <CAHp75Vetc+fgv=YrqPuW9YChez82h7N7VeX_5bW5tpXm2j=h7g@mail.gmail.com> <1420451671.9459.1.camel@sipsolutions.net>

[-- Attachment #1: Type: text/plain, Size: 1949 bytes --]

On Mon, Jan 05, 2015 at 10:54:31 +0100, Johannes Berg wrote:
> On Sun, 2015-01-04 at 19:00 +0100, Giel van Schijndel wrote:
>> ---
>>  drivers/net/wireless/ti/wlcore/acx.c | 2 +-
>>  1 file changed, 1 insertion(+), 1 deletion(-)
>> 
>> diff --git a/drivers/net/wireless/ti/wlcore/acx.c b/drivers/net/wireless/ti/wlcore/acx.c
>> index beb354c..93a2fa8 100644
>> --- a/drivers/net/wireless/ti/wlcore/acx.c
>> +++ b/drivers/net/wireless/ti/wlcore/acx.c
>> @@ -1725,7 +1725,7 @@ int wl12xx_acx_config_hangover(struct wl1271 *wl)
>>  	acx->decrease_delta             = conf->decrease_delta;
>>  	acx->quiet_time                 = conf->quiet_time;
>>  	acx->increase_time              = conf->increase_time;
>> -	acx->window_size                = acx->window_size;
>> +	acx->window_size                = conf->window_size;
> 
> It would be far better to fix the bug *first*, that way the bugfix can
> be cherry-picked/applied to trees that don't have the alignment.

I agree on the ordering.

As for:
> (And anyway I question the value of the alignment - if you really want
> to make this bug disappear you could perhaps use a macro)

And:
On Wed, Jan 07, 2015 at 20:40:57 +0200, Andy Shevchenko wrote:
> On Sun, Jan 4, 2015 at 8:00 PM, Giel van Schijndel <me@mortis.eu> wrote:
> > This highlights the differences (errors).
> 
> Seems like patch for the patch. Just fix an error like it's done here:
> http://www.spinics.net/lists/linux-wireless/msg131667.html

IMO the aligned block of code has the significant advantage of taking
advantage of humans' ability to spot things that break a pattern. Which
in this case becomes *very* visible when properly aligned, because
without the alignment there is no (visual) pattern (or at least not one
very suitable for my "visual processing system", I know the same applies
to at least some others).

-- 
Met vriendelijke groet,
With kind regards,
Giel van Schijndel

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 181 bytes --]

  reply	other threads:[~2015-01-07 19:18 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-01-04 18:00 [PATCH 1/2] Align member-assigns in a structure-copy block Giel van Schijndel
2015-01-04 18:00 ` [PATCH 2/2] Fix copy-paste bug: assign from src struct not dest Giel van Schijndel
2015-01-04 23:02   ` Giel van Schijndel
2015-01-05  9:54   ` Johannes Berg
2015-01-07 19:18     ` Giel van Schijndel [this message]
2015-01-07 22:16       ` Johannes Berg
2015-01-07 23:06         ` Arend van Spriel
2015-01-04 23:02 ` [PATCH 1/2] Align member-assigns in a structure-copy block Giel van Schijndel
2015-01-05  9:17   ` Kalle Valo
2015-01-05  9:16 ` Kalle Valo
     [not found] ` <1420394427-19509-1-git-send-email-me-sZ9Uef1cvPWHXe+LvDLADg@public.gmane.org>
2015-01-07 18:40   ` Andy Shevchenko
2015-01-07 19:38 ` [PATCH RESEND 1/2] wlcore: fix copy-paste bug: assign from src struct not dest Giel van Schijndel
2015-01-07 19:38   ` [PATCH RESEND 2/2] wlcore: align member-assigns in a structure-copy block Giel van Schijndel
     [not found]     ` <1420659525-22975-2-git-send-email-me-sZ9Uef1cvPWHXe+LvDLADg@public.gmane.org>
2015-01-09 17:03       ` Kalle Valo
     [not found]         ` <87vbkfga32.fsf-HodKDYzPHsUD5k0oWYwrnHL1okKdlPRT@public.gmane.org>
2015-01-11 10:22           ` Eliad Peller
2015-01-11 20:32             ` Giel van Schijndel
2015-01-15 13:23             ` Kalle Valo
2015-01-23 17:07   ` [RESEND, 1/2] wlcore: fix copy-paste bug: assign from src struct not dest Kalle Valo

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20150107191836.GA18978@salidar.dom.custoft.eu \
    --to=me@mortis.eu \
    --cc=andy.shevchenko@gmail.com \
    --cc=arik@wizery.com \
    --cc=eliad@wizery.com \
    --cc=johannes@sipsolutions.net \
    --cc=kvalo@codeaurora.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-wireless@vger.kernel.org \
    --cc=linville@tuxdriver.com \
    --cc=netdev@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).