From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753766AbbIKSzu (ORCPT ); Fri, 11 Sep 2015 14:55:50 -0400 Received: from mail.kernel.org ([198.145.29.136]:54388 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751749AbbIKSzt (ORCPT ); Fri, 11 Sep 2015 14:55:49 -0400 Date: Fri, 11 Sep 2015 15:55:43 -0300 From: Arnaldo Carvalho de Melo To: =?iso-8859-1?Q?Rapha=EBl?= Beamonte Cc: Jiri Olsa , Namhyung Kim , Jiri Olsa , lkml , David Ahern , Ingo Molnar , Peter Zijlstra , Matt Fleming Subject: Re: [PATCH 5/5] perf tools: Enhance parsing events tracepoint error output Message-ID: <20150911185543.GT23511@kernel.org> References: <1441615087-13886-1-git-send-email-jolsa@kernel.org> <1441615087-13886-6-git-send-email-jolsa@kernel.org> <20150910070030.GB18425@danjae.kornet> <20150910080537.GA19014@krava.brq.redhat.com> <20150911160931.GB3447@danjae.kornet> <20150911161647.GB20016@krava.brq.redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: X-Url: http://acmel.wordpress.com User-Agent: Mutt/1.5.23 (2014-03-12) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Em Fri, Sep 11, 2015 at 01:50:02PM -0400, Raphaël Beamonte escreveu: > 2015-09-11 12:16 GMT-04:00 Jiri Olsa : > > On Sat, Sep 12, 2015 at 01:09:31AM +0900, Namhyung Kim wrote: > > >> has a problem - if tracefs is mounted under debugfs, the access mode > >> of debugfs also affects, so in this case I had to change it both for > >> debugfs and tracefs.. > > hum, I wonder the error message needs to be that smart.. > > Hmm... If tracefs is mounted under debugfs, wouldn't remounting > debugfs do the trick, as it was done before? Not necessarily, we may be able to access /a/ but not /a/b/, so, before we get to /a/b/ we need to solve access to /a/ to then realize that /a/b/ also need permission change so that we can access it. > If so, why couldn't we just check the paths with a basic strcmp to > verify if tracefs starts by debugfs, and in that case offer to remount > debugfs, else offer to remount tracefs? say it is how it was before tracefs: /sys/kernel/debug/tracing/ If we can't access "/sys/kernel/debug/tracing/" because we can't access "/sys/kernel/debug/" we need first to change (remount, chmod/grp/own, whatever is best in each hypotetical use case) /sys/kernel/debug/ to then do the same for /sys/kernel/debug/tracing/, no? We could of course say something like "Something is wrong with tracefs and/or debugfs, figure it out and try again", but we can do better, right? 8-P - Arnaldo