Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit edd0183c authored by Shashank Mittal's avatar Shashank Mittal Committed by Kyle Yan
Browse files

coresight: make 'coresight-name' a required property



Without 'coresight-name' a CoreSight device gets registered with its
dev_name.

This can be a problem in case where we have CoreSight properties defined
within some other platform device.

Make 'coresight-name' a required property for a CoreSight device to
avoid this problem.

Change-Id: I5e192c4d850bb040983024cfe163714fbebbb199
Signed-off-by: default avatarShashank Mittal <mittals@codeaurora.org>
parent ab366edb
Loading
Loading
Loading
Loading
+4 −1
Original line number Diff line number Diff line
@@ -37,6 +37,8 @@ its hardware characteristcs.
	  layout using the generic DT graph presentation found in
	  "bindings/graph.txt".

	* coresight-name: unique descriptive name of the component.

* Required properties for devices that don't show up on the AMBA bus, such as
  non-configurable replicators:

@@ -54,8 +56,9 @@ its hardware characteristcs.

	* port or ports: same as above.

* Optional properties for all components:
	* coresight-name: unique descriptive name of the component.

* Optional properties for all components:
	* reg-names: names corresponding to each reg property value.

* Optional properties for ETM/PTMs:
+2 −4
Original line number Diff line number Diff line
@@ -119,10 +119,8 @@ struct coresight_platform_data *of_get_coresight_platform_data(
		return ERR_PTR(-ENOMEM);

	ret = of_property_read_string(node, "coresight-name", &pdata->name);
	if (ret) {
		/* Use device name as sysfs handle */
		pdata->name = dev_name(dev);
	}
	if (ret)
		return ERR_PTR(ret);

	/* Get the number of input and output port for this component */
	of_coresight_get_ports(node, &pdata->nr_inport, &pdata->nr_outport);