diff options
author | Laura Abbott <labbott@redhat.com> | 2017-04-18 11:27:03 -0700 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2017-04-18 20:41:12 +0200 |
commit | f318dd083c8128c50e48ceb8c3e812e52800fc4f (patch) | |
tree | 29d2a27dbc996aac1413457a89832df22aae7da0 /drivers/base | |
parent | df47c0a638b07dab18b202b307506e4b86b02e9a (diff) |
cma: Store a name in the cma structure
Frameworks that may want to enumerate CMA heaps (e.g. Ion) will find it
useful to have an explicit name attached to each region. Store the name
in each CMA structure.
Signed-off-by: Laura Abbott <labbott@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/base')
-rw-r--r-- | drivers/base/dma-contiguous.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/drivers/base/dma-contiguous.c b/drivers/base/dma-contiguous.c index b55804cac4c4..ea9726e71468 100644 --- a/drivers/base/dma-contiguous.c +++ b/drivers/base/dma-contiguous.c @@ -165,7 +165,8 @@ int __init dma_contiguous_reserve_area(phys_addr_t size, phys_addr_t base, { int ret; - ret = cma_declare_contiguous(base, size, limit, 0, 0, fixed, res_cma); + ret = cma_declare_contiguous(base, size, limit, 0, 0, fixed, + "reserved", res_cma); if (ret) return ret; @@ -258,7 +259,7 @@ static int __init rmem_cma_setup(struct reserved_mem *rmem) return -EINVAL; } - err = cma_init_reserved_mem(rmem->base, rmem->size, 0, &cma); + err = cma_init_reserved_mem(rmem->base, rmem->size, 0, rmem->name, &cma); if (err) { pr_err("Reserved memory: unable to setup CMA region\n"); return err; |