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=-1.0 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_PASS autolearn=unavailable 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 149ECC04EB8 for ; Sun, 2 Dec 2018 06:13:20 +0000 (UTC) Received: from lists.ozlabs.org (lists.ozlabs.org [203.11.71.2]) (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 32D8A20672 for ; Sun, 2 Dec 2018 06:13:19 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 32D8A20672 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=kernel.crashing.org Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=linuxppc-dev-bounces+linuxppc-dev=archiver.kernel.org@lists.ozlabs.org Received: from lists.ozlabs.org (lists.ozlabs.org [IPv6:2401:3900:2:1::3]) by lists.ozlabs.org (Postfix) with ESMTP id 436yVN48d2zDqtt for ; Sun, 2 Dec 2018 17:13:16 +1100 (AEDT) Authentication-Results: lists.ozlabs.org; dmarc=none (p=none dis=none) header.from=kernel.crashing.org Authentication-Results: lists.ozlabs.org; spf=permerror (mailfrom) smtp.mailfrom=kernel.crashing.org (client-ip=63.228.1.57; helo=gate.crashing.org; envelope-from=benh@kernel.crashing.org; receiver=) Authentication-Results: lists.ozlabs.org; dmarc=none (p=none dis=none) header.from=kernel.crashing.org Received: from gate.crashing.org (gate.crashing.org [63.228.1.57]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by lists.ozlabs.org (Postfix) with ESMTPS id 436yS65YLtzDqgS for ; Sun, 2 Dec 2018 17:11:18 +1100 (AEDT) Received: from localhost (localhost.localdomain [127.0.0.1]) by gate.crashing.org (8.14.1/8.14.1) with ESMTP id wB26B3sd012208; Sun, 2 Dec 2018 00:11:04 -0600 Message-ID: <42b1408cafe77ebac1b1ad909db237fe34e4d177.camel@kernel.crashing.org> Subject: Re: use generic DMA mapping code in powerpc V4 From: Benjamin Herrenschmidt To: Rui Salvaterra , hch@lst.de Date: Sun, 02 Dec 2018 17:11:02 +1100 In-Reply-To: References: <20181130103222.GA23393@lst.de> Content-Type: text/plain; charset="UTF-8" User-Agent: Evolution 3.30.2 (3.30.2-2.fc29) Mime-Version: 1.0 Content-Transfer-Encoding: 7bit X-BeenThere: linuxppc-dev@lists.ozlabs.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Linux on PowerPC Developers Mail List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: linux-mm@kvack.org, linuxppc-dev@lists.ozlabs.org, linux-kernel@vger.kernel.org Errors-To: linuxppc-dev-bounces+linuxppc-dev=archiver.kernel.org@lists.ozlabs.org Sender: "Linuxppc-dev" On Fri, 2018-11-30 at 11:44 +0000, Rui Salvaterra wrote: > Thanks for the quick response! I applied it on top of your > powerpc-dma.4 branch and retested. > I'm not seeing nouveau complaining anymore (I'm not using X11 or any > DE, though). > In any case and FWIW, this series is > > Tested-by: Rui Salvaterra Talking of which ... Christoph, not sure if we can do something about this at the DMA API level or keep hacks but some adapters such as the nVidia GPUs have a HW hack we can use to work around their limitations in that case. They have a register that can program a fixed value for the top bits that they don't support. This works fine for any linear mapping with an offset, provided they can program the offset in that register and they have enough DMA range to cover all memory from that offset. I can probably get the info about this from them so we can exploit it in nouveau. Cheers, Ben. > Thanks, > Rui