Lean Sheng Tan has submitted this change. ( https://review.coreboot.org/c/coreboot/+/85318?usp=email )
(
8 is the latest approved patch-set. No files were changed between the latest approved patch-set and the submitted one. )Change subject: mb/ocp/tiogapass: Implement mainboard_dimm_slot_exists ......................................................................
mb/ocp/tiogapass: Implement mainboard_dimm_slot_exists
The board has 24 slots for DDR4 ECC RDIMMs and it has 2 CPU sockets, where each is connected to 12 DIMMs. Every socket supports up to 6 channels, thus every channel is connected to 2 DIMMs.
Implement mainboard_dimm_slot_exists accordingly to advertise all slots as SMBIOS type 17.
TEST: Found all installed DIMMs advertised through SMBIOS on ocp/tiogapass.
Change-Id: I31cb4a89aa11258ac04eb69a0e9c86f258280484 Signed-off-by: Patrick Rudolph patrick.rudolph@9elements.com Reviewed-on: https://review.coreboot.org/c/coreboot/+/85318 Reviewed-by: Christian Walter christian.walter@9elements.com Tested-by: build bot (Jenkins) no-reply@coreboot.org --- M src/mainboard/ocp/tiogapass/romstage.c 1 file changed, 17 insertions(+), 4 deletions(-)
Approvals: build bot (Jenkins): Verified Christian Walter: Looks good to me, approved
diff --git a/src/mainboard/ocp/tiogapass/romstage.c b/src/mainboard/ocp/tiogapass/romstage.c index d3063c6..283d5f1 100644 --- a/src/mainboard/ocp/tiogapass/romstage.c +++ b/src/mainboard/ocp/tiogapass/romstage.c @@ -1,13 +1,14 @@ /* SPDX-License-Identifier: GPL-2.0-or-later */
-#include <fsp/api.h> -#include <FspmUpd.h> #include <drivers/ipmi/ipmi_if.h> #include <drivers/ipmi/ocp/ipmi_ocp.h> +#include <fsp/api.h> +#include <FspmUpd.h> +#include <gpio.h> +#include <soc/ddr.h> +#include <soc/gpio_soc_defs.h> #include <soc/romstage.h> #include <string.h> -#include <gpio.h> -#include <soc/gpio_soc_defs.h> #include <skxsp_tp_iio.h>
#include "ipmi.h" @@ -64,3 +65,15 @@ mupd->FspmConfig.GpioConfig.GpioTable = NULL; mupd->FspmConfig.GpioConfig.NumberOfEntries = 0; } + +bool mainboard_dimm_slot_exists(uint8_t socket, uint8_t channel, uint8_t dimm) +{ + if (socket >= CONFIG_MAX_SOCKET) + return false; + if (channel >= 6) + return false; + if (dimm >= 2) + return false; + + return true; +}