Received: by 2002:ac0:a5a6:0:0:0:0:0 with SMTP id m35-v6csp43246imm; Thu, 30 Aug 2018 15:13:07 -0700 (PDT) X-Google-Smtp-Source: ANB0VdYMCNKULZ8AsjjHtxWmjGUhf6OAqQKI+LmcD06t2L1YffXoNJ5fc+wtf5QyOFi7DqG9N75i X-Received: by 2002:a63:e40d:: with SMTP id a13-v6mr11502654pgi.289.1535667187922; Thu, 30 Aug 2018 15:13:07 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1535667187; cv=none; d=google.com; s=arc-20160816; b=apZmXr5Z59OcKg7VSlh6sBZLOSVlVGQ0Ok4B7y/V6xAQUHFIM6H7czuA/vL4XxdmfE b7ZCmvRjdqwUccqFWAwUJOP/VhR1f+GR8l/Z4JlpzicTtk4UF26ZW/31PbYDYf64roQ1 9QMf49oXH7GrgC4Mjx1tHHNiWGMTOWT6LFW7DEjsQXel5jPObvVB9DjQeHGgkAv8t/gO 1jg5RDoqoHT37UfdP/XZWPE3nBIqJkz72mZxwdzfxHjSrT3FYoBySeHFqHiK2GyUtw4X 2p/x6W1++fRkRprHnTNIhcGwuj3hlwrCV6e80A81gRCRzQX/b355V0eAbbCZcHkOk7/3 s/mw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :organization:references:in-reply-to:date:cc:to:from:subject :message-id:arc-authentication-results; bh=p/T/k2Hb69+ccy5M6Yg8ZGsPsMkL360WVHhe83lMMwY=; b=Rllhkp27N2LpEC9bf5yb3voRXleqtgw/tkisPoBJlhwNxx3dhMphkn8h7UUN4CxAPS DeIclY4L/J/d9jJUemHIddsHXTeB1gVlaxMT04DuRIjMeFS/ml1PO77kJVF2DUYzEj+n rnGvUCbKqq68rXUke7mtvzYXaDA8uhV2At6VneknL+5K98oVEbdb7zlnxjfloboL00oY y5FLjSpgu8D0KaJjYFKG1JJ4fonPxqWj4F7AWSDrO62dDXhlDaVfKshw1bVOKtdaLDew 28S++7drVeuXM5YrIOcPzjhCOnw0ZLDC9Z5YHuYSQLsuePvZhPoUEtCGadBHbluE4d1i zibQ== ARC-Authentication-Results: i=1; mx.google.com; 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=fail (p=NONE sp=NONE dis=NONE) header.from=collabora.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id q132-v6si8439170pfc.159.2018.08.30.15.12.52; Thu, 30 Aug 2018 15:13:07 -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; 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=fail (p=NONE sp=NONE dis=NONE) header.from=collabora.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727240AbeHaCQF (ORCPT + 99 others); Thu, 30 Aug 2018 22:16:05 -0400 Received: from bhuna.collabora.co.uk ([46.235.227.227]:39636 "EHLO bhuna.collabora.co.uk" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725836AbeHaCQF (ORCPT ); Thu, 30 Aug 2018 22:16:05 -0400 Received: from [127.0.0.1] (localhost [127.0.0.1]) (Authenticated sender: ezequiel) with ESMTPSA id 66B732762BC Message-ID: <4fc5107f93871599ead017af7ad50f22535a7683.camel@collabora.com> Subject: Re: [RFC 2/3] USB: core: Add non-coherent buffer allocation helpers From: Ezequiel Garcia To: Christoph Hellwig Cc: linux-media@vger.kernel.org, linux-usb@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, Laurent Pinchart , Tomasz Figa , "Matwey V . Kornilov" , Alan Stern , kernel@collabora.com, Keiichi Watanabe Date: Thu, 30 Aug 2018 19:11:35 -0300 In-Reply-To: <20180830175850.GA11521@infradead.org> References: <20180830172030.23344-1-ezequiel@collabora.com> <20180830172030.23344-3-ezequiel@collabora.com> <20180830175850.GA11521@infradead.org> Organization: Collabora Content-Type: text/plain; charset="UTF-8" X-Mailer: Evolution 3.28.2-1 Mime-Version: 1.0 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, 2018-08-30 at 10:58 -0700, Christoph Hellwig wrote: > Please don't introduce new DMA_ATTR_NON_CONSISTENT users, it is > a rather horrible interface, and I plan to kill it off rather sooner > than later. I plan to post some patches for a better interface > that can reuse the normal dma_sync_single_* interfaces for ownership > transfers. I can happily include usb in that initial patch set based > on your work here if that helps. Please do. Until we have proper allocators that go thru the DMA API, drivers will have to kmalloc the USB transfer buffers, and have streaming mappings. Which in turns mean not using IOMMU or CMA. Regards, Eze