The patch titled vsprintf: factor out skip_space code in a separate function has been removed from the -mm tree. Its filename was vsprintf-factor-out-skip_space-code-in-a-separate-function.patch This patch was dropped because it was merged into mainline or a subsystem tree The current -mm tree may be found at http://userweb.kernel.org/~akpm/mmotm/ ------------------------------------------------------ Subject: vsprintf: factor out skip_space code in a separate function From: André Goddard Rosa <andre.goddard@xxxxxxxxx> When converting more caller sites, the inline decision will be left up to gcc. It decreases code size: text data bss dec hex filename 15710 0 8 15718 3d66 vsprintf.o (ex lib/lib.a-BEFORE) 15534 0 8 15542 3cb6 vsprintf.o (ex lib/lib.a-AFTER) Signed-off-by: André Goddard Rosa <andre.goddard@xxxxxxxxx> Acked-by: Frederic Weisbecker <fweisbec@xxxxxxxxx> Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx> --- lib/vsprintf.c | 19 +++++++++++-------- 1 file changed, 11 insertions(+), 8 deletions(-) diff -puN lib/vsprintf.c~vsprintf-factor-out-skip_space-code-in-a-separate-function lib/vsprintf.c --- a/lib/vsprintf.c~vsprintf-factor-out-skip_space-code-in-a-separate-function +++ a/lib/vsprintf.c @@ -1786,6 +1786,13 @@ EXPORT_SYMBOL_GPL(bprintf); #endif /* CONFIG_BINARY_PRINTF */ +static noinline char *skip_space(const char *str) +{ + while (isspace(*str)) + ++str; + return (char *)str; +} + /** * vsscanf - Unformat a buffer into a list of arguments * @buf: input buffer @@ -1807,10 +1814,8 @@ int vsscanf(const char *buf, const char * white space, including none, in the input. */ if (isspace(*fmt)) { - while (isspace(*fmt)) - ++fmt; - while (isspace(*str)) - ++str; + fmt = skip_space(fmt); + str = skip_space(str); } /* anything that is not a conversion must match exactly */ @@ -1880,8 +1885,7 @@ int vsscanf(const char *buf, const char if (field_width == -1) field_width = INT_MAX; /* first, skip leading white space in buffer */ - while (isspace(*str)) - str++; + str = skip_space(str); /* now copy until next white space */ while (*str && !isspace(*str) && field_width--) @@ -1923,8 +1927,7 @@ int vsscanf(const char *buf, const char /* have some sort of integer conversion. * first, skip white space in buffer. */ - while (isspace(*str)) - str++; + str = skip_space(str); digit = *str; if (is_sign && digit == '-') _ Patches currently in -mm which might be from andre.goddard@xxxxxxxxx are origin.patch pid-tighten-pidmap-spinlock-critical-section-by-removing-kfree.patch pid-reduce-code-size-by-using-a-pointer-to-iterate-over-array.patch -- To unsubscribe from this list: send the line "unsubscribe mm-commits" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html