[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAHp75Vd6JLjPfrA4f2ugwfiZS3fBSxN48ja7OjnZ4s_pqWJZng@mail.gmail.com>
Date: Thu, 9 Jan 2020 23:04:59 +0200
From: Andy Shevchenko <andy.shevchenko@...il.com>
To: Andrew Morton <akpm@...ux-foundation.org>
Cc: Andy Shevchenko <andriy.shevchenko@...ux.intel.com>,
Rasmus Villemoes <linux@...musvillemoes.dk>,
Yury Norov <yury.norov@...il.com>,
Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
Guenter Roeck <linux@...ck-us.net>
Subject: Re: [PATCH v2 2/2] lib/test_bitmap: Fix address space when test user buffer
On Thu, Jan 9, 2020 at 10:53 PM Andrew Morton <akpm@...ux-foundation.org> wrote:
>
> On Thu, 9 Jan 2020 12:36:01 +0200 Andy Shevchenko <andriy.shevchenko@...ux.intel.com> wrote:
>
> > Force address space to avoid the following warning:
> >
> > lib/test_bitmap.c:461:53: warning: incorrect type in argument 1 (different address spaces)
> > lib/test_bitmap.c:461:53: expected char const [noderef] <asn:1> *ubuf
> > lib/test_bitmap.c:461:53: got char const *in
>
> We did this in
>
> commit 17b6753ff08bc47f50da09f5185849172c598315
> Author: Andy Shevchenko <andriy.shevchenko@...ux.intel.com>
> AuthorDate: Wed Dec 4 16:53:06 2019 -0800
> Commit: Linus Torvalds <torvalds@...ux-foundation.org>
> CommitDate: Wed Dec 4 19:44:14 2019 -0800
>
> lib/test_bitmap: force argument of bitmap_parselist_user() to proper address space
This is for "parseLIST", while new patch for "parse".
>
> > --- a/lib/test_bitmap.c
> > +++ b/lib/test_bitmap.c
> > @@ -458,7 +458,8 @@ static void __init __test_bitmap_parse(int is_user)
> >
> > set_fs(KERNEL_DS);
> > time = ktime_get();
> > - err = bitmap_parse_user(test.in, len, bmap, test.nbits);
> > + err = bitmap_parse_user((__force const char __user *)test.in, len,
> > + bmap, test.nbits);
> > time = ktime_get() - time;
> > set_fs(orig_fs);
> > } else {
>
> Except your tree has `test' where mainline has `ptest'. I'm not sure
> what has happened here?
>
--
With Best Regards,
Andy Shevchenko
Powered by blists - more mailing lists