Merge branch 'x86-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel...
[cris-mirror.git] / include / linux / goldfish.h
blob2835c150c3ff0a89dc8f1a9628f2b3f3f0b0ed42
1 /* SPDX-License-Identifier: GPL-2.0 */
2 #ifndef __LINUX_GOLDFISH_H
3 #define __LINUX_GOLDFISH_H
5 /* Helpers for Goldfish virtual platform */
7 static inline void gf_write_ptr(const void *ptr, void __iomem *portl,
8 void __iomem *porth)
10 writel((u32)(unsigned long)ptr, portl);
11 #ifdef CONFIG_64BIT
12 writel((unsigned long)ptr >> 32, porth);
13 #endif
16 static inline void gf_write_dma_addr(const dma_addr_t addr,
17 void __iomem *portl,
18 void __iomem *porth)
20 writel((u32)addr, portl);
21 #ifdef CONFIG_ARCH_DMA_ADDR_T_64BIT
22 writel(addr >> 32, porth);
23 #endif
27 #endif /* __LINUX_GOLDFISH_H */