Received: by 2002:a05:6a10:f347:0:0:0:0 with SMTP id d7csp1514107pxu; Fri, 27 Nov 2020 08:53:04 -0800 (PST) X-Google-Smtp-Source: ABdhPJx/2pUkmgRCa9QMc7p3H7IDIiNS2BObiQ9JDSZ0G12e0zfFuQ5HHgdijupr/9tLpbUOemwC X-Received: by 2002:a50:bb66:: with SMTP id y93mr9063593ede.244.1606495984422; Fri, 27 Nov 2020 08:53:04 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1606495984; cv=none; d=google.com; s=arc-20160816; b=SRZxWPcIa0gCWXM67aCR+Qgt+Jaw0Y6zEl98a5LwmAmv3hKXVr+TMYFEiPML4/ND6n HihCbpQpRDMEzmgb8duS03IXLSFRFlms4WpFvoyV40Z4YnqzSmPoIOk0xx9Zn+z+DzU8 FcEdTSYpJjhBBCF6mW2T3qdKwW9lxiEu9T6a4jYRGsobpR0q+WHNPQjooA3tsdgi8O77 7piIpKjK65VsfpU6gMPWVOkFeCivT1imulhB679MmyMl431gpckJPPZNJkLXNbfjWVEv o7du3PQzHxFtLSaIAYfGfhrQbiL0IyEqLbGK/SQwEbJnv9CsAWXth/UitDWosmZLnjJe Wyiw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:dkim-signature; bh=t1q1/SHKgIbW+C5B/mTAdQ8BsxcSyq0zUymWZe9rx3U=; b=UDniyLIUoUapxUJxnD5f4pZBd1PwMUMvPOoCRBueITgi86yVgaGxkjSJyBeFNHQu09 ZKB2HghCp8p0YrVrIu604336ETOLGYgR48iTM+pInF3p0EZsKLFNs2oD0b8UGGuoYLRX BTMYwKi/uv1HgFhNIuVLPk8c+9w72ghcrxDy27niYPN6/RemCtLtHojwAQWISEnjXNxM yglDgPCmmNoniz8jJrSak32mOV7dHsjqGe+IOZqtEC/0cnE2KuAxpX7NRoQmzU0w2lTH BMpbxI4PQx7DxN6NzHKQAzjM25okNTaNSwJYmg4WBsPY1DgNcvqWxgto7ysPmJ2Kj/94 ZLxg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=ge2XywzP; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=chromium.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id ec19si5598338ejb.669.2020.11.27.08.52.40; Fri, 27 Nov 2020 08:53:04 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=ge2XywzP; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=chromium.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1731845AbgK0Qu2 (ORCPT + 99 others); Fri, 27 Nov 2020 11:50:28 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:55398 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1731534AbgK0Qu2 (ORCPT ); Fri, 27 Nov 2020 11:50:28 -0500 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 86E40C0613D2 for ; Fri, 27 Nov 2020 08:50:26 -0800 (PST) Received: by mail-ej1-x642.google.com with SMTP id hb22so8232963ejb.12 for ; Fri, 27 Nov 2020 08:50:26 -0800 (PST) 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=t1q1/SHKgIbW+C5B/mTAdQ8BsxcSyq0zUymWZe9rx3U=; b=ge2XywzPkpdxv9n/Fbs5vWEHA989qR/8Yox1ZRHLfL1xJSVMaIqd7r2X0hfJqySlWl MUDt/K1VtjFqQsHHOQBDcWjh9BqtMyF0ol3dlQdiybZobKY7sLJHvFb0vte1J1XIoGRz juKlidqO/OxMgfrKNYLPFyQQExhPFDMupmdj8= 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=t1q1/SHKgIbW+C5B/mTAdQ8BsxcSyq0zUymWZe9rx3U=; b=GyKceZuQs7XKJ69ADjQhijwyb/ghU+wCuGmKcLisnpkpjuGtFMP/qsGH0Y1BwBFa7F 0XgTHbcG+e7fu2EXXSm32ZfYDsNvLQM3Hnl9hCQYZ8YPkdGLTFnNiaYTShnR3oIaMkqZ JbvAl+XOhf9oehPrjYu+8hFjLAyn9jg9EInHEG5SvtzuTR31pnJ36iqj/4P7uVpPJH8Q ZwNkjjbCB9txxjpeb6gPL9N8SNM9NK+nC903delwApl+7VS51sHo//wCm6YOtKChpY6Q wYFXeqOGuJNEC+hOxf0f2nsdqBkrDfppm24khRP5Qa+cCycQUNorFRWfqYVrBolNv804 xiEA== X-Gm-Message-State: AOAM531Nupn90Yr6KSngJlfYXE4mo1WYg2Pz4WkcXqch8nWbq9L/tRJ2 uLgMnCBTkouBTj1oxN+ZZ7fIm6TQPqoG+w== X-Received: by 2002:a17:906:f18f:: with SMTP id gs15mr9018653ejb.474.1606495825037; Fri, 27 Nov 2020 08:50:25 -0800 (PST) Received: from mail-wr1-f53.google.com (mail-wr1-f53.google.com. [209.85.221.53]) by smtp.gmail.com with ESMTPSA id v5sm5031314ejh.99.2020.11.27.08.50.24 for (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Fri, 27 Nov 2020 08:50:24 -0800 (PST) Received: by mail-wr1-f53.google.com with SMTP id 64so6209959wra.11 for ; Fri, 27 Nov 2020 08:50:24 -0800 (PST) X-Received: by 2002:adf:f542:: with SMTP id j2mr11727842wrp.32.1606495823649; Fri, 27 Nov 2020 08:50:23 -0800 (PST) MIME-Version: 1.0 References: <20201127094136.1051071-1-sergey.senozhatsky@gmail.com> <0dbfa509-8c82-7470-c18b-24ab5c92dc4b@xs4all.nl> <509cc69b-39d7-4b13-f392-ebf25530c8fe@xs4all.nl> In-Reply-To: From: Tomasz Figa Date: Sat, 28 Nov 2020 01:50:12 +0900 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH] media: vb2: always set buffer cache sync hints To: Sergey Senozhatsky Cc: Hans Verkuil , Marek Szyprowski , Mauro Carvalho Chehab , Linux Media Mailing List , Linux Kernel Mailing List , Sergey Senozhatsky Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sat, Nov 28, 2020 at 1:35 AM Sergey Senozhatsky wrote: > > On (20/11/27 15:56), Hans Verkuil wrote: > > Yes. > > > > BTW, wouldn't it be sufficient to change this code to: > > > > if (!q->allow_cache_hints && q->memory != VB2_MEMORY_DMABUF) { > > vb->need_cache_sync_on_prepare = 1; > > vb->need_cache_sync_on_finish = 1; > > } > > I think it would be sufficient. Does it matter at this point if allow_cache_hints is set or not? Best regards, Tomasz