[dm-devel] [PATCH] dm raid1: Use struct_size() in kzalloc()

Markus Elfring Markus.Elfring at web.de
Tue Aug 6 12:45:30 UTC 2019


> +++ b/drivers/md/dm-raid1.c
> @@ -878,12 +878,9 @@ static struct mirror_set *alloc_context(unsigned int nr_mirrors,
>  					struct dm_target *ti,
>  					struct dm_dirty_log *dl)
>  {
> -	size_t len;
>  	struct mirror_set *ms = NULL;
…

How do you think about to replace the initialisation “NULL” by the desired function call?

Regards,
Markus




More information about the dm-devel mailing list