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=-3.9 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=no 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 2E924C433E1 for ; Thu, 20 Aug 2020 11:04:55 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id F2F9020738 for ; Thu, 20 Aug 2020 11:04:54 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=chromium.org header.i=@chromium.org header.b="foA95pAM" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729141AbgHTLEy (ORCPT ); Thu, 20 Aug 2020 07:04:54 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:35326 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1731108AbgHTKM5 (ORCPT ); Thu, 20 Aug 2020 06:12:57 -0400 Received: from mail-ej1-x642.google.com (mail-ej1-x642.google.com [IPv6:2a00:1450:4864:20::642]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0E952C061757 for ; Thu, 20 Aug 2020 03:12:56 -0700 (PDT) Received: by mail-ej1-x642.google.com with SMTP id c16so1785737ejx.12 for ; Thu, 20 Aug 2020 03:12:56 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=Pbe+IJf4ZBxt6yUxRRrQR1l3UQTW2eLx6AT4PE1gQKg=; b=foA95pAMne0k+ZduK2+JsEaA0Kd3Xk6AJeP12ZUtsQO8oCEqpY6AC2jWiQeJjjQrKA n//Z/S/hwU9sUSwrh2bpFx9EjO5w8H5vkm5cyHDHvlSF0L7E3fVBHC7P2Ym9zd8UwQZN UTTFBKoIkLT88Lc8FZLz7dV6a5Tegh0nandB0= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=Pbe+IJf4ZBxt6yUxRRrQR1l3UQTW2eLx6AT4PE1gQKg=; b=UiKyLdiYyXSIlGFym6Y0Jon1Z7AcLNsfX6hfWaiGxRMSNEb5PeJIdVc5rgPiSuwQFu 8pwMH1t95o3WAOoIxPNfx72aYve9SMwVWvoh3lQjkKkpxMTLCiGsz3wy0wVJfsIjZZGC ySHgnKk8aK/q5Tc7EcLC3zmYqun11aIF7ZL0ZQtzlQxLIZwv2Lh7lQQQAQLnVPCj024s 9wsEBXAJfRVoXR1feGAeG4fertwYoI/iC8d6yfdT4o1bSen5/AElzo3a6bO3iSUtvzod /p+AjAmZgP0sO3zT7Uk16feYlAGEjILjR+9KqSdDTbw29rqP0jHRgBD2Iq6wbF+qQl3Z wPcA== X-Gm-Message-State: AOAM5325EPKiUc1EXPIH0Sh2jBKihj9b9F5E4LmxZPEc7+IyIbM0X0xg KgZSZ/8wo6joGUJvBMu4iL3M8s+7+51u5Qem X-Google-Smtp-Source: ABdhPJzmNH7lGnbiye7d17EQaMEuMAwiWbgIiIcgib5igRoONcSajAI65P3MOjD0FnVNQusDZpo4SA== X-Received: by 2002:a17:906:4f8f:: with SMTP id o15mr2440063eju.220.1597918374629; Thu, 20 Aug 2020 03:12:54 -0700 (PDT) Received: from mail-ed1-f48.google.com (mail-ed1-f48.google.com. [209.85.208.48]) by smtp.gmail.com with ESMTPSA id 32sm1047701edf.83.2020.08.20.03.12.54 for (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Thu, 20 Aug 2020 03:12:54 -0700 (PDT) Received: by mail-ed1-f48.google.com with SMTP id w17so1133898edt.8 for ; Thu, 20 Aug 2020 03:12:54 -0700 (PDT) X-Received: by 2002:a5d:6744:: with SMTP id l4mr2628495wrw.105.1597917944145; Thu, 20 Aug 2020 03:05:44 -0700 (PDT) MIME-Version: 1.0 References: <20200819065555.1802761-1-hch@lst.de> <20200819065555.1802761-6-hch@lst.de> <20200819135454.GA17098@lst.de> <20200820044347.GA4533@lst.de> <20200820052004.GA5305@lst.de> In-Reply-To: <20200820052004.GA5305@lst.de> From: Tomasz Figa Date: Thu, 20 Aug 2020 12:05:29 +0200 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH 05/28] media/v4l2: remove V4L2-FLAG-MEMORY-NON-CONSISTENT To: Christoph Hellwig Cc: alsa-devel@alsa-project.org, linux-ia64@vger.kernel.org, Linux Doc Mailing List , nouveau@lists.freedesktop.org, linux-nvme@lists.infradead.org, linux-mips@vger.kernel.org, "James E.J. Bottomley" , linux-mm@kvack.org, linux-samsung-soc , Joonyoung Shim , linux-scsi@vger.kernel.org, Kyungmin Park , Ben Skeggs , Matt Porter , Linux Media Mailing List , Tom Lendacky , Pawel Osciak , Mauro Carvalho Chehab , "list@263.net:IOMMU DRIVERS , Joerg Roedel ," , Thomas Bogendoerfer , linux-parisc@vger.kernel.org, netdev@vger.kernel.org, Seung-Woo Kim , Linux Kernel Mailing List , "list@263.net:IOMMU DRIVERS , Joerg Roedel ," Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Aug 20, 2020 at 7:20 AM Christoph Hellwig wrote: > > On Thu, Aug 20, 2020 at 06:43:47AM +0200, Christoph Hellwig wrote: > > On Wed, Aug 19, 2020 at 03:57:53PM +0200, Tomasz Figa wrote: > > > > > Could you explain what makes you think it's unused? It's a feature of > > > > > the UAPI generally supported by the videobuf2 framework and relied on > > > > > by Chromium OS to get any kind of reasonable performance when > > > > > accessing V4L2 buffers in the userspace. > > > > > > > > Because it doesn't do anything except on PARISC and non-coherent MIPS, > > > > so by definition it isn't used by any of these media drivers. > > > > > > It's still an UAPI feature, so we can't simply remove the flag, it > > > must stay there as a no-op, until the problem is resolved. > > > > Ok, I'll switch to just ignoring it for the next version. > > So I took a deeper look. I don't really think it qualifies as a UAPI > in our traditional sense. For one it only appeared in 5.9-rc1, so we > can trivially expedite the patch into 5.9-rc and not actually make it > show up in any released kernel version. And even as of the current > Linus' tree the only user is a test driver. So I really think the best > way to go ahead is to just revert it ASAP as the design wasn't thought > out at all. The UAPI and V4L2/videobuf2 changes are in good shape and the only wrong part is the use of DMA API, which was based on an earlier email guidance anyway, and a change to the synchronization part . I find conclusions like the above insulting for people who put many hours into designing and implementing the related functionality, given the complexity of the videobuf2 framework and how ill-defined the DMA API was, and would feel better if such could be avoided in future communication. That said, we can revert it on the basis of the implementation issues, but I feel like we wouldn't get anything by doing so, because as I said, the design is sane and most of the implementation is fine as well. Instead. I'd suggest simply removing the use of the attribute being removed, so that the feature stays no-op until the DMA API provides a way to implement it or we just migrate videobuf2 to stop using the DMA API as much as possible, like many drivers in the DRM subsystem did. Best regards, Tomasz