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=-2.7 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_PASS,UNPARSEABLE_RELAY,URIBL_BLOCKED,USER_AGENT_GIT autolearn=ham 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 44A1FC433F5 for ; Thu, 30 Aug 2018 17:21:05 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id EFA0120838 for ; Thu, 30 Aug 2018 17:21:04 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org EFA0120838 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=collabora.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727212AbeH3VYL (ORCPT ); Thu, 30 Aug 2018 17:24:11 -0400 Received: from bhuna.collabora.co.uk ([46.235.227.227]:38030 "EHLO bhuna.collabora.co.uk" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725836AbeH3VYL (ORCPT ); Thu, 30 Aug 2018 17:24:11 -0400 Received: from [127.0.0.1] (localhost [127.0.0.1]) (Authenticated sender: ezequiel) with ESMTPSA id 5904126C052 From: Ezequiel Garcia To: linux-media@vger.kernel.org, linux-usb@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Cc: Laurent Pinchart , Tomasz Figa , "Matwey V . Kornilov" , Alan Stern , kernel@collabora.com, Keiichi Watanabe , Ezequiel Garcia Subject: [RFC 0/3] Introduce usb_{alloc,free}_noncoherent API Date: Thu, 30 Aug 2018 14:20:27 -0300 Message-Id: <20180830172030.23344-1-ezequiel@collabora.com> X-Mailer: git-send-email 2.18.0 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Following the discussion on PWC [1] and UVC [2] drivers, where use non-consistent mappings for the URB transfer buffers was shown to improve transfer speed significantly, here's a proposal for a non-coherent USB helpers. With this pachset, it's possible to get 360x288 raw analog video using stk1160 and a AM335x Beaglebone Black board. This isn't possible in mainline, for the same reasons Matwey has explained [1]. First patch is a hack, obviously incomplete, to add support for non-consistent mappings on ARM. The second patch introduces the usb_{alloc,free}_noncoherent API, while the third patch is an example on stk1160. I'm sending this patchset as RFC, just to get the ball rolling. [1] https://lkml.org/lkml/2018/8/21/663 [2] https://lkml.org/lkml/2018/6/27/188 Ezequiel Garcia (3): HACK: ARM: dma-mapping: Get writeback memory for non-consistent mappings USB: core: Add non-coherent buffer allocation helpers stk1160: Use non-coherent buffers for USB transfers arch/arm/include/asm/pgtable.h | 3 ++ arch/arm/mm/dma-mapping.c | 9 ++-- drivers/media/usb/stk1160/stk1160-video.c | 22 +++------ drivers/usb/core/buffer.c | 29 +++++++----- drivers/usb/core/hcd.c | 5 +- drivers/usb/core/usb.c | 56 ++++++++++++++++++++++- include/linux/usb.h | 5 ++ include/linux/usb/hcd.h | 4 +- 8 files changed, 97 insertions(+), 36 deletions(-) -- 2.18.0 From mboxrd@z Thu Jan 1 00:00:00 1970 From: ezequiel@collabora.com (Ezequiel Garcia) Date: Thu, 30 Aug 2018 14:20:27 -0300 Subject: [RFC 0/3] Introduce usb_{alloc,free}_noncoherent API Message-ID: <20180830172030.23344-1-ezequiel@collabora.com> To: linux-arm-kernel@lists.infradead.org List-Id: linux-arm-kernel.lists.infradead.org Following the discussion on PWC [1] and UVC [2] drivers, where use non-consistent mappings for the URB transfer buffers was shown to improve transfer speed significantly, here's a proposal for a non-coherent USB helpers. With this pachset, it's possible to get 360x288 raw analog video using stk1160 and a AM335x Beaglebone Black board. This isn't possible in mainline, for the same reasons Matwey has explained [1]. First patch is a hack, obviously incomplete, to add support for non-consistent mappings on ARM. The second patch introduces the usb_{alloc,free}_noncoherent API, while the third patch is an example on stk1160. I'm sending this patchset as RFC, just to get the ball rolling. [1] https://lkml.org/lkml/2018/8/21/663 [2] https://lkml.org/lkml/2018/6/27/188 Ezequiel Garcia (3): HACK: ARM: dma-mapping: Get writeback memory for non-consistent mappings USB: core: Add non-coherent buffer allocation helpers stk1160: Use non-coherent buffers for USB transfers arch/arm/include/asm/pgtable.h | 3 ++ arch/arm/mm/dma-mapping.c | 9 ++-- drivers/media/usb/stk1160/stk1160-video.c | 22 +++------ drivers/usb/core/buffer.c | 29 +++++++----- drivers/usb/core/hcd.c | 5 +- drivers/usb/core/usb.c | 56 ++++++++++++++++++++++- include/linux/usb.h | 5 ++ include/linux/usb/hcd.h | 4 +- 8 files changed, 97 insertions(+), 36 deletions(-) -- 2.18.0