Received: by 2002:a25:4158:0:0:0:0:0 with SMTP id o85csp1449643yba; Thu, 9 May 2019 17:18:07 -0700 (PDT) X-Google-Smtp-Source: APXvYqzsPb8QxmPqF7tqgs+HkAsPJTLHfBXjGIFDn1Uiv7eUDimzGlQ07grqqKZNLTeDBZ/onItC X-Received: by 2002:a63:7146:: with SMTP id b6mr3555577pgn.426.1557447486906; Thu, 09 May 2019 17:18:06 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1557447486; cv=none; d=google.com; s=arc-20160816; b=BvBCGEXlRjdBknHAwRpWvBolYeMKfp01h0OzrPKp8xqfj77Rw53qYHz1ETLHmPmfH7 dMtED8mDkBK0LgUm8noYeADDr/1Q9twVcSUUJkInd2PYwQ4yWvuRp4r8pY4ddS5hPG41 cXd/6geqSrwRas6+F049Lr7ZJjm5KPpNzNRMpPB+kltnjs8Xjq9PMWBrZgVDrUIt3UJX 1AbBfY5zrNXTFYhxedU+2sDlLnWs4Taem3C+UHH1rqFAlRiiSpw7ujM3ElFi7IlQAIao b7p3th8sm9CDyZ0AypzttyJb6/u35spH6DyQ2DEayP3gft1bFKwx/PgfPe4FCHh60J2t j6hg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:date:cc:to:from:subject :message-id:dkim-signature; bh=T7bYSQwhNYi2blWzJaCVc92DRNOgYM/SGpAsu+2vg2M=; b=s9gNm0N6sZNf5hpQy8A6+jq0zSKecF9IJdPtz6QjfoC3+7ALvmwL8IfYCwbLTvtBxv ZXD02eFbN8iIqNUGtBtKy+czQCspXPrSVC1D1rTZaKX9yIpIR+WNP/K1Kp8iAGjmmVAS /4aHRSdTv8JXV6g/bQg9XQyaihnvAaIi3EcGZSMaX4cbEQSZc953mfdQMf84JqPRXcQT CtH5OerHVb6syKgwmJUeBNK7qZfVYSv60lsezVcGmVpV5yINeHGSkV3DerEpnLnemT98 EAGtLuu3nqfQ9OIgtH/4F4b2VAml8ziNieZJaJAESsisKpOA4xSTesWOI0LRUTnl2YdB jlag== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@d-silva.org header.s=201810a header.b=FgHPIPlY; spf=pass (google.com: best guess record for domain of linux-wireless-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id o12si5104380plg.262.2019.05.09.17.17.35; Thu, 09 May 2019 17:18:06 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-wireless-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@d-silva.org header.s=201810a header.b=FgHPIPlY; spf=pass (google.com: best guess record for domain of linux-wireless-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726802AbfEJAR2 (ORCPT + 99 others); Thu, 9 May 2019 20:17:28 -0400 Received: from [66.55.73.32] ([66.55.73.32]:51484 "EHLO ushosting.nmnhosting.com" rhost-flags-FAIL-FAIL-OK-OK) by vger.kernel.org with ESMTP id S1726694AbfEJAR1 (ORCPT ); Thu, 9 May 2019 20:17:27 -0400 Received: from mail2.nmnhosting.com (unknown [202.169.106.97]) by ushosting.nmnhosting.com (Postfix) with ESMTPS id B6DC82DC0070; Thu, 9 May 2019 20:17:22 -0400 (EDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=d-silva.org; s=201810a; t=1557447443; bh=rJY0+D6TdRtTv0MtwykFJbYOSu46lpL7vkuRS2Zg75k=; h=Subject:From:To:Cc:Date:In-Reply-To:References:From; b=FgHPIPlYLmuLNtrMoQ1JdXOJBzIramXRU528FDdwgmUbYDUSurbrKOmk66MlGYzGl 0ruDR9MsmWn6Wa1JGtiiUa7MDmH9NnRiXxafLrfVNihMUrJYoUiQlr9ZF1I4HIM0PV bZ9W5c9BAYVyzA9PfwGf5o+hGD2hYyBjKLixvrQ1vno4Whs2Nw5LmAFMtjJBE96JB5 3A/TpZPKlUH/LZ9QviX5sPNxejvENaMBIYUal2Z2Hup4BijYTYYiF1F+eWLEYbhMu2 YBrAElUv44shUa1aHwy6Pfl3sYtAppFsneNmta4kToubNSSN/EMWCAgt+GOmMNuiZU dScx2/r4DfVPHVsLyA/C0IlAGJW5xx1NFqr3GJcu3u2ljmH/j2VABFWX8mKiViOjya UMzCeSKOTZj7GhaZKQ4wNLMdnnGeX0xRzwZxBPPwQPpa98wFjqGa4P4+HDIkphprBS cLR2rNyVdb5sI8TuETSE/d/sK5ExHhfuWol5Jk5PXVNE/IO16n6e0dCf3bBoCa8bTw zs4jlO1owv47NzN5dYrbV7R3mEfn3Wk/R8zsonqePsZtnUOe/9EZUeGRp5ITrVsRIK bdLoMtcOXzpm23UAwIN2Fr4caFvxOuuMjHxqg9nDMraA52HHWsxcudXZEv+JQvxYxU WRl4Hh/Ieej3f+hWeieXK7mA= Received: from adsilva.ozlabs.ibm.com (static-82-10.transact.net.au [122.99.82.10] (may be forged)) (authenticated bits=0) by mail2.nmnhosting.com (8.15.2/8.15.2) with ESMTPSA id x4A0GhJ3030327 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=NO); Fri, 10 May 2019 10:17:01 +1000 (AEST) (envelope-from alastair@d-silva.org) Message-ID: <80e51facb280e96018a4220adf8efa6fac823a94.camel@d-silva.org> Subject: Re: [PATCH v2 3/7] lib/hexdump.c: Optionally suppress lines of repeated bytes From: "Alastair D'Silva" To: Randy Dunlap Cc: linux-fbdev@vger.kernel.org, Stanislaw Gruszka , Petr Mladek , David Airlie , Joonas Lahtinen , dri-devel@lists.freedesktop.org, devel@driverdev.osuosl.org, linux-scsi@vger.kernel.org, Jassi Brar , ath10k@lists.infradead.org, intel-gfx@lists.freedesktop.org, Dan Carpenter , Jose Abreu , Tom Lendacky , "James E.J. Bottomley" , Jani Nikula , linux-fsdevel@vger.kernel.org, Steven Rostedt , Rodrigo Vivi , Benson Leung , Kalle Valo , Karsten Keil , "Martin K. Petersen" , Greg Kroah-Hartman , linux-wireless@vger.kernel.org, linux-kernel@vger.kernel.org, Sergey Senozhatsky , David Laight , Daniel Vetter , netdev@vger.kernel.org, Enric Balletbo i Serra , Andrew Morton , "David S. Miller" , Alexander Viro Date: Fri, 10 May 2019 10:16:42 +1000 In-Reply-To: References: <20190508070148.23130-1-alastair@au1.ibm.com> <20190508070148.23130-4-alastair@au1.ibm.com> Content-Type: text/plain; charset="UTF-8" User-Agent: Evolution 3.32.1 (3.32.1-1.fc30) MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.6.2 (mail2.nmnhosting.com [10.0.1.20]); Fri, 10 May 2019 10:17:17 +1000 (AEST) Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org On Wed, 2019-05-08 at 17:58 -0700, Randy Dunlap wrote: > On 5/8/19 12:01 AM, Alastair D'Silva wrote: > > From: Alastair D'Silva > > > > Some buffers may only be partially filled with useful data, while > > the rest > > is padded (typically with 0x00 or 0xff). > > > > This patch introduces a flag to allow the supression of lines of > > repeated > > bytes, which are replaced with '** Skipped %u bytes of value 0x%x > > **' > > > > An inline wrapper function is provided for backwards compatibility > > with > > existing code, which maintains the original behaviour. > > > > Signed-off-by: Alastair D'Silva > > --- > > include/linux/printk.h | 25 +++++++++--- > > lib/hexdump.c | 91 ++++++++++++++++++++++++++++++++++++ > > ------ > > 2 files changed, 99 insertions(+), 17 deletions(-) > > > > Hi, > Did you do "make htmldocs" or something similar on this? > > > diff --git a/lib/hexdump.c b/lib/hexdump.c > > index 3943507bc0e9..d61a1e4f19fa 100644 > > --- a/lib/hexdump.c > > +++ b/lib/hexdump.c > > @@ -212,8 +212,44 @@ int hex_dump_to_buffer(const void *buf, size_t > > len, int rowsize, int groupsize, > > EXPORT_SYMBOL(hex_dump_to_buffer); > > > > #ifdef CONFIG_PRINTK > > + > > +/** > > + * Check if a buffer contains only a single byte value > > + * @buf: pointer to the buffer > > + * @len: the size of the buffer in bytes > > + * @val: outputs the value if if the bytes are identical > > Does this work without a function name? > Documentation/doc-guide/kernel-doc.rst says the general format is: > > /** > * function_name() - Brief description of function. > * @arg1: Describe the first argument. > * @arg2: Describe the second argument. > * One can provide multiple line descriptions > * for arguments. > * > > > + */ > > /** > > - * print_hex_dump - print a text hex dump to syslog for a binary > > blob of data > > + * print_hex_dump_ext: dump a binary blob of data to syslog in > > hexadecimal > > Also not in the general documented format. > Thanks Randy, I'll address these. -- Alastair D'Silva mob: 0423 762 819 skype: alastair_dsilva Twitter: @EvilDeece blog: http://alastair.d-silva.org