public inbox for kvm@vger.kernel.org
 help / color / mirror / Atom feed
From: James Hogan <james.hogan@imgtec.com>
To: linux-mips@linux-mips.org
Cc: Deng-Cheng Zhu <dengcheng.zhu@imgtec.com>,
	pbonzini@redhat.com, gleb@kernel.org, kvm@vger.kernel.org,
	sanjayl@kymasys.com, ralf@linux-mips.org
Subject: Re: [PATCH v3 1/9] MIPS: KVM: Reformat code and comments
Date: Wed, 25 Jun 2014 00:13:58 +0100	[thread overview]
Message-ID: <2425309.IacJWOu9rB@radagast> (raw)
In-Reply-To: <1403631071-6012-2-git-send-email-dengcheng.zhu@imgtec.com>

Hi Deng-Cheng,

On Tuesday 24 June 2014 10:31:02 Deng-Cheng Zhu wrote:
> diff --git a/arch/mips/kvm/kvm_mips.c b/arch/mips/kvm/kvm_mips.c
> index cd5e4f5..821e7e8 100644
> --- a/arch/mips/kvm/kvm_mips.c
> +++ b/arch/mips/kvm/kvm_mips.c

> -#define VCPU_STAT(x) offsetof(struct kvm_vcpu, stat.x), KVM_STAT_VCPU
> +#define VCPU_STAT(x) offsetof(struct kvm_vcpu, stat.x)
>  struct kvm_stats_debugfs_item debugfs_entries[] = {
> -	{ "wait", VCPU_STAT(wait_exits) },
> -	{ "cache", VCPU_STAT(cache_exits) },
> -	{ "signal", VCPU_STAT(signal_exits) },
> -	{ "interrupt", VCPU_STAT(int_exits) },
> -	{ "cop_unsuable", VCPU_STAT(cop_unusable_exits) },
> -	{ "tlbmod", VCPU_STAT(tlbmod_exits) },
> -	{ "tlbmiss_ld", VCPU_STAT(tlbmiss_ld_exits) },
> -	{ "tlbmiss_st", VCPU_STAT(tlbmiss_st_exits) },
> -	{ "addrerr_st", VCPU_STAT(addrerr_st_exits) },
> -	{ "addrerr_ld", VCPU_STAT(addrerr_ld_exits) },
> -	{ "syscall", VCPU_STAT(syscall_exits) },
> -	{ "resvd_inst", VCPU_STAT(resvd_inst_exits) },
> -	{ "break_inst", VCPU_STAT(break_inst_exits) },
> -	{ "flush_dcache", VCPU_STAT(flush_dcache_exits) },
> -	{ "halt_wakeup", VCPU_STAT(halt_wakeup) },
> +	{ "wait", VCPU_STAT(wait_exits), KVM_STAT_VCPU },
> +	{ "cache", VCPU_STAT(cache_exits), KVM_STAT_VCPU },
> +	{ "signal", VCPU_STAT(signal_exits), KVM_STAT_VCPU },
> +	{ "interrupt", VCPU_STAT(int_exits), KVM_STAT_VCPU },
> +	{ "cop_unsuable", VCPU_STAT(cop_unusable_exits), KVM_STAT_VCPU },
> +	{ "tlbmod", VCPU_STAT(tlbmod_exits), KVM_STAT_VCPU },
> +	{ "tlbmiss_ld", VCPU_STAT(tlbmiss_ld_exits), KVM_STAT_VCPU },
> +	{ "tlbmiss_st", VCPU_STAT(tlbmiss_st_exits), KVM_STAT_VCPU },
> +	{ "addrerr_st", VCPU_STAT(addrerr_st_exits), KVM_STAT_VCPU },
> +	{ "addrerr_ld", VCPU_STAT(addrerr_ld_exits), KVM_STAT_VCPU },
> +	{ "syscall", VCPU_STAT(syscall_exits), KVM_STAT_VCPU },
> +	{ "resvd_inst", VCPU_STAT(resvd_inst_exits), KVM_STAT_VCPU },
> +	{ "break_inst", VCPU_STAT(break_inst_exits), KVM_STAT_VCPU },
> +	{ "flush_dcache", VCPU_STAT(flush_dcache_exits), KVM_STAT_VCPU },
> +	{ "halt_wakeup", VCPU_STAT(halt_wakeup), KVM_STAT_VCPU },

IMO more important than making checkpatch happy here would be to put it in 
nicely tabulated columns ;-)

