mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2025-01-09 06:43:09 +00:00
remoteproc: add name in rproc_mem_entry struct
Add name field in struct rproc_mem_entry. This new field will be used to match memory area requested in resource table with pre-registered carveout. Signed-off-by: Loic Pallardy <loic.pallardy@st.com> Acked-by: Bjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org>
This commit is contained in:
parent
f2e74abfaa
commit
3265230c5b
@ -752,6 +752,7 @@ static int rproc_handle_carveout(struct rproc *rproc,
|
|||||||
carveout->dma = dma;
|
carveout->dma = dma;
|
||||||
carveout->da = rsc->da;
|
carveout->da = rsc->da;
|
||||||
carveout->release = rproc_release_carveout;
|
carveout->release = rproc_release_carveout;
|
||||||
|
strlcpy(carveout->name, rsc->name, sizeof(carveout->name));
|
||||||
|
|
||||||
list_add_tail(&carveout->node, &rproc->carveouts);
|
list_add_tail(&carveout->node, &rproc->carveouts);
|
||||||
|
|
||||||
|
@ -260,6 +260,7 @@ static int rproc_carveouts_show(struct seq_file *seq, void *p)
|
|||||||
|
|
||||||
list_for_each_entry(carveout, &rproc->carveouts, node) {
|
list_for_each_entry(carveout, &rproc->carveouts, node) {
|
||||||
seq_puts(seq, "Carveout memory entry:\n");
|
seq_puts(seq, "Carveout memory entry:\n");
|
||||||
|
seq_printf(seq, "\tName: %s\n", carveout->name);
|
||||||
seq_printf(seq, "\tVirtual address: %pK\n", carveout->va);
|
seq_printf(seq, "\tVirtual address: %pK\n", carveout->va);
|
||||||
seq_printf(seq, "\tDMA address: %pad\n", &carveout->dma);
|
seq_printf(seq, "\tDMA address: %pad\n", &carveout->dma);
|
||||||
seq_printf(seq, "\tDevice address: 0x%x\n", carveout->da);
|
seq_printf(seq, "\tDevice address: 0x%x\n", carveout->da);
|
||||||
|
@ -315,6 +315,7 @@ struct rproc;
|
|||||||
* @da: device address
|
* @da: device address
|
||||||
* @release: release associated memory
|
* @release: release associated memory
|
||||||
* @priv: associated data
|
* @priv: associated data
|
||||||
|
* @name: associated memory region name (optional)
|
||||||
* @node: list node
|
* @node: list node
|
||||||
*/
|
*/
|
||||||
struct rproc_mem_entry {
|
struct rproc_mem_entry {
|
||||||
@ -323,6 +324,7 @@ struct rproc_mem_entry {
|
|||||||
int len;
|
int len;
|
||||||
u32 da;
|
u32 da;
|
||||||
void *priv;
|
void *priv;
|
||||||
|
char name[32];
|
||||||
struct list_head node;
|
struct list_head node;
|
||||||
int (*release)(struct rproc *rproc, struct rproc_mem_entry *mem);
|
int (*release)(struct rproc *rproc, struct rproc_mem_entry *mem);
|
||||||
};
|
};
|
||||||
|
Loading…
Reference in New Issue
Block a user