On Wed, Nov 18, 2020 at 03:37:47PM +0100, Jan Kara wrote:
> > -static inline dev_t blk_lookup_devt(const char *name, int partno)
> > -{
> > - dev_t devt = MKDEV(0, 0);
> > - return devt;
> > -}
> > #endif /* CONFIG_BLOCK */
>
> This hunk looks unrelated to the change? Also why you move the de
On Wed 18-11-20 09:47:48, Christoph Hellwig wrote:
> The code in devt_from_partuuid is very convoluted. Refactor a bit by
> sanitizing the goto and variable name usage.
>
> Signed-off-by: Christoph Hellwig
The patch looks good to me. You can add:
Reviewed-by: Jan Kara
On Wed 18-11-20 09:47:42, Christoph Hellwig wrote:
> Signed-off-by: Christoph Hellwig
Looks good. You can add:
Reviewed-by: Jan Kara
Honza
> ---
> include/linux/genhd.h | 1 -
> 1 file changed, 1 deletion(-)
>
> diff --git a/in
On Wed 18-11-20 09:47:49, Christoph Hellwig wrote:
> Avoid a totally pointless goto label, and use the same style of
> comparism for both helpers.
>
> Signed-off-by: Christoph Hellwig
OK. You can add:
Reviewed-by: Jan Kara
Honza
On Wed 18-11-20 09:47:50, Christoph Hellwig wrote:
> Reorder the code to have one big section for the last close, and to use
> bdev_is_partition.
>
> Signed-off-by: Christoph Hellwig
Looks good. You can add:
Reviewed-by: Jan Kara
On Wed 18-11-20 09:47:45, Christoph Hellwig wrote:
> Use put_device to put the device instead of poking into the internals
> and using kobject_put.
>
> Signed-off-by: Christoph Hellwig
Looks good. You can add:
Reviewed-by: Jan Kara
On Wed 18-11-20 09:47:43, Christoph Hellwig wrote:
> Add a little helper to find the kobject for a struct block_device.
>
> Signed-off-by: Christoph Hellwig
Looks good. You can add:
Reviewed-by: Jan Kara
Honza
> ---
> drivers/m
On Wed 18-11-20 09:47:46, Christoph Hellwig wrote:
> Adding the minor to the major creates tons of pointless conflicts. Just
> use the dev_t itself, which is 32-bits and thus is guaranteed to fit
> into ino_t.
>
> Signed-off-by: Christoph Hellwig
Fair enough. You can add:
Reviewed-by: Jan Kara
On Wed 18-11-20 09:47:47, Christoph Hellwig wrote:
> Split each case into a self-contained helper.
>
> Signed-off-by: Christoph Hellwig
> ---
> include/linux/genhd.h | 7 +-
> init/do_mounts.c | 183 +-
> 2 files changed, 91 insertions(+), 99 deleti
On Wed 18-11-20 09:47:44, Christoph Hellwig wrote:
> Call disk_part_iter_exit in disk_part_iter_next instead of duplicating
> the functionality.
>
> Signed-off-by: Christoph Hellwig
OK. You can add:
Reviewed-by: Jan Kara
Honza
>
On Wed, 18 Nov 2020, Mike Snitzer wrote:
> On Wed, Nov 18 2020 at 10:49am -0500,
> Mike Snitzer wrote:
>
> > I don't think my suggestion will help.. given it'd still leave
> > persistent_memory_claim() without a return statement.
> >
> > Think it worthwhile to just add a dummy 'return 0;' af
On Wed 18-11-20 09:47:41, Christoph Hellwig wrote:
> disk_get_part needs to be paired with a disk_put_part.
>
> Fixes: ef45fe470e1 ("blk-cgroup: show global disk stats in root cgroup
> io.stat")
> Signed-off-by: Christoph Hellwig
Looks good to me. You can add:
Reviewed-by: Jan Kara
On 11/18/20 8:35 AM, Christian Borntraeger wrote:
>
>
> On 18.11.20 17:07, Mike Snitzer wrote:
>> On Wed, Nov 18 2020 at 10:49am -0500,
>> Mike Snitzer wrote:
>>
>>> I don't think my suggestion will help.. given it'd still leave
>>> persistent_memory_claim() without a return statement.
>>>
>>> T
On 18.11.20 17:07, Mike Snitzer wrote:
> On Wed, Nov 18 2020 at 10:49am -0500,
> Mike Snitzer wrote:
>
>> I don't think my suggestion will help.. given it'd still leave
>> persistent_memory_claim() without a return statement.
>>
>> Think it worthwhile to just add a dummy 'return 0;' after the
On Wed, Nov 18, 2020 at 04:54:51PM +0800, Coly Li wrote:
> On 11/18/20 4:47 PM, Christoph Hellwig wrote:
> > Don't bother to call lookup_bdev for just a slightly different error
> > message without any functional change.
> >
> > Signed-off-by: Christoph Hellwig ist
>
> Hi Christoph,
>
> NACK. Th
On Wed, Nov 18 2020 at 10:49am -0500,
Mike Snitzer wrote:
> I don't think my suggestion will help.. given it'd still leave
> persistent_memory_claim() without a return statement.
>
> Think it worthwhile to just add a dummy 'return 0;' after the BUG().
Decided to go with this, now staged for 5.1
On Tue, Nov 17 2020 at 11:31am -0500,
Mike Snitzer wrote:
> On Mon, Nov 16 2020 at 6:00pm -0500,
> Randy Dunlap wrote:
>
> > On 11/15/20 11:30 PM, Christian Borntraeger wrote:
> > >
> > >
> > > On 13.11.20 23:52, Randy Dunlap wrote:
> > >> Building on arch/s390/ flags this as an error, so ad
I just staged this for 5.11, see:
https://git.kernel.org/pub/scm/linux/kernel/git/device-mapper/linux-dm.git/commit/?h=dm-5.11&id=373ce365b756bf6fec237461a0bbe65f33f201f6
I tweaked your patch header just a bit.
Thanks,
Mike
On Tue, Nov 17 2020 at 9:01pm -0500,
JeffleXu wrote:
> Hi Mike,
>
>
On Wed, Nov 18, 2020 at 10:23:51AM +0100, Jan Beulich wrote:
> On 18.11.2020 10:09, Greg KH wrote:
> > On Wed, Nov 18, 2020 at 10:04:04AM +0100, Jan Beulich wrote:
> >> On 18.11.2020 09:58, Christoph Hellwig wrote:
> >>> On Wed, Nov 18, 2020 at 09:56:11AM +0100, Jan Beulich wrote:
> since this
On 11/18/20 5:10 PM, Greg KH wrote:
> On Wed, Nov 18, 2020 at 04:54:51PM +0800, Coly Li wrote:
>> On 11/18/20 4:47 PM, Christoph Hellwig wrote:
>>> Don't bother to call lookup_bdev for just a slightly different error
>>> message without any functional change.
>>>
>>> Signed-off-by: Christoph Hellwi
On Wed, Nov 18, 2020 at 10:23:51AM +0100, Jan Beulich wrote:
> On 18.11.2020 10:09, Greg KH wrote:
> > On Wed, Nov 18, 2020 at 10:04:04AM +0100, Jan Beulich wrote:
> >> On 18.11.2020 09:58, Christoph Hellwig wrote:
> >>> On Wed, Nov 18, 2020 at 09:56:11AM +0100, Jan Beulich wrote:
> since this
On Wed, Nov 18, 2020 at 10:04:04AM +0100, Jan Beulich wrote:
> On 18.11.2020 09:58, Christoph Hellwig wrote:
> > On Wed, Nov 18, 2020 at 09:56:11AM +0100, Jan Beulich wrote:
> >> since this isn't the first series from you recently spamming
> >> xen-devel, may I ask that you don't Cc entire series t
On Wed, Nov 18, 2020 at 09:47:40AM +0100, Christoph Hellwig wrote:
> Hi Jens,
>
> this series cleans up our main per-device node data structure by merging
> the block_device and hd_struct data structures that have the same scope,
> but different life times. The main effect (besides removing lots
On 11/18/20 4:47 PM, Christoph Hellwig wrote:
> Don't bother to call lookup_bdev for just a slightly different error
> message without any functional change.
>
> Signed-off-by: Christoph Hellwig ist
Hi Christoph,
NACK. This removing error message is frequently triggered and observed,
and distinc
On Wed, Nov 18, 2020 at 04:54:51PM +0800, Coly Li wrote:
> On 11/18/20 4:47 PM, Christoph Hellwig wrote:
> > Don't bother to call lookup_bdev for just a slightly different error
> > message without any functional change.
> >
> > Signed-off-by: Christoph Hellwig ist
>
> Hi Christoph,
>
> NACK. Th
On Wed, Nov 18, 2020 at 10:04:04AM +0100, Jan Beulich wrote:
> That's the view of some people, but not all. Context can be easily
> established by those who care going to one of the many archives on
> which the entire series lands. Getting spammed, however, can't be
> avoided by the dozens or hundr
On Wed, Nov 18, 2020 at 09:56:11AM +0100, Jan Beulich wrote:
> since this isn't the first series from you recently spamming
> xen-devel, may I ask that you don't Cc entire series to lists
> which are involved with perhaps just one out of the many patches?
> IMO Cc lists should be compiled on a per-
Stop passing the whole device as a separate argument given that it
can be trivially deducted.
Signed-off-by: Christoph Hellwig
---
drivers/block/loop.c | 12 +++-
fs/block_dev.c | 69 +++---
include/linux/blkdev.h | 6 ++--
3 files changed, 38 i
Instead of having two structures that represent each block device with
different lift time rules merged them into a single one. This also
greatly simplifies the reference counting rules, as we can use the inode
reference count as the main reference count for the new struct
block_device, with the d
Now that each hd_struct has a reference to the corresponding
block_device, there is no need for the bd_contains pointer. Add
a bdev_whole() helper to look up the whole device block_device
struture instead.
Signed-off-by: Christoph Hellwig
---
drivers/scsi/scsicam.c| 2 +-
fs/block_dev.c
Add a little helper to find the kobject for a struct block_device.
Signed-off-by: Christoph Hellwig
---
drivers/md/bcache/super.c | 7 ++-
drivers/md/md.c | 4 +---
fs/btrfs/sysfs.c | 15 +++
include/linux/blk_types.h | 3 +++
4 files changed, 9 insertions(+
We can just dereference the point in struct gendisk instead. Also
remove the now unused export.
Signed-off-by: Christoph Hellwig
---
block/genhd.c | 1 -
drivers/block/nbd.c | 4 +---
drivers/block/xen-blkfront.c| 20 +---
drivers/block/zram/z
Adding the minor to the major creates tons of pointless conflicts. Just
use the dev_t itself, which is 32-bits and thus is guaranteed to fit
into ino_t.
Signed-off-by: Christoph Hellwig
---
fs/block_dev.c | 26 ++
1 file changed, 2 insertions(+), 24 deletions(-)
diff --g
Use file->f_mapping in all remaining places that have a struct file
available to properly handle the case where inode->i_mapping !=
file_inode(file)->i_mapping.
Signed-off-by: Christoph Hellwig
---
mm/filemap.c | 9 -
1 file changed, 4 insertions(+), 5 deletions(-)
diff --git a/mm/filem
To simplify block device lookup and a few other upcomdin areas, make sure
that we always have a struct block_device available for each disk and
each partition. The only downside of this is that each device and
partition uses a little more memories. The upside will be that a lot of
code can be sim
Switch the block device lookup interfaces to directly work with a dev_t
so that struct block_device references are only acquired by the
blkdev_get variants (and the blk-cgroup special case). This means that
we not don't need an extra reference in the inode and can generally
simplify handling of st
Signed-off-by: Christoph Hellwig
---
include/linux/genhd.h | 1 -
1 file changed, 1 deletion(-)
diff --git a/include/linux/genhd.h b/include/linux/genhd.h
index 46553d6d602563..22f5b9fd96f8bf 100644
--- a/include/linux/genhd.h
+++ b/include/linux/genhd.h
@@ -250,7 +250,6 @@ static inline dev_t p
Don't bother to call lookup_bdev for just a slightly different error
message without any functional change.
Signed-off-by: Christoph Hellwig
---
drivers/md/bcache/super.c | 44 +--
1 file changed, 1 insertion(+), 43 deletions(-)
diff --git a/drivers/md/bcache
Call disk_part_iter_exit in disk_part_iter_next instead of duplicating
the functionality.
Signed-off-by: Christoph Hellwig
---
block/genhd.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/block/genhd.c b/block/genhd.c
index 4e039524f92b8f..0bd9c41dd4cb69 100644
--- a/block
disk_get_part needs to be paired with a disk_put_part.
Fixes: ef45fe470e1 ("blk-cgroup: show global disk stats in root cgroup io.stat")
Signed-off-by: Christoph Hellwig
---
block/blk-cgroup.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/block/blk-cgroup.c b/block/blk-cgroup.c
index c68bdf
Avoid a totally pointless goto label, and use the same style of
comparism for both helpers.
Signed-off-by: Christoph Hellwig
---
init/do_mounts.c | 18 ++
1 file changed, 6 insertions(+), 12 deletions(-)
diff --git a/init/do_mounts.c b/init/do_mounts.c
index afa26a4028d25e..5879
Split each case into a self-contained helper.
Signed-off-by: Christoph Hellwig
---
include/linux/genhd.h | 7 +-
init/do_mounts.c | 183 +-
2 files changed, 91 insertions(+), 99 deletions(-)
diff --git a/include/linux/genhd.h b/include/linux/genhd.
Now that the hd_struct always has a block device attached to it, there is
no need for having two size field that just get out of sync.
Additional the field in hd_struct did not use proper serializiation,
possibly allowing for torn writes. By only using the block_device field
this problem also get
Use put_device to put the device instead of poking into the internals
and using kobject_put.
Signed-off-by: Christoph Hellwig
---
block/genhd.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/block/genhd.c b/block/genhd.c
index 0bd9c41dd4cb69..f46e89226fdf91 100644
--- a/bloc
Just open code the wait in the only caller of both functions.
Signed-off-by: Christoph Hellwig
---
fs/internal.h | 2 ++
fs/quota/quota.c | 31 +---
fs/super.c | 51 ++
include/linux/fs.h | 4 +---
4 files chang
Hi Jens,
this series cleans up our main per-device node data structure by merging
the block_device and hd_struct data structures that have the same scope,
but different life times. The main effect (besides removing lots of
code) is that instead of having two device sizes that need complex
synchro
Reorder the code to have one big section for the last close, and to use
bdev_is_partition.
Signed-off-by: Christoph Hellwig
---
fs/block_dev.c | 14 +++---
1 file changed, 7 insertions(+), 7 deletions(-)
diff --git a/fs/block_dev.c b/fs/block_dev.c
index 29db12c3bb501c..4c4d6c30382c06 1
The code in devt_from_partuuid is very convoluted. Refactor a bit by
sanitizing the goto and variable name usage.
Signed-off-by: Christoph Hellwig
---
init/do_mounts.c | 68 ++--
1 file changed, 31 insertions(+), 37 deletions(-)
diff --git a/init/do_
48 matches
Mail list logo