Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 63687C433EF for ; Wed, 5 Jan 2022 10:12:02 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id C4B3810EB46; Wed, 5 Jan 2022 10:12:01 +0000 (UTC) Received: from mga02.intel.com (mga02.intel.com [134.134.136.20]) by gabe.freedesktop.org (Postfix) with ESMTPS id B78A710EB41 for ; Wed, 5 Jan 2022 10:11:59 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1641377519; x=1672913519; h=message-id:date:mime-version:subject:to:references:from: in-reply-to:content-transfer-encoding; bh=D5Ld3RWkeNnnwhkmUvVCcLZr4T8NJUagqiIIA0HfL/E=; b=hGx+L2525+ZHPWpkrvlfdAYKacUK23ybFmAHiNtNA0W7AxjBqlsnOF+q iDI0dkg0lwbH1+YyC7Wr90LFxiG2Gwy0MRPWzXQ1MWV/Tg4p7QqiwCYN/ 6cv4qBQLy3Iw/ZW+cA+VTwYsSALZAwCU3PC+/jCHVci6wow1oAQ+rUU+H OFzeeXyb+S6II5SGwax7cXerB67Upad65bUHlTsvhPHKduLDJL3CYGwKU wapNpc9QC7x6gu/lmP1Uw6B2IfrrSoW2+Q3dRBWmddf6RQ8oUJVBkaMRN Wp2TciVC/Vhkl8j37IeuUvviW2gC5RZZae/rCRojRUKxax0C+gcFJOC3b Q==; X-IronPort-AV: E=McAfee;i="6200,9189,10217"; a="229729537" X-IronPort-AV: E=Sophos;i="5.88,263,1635231600"; d="scan'208";a="229729537" Received: from orsmga006.jf.intel.com ([10.7.209.51]) by orsmga101.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 05 Jan 2022 02:11:59 -0800 X-IronPort-AV: E=Sophos;i="5.88,263,1635231600"; d="scan'208";a="472441381" Received: from jwebb-mobl1.ger.corp.intel.com (HELO [10.213.202.78]) ([10.213.202.78]) by orsmga006-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 05 Jan 2022 02:11:57 -0800 Message-ID: <170a7507-ff7e-204f-eba3-89571ab87842@linux.intel.com> Date: Wed, 5 Jan 2022 10:11:56 +0000 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.3.1 Content-Language: en-US To: Jani Nikula , intel-gfx@lists.freedesktop.org References: <20220105100520.976092-1-jani.nikula@intel.com> <20220105100520.976092-2-jani.nikula@intel.com> From: Tvrtko Ursulin Organization: Intel Corporation UK Plc In-Reply-To: <20220105100520.976092-2-jani.nikula@intel.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [Intel-gfx] [PATCH 2/2] drm/i915/uncore: rename i915_reg_read_ioctl intel_uncore_reg_read_ioctl X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Intel graphics driver community testing & development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: intel-gfx-bounces@lists.freedesktop.org Sender: "Intel-gfx" On 05/01/2022 10:05, Jani Nikula wrote: > Follow the usual naming convention. But intel_uncore_ prefix usually means functions takes intel_uncore as the first argument. Maybe solution here is that i915_reg_read_ioctl does not belong in intel_uncore.c, it being the UAPI layer thing? I guess arguments could be made for either way. Regards, Tvrtko > Signed-off-by: Jani Nikula > --- > drivers/gpu/drm/i915/i915_driver.c | 2 +- > drivers/gpu/drm/i915/intel_uncore.c | 4 ++-- > drivers/gpu/drm/i915/intel_uncore.h | 4 ++-- > 3 files changed, 5 insertions(+), 5 deletions(-) > > diff --git a/drivers/gpu/drm/i915/i915_driver.c b/drivers/gpu/drm/i915/i915_driver.c > index 95174938b160..f9a494e159dc 100644 > --- a/drivers/gpu/drm/i915/i915_driver.c > +++ b/drivers/gpu/drm/i915/i915_driver.c > @@ -1805,7 +1805,7 @@ static const struct drm_ioctl_desc i915_ioctls[] = { > DRM_IOCTL_DEF_DRV(I915_GEM_WAIT, i915_gem_wait_ioctl, DRM_RENDER_ALLOW), > DRM_IOCTL_DEF_DRV(I915_GEM_CONTEXT_CREATE_EXT, i915_gem_context_create_ioctl, DRM_RENDER_ALLOW), > DRM_IOCTL_DEF_DRV(I915_GEM_CONTEXT_DESTROY, i915_gem_context_destroy_ioctl, DRM_RENDER_ALLOW), > - DRM_IOCTL_DEF_DRV(I915_REG_READ, i915_reg_read_ioctl, DRM_RENDER_ALLOW), > + DRM_IOCTL_DEF_DRV(I915_REG_READ, intel_uncore_reg_read_ioctl, DRM_RENDER_ALLOW), > DRM_IOCTL_DEF_DRV(I915_GET_RESET_STATS, i915_gem_context_reset_stats_ioctl, DRM_RENDER_ALLOW), > DRM_IOCTL_DEF_DRV(I915_GEM_USERPTR, i915_gem_userptr_ioctl, DRM_RENDER_ALLOW), > DRM_IOCTL_DEF_DRV(I915_GEM_CONTEXT_GETPARAM, i915_gem_context_getparam_ioctl, DRM_RENDER_ALLOW), > diff --git a/drivers/gpu/drm/i915/intel_uncore.c b/drivers/gpu/drm/i915/intel_uncore.c > index fc25ebf1a593..33f95bb2d3d5 100644 > --- a/drivers/gpu/drm/i915/intel_uncore.c > +++ b/drivers/gpu/drm/i915/intel_uncore.c > @@ -2269,8 +2269,8 @@ static const struct reg_whitelist { > .size = 8 > } }; > > -int i915_reg_read_ioctl(struct drm_device *dev, > - void *data, struct drm_file *file) > +int intel_uncore_reg_read_ioctl(struct drm_device *dev, > + void *data, struct drm_file *file) > { > struct drm_i915_private *i915 = to_i915(dev); > struct intel_uncore *uncore = &i915->uncore; > diff --git a/drivers/gpu/drm/i915/intel_uncore.h b/drivers/gpu/drm/i915/intel_uncore.h > index 3a87bbd906f8..697ac4586159 100644 > --- a/drivers/gpu/drm/i915/intel_uncore.h > +++ b/drivers/gpu/drm/i915/intel_uncore.h > @@ -457,7 +457,7 @@ static inline int intel_uncore_write_and_verify(struct intel_uncore *uncore, > #define raw_reg_write(base, reg, value) \ > writel(value, base + i915_mmio_reg_offset(reg)) > > -int i915_reg_read_ioctl(struct drm_device *dev, void *data, > - struct drm_file *file); > +int intel_uncore_reg_read_ioctl(struct drm_device *dev, void *data, > + struct drm_file *file); > > #endif /* !__INTEL_UNCORE_H__ */ >