Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752516AbcDMPnE (ORCPT ); Wed, 13 Apr 2016 11:43:04 -0400 Received: from mail-lf0-f51.google.com ([209.85.215.51]:33950 "EHLO mail-lf0-f51.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752490AbcDMPnC (ORCPT ); Wed, 13 Apr 2016 11:43:02 -0400 MIME-Version: 1.0 In-Reply-To: <1460538555-138517-1-git-send-email-lipengcheng8@huawei.com> References: <1460538555-138517-1-git-send-email-lipengcheng8@huawei.com> Date: Wed, 13 Apr 2016 09:42:59 -0600 Message-ID: Subject: Re: [PATCH] coresight: no need to do the forced type conversion From: Mathieu Poirier To: lipengcheng Cc: "linux-arm-kernel@lists.infradead.org" , "linux-kernel@vger.kernel.org" , lizhong11@hisilicon.com, Feng Chen , liuyongfu@hisilicon.com, Dan Zhao Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1375 Lines: 39 On 13 April 2016 at 03:09, lipengcheng wrote: > activated and enable are already unsigned type, > no need to change them to unsigned. > > Signed-off-by: Li Pengcheng > Signed-off-by: Li Zhong > --- > 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 >