[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <20201222095056.7a5ac0a0@canb.auug.org.au>
Date: Tue, 22 Dec 2020 09:50:56 +1100
From: Stephen Rothwell <sfr@...b.auug.org.au>
To: Alasdair G Kergon <agk@...hat.com>,
Mike Snitzer <snitzer@...hat.com>
Cc: Christoph Hellwig <hch@....de>, Hannes Reinecke <hare@...e.de>,
Jens Axboe <axboe@...nel.dk>,
Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
Linux Next Mailing List <linux-next@...r.kernel.org>
Subject: linux-next: manual merge of the device-mapper tree with Linus' tree
Hi all,
Today's linux-next merge of the device-mapper tree got a conflict in:
drivers/md/dm-table.c
between commit:
4e7b5671c6a8 ("block: remove i_bdev")
from Linus' tree and commit:
05a876e9a2a8 ("dm table: avoid filesystem lookup in dm_get_dev_t()")
from the device-mapper tree.
I fixed it up (see below) and can carry the fix as necessary. This
is now fixed as far as linux-next is concerned, but any non trivial
conflicts should be mentioned to your upstream maintainer when your tree
is submitted for merging. You may also want to consider cooperating
with the maintainer of the conflicting tree to minimise any particularly
complex conflicts.
--
Cheers,
Stephen Rothwell
diff --cc drivers/md/dm-table.c
index 188f41287f18,299a256fb409..000000000000
--- a/drivers/md/dm-table.c
+++ b/drivers/md/dm-table.c
@@@ -347,9 -347,22 +347,15 @@@ static int upgrade_mode(struct dm_dev_i
dev_t dm_get_dev_t(const char *path)
{
dev_t dev;
- struct block_device *bdev;
+ unsigned int maj, min;
+ if (sscanf(path, "%u:%u", &maj, &min) == 2) {
+ dev = MKDEV(maj, min);
+ if (maj == MAJOR(dev) && min == MINOR(dev))
+ return dev;
+ }
- bdev = lookup_bdev(path);
- if (IS_ERR(bdev))
+ if (lookup_bdev(path, &dev))
dev = name_to_dev_t(path);
- else {
- dev = bdev->bd_dev;
- bdput(bdev);
- }
-
return dev;
}
EXPORT_SYMBOL_GPL(dm_get_dev_t);
Content of type "application/pgp-signature" skipped
Powered by blists - more mailing lists