From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754279AbdEXRqQ (ORCPT ); Wed, 24 May 2017 13:46:16 -0400 Received: from mail-yb0-f193.google.com ([209.85.213.193]:33749 "EHLO mail-yb0-f193.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754254AbdEXRqM (ORCPT ); Wed, 24 May 2017 13:46:12 -0400 Date: Wed, 24 May 2017 13:46:04 -0400 From: Tejun Heo To: Christoph Hellwig Cc: Shaohua Li , linux-kernel@vger.kernel.org, gregkh@linuxfoundation.org, viro@zeniv.linux.org.uk, Kernel-team@fb.com Subject: Re: [PATCH 5/5] kernfs: add exportfs operations Message-ID: <20170524174604.GK24798@htj.duckdns.org> References: <3d3a0860317afa0fb722c1a6df58e04593fc700a.1495490800.git.shli@fb.com> <20170523074019.GC29525@infradead.org> <20170523185711.GB13222@htj.duckdns.org> <20170524173822.GB13151@infradead.org> <20170524173939.GJ24798@htj.duckdns.org> <20170524174138.GA28155@infradead.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20170524174138.GA28155@infradead.org> User-Agent: Mutt/1.8.2 (2017-04-18) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hello, Christoph. On Wed, May 24, 2017 at 10:41:38AM -0700, Christoph Hellwig wrote: > > But how do you map that back to the cgroup without scanning the cgroup > > hierarchy? > > I'm totally lost on why you would do that. So maybe you just need > to send the full patch so that reviewers get the full picture. Here's a simple scenario. Let's say blktrace now exposes the cgroup inode and generation numbers per trace. Userland tool now wants to show that in a human readable format but it can only map back the inode and generation numbers to the path by scanning the cgroup tree. So, the goal is having a token which is not path which uniquely identifies a cgroup and the ability to map that back to cgroup path. We can add a dedicated interface to cgroup root, for example, and allow querying by echoing inode and generation numbers into it but that's kinda clumsy. Thanks. -- tejun