]> git.ipfire.org Git - thirdparty/u-boot.git/blame - arch/arm/mach-bcm283x/phys2bus.c
SPDX: Convert all of our single license tags to Linux Kernel style
[thirdparty/u-boot.git] / arch / arm / mach-bcm283x / phys2bus.c
CommitLineData
83d290c5 1// SPDX-License-Identifier: GPL-2.0+
79340db7
SW
2/*
3 * Copyright 2015 Stephen Warren
79340db7
SW
4 */
5
6#include <config.h>
7#include <phys2bus.h>
8
9unsigned long phys_to_bus(unsigned long phys)
10{
ed7481c7 11#ifndef CONFIG_BCM2835
79340db7
SW
12 return 0xc0000000 | phys;
13#else
14 return 0x40000000 | phys;
15#endif
16}
17
18unsigned long bus_to_phys(unsigned long bus)
19{
20 return bus & ~0xc0000000;
21}