Skip to content

Commit

Permalink
asm-generic/io.h: remove asm/cacheflush.h include
Browse files Browse the repository at this point in the history
Including <asm/cacheflush.h> from <asm-generic/io.h> prevents
cacheflush.h being able to use I/O functions like readl and writel due
to circular include dependencies. It doesn't appear as if anything from
cacheflush.h is actually used by the generic io.h, so remove the
include.

I've compile tested a defconfig compilation of blackfin, openrisc (which
needed <asm/pgtable.h> including from it's <asm/io.h> to get the PAGE_*
definitions), and xtensa.

Other architectures which use asm-generic/io.h are score and unicore32,
and looking at their io.h I don't see any obvious problems.

Signed-off-by: James Hogan <james.hogan@imgtec.com>
Acked-by: Jonas Bonn <jonas@southpole.se>
Cc: Chris Zankel <chris@zankel.net>
Cc: Max Filippov <jcmvbkbc@gmail.com>
Cc: Mike Frysinger <vapier@gentoo.org>
Cc: Chen Liqin <liqin.chen@sunplusct.com>
Cc: Lennox Wu <lennox.wu@gmail.com>
Cc: Guan Xuetao <gxt@mprc.pku.edu.cn>
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
  • Loading branch information
James Hogan authored and Arnd Bergmann committed Oct 25, 2012
1 parent 6f0c058 commit 9b04ebd
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 1 deletion.
1 change: 1 addition & 0 deletions arch/openrisc/include/asm/io.h
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@
#define PIO_MASK 0

#include <asm-generic/io.h>
#include <asm/pgtable.h>

extern void __iomem *__ioremap(phys_addr_t offset, unsigned long size,
pgprot_t prot);
Expand Down
1 change: 0 additions & 1 deletion include/asm-generic/io.h
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@
#define __ASM_GENERIC_IO_H

#include <asm/page.h> /* I/O is all done through memory accesses */
#include <asm/cacheflush.h>
#include <linux/types.h>

#ifdef CONFIG_GENERIC_IOMAP
Expand Down

0 comments on commit 9b04ebd

Please sign in to comment.