Avoid non-portable sed construct
[platform/kernel/u-boot.git] / include / phys2bus.h
1 /*
2  * Copyright 2015 Stephen Warren
3  *
4  * SPDX-License-Identifier:     GPL-2.0+
5  */
6
7 #ifndef _BUS_ADDR_H
8 #define _BUS_ADDR_H
9
10 #ifdef CONFIG_PHYS_TO_BUS
11 unsigned long phys_to_bus(unsigned long phys);
12 unsigned long bus_to_phys(unsigned long bus);
13 #else
14 static inline unsigned long phys_to_bus(unsigned long phys)
15 {
16         return phys;
17 }
18
19 static inline unsigned long bus_to_phys(unsigned long bus)
20 {
21         return bus;
22 }
23 #endif
24
25 #endif