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=-8.3 required=3.0 tests=DKIM_ADSP_CUSTOM_MED, DKIM_INVALID,DKIM_SIGNED,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI,SIGNED_OFF_BY, SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED,USER_AGENT_SANE_2 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 1C4BEC433E1 for ; Mon, 22 Jun 2020 14:28:26 +0000 (UTC) Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id E279920732 for ; Mon, 22 Jun 2020 14:28:25 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=fail reason="signature verification failed" (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="pmYe8CFr" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org E279920732 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=gmail.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=amd-gfx-bounces@lists.freedesktop.org Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 9C12D6E0EB; Mon, 22 Jun 2020 14:28:25 +0000 (UTC) Received: from mail-lj1-x241.google.com (mail-lj1-x241.google.com [IPv6:2a00:1450:4864:20::241]) by gabe.freedesktop.org (Postfix) with ESMTPS id 6647C6E0EB; Mon, 22 Jun 2020 14:28:24 +0000 (UTC) Received: by mail-lj1-x241.google.com with SMTP id n23so19519992ljh.7; Mon, 22 Jun 2020 07:28:24 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:from:to:cc:subject:message-id:in-reply-to:references :mime-version; bh=P5gBKjnB1OsXDdzy1+PQDW2YHOnzPHmavQRkrhB8/ks=; b=pmYe8CFrf/1oTHQD7/8NK7Q3f8a2RLFe5qOEE56ftVtE91mg1r2qJXrzxiQz5HgII3 ihM+eO3QwqPiKlCN71XPpxkiXGOYE8GOtlXP7tgK629Ia435CXRdn6CFmj7g2G1rdZNN lJYjgJ4VrMtwa+vbYb5093qepsquLGbljQEdGVUoYWGCh7/kvK8m0U/R+/FYPc/kh+cK svtL71wHV+TxPd/2ZUet635lNM9xYvr4+LJdUmIo0/DM8TCQYMu/dvdu1yUhU/RXMXm9 7YMzqztx0g56ySAQ7atK2bM9P+1z1RLz7lXSy1uxIoW5pl4CGfwTRZ3DMMq7qd52z+fs hO/w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:in-reply-to :references:mime-version; bh=P5gBKjnB1OsXDdzy1+PQDW2YHOnzPHmavQRkrhB8/ks=; b=lJx6wOjaJthTXgEhe30DQyiRfiGseNaTyp3hSqqWaXU95U/8fu4QIurUWZHOUVU4vc KLXl2fy9pFk7kFWLYhDcpYg1z/IlparY4mk5E2Qwh4ZW+w8JpsWhwjwbepu3FeMPWpt1 DL0ji7OCai8t5MXzRHM7hjhDXfVDa4I05qq6mF+iZc447xoWqg7R1LJI5h90uwkDcASC 69LaOy0SpHUQJe1A1p6ShCkLG9/ktDtC6lXdkZVbNAthbmRp7p60/mausD/EVMJLFMXu sinzBjVRyqcpzb6HUzMQwQF/UWt3wYBN2OkQ0w+w+gry0s0AgTZCoTR9MsxenAUHVKsN ejSg== X-Gm-Message-State: AOAM5328818D6wtwSkJWSwz9pigL11Nguhs4Rd/5vcCPbkeqgR2NP5SJ RdlU9XKr5l/ucJa7Hopw6cY= X-Google-Smtp-Source: ABdhPJyeuLaNYxxmzjgf+lD2RopbCcx+47YCVlE8qX0wgtkcnCQ8Lb3EfE5uStg7ADgeuGgn61xDzw== X-Received: by 2002:a2e:5758:: with SMTP id r24mr338992ljd.203.1592836102483; Mon, 22 Jun 2020 07:28:22 -0700 (PDT) Received: from eldfell ([194.136.85.206]) by smtp.gmail.com with ESMTPSA id s17sm2744431ljd.51.2020.06.22.07.28.21 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 22 Jun 2020 07:28:22 -0700 (PDT) Date: Mon, 22 Jun 2020 17:28:18 +0300 From: Pekka Paalanen To: Daniel Vetter Subject: Re: [PATCH v2 1/8] drm: Add dummy page per device or GEM object Message-ID: <20200622172818.307f626b@eldfell> In-Reply-To: References: <1592719388-13819-1-git-send-email-andrey.grodzovsky@amd.com> <1592719388-13819-2-git-send-email-andrey.grodzovsky@amd.com> <20200622093501.GZ20149@phenom.ffwll.local> <20200622172157.49b835ca@eldfell> X-Mailer: Claws Mail 3.17.3 (GTK+ 2.24.32; x86_64-pc-linux-gnu) MIME-Version: 1.0 X-BeenThere: amd-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Discussion list for AMD gfx List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Andrey Grodzovsky , Christian =?UTF-8?B?S8O2bmln?= , Michel =?UTF-8?B?RMOkbnplcg==?= , dri-devel , amd-gfx list , Alex Deucher Content-Type: multipart/mixed; boundary="===============0981292105==" Errors-To: amd-gfx-bounces@lists.freedesktop.org Sender: "amd-gfx" --===============0981292105== Content-Type: multipart/signed; micalg=pgp-sha256; boundary="Sig_/GZ6mKcFtfhRl.t+Qvy7Pj+y"; protocol="application/pgp-signature" --Sig_/GZ6mKcFtfhRl.t+Qvy7Pj+y Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: quoted-printable On Mon, 22 Jun 2020 16:24:38 +0200 Daniel Vetter wrote: > On Mon, Jun 22, 2020 at 4:22 PM Pekka Paalanen wrot= e: > > > > On Mon, 22 Jun 2020 11:35:01 +0200 > > Daniel Vetter wrote: > > =20 > > > On Sun, Jun 21, 2020 at 02:03:01AM -0400, Andrey Grodzovsky wrote: =20 > > > > Will be used to reroute CPU mapped BO's page faults once > > > > device is removed. > > > > > > > > Signed-off-by: Andrey Grodzovsky > > > > --- > > > > drivers/gpu/drm/drm_file.c | 8 ++++++++ > > > > drivers/gpu/drm/drm_prime.c | 10 ++++++++++ > > > > include/drm/drm_file.h | 2 ++ > > > > include/drm/drm_gem.h | 2 ++ > > > > 4 files changed, 22 insertions(+) =20 > > > > ... > > =20 > > > > diff --git a/include/drm/drm_gem.h b/include/drm/drm_gem.h > > > > index 0b37506..47460d1 100644 > > > > --- a/include/drm/drm_gem.h > > > > +++ b/include/drm/drm_gem.h > > > > @@ -310,6 +310,8 @@ struct drm_gem_object { > > > > * > > > > */ > > > > const struct drm_gem_object_funcs *funcs; > > > > + > > > > + struct page *dummy_page; > > > > }; =20 > > > > > > I think amdgpu doesn't care, but everyone else still might care somew= hat > > > about flink. That also shares buffers, so also needs to allocate the > > > per-bo dummy page. =20 > > > > Do you really care about making flink not explode on device > > hot-unplug? Why not just leave flink users die in a fire? > > It's not a regression. =20 >=20 > It's not about exploding, they won't. With flink you can pass a buffer > from one address space to the other, so imo we should avoid false > sharing. E.g. if you happen to write something $secret into a private > buffer, but only $non-secret stuff into shared buffers. Then if you > unplug, your well-kept $secret might suddenly be visible by lots of > other processes you never intended to share it with. >=20 > Just feels safer to plug that hole completely. Ah! Ok, I clearly didn't understand the consequences. Thanks, pq --Sig_/GZ6mKcFtfhRl.t+Qvy7Pj+y Content-Type: application/pgp-signature Content-Description: OpenPGP digital signature -----BEGIN PGP SIGNATURE----- iQIzBAEBCAAdFiEEJQjwWQChkWOYOIONI1/ltBGqqqcFAl7wwAIACgkQI1/ltBGq qqcE9A//Z3UNEnWcqO8aJ0C7ncKWgq8M8BVs9oU78I/4P4lQLK0lpw+zQYKlgzWY LUc53AqymxN/BWsm+8c8AuKmu6r7plkigZzu1Ee77YKIshEQiblMhyKG6MIC+wwH jhTtB45p8BbRjpBuO2v1Il9aEd1r9FENxbY1S0AU2arCntoAlg1kaGgTilRiPrsr NAVqxuwOLCcD+uI/1w6BFAvU1OYmfOcc41lB/UJHc84ftAfHzuRqjrIqHQbpLvkV OtBHHHAQEWsVkW5G2BUes7Umh8zwmUBOUwwy1hXaWg/sOI1TID6NzVVqYlIY/jXw SVWiPPB8/lBGSyYBA5IEyxO+1ijMHchvpn9vqWz/3NU6ibpcReN0i0JBUhEDPWIm uQzYWJy2I2j3Sai4hiz0b4m3JRx1TOrg0ysbPDON48Rlq8lZxRMGaA8P1qmtcuwv 6l7deV5C9uCy8jmx9p0WXoR8RBS1WDm/JFhrGXk8Sw1HZBpv1/Bp6mrPqiIcxFyG S7bm8UgklOHOHQXgXHe6XgME5hD6D3Kw+Sl/CBv9Ac/f5Sz2EX7I7MGop3XzPZzi /ut1tcFJL5mJowNR3vUJXVDmh5pKvBC0qITkMs3KPChdNQNObNdAgFjl8vO8kqeC 7BxaVkcHVKEJ6BzddPwsRQmNieoeBOPwxYG0FQYFY4/wvcVQBAg= =PNHM -----END PGP SIGNATURE----- --Sig_/GZ6mKcFtfhRl.t+Qvy7Pj+y-- --===============0981292105== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ amd-gfx mailing list amd-gfx@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/amd-gfx --===============0981292105==--