]> git.ipfire.org Git - thirdparty/mdadm.git/commit - super-intel.c
imsm: add generic method to resolve "device" links
authorMariusz Tkaczyk <mariusz.tkaczyk@linux.intel.com>
Mon, 17 May 2021 14:39:00 +0000 (16:39 +0200)
committerJes Sorensen <jsorensen@fb.com>
Wed, 26 May 2021 11:26:21 +0000 (07:26 -0400)
commit7c798f870900f6f4d4647dd3c88318524d7ccee4
treecc2a1a94251ff5c6aa9c4f828a5e9dcb0ced8a91
parent0530e2e0d8c9ecb5171e70bc48e1a6566f317378
imsm: add generic method to resolve "device" links

Each virtual device is linked with parent by "device". This patch adds
possibility to get previous device in sysfs tree.

Depending on device type, there is a different amount of virutal
layers. The best we can do is allow to directly specify how many
"device" links need to be resolved. This approach also allows to get
previous virtual device, which may contain some attributes.

Simplify fd2devname, this function doesn't require new functionality and
shall use generic fd2kname.

For nvme drives represented via nvme-subystem when path to block
device if requested, then return it without translation.

Signed-off-by: Mariusz Tkaczyk <mariusz.tkaczyk@linux.intel.com>
Signed-off-by: Jes Sorensen <jsorensen@fb.com>
platform-intel.c
platform-intel.h
super-intel.c