Move C labels to start-of-line
authorPatrick Georgi <patrick@georgi-clan.de>
Wed, 7 Mar 2012 14:55:47 +0000 (15:55 +0100)
committerStefan Reinauer <stefan.reinauer@coreboot.org>
Wed, 7 Mar 2012 16:48:03 +0000 (17:48 +0100)
Also mark the corresponding lint test stable.

Change-Id: Ib7c9ed88c5254bf56e68c01cdbd5ab91cd7bfc2f
Signed-off-by: Patrick Georgi <patrick@georgi-clan.de>
Reviewed-on: http://review.coreboot.org/772
Tested-by: build bot (Jenkins)
Reviewed-by: Stefan Reinauer <stefan.reinauer@coreboot.org>
18 files changed:
src/arch/x86/boot/mpspec.c
src/arch/x86/lib/cpu.c
src/boot/selfboot.c
src/console/vtxprintf.c
src/cpu/x86/lapic/secondary.S
src/devices/oprom/yabel/pmm.c
src/lib/xmodem.c
src/northbridge/amd/amdk8/raminit.c
src/northbridge/amd/amdk8/raminit_f.c
src/northbridge/amd/amdk8/raminit_test.c
src/northbridge/intel/e7520/raminit.c
src/northbridge/intel/e7525/raminit.c
src/northbridge/intel/i3100/raminit.c
src/northbridge/intel/i3100/raminit_ep80579.c
src/northbridge/intel/i945/raminit.c
src/southbridge/amd/cs5536/early_smbus.c
util/lint/lint-004-style-labels [deleted file]
util/lint/lint-stable-004-style-labels [new file with mode: 0755]

index d519cfaacc26422e00382aeaff9224ac62f9e19c..e7d767b7ac61a156fbfb4d26bebc943e72955a81 100644 (file)
@@ -267,7 +267,7 @@ void smp_write_intsrc_pci_bridge(struct mp_config_table *mc,
                                smp_write_intsrc_pci_bridge(mc, irqtype, irqflag, child, dstapic, dstirq_x);
                        }
 
-               next:
+next:
                        child = child->sibling;
                }
 
index 8aacaac1962f107a0de6a9a990e08c28365be7d4..a7f7b322c003f8b0fff26d1a417b67d7da6348fb 100644 (file)
@@ -227,7 +227,7 @@ static void set_cpu_ops(struct device *cpu)
                }
        }
        return;
- found:
+found:
        cpu->ops = driver->ops;
 }
 
index c45fa636522bf6c1085bfc8096a249b02f07a79b..99b1493ed7c39d0d6ed3db78a7845bb6bf41ed5c 100644 (file)
@@ -511,7 +511,7 @@ static int selfboot(struct lb_memory *mem, struct cbfs_payload *payload)
        jmp_to_elf_entry((void*)entry, bounce_buffer, bounce_size);
        return 1;
 
- out:
+out:
        return 0;
 }
 
index 944fd5b96f348f9cf14d2065ff8730da04dae1ed..405302311d6d6a6c85ca6692ea3fbdbf7f61f827 100644 (file)
@@ -123,7 +123,7 @@ int vtxprintf(void (*tx_byte)(unsigned char byte), const char *fmt, va_list args
 
                /* process flags */
                flags = 0;
-               repeat:
+repeat:
                        ++fmt;          /* this also skips first '%' */
                        switch (*fmt) {
                                case '-': flags |= LEFT; goto repeat;
index 5c1e7607e8ff06437cb61313e3898195aecf2fdf..dc00b082e9f571b3af3831f58e273bf138593c17 100644 (file)
@@ -47,7 +47,7 @@ _secondary_start:
 1:     hlt
        jmp     1b
 
-       gdtaddr:
+gdtaddr:
        .word   gdt_limit       /* the table limit */
        .long   gdt             /* we know the offset */
 
index 989bde4d278eca03a612d6186f07dff17ceb0815..19d14d46b6c3bd6cb6000dce8a595dc6761d5183 100644 (file)
@@ -267,7 +267,7 @@ void pmm_handleInt()
                rval = 0xFFFFFFFF;
                goto exit;
        }
-      exit:
+exit:
        /* exit handler of this function, restore registers, put return value in DX:AX */
        M.x86 = backup_regs;
        M.x86.R_DX = (u16) ((rval >> 16) & 0xFFFF);
index 2d553bed03a7a27016c357d5b53bf08ee44e046d..a00653a7311779b812762fb5378e34f5bf5b5166 100644 (file)
@@ -166,7 +166,7 @@ int xmodemReceive(unsigned char *dest, int destsz)
                        _outbyte(ACK);
                        continue;
                }
