From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-15.3 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER,INCLUDES_PATCH, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,USER_AGENT_SANE_1 autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 93C11C433DB for ; Tue, 23 Mar 2021 19:28:45 +0000 (UTC) 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 mail.kernel.org (Postfix) with ESMTPS id 4D7616192B for ; Tue, 23 Mar 2021 19:28:45 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 4D7616192B Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=lst.de Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=intel-gfx-bounces@lists.freedesktop.org Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id DAD2B6E943; Tue, 23 Mar 2021 19:28:44 +0000 (UTC) Received: from verein.lst.de (verein.lst.de [213.95.11.211]) by gabe.freedesktop.org (Postfix) with ESMTPS id A63486E943; Tue, 23 Mar 2021 19:28:43 +0000 (UTC) Received: by verein.lst.de (Postfix, from userid 2407) id 040C368BFE; Tue, 23 Mar 2021 20:28:41 +0100 (CET) Date: Tue, 23 Mar 2021 20:28:40 +0100 From: Christoph Hellwig To: Jason Gunthorpe Message-ID: <20210323192840.GN17735@lst.de> References: <0-v1-7dedf20b2b75+4f785-vfio2_jgg@nvidia.com> <16-v1-7dedf20b2b75+4f785-vfio2_jgg@nvidia.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <16-v1-7dedf20b2b75+4f785-vfio2_jgg@nvidia.com> User-Agent: Mutt/1.5.17 (2007-11-01) Subject: Re: [Intel-gfx] [PATCH 16/18] vfio/gvt: Use mdev_get_type_group_id() 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: , Cc: Max Gurtovoy , "Raj, Ashok" , David Airlie , Leon Romanovsky , intel-gfx@lists.freedesktop.org, dri-devel@lists.freedesktop.org, Dan Williams , intel-gvt-dev@lists.freedesktop.org, Christoph Hellwig , Tarun Gupta Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: intel-gfx-bounces@lists.freedesktop.org Sender: "Intel-gfx" On Tue, Mar 23, 2021 at 02:55:33PM -0300, Jason Gunthorpe wrote: > intel_gvt_init_vgpu_type_groups() makes gvt->types 1:1 with the > supported_type_groups array, so the type_group_id is also the index into > gvt->types. Use it directly and remove the string matching. > > Signed-off-by: Jason Gunthorpe > --- > drivers/gpu/drm/i915/gvt/gvt.c | 24 +++++++----------------- > drivers/gpu/drm/i915/gvt/gvt.h | 4 ++-- > drivers/gpu/drm/i915/gvt/kvmgt.c | 5 ++--- > 3 files changed, 11 insertions(+), 22 deletions(-) Looks good, Reviewed-by: Christoph Hellwig _______________________________________________ Intel-gfx mailing list Intel-gfx@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/intel-gfx