mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Felipe Contreras <felipe.contreras@gmail.com>
To: linux-kernel@vger.kernel.org
Cc: Rusty Russell <rusty@rustcorp.com.au>,
	Ingo Molnar <mingo@elte.hu>,
	Linus Torvalds <torvalds@linux-foundation.org>,
	Andrew Morton <akpm@linux-foundation.org>,
	Levente Kurusa <levex@linux.com>,
	Felipe Contreras <felipe.contreras@gmail.com>
Subject: [PATCH 1/5] kstrtox: remove redundant cleanup
Date: Sat, 16 Nov 2013 11:32:27 -0600	[thread overview]
Message-ID: <1384623151-31302-2-git-send-email-felipe.contreras@gmail.com> (raw)
In-Reply-To: <1384623151-31302-1-git-send-email-felipe.contreras@gmail.com>

We can't reach the cleanup code unless the flag KSTRTOX_OVERFLOW is not
set, so there's not no point in clearing a bit that we know is not set.

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
---
 lib/kstrtox.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/lib/kstrtox.c b/lib/kstrtox.c
index f78ae0c..ec8da78 100644
--- a/lib/kstrtox.c
+++ b/lib/kstrtox.c
@@ -92,7 +92,6 @@ static int _kstrtoull(const char *s, unsigned int base, unsigned long long *res)
 	rv = _parse_integer(s, base, &_res);
 	if (rv & KSTRTOX_OVERFLOW)
 		return -ERANGE;
-	rv &= ~KSTRTOX_OVERFLOW;
 	if (rv == 0)
 		return -EINVAL;
 	s += rv;
-- 
1.8.4.2+fc1


  reply	other threads:[~2013-11-16 17:39 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-11-16 17:32 [PATCH 0/5] Command line related cleanups Felipe Contreras
2013-11-16 17:32 ` Felipe Contreras [this message]
2013-11-16 20:19   ` [PATCH 1/5] kstrtox: remove redundant cleanup Levente Kurusa
2013-11-16 17:32 ` [PATCH 2/5] cmdline: fix style issues Felipe Contreras
2013-11-16 17:32 ` [PATCH 3/5] cmdline: declare exported symbols immediately Felipe Contreras
2013-11-16 20:21   ` Levente Kurusa
2013-11-16 20:27     ` Felipe Contreras
2013-11-16 17:32 ` [PATCH 4/5] kstrtox: remove redundant casts Felipe Contreras
2013-11-16 17:32 ` [PATCH 5/5] params: improve standard definitions Felipe Contreras
2013-11-21  1:43   ` Rusty Russell

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1384623151-31302-2-git-send-email-felipe.contreras@gmail.com \
    --to=felipe.contreras@gmail.com \
    --cc=akpm@linux-foundation.org \
    --cc=levex@linux.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@elte.hu \
    --cc=rusty@rustcorp.com.au \
    --cc=torvalds@linux-foundation.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®