Hi Pavel,
On Sun, 2020-11-22 at 22:00 +0100, Pavel Machek wrote:
> Hi!
>
> > >How is it supposed to be useful?
> > >
> > >I'm pretty sure there are critical data that are not measured by
> > >proposed module... and that are written under normal circumstances.
> > >
> > The goal of this series is
On Sun, Nov 22, 2020 at 11:54 PM Finn Thain wrote:
>
> We should also take into account optimisim about future improvements in
> tooling.
Not sure what you mean here. There is no reliable way to guess what
the intention was with a missing fallthrough, even if you parsed
whitespace and indentation
On Sun, Nov 22, 2020 at 11:53:55AM -0800, James Bottomley wrote:
> On Sun, 2020-11-22 at 11:22 -0800, Joe Perches wrote:
> > On Sun, 2020-11-22 at 11:12 -0800, James Bottomley wrote:
> > > On Sun, 2020-11-22 at 10:25 -0800, Joe Perches wrote:
> > > > On Sun, 2020-11-22 at 10:21 -0800, James Bottoml
On Mon, 2020-11-23 at 15:19 +0100, Miguel Ojeda wrote:
> On Sun, Nov 22, 2020 at 11:36 PM James Bottomley
> wrote:
> > Well, it seems to be three years of someone's time plus the
> > maintainer review time and series disruption of nearly a thousand
> > patches. Let's be conservative and assume th
On Sun, Nov 22, 2020 at 11:36 PM James Bottomley
wrote:
>
> Well, it seems to be three years of someone's time plus the maintainer
> review time and series disruption of nearly a thousand patches. Let's
> be conservative and assume the producer worked about 30% on the series
> and it takes about
On Mon, 2020-11-23 at 07:58 -0800, James Bottomley wrote:
> We're also complaining about the inability to recruit maintainers:
>
> https://www.theregister.com/2020/06/30/hard_to_find_linux_maintainers_says_torvalds/
>
> And burn out:
>
> http://antirez.com/news/129
https://www.wired.com/story/o
On Mon, Nov 23, 2020 at 4:58 PM James Bottomley
wrote:
>
> Well, I used git. It says that as of today in Linus' tree we have 889
> patches related to fall throughs and the first series went in in
> october 2017 ... ignoring a couple of outliers back to February.
I can see ~10k insertions over ~1
On Mon, 23 Nov 2020, Miguel Ojeda wrote:
> On Mon, 23 Nov 2020, Finn Thain wrote:
>
> > On Sun, 22 Nov 2020, Miguel Ojeda wrote:
> >
> > >
> > > It isn't that much effort, isn't it? Plus we need to take into
> > > account the future mistakes that it might prevent, too.
> >
> > We should als
On Mon, Nov 23, 2020 at 4:58 PM James Bottomley
wrote:
>
> On Mon, 2020-11-23 at 15:19 +0100, Miguel Ojeda wrote:
> > On Sun, Nov 22, 2020 at 11:36 PM James Bottomley
> > wrote:
[cut]
> >
> > Maintainers routinely review 1-line trivial patches, not to mention
> > internal API changes, etc.
>
>
On Mon, 2020-11-23 at 07:03 -0600, Gustavo A. R. Silva wrote:
> On Sun, Nov 22, 2020 at 11:53:55AM -0800, James Bottomley wrote:
> > On Sun, 2020-11-22 at 11:22 -0800, Joe Perches wrote:
> > > On Sun, 2020-11-22 at 11:12 -0800, James Bottomley wrote:
> > > > On Sun, 2020-11-22 at 10:25 -0800, Joe P
On Mon, 23 Nov 2020 17:32:51 -0800 Nick Desaulniers wrote:
> On Sun, Nov 22, 2020 at 8:17 AM Kees Cook wrote:
> > On Fri, Nov 20, 2020 at 11:51:42AM -0800, Jakub Kicinski wrote:
> > > If none of the 140 patches here fix a real bug, and there is no change
> > > to machine code then it sounds to m
Hi James,
On 2020-11-20 6:05 p.m., James Morris wrote:
On Thu, 19 Nov 2020, Tushar Sugandhi wrote:
an impact on the security guarantees provided by SELinux. Measuring
such in-memory data structures through IMA subsystem provides a secure
way for a remote attestation service to know the state o
On Mon, 2020-11-23 at 19:56 +0100, Miguel Ojeda wrote:
> On Mon, Nov 23, 2020 at 4:58 PM James Bottomley
> wrote:
> > Well, I used git. It says that as of today in Linus' tree we have
> > 889 patches related to fall throughs and the first series went in
> > in october 2017 ... ignoring a couple o
On Mon, 2020-11-23 at 18:18 +0100, Pavel Machek wrote:
> > > Basically every other data structure in kernel is "critical" by your
> > > definition, and you can't really measure them all; some of them change
> > > rather often. Going piecemeal does not really help here.
> >
> > Agreed, measuring da
On Fri, Nov 20, 2020 at 12:21:39PM -0600, Gustavo A. R. Silva wrote:
> IB/hfi1: Fix fall-through warnings for Clang
> IB/mlx4: Fix fall-through warnings for Clang
> IB/qedr: Fix fall-through warnings for Clang
> RDMA/mlx5: Fix fall-through warnings for Clang
I picked these four to the rdm
On Tue, 2020-11-24 at 11:58 +1100, Finn Thain wrote:
> it's not for me to prove that such patches don't affect code
> generation. That's for the patch author and (unfortunately) for reviewers.
Ideally, that proof would be provided by the compilation system itself
and not patch authors nor reviewe
On Mon, 23 Nov 2020, Joe Perches wrote:
> On Tue, 2020-11-24 at 11:58 +1100, Finn Thain wrote:
> > it's not for me to prove that such patches don't affect code
> > generation. That's for the patch author and (unfortunately) for
> > reviewers.
>
> Ideally, that proof would be provided by the c
On Fri, 20 Nov 2020 12:21:39 -0600, Gustavo A. R. Silva wrote:
> This series aims to fix almost all remaining fall-through warnings in
> order to enable -Wimplicit-fallthrough for Clang.
>
> In preparation to enable -Wimplicit-fallthrough for Clang, explicitly
> add multiple break/goto/return/fall
On Wed, Nov 18, 2020 at 09:47:41AM +0100, 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
Acked-by: Tejun Heo
Thanks.
--
tejun
--
dm-d
Move the make_it_fail flag to struct block_device an turn it into a bool
in preparation of killing struct hd_struct.
Signed-off-by: Christoph Hellwig
---
block/blk-core.c | 3 ++-
block/genhd.c | 4 ++--
include/linux/blk_types.h | 3 +++
include/linux/genhd.h | 3 ---
4
Switch the partition iter infrastructure to iterate over block_device
references instead of hd_struct ones mostly used to get at the
block_device.
Signed-off-by: Christoph Hellwig
---
block/genhd.c | 57 +++
block/partitions/core.c | 13 +
Just use the bd_partno field in struct block_device everywhere.
Signed-off-by: Christoph Hellwig
---
block/genhd.c | 12 ++--
block/partitions/core.c | 9 -
include/linux/genhd.h | 1 -
init/do_mounts.c| 2 +-
4 files changed, 11 insertions(+), 13 deletions
bd_part is never NULL for a block device in use by a file system, so
remove the checks.
Signed-off-by: Christoph Hellwig
---
fs/f2fs/checkpoint.c | 5 +
fs/f2fs/sysfs.c | 9 -
2 files changed, 1 insertion(+), 13 deletions(-)
diff --git a/fs/f2fs/checkpoint.c b/fs/f2fs/checkpoin
Use struct block_device to lookup partitions on a disk. This removes
all usage of struct hd_struct from the I/O path, and this allows removing
the percpu refcount in struct hd_struct.
Signed-off-by: Christoph Hellwig
---
block/bio.c| 4 +-
block/blk-core.c
Pass the block_device actually needed instead of the hd_struct.
Signed-off-by: Christoph Hellwig
---
block/blk.h | 2 +-
block/genhd.c | 14 +++---
block/partitions/core.c | 2 +-
3 files changed, 9 insertions(+), 9 deletions(-)
diff --git a/block/blk.h b/block/b
We can just dereference the point in struct gendisk instead. Also
remove the now unused export.
Signed-off-by: Christoph Hellwig
Reviewed-by: Greg Kroah-Hartman
Reviewed-by: Jan Kara
---
block/genhd.c | 1 -
drivers/block/nbd.c | 4 +---
drivers/block/xen-blkfr
Move the policy field to struct block_device and rename it to the
more descriptive bd_read_only. Also turn the field into a bool as it
is used as such.
Signed-off-by: Christoph Hellwig
---
block/blk-core.c | 2 +-
block/genhd.c | 8
block/ioctl.c | 2 +-
Move the dkstats and stamp field to struct block_device in preparation
of killing struct hd_struct.
Signed-off-by: Christoph Hellwig
---
block/blk-cgroup.c| 2 +-
block/blk-core.c | 4 ++--
block/blk.h | 1 -
block/genhd.c | 14 --
block/
Pass the block_device actually needed instead of looking it up using
bdget_disk.
Signed-off-by: Christoph Hellwig
---
block/genhd.c | 13 +++--
1 file changed, 3 insertions(+), 10 deletions(-)
diff --git a/block/genhd.c b/block/genhd.c
index 498c816e90df64..2985740eab084b 100644
--- a/b
Instead of having two structures that represent each block device with
different life time rules, merge 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
Allocate hd_struct together with struct block_device to pre-load
the lifetime rule changes in preparation of merging the two structures.
Note that part0 was previously embedded into struct gendisk, but is
a separate allocation now, and already points to the block_device instead
of the hd_struct.
Use put_device to put the device instead of poking into the internals
and using kobject_put.
Signed-off-by: Christoph Hellwig
Reviewed-by: Greg Kroah-Hartman
Reviewed-by: Jan Kara
Reviewed-by: Johannes Thumshirn
---
block/genhd.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --g
sector_t is now always a u64, so this check is not needed.
Signed-off-by: Christoph Hellwig
---
block/ioctl.c | 9 -
1 file changed, 9 deletions(-)
diff --git a/block/ioctl.c b/block/ioctl.c
index 6b785181344fe1..0c09bb7a6ff35f 100644
--- a/block/ioctl.c
+++ b/block/ioctl.c
@@ -35,15 +3
Signed-off-by: Christoph Hellwig
Reviewed-by: Greg Kroah-Hartman
Reviewed-by: Jan Kara
Reviewed-by: Johannes Thumshirn
---
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/in
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
Reviewed-by: Greg Kroah-Hartman
Reviewed-by: Jan Kara
---
fs/block_dev.c | 26 ++
1
Properly open the device instead of relying on deep internals by
using get_gendisk. Note that this uses FMODE_NDELAY without either
FMODE_READ or FMODE_WRITE, which is a special open mode to allow
for opening without media access, thus avoiding unexpexted interactions
especially on removable media
Now that struct hd_struct has a block_device pointer use that to
find the disk.
Signed-off-by: Christoph Hellwig
---
include/linux/genhd.h | 10 +++---
1 file changed, 3 insertions(+), 7 deletions(-)
diff --git a/include/linux/genhd.h b/include/linux/genhd.h
index d068e46f9086ae..dcf86a3d4d
Move more code that is only run on the outer open but not the open of
the underlying whole device when opening a partition into blkdev_get,
which leads to a much easier to follow structure.
This allows to simplify the disk and module refcounting so that one
reference is held for each open, similar
Stop passing the whole device as a separate argument given that it
can be trivially deducted and cleanup the !holder debug check.
Signed-off-by: Christoph Hellwig
Reviewed-by: Greg Kroah-Hartman
Reviewed-by: Jan Kara
---
drivers/block/loop.c | 12 +-
fs/block_dev.c | 51 +
Call disk_part_iter_exit in disk_part_iter_next instead of duplicating
the functionality.
Signed-off-by: Christoph Hellwig
Reviewed-by: Greg Kroah-Hartman
Reviewed-by: Jan Kara
Reviewed-by: Johannes Thumshirn
---
block/genhd.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --gi
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
del_gendisk already calls fsync_bdev for every partition, no need
to do this twice.
Signed-off-by: Christoph Hellwig
---
drivers/block/mtip32xx/mtip32xx.c | 15 ---
drivers/block/mtip32xx/mtip32xx.h | 2 --
2 files changed, 17 deletions(-)
diff --git a/drivers/block/mtip32xx/mtip32
Move the partition_meta_info to struct block_device in preparation for
killing struct hd_struct.
Signed-off-by: Christoph Hellwig
---
block/blk.h | 1 -
block/genhd.c | 3 ++-
block/partitions/core.c | 18 +++---
fs/block_dev.c| 1 +
include
Avoid a totally pointless goto label, and use the same style of
comparism for both helpers.
Signed-off-by: Christoph Hellwig
Reviewed-by: Greg Kroah-Hartman
Reviewed-by: Jan Kara
Reviewed-by: Johannes Thumshirn
---
init/do_mounts.c | 18 ++
1 file changed, 6 insertions(+), 12
Just call devcgroup_check_permission to avoid various superflous checks
and a double conversion of the access flags.
Signed-off-by: Christoph Hellwig
---
fs/block_dev.c | 10 --
1 file changed, 4 insertions(+), 6 deletions(-)
diff --git a/fs/block_dev.c b/fs/block_dev.c
index 2ffa11a95f
On 11/24/20 9:27 PM, Christoph Hellwig wrote:
> Use struct block_device to lookup partitions on a disk. This removes
> all usage of struct hd_struct from the I/O path, and this allows removing
> the percpu refcount in struct hd_struct.
>
> Signed-off-by: Christoph Hellwig
For the bcache part,
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
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 | 13 ++---
1 file changed, 6 insertions(+), 7 deletions(-)
diff --git a/mm/
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
The zram claim mechanism was added to ensure no new opens come in
during teardown. But the proper way to archive that is to call
del_gendisk first, which takes care of all that. Once del_gendisk
is called in the right place, the reset side can also be simplified
as no I/O can be outstanding on a
Reorder the code to have one big section for the last close, and to use
bdev_is_partition.
Signed-off-by: Christoph Hellwig
Reviewed-by: Greg Kroah-Hartman
Reviewed-by: Jan Kara
---
fs/block_dev.c | 14 +++---
1 file changed, 7 insertions(+), 7 deletions(-)
diff --git a/fs/block_dev.c
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
Reviewed-by: Greg Kroah-Hartman
Reviewed-by: Jan Kara
---
init/do_mounts.c | 68 ++--
1 file changed,
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
Reviewed-by: Greg Kroah-Hartman
Reviewed-by: Jan Kara
Reviewed-by: Johannes Thumshirn
Acked-by: Tejun Heo
---
block/blk-cgr
Get rid of the long-lasting struct block_device reference in
struct mapped_device. The only remaining user is the freeze code,
where we can trivially look up the block device at freeze time
and release the reference at thaw time.
Signed-off-by: Christoph Hellwig
Acked-by: Mike Snitzer
---
driv
Split each case into a self-contained helper, and move the block
dependent code entirely under the pre-existing #ifdef CONFIG_BLOCK.
This allows to remove the blk_lookup_devt stub in genhd.h.
Signed-off-by: Christoph Hellwig
Reviewed-by: Greg Kroah-Hartman
Reviewed-by: Jan Kara
Reviewed-by: Joh
Add a little helper to find the kobject for a struct block_device.
Signed-off-by: Christoph Hellwig
Reviewed-by: Greg Kroah-Hartman
Reviewed-by: Jan Kara
Reviewed-by: Johannes Thumshirn
---
drivers/md/bcache/super.c | 7 ++-
drivers/md/md.c | 4 +---
fs/block_dev.c
Move the holder_dir field to struct block_device in preparation for
kill struct hd_struct.
Signed-off-by: Christoph Hellwig
---
block/genhd.c | 5 +++--
block/partitions/core.c | 8
fs/block_dev.c| 11 +--
include/linux/blk_types.h | 1 +
include/lin
set_blocksize is used by file systems to use their preferred buffer cache
block size. Block drivers should not set it.
Signed-off-by: Christoph Hellwig
---
drivers/block/zram/zram_drv.c | 11 +--
drivers/block/zram/zram_drv.h | 1 -
2 files changed, 1 insertion(+), 11 deletions(-)
dif
Store the frozen superblock in struct block_device to avoid the awkward
interface that can return a sb only used a cookie, an ERR_PTR or NULL.
Signed-off-by: Christoph Hellwig
---
drivers/md/dm-core.h | 5 -
drivers/md/dm.c | 20 ++--
fs/block_dev.c
We don't really need the struct block_device to initialize a bio. So
switch from using bio_set_dev to manually setting up bi_disk (bi_partno
will always be zero and has been cleared by bio_init already).
Signed-off-by: Christoph Hellwig
Acked-by: Mike Snitzer
---
drivers/md/dm.c | 12 +++--
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
Reviewed-by: Greg Kroah-Hartman
Reviewed-by: Jan Kara
-
Don't play tricks with slab constructors as bdev structures tends to not
get reused very much, and this makes the code a lot less error prone.
Signed-off-by: Christoph Hellwig
---
fs/block_dev.c | 22 +-
1 file changed, 9 insertions(+), 13 deletions(-)
diff --git a/fs/block_
set_blocksize is used by file systems to use their preferred buffer cache
block size. Block drivers should not set it.
Signed-off-by: Christoph Hellwig
---
drivers/block/loop.c | 3 ---
1 file changed, 3 deletions(-)
diff --git a/drivers/block/loop.c b/drivers/block/loop.c
index 9a27d4f1c08aac
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
To simplify block device lookup and a few other upcoming 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 memory. The upside will be that a lot of
code can be simpl
Move the start_sect field to struct block_device in preparation
of killing struct hd_struct.
Signed-off-by: Christoph Hellwig
---
block/blk-core.c | 5 +++--
block/blk-lib.c | 2 +-
block/genhd.c | 4 ++--
block/partitions/core.c | 17 +
includ
On 11/24/20 9:27 PM, Christoph Hellwig wrote:
> 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
On 11/24/20 9:27 PM, Christoph Hellwig wrote:
> 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
On 11/24/20 9:27 PM, Christoph Hellwig wrote:
> Add a little helper to find the kobject for a struct block_device.
>
> Signed-off-by: Christoph Hellwig
> Reviewed-by: Greg Kroah-Hartman
> Reviewed-by: Jan Kara
> Reviewed-by: Johannes Thumshirn
For the bcache part, Acked-by: Coly Li
Thanks.
On Tue, Nov 24, 2020 at 02:27:08PM +0100, Christoph Hellwig wrote:
> 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
Reviewed-by: Matthew Wilc
Hello,
This is great. So much simpler & better. Some nits below.
> diff --git a/block/partitions/core.c b/block/partitions/core.c
> index a02e224115943d..0ba0bf44b88af3 100644
> --- a/block/partitions/core.c
> +++ b/block/partitions/core.c
> @@ -340,12 +340,11 @@ void delete_partition(struct hd_s
On Tue, Nov 24, 2020 at 02:27:18PM +0100, Christoph Hellwig wrote:
> sector_t is now always a u64, so this check is not needed.
>
> Signed-off-by: Christoph Hellwig
Acked-by: Tejun Heo
--
tejun
--
dm-devel mailing list
dm-devel@redhat.com
https://www.redhat.com/mailman/listinfo/dm-devel
On Tue, Nov 24, 2020 at 02:27:17PM +0100, Christoph Hellwig wrote:
> Signed-off-by: Christoph Hellwig
> Reviewed-by: Greg Kroah-Hartman
> Reviewed-by: Jan Kara
> Reviewed-by: Johannes Thumshirn
Acked-by: Tejun Heo
--
tejun
--
dm-devel mailing list
dm-devel@redhat.com
https://www.redhat.com
On Tue, Nov 24, 2020 at 02:27:19PM +0100, Christoph Hellwig wrote:
> Add a little helper to find the kobject for a struct block_device.
Acked-by: Tejun Heo
--
tejun
--
dm-devel mailing list
dm-devel@redhat.com
https://www.redhat.com/mailman/listinfo/dm-devel
On Tue, Nov 24, 2020 at 02:27:20PM +0100, Christoph Hellwig wrote:
> Call disk_part_iter_exit in disk_part_iter_next instead of duplicating
> the functionality.
Acked-by: Tejun Heo
--
tejun
--
dm-devel mailing list
dm-devel@redhat.com
https://www.redhat.com/mailman/listinfo/dm-devel
On Tue, Nov 24, 2020 at 02:27:22PM +0100, 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
> Reviewed-by: Greg Kroah-Hartman
On Tue, Nov 24, 2020 at 02:27:21PM +0100, 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
> Reviewed-by: Greg Kroah-Hartman
> Reviewed-by: Jan Kara
> Reviewed-by: Johannes Thumshirn
On Tue, Nov 24, 2020 at 02:27:23PM +0100, Christoph Hellwig wrote:
> Split each case into a self-contained helper, and move the block
> dependent code entirely under the pre-existing #ifdef CONFIG_BLOCK.
> This allows to remove the blk_lookup_devt stub in genhd.h.
>
> Signed-off-by: Christoph Hell
On Tue, Nov 24, 2020 at 02:27:24PM +0100, 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
> Reviewed-by: Greg Kroah-Hartman
> Reviewed-by: Jan Kara
Acked-by: Tej
On Tue, Nov 24, 2020 at 02:27:25PM +0100, Christoph Hellwig wrote:
> Avoid a totally pointless goto label, and use the same style of
> comparism for both helpers.
>
> Signed-off-by: Christoph Hellwig
> Reviewed-by: Greg Kroah-Hartman
> Reviewed-by: Jan Kara
> Reviewed-by: Johannes Thumshirn
A
On Tue, Nov 24, 2020 at 02:27:26PM +0100, 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
> Reviewed-by: Greg Kroah-Hartman
> Reviewed-by: Jan Kara
Acked-by: Tejun Heo
--
tejun
--
d
On Tue, Nov 24, 2020 at 02:27:27PM +0100, Christoph Hellwig wrote:
> Move more code that is only run on the outer open but not the open of
> the underlying whole device when opening a partition into blkdev_get,
> which leads to a much easier to follow structure.
>
> This allows to simplify the dis
On Tue, Nov 24, 2020 at 02:27:28PM +0100, Christoph Hellwig wrote:
> Just call devcgroup_check_permission to avoid various superflous checks
> and a double conversion of the access flags.
>
> Signed-off-by: Christoph Hellwig
Acked-by: Tejun Heo
--
tejun
--
dm-devel mailing list
dm-devel@redh
On Tue, Nov 24, 2020 at 02:27:29PM +0100, Christoph Hellwig wrote:
> 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 nee
On Tue, Nov 24, 2020 at 02:27:30PM +0100, Christoph Hellwig wrote:
> Properly open the device instead of relying on deep internals by
> using get_gendisk. Note that this uses FMODE_NDELAY without either
> FMODE_READ or FMODE_WRITE, which is a special open mode to allow
> for opening without media
On Fri, Nov 06, 2020 at 06:32:16PM +0100, Martin Wilck wrote:
> On Thu, 2020-11-05 at 18:41 -0600, Benjamin Marzinski wrote:
> >
> > I can't make this segfault. So that looks good, but it does need
> > libmultipath.version updated to include checker_thread_entry()
>
> Great news, thanks. Well the
Hello,
Please see lkml.kernel.org/r/x708btj5njtbc...@mtj.duckdns.org for a few nits
on the previous version.
On Tue, Nov 24, 2020 at 02:27:31PM +0100, Christoph Hellwig wrote:
> To simplify block device lookup and a few other upcoming areas, make sure
> that we always have a struct block_device a
On Tue, Nov 24, 2020 at 02:27:32PM +0100, Christoph Hellwig wrote:
> 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-b
On Tue, Nov 24, 2020 at 02:27:33PM +0100, Christoph Hellwig wrote:
> Stop passing the whole device as a separate argument given that it
> can be trivially deducted and cleanup the !holder debug check.
>
> Signed-off-by: Christoph Hellwig
> Reviewed-by: Greg Kroah-Hartman
> Reviewed-by: Jan Kara
On Tue, Nov 24, 2020 at 02:27:34PM +0100, Christoph Hellwig wrote:
> Now that struct hd_struct has a block_device pointer use that to
> find the disk.
>
> Signed-off-by: Christoph Hellwig
Acked-by: Tejun Heo
--
tejun
--
dm-devel mailing list
dm-devel@redhat.com
https://www.redhat.com/mailman
On Tue, Nov 24, 2020 at 02:27:35PM +0100, Christoph Hellwig wrote:
> Don't play tricks with slab constructors as bdev structures tends to not
> get reused very much, and this makes the code a lot less error prone.
>
> Signed-off-by: Christoph Hellwig
Acked-by: Tejun Heo
--
tejun
--
dm-devel
On Tue, 2020-11-24 at 14:33 -0600, Benjamin Marzinski wrote:
> On Fri, Nov 06, 2020 at 06:32:16PM +0100, Martin Wilck wrote:
> > On Thu, 2020-11-05 at 18:41 -0600, Benjamin Marzinski wrote:
> > > I can't make this segfault. So that looks good, but it does need
> > > libmultipath.version updated to
On 11/24/20 2:27 PM, 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
Reviewed-by: Greg Kroah-Hartman
Reviewed-by: Jan Kara
Reviewed-by: Johannes Th
On 11/24/20 2:27 PM, Christoph Hellwig wrote:
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 | 13 ++---
1 file changed,
On 11/24/20 2:27 PM, Christoph Hellwig wrote:
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 ++--
On Tue, Nov 24, 2020 at 11:24 PM Finn Thain wrote:
>
> These statements are not "missing" unless you presume that code written
> before the latest de facto language spec was written should somehow be
> held to that spec.
There is no "language spec" the kernel adheres to. Even if it did,
kernel co
On Mon, Nov 23, 2020 at 08:31:30AM -0800, James Bottomley wrote:
> Really, no ... something which produces no improvement has no value at
> all ... we really shouldn't be wasting maintainer time with it because
> it has a cost to merge. I'm not sure we understand where the balance
> lies in value
On Tue, Nov 24, 2020 at 1:58 AM Finn Thain wrote:
>
> What I meant was that you've used pessimism as if it was fact.
"future mistakes that it might prevent" is neither pessimism nor states a fact.
> For example, "There is no way to guess what the effect would be if the
> compiler trained program
On 2020/11/24 21:27, Christoph Hellwig wrote:
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 us
On Wed, Nov 25, 2020 at 12:53 AM Finn Thain wrote:
>
> I'm saying that supporting the official language spec makes more sense
> than attempting to support a multitude of divergent interpretations of the
> spec (i.e. gcc, clang, coverity etc.)
Making the kernel strictly conforming is a ship that s
1 - 100 of 110 matches
Mail list logo