From owner-freebsd-hackers@FreeBSD.ORG Sat Aug 16 17:15:36 2008 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 5C51C106569B for ; Sat, 16 Aug 2008 17:15:36 +0000 (UTC) (envelope-from sam@freebsd.org) Received: from ebb.errno.com (ebb.errno.com [69.12.149.25]) by mx1.freebsd.org (Postfix) with ESMTP id 2D5EA8FC17 for ; Sat, 16 Aug 2008 17:15:36 +0000 (UTC) (envelope-from sam@freebsd.org) Received: from trouble.errno.com (trouble.errno.com [10.0.0.248]) (authenticated bits=0) by ebb.errno.com (8.13.6/8.12.6) with ESMTP id m7GHFZS0044683 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Sat, 16 Aug 2008 10:15:35 -0700 (PDT) (envelope-from sam@freebsd.org) Message-ID: <48A70B37.60401@freebsd.org> Date: Sat, 16 Aug 2008 10:15:35 -0700 From: Sam Leffler Organization: FreeBSD Project User-Agent: Thunderbird 2.0.0.9 (X11/20071125) MIME-Version: 1.0 To: Guillaume Ballet References: In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-DCC--Metrics: ebb.errno.com; whitelist Cc: freebsd-hackers@freebsd.org Subject: Re: Extending the ddb command set X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 16 Aug 2008 17:15:36 -0000 Guillaume Ballet wrote: > Hello hackers, > > I am currently working on a small project and would like to add a few > commands to the set that is available in ddb. > > I found that very interesting albeit succinct presentation: > http://people.freebsd.org/~jhb/papers/bsdcan/2008/slides.odp > > where the author hints that I should use DB_COMMAND, which I did. Yet when > invoking ddb, the command does not appear in the help list. I have taken a > look at the source code and was expecting set_db_cmd_set to appear in my > module's section list when calling objdump -h > > Is DB_COMMAND only working within the kernel itself, and not modules? > > That is correct; you can't add ddb cmds from modules. It should be doable; just hasn't been done yet. Sam