linux-ext4.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Shuah Khan <skhan@linuxfoundation.org>
To: Iurii Zaikin <yzaikin@google.com>,
	brendanhiggins@google.com, tytso@mit.edu, geert@linux-m68k.org
Cc: linux-ext4@vger.kernel.org, linux-kselftest@vger.kernel.org,
	kunit-dev@googlegroups.com,
	"skh >> Shuah Khan" <skhan@linuxfoundation.org>
Subject: Re: [PATCH] fs/ext4/inode-test: Fix inode test on 32 bit platforms.
Date: Tue, 26 Nov 2019 17:33:03 -0700	[thread overview]
Message-ID: <41d22ac8-7907-6bcf-883f-27518506b87f@linuxfoundation.org> (raw)
In-Reply-To: <20191127001023.63271-1-yzaikin@google.com>

On 11/26/19 5:10 PM, Iurii Zaikin wrote:
> Fixes the issue caused by the fact that in C in the expression
> of the form -1234L only 1234L is the actual literal, the unary
> minus is an operation applied to the literal. Which means that
> to express the lower bound for the type one has to negate the
> upper bound and subtract 1.
> 
> Signed-off-by: Iurii Zaikin <yzaikin@google.com>

Thanks for sending the patch quickly.

Please add Reported-by for Geert and also include the error he is
seeing in the commit log.
> ---
>   fs/ext4/inode-test.c | 2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/fs/ext4/inode-test.c b/fs/ext4/inode-test.c
> index 92a9da1774aa..bbce1c328d85 100644
> --- a/fs/ext4/inode-test.c
> +++ b/fs/ext4/inode-test.c
> @@ -25,7 +25,7 @@
>    * For constructing the negative timestamp lower bound value.
>    * binary: 10000000 00000000 00000000 00000000
>    */
> -#define LOWER_MSB_1 (-0x80000000L)
> +#define LOWER_MSB_1 (-(UPPER_MSB_0) - 1L)  /* avoid overflow */
>   /*
>    * For constructing the negative timestamp upper bound value.
>    * binary: 11111111 11111111 11111111 11111111
> --
> 2.24.0.432.g9d3f5f5b63-goog
> 

thanks,
-- Shuah

  reply	other threads:[~2019-11-27  0:33 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-11-27  0:10 [PATCH] fs/ext4/inode-test: Fix inode test on 32 bit platforms Iurii Zaikin
2019-11-27  0:33 ` Shuah Khan [this message]
2019-11-27  0:37   ` Iurii Zaikin
2019-11-27  0:37 Iurii Zaikin
2019-11-27  7:29 ` Geert Uytterhoeven
2019-11-27 18:55 Iurii Zaikin
2019-12-02 16:18 ` Brendan Higgins

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=41d22ac8-7907-6bcf-883f-27518506b87f@linuxfoundation.org \
    --to=skhan@linuxfoundation.org \
    --cc=brendanhiggins@google.com \
    --cc=geert@linux-m68k.org \
    --cc=kunit-dev@googlegroups.com \
    --cc=linux-ext4@vger.kernel.org \
    --cc=linux-kselftest@vger.kernel.org \
    --cc=tytso@mit.edu \
    --cc=yzaikin@google.com \
    /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;
as well as URLs for NNTP newsgroup(s).