| .. | .. |
|---|
| 1 | +/* SPDX-License-Identifier: GPL-2.0-or-later */ |
|---|
| 1 | 2 | /* |
|---|
| 2 | 3 | * OpenRISC Linux |
|---|
| 3 | 4 | * |
|---|
| .. | .. |
|---|
| 8 | 9 | * OpenRISC implementation: |
|---|
| 9 | 10 | * Copyright (C) 2010-2011 Jonas Bonn <jonas@southpole.se> |
|---|
| 10 | 11 | * et al. |
|---|
| 11 | | - * |
|---|
| 12 | | - * This program is free software; you can redistribute it and/or modify |
|---|
| 13 | | - * it under the terms of the GNU General Public License as published by |
|---|
| 14 | | - * the Free Software Foundation; either version 2 of the License, or |
|---|
| 15 | | - * (at your option) any later version. |
|---|
| 16 | 12 | */ |
|---|
| 17 | 13 | |
|---|
| 18 | 14 | #ifndef __ASM_OPENRISC_IO_H |
|---|
| 19 | 15 | #define __ASM_OPENRISC_IO_H |
|---|
| 16 | + |
|---|
| 17 | +#include <linux/types.h> |
|---|
| 20 | 18 | |
|---|
| 21 | 19 | /* |
|---|
| 22 | 20 | * PCI: can we really do 0 here if we have no port IO? |
|---|
| .. | .. |
|---|
| 29 | 27 | #define PIO_OFFSET 0 |
|---|
| 30 | 28 | #define PIO_MASK 0 |
|---|
| 31 | 29 | |
|---|
| 32 | | -#define ioremap_nocache ioremap_nocache |
|---|
| 33 | | -#include <asm-generic/io.h> |
|---|
| 34 | | -#include <asm/pgtable.h> |
|---|
| 30 | +#define ioremap ioremap |
|---|
| 31 | +void __iomem *ioremap(phys_addr_t offset, unsigned long size); |
|---|
| 35 | 32 | |
|---|
| 36 | | -extern void __iomem *__ioremap(phys_addr_t offset, unsigned long size, |
|---|
| 37 | | - pgprot_t prot); |
|---|
| 38 | | - |
|---|
| 39 | | -static inline void __iomem *ioremap(phys_addr_t offset, size_t size) |
|---|
| 40 | | -{ |
|---|
| 41 | | - return __ioremap(offset, size, PAGE_KERNEL); |
|---|
| 42 | | -} |
|---|
| 43 | | - |
|---|
| 44 | | -/* #define _PAGE_CI 0x002 */ |
|---|
| 45 | | -static inline void __iomem *ioremap_nocache(phys_addr_t offset, |
|---|
| 46 | | - unsigned long size) |
|---|
| 47 | | -{ |
|---|
| 48 | | - return __ioremap(offset, size, |
|---|
| 49 | | - __pgprot(pgprot_val(PAGE_KERNEL) | _PAGE_CI)); |
|---|
| 50 | | -} |
|---|
| 51 | | - |
|---|
| 33 | +#define iounmap iounmap |
|---|
| 52 | 34 | extern void iounmap(void *addr); |
|---|
| 35 | + |
|---|
| 36 | +#include <asm-generic/io.h> |
|---|
| 37 | + |
|---|
| 53 | 38 | #endif |
|---|