From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1L119L-0000X0-3R for qemu-devel@nongnu.org; Fri, 14 Nov 2008 11:03:59 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1L119K-0000WV-JR for qemu-devel@nongnu.org; Fri, 14 Nov 2008 11:03:58 -0500 Received: from [199.232.76.173] (port=43483 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1L119K-0000WQ-6O for qemu-devel@nongnu.org; Fri, 14 Nov 2008 11:03:58 -0500 Received: from mx2.redhat.com ([66.187.237.31]:49815) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1L119K-0007GK-7p for qemu-devel@nongnu.org; Fri, 14 Nov 2008 11:03:58 -0500 From: Mark McLoughlin In-Reply-To: <491C8520.5040005@codemonkey.ws> References: <> <1226594763-2304-1-git-send-email-markmc@redhat.com> <1226594763-2304-2-git-send-email-markmc@redhat.com> <1226594763-2304-3-git-send-email-markmc@redhat.com> <1226594763-2304-4-git-send-email-markmc@redhat.com> <1226594763-2304-5-git-send-email-markmc@redhat.com> <1226594763-2304-6-git-send-email-markmc@redhat.com> <491C8520.5040005@codemonkey.ws> Content-Type: text/plain Date: Fri, 14 Nov 2008 16:02:43 +0000 Message-Id: <1226678563.9332.98.camel@blaa> Mime-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: [Qemu-devel] Re: [PATCH 5/5] monitor: add "info capabilities" command Reply-To: Mark McLoughlin , qemu-devel@nongnu.org List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Anthony Liguori Cc: qemu-devel@nongnu.org On Thu, 2008-11-13 at 13:50 -0600, Anthony Liguori wrote: > Mark McLoughlin wrote: > > +static void do_info_capabilities(void) > > +{ > > + term_printf("[qemu]\n"); > > + list_printf("accel", accel_names); > > + term_printf("arch=%s\n", TARGET_ARCH); > > + list_printf("cpu", cpu_names()); > > + machines_printf(); > > + > > + term_printf("\n"); > > + > > + do_machine_capabilities(); > > + > > + term_printf("[devices]\n"); > > + list_printf("bluetooth", bt_list_types()); > > + list_printf("char", qemu_chr_list_types()); > > + list_printf("drive_cache", drive_cache_types()); > > + list_printf("drive_if", drive_if_types()); > > + list_printf("graphics", graphics_list_types()); > > + list_printf("network", net_client_types()); > > +#ifdef HAS_AUDIO > > + list_printf("soundhw", soundhw_list_types()); > > +#endif > > + list_printf("vga", vga_list_types()); > > + > > + term_printf("\n"); > > > > This makes me uneasy because it introduces a lot of dependencies that > are going to be hard to break. I think this level of logic needs to be > more encapsulated in the various subsystems. So, something like have [network], [block], [audio] etc. sections and call out to network_capabilities() etc.? Cheers, Mark.