Message ID | 20190708104520.24217-4-jjhiblot@ti.com |
---|---|
State | Superseded |
Headers | show
Delivered-To: patch@linaro.org Received: by 2002:a92:4782:0:0:0:0:0 with SMTP id e2csp6983026ilk; Mon, 8 Jul 2019 03:45:40 -0700 (PDT) X-Google-Smtp-Source: APXvYqwKeDOX7nT8pHzWTRSFQDP1AV4hQEcsVviv1V3jQ+rMkk3IuMYbc3RbW/HkBAYl7OdjevNI X-Received: by 2002:a63:6fcf:: with SMTP id k198mr22537043pgc.276.1562582740669; Mon, 08 Jul 2019 03:45:40 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1562582740; cv=none; d=google.com; s=arc-20160816; b=j+8efnXEkI0V9cHoLvuuaUgm40Vg6TLX7cBG88Wpa8PWQFsg6PwsOa7qfo4h6Pe9KL 7O0+GtM2cvbwfKfnAodV8oGPf7GDdmT3vpVo6e9aarYQwbDng6KFaok8E3zdBnTMcX5e ozZe/qk6r1Q6clF5YPfczdP13WXGHq4XkK1Du7MPsIIS+pvy+DHjxPBK9u9q9Vksuyu6 gL6Aif9ksI7Mk4shq5USRzWUZ6PXQJ/k5fO4IVRfU5K2o2EPi/oFP2G6Xczmj9MiSqdS yraLxbMO73RCsW+g2fp5BgXIM+ZSl/CMXXkMkA3vzkt4A3jPKqtQMLT9wRLYbgbYyliS R+0A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:content-transfer-encoding:cc:list-subscribe :list-help:list-post:list-archive:list-unsubscribe:list-id :precedence:mime-version:references:in-reply-to:message-id:date :subject:to:from:delivered-to; bh=TDHIy4bQRuNHN/UK/UVlmTW3J3+/+T00Q2zpxxYzl9I=; b=GpPi7nQYJ96YpSbS7Lk5whpnjehEesuxTyvLLHgNV/imGm48pc1ur0eitDkBSIlx1n IemcEcn4LVizTMUbuYt2j+xcWF9pSKXg/iIjPOcT2eoGtTVGCMbDpRGbI/4bi6aTGG7H YiqwVAEYL9byS7x4tX1LRvBeniA2jOTqWDUhIZctfXV6atoAmcpAXkX3M2vGkTcSUH2k ZgEB25oATndLBexUJew+joFtml77H4ee6xFx+GD3Bnb76xS49E69kMRvMOpFrrwPPYL6 CC/iw08sh/RTRL3/rXhrBIC83lwJEuVxtxFcghZz3CTccMW1ZA3ViFRgqcl2UQ64Hr2t HqJw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of dri-devel-bounces@lists.freedesktop.org designates 2610:10:20:722:a800:ff:fe36:1795 as permitted sender) smtp.mailfrom=dri-devel-bounces@lists.freedesktop.org; dmarc=fail (p=QUARANTINE sp=NONE dis=NONE) header.from=ti.com Return-Path: <dri-devel-bounces@lists.freedesktop.org> Received: from gabe.freedesktop.org (gabe.freedesktop.org. [2610:10:20:722:a800:ff:fe36:1795]) by mx.google.com with ESMTPS id r185si4511062pgr.506.2019.07.08.03.45.40 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Mon, 08 Jul 2019 03:45:40 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of dri-devel-bounces@lists.freedesktop.org designates 2610:10:20:722:a800:ff:fe36:1795 as permitted sender) client-ip=2610:10:20:722:a800:ff:fe36:1795; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of dri-devel-bounces@lists.freedesktop.org designates 2610:10:20:722:a800:ff:fe36:1795 as permitted sender) smtp.mailfrom=dri-devel-bounces@lists.freedesktop.org; dmarc=fail (p=QUARANTINE sp=NONE dis=NONE) header.from=ti.com Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 61B6289C84; Mon, 8 Jul 2019 10:45:39 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from lelv0142.ext.ti.com (lelv0142.ext.ti.com [198.47.23.249]) by gabe.freedesktop.org (Postfix) with ESMTPS id 619A289C68 for <dri-devel@lists.freedesktop.org>; Mon, 8 Jul 2019 10:45:32 +0000 (UTC) Received: from fllv0035.itg.ti.com ([10.64.41.0]) by lelv0142.ext.ti.com (8.15.2/8.15.2) with ESMTP id x68AjV6T005778; Mon, 8 Jul 2019 05:45:31 -0500 Received: from DLEE114.ent.ti.com (dlee114.ent.ti.com [157.170.170.25]) by fllv0035.itg.ti.com (8.15.2/8.15.2) with ESMTPS id x68AjVMf089628 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=FAIL); Mon, 8 Jul 2019 05:45:31 -0500 Received: from DLEE109.ent.ti.com (157.170.170.41) by DLEE114.ent.ti.com (157.170.170.25) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1713.5; Mon, 8 Jul 2019 05:45:30 -0500 Received: from fllv0040.itg.ti.com (10.64.41.20) by DLEE109.ent.ti.com (157.170.170.41) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1713.5 via Frontend Transport; Mon, 8 Jul 2019 05:45:30 -0500 Received: from localhost (ileax41-snat.itg.ti.com [10.172.224.153]) by fllv0040.itg.ti.com (8.15.2/8.15.2) with ESMTP id x68AjU2J100316; Mon, 8 Jul 2019 05:45:30 -0500 From: Jean-Jacques Hiblot <jjhiblot@ti.com> To: <tomi.valkeinen@ti.com>, <airlied@linux.ie>, <daniel@ffwll.ch>, <dri-devel@lists.freedesktop.org> Subject: [PATCH v2 3/8] drm/omap: accept NULL for dma_addr in omap_gem_pin Date: Mon, 8 Jul 2019 12:45:15 +0200 Message-ID: <20190708104520.24217-4-jjhiblot@ti.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20190708104520.24217-1-jjhiblot@ti.com> References: <20190708104520.24217-1-jjhiblot@ti.com> MIME-Version: 1.0 X-EXCLAIMER-MD-CONFIG: e1e8a2fd-e40a-4ac6-ac9b-f7e9cc9ee180 X-Mailman-Original-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ti.com; s=ti-com-17Q1; t=1562582731; bh=jlgb27R7PVNb2+coCp4QHw61HjPEjybhkNB/01z9lz0=; h=From:To:CC:Subject:Date:In-Reply-To:References; b=OJN70SUd/N4He42X0nZd9U8Fc0Lvn5y8fuw8IbqYvJ0ffEddbvKGF4YdP2bKd4on9 68NFU/5PxKx31h1LkqCA+o/yXuzsYuQmNkZ+LTKCzQ5yT21RyHkc4LXLDERwJvIFJd BX/rOZDiHEEYdvvoD2akEaf6UH3cXbFEbsY0po8k= X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Direct Rendering Infrastructure - Development <dri-devel.lists.freedesktop.org> List-Unsubscribe: <https://lists.freedesktop.org/mailman/options/dri-devel>, <mailto:dri-devel-request@lists.freedesktop.org?subject=unsubscribe> List-Archive: <https://lists.freedesktop.org/archives/dri-devel> List-Post: <mailto:dri-devel@lists.freedesktop.org> List-Help: <mailto:dri-devel-request@lists.freedesktop.org?subject=help> List-Subscribe: <https://lists.freedesktop.org/mailman/listinfo/dri-devel>, <mailto:dri-devel-request@lists.freedesktop.org?subject=subscribe> Cc: jsarha@ti.com Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: base64 Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" <dri-devel-bounces@lists.freedesktop.org> |
Series |
None
|
expand
|
diff --git a/drivers/gpu/drm/omapdrm/omap_gem.c b/drivers/gpu/drm/omapdrm/omap_gem.c index 3071e815da73..2ac83cdbb15a 100644 --- a/drivers/gpu/drm/omapdrm/omap_gem.c +++ b/drivers/gpu/drm/omapdrm/omap_gem.c @@ -817,9 +817,11 @@ int omap_gem_pin(struct drm_gem_object *obj, dma_addr_t *dma_addr) refcount_inc(&omap_obj->dma_addr_cnt); } - *dma_addr = omap_obj->dma_addr; + if (dma_addr) + *dma_addr = omap_obj->dma_addr; } else if (omap_gem_is_contiguous(omap_obj)) { - *dma_addr = omap_obj->dma_addr; + if (dma_addr) + *dma_addr = omap_obj->dma_addr; } else { ret = -EINVAL; goto fail;