Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 24 Jul 2013 13:20:27 -0600
From:      "Justin T. Gibbs" <gibbs@FreeBSD.org>
To:        =?iso-8859-1?Q?Ulrich_Sp=F6rlein?= <uqs@freebsd.org>
Cc:        scsi@freebsd.org
Subject:   Re: Please review patch for aic7xxx_pci.c
Message-ID:  <1A005A2E-6DD4-4D3D-AD5B-2C8BD167EB03@FreeBSD.org>
In-Reply-To: <20130723222939.GH9030@acme.spoerlein.net>
References:  <20130716094927.GA9030@acme.spoerlein.net> <20130723071129.GD9030@acme.spoerlein.net> <FBF11F26-4083-4F7C-AEC6-054E369A1A25@FreeBSD.org> <20130723204530.GE9030@acme.spoerlein.net> <86E509ED-694D-49B0-A3D9-C9C7B71F67CE@FreeBSD.org> <20130723214126.GG9030@acme.spoerlein.net> <DB1AD5E3-8108-46EF-AEC0-195AEEF7FCEC@FreeBSD.org> <20130723222939.GH9030@acme.spoerlein.net>

index | next in thread | previous in thread | raw e-mail

On Jul 23, 2013, at 4:29 PM, Ulrich Spörlein <uqs@freebsd.org> wrote:

> On Tue, 2013-07-23 at 16:04:04 -0600, Justin T. Gibbs wrote:
>> On Jul 23, 2013, at 3:41 PM, Ulrich Spörlein <uqs@freebsd.org> wrote:
>> 
>>> On Tue, 2013-07-23 at 15:15:53 -0600, Justin T. Gibbs wrote:
>>>> On Jul 23, 2013, at 2:45 PM, Ulrich Spörlein <uqs@freebsd.org> wrote:
>>>> 
>>>>> Thanks, but maybe it's better to have the discussion here.
>>>>> 
>>>>> You wrote:
>>>>> The difference in the argument order between the declaration and definition is
>>>>> likely what led to this programming error. Your patch should also correct the
>>>>> argument reversal in the declaration of ahc_9005_subdevinfo_valid().
>>>>> 
>>>>> The argument order you've used seems the best choice since it matches what is
>>>>> used in ahc_compose_id().
>>>>> 
>>>>> 
>>>>> 
>>>>> I'm not sure that reversing the arguments in the function definition is
>>>>> the right way. This would make the patch a no-op.
>>>> 
>>>> Read the quote again.  I said change the "declaration", not the
>>>> "definition".  To be extremely clear, the code currently looks like
>>>> this:
>>> 
>>> D'oh, that's what I get for reading too fast. I've opted to change the
>>> function definition, in the end, so that declaration, definition and
>>> call-site are in sync, see
>>> https://github.com/uqs/freebsd-head/commit/e699b2fde01f235a22e1125e9f3aef16623b512f
>>> 
>>> Thanks!
>>> Uli
>> 
>> But now the order of the arguments does not match ahc_compose_id().
>> 
>> It seems to me that we want to only have a single convention in how this
>> data is passed to functions.
> 
> Ok, back to the first variant then.

Works for me.

--
Justin

help

Want to link to this message? Use this
URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?1A005A2E-6DD4-4D3D-AD5B-2C8BD167EB03>