Re: [PATCH 1/3] mips/kvm: Improve code formatting in arch/mips/kvm/kvm_locore.S

2013-08-05 Thread James Hogan
Hi David,

On 01/08/13 21:22, David Daney wrote:
 From: David Daney david.da...@cavium.com
 
 No code changes, just reflowing some comments and consistently using
 tabs and spaces.  Object code is verified to be unchanged.
 
 Signed-off-by: David Daney david.da...@cavium.com
 Acked-by: Ralf Baechle r...@linux-mips.org


 +  /* Put the saved pointer to vcpu (s1) back into the DDATA_LO Register 
 */

git am detects a whitespace error here (space before tab in indent).
It's got spaces before and after the tab actually.

  /* load the guest context from VCPU and return */

this comment could have it's indentation fixed too

Otherwise, for all 3 patches:

Reviewed-by: James Hogan james.ho...@imgtec.com

Thanks
James

--
To unsubscribe from this list: send the line unsubscribe kvm in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH 1/3] mips/kvm: Improve code formatting in arch/mips/kvm/kvm_locore.S

2013-08-05 Thread Ralf Baechle
On Mon, Aug 05, 2013 at 02:17:01PM +0100, James Hogan wrote:

 
 On 01/08/13 21:22, David Daney wrote:
  From: David Daney david.da...@cavium.com
  
  No code changes, just reflowing some comments and consistently using
  tabs and spaces.  Object code is verified to be unchanged.
  
  Signed-off-by: David Daney david.da...@cavium.com
  Acked-by: Ralf Baechle r...@linux-mips.org
 
 
  +/* Put the saved pointer to vcpu (s1) back into the DDATA_LO 
  Register */
 
 git am detects a whitespace error here (space before tab in indent).
 It's got spaces before and after the tab actually.
 
   /* load the guest context from VCPU and return */
 
 this comment could have it's indentation fixed too
 
 Otherwise, for all 3 patches:
 
 Reviewed-by: James Hogan james.ho...@imgtec.com

I'm happy with the patch series as well and will fix this issue when
applying the patch.

  Ralf
--
To unsubscribe from this list: send the line unsubscribe kvm in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH 1/3] mips/kvm: Improve code formatting in arch/mips/kvm/kvm_locore.S

2013-08-05 Thread Gleb Natapov
On Mon, Aug 05, 2013 at 03:21:57PM +0200, Ralf Baechle wrote:
 On Mon, Aug 05, 2013 at 02:17:01PM +0100, James Hogan wrote:
 
  
  On 01/08/13 21:22, David Daney wrote:
   From: David Daney david.da...@cavium.com
   
   No code changes, just reflowing some comments and consistently using
   tabs and spaces.  Object code is verified to be unchanged.
   
   Signed-off-by: David Daney david.da...@cavium.com
   Acked-by: Ralf Baechle r...@linux-mips.org
  
  
   +  /* Put the saved pointer to vcpu (s1) back into the DDATA_LO 
   Register */
  
  git am detects a whitespace error here (space before tab in indent).
  It's got spaces before and after the tab actually.
  
/* load the guest context from VCPU and return */
  
  this comment could have it's indentation fixed too
  
  Otherwise, for all 3 patches:
  
  Reviewed-by: James Hogan james.ho...@imgtec.com
 
 I'm happy with the patch series as well and will fix this issue when
 applying the patch.
 
kvm fixes usually go through kvm.git tree for all arches. Any special
reasons you want to get those through mips tree?

--
Gleb.
--
To unsubscribe from this list: send the line unsubscribe kvm in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH 1/3] mips/kvm: Improve code formatting in arch/mips/kvm/kvm_locore.S

2013-08-05 Thread Ralf Baechle
On Mon, Aug 05, 2013 at 04:43:27PM +0300, Gleb Natapov wrote:
 Date:   Mon, 5 Aug 2013 16:43:27 +0300
 From: Gleb Natapov g...@redhat.com
 To: Ralf Baechle r...@linux-mips.org
 Cc: James Hogan james.ho...@imgtec.com, David Daney
  ddaney.c...@gmail.com, linux-m...@linux-mips.org, kvm@vger.kernel.org,
  Sanjay Lal sanj...@kymasys.com, linux-ker...@vger.kernel.org, David
  Daney david.da...@cavium.com
 Subject: Re: [PATCH 1/3] mips/kvm: Improve code formatting in
  arch/mips/kvm/kvm_locore.S
 Content-Type: text/plain; charset=us-ascii
 
 On Mon, Aug 05, 2013 at 03:21:57PM +0200, Ralf Baechle wrote:
  On Mon, Aug 05, 2013 at 02:17:01PM +0100, James Hogan wrote:
  
   
   On 01/08/13 21:22, David Daney wrote:
