Received: by 2002:a05:6a10:6744:0:0:0:0 with SMTP id w4csp795304pxu; Wed, 14 Oct 2020 14:05:00 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxXucwEhYMQdLYVDjVkZUh7vTIJoD5QjHn9JvLaM/dhJhGAkEAkIo/kgHA8MUerSr8eGJZb X-Received: by 2002:aa7:cf95:: with SMTP id z21mr919184edx.346.1602709500203; Wed, 14 Oct 2020 14:05:00 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1602709500; cv=none; d=google.com; s=arc-20160816; b=Mb9BpAU3WL6GZ1290IiC1HP77LHjcChzrOiVsaS8FJddzRhGErAnWmJcmDpvf1/Lnt Qys2JQROVsQRHMKPW0s101OnrC1QLo2g9sMZG+jJTQWLfFBuOc9z+ErZsa7mOnlln6ac edTg5qFQpEEsYvl8SQVaBi81lAmk5NL6ERgTIZHwYmWg63MM/W4psOfe9xwjAZYX1ZUR gg3zlWSw9r3jZtMFEpKtmM4KOzuP5LEYTlhYz9TMMEatk+fvV9izXSXtLozukfSEpXQ+ sZ5vQYns5lZ9wX7y4mLqWsuqZKSee0kJC8G/kV3rURuUJqwgacllK73yrWqU3p4yLF/d L+kA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :organization:references:in-reply-to:message-id:subject:cc:to:from :date; bh=PwTkRLtFRdOlzubk0Gt2oxvALNDVSxFw+BPBTewjipk=; b=q1EFzfWd7Goz2z+JFGhEF+R3n9TVovW9G3Ut+xmAwuRaNKAYPgtPfSrfpSOuc9nJx6 B3+qSVX9m8wWCLl8lDzJSs61lEJiFDrF7anwUGJjndF6LXFchrgTBFwyE9rhs+RJxNFJ vtfya+ECE2VDWrFAwyZVCEUE1s+Vc56y/dUN5B8/vTdon+5BktEyHDJEqOKrwJpAjKuL z9Tt/myKlN8cG5+f40UzlO7twbdzzB79O4lHWkqfvV2/u5gHfoLWCfu5+lyeg2hvntBk weP/P8VXFQ4+t2jkiuUl+BG9a7hUyOc3C0ElhvMGiHznP1zoKSVYv8ZNJ0WalHCuBfBA Biqw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id u18si547571edf.133.2020.10.14.14.04.37; Wed, 14 Oct 2020 14:05:00 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729577AbgJNMCu convert rfc822-to-8bit (ORCPT + 99 others); Wed, 14 Oct 2020 08:02:50 -0400 Received: from mx2.suse.de ([195.135.220.15]:40256 "EHLO mx2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728627AbgJNMCu (ORCPT ); Wed, 14 Oct 2020 08:02:50 -0400 X-Virus-Scanned: by amavisd-new at test-mx.suse.de Received: from relay2.suse.de (unknown [195.135.221.27]) by mx2.suse.de (Postfix) with ESMTP id 8F5A3AC6D; Wed, 14 Oct 2020 12:02:48 +0000 (UTC) Date: Wed, 14 Oct 2020 14:02:47 +0200 From: Thomas Zimmermann To: Tian Tao Cc: , , , , , , , , Subject: Re: [PATCH drm/hisilicon 2/2] drm/hisilicon: Use the same style of variable type in hibmc_drm_drv Message-ID: <20201014140247.154ed8ee@linux-uq9g> In-Reply-To: <1601449988-41463-3-git-send-email-tiantao6@hisilicon.com> References: <1601449988-41463-1-git-send-email-tiantao6@hisilicon.com> <1601449988-41463-3-git-send-email-tiantao6@hisilicon.com> Organization: SUSE Software Solutions Germany GmbH X-Mailer: Claws Mail 3.17.7 (GTK+ 2.24.32; x86_64-suse-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8BIT Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi On Wed, 30 Sep 2020 15:13:08 +0800 Tian Tao wrote: > Consistently Use the same style of variable type in hibmc_drm_de.c and > hibmc_drm_de.h. > > Signed-off-by: Tian Tao > --- > drivers/gpu/drm/hisilicon/hibmc/hibmc_drm_drv.c | 13 ++++++------- > drivers/gpu/drm/hisilicon/hibmc/hibmc_drm_drv.h | 8 ++++---- > 2 files changed, 10 insertions(+), 11 deletions(-) > > diff --git a/drivers/gpu/drm/hisilicon/hibmc/hibmc_drm_drv.c > b/drivers/gpu/drm/hisilicon/hibmc/hibmc_drm_drv.c index 5632bce..0c1b40d > 100644 --- a/drivers/gpu/drm/hisilicon/hibmc/hibmc_drm_drv.c > +++ b/drivers/gpu/drm/hisilicon/hibmc/hibmc_drm_drv.c > @@ -121,12 +121,11 @@ static void hibmc_kms_fini(struct hibmc_drm_private > *priv) /* > * It can operate in one of three modes: 0, 1 or Sleep. > */ > -void hibmc_set_power_mode(struct hibmc_drm_private *priv, > - unsigned int power_mode) > +void hibmc_set_power_mode(struct hibmc_drm_private *priv, u32 power_mode) > { > - unsigned int control_value = 0; > + u32 control_value = 0; > void __iomem *mmio = priv->mmio; > - unsigned int input = 1; > + u32 input = 1; > > if (power_mode > HIBMC_PW_MODE_CTL_MODE_SLEEP) > return; > @@ -144,8 +143,8 @@ void hibmc_set_power_mode(struct hibmc_drm_private > *priv, > void hibmc_set_current_gate(struct hibmc_drm_private *priv, unsigned int > gate) { > - unsigned int gate_reg; > - unsigned int mode; > + u32 gate_reg; > + u32 mode; > void __iomem *mmio = priv->mmio; > > /* Get current power mode. */ > @@ -170,7 +169,7 @@ void hibmc_set_current_gate(struct hibmc_drm_private > *priv, unsigned int gate) > static void hibmc_hw_config(struct hibmc_drm_private *priv) > { > - unsigned int reg; > + u32 reg; > > /* On hardware reset, power mode 0 is default. */ > hibmc_set_power_mode(priv, HIBMC_PW_MODE_CTL_MODE_MODE0); > diff --git a/drivers/gpu/drm/hisilicon/hibmc/hibmc_drm_drv.h > b/drivers/gpu/drm/hisilicon/hibmc/hibmc_drm_drv.h index 6a63502..5c4030d > 100644 --- a/drivers/gpu/drm/hisilicon/hibmc/hibmc_drm_drv.h > +++ b/drivers/gpu/drm/hisilicon/hibmc/hibmc_drm_drv.h > @@ -33,8 +33,8 @@ struct hibmc_drm_private { > /* hw */ > void __iomem *mmio; > void __iomem *fb_map; > - unsigned long fb_base; > - unsigned long fb_size; > + u64 fb_base; > + u64 fb_size; resource_size_t would be the correct type here. With my comments addressed: Acked-by: Thomas Zimmermann Best regards Thomas > > /* drm */ > struct drm_device *dev; > @@ -56,9 +56,9 @@ static inline struct hibmc_drm_private > *to_hibmc_drm_private(struct drm_device * } > > void hibmc_set_power_mode(struct hibmc_drm_private *priv, > - unsigned int power_mode); > + u32 power_mode); > void hibmc_set_current_gate(struct hibmc_drm_private *priv, > - unsigned int gate); > + u32 gate); > > int hibmc_de_init(struct hibmc_drm_private *priv); > int hibmc_vdac_init(struct hibmc_drm_private *priv); -- Thomas Zimmermann Graphics Driver Developer SUSE Software Solutions Germany GmbH Maxfeldstr. 5, 90409 Nürnberg, Germany (HRB 36809, AG Nürnberg) Geschäftsführer: Felix Imendörffer