Skip to content

lib/vsprintf: introduce stricter rules for %p extensions

Andy Shevchenko lkml 2 versions – New

Get series with b4
b4 am 1451407358-7041-1-git-send-email-andriy.shevchenko@linux.intel.com

Versions newest first · linked by author and title

  1. v2 Latest2 patches 0 repliesNew
  2. v11 patch 9 repliesSuperseded

Changes in v2 from the cover letter

- address comments from Joe and Rasmums (might be not all of them)
- add patch 2
- desribe in cover letter what is done besides refactoring

Patches in v2 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/2lib/vsprintf: refactor duplicate code to special_hex_number()lib/vsprintf.c+27 -260 replies
2/2lib/vsprintf: factor out %pN[F] handler as netdev_bits()lib/vsprintf.c+16 -90 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v2 yet.

Read the v2 thread

Cover letter [PATCH v2 0/2] lib/vsprintf: introduce stricter rules for %p extensions

Besides the code refactoring we introduce the following rules for %p extensions here. i.e:

- fixed type extensions are always printed in hex format, prefixed by '0x', small letters, full field width on a running architecture (%pa[dp], %pNF)

- fallback to %p based on different kernel configuration will be under the same rule set as for fixed types above (%pCn when COMMON_CLK=n, %p[FfSsB] when KALLSYMS=n)

- fallback to %p of unimplemented extension will be under the same rule set as for fixed types above (%pN)

Since v1:
- address comments from Joe and Rasmums (might be not all of them)
- add patch 2
- desribe in cover letter what is done besides refactoring

Andy Shevchenko (2):
lib/vsprintf: refactor duplicate code to special_hex_number() lib/vsprintf: factor out %pN[F] handler as netdev_bits()

 lib/vsprintf.c | 70 ++++++++++++++++++++++++++++++++--------------------------
 1 file changed, 39 insertions(+), 31 deletions(-)
Signature · 1 line
2.6.4