From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([140.186.70.92]:45214) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RO3ii-0005n2-F1 for qemu-devel@nongnu.org; Wed, 09 Nov 2011 03:41:21 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1RO3ih-0004zW-4f for qemu-devel@nongnu.org; Wed, 09 Nov 2011 03:41:20 -0500 Received: from e28smtp09.in.ibm.com ([122.248.162.9]:33233) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RO3ig-0004yZ-DB for qemu-devel@nongnu.org; Wed, 09 Nov 2011 03:41:19 -0500 Received: from /spool/local by e28smtp09.in.ibm.com with XMail ESMTP for from ; Wed, 9 Nov 2011 14:11:06 +0530 Received: from d28av03.in.ibm.com (d28av03.in.ibm.com [9.184.220.65]) by d28relay03.in.ibm.com (8.13.8/8.13.8/NCO v10.0) with ESMTP id pA98emAJ4030516 for ; Wed, 9 Nov 2011 14:10:49 +0530 Received: from d28av03.in.ibm.com (loopback [127.0.0.1]) by d28av03.in.ibm.com (8.14.4/8.13.1/NCO v10.0 AVout) with ESMTP id pA98emep030592 for ; Wed, 9 Nov 2011 19:40:48 +1100 Message-ID: <4EBA3C8F.7040405@linux.vnet.ibm.com> Date: Wed, 09 Nov 2011 14:10:47 +0530 From: Harsh Bora MIME-Version: 1.0 References: <1320819951-5302-1-git-send-email-harsh@linux.vnet.ibm.com> <871uth90j7.fsf@linux.vnet.ibm.com> In-Reply-To: <871uth90j7.fsf@linux.vnet.ibm.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH] scripts/analyse-9p-simpletrace.py: Add symbolic names for 9p operations. List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org, "Aneesh Kumar K. V" On 11/09/2011 01:43 PM, Aneesh Kumar K.V wrote: > On Wed, 9 Nov 2011 11:55:51 +0530, Harsh Prateek Bora wrote: >> Currently, we just print the numerical value of 9p operation identifier in >> case of RERROR which is less meaningful for readability. Mapping 9p >> operation ids to symbolic names provides a better tracelog: >> >> RERROR (tag = 1 , id = TWALK , err = 2 ) >> RERROR (tag = 1 , id = TUNLINKAT , err = 39 ) > > It would be nice to map that err to a string. os.strerror(err) may be ? > makes sense, however os.strerror prints multi word text explaining the error and not just the symbolic word, hope its okay: RERROR (tag = 1 , id = TWALK , err = No such file or directory ) RERROR (tag = 1 , id = TUNLINKAT , err = Directory not empty ) will update in v2. > >> >> This patch provides a dictionary of all possible 9p operation symbols mapped >> to their numerical identifiers which are likely to be used in future at >> various places in this script. >> >> Signed-off-by: Harsh Prateek Bora >> --- > > -aneesh > >