From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from resqmta-ch2-09v.sys.comcast.net ([69.252.207.41]:35068 "EHLO resqmta-ch2-09v.sys.comcast.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1757496AbcGZSe3 (ORCPT ); Tue, 26 Jul 2016 14:34:29 -0400 Date: Tue, 26 Jul 2016 11:32:25 -0700 From: "W. Trevor King" To: Andrew Vagin Cc: "Michael Kerrisk (man-pages)" , Serge Hallyn , Andrey Vagin , Linux API , Linux Containers , LKML , "criu@openvz.org" , "Eric W. Biederman" , linux-fsdevel , James Bottomley , Alexander Viro Subject: Re: [PATCH 0/5 RFC] Add an interface to discover relationships between namespaces Message-ID: <20160726183224.GN24913@odin.tremily.us> References: <20160721210650.GA10989@outlook.office365.com> <1515f5f2-5a49-fcab-61f4-8b627d3ba3e2@gmail.com> <87lh0pg8jx.fsf@x220.int.ebiederm.org> <44ca0e41-dc92-45b1-2a6c-c41a048a072d@gmail.com> <87r3ahepb4.fsf@x220.int.ebiederm.org> <20160726025455.GC26206@outlook.office365.com> <3390535b-0660-757f-aeba-c03d936b3485@gmail.com> <20160726182524.GA328@outlook.office365.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="9qSUuv1pKdnPyWmS" Content-Disposition: inline In-Reply-To: <20160726182524.GA328@outlook.office365.com> Sender: linux-fsdevel-owner@vger.kernel.org List-ID: --9qSUuv1pKdnPyWmS Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Tue, Jul 26, 2016 at 11:25:24AM -0700, Andrew Vagin wrote: > Sure. If a process wants to compare two namespaces, it needs to get file > descriptors for them (open /proc/PID/ns/XXX, use new ioctl-s, find a > process which has them), > and then it calls kcmp(pid1, pid2, KCMP_NSFD, ns_fd1, ns_fd2) If you use the new ioctl-s to get ns_fd2, do you walk your local /proc to find pid2? Cheers, Trevor --=20 This email may be signed or encrypted with GnuPG (http://www.gnupg.org). For more information, see http://en.wikipedia.org/wiki/Pretty_Good_Privacy --9qSUuv1pKdnPyWmS Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 iQIcBAEBAgAGBQJXl6yyAAoJEBBpoQVgXJg14XQP/0mQqjIzdYwyZzqcx9UjMmor KB795YEcFsDzw4kDaBM6MpGMcG7w/zdp8namR4Sq69F+51H0lepE6PQMtga7fFep KQGhLD6k8bJETLmGvFbl6qAZ7nFUDMYORg7ZxN/VgGPdEykCrFa0wybrR7Lj3KF7 i1FDfos2QNqxoglSsEOCaINPPGG0yfyyYVYLakkFLz/Z1H+ExWyW5nF14vGk9O87 LLPlMpZLjrYWyLJt1LEKKPYFlIOBPCfVIYv2gbh61Gb45l5Sq6HoAZNvMs0E2gnG HcscK4Ol2dUTqLK4SrAobOrpwIZnz9Avsk6Foo3gLBo2wwBqvwl4ORiXuPFiCoU0 +a6jaHPyGeRBpe/fL0E5TVsyt2m5QMm5SnxatW2FkLQl96F/lJDvtq4cUU3r254v ShyCtyJgOPbGmW7X9adzOPjGQKfTQ26igv5axcYGjd2XdpeHyJvLb0xO26r8OQo5 GiZ8tYesOqPb4D6Dn3nczRWBzpyziF+MGNRTmD/bRCGMwzfxlOvu0OkJxnLy1dVJ JK7RXZpSLCfxfFEAZoJ+NHW1n5CZkqNkNBrmW3mzh0C7ljCsB0QRW8Y+eaTBCtpD 8IWOF2waF9R4FFUwGxHYv0UEB5wXInL5tDwIaIuzVmthdNCaSS+m09fm2NSqt6gD Ou1LDpBoMQByobYl3Y3g =uvB6 -----END PGP SIGNATURE----- --9qSUuv1pKdnPyWmS--