lkml.org 
[lkml]   [2013]   [Sep]   [19]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRe: [PATCH v6 1/5] ARM: add basic support for Trusted Foundations
Date
Alexandre Courbot <acourbot@nvidia.com> writes:

> Trusted Foundations is a TrustZone-based secure monitor for ARM that
> can be invoked using the same SMC-based API on all supported
> platforms. This patch adds initial basic support for Trusted
> Foundations using the ARM firmware API. Current features are limited
> to the ability to boot secondary processors.

[...]

> +#if IS_ENABLED(CONFIG_OF)
> +void of_register_trusted_foundations(void)
> +{
> + struct device_node *node;
> + struct trusted_foundations_platform_data pdata;
> + int err;
> +
> + node = of_find_compatible_node(NULL, NULL, "tl,trusted-foundations");
> + if (!node)
> + return;
> +
> + err = of_property_read_u32(node, "version-major", &pdata.version_major);
> + if (err != 0)
> + panic("Trusted Foundation: missing version-major property\n");

Do really need to panic() the whole kernel for a missing property?
Surely this can more gracefully recover, or assume some defaults?

Same comment for the other uses of panic() in this patch.

Kevin



\
 
 \ /
  Last update: 2013-09-19 23:21    [W:0.075 / U:0.140 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site