-       reject:
+reject:
                flushinput();
                _outbyte(NAK);
        }
index eb33a3974562879a81bcdf23f35a65cd575c064a..9cb7c60004b7d1eddefab539af5c68b695c8ec5b 100644 (file)
@@ -681,7 +681,7 @@ hw_err:
 #if CONFIG_QRANK_DIMM_SUPPORT
        sz.rank = 0;
 #endif
- out:
+out:
        return sz;
 }
 
index dc3addbe87e505b02aa6ae393fa3bc28ab85af2c..33df485c8c7b255acf4553189a2ab3937b6e39a2 100644 (file)
@@ -49,7 +49,7 @@
        /* for PCI_ADDR(0, 0x18, 2, 0x98) index,
         and PCI_ADDR(0x, 0x18, 2, 0x9c) data */
        /*
-               index:
+index:
                [29: 0] DctOffset (Dram Controller Offset)
                [30:30] DctAccessWrite (Dram Controller Read/Write Select)
                        0 = read access
@@ -659,7 +659,7 @@ static void sdram_set_registers(const struct mem_controller *ctrl, struct sys_in
        /* for PCI_ADDR(0, 0x18, 2, 0x98) index,
         and PCI_ADDR(0x, 0x18, 2, 0x9c) data */
        /*
-               index:
+index:
                [29: 0] DctOffset (Dram Controller Offset)
                [30:30] DctAccessWrite (Dram Controller Read/Write Select)
                        0 = read access
@@ -820,7 +820,7 @@ static void spd_get_dimm_size(unsigned device, struct dimm_size *sz)
        sz->col = 0;
        sz->bank = 0;
        sz->rank = 0;
- out:
+out:
        return;
 }
 
index e2a13a3c6d0b5aae2add5e05e3546f6b81552473..fd2107cce91fdcd45c2f626b23fdcbe0b438e94b 100644 (file)
@@ -419,7 +419,7 @@ static void do_test2(int i)
 
        raminit_main();
 
- done:
+done:
        memcpy(&end_buf, &tmp_buf, sizeof(end_buf));
 }
 
index e9a60f1e20c7df1768ccdc182c32c430a49c600a..d226085d0d834cb86ad47c571f323b3ee95f169b 100644 (file)
@@ -161,7 +161,7 @@ static struct dimm_size spd_get_dimm_size(unsigned device)
 hw_err:
        sz.side1 = 0;
        sz.side2 = 0;
- out:
+out:
        return sz;
 
 }
@@ -286,7 +286,7 @@ static int spd_set_row_attributes(const struct mem_controller *ctrl,
        /* If an hw_error occurs report that I have no memory */
 hw_err:
        dra = 0;
- out:
+out:
        return dra;
 
 }
@@ -658,7 +658,7 @@ static int spd_set_dram_controller_mode(const struct mem_controller *ctrl,
        /* If an hw_error occurs report that I have no memory */
 hw_err:
        drc = 0;
- out:
+out:
        return drc;
 }
 
index e341596997c40a87df88164de6854be8bea96223..b5895bc64743114824c55fe64e122b53b5257eb6 100644 (file)
@@ -164,7 +164,7 @@ static struct dimm_size spd_get_dimm_size(unsigned device)
 hw_err:
        sz.side1 = 0;
        sz.side2 = 0;
- out:
+out:
        return sz;
 
 }
@@ -291,7 +291,7 @@ static int spd_set_row_attributes(const struct mem_controller *ctrl,
        /* If an hw_error occurs report that I have no memory */
 hw_err:
        dra = 0;
- out:
+out:
        return dra;
 
 }
