remoteproc: Keep local copy of firmware name

Storage of the firmware name was inconsistent, either storing a pointer
to a name stored with unknown ownership, or a variable length tacked
onto the end of the struct proc allocated in rproc_alloc.

In preparation for allowing the firmware of an already allocated struct
rproc to be changed, instead always keep a locally maintained copy of
the firmware name.

Signed-off-by: Matt Redfearn <matt.redfearn@imgtec.com>
Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org>
This commit is contained in:
Matt Redfearn
2016-10-17 16:48:58 +01:00
committed by Bjorn Andersson
parent 1001354ca3
commit 0f57dc6ae1
2 changed files with 17 additions and 16 deletions

View File

@@ -415,7 +415,7 @@ struct rproc {
struct list_head node;
struct iommu_domain *domain;
const char *name;
const char *firmware;
char *firmware;
void *priv;
const struct rproc_ops *ops;
struct device dev;