Received: by 2002:a25:e7d8:0:0:0:0:0 with SMTP id e207csp2708617ybh; Mon, 16 Mar 2020 08:15:07 -0700 (PDT) X-Google-Smtp-Source: ADFU+vuhnRov/7zevQT6+Vq56ombWEZcWHcPSLpsp/7GUWFcKUtv9uIcNC96UIFk4/0VEZ1p3LN5 X-Received: by 2002:aca:ad93:: with SMTP id w141mr49677oie.54.1584371707342; Mon, 16 Mar 2020 08:15:07 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1584371707; cv=none; d=google.com; s=arc-20160816; b=JXpuVclInVb4QBOOTwGrUwocpqw/3VsfGBTq2wurFwZY71oMkia4Z8+/ftw2gCBs08 a/Sc6z2EX1cUVWVjUhAYa3Ya6ILs9ax5XAVHs8DZbjiI6WtjrCHQh4EILa2sLqH42RgD vmB2HHDTz9s/Wl0pft7xjhl8x5SpxXgDerso7INui5+I0sYntqnCw0zY8YGGId9qZeMT 5uOE2YfLaNU+3cSODnHhhnUF9TVvZbe4gL0txFnCMFhRuuVnziaQcA5oFQB3KzHUDC2O hjmhahqUXOJ4tbk1/cnXniYVoDVNG0HoeCWOKt63GNVyUpARR69p7sKsEJGrt7SZ30+I nRIQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-transfer-encoding:content-disposition:mime-version :references:message-id:subject:to:from:date:ironport-sdr :ironport-sdr; bh=aL0vP4ofnXspd3VZjEEqpxQxuDHDjii0BMr/NiJO13g=; b=yKL2emZMp7Vbu1BnPiO0dUCw9HZeI71jie8v7v1+W03iUe7uYDBRIAjEjs4CXDSogF KJ0jrYU8Oh3edNb/OZ3JyxyLkNxFwSBg0RUwisT7JreKB942lm81N7dynrSll/rSe2Ff Gqa3p0vagTVFVoVEBTcR1TrtC+y8d8Kd9uGz+tqR969Ew2VpzXT3+PqweGC1K6+x8DSF o6Ceco+oTBCmBo013C0G4Ic8FO183WSHZLblp4Mb59Qz7qmQ9G1rw+xOr464Vzjr3ui1 /W7UJLmEkLZhRsC9bkRgDjANxgJHCfLPOmsGSf8+0l3IugmPvjWcqJuloIJbSOdzC5VM xd2Q== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 48si106265otv.320.2020.03.16.08.14.54; Mon, 16 Mar 2020 08:15:07 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1731786AbgCPPOR (ORCPT + 99 others); Mon, 16 Mar 2020 11:14:17 -0400 Received: from mga03.intel.com ([134.134.136.65]:61876 "EHLO mga03.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1731631AbgCPPOR (ORCPT ); Mon, 16 Mar 2020 11:14:17 -0400 IronPort-SDR: bWdQ6Dfk4JEYn31xf3c5Xwp29evPuMvyXky3178m7/2Pq0oRDFGSRQK+u0sExH/tcGHI7HDViY tcaRby6mYBmg== X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga002.jf.intel.com ([10.7.209.21]) by orsmga103.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 16 Mar 2020 08:14:16 -0700 IronPort-SDR: SMrdSI+w47upSYJuzeWVXhH/NRV+HgwXOk6Ud/Sh2F8w0MinBcB7rAYKoAxxq9j0TzGHZ6Hr+B TSJzpG6GYyYA== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.70,560,1574150400"; d="scan'208";a="262705244" Received: from stinkbox.fi.intel.com (HELO stinkbox) ([10.237.72.174]) by orsmga002.jf.intel.com with SMTP; 16 Mar 2020 08:14:12 -0700 Received: by stinkbox (sSMTP sendmail emulation); Mon, 16 Mar 2020 17:14:12 +0200 Date: Mon, 16 Mar 2020 17:14:12 +0200 From: Ville =?iso-8859-1?Q?Syrj=E4l=E4?= To: Pankaj Bharadiya , jani.nikula@linux.intel.com, intel-gfx@lists.freedesktop.org, dri-devel@lists.freedesktop.org, airlied@linux.ie, maarten.lankhorst@linux.intel.com, tzimmermann@suse.de, mripard@kernel.org, mihail.atanassov@arm.com, linux-kernel@vger.kernel.org, ankit.k.nautiyal@intel.com Subject: Re: [RFC][PATCH 1/5] drm: Introduce scaling filter property Message-ID: <20200316151412.GS13686@intel.com> References: <20200225070545.4482-1-pankaj.laxminarayan.bharadiya@intel.com> <20200225070545.4482-2-pankaj.laxminarayan.bharadiya@intel.com> <20200310160106.GH13686@intel.com> <20200316083132.GC2363188@phenom.ffwll.local> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <20200316083132.GC2363188@phenom.ffwll.local> X-Patchwork-Hint: comment User-Agent: Mutt/1.10.1 (2018-07-13) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Mar 16, 2020 at 09:31:32AM +0100, Daniel Vetter wrote: > On Tue, Mar 10, 2020 at 06:01:06PM +0200, Ville Syrj?l? wrote: > > On Tue, Feb 25, 2020 at 12:35:41PM +0530, Pankaj Bharadiya wrote: > > > Introduce new scaling filter property to allow userspace to select > > > the driver's default scaling filter or Nearest-neighbor(NN) filter > > > for upscaling operations on crtc/plane. > > > > > > Drivers can set up this property for a plane by calling > > > drm_plane_enable_scaling_filter() and for a CRTC by calling > > > drm_crtc_enable_scaling_filter(). > > > > > > NN filter works by filling in the missing color values in the upscaled > > > image with that of the coordinate-mapped nearest source pixel value. > > > > > > NN filter for integer multiple scaling can be particularly useful for > > > for pixel art games that rely on sharp, blocky images to deliver their > > > distinctive look. > > > > > > Signed-off-by: Pankaj Bharadiya > > > Signed-off-by: Shashank Sharma > > > Signed-off-by: Ankit Nautiyal > > > --- > > > drivers/gpu/drm/drm_atomic_uapi.c | 8 +++++++ > > > drivers/gpu/drm/drm_crtc.c | 16 ++++++++++++++ > > > drivers/gpu/drm/drm_mode_config.c | 13 ++++++++++++ > > > drivers/gpu/drm/drm_plane.c | 35 +++++++++++++++++++++++++++++++ > > > include/drm/drm_crtc.h | 10 +++++++++ > > > include/drm/drm_mode_config.h | 6 ++++++ > > > include/drm/drm_plane.h | 14 +++++++++++++ > > > 7 files changed, 102 insertions(+) > > > > > > diff --git a/drivers/gpu/drm/drm_atomic_uapi.c b/drivers/gpu/drm/drm_atomic_uapi.c > > > index a1e5e262bae2..4e3c1f3176e4 100644 > > > --- a/drivers/gpu/drm/drm_atomic_uapi.c > > > +++ b/drivers/gpu/drm/drm_atomic_uapi.c > > > @@ -435,6 +435,8 @@ static int drm_atomic_crtc_set_property(struct drm_crtc *crtc, > > > return ret; > > > } else if (property == config->prop_vrr_enabled) { > > > state->vrr_enabled = val; > > > + } else if (property == config->scaling_filter_property) { > > > + state->scaling_filter = val; > > > > I think we want a per-plane/per-crtc prop for this. If we start adding > > more filters we are surely going to need different sets for different hw > > blocks. > > In the past we've only done that once we have a demonstrated need. Usually > the patch to move the property to a per-object location isn't a lot of > churn. Seems silly to not do it from the start when we already know there is hardware out there that has different capabilities per hw block. -- Ville Syrj?l? Intel