From: David Daney david.da...@cavium.com

No code changes, just reflowing some comments and consistently using
tabs and spaces.  Object code is verified to be unchanged.

Signed-off-by: David Daney david.da...@cavium.com
Acked-by: Ralf Baechle r...@linux-mips.org
   
   
+/* Put the saved pointer to vcpu (s1) back into the DDATA_LO 
Register */
   
   git am detects a whitespace error here (space before tab in indent).
   It's got spaces before and after the tab actually.
   
 /* load the guest context from VCPU and return */
   
   this comment could have it's indentation fixed too
   
   Otherwise, for all 3 patches:
   
   Reviewed-by: James Hogan james.ho...@imgtec.com
  
  I'm happy with the patch series as well and will fix this issue when
  applying the patch.
  
 kvm fixes usually go through kvm.git tree for all arches. Any special
 reasons you want to get those through mips tree?

MIPS fixes usually go through the MIPS tree ;-)

I don't care which tree this stuff goes through - but a general experience
is that things that affect MIPS systems receive most testing if going
through the MIPS tree.

  Ralf
--
To unsubscribe from this list: send the line unsubscribe kvm in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH 1/3] mips/kvm: Improve code formatting in arch/mips/kvm/kvm_locore.S

2013-08-05 Thread David Daney

On 08/05/2013 06:43 AM, Gleb Natapov wrote:

On Mon, Aug 05, 2013 at 03:21:57PM +0200, Ralf Baechle wrote:

On Mon, Aug 05, 2013 at 02:17:01PM +0100, James Hogan wrote:



On 01/08/13 21:22, David Daney wrote:

From: David Daney david.da...@cavium.com

No code changes, just reflowing some comments and consistently using
tabs and spaces.  Object code is verified to be unchanged.

Signed-off-by: David Daney david.da...@cavium.com
Acked-by: Ralf Baechle r...@linux-mips.org




+/* Put the saved pointer to vcpu (s1) back into the DDATA_LO Register 
*/


git am detects a whitespace error here (space before tab in indent).
It's got spaces before and after the tab actually.


  /* load the guest context from VCPU and return */


this comment could have it's indentation fixed too

Otherwise, for all 3 patches:

Reviewed-by: James Hogan james.ho...@imgtec.com


I'm happy with the patch series as well and will fix this issue when
applying the patch.


kvm fixes usually go through kvm.git tree for all arches. Any special
reasons you want to get those through mips tree?



I don't really care which tree takes this particular patch set.

However, in the near future, I will be sending revised versions of 
patches needed by MIPS/KVM that are in files outside of the 
arch/mips/kvm directory and it is possible that those may suffer patch 
ordering problems if merged through a 'foreign tree'.


In any event, there is the problem with the whitespace error in the 
comment.  I blame checkpatch.pl for not flagging it, but that is not 
really a good excuse.  If it goes by the KVM tree, do you want me to 
send a corrected patch?  Or can you fix it when you merge it.


David Daney

--
To unsubscribe from this list: send the line unsubscribe kvm in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH 1/3] mips/kvm: Improve code formatting in arch/mips/kvm/kvm_locore.S

2013-08-05 Thread Gleb Natapov
On Mon, Aug 05, 2013 at 07:06:10PM +0200, Ralf Baechle wrote:
 On Mon, Aug 05, 2013 at 04:43:27PM +0300, Gleb Natapov wrote:
  Date:   Mon, 5 Aug 2013 16:43:27 +0300
  From: Gleb Natapov g...@redhat.com
  To: Ralf Baechle r...@linux-mips.org
  Cc: James Hogan james.ho...@imgtec.com, David Daney
   ddaney.c...@gmail.com, linux-m...@linux-mips.org, kvm@vger.kernel.org,
   Sanjay Lal sanj...@kymasys.com, linux-ker...@vger.kernel.org, David
   Daney david.da...@cavium.com
  Subject: Re: [PATCH 1/3] mips/kvm: Improve code formatting in
   arch/mips/kvm/kvm_locore.S
  Content-Type: text/plain; charset=us-ascii
  
  On Mon, Aug 05, 2013 at 03:21:57PM +0200, Ralf Baechle wrote:
   On Mon, Aug 05, 2013 at 02:17:01PM +0100, James Hogan wrote:
   

