summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLaxman Dewangan <ldewangan@nvidia.com>2010-09-03 16:03:58 +0530
committerBharat Nihalani <bnihalani@nvidia.com>2010-09-06 06:07:21 -0700
commitbf59cb1843c1a38b863aded00202b089a71c0653 (patch)
tree0445d32dce697c6c7861857ca9fa2331eb980d78
parent0e52d7fe25b11a656c376a37890be219470661fb (diff)
[arm/tegra]: Allocating dma action memory with zero init.
In NvRmDmaStartDmaTransfer(), the memory is allocated for the dma action. The allocated memory does not get initialized and so uninitialized member unintentionally changing the behavior of dma. Allocating memory with zero initialized. bug 728661 (cherry picked from commit ac036af2c9599c419c12a8ba1c4309a9d8364b21) Change-Id: Ie36db6ad88eb9a9870f53b2c685eed6888decaf9 Reviewed-on: http://git-master.nvidia.com/r/6052 Reviewed-by: Laxman Dewangan <ldewangan@nvidia.com> Tested-by: Laxman Dewangan <ldewangan@nvidia.com> Reviewed-by: Bharat Nihalani <bnihalani@nvidia.com>
-rw-r--r--arch/arm/mach-tegra/nvrm/io/common/nvrm_dma.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/arm/mach-tegra/nvrm/io/common/nvrm_dma.c b/arch/arm/mach-tegra/nvrm/io/common/nvrm_dma.c
index 03597ec08709..0734dc9dda18 100644
--- a/arch/arm/mach-tegra/nvrm/io/common/nvrm_dma.c
+++ b/arch/arm/mach-tegra/nvrm/io/common/nvrm_dma.c
@@ -236,7 +236,7 @@ NvError NvRmDmaStartDmaTransfer(NvRmDmaHandle dma, NvRmDmaClientBuffer *b,
return NvError_NotSupported;
}
- action = kmalloc(sizeof(*action), GFP_KERNEL);
+ action = kzalloc(sizeof(*action), GFP_KERNEL);
if (!action) {
pr_debug("%s: insufficient memory\n", __func__);
return NvError_InsufficientMemory;