Received: by 2002:a4a:311b:0:0:0:0:0 with SMTP id k27-v6csp4533719ooa; Tue, 14 Aug 2018 07:15:09 -0700 (PDT) X-Google-Smtp-Source: AA+uWPxu4tHb9QIoGm4eoeLWi/zC74yV/X5aPH2/z6LJw1/I1ll8qTXcwYFhWzhwm5pXL2KxU/It X-Received: by 2002:a65:5784:: with SMTP id b4-v6mr21661185pgr.315.1534256109740; Tue, 14 Aug 2018 07:15:09 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1534256109; cv=none; d=google.com; s=arc-20160816; b=0OimavePhdIeoZojR+tdftoNfKndbs+9F+Roa8EcYhds96TDiLmm4zEXAn/BiCkdHh A1wGv2I7xIUMNlgoku8ewKYpRWEj7Ymv9/l52fYzZ4UlTXKWacpyJxnujFh3eHFDvqHS UnSpaJ4e8TTQ6a9tVLhJBCv8PFJhT7uAPN2ujFGZug/zsoqYyI7zy1GThPXSYWptbT9C ZWVbNwrpDmR7VKeS7xfmjDQ8TJhWQ5YjzOHjRHOPSj8vcLmX+Orl0J56kbiIC0gvrPrh 5rjGTFXu/0lXOJqHwUj3lFYkbqrzOGRWcv03x32uKxR1qzpTE+SKhAVmXRqor15ufS1w c6Ug== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:cc:to:from :dkim-signature:arc-authentication-results; bh=3YOASqYWEsAsyawC+eChHQo+vXpBa3iZZJe4U6pBGzI=; b=iTFOOK1hY2SGtqPI1LN+Rh90e6iKLX7We28A/4pMJJ/dkEw7Q16PJHZlz40omteRLE kQNTXx7KQZ4PXdsb+pG0CJJq5zQpVfztpfmEQfUdibFpH7krRtk5G5KoKyykiCT/p/GK ozE7+IdjLDBJlRrAyQ9BbgYLElJbERnqTEEbpxbF5he6iy9dZvXK8Qfkin2YFTHMZtsf cCmWpohJcotvonK79ABobqenPOHEM3Q7zpjehmwZyJpTSp+YWlkTiiPS4jfqdbZY7RuI EPZrPWrXPOsc943gvRzpgRwZ5/ofrQWq9WrzABq3oekT5OBVmIrqftSCnzLd1BoD1dan jo5Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@synopsys.com header.s=mail header.b=H+NXMFoC; 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=pass (p=NONE sp=NONE dis=NONE) header.from=synopsys.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id d10-v6si21219061pgg.341.2018.08.14.07.14.53; Tue, 14 Aug 2018 07:15:09 -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; dkim=pass header.i=@synopsys.com header.s=mail header.b=H+NXMFoC; 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=pass (p=NONE sp=NONE dis=NONE) header.from=synopsys.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1732119AbeHNQ7x (ORCPT + 99 others); Tue, 14 Aug 2018 12:59:53 -0400 Received: from smtprelay.synopsys.com ([198.182.60.111]:45664 "EHLO smtprelay.synopsys.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728458AbeHNQ7x (ORCPT ); Tue, 14 Aug 2018 12:59:53 -0400 Received: from mailhost.synopsys.com (mailhost1.synopsys.com [10.12.238.239]) by smtprelay.synopsys.com (Postfix) with ESMTP id 5FDD310C119D; Tue, 14 Aug 2018 07:12:32 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=synopsys.com; s=mail; t=1534255952; bh=b+txpZOEHf4h8yNlZzz73CQXA+OuI/U6s98MsOHuw3o=; h=From:To:Cc:Subject:Date:From; b=H+NXMFoCJEzgMgdl8OkSi+lkFGt4/0grOxfX1DLXMg67/GTiFBOhT03DxjycZJJId oYPhaFE0URZi8kybEDroWx4wsUtXogPCukX+1rgVkhNx45/xXojAH1MbcrgWegCYtS 3BAwCNe8+rLyOE02X2YbL68M8Y/FE3cU31AyMOHkecxzi+oq6vahXHM+kYs9480Pc1 5p7jLOUxYoH/zNsaM4EWnYJC+zI7YRDYDmgellYQEZ4TjOIPWG6XavM0GZU4M3KpuY Z3wuS731m310JmYlc723ZnD4UVvzEjJpJaoItqozvjTLsCqYx/uTydmUaT54GUugEY 93KBDLu63AY+A== Received: from paltsev-e7480.internal.synopsys.com (paltsev-e7480.internal.synopsys.com [10.121.8.86]) by mailhost.synopsys.com (Postfix) with ESMTP id 7931756E2; Tue, 14 Aug 2018 07:12:28 -0700 (PDT) From: Eugeniy Paltsev To: linux-snps-arc@lists.infradead.org, Lucas Stach , Christoph Hellwig Cc: linux-kernel@vger.kernel.org, Vineet Gupta , Alexey Brodkin , Russell King , Christian Gmeiner , etnaviv@lists.freedesktop.org, dri-devel@lists.freedesktop.org, Eugeniy Paltsev Subject: [RFC] etnaviv: missing dma_mask Date: Tue, 14 Aug 2018 17:12:25 +0300 Message-Id: <20180814141225.6123-1-Eugeniy.Paltsev@synopsys.com> X-Mailer: git-send-email 2.14.4 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Lucas, Christoph, After switching ARC to generic dma_noncoherent cache ops etnaviv driver start failing on dma maping functions because of dma_mask lack. So I'm wondering is it valid case to have device which is DMA capable and doesn't have dma_mask set? If not, then I guess something like that should work (at least it works for ARC): Signed-off-by: Eugeniy Paltsev --- drivers/gpu/drm/etnaviv/etnaviv_drv.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/etnaviv/etnaviv_drv.c b/drivers/gpu/drm/etnaviv/etnaviv_drv.c index 540b59fb4103..69d80937e021 100644 --- a/drivers/gpu/drm/etnaviv/etnaviv_drv.c +++ b/drivers/gpu/drm/etnaviv/etnaviv_drv.c @@ -593,7 +593,7 @@ static int etnaviv_pdev_probe(struct platform_device *pdev) struct device *dev = &pdev->dev; struct component_match *match = NULL; - dma_set_coherent_mask(&pdev->dev, DMA_BIT_MASK(32)); + dma_coerce_mask_and_coherent(&pdev->dev, DMA_BIT_MASK(32)); if (!dev->platform_data) { struct device_node *core_node; -- 2.14.4