diff options
author | Hiroshi DOYU <hdoyu@nvidia.com> | 2012-07-09 11:24:57 +0300 |
---|---|---|
committer | Rohan Somvanshi <rsomvanshi@nvidia.com> | 2012-07-11 06:37:43 -0700 |
commit | 6cbf4c7465b7b70936cb422b509da0ad0829c306 (patch) | |
tree | 89cb91fd31b9fe3275b192106355b908257c5bec /arch/arm/mach-tegra/include | |
parent | f938865b63a8a34a073e2bb366aeff1d4af6890a (diff) |
ARM: tegra: iovmm: Allow alloc_client to take struct device
Allow tegra_iovmm_alloc_client() to take struct device * instead of
const char *name w/ __tegra_iovmm_alloc_client(). This is necessary to
support IOVMM and IOMMU simultaneously.
Change-Id: I18df5001bfe0ece8f9f15b636eb11def9f228dfb
Signed-off-by: Hiroshi DOYU <hdoyu@nvidia.com>
Reviewed-on: http://git-master/r/114215
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Krishna Reddy <vdumpa@nvidia.com>
Diffstat (limited to 'arch/arm/mach-tegra/include')
-rw-r--r-- | arch/arm/mach-tegra/include/mach/iovmm.h | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/arch/arm/mach-tegra/include/mach/iovmm.h b/arch/arm/mach-tegra/include/mach/iovmm.h index fd83a326e129..ff94e4751a75 100644 --- a/arch/arm/mach-tegra/include/mach/iovmm.h +++ b/arch/arm/mach-tegra/include/mach/iovmm.h @@ -1,7 +1,7 @@ /* * arch/arm/mach-tegra/include/mach/iovmm.h * - * Copyright (c) 2010-2011, NVIDIA Corporation. + * Copyright (c) 2010-2012, NVIDIA Corporation. * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -140,9 +140,16 @@ struct tegra_iovmm_area_ops { * called by clients to allocate an I/O VMM client mapping context which * will be shared by all clients in the same share_group */ -struct tegra_iovmm_client *tegra_iovmm_alloc_client(const char *name, +struct tegra_iovmm_client *__tegra_iovmm_alloc_client(const char *name, const char *share_group, struct miscdevice *misc_dev); +static inline struct tegra_iovmm_client *tegra_iovmm_alloc_client( + struct device *dev, const char *share_group, + struct miscdevice *misc_dev) +{ + return __tegra_iovmm_alloc_client(dev_name(dev), share_group, misc_dev); +} + size_t tegra_iovmm_get_vm_size(struct tegra_iovmm_client *client); void tegra_iovmm_free_client(struct tegra_iovmm_client *client); |