aboutsummaryrefslogtreecommitdiff
path: root/src/northbridge/intel/pineview/northbridge.c
diff options
context:
space:
mode:
authorAngel Pons <th3fanbus@gmail.com>2020-08-03 15:16:12 +0200
committerAngel Pons <th3fanbus@gmail.com>2020-08-04 21:26:49 +0000
commit69356489fe43ca36f5ed20b7b92dc2cd0641803d (patch)
tree63f2cb44d262215c7a278b97130e69d215070f89 /src/northbridge/intel/pineview/northbridge.c
parent92e4ca6a38a4f4c0cb772b9694e2d20ada254a46 (diff)
nb/intel/pineview: Use `MiB` definition
Also constify a local variable while we're at it. Tested with BUILD_TIMELESS=1, Foxconn D41S does not change. Change-Id: I90ab35932d7c0ba99ca16732b9616f3a15d972dd Signed-off-by: Angel Pons <th3fanbus@gmail.com> Reviewed-on: https://review.coreboot.org/c/coreboot/+/44124 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Arthur Heymans <arthur@aheymans.xyz>
Diffstat (limited to 'src/northbridge/intel/pineview/northbridge.c')
-rw-r--r--src/northbridge/intel/pineview/northbridge.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/northbridge/intel/pineview/northbridge.c b/src/northbridge/intel/pineview/northbridge.c
index 856eab3301..e005bc9dfc 100644
--- a/src/northbridge/intel/pineview/northbridge.c
+++ b/src/northbridge/intel/pineview/northbridge.c
@@ -18,7 +18,7 @@
* 0xc0000 - 0xcffff: VGA OPROM (needed by kernel)
* 0xe0000 - 0xfffff: SeaBIOS, if used, otherwise DMI
*/
-static const int legacy_hole_base_k = 0xa0000 / 1024;
+static const int legacy_hole_base_k = 0xa0000 / KiB;
static void add_fixed_resources(struct device *dev, int index)
{
@@ -33,8 +33,8 @@ static void add_fixed_resources(struct device *dev, int index)
| IORESOURCE_STORED
| IORESOURCE_ASSIGNED;
- mmio_resource(dev, index++, legacy_hole_base_k, (0xc0000 >> 10) - legacy_hole_base_k);
- reserved_ram_resource(dev, index++, 0xc0000 >> 10, (0x100000 - 0xc0000) >> 10);
+ mmio_resource(dev, index++, legacy_hole_base_k, (0xc0000 / KiB) - legacy_hole_base_k);
+ reserved_ram_resource(dev, index++, 0xc0000 / KiB, (0x100000 - 0xc0000) / KiB);
}
static void mch_domain_read_resources(struct device *dev)