Hello Julius Werner,
I'd like you to do a code review. Please visit
https://review.coreboot.org/c/coreboot/+/38536
to review the following change.
Change subject: libpayload/corebootfb: Fix character buffer relocation
......................................................................
libpayload/corebootfb: Fix character buffer relocation
The `chars` pointer references the heap which is part of the payload
and relocated along with it. So calling phys_to_virt() on it was
always wrong; and the virt_to_phys() at its initialization was a
no-op anyway, when the console was brought up before relocation.
While we are at it, add a null-pointer check.
Change-Id: Ic03150f0bcd14a6ec6bf514dffe2b9153d5a6d2a
Signed-off-by: Nico Huber <nico.huber(a)secunet.com>
---
M payloads/libpayload/drivers/video/corebootfb.c
1 file changed, 6 insertions(+), 5 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/36/38536/1
diff --git a/payloads/libpayload/drivers/video/corebootfb.c b/payloads/libpayload/drivers/video/corebootfb.c
index b5ad1a5..11397ba 100644
--- a/payloads/libpayload/drivers/video/corebootfb.c
+++ b/payloads/libpayload/drivers/video/corebootfb.c
@@ -64,11 +64,11 @@
/* Addresses for the various components */
static unsigned long fbinfo;
static unsigned long fbaddr;
-static unsigned long chars;
+static unsigned short *chars;
#define FI ((struct cb_framebuffer *) phys_to_virt(fbinfo))
#define FB ((unsigned char *) phys_to_virt(fbaddr))
-#define CHARS ((unsigned short *) phys_to_virt(chars))
+#define CHARS (chars)
static void corebootfb_scroll_up(void)
{
@@ -243,9 +243,10 @@
coreboot_video_console.columns = FI->x_resolution / font_width;
coreboot_video_console.rows = FI->y_resolution / font_height;
- /* See setting of fbinfo above. */
- chars = virt_to_phys(malloc(coreboot_video_console.rows *
- coreboot_video_console.columns * 2));
+ chars = malloc(coreboot_video_console.rows *
+ coreboot_video_console.columns * 2);
+ if (!chars)
+ return -1;
// clear boot splash screen if there is one.
corebootfb_clear();
--
To view, visit https://review.coreboot.org/c/coreboot/+/38536
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-Change-Id: Ic03150f0bcd14a6ec6bf514dffe2b9153d5a6d2a
Gerrit-Change-Number: 38536
Gerrit-PatchSet: 1
Gerrit-Owner: Nico Huber <nico.h(a)gmx.de>
Gerrit-Reviewer: Julius Werner <jwerner(a)chromium.org>
Gerrit-MessageType: newchange
John Su has uploaded this change for review. ( https://review.coreboot.org/c/coreboot/+/38811 )
Change subject: mb/google/drallion: Set baseline config for U42 and U62 CPU
......................................................................
mb/google/drallion: Set baseline config for U42 and U62 CPU
VR settings will be selected by CPU SKU.
Change-Id: Ie471dee0c70e1831a822860c0a44455772a2b8be
Signed-off-by: John Su <john_su(a)compal.corp-partner.google.com>
---
M src/mainboard/google/drallion/variants/drallion/devicetree.cb
1 file changed, 3 insertions(+), 0 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/11/38811/1
diff --git a/src/mainboard/google/drallion/variants/drallion/devicetree.cb b/src/mainboard/google/drallion/variants/drallion/devicetree.cb
index 06d3e5d..489b383 100644
--- a/src/mainboard/google/drallion/variants/drallion/devicetree.cb
+++ b/src/mainboard/google/drallion/variants/drallion/devicetree.cb
@@ -65,6 +65,9 @@
register "PchHdaIDispCodecDisconnect" = "1"
register "PchHdaAudioLinkHda" = "1"
+ # Select CPU PL2/PL4 config
+ register "cpu_pl2_4_cfg" = "baseline"
+
# VR Settings Configuration for 2/4 Domains
#+----------------+-------+-------+-------+-------+
#| Domain/Setting | SA | IA | GTUS | GTS |
--
To view, visit https://review.coreboot.org/c/coreboot/+/38811
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-Change-Id: Ie471dee0c70e1831a822860c0a44455772a2b8be
Gerrit-Change-Number: 38811
Gerrit-PatchSet: 1
Gerrit-Owner: John Su <john_su(a)compal.corp-partner.google.com>
Gerrit-MessageType: newchange