diff mbox series

[XEN] EFI: address violations of MISRA C:2012 Rules 8.2 and 8.3

Message ID 83d4091852797044209272dab750f13f7d30d35c.1690792406.git.federico.serafini@bugseng.com (mailing list archive)
State New, archived
Headers show
Series [XEN] EFI: address violations of MISRA C:2012 Rules 8.2 and 8.3 | expand

Commit Message

Federico Serafini July 31, 2023, 8:35 a.m. UTC
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@bugseng.com>
---
 xen/common/efi/efi.h  | 2 +-
 xen/include/xen/efi.h | 8 ++++----
 2 files changed, 5 insertions(+), 5 deletions(-)

Comments

Jan Beulich July 31, 2023, 10:43 a.m. UTC | #1
On 31.07.2023 10:35, 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@bugseng.com>

Acked-by: Jan Beulich <jbeulich@suse.com>
diff mbox series

Patch

diff --git a/xen/common/efi/efi.h b/xen/common/efi/efi.h
index c9aa65d506..c02fbb7b69 100644
--- a/xen/common/efi/efi.h
+++ b/xen/common/efi/efi.h
@@ -49,5 +49,5 @@  const CHAR16 *wmemchr(const CHAR16 *s, CHAR16 c, UINTN n);
 void *ebmalloc(size_t size);
 void free_ebmalloc_unused_mem(void);
 
-const void *pe_find_section(const void *image_base, const size_t image_size,
+const void *pe_find_section(const void *image, const UINTN image_size,
                             const CHAR16 *section_name, UINTN *size_out);
diff --git a/xen/include/xen/efi.h b/xen/include/xen/efi.h
index 94a7e547f9..942d2e9491 100644
--- a/xen/include/xen/efi.h
+++ b/xen/include/xen/efi.h
@@ -39,11 +39,11 @@  unsigned long efi_get_time(void);
 void efi_halt_system(void);
 void efi_reset_system(bool warm);
 #ifndef COMPAT
-int efi_get_info(uint32_t idx, union xenpf_efi_info *);
-int efi_runtime_call(struct xenpf_efi_runtime_call *);
+int efi_get_info(uint32_t idx, union xenpf_efi_info *info);
+int efi_runtime_call(struct xenpf_efi_runtime_call *op);
 #endif
-int efi_compat_get_info(uint32_t idx, union compat_pf_efi_info *);
-int efi_compat_runtime_call(struct compat_pf_efi_runtime_call *);
+int efi_compat_get_info(uint32_t idx, union compat_pf_efi_info *info);
+int efi_compat_runtime_call(struct compat_pf_efi_runtime_call *op);
 
 #endif /* !__ASSEMBLY__ */