All of lore.kernel.org
 help / color / mirror / Atom feed
From: Sven Geggus <lists@fuchsschwanzdomain.de>
To: "J. Bruce Fields" <bfields@fieldses.org>
Cc: linux-nfs@vger.kernel.org, Eldad Zack <eldad@fogrefinery.com>
Subject: Re: Kernel update 3.5.7 -> 3.6.3 breaks NFS4
Date: Thu, 15 Nov 2012 17:58:24 +0100	[thread overview]
Message-ID: <20121115165823.GA5505@geggus.net> (raw)
In-Reply-To: <20121114160808.GH23604@fieldses.org>

J. Bruce Fields schrieb am Mittwoch, den 14. November um 17:08 Uhr:

> commit 8688bcb10bd006111b1b46c23a27081ea359e140
> Author: J. Bruce Fields <bfields@redhat.com>
> Date:   Wed Nov 14 10:48:05 2012 -0500
> 
>     svcrpc: Revert "sunrpc/cache.h: replace simple_strtoul"
>     
>     Commit bbf43dc888833ac0539e437dbaeb28bfd4fbab9f "sunrpc/cache.h: replace
>     simple_strtoul" introduced new range-checking which could cause get_int
>     to fail on unsigned integers to large to be represented as an int.
>     
>     We could parse them as unsigned instead--but it turns out svcgssd is
>     actually passing down "-1" in some cases.  Which is perhaps stupid, but
>     there's nothing we can do about it now.
>     
>     So just revert back to the previous "sloppy" behavior that accepts
>     either representation.
>     
>     Signed-off-by: J. Bruce Fields <bfields@redhat.com>
> 
> diff --git a/include/linux/sunrpc/cache.h b/include/linux/sunrpc/cache.h
> index f792794..5dc9ee4 100644
> --- a/include/linux/sunrpc/cache.h
> +++ b/include/linux/sunrpc/cache.h
> @@ -217,6 +217,8 @@ extern int qword_get(char **bpp, char *dest, int bufsize);
>  static inline int get_int(char **bpp, int *anint)
>  {
>  	char buf[50];
> +	char *ep;
> +	int rv;
>  	int len = qword_get(bpp, buf, sizeof(buf));
>  
>  	if (len < 0)
> @@ -224,9 +226,11 @@ static inline int get_int(char **bpp, int *anint)
>  	if (len == 0)
>  		return -ENOENT;
>  
> -	if (kstrtoint(buf, 0, anint))
> +	rv = simple_strtol(buf, &ep, 0);
> +	if (*ep)
>  		return -EINVAL;
>  
> +	*anint = rv;
>  	return 0;
>  }

OK, so this can be marked as resolved (for now) on my todo list, right? Will
this go into 3.6.7 and of course 3.7?

Sven

-- 
"Those who do not understand Unix are condemned to reinvent it, poorly"
(Henry Spencer)

/me is giggls@ircnet, http://sven.gegg.us/ on the Web

  reply	other threads:[~2012-11-15 16:58 UTC|newest]

Thread overview: 29+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-10-26 15:58 Kernel update 3.5.7 -> 3.6.3 breaks NFS4 Sven Geggus
2012-10-26 16:39 ` VDR User
2012-10-31 12:47   ` Sven Geggus
2012-10-26 17:15 ` J. Bruce Fields
     [not found]   ` <20121029094038.GA14836@geggus.net>
2012-10-29 15:02     ` J. Bruce Fields
2012-10-29 16:33       ` Sven Geggus
2012-10-29 22:09         ` J. Bruce Fields
2012-10-31 12:52         ` Sven Geggus
2012-10-31 14:28           ` VDR User
2012-10-31 15:33             ` Sven Geggus
2012-10-31 17:43               ` VDR User
2012-11-05 14:45                 ` Sven Geggus
2012-11-05 16:55       ` Sven Geggus
2012-11-09 18:45         ` Sven Geggus
2012-11-09 20:07           ` J. Bruce Fields
2012-11-09 20:09             ` J. Bruce Fields
2012-11-09 22:45             ` Sven Geggus
2012-11-09 23:24               ` J. Bruce Fields
2012-11-12  9:17                 ` Sven Geggus
2012-11-13 22:40                   ` J. Bruce Fields
2012-11-14  0:58                     ` J. Bruce Fields
2012-11-14 16:07                       ` J. Bruce Fields
2012-11-14 16:08                         ` J. Bruce Fields
2012-11-15 16:58                           ` Sven Geggus [this message]
2012-11-16 19:19                             ` J. Bruce Fields
2012-12-12 11:15                               ` Sven Geggus
2012-12-12 18:57                                 ` J. Bruce Fields
2012-11-14 22:26                         ` Eldad Zack
2012-11-09 23:17             ` Eldad Zack

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=20121115165823.GA5505@geggus.net \
    --to=lists@fuchsschwanzdomain.de \
    --cc=bfields@fieldses.org \
    --cc=eldad@fogrefinery.com \
    --cc=linux-nfs@vger.kernel.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.