On Tue, Jun 19, 2018 at 11:00:32AM -0400, Mike Snitzer wrote:
>
> On Tue, Jun 19 2018 at 10:43am -0400,
> Joe Thornber wrote:
>
> > On Tue, Jun 19, 2018 at 09:11:06AM -0400, Mike Snitzer wrote:
> > > On Mon, May 21 2018 at 8:53pm -0400,
> > > Monty Pavel wrote:
> > >
> > > >
> > > > If
On Tue, Jun 19 2018 at 10:43am -0400,
Joe Thornber wrote:
> On Tue, Jun 19, 2018 at 09:11:06AM -0400, Mike Snitzer wrote:
> > On Mon, May 21 2018 at 8:53pm -0400,
> > Monty Pavel wrote:
> >
> > >
> > > If dm_bufio_write_dirty_buffers func is called by __commit_transaction
> > > func and
On Tue, Jun 19, 2018 at 09:11:06AM -0400, Mike Snitzer wrote:
> On Mon, May 21 2018 at 8:53pm -0400,
> Monty Pavel wrote:
>
> >
> > If dm_bufio_write_dirty_buffers func is called by __commit_transaction
> > func and power loss happens during executing it, coincidencely
> > superblock wrote
On Mon, May 21 2018 at 8:53pm -0400,
Monty Pavel wrote:
>
> If dm_bufio_write_dirty_buffers func is called by __commit_transaction
> func and power loss happens during executing it, coincidencely
> superblock wrote correctly but some metadata blocks didn't. The reason
> is we write all
On 2018/6/19 12:52 PM, Christoph Hellwig wrote:
> We immediately overwrite the biovec array, so instead just allocate
> a new bio and copy over the disk, setor and size.
>
> Signed-off-by: Christoph Hellwig
It looks good to me. Acked-by: Coly Li
Thanks.
Coly Li
> ---
>
The nbits == 0 is safe to be supplied to the function body, so,
remove unnecessary checks in bitmap_to_arr32() and bitmap_from_arr32().
Acked-by: Yury Norov
Signed-off-by: Andy Shevchenko
---
lib/bitmap.c | 9 +
1 file changed, 1 insertion(+), 8 deletions(-)
diff --git a/lib/bitmap.c
bitmap API (include/linux/bitmap.h) has 'bitmap' prefix for its methods.
On the other hand MD bitmap API is special case.
Adding 'md' prefix to it to avoid name space collision.
No functional changes intended.
Signed-off-by: Andy Shevchenko
---
drivers/md/dm-raid.c |
A lot of code become ugly because of open coding allocations for bitmaps.
Introduce three helpers to allow users be more clear of intention
and keep their code neat.
Signed-off-by: Andy Shevchenko
---
include/linux/bitmap.h | 8
lib/bitmap.c | 19 +++
2
A lot of code is using allocation of bitmaps using BITS_PER_LONG() macro and
sizeof(unsigned long) operator. The readability suffers because of this.
The series introduces three helpers, i.e. bitmap_alloc(), bitmap_zalloc() and
bitmap_free(), to make it more cleaner.
Patch 1 is a preparatory to
Switch to bitmap_zalloc() to show clearly what we are allocating.
Besides that it returns pointer of bitmap type instead of opaque void *.
Acked-by: Dmitry Torokhov
Signed-off-by: Andy Shevchenko
---
drivers/input/keyboard/gpio_keys.c | 8
1 file changed, 4 insertions(+), 4
On Mon, Jun 18, 2018 at 2:14 PM Andrew Morton wrote:
>
> On Mon, 18 Jun 2018 16:10:01 +0300 Andy Shevchenko
> wrote:
>
> > A lot of code become ugly because of open coding allocations for bitmaps.
> >
> > Introduce three helpers to allow users be more clear of intention
> > and keep their code
On Tue, Jun 19, 2018 at 2:10 AM, Andrew Morton
wrote:
> On Mon, 18 Jun 2018 15:01:43 -0700 Dmitry Torokhov
> wrote:
>
>> > > +unsigned long *bitmap_alloc(unsigned int nbits, gfp_t flags)
>> > > +{
>> > > + return kmalloc_array(BITS_TO_LONGS(nbits), sizeof(unsigned long),
>> > > flags);
>>
Switch to bitmap API, i.e. bitmap_alloc(), bitmap_zalloc(), to show
clearly what we are allocating. Besides that it returns pointer of
bitmap type instead of opaque void *.
While here, replace memcpy() with bitmap_copy() for sake of consistency.
Acked-by: Dmitry Torokhov
Signed-off-by: Andy
On Sat, 2018-06-16 at 12:16 -0700, Joe Perches wrote:
> On Sat, 2018-06-16 at 21:45 +0300, Andy Shevchenko wrote:
> > On Sat, Jun 16, 2018 at 12:46 AM Yury Norov > om> wrote:
> > > On Fri, Jun 15, 2018 at 04:20:17PM +0300, Andy Shevchenko wrote:
> > > > Switch to bitmap_zalloc() to show clearly
On Mon, 2018-06-18 at 09:44 -0400, Mike Snitzer wrote:
> On Mon, Jun 18 2018 at 9:09am -0400,
> Andy Shevchenko wrote:
>
> > bitmap API (include/linux/bitmap.h) has 'bitmap' prefix for its
> > methods.
> >
> > On the other hand MD bitmap API is special case.
> > Adding 'md' prefix to it to
On Tue, Jun 19, 2018 at 1:01 AM, Dmitry Torokhov
wrote:
> On Mon, Jun 18, 2018 at 2:14 PM Andrew Morton
> wrote:
>>
>> On Mon, 18 Jun 2018 16:10:01 +0300 Andy Shevchenko
>> wrote:
>>
>> > A lot of code become ugly because of open coding allocations for bitmaps.
>> >
>> > Introduce three
16 matches
Mail list logo