lkml.org 
[lkml]   [2016]   [Apr]   [13]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
SubjectRe: [PATCH] coresight: no need to do the forced type conversion
From
On 13 April 2016 at 03:09, lipengcheng <lipengcheng8@huawei.com> wrote:
> activated and enable are already unsigned type,
> no need to change them to unsigned.
>
> Signed-off-by: Li Pengcheng <lipengcheng8@huawei.com>
> Signed-off-by: Li Zhong <lizhong11@hisilicon.com>
> ---
> drivers/hwtracing/coresight/coresight.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/hwtracing/coresight/coresight.c b/drivers/hwtracing/coresight/coresight.c
> index bba9f3d..617574a 100644
> --- a/drivers/hwtracing/coresight/coresight.c
> +++ b/drivers/hwtracing/coresight/coresight.c
> @@ -538,7 +538,7 @@ static ssize_t enable_sink_show(struct device *dev,
> {
> struct coresight_device *csdev = to_coresight_device(dev);
>
> - return scnprintf(buf, PAGE_SIZE, "%u\n", (unsigned)csdev->activated);
> + return scnprintf(buf, PAGE_SIZE, "%u\n", csdev->activated);
> }
>
> static ssize_t enable_sink_store(struct device *dev,
> @@ -568,7 +568,7 @@ static ssize_t enable_source_show(struct device *dev,
> {
> struct coresight_device *csdev = to_coresight_device(dev);
>
> - return scnprintf(buf, PAGE_SIZE, "%u\n", (unsigned)csdev->enable);
> + return scnprintf(buf, PAGE_SIZE, "%u\n", csdev->enable);
> }

Applied - thanks.
Mathieu

>
> static ssize_t enable_source_store(struct device *dev,
> --
> 1.8.3.2
>

\
 
 \ /
  Last update: 2016-04-13 18:01    [W:0.031 / U:0.160 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site