On 01/08/13 21:22, David Daney wrote:
 From: David Daney david.da...@cavium.com
 
 No code changes, just reflowing some comments and consistently using
 tabs and spaces.  Object code is verified to be unchanged.
 
 Signed-off-by: David Daney david.da...@cavium.com
 Acked-by: Ralf Baechle r...@linux-mips.org


 +  /* Put the saved pointer to vcpu (s1) back into the DDATA_LO 
 Register */

git am detects a whitespace error here (space before tab in indent).
It's got spaces before and after the tab actually.

  /* load the guest context from VCPU and return */

this comment could have it's indentation fixed too

Otherwise, for all 3 patches:

Reviewed-by: James Hogan james.ho...@imgtec.com
   
   I'm happy with the patch series as well and will fix this issue when
   applying the patch.
   
  kvm fixes usually go through kvm.git tree for all arches. Any special
  reasons you want to get those through mips tree?
 
 MIPS fixes usually go through the MIPS tree ;-)
 
arch/*/kvm/ fixes usually go through the kvm.git though :) KVM arch
code, after it is reasonably stable, usually depends more on kvm common
code then arch code and kvm development suppose to happen against
kvm.git otherwise APIs can go out of sync. I need to get acks of MIPS
people before taking patches of course.

When patch series touches code outside of arch/*/kvm, like David says
the next one will, it make sense to merge it through MIPS tree, just
please take KVM maintainers ACK for kvm part.

 I don't care which tree this stuff goes through - but a general experience
 is that things that affect MIPS systems receive most testing if going
 through the MIPS tree.
 
   Ralf

--
Gleb.
--
To unsubscribe from this list: send the line unsubscribe kvm in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[PATCH 1/3] mips/kvm: Improve code formatting in arch/mips/kvm/kvm_locore.S

2013-08-01 Thread David Daney
From: David Daney david.da...@cavium.com

No code changes, just reflowing some comments and consistently using
tabs and spaces.  Object code is verified to be unchanged.

Signed-off-by: David Daney david.da...@cavium.com
Acked-by: Ralf Baechle r...@linux-mips.org
---
 arch/mips/kvm/kvm_locore.S | 971 +++--
 1 file changed, 489 insertions(+), 482 deletions(-)

diff --git a/arch/mips/kvm/kvm_locore.S b/arch/mips/kvm/kvm_locore.S
index dca2aa6..2b4fdd1 100644
--- a/arch/mips/kvm/kvm_locore.S
+++ b/arch/mips/kvm/kvm_locore.S
@@ -1,13 +1,13 @@
 /*
-* This file is subject to the terms and conditions of the GNU General Public
-* License.  See the file COPYING in the main directory of this archive
-* for more details.
-*
-* Main entry point for the guest, exception handling.
-*
-* Copyright (C) 2012  MIPS Technologies, Inc.  All rights reserved.
-* Authors: Sanjay Lal sanj...@kymasys.com
-*/
+ * This file is subject to the terms and conditions of the GNU General Public
+ * License.  See the file COPYING in the main directory of this archive
+ * for more details.
+ *
+ * Main entry point for the guest, exception handling.
+ *
+ * Copyright (C) 2012  MIPS Technologies, Inc.  All rights reserved.
+ * Authors: Sanjay Lal sanj...@kymasys.com
+ */
 
 #include asm/asm.h
 #include asm/asmmacro.h
@@ -57,172 +57,177 @@
  */
 
 FEXPORT(__kvm_mips_vcpu_run)