> diff --git a/arch/mips/kvm/kvm_mips_emul.c b/arch/mips/kvm/kvm_mips_emul.c
> index 8d48400..993dd1c 100644
> --- a/arch/mips/kvm/kvm_mips_emul.c
> +++ b/arch/mips/kvm/kvm_mips_emul.c

>  	switch (insn.i_format.opcode) {
> -		/*
> -		 * jr and jalr are in r_format format.
> -		 */
> +		 /* jr and jalr are in r_format format. */

bad indentation.

> diff --git a/arch/mips/kvm/kvm_trap_emul.c b/arch/mips/kvm/kvm_trap_emul.c
> index 693f952..baf6577 100644
> --- a/arch/mips/kvm/kvm_trap_emul.c
> +++ b/arch/mips/kvm/kvm_trap_emul.c

> @@ -186,10 +185,12 @@ static int kvm_trap_emul_handle_tlb_ld_miss(struct
> kvm_vcpu *vcpu) vcpu->arch.pc, badvaddr);
> 
>  		/* User Address (UA) fault, this could happen if

this comment could be fixed too

Otherwise this patch looks good. Thanks for doing this!

Cheers
James

  reply	other threads:[~2014-06-24 23:14 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-06-24 17:31 [PATCH v3 0/9] MIPS: KVM: Bugfixes and cleanups Deng-Cheng Zhu
2014-06-24 17:31 ` [PATCH v3 1/9] MIPS: KVM: Reformat code and comments Deng-Cheng Zhu
2014-06-24 23:13   ` James Hogan [this message]
2014-06-24 17:31 ` [PATCH v3 2/9] MIPS: KVM: Use KVM internal logger Deng-Cheng Zhu
2014-06-25  8:59   ` James Hogan
2014-06-24 17:31 ` [PATCH v3 3/9] MIPS: KVM: Simplify functions by removing redundancy Deng-Cheng Zhu
2014-06-25  9:09   ` James Hogan
2014-06-24 17:31 ` [PATCH v3 4/9] MIPS: KVM: Remove unneeded volatile Deng-Cheng Zhu
2014-06-25  9:09   ` James Hogan
2014-06-24 17:31 ` [PATCH v3 5/9] MIPS: KVM: Rename files to remove the prefix "kvm_" and "kvm_mips_" Deng-Cheng Zhu
2014-06-25  9:11   ` James Hogan
2014-06-24 17:31 ` [PATCH v3 6/9] MIPS: KVM: Restore correct value for WIRED at TLB uninit Deng-Cheng Zhu
2014-06-25  9:24   ` James Hogan
2014-06-24 17:31 ` [PATCH v3 7/9] MIPS: KVM: Fix memory leak on VCPU Deng-Cheng Zhu
2014-06-25  9:28   ` James Hogan
2014-06-25 12:17     ` Paolo Bonzini
2014-06-27 23:47       ` Deng-Cheng Zhu
2014-06-24 17:31 ` [PATCH v3 8/9] MIPS: KVM: Skip memory cleaning in kvm_mips_commpage_init() Deng-Cheng Zhu
2014-06-25  9:31   ` James Hogan
2014-06-24 17:31 ` [PATCH v3 9/9] MIPS: KVM: Remove dead code of TLB index error in kvm_mips_emul_tlbwr() Deng-Cheng Zhu
2014-06-25 12:18 ` [PATCH v3 0/9] MIPS: KVM: Bugfixes and cleanups Paolo Bonzini

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=2425309.IacJWOu9rB@radagast \
    --to=james.hogan@imgtec.com \
    --cc=dengcheng.zhu@imgtec.com \
    --cc=gleb@kernel.org \
    --cc=kvm@vger.kernel.org \
    --cc=linux-mips@linux-mips.org \
    --cc=pbonzini@redhat.com \
    --cc=ralf@linux-mips.org \
    --cc=sanjayl@kymasys.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox