]> err.no Git - linux-2.6/commitdiff
parse errors in ifdefs
authorYoann Padioleau <padator@wanadoo.fr>
Fri, 1 Jun 2007 07:46:36 +0000 (00:46 -0700)
committerLinus Torvalds <torvalds@woody.linux-foundation.org>
Fri, 1 Jun 2007 15:18:28 +0000 (08:18 -0700)
Fix various bits of obviously-busted code which we're not happening to
compile, due to ifdefs.

Cc: "Luck, Tony" <tony.luck@intel.com>
Cc: Ivan Kokshaysky <ink@jurassic.park.msu.ru>
Cc: Richard Henderson <rth@twiddle.net>
Cc: Russell King <rmk@arm.linux.org.uk>
Cc: Ralf Baechle <ralf@linux-mips.org>
Cc: Jeff Garzik <jeff@garzik.org>
Cc: Jan Kara <jack@ucw.cz>
Cc: James Bottomley <James.Bottomley@steeleye.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Documentation/ia64/aliasing-test.c
arch/alpha/boot/tools/mkbb.c
arch/arm/mm/alignment.c
arch/mips/jmr3927/rbhma3100/kgdb_io.c
arch/mips/pci/pci-ocelot.c
drivers/mtd/nand/ppchameleonevb.c
drivers/net/fec_8xx/fec_main.c
drivers/scsi/NCR5380.c
fs/udf/super.c

index 3153167b41c3c39b999822df7f283aa1dd686d9e..d485256ee1cead1c71b20610c0db3e458cbd10db 100644 (file)
@@ -197,7 +197,7 @@ skip:
        return rc;
 }
 
-main()
+int main()
 {
        int rc;
 
index 23c7190b047c2d716303d1beefa69342280c5a43..632a7fd6d7dcfeb42efd837e8188d55b5ebd933d 100644 (file)
@@ -81,7 +81,7 @@ typedef union __bootblock {
 #define        bootblock_label         __u1.__label
 #define bootblock_checksum     __u2.__checksum
 
-main(int argc, char ** argv)
+int main(int argc, char ** argv)
 {
     bootblock          bootblock_from_disk;
     bootblock          bootloader_image;
index 36440c899583b9131143e9fc30a54fb8b9be70ab..074b7cb0774349d6a51e7c4d210e472a892c4e01 100644 (file)
@@ -630,7 +630,7 @@ do_alignment(unsigned long addr, unsigned int fsr, struct pt_regs *regs)
 
        fs = get_fs();
        set_fs(KERNEL_DS);
-       if thumb_mode(regs) {
+       if (thumb_mode(regs)) {
                fault = __get_user(tinstr, (u16 *)(instrptr & ~1));
                if (!(fault))
                        instr = thumb2arm(tinstr);
index 2604f2c9a96e0c89359553ec747e25a65d78da89..342579cfdc01d3b37ca739b96c862753734cc202 100644 (file)
@@ -36,7 +36,7 @@
 #define TIMEOUT       0xffffff
 
 static int remoteDebugInitialized = 0;
-static void debugInit(int baud)
+static void debugInit(int baud);
 
 int putDebugChar(unsigned char c)
 {
index 7f94f26d35ae054abc028298e6aacc77321486c1..1421d34535efecf29475c631492010480feb4942 100644 (file)
@@ -71,19 +71,19 @@ static inline void pci0WriteConfigReg(unsigned int offset, unsigned int data)
 }
 
 static struct resource ocelot_mem_resource = {
-       start   = GT_PCI_MEM_BASE;
-       end     = GT_PCI_MEM_BASE + GT_PCI_MEM_BASE - 1;
+       .start  = GT_PCI_MEM_BASE,
+       .end    = GT_PCI_MEM_BASE + GT_PCI_MEM_BASE - 1,
 };
 
 static struct resource ocelot_io_resource = {
-       start   = GT_PCI_IO_BASE;
-       end     = GT_PCI_IO_BASE + GT_PCI_IO_SIZE - 1;
+       .start  = GT_PCI_IO_BASE,
+       .end    = GT_PCI_IO_BASE + GT_PCI_IO_SIZE - 1,
 };
 
 static struct pci_controller ocelot_pci_controller = {
-       .pci_ops        = gt64xxx_pci0_ops;
-       .mem_resource   = &ocelot_mem_resource;
-       .io_resource    = &ocelot_io_resource;
+       .pci_ops        = gt64xxx_pci0_ops,
+       .mem_resource   = &ocelot_mem_resource,
+       .io_resource    = &ocelot_io_resource,
 };
 
 static int __init ocelot_pcibios_init(void)
index 38fe9e998ee571e604eaedef3b514085a64afcd1..082073acf20fc51b6a252623bca2d7cc59ba456b 100644 (file)
@@ -424,9 +424,9 @@ static void __exit ppchameleonevb_cleanup(void)
 
        /* Release iomaps */
        this = (struct nand_chip *) &ppchameleon_mtd[1];
-       iounmap((void *) this->IO_ADDR_R;
+       iounmap((void *) this->IO_ADDR_R);
        this = (struct nand_chip *) &ppchameleonevb_mtd[1];
-       iounmap((void *) this->IO_ADDR_R;
+       iounmap((void *) this->IO_ADDR_R);
 
        /* Free the MTD device structure */
        kfree (ppchameleon_mtd);
index 88efe9731babe983d6cc76983c3a93a5173498d5..e5502af5b8e21a2bf7e3cef3aa13b6e1f1f9c69b 100644 (file)
@@ -550,7 +550,7 @@ static int fec_enet_rx_common(struct net_device *dev, int *budget)
                                skbn = dev_alloc_skb(pkt_len + 2);
                                if (skbn != NULL) {
                                        skb_reserve(skbn, 2);   /* align IP header */
-                                       skb_copy_from_linear_data(skb
+                                       skb_copy_from_linear_data(skb,
                                                                  skbn->data,
                                                                  pkt_len);
                                        /* swap */
index bb3cb33605417aa3f4b23dd4dc6216b744ebc2ad..88ea5a1fb606d8b8bb7c91c7c9bb2a4721e43bd9 100644 (file)
@@ -2625,7 +2625,7 @@ static void NCR5380_reselect(struct Scsi_Host *instance) {
 #ifdef REAL_DMA
 static void NCR5380_dma_complete(NCR5380_instance * instance) {
        NCR5380_local_declare();
-       struct NCR5380_hostdata *hostdata = (struct NCR5380_hostdata * instance->hostdata);
+       struct NCR5380_hostdata *hostdata = (struct NCR5380_hostdata *) instance->hostdata;
        int transferred;
        NCR5380_setup(instance);
 
index 3a743d854c17bf9408b8114d0b44ead19fe18b1e..6658afb41cc7564ffeced0d42e0b35b0421baf0e 100644 (file)
@@ -1351,7 +1351,7 @@ udf_load_partition(struct super_block *sb, kernel_lb_addr *fileset)
 
        for (i=0; i<UDF_SB_NUMPARTS(sb); i++)
        {
-               switch UDF_SB_PARTTYPE(sb, i)
+               switch (UDF_SB_PARTTYPE(sb, i))
                {
                        case UDF_VIRTUAL_MAP15:
                        case UDF_VIRTUAL_MAP20: