Skip to contentSkip to conversation

tree-wide: replace tabs with sapce and align code This patch updates by replacing the tabs with spaces and fixing alignment issues Signed-off-by: Harshini <[email protected]> Signed-off-by: Akshaya S <[email protected]> Signed-off-by: Sri Vishnu <[email protected]>

PATCH In review Harshini 4 participants 4 messages Sep 10, 2025

lore
Share & tools
lore

Harshini

author
#0 lore raw

PATCH v2 1/1 tree-wide: replace tabs with sapce and align code This patch updates by replacing the tabs with spaces and fixing alignment issues Signed-off-by: Harshini <[email protected]> Signed-off-by: Akshaya S <[email protected]> Signed-off-by: Sri Vishnu <[email protected]>

---
 target/alpha/cpu.h               |   6 +-
 target/i386/cpu.h                | 330 +++++++++----------
 target/i386/svm.h                | 334 +++++++++----------
 target/microblaze/cpu.h          |  20 +-
 tests/tcg/alpha/test-cond.c      |  36 +-
 tests/tcg/arm/hello-arm.c        | 160 ++++-----
 tests/tcg/i386/test-i386-ssse3.c |  92 +++---
 tests/tcg/i386/test-i386.c       |  52 +--
 tests/tcg/mips/hello-mips.c      |  28 +-
 tests/tcg/multiarch/sha1.c       |   5 +-
 tests/tcg/multiarch/test-mmap.c  | 547 ++++++++++++++++---------------
 11 files changed, 805 insertions(+), 805 deletions(-)
target/alpha/cpu.h +3 -3
index 45944e46b5..a037ee9091 100644
@@ -311,9 +311,9 @@ enum {
 };
 
 /* Alpha-specific interrupt pending bits.  */
