[dm-devel] [PATCH v2 09/11] dm: rearrange core declarations

Hannes Reinecke hare at suse.de
Thu May 20 05:59:38 UTC 2021


On 5/20/21 6:22 AM, Damien Le Moal wrote:
> Move the definitions of struct dm_target_io, struct dm_io and of the
> bits of the flags field of struct mapped_device from dm.c to dm-core.h
> to make them usable from dm-zone.c.
> For the same reason, declare dec_pending() in dm-core.h after renaming
> it to dm_io_dec_pending(). And for symmetry of the function names,
> introduce the inline helper dm_io_inc_pending() instead of directly
> using atomic_inc() calls.
> 
> Signed-off-by: Damien Le Moal <damien.lemoal at wdc.com>
> ---
>   drivers/md/dm-core.h | 52 ++++++++++++++++++++++++++++++++++++++
>   drivers/md/dm.c      | 59 ++++++--------------------------------------
>   2 files changed, 59 insertions(+), 52 deletions(-)
> I've never been a fan of private structures.

Reviewed-by: Hannes Reinecke <hare at suse.de>

Cheers,

Hannes
-- 
Dr. Hannes Reinecke                Kernel Storage Architect
hare at suse.de                              +49 911 74053 688
SUSE Software Solutions GmbH, Maxfeldstr. 5, 90409 Nürnberg
HRB 36809 (AG Nürnberg), Geschäftsführer: Felix Imendörffer





More information about the dm-devel mailing list