Christian Walter has uploaded a new patch set (#29) to the change originally created by Frans Hendriks. ( https://review.coreboot.org/c/coreboot/+/23135 )
Change subject: superio: Add ASpeed AST2400
......................................................................
superio: Add ASpeed AST2400
Add support for ASpeed AST2400.
This device uses write twice 0xA5 to enter config mode.
BUG = N/A
TEST = ASRock D1521D4U
Change-Id: I58fce31f0a2483e61e9d31f38ab5a059b8cf4f83
Signed-off-by: Frans Hendriks <fhendriks(a)eltan.com>
Signed-off-by: Felix Singer <migy(a)darmstadt.ccc.de>
---
M src/include/superio/conf_mode.h
M src/superio/Makefile.inc
A src/superio/aspeed/Makefile.inc
A src/superio/aspeed/ast2400/Kconfig
A src/superio/aspeed/ast2400/Makefile.inc
A src/superio/aspeed/ast2400/ast2400.h
A src/superio/aspeed/ast2400/superio.c
A src/superio/aspeed/common/Kconfig
A src/superio/aspeed/common/aspeed.h
A src/superio/aspeed/common/early_serial.c
M src/superio/common/conf_mode.c
11 files changed, 316 insertions(+), 0 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/35/23135/29
--
To view, visit https://review.coreboot.org/c/coreboot/+/23135
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-Change-Id: I58fce31f0a2483e61e9d31f38ab5a059b8cf4f83
Gerrit-Change-Number: 23135
Gerrit-PatchSet: 29
Gerrit-Owner: Frans Hendriks <fhendriks(a)eltan.com>
Gerrit-Reviewer: Christian Walter <christian.walter(a)9elements.com>
Gerrit-Reviewer: Felix Held <felix-coreboot(a)felixheld.de>
Gerrit-Reviewer: Frans Hendriks <fhendriks(a)eltan.com>
Gerrit-Reviewer: Martin Roth <martinroth(a)google.com>
Gerrit-Reviewer: Patrick Georgi <pgeorgi(a)google.com>
Gerrit-Reviewer: Paul Menzel <paulepanter(a)users.sourceforge.net>
Gerrit-Reviewer: Stefan Reinauer <stefan.reinauer(a)coreboot.org>
Gerrit-Reviewer: build bot (Jenkins) <no-reply(a)coreboot.org>
Gerrit-CC: Arthur Heymans <arthur(a)aheymans.xyz>
Gerrit-CC: Felix Singer <felixsinger(a)posteo.net>
Gerrit-CC: Kyösti Mälkki <kyosti.malkki(a)gmail.com>
Gerrit-CC: Matt DeVillier <matt.devillier(a)gmail.com>
Gerrit-CC: Patrick Rudolph <patrick.rudolph(a)9elements.com>
Gerrit-CC: Patrick Rudolph <siro(a)das-labor.org>
Gerrit-CC: Philipp Deppenwiese <zaolin.daisuki(a)gmail.com>
Gerrit-MessageType: newpatchset
Arthur Heymans has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/29662 )
Change subject: {drivers,soc/intel/braswell}: Implement C_ENVIRONMENT_BOOTBLOCK support
......................................................................
Patch Set 28:
(7 comments)
A bit outside the scope of this patch but the romstage codeflow is pretty messy with FSP1.1 with many functions doing nothing but calling the next: car_stage_entry -> romstage_c_entry -> cache_as_ram_stage_main -> romstage_main... It might be good to clean that up too. cpu/intel/car/romstage.c has a clean interface to start from.
https://review.coreboot.org/#/c/29662/28/src/drivers/intel/fsp1_1/include/f…
File src/drivers/intel/fsp1_1/include/fsp/car.h:
https://review.coreboot.org/#/c/29662/28/src/drivers/intel/fsp1_1/include/f…
PS28, Line 38:
: /* Mainboard and SoC initialization prior to console. */
: void car_mainboard_pre_console_init(void);
: void car_soc_pre_console_init(void);
: /* Mainboard and SoC initialization post console initialization. */
: void car_mainboard_post_console_init(void);
: void car_soc_post_console_init(void);
Those are unused now?
https://review.coreboot.org/#/c/29662/28/src/soc/intel/braswell/bootblock/b…
File src/soc/intel/braswell/bootblock/bootblock.c:
https://review.coreboot.org/#/c/29662/28/src/soc/intel/braswell/bootblock/b…
PS28, Line 35:
: void program_base_addresses(void)
Is this called somewhere else? Why not static void?
https://review.coreboot.org/#/c/29662/28/src/soc/intel/braswell/bootblock/b…
PS28, Line 127: setup_mmconfig();
Doing this before programming base addresses would be more logical.
https://review.coreboot.org/#/c/29662/28/src/soc/intel/braswell/bootblock/c…
File src/soc/intel/braswell/bootblock/cache_as_ram.S:
https://review.coreboot.org/#/c/29662/28/src/soc/intel/braswell/bootblock/c…
PS28, Line 19: /*
: * Replacement for cache_as_ram.inc when using the FSP binary. This code
: * locates the FSP binary, initializes the cache as RAM and performs the
: * first stage of initialization. Next this code switches the stack from
: * the cache to RAM and then disables the cache as RAM. Finally this code
: * performs the final stage of initialization.
: */
:
: /* I/O delay between post codes on failure */
: #define LHLT_DELAY 0x50000
: /*
: * Per FSP1.1 specs, following registers are preserved:
: * EBX, EDI, ESI, EBP, MM0, MM1
: *
: * Shift values to release MM2.
: * mm0 -> edi: BIST value
: * mm1 -> mm0: low 32-bits of TSC value
: * mm2 -> mm1: high 32-bits of TSC value
: */
: movd %mm0, %edi
: movd %mm1, %eax
: movd %eax, %mm0
: movd %mm2, %eax
: movd %eax, %mm1
Why is this removed?
https://review.coreboot.org/#/c/29662/28/src/soc/intel/braswell/bootblock/c…
PS28, Line 128: /* Restore the timestamp from bootblock_crt0.S (ebp:mm1) */
Your removed the code that moved the timestamps in ebp:mm1...
https://review.coreboot.org/#/c/29662/28/src/soc/intel/braswell/bootblock/p…
File src/soc/intel/braswell/bootblock/pmc.c:
https://review.coreboot.org/#/c/29662/28/src/soc/intel/braswell/bootblock/p…
PS28, Line 21: tco_disable
Feel free to move it to the bootblock.c file
https://review.coreboot.org/#/c/29662/28/src/soc/intel/braswell/romstage/ca…
File src/soc/intel/braswell/romstage/car_stage_entry.S:
https://review.coreboot.org/#/c/29662/28/src/soc/intel/braswell/romstage/ca…
PS28, Line 21: .global car_stage_entry
: car_stage_entry:
: call romstage_c_entry
:
: movb $0x69, %ah
: jmp .Lhlt
Looks like skylake does this too, but IMO it makes little sense. Just use rename the romstage entry in the C code to car_stage_entry. (maybe in a separate patch for skylake first)
--
To view, visit https://review.coreboot.org/c/coreboot/+/29662
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-Change-Id: Iab48ad72f1514c93f20d70db5ef4fd8fa2383e8c
Gerrit-Change-Number: 29662
Gerrit-PatchSet: 28
Gerrit-Owner: Frans Hendriks <fhendriks(a)eltan.com>
Gerrit-Reviewer: Arthur Heymans <arthur(a)aheymans.xyz>
Gerrit-Reviewer: Frans Hendriks <fhendriks(a)eltan.com>
Gerrit-Reviewer: Hannah Williams <hannah.williams(a)intel.com>
Gerrit-Reviewer: Huang Jin <huang.jin(a)intel.com>
Gerrit-Reviewer: Lee Leahy <leroy.p.leahy(a)intel.com>
Gerrit-Reviewer: Martin Roth <martinroth(a)google.com>
Gerrit-Reviewer: Matt DeVillier <matt.devillier(a)gmail.com>
Gerrit-Reviewer: Michał Żygowski <michal.zygowski(a)3mdeb.com>
Gerrit-Reviewer: Patrick Georgi <pgeorgi(a)google.com>
Gerrit-Reviewer: Patrick Rudolph <siro(a)das-labor.org>
Gerrit-Reviewer: York Yang <yyang024(a)gmail.com>
Gerrit-Reviewer: build bot (Jenkins) <no-reply(a)coreboot.org>
Gerrit-CC: Angel Pons <th3fanbus(a)gmail.com>
Gerrit-CC: Patrick Rudolph <patrick.rudolph(a)9elements.com>
Gerrit-CC: Paul Menzel <paulepanter(a)users.sourceforge.net>
Gerrit-Comment-Date: Thu, 23 May 2019 11:55:47 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Gerrit-MessageType: comment
Hello Patrick Rudolph, Huang Jin, Arthur Heymans, York Yang, Lee Leahy, Matt DeVillier, build bot (Jenkins), Hannah Williams, Michał Żygowski, Patrick Georgi, Martin Roth,
I'd like you to reexamine a change. Please visit
https://review.coreboot.org/c/coreboot/+/29662
to look at the new patch set (#28).
Change subject: {drivers,soc/intel/braswell}: Implement C_ENVIRONMENT_BOOTBLOCK support
......................................................................
{drivers,soc/intel/braswell}: Implement C_ENVIRONMENT_BOOTBLOCK support
No C_ENVIRONMENT_BOOTBLOCK support for Braswell is available.
Enable support and add required files for the Braswell Bootblock in C.
The next changes are made support C_ENVIRONMENT_BOOTBLOCK:
- Add car_stage_entry() function bootblock-c_entry() functions.
- Specify config DCACHE_BSP_STACK_SIZE and C_ENV_BOOTBLOCK_SIZE.
- Add bootblock_c_entry().
- Move init from car_soc_XXX_console_init() to bootblock_soc_XXX_Init()
Removed the unused cache_as_ram_main().
BUG=NA
TEST=Booting Embedded Linux on Facebook FBG-1701
Building Google Banos
Change-Id: Iab48ad72f1514c93f20d70db5ef4fd8fa2383e8c
Signed-off-by: Frans Hendriks <fhendriks(a)eltan.com>
---
M src/drivers/intel/fsp1_1/Makefile.inc
M src/drivers/intel/fsp1_1/car.c
M src/drivers/intel/fsp1_1/include/fsp/car.h
M src/soc/intel/braswell/Kconfig
M src/soc/intel/braswell/Makefile.inc
M src/soc/intel/braswell/bootblock/bootblock.c
R src/soc/intel/braswell/bootblock/cache_as_ram.S
R src/soc/intel/braswell/bootblock/pmc.c
C src/soc/intel/braswell/include/soc/bootblock.h
M src/soc/intel/braswell/include/soc/romstage.h
M src/soc/intel/braswell/romstage/Makefile.inc
A src/soc/intel/braswell/romstage/car_stage_entry.S
M src/soc/intel/braswell/romstage/romstage.c
13 files changed, 170 insertions(+), 239 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/62/29662/28
--
To view, visit https://review.coreboot.org/c/coreboot/+/29662
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-Change-Id: Iab48ad72f1514c93f20d70db5ef4fd8fa2383e8c
Gerrit-Change-Number: 29662
Gerrit-PatchSet: 28
Gerrit-Owner: Frans Hendriks <fhendriks(a)eltan.com>
Gerrit-Reviewer: Arthur Heymans <arthur(a)aheymans.xyz>
Gerrit-Reviewer: Frans Hendriks <fhendriks(a)eltan.com>
Gerrit-Reviewer: Hannah Williams <hannah.williams(a)intel.com>
Gerrit-Reviewer: Huang Jin <huang.jin(a)intel.com>
Gerrit-Reviewer: Lee Leahy <leroy.p.leahy(a)intel.com>
Gerrit-Reviewer: Martin Roth <martinroth(a)google.com>
Gerrit-Reviewer: Matt DeVillier <matt.devillier(a)gmail.com>
Gerrit-Reviewer: Michał Żygowski <michal.zygowski(a)3mdeb.com>
Gerrit-Reviewer: Patrick Georgi <pgeorgi(a)google.com>
Gerrit-Reviewer: Patrick Rudolph <siro(a)das-labor.org>
Gerrit-Reviewer: York Yang <yyang024(a)gmail.com>
Gerrit-Reviewer: build bot (Jenkins) <no-reply(a)coreboot.org>
Gerrit-CC: Angel Pons <th3fanbus(a)gmail.com>
Gerrit-CC: Patrick Rudolph <patrick.rudolph(a)9elements.com>
Gerrit-CC: Paul Menzel <paulepanter(a)users.sourceforge.net>
Gerrit-MessageType: newpatchset
Patrick Georgi has uploaded this change for review. ( https://review.coreboot.org/c/coreboot/+/32954
Change subject: Renumber cbtable tag MMC_INFO
......................................................................
Renumber cbtable tag MMC_INFO
We got another tag in the meantime, so resolve the conflict.
Change-Id: I64cb5e02a9bed3d8746b75e451c13a1598341ba1
Signed-off-by: Patrick Georgi <pgeorgi(a)google.com>
---
M payloads/libpayload/include/coreboot_tables.h
M src/commonlib/include/commonlib/coreboot_tables.h
2 files changed, 2 insertions(+), 2 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/54/32954/1
diff --git a/payloads/libpayload/include/coreboot_tables.h b/payloads/libpayload/include/coreboot_tables.h
index 705e348..8e5cec0 100644
--- a/payloads/libpayload/include/coreboot_tables.h
+++ b/payloads/libpayload/include/coreboot_tables.h
@@ -287,7 +287,7 @@
struct mac_address mac_addrs[0];
};
-#define CB_TAG_MMC_INFO 0x0034
+#define CB_TAG_MMC_INFO 0x0035
struct cb_mmc_info {
uint32_t tag;
uint32_t size;
diff --git a/src/commonlib/include/commonlib/coreboot_tables.h b/src/commonlib/include/commonlib/coreboot_tables.h
index 99ab21c..bbc8608 100644
--- a/src/commonlib/include/commonlib/coreboot_tables.h
+++ b/src/commonlib/include/commonlib/coreboot_tables.h
@@ -385,7 +385,7 @@
uint8_t pad[2]; /* Pad it to 8 bytes to keep it simple. */
};
-#define LB_TAG_MMC_INFO 0x0034
+#define LB_TAG_MMC_INFO 0x0035
struct lb_mmc_info {
uint32_t tag;
uint32_t size;
--
To view, visit https://review.coreboot.org/c/coreboot/+/32954
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-Change-Id: I64cb5e02a9bed3d8746b75e451c13a1598341ba1
Gerrit-Change-Number: 32954
Gerrit-PatchSet: 1
Gerrit-Owner: Patrick Georgi <pgeorgi(a)google.com>
Gerrit-MessageType: newchange
Frans Hendriks has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/29662 )
Change subject: {drivers,soc/intel/braswell}: Add C_ENVIRONMENT_BOOTBLOCK support
......................................................................
Patch Set 27:
(1 comment)
https://review.coreboot.org/#/c/29662/27/src/drivers/intel/fsp1_1/car.c
File src/drivers/intel/fsp1_1/car.c:
https://review.coreboot.org/#/c/29662/27/src/drivers/intel/fsp1_1/car.c@105
PS27, Line 105: car_soc_pre_console_init();
: car_mainboard_pre_console_init();
> console_init also happens in the bootblock, therefore you want to initialise SPI and LPC in the boot […]
The init in car_soc_XXXX_console_init() are not related to console on Braswell (at least then when using external UART). For this reason console is working in bootblock without problems.
Have moved the code in car_soc_XXXX_console_init() to bootblock_soc_init() and bootblock_soc_early_init().
Will upload new patch set.
--
To view, visit https://review.coreboot.org/c/coreboot/+/29662
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-Change-Id: Iab48ad72f1514c93f20d70db5ef4fd8fa2383e8c
Gerrit-Change-Number: 29662
Gerrit-PatchSet: 27
Gerrit-Owner: Frans Hendriks <fhendriks(a)eltan.com>
Gerrit-Reviewer: Arthur Heymans <arthur(a)aheymans.xyz>
Gerrit-Reviewer: Frans Hendriks <fhendriks(a)eltan.com>
Gerrit-Reviewer: Hannah Williams <hannah.williams(a)intel.com>
Gerrit-Reviewer: Huang Jin <huang.jin(a)intel.com>
Gerrit-Reviewer: Lee Leahy <leroy.p.leahy(a)intel.com>
Gerrit-Reviewer: Martin Roth <martinroth(a)google.com>
Gerrit-Reviewer: Matt DeVillier <matt.devillier(a)gmail.com>
Gerrit-Reviewer: Michał Żygowski <michal.zygowski(a)3mdeb.com>
Gerrit-Reviewer: Patrick Georgi <pgeorgi(a)google.com>
Gerrit-Reviewer: Patrick Rudolph <siro(a)das-labor.org>
Gerrit-Reviewer: York Yang <yyang024(a)gmail.com>
Gerrit-Reviewer: build bot (Jenkins) <no-reply(a)coreboot.org>
Gerrit-CC: Angel Pons <th3fanbus(a)gmail.com>
Gerrit-CC: Patrick Rudolph <patrick.rudolph(a)9elements.com>
Gerrit-CC: Paul Menzel <paulepanter(a)users.sourceforge.net>
Gerrit-Comment-Date: Thu, 23 May 2019 10:29:05 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: Arthur Heymans <arthur(a)aheymans.xyz>
Comment-In-Reply-To: Frans Hendriks <fhendriks(a)eltan.com>
Gerrit-MessageType: comment
Arthur Heymans has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/29662 )
Change subject: {drivers,soc/intel/braswell}: Add C_ENVIRONMENT_BOOTBLOCK support
......................................................................
Patch Set 27:
(1 comment)
https://review.coreboot.org/#/c/29662/27/src/drivers/intel/fsp1_1/car.c
File src/drivers/intel/fsp1_1/car.c:
https://review.coreboot.org/#/c/29662/27/src/drivers/intel/fsp1_1/car.c@105
PS27, Line 105: car_soc_pre_console_init();
: car_mainboard_pre_console_init();
> The car_soc_pre_console_init() is required to have SPI and LPC init. […]
console_init also happens in the bootblock, therefore you want to initialise SPI and LPC in the bootblock and not in the romstage. See lib/bootblock.c
--
To view, visit https://review.coreboot.org/c/coreboot/+/29662
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-Change-Id: Iab48ad72f1514c93f20d70db5ef4fd8fa2383e8c
Gerrit-Change-Number: 29662
Gerrit-PatchSet: 27
Gerrit-Owner: Frans Hendriks <fhendriks(a)eltan.com>
Gerrit-Reviewer: Arthur Heymans <arthur(a)aheymans.xyz>
Gerrit-Reviewer: Frans Hendriks <fhendriks(a)eltan.com>
Gerrit-Reviewer: Hannah Williams <hannah.williams(a)intel.com>
Gerrit-Reviewer: Huang Jin <huang.jin(a)intel.com>
Gerrit-Reviewer: Lee Leahy <leroy.p.leahy(a)intel.com>
Gerrit-Reviewer: Martin Roth <martinroth(a)google.com>
Gerrit-Reviewer: Matt DeVillier <matt.devillier(a)gmail.com>
Gerrit-Reviewer: Michał Żygowski <michal.zygowski(a)3mdeb.com>
Gerrit-Reviewer: Patrick Georgi <pgeorgi(a)google.com>
Gerrit-Reviewer: Patrick Rudolph <siro(a)das-labor.org>
Gerrit-Reviewer: York Yang <yyang024(a)gmail.com>
Gerrit-Reviewer: build bot (Jenkins) <no-reply(a)coreboot.org>
Gerrit-CC: Angel Pons <th3fanbus(a)gmail.com>
Gerrit-CC: Patrick Rudolph <patrick.rudolph(a)9elements.com>
Gerrit-CC: Paul Menzel <paulepanter(a)users.sourceforge.net>
Gerrit-Comment-Date: Thu, 23 May 2019 09:57:10 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: Arthur Heymans <arthur(a)aheymans.xyz>
Comment-In-Reply-To: Frans Hendriks <fhendriks(a)eltan.com>
Gerrit-MessageType: comment
Frans Hendriks has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/29662 )
Change subject: {drivers,soc/intel/braswell}: Add C_ENVIRONMENT_BOOTBLOCK support
......................................................................
Patch Set 27:
(2 comments)
https://review.coreboot.org/#/c/29662/27/src/drivers/intel/fsp1_1/car.c
File src/drivers/intel/fsp1_1/car.c:
https://review.coreboot.org/#/c/29662/27/src/drivers/intel/fsp1_1/car.c@105
PS27, Line 105: car_soc_pre_console_init();
: car_mainboard_pre_console_init();
> Same here. […]
The car_soc_pre_console_init() is required to have SPI and LPC init.
Without these functions SPI access errors during MRC write.
https://review.coreboot.org/#/c/29662/27/src/soc/intel/braswell/bootblock/b…
File src/soc/intel/braswell/bootblock/bootblock.c:
https://review.coreboot.org/#/c/29662/27/src/soc/intel/braswell/bootblock/b…
PS27, Line 50:
> Adding bootblock_cpu_init function result into message that fucntion is not used. […]
Will add bootblock_soc_init() in next patch to call the setup_mmconfig()
--
To view, visit https://review.coreboot.org/c/coreboot/+/29662
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-Change-Id: Iab48ad72f1514c93f20d70db5ef4fd8fa2383e8c
Gerrit-Change-Number: 29662
Gerrit-PatchSet: 27
Gerrit-Owner: Frans Hendriks <fhendriks(a)eltan.com>
Gerrit-Reviewer: Arthur Heymans <arthur(a)aheymans.xyz>
Gerrit-Reviewer: Frans Hendriks <fhendriks(a)eltan.com>
Gerrit-Reviewer: Hannah Williams <hannah.williams(a)intel.com>
Gerrit-Reviewer: Huang Jin <huang.jin(a)intel.com>
Gerrit-Reviewer: Lee Leahy <leroy.p.leahy(a)intel.com>
Gerrit-Reviewer: Martin Roth <martinroth(a)google.com>
Gerrit-Reviewer: Matt DeVillier <matt.devillier(a)gmail.com>
Gerrit-Reviewer: Michał Żygowski <michal.zygowski(a)3mdeb.com>
Gerrit-Reviewer: Patrick Georgi <pgeorgi(a)google.com>
Gerrit-Reviewer: Patrick Rudolph <siro(a)das-labor.org>
Gerrit-Reviewer: York Yang <yyang024(a)gmail.com>
Gerrit-Reviewer: build bot (Jenkins) <no-reply(a)coreboot.org>
Gerrit-CC: Angel Pons <th3fanbus(a)gmail.com>
Gerrit-CC: Patrick Rudolph <patrick.rudolph(a)9elements.com>
Gerrit-CC: Paul Menzel <paulepanter(a)users.sourceforge.net>
Gerrit-Comment-Date: Thu, 23 May 2019 09:33:14 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: Arthur Heymans <arthur(a)aheymans.xyz>
Comment-In-Reply-To: Frans Hendriks <fhendriks(a)eltan.com>
Gerrit-MessageType: comment
Patrick Georgi has submitted this change and it was merged. ( https://review.coreboot.org/c/coreboot/+/25464 )
Change subject: coreboot_tables: pass the early_mmc_wake_hw status to payload
......................................................................
coreboot_tables: pass the early_mmc_wake_hw status to payload
Pass the return value from early_mmc_wake_hw() to the payload so that
payload can skip sending CMD0 and resetting the card in case of success
or in case of a failure in firmware, payload can recover by sending
CMD0 and resetting the card.
BUG=b:78106689
TEST=Boot to OS
Change-Id: Ia4c57d05433c3966118c3642913d7017958cce55
Signed-off-by: Bora Guvendik <bora.guvendik(a)intel.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/25464
Reviewed-by: Lijian Zhao <lijian.zhao(a)intel.com>
Tested-by: build bot (Jenkins) <no-reply(a)coreboot.org>
---
M payloads/libpayload/include/coreboot_tables.h
M payloads/libpayload/include/sysinfo.h
M payloads/libpayload/libc/coreboot.c
M src/commonlib/include/commonlib/coreboot_tables.h
M src/lib/coreboot_table.c
5 files changed, 60 insertions(+), 0 deletions(-)
Approvals:
build bot (Jenkins): Verified
Lijian Zhao: Looks good to me, approved
diff --git a/payloads/libpayload/include/coreboot_tables.h b/payloads/libpayload/include/coreboot_tables.h
index 92e3f26..705e348 100644
--- a/payloads/libpayload/include/coreboot_tables.h
+++ b/payloads/libpayload/include/coreboot_tables.h
@@ -287,6 +287,21 @@
struct mac_address mac_addrs[0];
};
+#define CB_TAG_MMC_INFO 0x0034
+struct cb_mmc_info {
+ uint32_t tag;
+ uint32_t size;
+ /*
+ * Passes the early mmc status to payload to indicate if firmware
+ * successfully sent CMD0, CMD1 to the card or not. In case of
+ * success, the payload can skip the first step of the initialization
+ * sequence which is to send CMD0, and instead start by sending CMD1
+ * as described in Jedec Standard JESD83-B1 section 6.4.3.
+ * passes 1 on success
+ */
+ int32_t early_cmd1_status;
+};
+
#define CB_TAG_SERIALNO 0x002a
#define CB_MAX_SERIALNO_LENGTH 32
diff --git a/payloads/libpayload/include/sysinfo.h b/payloads/libpayload/include/sysinfo.h
index 7e6e748..72059ad 100644
--- a/payloads/libpayload/include/sysinfo.h
+++ b/payloads/libpayload/include/sysinfo.h
@@ -129,6 +129,7 @@
uint64_t mtc_start;
uint32_t mtc_size;
void *chromeos_vpd;
+ int mmc_early_wake_status;
};
extern struct sysinfo_t lib_sysinfo;
diff --git a/payloads/libpayload/libc/coreboot.c b/payloads/libpayload/libc/coreboot.c
index 3982e47..26a3a48 100644
--- a/payloads/libpayload/libc/coreboot.c
+++ b/payloads/libpayload/libc/coreboot.c
@@ -102,6 +102,13 @@
info->vbnv_size = vbnv->range_size;
}
+static void cb_parse_mmc_info(unsigned char *ptr, struct sysinfo_t *info)
+{
+ struct cb_mmc_info *mmc_info = (struct cb_mmc_info *)ptr;
+
+ info->mmc_early_wake_status = mmc_info->early_cmd1_status;
+}
+
static void cb_parse_gpios(unsigned char *ptr, struct sysinfo_t *info)
{
int i;
@@ -399,6 +406,9 @@
case CB_TAG_SPI_FLASH:
cb_parse_spi_flash(ptr, info);
break;
+ case CB_TAG_MMC_INFO:
+ cb_parse_mmc_info(ptr, info);
+ break;
case CB_TAG_MTC:
cb_parse_mtc(ptr, info);
break;
diff --git a/src/commonlib/include/commonlib/coreboot_tables.h b/src/commonlib/include/commonlib/coreboot_tables.h
index 198ad27..99ab21c 100644
--- a/src/commonlib/include/commonlib/coreboot_tables.h
+++ b/src/commonlib/include/commonlib/coreboot_tables.h
@@ -385,6 +385,21 @@
uint8_t pad[2]; /* Pad it to 8 bytes to keep it simple. */
};
+#define LB_TAG_MMC_INFO 0x0034
+struct lb_mmc_info {
+ uint32_t tag;
+ uint32_t size;
+ /*
+ * Passes the early mmc status to payload to indicate if firmware
+ * successfully sent CMD0, CMD1 to the card or not. In case of
+ * success, the payload can skip the first step of the initialization
+ * sequence which is to send CMD0, and instead start by sending CMD1
+ * as described in Jedec Standard JESD83-B1 section 6.4.3.
+ * passes 1 on success
+ */
+ int32_t early_cmd1_status;
+};
+
struct lb_macs {
uint32_t tag;
uint32_t size;
diff --git a/src/lib/coreboot_table.c b/src/lib/coreboot_table.c
index 6e44f5d..14cd030 100644
--- a/src/lib/coreboot_table.c
+++ b/src/lib/coreboot_table.c
@@ -321,6 +321,22 @@
printk(BIOS_INFO, "SKU ID: %d\n", sid);
}
+static void lb_mmc_info(struct lb_header *header)
+{
+ struct lb_mmc_info *rec;
+ int32_t *ms_cbmem;
+
+ ms_cbmem = cbmem_find(CBMEM_ID_MMC_STATUS);
+ if (!ms_cbmem)
+ return;
+
+ rec = (struct lb_mmc_info *)lb_new_record(header);
+
+ rec->tag = LB_TAG_MMC_INFO;
+ rec->size = sizeof(*rec);
+ rec->early_cmd1_status = *ms_cbmem;
+}
+
static void add_cbmem_pointers(struct lb_header *header)
{
/*
@@ -559,6 +575,9 @@
lb_ram_code(head);
lb_sku_id(head);
+ /* Pass mmc early init status */
+ lb_mmc_info(head);
+
/* Add SPI flash description if available */
if (CONFIG(BOOT_DEVICE_SPI_FLASH))
lb_spi_flash(head);
--
To view, visit https://review.coreboot.org/c/coreboot/+/25464
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-Change-Id: Ia4c57d05433c3966118c3642913d7017958cce55
Gerrit-Change-Number: 25464
Gerrit-PatchSet: 29
Gerrit-Owner: Bora Guvendik <bora.guvendik(a)intel.com>
Gerrit-Reviewer: Aaron Durbin <adurbin(a)chromium.org>
Gerrit-Reviewer: Bora Guvendik <bora.guvendik(a)intel.com>
Gerrit-Reviewer: Duncan Laurie <dlaurie(a)chromium.org>
Gerrit-Reviewer: Furquan Shaikh <furquan(a)google.com>
Gerrit-Reviewer: Hannah Williams <hannah.williams(a)intel.com>
Gerrit-Reviewer: Julius Werner <jwerner(a)chromium.org>
Gerrit-Reviewer: Karthik Ramasubramanian <kramasub(a)google.com>
Gerrit-Reviewer: Lijian Zhao <lijian.zhao(a)intel.com>
Gerrit-Reviewer: Patrick Georgi <pgeorgi(a)google.com>
Gerrit-Reviewer: Patrick Rudolph <siro(a)das-labor.org>
Gerrit-Reviewer: Paul Menzel <paulepanter(a)users.sourceforge.net>
Gerrit-Reviewer: Subrata Banik <subrata.banik(a)intel.com>
Gerrit-Reviewer: build bot (Jenkins) <no-reply(a)coreboot.org>
Gerrit-MessageType: merged
Patrick Georgi has submitted this change and it was merged. ( https://review.coreboot.org/c/coreboot/+/25068 )
Change subject: intel/common/block/scs: Add ability to send early CMD0, CMD1
......................................................................
intel/common/block/scs: Add ability to send early CMD0, CMD1
In order to improve boot time with emmc, add ability to send CMD0
and CMD1 early in romstage. This way, by the time system boots to
payload, we are ready to continue with emmc setup and we don't need
to send CMD0 in payload again, and wait for card to reset and be ready.
BUG=b:78106689
TESTS = Boot to OS
Force early_mmc_wake_hw() to return error, recover in payload
Force an error in payload, make sure system can recover/boot
Change-Id: I3488b077bf5100a1e0f2c879fb1436105607d25e
Signed-off-by: Bora Guvendik <bora.guvendik(a)intel.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/25068
Tested-by: build bot (Jenkins) <no-reply(a)coreboot.org>
Reviewed-by: Lijian Zhao <lijian.zhao(a)intel.com>
---
M src/commonlib/include/commonlib/cbmem_id.h
A src/soc/intel/common/block/include/intelblocks/early_mmc.h
M src/soc/intel/common/block/scs/Kconfig
M src/soc/intel/common/block/scs/Makefile.inc
A src/soc/intel/common/block/scs/early_mmc.c
5 files changed, 259 insertions(+), 0 deletions(-)
Approvals:
build bot (Jenkins): Verified
Lijian Zhao: Looks good to me, approved
diff --git a/src/commonlib/include/commonlib/cbmem_id.h b/src/commonlib/include/commonlib/cbmem_id.h
index af79a59..535ba33 100644
--- a/src/commonlib/include/commonlib/cbmem_id.h
+++ b/src/commonlib/include/commonlib/cbmem_id.h
@@ -39,6 +39,7 @@
#define CBMEM_ID_IMD_SMALL 0x53a11439
#define CBMEM_ID_MEMINFO 0x494D454D
#define CBMEM_ID_MMA_DATA 0x4D4D4144
+#define CBMEM_ID_MMC_STATUS 0x4d4d4353
#define CBMEM_ID_MPTABLE 0x534d5054
#define CBMEM_ID_MRCDATA 0x4d524344
#define CBMEM_ID_VAR_MRCDATA 0x4d524345
@@ -100,6 +101,7 @@
{ CBMEM_ID_IMD_SMALL, "IMD SMALL " }, \
{ CBMEM_ID_MEMINFO, "MEM INFO " }, \
{ CBMEM_ID_MMA_DATA, "MMA DATA " }, \
+ { CBMEM_ID_MMC_STATUS, "MMC STATUS " }, \
{ CBMEM_ID_MPTABLE, "SMP TABLE " }, \
{ CBMEM_ID_MRCDATA, "MRC DATA " }, \
{ CBMEM_ID_VAR_MRCDATA, "VARMRC DATA" }, \
diff --git a/src/soc/intel/common/block/include/intelblocks/early_mmc.h b/src/soc/intel/common/block/include/intelblocks/early_mmc.h
new file mode 100644
index 0000000..69be40c
--- /dev/null
+++ b/src/soc/intel/common/block/include/intelblocks/early_mmc.h
@@ -0,0 +1,80 @@
+/*
+ * This file is part of the coreboot project.
+ *
+ * Copyright (C) 2018 Intel Corporation.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; version 2 of the License.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ */
+
+#ifndef SOC_INTEL_COMMON_BLOCK_EARLY_MMC_H
+#define SOC_INTEL_COMMON_BLOCK_EARLY_MMC_H
+
+#include <stdint.h>
+
+/*
+ * Following should be defined in soc/iomap.h
+ * PRERAM_MMC_BASE_ADDRESS - Provide an address to setup emmc controller's
+ PCI BAR.
+ */
+
+/*
+ * Structure for the following delay registers
+ * emmc_tx_data_cntl1: Tx Delay Control 1 (Tx_DATA_dly_1)-Offset 824h
+ * emmc_tx_data_cntl2: Tx Delay Control 2 (Tx_DATA_dly_2)-Offset 828h
+ * emmc_rx_cmd_data_cntl1: Rx CMD Data Delay Control 1
+ * (Rx_CMD_Data_dly_1)-Offset 82Ch
+ * emmc_rx_cmd_data_cntl2: Rx CMD Data Path Delay Control 2
+ * (Rx_CMD_Data_dly_2)-Offset 834h
+ * emmc_rx_strobe_cntl: Rx Strobe Delay Control
+ * (Rx_Strobe_Ctrl_Path)-Offset 830h
+ * emmc_tx_cmd_cntl: Tx CMD Delay Control (Tx_CMD_dly)-Offset 820h
+ */
+struct mmc_dll_params {
+ uint32_t emmc_tx_data_cntl1;
+ uint32_t emmc_tx_data_cntl2;
+ uint32_t emmc_rx_cmd_data_cntl1;
+ uint32_t emmc_rx_cmd_data_cntl2;
+ uint32_t emmc_rx_strobe_cntl;
+ uint32_t emmc_tx_cmd_cntl;
+};
+
+/*
+ * SOC specific API to get mmc min max frequencies.
+ * returns 0, if able to get f_min, f_max; otherwise returns -1
+ */
+int soc_get_mmc_frequencies(uint32_t *f_min, uint32_t *f_max);
+/*
+ * SOC specific API to configure mmc gpios.
+ * returns 0, if able to configure gpios; otherwise returns -1
+ */
+int soc_configure_mmc_gpios(void);
+/*
+ * SOC specific API to get mmc delay register settings.
+ * returns 0, if able to get register settings; otherwise returns -1
+ */
+int soc_get_mmc_dll(struct mmc_dll_params *params);
+
+#if IS_ENABLED(CONFIG_SOC_INTEL_COMMON_EARLY_MMC_WAKE)
+/*
+ * Initializes sdhci / mmc controller and sends CMD0, CMD1 to emmc card.
+ * In case of success: It returns 0 and adds cbmem entry CBMEM_ID_MMC_STATUS
+ * and sets it to 1. Payload can start by sending CMD1, there is no need to
+ * send CMD0 and wait for the card to be ready.
+ * In case of failure: It returns -1 and doesn't add cbmem entry. Payload
+ * should do complete initialization starting with CMD0.
+ */
+int early_mmc_wake_hw(void);
+#else
+static inline int early_mmc_wake_hw(void)
+{
+ return -1;
+}
+#endif /* CONFIG_SOC_INTEL_COMMON_EARLY_MMC_WAKE */
+#endif /* SOC_INTEL_COMMON_BLOCK_EARLY_MMC_H */
diff --git a/src/soc/intel/common/block/scs/Kconfig b/src/soc/intel/common/block/scs/Kconfig
index 0a40213..06ad8e4 100644
--- a/src/soc/intel/common/block/scs/Kconfig
+++ b/src/soc/intel/common/block/scs/Kconfig
@@ -2,3 +2,13 @@
bool
help
Intel Processor common storage and communication subsystem support
+
+config SOC_INTEL_COMMON_EARLY_MMC_WAKE
+ bool
+ default n
+ select COMMONLIB_STORAGE
+ select COMMONLIB_STORAGE_MMC
+ select SDHCI_CONTROLLER
+ help
+ Send CMD1 early in romstage to improve boot time. It requires emmc
+ DLL tuning parameters to be added to devicetree.cb
diff --git a/src/soc/intel/common/block/scs/Makefile.inc b/src/soc/intel/common/block/scs/Makefile.inc
index 1c2a6c6..1160802 100644
--- a/src/soc/intel/common/block/scs/Makefile.inc
+++ b/src/soc/intel/common/block/scs/Makefile.inc
@@ -1 +1,2 @@
ramstage-$(CONFIG_SOC_INTEL_COMMON_BLOCK_SCS) += sd.c
+romstage-$(CONFIG_SOC_INTEL_COMMON_EARLY_MMC_WAKE) += early_mmc.c
diff --git a/src/soc/intel/common/block/scs/early_mmc.c b/src/soc/intel/common/block/scs/early_mmc.c
new file mode 100644
index 0000000..4b15bb4
--- /dev/null
+++ b/src/soc/intel/common/block/scs/early_mmc.c
@@ -0,0 +1,166 @@
+/*
+ * This file is part of the coreboot project.
+ *
+ * Copyright (C) 2018 Intel Corporation.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; version 2 of the License.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ */
+
+#include <arch/acpi.h>
+#include <arch/early_variables.h>
+#include <cbmem.h>
+#include <commonlib/storage/sd_mmc.h>
+#include <commonlib/sd_mmc_ctrlr.h>
+#include <commonlib/sdhci.h>
+#include <compiler.h>
+#include <console/console.h>
+#include <device/pci.h>
+#include <intelblocks/early_mmc.h>
+#include <soc/iomap.h>
+#include <soc/pci_devs.h>
+#include <string.h>
+
+#define EMMC_TX_CMD_CNTL_OFFSET 0x820
+#define EMMC_TX_DATA_CNTL1_OFFSET 0x824
+#define EMMC_TX_DATA_CNTL2_OFFSET 0x828
+#define EMMC_RX_CMD_DATA_CNTL1_OFFSET 0x82C
+#define EMMC_RX_STROBE_CNTL_OFFSET 0x830
+#define EMMC_RX_CMD_DATA_CNTL2_OFFSET 0x834
+
+void soc_sd_mmc_controller_quirks(struct sd_mmc_ctrlr *ctrlr)
+{
+ uint32_t f_min, f_max;
+
+ if (soc_get_mmc_frequencies(&f_min, &f_max) < 0) {
+ printk(BIOS_ERR,
+ "MMC early init: failed to get mmc frequencies\n");
+ return;
+ }
+
+ ctrlr->f_min = f_min;
+ ctrlr->f_max = f_max;
+}
+
+static void enable_mmc_controller_bar(void)
+{
+ pci_write_config32(PCH_DEV_EMMC, PCI_BASE_ADDRESS_0,
+ PRERAM_MMC_BASE_ADDRESS);
+ pci_write_config32(PCH_DEV_EMMC, PCI_COMMAND,
+ PCI_COMMAND_MASTER | PCI_COMMAND_MEMORY);
+}
+
+static void disable_mmc_controller_bar(void)
+{
+ pci_write_config32(PCH_DEV_EMMC, PCI_BASE_ADDRESS_0, 0);
+ pci_write_config32(PCH_DEV_EMMC, PCI_COMMAND,
+ ~(PCI_COMMAND_MASTER | PCI_COMMAND_MEMORY));
+}
+
+static int set_mmc_dll(void *ioaddr)
+{
+ struct mmc_dll_params dll_params;
+
+ if (soc_get_mmc_dll(&dll_params) < 0) {
+ printk(BIOS_ERR,
+ "MMC early init: failed to get mmc DLL parameters\n");
+ return -1;
+ }
+
+ write32(ioaddr + EMMC_TX_DATA_CNTL1_OFFSET,
+ dll_params.emmc_tx_data_cntl1);
+ write32(ioaddr + EMMC_TX_DATA_CNTL2_OFFSET,
+ dll_params.emmc_tx_data_cntl2);
+ write32(ioaddr + EMMC_RX_CMD_DATA_CNTL1_OFFSET,
+ dll_params.emmc_rx_cmd_data_cntl1);
+ write32(ioaddr + EMMC_RX_CMD_DATA_CNTL2_OFFSET,
+ dll_params.emmc_rx_cmd_data_cntl2);
+ write32(ioaddr + EMMC_RX_STROBE_CNTL_OFFSET,
+ dll_params.emmc_rx_strobe_cntl);
+ write32(ioaddr + EMMC_TX_CMD_CNTL_OFFSET,
+ dll_params.emmc_tx_cmd_cntl);
+
+ return 0;
+}
+
+static void set_early_mmc_wake_status(int32_t status)
+{
+ int32_t *ms_cbmem;
+
+ ms_cbmem = cbmem_add(CBMEM_ID_MMC_STATUS, sizeof(int));
+
+ if (ms_cbmem == NULL) {
+ printk(BIOS_ERR,
+ "%s: Failed to add early mmc wake status to cbmem!\n",
+ __func__);
+ return;
+ }
+
+ *ms_cbmem = status;
+}
+
+int early_mmc_wake_hw(void)
+{
+ struct storage_media media;
+ struct sd_mmc_ctrlr *mmc_ctrlr;
+ struct sdhci_ctrlr *sdhci_ctrlr;
+ int err;
+
+ if (acpi_is_wakeup_s3())
+ return -1;
+
+ /* Configure mmc gpios */
+ if (soc_configure_mmc_gpios() < 0) {
+ printk(BIOS_ERR,
+ "%s: MMC early init: failed to configure mmc gpios\n",
+ __func__);
+ return -1;
+ }
+ /* Setup pci bar */
+ enable_mmc_controller_bar();
+
+ /* Initialize sdhci */
+ mmc_ctrlr = new_pci_sdhci_controller(PCH_DEV_EMMC);
+ if (mmc_ctrlr == NULL)
+ goto out_err;
+
+ sdhci_ctrlr = container_of(mmc_ctrlr, struct sdhci_ctrlr, sd_mmc_ctrlr);
+
+ /* set emmc DLL tuning parameters */
+ if (set_mmc_dll(sdhci_ctrlr->ioaddr) < 0)
+ goto out_err;
+
+ memset(&media, 0, sizeof(media));
+ media.ctrlr = mmc_ctrlr;
+ SET_BUS_WIDTH(mmc_ctrlr, 1);
+ /*
+ * Set clock to 1 so that the driver can choose minimum frequency
+ * possible
+ */
+ SET_CLOCK(mmc_ctrlr, 1);
+
+ /* Reset emmc, send CMD0 */
+ if (sd_mmc_go_idle(&media))
+ goto out_err;
+
+ /* Send CMD1 */
+ err = mmc_send_op_cond(&media);
+ if (err != 0 && err != CARD_IN_PROGRESS)
+ goto out_err;
+
+ disable_mmc_controller_bar();
+
+ set_early_mmc_wake_status(1);
+ return 0;
+
+out_err:
+
+ disable_mmc_controller_bar();
+ return -1;
+}
--
To view, visit https://review.coreboot.org/c/coreboot/+/25068
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-Change-Id: I3488b077bf5100a1e0f2c879fb1436105607d25e
Gerrit-Change-Number: 25068
Gerrit-PatchSet: 25
Gerrit-Owner: Bora Guvendik <bora.guvendik(a)intel.com>
Gerrit-Reviewer: Aaron Durbin <adurbin(a)chromium.org>
Gerrit-Reviewer: Barnali Sarkar <barnali.sarkar(a)intel.com>
Gerrit-Reviewer: Bora Guvendik <bora.guvendik(a)intel.com>
Gerrit-Reviewer: Duncan Laurie <dlaurie(a)chromium.org>
Gerrit-Reviewer: Furquan Shaikh <furquan(a)google.com>
Gerrit-Reviewer: Hannah Williams <hannah.williams(a)intel.com>
Gerrit-Reviewer: John Zhao <john.zhao(a)intel.com>
Gerrit-Reviewer: Julius Werner <jwerner(a)chromium.org>
Gerrit-Reviewer: Karthik Ramasubramanian <kramasub(a)google.com>
Gerrit-Reviewer: Lijian Zhao <lijian.zhao(a)intel.com>
Gerrit-Reviewer: Patrick Georgi <pgeorgi(a)google.com>
Gerrit-Reviewer: Patrick Rudolph <siro(a)das-labor.org>
Gerrit-Reviewer: Paul Menzel <paulepanter(a)users.sourceforge.net>
Gerrit-Reviewer: Srinidhi N Kaushik <srinidhi.n.kaushik(a)intel.com>
Gerrit-Reviewer: Subrata Banik <subrata.banik(a)intel.com>
Gerrit-Reviewer: build bot (Jenkins) <no-reply(a)coreboot.org>
Gerrit-Reviewer: dhaval v sharma <dhaval.v.sharma(a)intel.com>
Gerrit-MessageType: merged