Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754111Ab0LFSQZ (ORCPT ); Mon, 6 Dec 2010 13:16:25 -0500 Received: from waste.org ([173.11.57.241]:45619 "EHLO waste.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752960Ab0LFSQX (ORCPT ); Mon, 6 Dec 2010 13:16:23 -0500 Subject: Re: [PATCH 0/7] printk: add pr__once, guard print_hex_dump From: Matt Mackall To: Joe Perches Cc: Andrew Morton , Paul Gortmaker , David Woodhouse , linux-embedded@vger.kernel.org, linux-kernel@vger.kernel.org In-Reply-To: <1291659120.17494.179.camel@Joe-Laptop> References: <1291649869.3065.2095.camel@calx> <1291659120.17494.179.camel@Joe-Laptop> Content-Type: text/plain; charset="UTF-8" Date: Mon, 06 Dec 2010 12:16:20 -0600 Message-ID: <1291659380.3065.2214.camel@calx> Mime-Version: 1.0 X-Mailer: Evolution 2.30.3 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1304 Lines: 31 On Mon, 2010-12-06 at 10:12 -0800, Joe Perches wrote: > On Mon, 2010-12-06 at 09:37 -0600, Matt Mackall wrote: > > On Sun, 2010-12-05 at 21:44 -0800, Joe Perches wrote: > > > There are many uses of printk_once(KERN_. > > > Add pr__once macros to avoid printk_once(KERN_ pr_fmt(fmt). > > > Add an #ifdef CONFIG_PRINTK for print_hex_dump and static inline void > > > functions for the #else cases to reduce embedded code size. > > > Neaten and organize the rest of the code. > > Looks fine to me. I'd missed the introduction of the pr_ macros > > and I'm not sure if I like the idea, but this is a tidy and > > well-presented cleanup and extension. > > Acked-by: Matt Mackall > > The #ifdef CONFIG_PRINTK guard for print_hex_dump saves ~200 > bytes in an x86 !CONFIG_PRINTK > > There could be ~500 bytes more saved if hex_dump_to_buffer > was compiled out. Can't say I'm excited by this approach. .5k is under my threshold for this level of invasiveness. -- Mathematics is the supreme nostalgia of our time. -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/