]> git.karo-electronics.de Git - linux-beck.git/commitdiff
coresight: tmc: Remove duplicate memset
authorSuzuki K. Poulose <Suzuki.Poulose@arm.com>
Tue, 29 Nov 2016 16:47:17 +0000 (09:47 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 29 Nov 2016 19:05:32 +0000 (20:05 +0100)
The tmc_etr_enable_hw() fills the buffer with 0's before enabling
the hardware. So, we don't need an explicit memset() in
tmc_enable_etr_sink_sysfs() before calling the tmc_etr_enable_hw().
This patch removes the explicit memset from tmc_enable_etr_sink_sysfs.

Signed-off-by: Suzuki K Poulose <suzuki.poulose@arm.com>
Signed-off-by: Mathieu Poirier <mathieu.poirier@linaro.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/hwtracing/coresight/coresight-tmc-etr.c

index 3b84d0d38c22452f0980cccd09d1a0bf37680c19..5d312699b3b9d3a27e3039459d0c5f13097f548c 100644 (file)
@@ -150,8 +150,6 @@ static int tmc_enable_etr_sink_sysfs(struct coresight_device *csdev)
                drvdata->buf = drvdata->vaddr;
        }
 
-       memset(drvdata->vaddr, 0, drvdata->size);
-
        drvdata->mode = CS_MODE_SYSFS;
        tmc_etr_enable_hw(drvdata);
 out: