From 330c07f8e4d26f4f2d068e11f09c9df8a3380087 Mon Sep 17 00:00:00 2001 From: Mariusz Tkaczyk Date: Thu, 1 Jun 2023 09:27:47 +0200 Subject: mdadm: set ident.devname if applicable This patch tries to propagate the usage of struct mddev_ident for cmdline where it is applicable. To avoid regression, this value is derived from devlist->devname for applicable modes only. As a result, the whole structure is passed to some functions. It produces some changes for Build, Create and Assemble. No functional changes intended. The goal of the change is to unify devname validation which is done in next patches. Signed-off-by: Mariusz Tkaczyk Signed-off-by: Jes Sorensen --- mdadm.h | 13 +++++-------- 1 file changed, 5 insertions(+), 8 deletions(-) (limited to 'mdadm.h') diff --git a/mdadm.h b/mdadm.h index f0ceeb78..5678eb11 100644 --- a/mdadm.h +++ b/mdadm.h @@ -1531,14 +1531,11 @@ extern int Assemble(struct supertype *st, char *mddev, struct mddev_dev *devlist, struct context *c); -extern int Build(char *mddev, struct mddev_dev *devlist, - struct shape *s, struct context *c); - -extern int Create(struct supertype *st, char *mddev, - char *name, int *uuid, - int subdevs, struct mddev_dev *devlist, - struct shape *s, - struct context *c); +extern int Build(struct mddev_ident *ident, struct mddev_dev *devlist, struct shape *s, + struct context *c); + +extern int Create(struct supertype *st, struct mddev_ident *ident, int subdevs, + struct mddev_dev *devlist, struct shape *s, struct context *c); extern int Detail(char *dev, struct context *c); extern int Detail_Platform(struct superswitch *ss, int scan, int verbose, int export, char *controller_path); -- cgit v1.2.3