-.setpush
-.setnoreorder
-.setnoat
-
-/* k0/k1 not being used in host kernel context */
-   addiu   k1,sp, -PT_SIZE
-LONG_S $0, PT_R0(k1)
-LONG_S $1, PT_R1(k1)
-LONG_S $2, PT_R2(k1)
-LONG_S $3, PT_R3(k1)
-
-LONG_S $4, PT_R4(k1)
-LONG_S $5, PT_R5(k1)
-LONG_S $6, PT_R6(k1)
-LONG_S $7, PT_R7(k1)
-
-LONG_S $8,  PT_R8(k1)
-LONG_S $9,  PT_R9(k1)
-LONG_S $10, PT_R10(k1)
-LONG_S $11, PT_R11(k1)
-LONG_S $12, PT_R12(k1)
-LONG_S $13, PT_R13(k1)
-LONG_S $14, PT_R14(k1)
-LONG_S $15, PT_R15(k1)
-LONG_S $16, PT_R16(k1)
-LONG_S $17, PT_R17(k1)
-
-LONG_S $18, PT_R18(k1)
-LONG_S $19, PT_R19(k1)
-LONG_S $20, PT_R20(k1)
-LONG_S $21, PT_R21(k1)
-LONG_S $22, PT_R22(k1)
-LONG_S $23, PT_R23(k1)
-LONG_S $24, PT_R24(k1)
-LONG_S $25, PT_R25(k1)
+   .setpush
+   .setnoreorder
+   .setnoat
+
+   /* k0/k1 not being used in host kernel context */
+   addiu   k1, sp, -PT_SIZE
+   LONG_S  $0, PT_R0(k1)
+   LONG_S  $1, PT_R1(k1)
+   LONG_S  $2, PT_R2(k1)
+   LONG_S  $3, PT_R3(k1)
+
+   LONG_S  $4, PT_R4(k1)
+   LONG_S  $5, PT_R5(k1)
+   LONG_S  $6, PT_R6(k1)
+   LONG_S  $7, PT_R7(k1)
+
+   LONG_S  $8,  PT_R8(k1)
+   LONG_S  $9,  PT_R9(k1)
+   LONG_S  $10, PT_R10(k1)
+   LONG_S  $11, PT_R11(k1)
+   LONG_S  $12, PT_R12(k1)
+   LONG_S  $13, PT_R13(k1)
+   LONG_S  $14, PT_R14(k1)
+   LONG_S  $15, PT_R15(k1)
+   LONG_S  $16, PT_R16(k1)
+   LONG_S  $17, PT_R17(k1)
+
+   LONG_S  $18, PT_R18(k1)
+   LONG_S  $19, PT_R19(k1)
+   LONG_S  $20, PT_R20(k1)
+   LONG_S  $21, PT_R21(k1)
+   LONG_S  $22, PT_R22(k1)
+   LONG_S  $23, PT_R23(k1)
+   LONG_S  $24, PT_R24(k1)
+   LONG_S  $25, PT_R25(k1)
 
/* XXXKYMA k0/k1 not saved, not being used if we got here through an 
ioctl() */
 
-LONG_S $28, PT_R28(k1)
-LONG_S $29, PT_R29(k1)
-LONG_S $30, PT_R30(k1)
-LONG_S $31, PT_R31(k1)
+   LONG_S  $28, PT_R28(k1)
+   LONG_S  $29, PT_R29(k1)
+   LONG_S  $30, PT_R30(k1)
+   LONG_S  $31, PT_R31(k1)
 
-/* Save hi/lo */
-   mflov0
-   LONG_S  v0, PT_LO(k1)
-   mfhiv1
-   LONG_S  v1, PT_HI(k1)
+   /* Save hi/lo */
+   mflov0
+   LONG_S  v0, PT_LO(k1)
+   mfhiv1
+   LONG_S  v1, PT_HI(k1)
 
/* Save host status */
-   mfc0v0, CP0_STATUS
-   LONG_S  v0, PT_STATUS(k1)
+   mfc0v0, CP0_STATUS
+   LONG_S  v0, PT_STATUS(k1)
 
/* Save host ASID, shove it into the BVADDR location */
-   mfc0v1,CP0_ENTRYHI
-   andiv1, 0xff
-   LONG_S  v1, PT_HOST_ASID(k1)
+   mfc0v1, CP0_ENTRYHI
+   andiv1, 0xff
+   LONG_S  v1, PT_HOST_ASID(k1)
 
-/* Save DDATA_LO, will be used to store pointer to vcpu */
-mfc0v1, CP0_DDATA_LO
-LONG_S  v1, PT_HOST_USERLOCAL(k1)
+   /* Save DDATA_LO, will be used to store pointer to vcpu */
+   mfc0v1, CP0_DDATA_LO
+   LONG_S  v1, PT_HOST_USERLOCAL(k1)
 
-/* DDATA_LO has pointer to vcpu