diff options
author | Mariusz Tkaczyk <mariusz.tkaczyk@linux.intel.com> | 2023-06-01 09:27:48 +0200 |
---|---|---|
committer | Jes Sorensen <jes@trained-monkey.org> | 2023-10-26 23:28:23 +0200 |
commit | 67417d9222c505103357191bb0e0ae300892e8a9 (patch) | |
tree | ec4990547c9556b08af0b7a098f44d4b9622eeae /tests/01replace | |
parent | mdadm: set ident.devname if applicable (diff) | |
download | mdadm-67417d9222c505103357191bb0e0ae300892e8a9.tar.xz mdadm-67417d9222c505103357191bb0e0ae300892e8a9.zip |
mdadm: refactor ident->name handling
Create dedicated setter for name in mddev_ident and propagate it.
Following changes are made:
- move duplicated code from config.c and mdadm.c into new function.
- Add error enum in mdadm.h.
- Use MD_NAME_MAX instead of hardcoded value in mddev_ident.
- Use secure functions.
- Add more detailed verification of the name.
- make error messages reusable for cmdline and config:
- for cmdline, these are errors so use pr_err().
- for config, these are just warnings, so use pr_info().
Signed-off-by: Mariusz Tkaczyk <mariusz.tkaczyk@linux.intel.com>
Signed-off-by: Jes Sorensen <jes@trained-monkey.org>
Diffstat (limited to 'tests/01replace')
0 files changed, 0 insertions, 0 deletions