-#define CPU_INTERRUPT_TIMER	CPU_INTERRUPT_TGT_EXT_0
-#define CPU_INTERRUPT_SMP	CPU_INTERRUPT_TGT_EXT_1
-#define CPU_INTERRUPT_MCHK	CPU_INTERRUPT_TGT_EXT_2
+#define CPU_INTERRUPT_TIMER    CPU_INTERRUPT_TGT_EXT_0
+#define CPU_INTERRUPT_SMP      CPU_INTERRUPT_TGT_EXT_1
+#define CPU_INTERRUPT_MCHK     CPU_INTERRUPT_TGT_EXT_2
 
 /* OSF/1 Page table bits.  */
 enum {
target/i386/cpu.h +165 -165

442 lines not on this page · raw message

target/i386/svm.h +167 -167

395 lines not on this page · raw message

target/microblaze/cpu.h +10 -10
index 3ce28b302f..54047de1e9 100644
@@ -69,15 +69,15 @@ typedef struct CPUArchState CPUMBState;
 #define MSR_CC  (1<<31)
 
 /* Machine State Register (MSR) Fields */
-#define MSR_UM (1<<11) /* User Mode */
+#define MSR_UM         (1<<11) /* User Mode */
 #define MSR_UMS        (1<<12) /* User Mode Save */
-#define MSR_VM (1<<13) /* Virtual Mode */
+#define MSR_VM         (1<<13) /* Virtual Mode */
 #define MSR_VMS        (1<<14) /* Virtual Mode Save */
 
 #define MSR_KERNEL      MSR_EE|MSR_VM
-//#define MSR_USER     MSR_KERNEL|MSR_UM|MSR_IE
+//#define MSR_USER      MSR_KERNEL|MSR_UM|MSR_IE
 #define MSR_KERNEL_VMS  MSR_EE|MSR_VMS
-//#define MSR_USER_VMS MSR_KERNEL_VMS|MSR_UMS|MSR_IE
+//#define MSR_USER_VMS  MSR_KERNEL_VMS|MSR_UMS|MSR_IE
 
 /* Exception State Register (ESR) Fields */
 #define          ESR_DIZ       (1<<11) /* Zone Protection */
@@ -121,9 +121,9 @@ typedef struct CPUArchState CPUMBState;
 #define PVR0_USE_ICACHE_MASK            0x02000000
 #define PVR0_USE_DCACHE_MASK            0x01000000
 #define PVR0_USE_MMU_MASK               0x00800000
-#define PVR0_USE_BTC			0x00400000
+#define PVR0_USE_BTC                    0x00400000
 #define PVR0_ENDI_MASK                  0x00200000
-#define PVR0_FAULT			0x00100000
+#define PVR0_FAULT                      0x00100000
 #define PVR0_VERSION_MASK               0x0000FF00
 #define PVR0_USER1_MASK                 0x000000FF
 #define PVR0_SPROT_MASK                 0x00000001
@@ -270,10 +270,10 @@ struct CPUArchState {
 /* MSR_UM               (1 << 11) */
 /* MSR_VM               (1 << 13) */
 /* ESR_ESS_MASK         [11:5]    -- unwind into iflags for unaligned excp */
-#define D_FLAG		(1 << 12)  /* Bit in ESR.  */
-#define DRTI_FLAG	(1 << 16)
-#define DRTE_FLAG	(1 << 17)
-#define DRTB_FLAG	(1 << 18)
+#define D_FLAG          (1 << 12)  /* Bit in ESR.  */
+#define DRTI_FLAG       (1 << 16)
+#define DRTE_FLAG       (1 << 17)
+#define DRTB_FLAG       (1 << 18)
 
 /* TB dependent CPUMBState.  */
 #define IFLAGS_TB_MASK  (D_FLAG | BIMM_FLAG | IMM_FLAG | \
tests/tcg/alpha/test-cond.c +18 -18
index 3e11c4c105..27be6ac4f9 100644
@@ -2,28 +2,28 @@
 
 #ifdef TEST_CMOV
 
-#define TEST_COND(N) 				\
-int test_##N (long a)				\
-{						\
-  int res = 1;					\
-                                                \
-  asm ("cmov"#N" %1,$31,%0"			\
-       : "+r" (res) : "r" (a));			\
-  return !res;					\
+#define TEST_COND(N)                 \
+int test_##N (long a)                \
+{                                    \
+  int res = 1;                       \
+                                     \
+  asm ("cmov"#N" %1,$31,%0"          \
+       : "+r" (res) : "r" (a));      \
+  return !res;                       \
 }
 
 #else
 
-#define TEST_COND(N) 				\
-int test_##N (long a)				\
-{						\
-  int res = 1;					\
-                                                \
-  asm ("b"#N" %1,1f\n\t"			\
-       "addq $31,$31,%0\n\t"			\
-       "1: unop\n"				\
-       : "+r" (res) : "r" (a));			\
-  return res;					\
+#define TEST_COND(N)                 \
+int test_##N (long a)                \
+{                                    \
+  int res = 1;                       \
+                                     \
+  asm ("b"#N" %1,1f\n\t"             \
+       "addq $31,$31,%0\n\t"         \
+       "1: unop\n"                   \
+       : "+r" (res) : "r" (a));      \
+  return res;                        \
 }
 
 #endif
tests/tcg/arm/hello-arm.c +80 -80

184 lines not on this page · raw message

tests/tcg/i386/test-i386-ssse3.c +46 -46

100 lines not on this page · raw message

tests/tcg/i386/test-i386.c +26 -26

90 lines not on this page · raw message

tests/tcg/mips/hello-mips.c +14 -14
index 38e22d00e3..6aa5e07b8a 100644
@@ -9,20 +9,20 @@
 *                  -mabi=32 -O2 -static -o hello-mips hello-mips.c
 *
 */
-#define __NR_SYSCALL_BASE	4000
-#define __NR_exit			(__NR_SYSCALL_BASE+  1)
-#define __NR_write			(__NR_SYSCALL_BASE+  4)
+#define __NR_SYSCALL_BASE    4000
+#define __NR_exit            (__NR_SYSCALL_BASE+  1)
+#define __NR_write           (__NR_SYSCALL_BASE+  4)
 
 static inline void exit1(int status)
 {
     register unsigned long __a0 asm("$4") = (unsigned long) status;
 
     __asm__ __volatile__ (
-        "	.set push	\n"
-        "	.set noreorder	\n"
-        "	li	$2, %0	\n"
-        "	syscall		\n"
-        "	.set pop	"
+        "    .set push      \n"
+        "    .set noreorder \n"
+        "    li    $2, %0   \n"
+        "    syscall        \n"
+        "    .set pop    "
         :
         : "i" (__NR_exit), "r" (__a0)
         : "$2", "$8", "$9", "$10", "$11", "$12", "$13", "$14", "$15", "$24",
@@ -38,12 +38,12 @@ static inline int write(int fd, const char *buf, int len)
     unsigned long __v0;
 
     __asm__ __volatile__ (
-        "	.set push	\n"
-        "	.set noreorder	\n"
-        "	li	$2, %2	\n"
-        "	syscall		\n"
-        "	move	%0, $2	\n"
-        "	.set pop	"
+        "    .set push      \n"
+        "    .set noreorder \n"
+        "    li    $2, %2   \n"
+        "    syscall        \n"
+        "    move    %0, $2 \n"
+        "    .set pop    "
         : "=r" (__v0), "=r" (__a3)
         : "i" (__NR_write), "r" (__a0), "r" (__a1), "r" (__a2)
         : "$2", "$8", "$9", "$10", "$11", "$12", "$13", "$14", "$15", "$24",
tests/tcg/multiarch/sha1.c +2 -3
index 0081bd7657..7d22423b7e 100644
@@ -175,7 +175,7 @@ unsigned i;
 unsigned char finalcount[8];
 unsigned char c;
 
-#if 0	/* untested "improvement" by DHR */
+#if 0    /* untested "improvement" by DHR */
     /* Convert context->count to a sequence of bytes
      * in finalcount.  Second element first, but
      * big-endian order within element.
@@ -216,8 +216,7 @@ unsigned char c;
 
 #define BUFSIZE 4096
 
-int
-main(int argc, char **argv)
+int main(int argc, char **argv)
 {
     SHA1_CTX ctx;
     unsigned char hash[20], buf[BUFSIZE];
tests/tcg/multiarch/test-mmap.c +274 -273

604 lines not on this page · raw message

Signature · 1 line
2.43.0
#1 lore raw

Please don't. For the countless number of times.
This changes authorship of code while actual code
has not changed.

Thanks,

/mjt

#2 lore raw
Quoted 3 lines · Michael Tokarev

Please don't. For the countless number of times.
This changes authorship of code while actual code
has not changed.

FWIW, we can workaround that by adding to .git-blame-ignore-revs, but bulk re-formatting across multiple subsystems is not so nice regardless.

With regards,
Daniel

Signature · 3 lines
|: https://berrange.com      -o-    https://www.flickr.com/photos/dberrange :|
|: https://libvirt.org         -o-            https://fstop138.berrange.com :|
|: https://entangle-photo.org    -o-    https://www.instagram.com/dberrange :|
#3 lore raw
In reply to Harshini
Quoted 15 lines · Harshini
---
 target/alpha/cpu.h               |   6 +-
 target/i386/cpu.h                | 330 +++++++++----------
 target/i386/svm.h                | 334 +++++++++----------
 target/microblaze/cpu.h          |  20 +-
 tests/tcg/alpha/test-cond.c      |  36 +-
 tests/tcg/arm/hello-arm.c        | 160 ++++-----
 tests/tcg/i386/test-i386-ssse3.c |  92 +++---
 tests/tcg/i386/test-i386.c       |  52 +--
 tests/tcg/mips/hello-mips.c      |  28 +-
 tests/tcg/multiarch/sha1.c       |   5 +-
 tests/tcg/multiarch/test-mmap.c  | 547 ++++++++++++++++---------------
 11 files changed, 805 insertions(+), 805 deletions(-)

Please don't try to do this kind of thing as a single massive tree-wide patch: it makes it unreviewable. More generally, we usually don't try to fix up coding style or formatting in older code unless we're touching that area of the code anyway.

thanks
-- PMM