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

Re: [XEN PATCH] IOMMU: address violations of MISRA C:2012 Rules 8.2 and 8.3


  • To: Federico Serafini <federico.serafini@xxxxxxxxxxx>
  • From: Jan Beulich <jbeulich@xxxxxxxx>
  • Date: Mon, 31 Jul 2023 12:42:06 +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=bxcWbuG6pYAfIrM2OIbIli2RThg4K/IU7PnaTQ/lKKM=; b=fVxZG9gOyjJEUJdBwR2xCyTpfSB8t77zDDLXlhWolg0eKMPkMhJtUZvNZPFjHy3BN1vumLb78aaPZyg/BB9kTVj31GFBBUAAhts15wYy538T+FQmHvqPaRhFMh26JUeJpuB8HkRoc4PtfpM14QivmdTIXefoZrf9v10bUT2Rp04uLloFsIYh5uyZcRISQqgYI6Zt1V5Az2gbYKxF3UynaGfpcOaigYM9Ti9fQwVzVAlYGSKp/seIDzJGfo6nFUYFlvq3QOVi+56uq6TFZilw8RzCS9L0iq24KkiCXPG0hZI+1LXAKKDu+PZS6aeiIdJ3WvCuVsXXSD/XlXAanR9wyQ==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=SIq9WTz9eY5Sz54fEDUs2ww9xjijbyzFeJprGO7+ctZIAFcKNO/JX/17cFuHh+LsDAAf3dSwDjQsF3DXv8DAPSYQz5K77pL0+sAdjITjofiXFzqQ7vYKrJlVEyestcbqER6B9fKPzHtdUPUNIJ4S6vUJZjoxsNbk0Pkz1aNN5n4GjeV3NPseaWs9qtqvhJP5JJStt2Cfd/bjJcA3qtwmLxwgJDodjU6gAu065V6U+PLpChfzQLdfZPnMNRwmYyZ2fBauZWjNxIWkYVYh6bXicSfMsX+ktxU5TSFYdahnTMiBTz4nJ6vfcTjg9V8XWjgNkthQ05hxnCwmImNTpPpCRQ==
  • Authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=suse.com;
  • Cc: xen-devel@xxxxxxxxxxxxxxxxxxxx, consulting@xxxxxxxxxxx, Paul Durrant <paul@xxxxxxx>, Roger Pau Monné <roger.pau@xxxxxxxxxx>, Michal Orzel <michal.orzel@xxxxxxx>, Xenia Ragiadakou <xenia.ragiadakou@xxxxxxx>, Ayan Kumar Halder <ayan.kumar.halder@xxxxxxx>, Stefano Stabellini <sstabellini@xxxxxxxxxx>
  • Delivery-date: Mon, 31 Jul 2023 10:42:20 +0000
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>

On 29.07.2023 01:29, Stefano Stabellini wrote:
> On Fri, 28 Jul 2023, Federico Serafini wrote:
>> Give a name to unnamed parameters to address violations of
>> MISRA C:2012 Rule 8.2 ("Function types shall be in prototype form with
>> named parameters").
>> Keep consistency between parameter names and types used in function
>> declarations and the ones used in the corresponding function
>> definitions, thus addressing violations of MISRA C:2012 Rule 8.3
>> ("All declarations of an object or function shall use the same names
>> and type qualifiers").
>>
>> No functional changes.
>>
>> Signed-off-by: Federico Serafini <federico.serafini@xxxxxxxxxxx>
> 
> Reviewed-by: Stefano Stabellini <sstabellini@xxxxxxxxxx>

Acked-by: Jan Beulich <jbeulich@xxxxxxxx>

>> --- a/xen/drivers/passthrough/iommu.c
>> +++ b/xen/drivers/passthrough/iommu.c
>> @@ -25,10 +25,10 @@
>>  unsigned int __read_mostly iommu_dev_iotlb_timeout = 1000;
>>  integer_param("iommu_dev_iotlb_timeout", iommu_dev_iotlb_timeout);
>>  
>> -bool_t __initdata iommu_enable = 1;
>> -bool_t __read_mostly iommu_enabled;
>> -bool_t __read_mostly force_iommu;
>> -bool_t __read_mostly iommu_verbose;
>> +bool __initdata iommu_enable = 1;
>> +bool __read_mostly iommu_enabled;
>> +bool __read_mostly force_iommu;
>> +bool __read_mostly iommu_verbose;
>>  static bool_t __read_mostly iommu_crash_disable;
>>  
>>  #define IOMMU_quarantine_none         0 /* aka false */
>> @@ -57,7 +57,7 @@ int8_t __hwdom_initdata iommu_hwdom_reserved = -1;
>>  bool __read_mostly iommu_hap_pt_share = true;
>>  #endif
>>  
>> -bool_t __read_mostly iommu_debug;
>> +bool __read_mostly iommu_debug;

Lots of data objects are fiddled with here, so I guess the description
would better not talk of only functions. I guess adjusting for that
could be done while committing ...

Jan



 


Rackspace

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