[PATCH 2/2] tpm: add support for TPMv2.x I2C chips

Ilias Apalodimas ilias.apalodimas at linaro.org
Mon May 23 08:12:05 CEST 2022


Hi Eddie, 

Thanks for the patch.

[...]

> +static const struct tpm_tis_chip_data tpm_tis_std_chip_data = {
> +	.pcr_count = 24,
> +	.pcr_select_min = 3,
> +};
> +
> +static const struct udevice_id tpm_tis_i2c_ids[] = {
> +	{
> +		.compatible = "nuvoton,npct75x",
> +		.data = (ulong)&tpm_tis_std_chip_data,
> +	},
> +	{
> +		.compatible = "tcg,tpm-tis-i2c",
> +		.data = (ulong)&tpm_tis_std_chip_data,
> +	},
> +	{ }
> +};
> +
> +U_BOOT_DRIVER(tpm_tis_i2c) = {
> +	.name = "tpm_tis_i2c",
> +	.id = UCLASS_TPM,
> +	.of_match = tpm_tis_i2c_ids,
> +	.ops = &tpm_tis_i2c_ops,
> +	.probe = tpm_tis_i2c_probe,
> +	.remove = tpm_tis_i2c_remove,
> +	.priv_auto_alloc_size = sizeof(struct tpm_chip),

Shouldn't this be .priv_auto only? IIRC we got rid of the
.priv_auto_alloc_size a while back?  If so I can fix this while merging

Regards
/Ilias

> +};
> -- 
> 2.27.0
> 


More information about the U-Boot mailing list