Edward O'Callaghan has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/43741 )
Change subject: drivers/spi/tpm: Enable long cr50 ready pulses for Tiger Lake systems
......................................................................
Patch Set 22:
(1 comment)
https://review.coreboot.org/c/coreboot/+/43741/22/src/drivers/spi/tpm/tpm.c
File src/drivers/spi/tpm/tpm.c:
https://review.coreboot.org/c/coreboot/+/43741/22/src/drivers/spi/tpm/tpm.c@...
PS22, Line 51: tatic int cr50_firmware_version[3];
Actually, Karthik is working on some patches that might need stashing of cr50 firmware version somew […]
Well that isn't happening in this patch and the control flow isn't currently good by doing this.
Why not stash it at the buttom of the call frame stack and pass by reference up? I suspect we can resolve this in the subsequent patches if a singleton really is required, however it is clearly not required here. In the absolute worst case of requiring a singleton pattern, one should access the state variable via a getter/setter functions and have a default value in the getter for uninitialised.
--
To view, visit
https://review.coreboot.org/c/coreboot/+/43741
To unsubscribe, or for help writing mail filters, visit
https://review.coreboot.org/settings
Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-Change-Id: If83188fd09fe69c2cda4ce1a8bf5b2efe1ca86da
Gerrit-Change-Number: 43741
Gerrit-PatchSet: 22
Gerrit-Owner: Jes Klinke
jbk@chromium.org
Gerrit-Reviewer: Aaron Durbin
adurbin@chromium.org
Gerrit-Reviewer: Christian Walter
christian.walter@9elements.com
Gerrit-Reviewer: Furquan Shaikh
furquan@google.com
Gerrit-Reviewer: Jes Klinke
jbk@google.com
Gerrit-Reviewer: Julius Werner
jwerner@chromium.org
Gerrit-Reviewer: Martin Roth
martinroth@google.com
Gerrit-Reviewer: Patrick Georgi
pgeorgi@google.com
Gerrit-Reviewer: Patrick Rudolph
siro@das-labor.org
Gerrit-Reviewer: build bot (Jenkins)
no-reply@coreboot.org
Gerrit-CC: Edward O'Callaghan
quasisec@chromium.org
Gerrit-CC: Karthik Ramasubramanian
kramasub@google.com
Gerrit-CC: Namyoon Woo
namyoon@google.com
Gerrit-CC: Paul Menzel
paulepanter@users.sourceforge.net
Gerrit-Comment-Date: Mon, 17 Aug 2020 00:47:17 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: Furquan Shaikh
furquan@google.com
Comment-In-Reply-To: Edward O'Callaghan
quasisec@chromium.org
Gerrit-MessageType: comment