[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [XEN PATCH v2] x86: make function declarations consistent with definitions


  • To: Stefano Stabellini <sstabellini@xxxxxxxxxx>
  • From: Jan Beulich <jbeulich@xxxxxxxx>
  • Date: Thu, 6 Jul 2023 08:27:55 +0200
  • Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=suse.com; dmarc=pass action=none header.from=suse.com; dkim=pass header.d=suse.com; arc=none
  • Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=VeQhAvnn9t5CFGlnixpbBOKQTUVYlkm4QPRjUZao/po=; b=nqh2DP6SyYV4umBgYwnNpUxM+zC3TZoor18QP/Cm1vyoe3glzWgNWxUolyRdEgJkan0yzhivPz+fSQ6tZohumV9uHpHFghF68OstZtPGocYYSjuBw37s57n99eP/lZlA75t6db5KwGwtLFGciX3CuIFI7o66tUSDiVQVLWxJZ7m6nJ+sa60YB/MXf3HhFURxgGaE3847E7hAlF7JJneODVkK2rFoxFA7qd7cnWYrkr8FNKBmTYw17WmXOFtIk+UX70hDEiSYNabh5grooNjDnsgKayV8TC1JGaaq+s8FsUCrrXtSPQyJKSVefL5cRr8Z8y+iplvph4llq/90rRNteQ==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=ALdsiUSRHAKg55ClmFzd9Fz5hmFRyaG99YWyG26BOEg49z0C/CsDx0n2uor/isiAJZxvivygUYQqyB48SrooG2vh8VAbwZ8O0uibrxSxsCOL9GoptBMJZLBs1b/DvjNfbn22NxBWv5793ScjKupoxnp95P4dpaY/zOUb0oCL9YEqzUAqrCINOLf6VFwXzFkjQLPjdm2ALKlgemwUAVZAcQ3TUWAWrG526nyipVCDPzg9BHmkybm/94f+c/tmwS9SqyATGsJNAak/tZrNJ3a9I6m3epXjfzegWpFzWgPlQGP5oFGaLoEr3YYn4XnFreTCRsjmI9YY04wDBY+rL7jFKw==
  • Authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=suse.com;
  • Cc: Federico Serafini <federico.serafini@xxxxxxxxxxx>, consulting@xxxxxxxxxxx, Andrew Cooper <andrew.cooper3@xxxxxxxxxx>, Roger Pau Monné <roger.pau@xxxxxxxxxx>, Wei Liu <wl@xxxxxxx>, Paul Durrant <paul@xxxxxxx>, Tamas K Lengyel <tamas@xxxxxxxxxxxxx>, Alexandru Isaila <aisaila@xxxxxxxxxxxxxxx>, Petre Pircalabu <ppircalabu@xxxxxxxxxxxxxxx>, Jun Nakajima <jun.nakajima@xxxxxxxxx>, Kevin Tian <kevin.tian@xxxxxxxxx>, Michal Orzel <michal.orzel@xxxxxxx>, Xenia Ragiadakou <xenia.ragiadakou@xxxxxxx>, Ayan Kumar Halder <ayan.kumar.halder@xxxxxxx>, xen-devel@xxxxxxxxxxxxxxxxxxxx
  • Delivery-date: Thu, 06 Jul 2023 06:28:18 +0000
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>

On 06.07.2023 01:22, Stefano Stabellini wrote:
> On Tue, 4 Jul 2023, Jan Beulich wrote:
>> On 04.07.2023 12:23, Federico Serafini wrote:
>>> Change mechanically the parameter names and types of function
>>> declarations to be consistent with the ones used in the corresponding
>>> definitions so as to fix violations of MISRA C:2012 Rule 8.3 ("All
>>> declarations of an object or function shall use the same names and type
>>> qualifiers") and MISRA C:2012 Rule 8.2 ("Function types shall be in
>>> prototype form with named parameters").
>>>
>>> Signed-off-by: Federico Serafini <federico.serafini@xxxxxxxxxxx>
>>
>> On top of my earlier remark (when this was part of a series):
> 
> I am not addressing specifically this comment. I am trying to build a
> common understanding on how to do things so that we can go faster in the
> future.
> 
> In general, as discussed at Xen Summit, in order to successfully merge
> large numbers of changes in the coming weeks we should try to keep
> mechanical changes mechanical. Separate non-mechanical changes into
> different patches.
> 
> This patch is large but mechanical. If I understand you correctly, you
> are asking:
> 1) to split the patch into smaller patches
> 2) make a couple of non-mechanical changes described below
> 
> 
> For 1), in my opinion it is not necessary as long as all changes remain
> mechanical. If some changes are not mechanical they should be split out.
> So if you are asking non-mechanical changes in 2), then 2) should be
> split out but everything else could stay in the same patch.
> 
> If you'd still like the patch to be split, OK but then you might want to
> suggest exactly how it should be split because it is not obvious: all
> changes are similar, local, and mechanical. I for one wouldn't know how
> you would like this patch to be split.

So I gave a clear reason and guideline how to split: To reduce the Cc
list of (because of requiring fewer acks for) individual patches, and
to separate (possibly) controversial from non-controversial changes.
This then allows "easy" changes to go in quickly.

I realize that what may be controversial may not always be obvious,
but if in doubt this can be addressed in a v2 by simply omitting such
changes after a respective comment was given (see also below).

> For 2), I would encourage you to consider the advantage of keeping the
> changes as-is in this patch, then send out a patch on top the way you
> prefer. That is because it costs you more time to describe how you
> would like these lines to be changed in English and review the full
> patch a second time, than change them yourself and anyone could ack them
> (feel free to CC me).
> 
> For clarity: I think it is totally fine that you have better suggestions
> on parameter names. I am only pointing out that providing those
> suggestions as feedback in an email reply is not a very efficient way to
> get it done.

What you suggest results in the same code being touched twice to
achieve the overall goal (satisfy Misra while at the same time not
making the code any worse than it already is). I'd like to avoid this
whenever possible, so my preference would be that if the English
description isn't clear, then the respective change would best be
omitted (and left to be addressed separately). (I hope it is obvious
enough why [largely needlessly] touching the same code twice isn't
nice.)

Jan



 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.