HomeClusterLabs Projects

mdraid: Add 'auto' and multiple devices support to parameter md_dev
c0648ba5d496Unpublished

Unpublished Commit ยท Learn More

Not On Permanent Ref: This commit is not an ancestor of any permanent ref.

Description

mdraid: Add 'auto' and multiple devices support to parameter md_dev

This commit allows the value 'auto' or multiple devices separated by space are
set in parameter md_dev.

When 'auto' is assigned, mdraid RA will try to get all md arrays from mdraid_conf
then assemble them automatically.
If multiple devices are assigned e.g. '/dev/md2 /dev/md3', the RA will try to
assemble them.

The single device syntax is same as the original.

To keep the code and logic simple, global varaiable RAIDDEVS is introduced to record
md devices. All entry functions mdraid_(stop|start|mintor) are renamed to
mdraid_(stop|start|mintor)_one which are called by new function forall().
In forall(), md_dev and devs are used by mdraid_(stop|start|mintor)_one during
iterating RAIDDEVS.
The original mdraid_stop_one is renamed to mdraid_stop_array for naming consistency.

Signed-off-by: Su Yue <glass.su@suse.com>

Details

Provenance
Su Yue <glass.su@suse.com>Authored on Mon, Mar 31, 9:23 PM
Parents
rR1970602e48d3: azure-events-az: Add params defaults to RA description (#2034)
Branches
Unknown
Tags
Unknown

Event Timeline