From f241410c51de1b2f8d70b80b8be6eff0af92d624 Mon Sep 17 00:00:00 2001 From: nbd Date: Thu, 28 Jun 2007 20:42:21 +0000 Subject: update magicbox target to 2.6.22-rc6, select gcc 4.2.0 as default for this target (4.1.2 segfaults at compile time) git-svn-id: svn://svn.openwrt.org/openwrt/trunk@7762 3c298f89-4303-0410-b956-a3cf2f4a3e73 --- target/linux/magicbox-2.6/files/drivers/ide/ppc/magicbox_ide.c | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'target/linux/magicbox-2.6/files') diff --git a/target/linux/magicbox-2.6/files/drivers/ide/ppc/magicbox_ide.c b/target/linux/magicbox-2.6/files/drivers/ide/ppc/magicbox_ide.c index d1f6d68edb..2e29e8380a 100644 --- a/target/linux/magicbox-2.6/files/drivers/ide/ppc/magicbox_ide.c +++ b/target/linux/magicbox-2.6/files/drivers/ide/ppc/magicbox_ide.c @@ -4,6 +4,7 @@ * GNU General Public License. */ +#include #include #include #include @@ -97,7 +98,11 @@ static void __init ide_magicbox_register(unsigned long addr, memset(&hw, 0, sizeof(hw)); ide_setup_ports(&hw, addr, ide_offsets, caddr + 12, 0, NULL,irq); +#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,22) if (ide_register_hw(&hw, &hwif) != -1) +#else + if (ide_register_hw(&hw, 1, &hwif) != -1) +#endif { printk(KERN_NOTICE "magicbox-ide: Registered IDE-CF driver\n"); hwif->mmio = 2; -- cgit v1.2.3