@@ -664,7 +664,7 @@ static int spd_set_dram_controller_mode(const struct mem_controller *ctrl,
        /* If an hw_error occurs report that I have no memory */
 hw_err:
        drc = 0;
- out:
+out:
        return drc;
 }
 
index ced3de1e22cd407eee90e5f144b2438714e24865..926d5b3afbe3207089dcab1bdeadd9825931af24 100644 (file)
@@ -154,7 +154,7 @@ static struct dimm_size spd_get_dimm_size(u16 device)
  hw_err:
        sz.side1 = 0;
        sz.side2 = 0;
- out:
+out:
        return sz;
 
 }
@@ -281,7 +281,7 @@ static int spd_set_row_attributes(const struct mem_controller *ctrl,
        /* If an hw_error occurs report that I have no memory */
  hw_err:
        dra = 0;
- out:
+out:
        return dra;
 
 }
@@ -597,7 +597,7 @@ static int spd_set_dram_controller_mode(const struct mem_controller *ctrl,
        /* If an hw_error occurs report that I have no memory */
  hw_err:
        drc = 0;
- out:
+out:
        return drc;
 }
 
index de3ffcefa56d03764a08c0f9e5823142e1fece40..79fc5f72e2ab62901939af42505c080605cd99f9 100644 (file)
@@ -126,7 +126,7 @@ static struct dimm_size spd_get_dimm_size(u16 device)
  hw_err:
        sz.side1 = 0;
        sz.side2 = 0;
- out:
+out:
        print_debug("dimm ");
        print_debug_hex8(device);
        print_debug(" size = ");
index d92c00672e4924dedd1d47679aba65fba857ba66..a4512d7ba80743c5d5561fb4d5cffe955399b513 100644 (file)
@@ -1478,7 +1478,7 @@ static struct dimm_size sdram_get_dimm_size(struct sys_info *sysinfo, u16 dimmno
         */
        sz.side1 = 0;
        sz.side2 = 0;
- out:
+out:
        return sz;
 }
 
index 5cb815d2509639b6daef63b311744a81dccd8189..814bc5a1fb1a2081f55db5382344595b85b187a1 100644 (file)
@@ -194,7 +194,7 @@ static unsigned char do_smbus_read_byte(unsigned smbus_io_base,
 
        return smbus_get_result(smbus_io_base);
 
-      err:
+err:
        print_debug("SMBUS READ ERROR:");
        print_debug_hex8(error);
        print_debug(" device:");
diff --git a/util/lint/lint-004-style-labels b/util/lint/lint-004-style-labels
deleted file mode 100755 (executable)
index 31ad74e..0000000
+++ /dev/null
@@ -1,22 +0,0 @@
-#!/bin/sh
-# This file is part of the coreboot project.
-#
-# Copyright (C) 2012 Patrick Georgi <patrick@georgi-clan.de>
-#
-# This program is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; version 2 of the License.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with this program; if not, write to the Free Software
-# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
-#
-# DESCR: Check that C labels begin at start-of-line
-
-LC_ALL=C export LC_ALL
-find src -name '*.[scS]' -exec grep '^[[:space:]][[:space:]]*[a-z][a-z]*:[[:space:]]*$' {} + |grep -v "[^a-z_]default:"
diff --git a/util/lint/lint-stable-004-style-labels b/util/lint/lint-stable-004-style-labels
new file mode 100755 (executable)
index 0000000..31ad74e
--- /dev/null
@@ -0,0 +1,22 @@
+#!/bin/sh
+# This file is part of the coreboot project.
+#
+# Copyright (C) 2012 Patrick Georgi <patrick@georgi-clan.de>
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; version 2 of the License.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
+#
+# DESCR: Check that C labels begin at start-of-line
+
+LC_ALL=C export LC_ALL
+find src -name '*.[scS]' -exec grep '^[[:space:]][[:space:]]*[a-z][a-z]*:[[:space:]]*$' {} + |grep -v "[^a-z_]default:"