soc/intel/braswell/acpi/lpc.asl: Allocate used ROM size only

Fixed ROM area is allocated.
Reduce the ROM size using CONFIG_COREBOOT_ROMSIZE.

BUG=N/A
TEST=Facebook FBG-1701 booting Embedded Linux

Change-Id: I7a47bf2600f546271c5a65641d29f868ff2748bf
Signed-off-by: Frans Hendriks <fhendriks@eltan.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/31822
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Nico Huber <nico.h@gmx.de>
This commit is contained in:
Frans Hendriks 2019-04-25 11:17:05 +02:00 committed by Patrick Georgi
parent 0d9f4e9277
commit 6665da81ef
1 changed files with 13 additions and 3 deletions

View File

@ -3,7 +3,7 @@
* *
* Copyright (C) 2007-2009 coresystems GmbH * Copyright (C) 2007-2009 coresystems GmbH
* Copyright (C) 2013 Google Inc. * Copyright (C) 2013 Google Inc.
* Copyright (C) 2018 Eltan B.V. * Copyright (C) 2018-2019 Eltan B.V.
* *
* This program is free software; you can redistribute it and/or * This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License as * modify it under the terms of the GNU General Public License as
@ -42,10 +42,20 @@ Device (LPCB)
Device (FWH) /* Firmware Hub */ Device (FWH) /* Firmware Hub */
{ {
Name (_HID, EISAID("INT0800")) Name (_HID, EISAID("INT0800"))
Name (_CRS, ResourceTemplate() Name (RBUF, ResourceTemplate()
{ {
Memory32Fixed(ReadOnly, 0xff000000, 0x01000000) Memory32Fixed(ReadOnly, 0, 0, FBAR)
}) })
Method (_CRS)
{
CreateDwordField (^RBUF, ^FBAR._BAS, FBAS)
CreateDwordField (^RBUF, ^FBAR._LEN, FLEN)
Multiply(CONFIG_COREBOOT_ROMSIZE_KB, 1024, Local0)
Store(Local0, FLEN)
Add(Subtract(0xffffffff, Local0), 1, FBAS)
Return (^RBUF)
}
} }
#if !CONFIG(DISABLE_HPET) #if !CONFIG(DISABLE_HPET)