[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-devel] [PATCH 4/8] xen/arm: Warn when a device tree path will be re-used by Xen



On Tue, 2015-09-22 at 18:47 +0100, Julien Grall wrote:
> Xen is using unconditionnally some device tree path to create DOM0

"unconditionally"

> specific node (for instance /psci, /memory and /hypervisor).
> 
> Rather than blindly add new nodes with the same, print a warning message
> on the console to let know the user that something may go wrong.

So it seems to me that /psci and /memory should be pretty common and that
warning when we deliberately replace them with our own contents seems
wrong.

I think the bit which the commit message misses out is that we already
filter out psci and such by compatible string before this point, so this
warning is only for the case where there is a /psci which is not compatible
"arm,psci" or "arm,psci-0.2" etc, i.e. it is something strange and special.

And that case does indeed seem worth warning about but the commit message
needs to be clearer about the circumstances of the logging.

I wonder if it would be worth printing the compatible strings of the node
we are clobbering? There's a good chance they will be e.g. "arm,psci-0.3"
(with no backwards compat) or something and knowing that might be useful.
But maybe it's too much code to worry about.

BTW, how did you trip over this?

> +    /*
> +     * Xen is using some path for its own purpose. Warn if a node

"paths" and "purposes".

> +     * already exists with the same path.
> +     */
> +    if ( dt_match_node(reserved_matches, node) )
> +        printk(XENLOG_WARNING "WARNING: Path %s is reserved, skip the
> node\n",

Rather than skipping we are actually replacing it with our version. Maybe
say that?


_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
http://lists.xen.org/xen-devel


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.