]> pilppa.com Git - linux-2.6-omap-h63xx.git/commitdiff
fix CONFIG_SATA_SIS=y compile error
authorAdrian Bunk <bunk@stusta.de>
Tue, 30 Jan 2007 08:59:17 +0000 (00:59 -0800)
committerJeff Garzik <jeff@garzik.org>
Fri, 9 Feb 2007 22:39:34 +0000 (17:39 -0500)
Static code shouldn't be used from other modules.

drivers/built-in.o: In function `sis_init_one':
sata_sis.c:(.text+0x7634cd): undefined reference to `sis_info133'
sata_sis.c:(.text+0x7634d6): undefined reference to `sis_info133'

While I was at it, I also moved the prototype of this struct to a header
file.

Signed-off-by: Adrian Bunk <bunk@stusta.de>
Cc: Jeff Garzik <jeff@garzik.org>
Cc: Tejun Heo <htejun@gmail.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
drivers/ata/libata.h
drivers/ata/pata_sis.c
drivers/ata/sata_sis.c

index 81ae41d5f23f04a4447c7b40bf7d347d5ef2b30c..94eeb3d3c674b278d271b2fcf9d04cbd55bf1df8 100644 (file)
@@ -136,4 +136,7 @@ extern void ata_qc_schedule_eh(struct ata_queued_cmd *qc);
 /* libata-sff.c */
 extern u8 ata_irq_on(struct ata_port *ap);
 
+/* pata_sis.c */
+extern struct ata_port_info sis_info133;
+
 #endif /* __LIBATA_H__ */
index 6746f3fb0876ba5227c72880e6b564a36d89a964..5e616d3cc870ac15005d930259c54c6a70d90e3c 100644 (file)
@@ -32,6 +32,7 @@
 #include <scsi/scsi_host.h>
 #include <linux/libata.h>
 #include <linux/ata.h>
+#include "libata.h"
 
 #define DRV_NAME       "pata_sis"
 #define DRV_VERSION    "0.4.5"
@@ -781,7 +782,7 @@ static struct ata_port_info sis_info100_early = {
        .pio_mask       = 0x1f, /* pio0-4 */
        .port_ops       = &sis_66_ops,
 };
-static struct ata_port_info sis_info133 = {
+struct ata_port_info sis_info133 = {
        .sht            = &sis_sht,
        .flags          = ATA_FLAG_SLAVE_POSS | ATA_FLAG_SRST,
        .pio_mask       = 0x1f, /* pio0-4 */
index a915822ae63cbaa27a292946db56a79b9e2b0529..af6f42578f59e3b3637fa092821ab80f1c9df90d 100644 (file)
@@ -40,6 +40,7 @@
 #include <linux/device.h>
 #include <scsi/scsi_host.h>
 #include <linux/libata.h>
+#include "libata.h"
 
 #define DRV_NAME       "sata_sis"
 #define DRV_VERSION    "0.7"
@@ -254,9 +255,6 @@ static void sis_scr_write (struct ata_port *ap, unsigned int sc_reg, u32 val)
 
 static int sis_init_one (struct pci_dev *pdev, const struct pci_device_id *ent)
 {
-       /* Provided by the PATA driver */
-       extern struct ata_port_info sis_info133;
-
        static int printed_version;
        struct ata_probe_ent *probe_ent = NULL;
        int rc;