lkml.org 
[lkml]   [2004]   [Oct]   [20]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    Patch in this message
    /
    Date
    From
    Subject[patch] 2.6.9-rc4-mm1: compile error with BLK_DEV_IDEDMA=n
    On Mon, Oct 11, 2004 at 03:25:02AM -0700, Andrew Morton wrote:
    >...
    > All 741 patches
    >...
    > bk-ide-dev.patch
    >...


    This patch causes the following compile error with
    CONFIG_BLK_DEV_IDEDMA=n:


    <-- snip -->

    ...
    CC drivers/ide/ide-lib.o
    drivers/ide/ide-lib.c: In function `ide_use_dma':
    drivers/ide/ide-lib.c:78: warning: implicit declaration of function `__ide_dma_bad_drive'
    drivers/ide/ide-lib.c:96: warning: implicit declaration of function `__ide_dma_good_drive'
    ...
    LD .tmp_vmlinux1
    drivers/built-in.o(.text+0x26c4bf): In function `ide_use_dma':
    : undefined reference to `__ide_dma_bad_drive'
    drivers/built-in.o(.text+0x26c50c): In function `ide_use_dma':
    : undefined reference to `__ide_dma_good_drive'
    make: *** [.tmp_vmlinux1] Error 1

    <-- snip -->


    The following patch fixes this problem:


    Signed-off-by: Adrian Bunk <bunk@stusta.de>

    --- linux-2.6.9-rc4-mm1/include/linux/ide.h 2004-10-20 13:29:37.000000000 +0200
    +++ linux-2.6.9-rc4-mm1-full/include/linux/ide.h 2004-10-20 13:26:54.000000000 +0200
    @@ -1534,8 +1534,13 @@
    hwif->hwif_data = data;
    }

    +
    /* ide-lib.c */
    +
    +#ifdef CONFIG_BLK_DEV_IDEDMA
    int ide_use_dma(ide_drive_t *);
    +#endif
    +
    extern u8 ide_dma_speed(ide_drive_t *drive, u8 mode);
    extern u8 ide_rate_filter(u8 mode, u8 speed);
    extern int ide_dma_enable(ide_drive_t *drive);
    --- linux-2.6.9-rc4-mm1-full/drivers/ide/ide-lib.c.old 2004-10-20 02:02:13.000000000 +0200
    +++ linux-2.6.9-rc4-mm1-full/drivers/ide/ide-lib.c 2004-10-20 13:26:20.000000000 +0200
    @@ -69,6 +69,7 @@

    EXPORT_SYMBOL(ide_xfer_verbose);

    +#ifdef CONFIG_BLK_DEV_IDEDMA
    int ide_use_dma(ide_drive_t *drive)
    {
    struct hd_driveid *id = drive->id;
    @@ -100,6 +101,7 @@
    }

    EXPORT_SYMBOL_GPL(ide_use_dma);
    +#endif /* CONFIG_BLK_DEV_IDEDMA */

    /**
    * ide_dma_speed - compute DMA speed

    -
    To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
    the body of a message to majordomo@vger.kernel.org
    More majordomo info at http://vger.kernel.org/majordomo-info.html
    Please read the FAQ at http://www.tux.org/lkml/

    \
     
     \ /
      Last update: 2005-03-22 14:07    [W:5.048 / U:0.768 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site