Received: by 2002:a6b:fb09:0:0:0:0:0 with SMTP id h9csp4720078iog; Wed, 22 Jun 2022 04:39:16 -0700 (PDT) X-Google-Smtp-Source: AGRyM1sSV9xge5IjwiBLpbh3vuRYdoSZXRsodtUY5lngvc8QArx2dnF5zbr8nJeaVvhCJCtGStjA X-Received: by 2002:aa7:cdd1:0:b0:435:750f:7c75 with SMTP id h17-20020aa7cdd1000000b00435750f7c75mr3592282edw.91.1655897956501; Wed, 22 Jun 2022 04:39:16 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1655897956; cv=none; d=google.com; s=arc-20160816; b=NpP17vEu3+XMUwd9jBwauyMUfP9tBPBDIyQFyoZ/Su24JCfGjzhuKKW6ZHjdOypIkL YXf86Bn2pnHZoIw+Eqlja6t739V5nKtgx/r+JQ+TmQa0o0fdB52wW9wsIk8+wMETDGr+ pz2jsKuu7EO3oHE6tZZN2uW/CfRQoZcDViHCUtxy8R6RYN6S1PMIzHOXHbhvCa3CB4i2 Cxl1BoGA5OE1D7fvlxnljeAHSffnqtLvKEbIfeDZkoKPuLBwYRy2Z6dI8NBZyVELTVqx FJSvRe7FrqB7WBRQbKmKRlPXAv/g99xxsQbQIOn2g6cYvqpnhYvjCHaxVjC44+8NJlTN Abzw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to:from :references:cc:to:content-language:subject:user-agent:mime-version :date:message-id:dkim-signature; bh=+xrZUjPPEGld3+v2b4fq0ZJMrkk9GW3A0GJcVLlt58o=; b=blTljtYq/Mllh7MI620+WlaNiGG5fFjgojdIASWA1wewCFTw9Zw7+xQXfHqtlZq8UG e8FuAEPiHkjksSKwZ1OVSt/6Lh3bcR4uOhsbL5+bQjFRf/aVTgCL7uGrELUnpvaBZKTw 8Uz3oc5+y66QmdB0n7lbTqe/yp8w2sQIcFsQLdxgbuZLwvl07VZsF/1HB2nhDqFJhDtT 1hp8Cc05gDinMu1KiBMffFNKtA88htdLMRXPddw5FTCQKLZVfseRy2oZ25dtICnDsvBK 9BeJzLyi+A+9t2GM/pjy53GIa4ZChj26xfrF2R8oQX1p3j0jvP6VrZIWXfNN6oPbV4jA 0xcw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=jsKkISor; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id b12-20020a0564021f0c00b004358c420d5fsi7699182edb.302.2022.06.22.04.38.50; Wed, 22 Jun 2022 04:39:16 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=jsKkISor; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234528AbiFVKp4 (ORCPT + 99 others); Wed, 22 Jun 2022 06:45:56 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:33982 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232630AbiFVKpz (ORCPT ); Wed, 22 Jun 2022 06:45:55 -0400 Received: from mga04.intel.com (mga04.intel.com [192.55.52.120]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id E80D92FE50 for ; Wed, 22 Jun 2022 03:45:54 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1655894754; x=1687430754; h=message-id:date:mime-version:subject:to:cc:references: from:in-reply-to:content-transfer-encoding; bh=EnIwRYdqMUiifM9lQEkNSaL0Jx7fpMpLKv6tMUllslk=; b=jsKkISoriF5cm1PVtrNG0mU0NkJTXh1FxsStM9Allo/rgEZd60Ex0Cw9 +YwEp1ZerVvh7ZKTFbaL+jF20XUf9FSOzsJepYATn/aJqn2LR1upctPZF 9ZabHaDcpP2VGIxNf+Iw0HzV7+kiZxenmzovGlDKAABktTVoaYe/39PPr DRrV5wKW4xjKuoRjIJucJcUzN4c7XSF2GmLup48VS0slSL3bz5veI7s0W uxbe3FD+SJt2SaxE6Tkf6UCj/krjXHxZPKW2rumQtOcXfi1YgO13QcrVW MPN6MmDZXNJ80SXbLd/XSSVAFwt5IxQKc1BKDmKk+Z6VT4PXG6vtgeoqn w==; X-IronPort-AV: E=McAfee;i="6400,9594,10385"; a="279151134" X-IronPort-AV: E=Sophos;i="5.92,212,1650956400"; d="scan'208";a="279151134" Received: from fmsmga002.fm.intel.com ([10.253.24.26]) by fmsmga104.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 22 Jun 2022 03:45:54 -0700 X-IronPort-AV: E=Sophos;i="5.92,212,1650956400"; d="scan'208";a="690438517" Received: from wterliko-mobl.ger.corp.intel.com (HELO [10.249.254.201]) ([10.249.254.201]) by fmsmga002-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 22 Jun 2022 03:45:52 -0700 Message-ID: <783ff8b6-0128-45e1-5705-7681f314db6c@linux.intel.com> Date: Wed, 22 Jun 2022 12:45:50 +0200 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.9.0 Subject: Re: [PATCH v8 02/10] drm/i915: limit ttm to dma32 for i965G[M] Content-Language: en-US To: Robert Beckett , dri-devel@lists.freedesktop.org, intel-gfx@lists.freedesktop.org, Jani Nikula , Joonas Lahtinen , Rodrigo Vivi , Tvrtko Ursulin , David Airlie , Daniel Vetter Cc: kernel@collabora.com, Matthew Auld , linux-kernel@vger.kernel.org References: <20220621200058.3536182-1-bob.beckett@collabora.com> <20220621200058.3536182-3-bob.beckett@collabora.com> From: =?UTF-8?Q?Thomas_Hellstr=c3=b6m?= In-Reply-To: <20220621200058.3536182-3-bob.beckett@collabora.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-4.9 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_EF,NICE_REPLY_A,RCVD_IN_DNSWL_MED, SPF_HELO_NONE,SPF_NONE,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 6/21/22 22:00, Robert Beckett wrote: > i965G[M] cannot relocate objects above 4GiB. > Ensure ttm uses dma32 on these systems. > > Signed-off-by: Robert Beckett LGTM. Reviewed-by: Thomas Hellström > --- > drivers/gpu/drm/i915/intel_region_ttm.c | 7 ++++++- > 1 file changed, 6 insertions(+), 1 deletion(-) > > diff --git a/drivers/gpu/drm/i915/intel_region_ttm.c b/drivers/gpu/drm/i915/intel_region_ttm.c > index 62ff77445b01..fd2ecfdd8fa1 100644 > --- a/drivers/gpu/drm/i915/intel_region_ttm.c > +++ b/drivers/gpu/drm/i915/intel_region_ttm.c > @@ -32,10 +32,15 @@ > int intel_region_ttm_device_init(struct drm_i915_private *dev_priv) > { > struct drm_device *drm = &dev_priv->drm; > + bool use_dma32 = false; > + > + /* i965g[m] cannot relocate objects above 4GiB. */ > + if (IS_I965GM(dev_priv) || IS_I965G(dev_priv)) > + use_dma32 = true; > > return ttm_device_init(&dev_priv->bdev, i915_ttm_driver(), > drm->dev, drm->anon_inode->i_mapping, > - drm->vma_offset_manager, false, false); > + drm->vma_offset_manager, false, use_dma32); > } > > /**