From: David S. Miller Date: Mon, 5 Mar 2007 04:36:18 +0000 (-0800) Subject: [SPARC64]: Fix floppy build failure. X-Git-Url: http://drtracing.org/?a=commitdiff_plain;h=78ad0b840848bebe266bcc8f1f9be429d2105264;p=deliverable%2Flinux.git [SPARC64]: Fix floppy build failure. Just define a local {claim,release}_dma_lock() implementation for the floppy driver to use so we don't need to define and export to modules the silly dma_spin_lock. Signed-off-by: David S. Miller --- diff --git a/include/asm-sparc64/dma.h b/include/asm-sparc64/dma.h index 1bf4f7a8fbe1..a9fd06183972 100644 --- a/include/asm-sparc64/dma.h +++ b/include/asm-sparc64/dma.h @@ -15,17 +15,6 @@ #include #include -extern spinlock_t dma_spin_lock; - -#define claim_dma_lock() \ -({ unsigned long flags; \ - spin_lock_irqsave(&dma_spin_lock, flags); \ - flags; \ -}) - -#define release_dma_lock(__flags) \ - spin_unlock_irqrestore(&dma_spin_lock, __flags); - /* These are irrelevant for Sparc DMA, but we leave it in so that * things can compile. */ diff --git a/include/asm-sparc64/floppy.h b/include/asm-sparc64/floppy.h index dbe033e494db..331013a0053e 100644 --- a/include/asm-sparc64/floppy.h +++ b/include/asm-sparc64/floppy.h @@ -854,4 +854,15 @@ static unsigned long __init sun_floppy_init(void) #define EXTRA_FLOPPY_PARAMS +static DEFINE_SPINLOCK(dma_spin_lock); + +#define claim_dma_lock() \ +({ unsigned long flags; \ + spin_lock_irqsave(&dma_spin_lock, flags); \ + flags; \ +}) + +#define release_dma_lock(__flags) \ + spin_unlock_irqrestore(&dma_spin_lock, __flags); + #endif /* !(__ASM_SPARC64_FLOPPY_H) */