From 425f3740cf8e93fac6318ed862bcc3081b818f0b Mon Sep 17 00:00:00 2001 From: Alan Date: Mon, 28 Apr 2014 20:47:36 +0100 Subject: goldfish: Add a 64bit write helper The base code imported from the Google tree is ifdef heaven. Prepare to fix this by adding a helper function. Signed-off-by: Alan Cox Signed-off-by: Greg Kroah-Hartman --- include/linux/goldfish.h | 15 +++++++++++++++ 1 file changed, 15 insertions(+) create mode 100644 include/linux/goldfish.h (limited to 'include/linux/goldfish.h') diff --git a/include/linux/goldfish.h b/include/linux/goldfish.h new file mode 100644 index 000000000000..9cc28902b54c --- /dev/null +++ b/include/linux/goldfish.h @@ -0,0 +1,15 @@ +#ifndef __LINUX_GOLDFISH_H +#define __LINUX_GOLDFISH_H + +/* Helpers for Goldfish virtual platform */ + +static inline void gf_write64(unsigned long data, + void __iomem *portl, void __iomem *porth) +{ + writel((u32)data, portl); +#ifdef CONFIG_ARCH_DMA_ADDR_T_64BIT + writel(data>>32, porth); +#endif +} + +#endif /* __LINUX_GOLDFISH_H */ -- cgit