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 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 91656C433E1 for ; Thu, 20 Aug 2020 10:05:48 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id 4C114206DA for ; Thu, 20 Aug 2020 10:05:48 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=chromium.org header.i=@chromium.org header.b="foA95pAM" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 4C114206DA Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=chromium.org Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=owner-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix) id E0DAC8D0007; Thu, 20 Aug 2020 06:05:47 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id DC04F8D0001; Thu, 20 Aug 2020 06:05:47 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id CD4248D0007; Thu, 20 Aug 2020 06:05:47 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0119.hostedemail.com [216.40.44.119]) by kanga.kvack.org (Postfix) with ESMTP id B5EFC8D0001 for ; Thu, 20 Aug 2020 06:05:47 -0400 (EDT) Received: from smtpin18.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay01.hostedemail.com (Postfix) with ESMTP id 61C94180AD81A for ; Thu, 20 Aug 2020 10:05:47 +0000 (UTC) X-FDA: 77170515534.18.start89_1906eef2702f Received: from filter.hostedemail.com (10.5.16.251.rfc1918.com [10.5.16.251]) by smtpin18.hostedemail.com (Postfix) with ESMTP id 32748100ED3CB for ; Thu, 20 Aug 2020 10:05:47 +0000 (UTC) X-HE-Tag: start89_1906eef2702f X-Filterd-Recvd-Size: 6809 Received: from mail-ej1-f68.google.com (mail-ej1-f68.google.com [209.85.218.68]) by imf30.hostedemail.com (Postfix) with ESMTP for ; Thu, 20 Aug 2020 10:05:46 +0000 (UTC) Received: by mail-ej1-f68.google.com with SMTP id m22so1773541eje.10 for ; Thu, 20 Aug 2020 03:05:46 -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=rteLspKE6W9sydZeuWzRbFLSFcNHJB0o1t6fS0ixKGwcOzpcJFyZsu6a6Ueh4UC35m spodHyFvH9TDo1sYJ1mUtutztQAzUU9nLvoMwQr9NbBtAty6VYXKKiDazLbFkL6qv5WH tb69+UXkbVMg0ME+yY8ON1TuUNi6TD1tX7/075lIJxNHRNzKVAU2fHlkNqxNqNkAerGV aKrt93dgdVGDGpy9R738zLKKmJHaf/4Lnut6dEEWdGCo4h6QeGvXdqY2HaxKMPC9hnHM ItCZXQGREZap0DxqhA2h9rNTBRzNI/+cCEIug1iU4FFW+jaRTno/HSSBCCr/23gWoZ2x Kf0Q== X-Gm-Message-State: AOAM5321zBrWeYxcRvzDY+j3Vfc/e1+AIqd9l9bDoAJVoMrNL3z5O7lh LfFgQSvu8ZaRD8jBtIP/ErhydUT6c06iHNSY X-Google-Smtp-Source: ABdhPJwA9o/Lo2cAW/jreAbScKbu/sdA6Ese9NRmiszuiyul9Yz0IcPDZaBHBISaVSsgZzV//DEvzQ== X-Received: by 2002:a17:907:36b:: with SMTP id rs11mr2585715ejb.544.1597917945422; Thu, 20 Aug 2020 03:05:45 -0700 (PDT) Received: from mail-wr1-f50.google.com (mail-wr1-f50.google.com. [209.85.221.50]) by smtp.gmail.com with ESMTPSA id v14sm1140318ejb.63.2020.08.20.03.05.44 for (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Thu, 20 Aug 2020 03:05:45 -0700 (PDT) Received: by mail-wr1-f50.google.com with SMTP id a5so1454153wrm.6 for ; Thu, 20 Aug 2020 03:05:44 -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" X-Rspamd-Queue-Id: 32748100ED3CB X-Spamd-Result: default: False [0.00 / 100.00] X-Rspamd-Server: rspam04 X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: 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