mirror of
https://github.com/xen-project/xen.git
synced 2026-10-28 02:01:24 +01:00
x86: Name parameters in function declarations
With the wider testing, some more violations have been spotted. This addresses violations of Rule 8.2 (parameters must be named). livepatch_op() has a further problem. The other declaration (the stub for !LIVEPATCH builds) has a parameter named op, but the definition has the parameter named livepatch. Rename it to op which is more concise and better in line with it's type name. No functional change. Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com> Reviewed-by: Nicola Vetrini <nicola.vetrini@bugseng.com>
This commit is contained in:
1 parent
b6f399b341
commit
eb518632cd
4 files changed
+15
-15
No files matched your search
@@ -69,11 +69,11 @@ const uint8_t sh_type_to_size[] = {
|
||||
|
||||
DEFINE_PER_CPU(uint32_t,trace_shadow_path_flags);
|
||||
|
||||
static int cf_check sh_enable_log_dirty(struct domain *);
|
||||
static int cf_check sh_disable_log_dirty(struct domain *);
|
||||
static void cf_check sh_clean_dirty_bitmap(struct domain *);
|
||||
static int cf_check sh_enable_log_dirty(struct domain *d);
|
||||
static int cf_check sh_disable_log_dirty(struct domain *d);
|
||||
static void cf_check sh_clean_dirty_bitmap(struct domain *d);
|
||||
|
||||
static void cf_check shadow_update_paging_modes(struct vcpu *);
|
||||
static void cf_check shadow_update_paging_modes(struct vcpu *v);
|
||||
|
||||
/* Set up the shadow-specific parts of a domain struct at start of day.
|
||||
* Called for every domain from arch_domain_create() */
|
||||
|
||||
@@ -40,10 +40,10 @@ struct priv_op_ctxt {
|
||||
};
|
||||
|
||||
/* I/O emulation helpers. Use non-standard calling conventions. */
|
||||
void nocall load_guest_gprs(struct cpu_user_regs *);
|
||||
void nocall load_guest_gprs(struct cpu_user_regs *regs);
|
||||
void nocall save_guest_gprs(void);
|
||||
|
||||
typedef void io_emul_stub_t(struct cpu_user_regs *);
|
||||
typedef void io_emul_stub_t(struct cpu_user_regs *regs);
|
||||
|
||||
static io_emul_stub_t *io_emul_stub_setup(struct priv_op_ctxt *ctxt, u8 opcode,
|
||||
unsigned int port, unsigned int bytes)
|
||||
|
||||
@@ -2196,30 +2196,30 @@ static int livepatch_action(struct xen_sysctl_livepatch_action *action)
|
||||
return rc;
|
||||
}
|
||||
|
||||
int livepatch_op(struct xen_sysctl_livepatch_op *livepatch)
|
||||
int livepatch_op(struct xen_sysctl_livepatch_op *op)
|
||||
{
|
||||
int rc;
|
||||
|
||||
if ( (livepatch->flags & ~LIVEPATCH_FLAGS_MASK) &&
|
||||
!(livepatch->flags & LIVEPATCH_FLAG_FORCE) )
|
||||
if ( (op->flags & ~LIVEPATCH_FLAGS_MASK) &&
|
||||
!(op->flags & LIVEPATCH_FLAG_FORCE) )
|
||||
return -EINVAL;
|
||||
|
||||
switch ( livepatch->cmd )
|
||||
switch ( op->cmd )
|
||||
{
|
||||
case XEN_SYSCTL_LIVEPATCH_UPLOAD:
|
||||
rc = livepatch_upload(&livepatch->u.upload);
|
||||
rc = livepatch_upload(&op->u.upload);
|
||||
break;
|
||||
|
||||
case XEN_SYSCTL_LIVEPATCH_GET:
|
||||
rc = livepatch_get(&livepatch->u.get);
|
||||
rc = livepatch_get(&op->u.get);
|
||||
break;
|
||||
|
||||
case XEN_SYSCTL_LIVEPATCH_LIST:
|
||||
rc = livepatch_list(&livepatch->u.list);
|
||||
rc = livepatch_list(&op->u.list);
|
||||
break;
|
||||
|
||||
case XEN_SYSCTL_LIVEPATCH_ACTION:
|
||||
rc = livepatch_action(&livepatch->u.action);
|
||||
rc = livepatch_action(&op->u.action);
|
||||
break;
|
||||
|
||||
default:
|
||||
|
||||
@@ -62,7 +62,7 @@ struct livepatch_fstate {
|
||||
uint8_t insn_buffer[LIVEPATCH_OPAQUE_SIZE];
|
||||
};
|
||||
|
||||
int livepatch_op(struct xen_sysctl_livepatch_op *);
|
||||
int livepatch_op(struct xen_sysctl_livepatch_op *op);
|
||||
void check_for_livepatch_work(void);
|
||||
unsigned long livepatch_symbols_lookup_by_name(const char *symname);
|
||||
bool is_patch(const void *addr);
|
||||
|
||||