[PATCH] ARM: <asm/floppy.h>: fix build with sparse IRQs

Ethan Nelson-Moore enelsonmoore at gmail.com
Sat May 9 20:23:51 PDT 2026


If sparse IRQs are enabled, <mach/irqs.h> is no longer implicitly
included when building the floppy driver. This causes the build to fail
because IRQ_FLOPPYDISK, which is used by <asm/floppy.h>, is no longer
defined. Fix this issue by including <mach/irqs.h> from <asm/floppy.h>.
The only machines that select ARCH_MAY_HAVE_PC_FDC (and thus use
<asm/floppy.h>) are footbridge and rpc, both of which have
<mach/irqs.h>.

Signed-off-by: Ethan Nelson-Moore <enelsonmoore at gmail.com>
---
 arch/arm/include/asm/floppy.h | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/arch/arm/include/asm/floppy.h b/arch/arm/include/asm/floppy.h
index e579f77162e9..4fdc3f633b1e 100644
--- a/arch/arm/include/asm/floppy.h
+++ b/arch/arm/include/asm/floppy.h
@@ -6,6 +6,9 @@
  *
  *  Note that we don't touch FLOPPY_DMA nor FLOPPY_IRQ here
  */
+
+#include <mach/irqs.h> /* for IRQ_FLOPPYDISK */
+
 #ifndef __ASM_ARM_FLOPPY_H
 #define __ASM_ARM_FLOPPY_H
 
-- 
2.43.0




More information about the linux-arm-kernel mailing list