Re: [PATCH v2] dm-ioctl: return UUID in DM_LIST_DEVICES_CMD result

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




On Thu, 11 Mar 2021, Mike Snitzer wrote:

> > Index: linux-2.6/include/uapi/linux/dm-ioctl.h
> > ===================================================================
> > --- linux-2.6.orig/include/uapi/linux/dm-ioctl.h	2021-03-09 12:20:23.000000000 +0100
> > +++ linux-2.6/include/uapi/linux/dm-ioctl.h	2021-03-11 18:42:14.000000000 +0100
> > @@ -193,8 +193,15 @@ struct dm_name_list {
> >  	__u32 next;		/* offset to the next record from
> >  				   the _start_ of this */
> >  	char name[0];
> > +
> > +	/* uint32_t event_nr; */
> > +	/* uint32_t flags; */
> > +	/* char uuid[0]; */
> >  };
> 
> If extra padding is being leveraged here (from the __u32 next), why not
> at least explicitly add the members and then pad out the balance of that
> __u32?  I'm not liking the usage of phantom struct members.. e.g.
> the games played with accessing them.
> 
> Mike

What exactly do you mean?

Do you want to create another structure that holds event_nr, flags and 
uuid? Or something else?

Mikulas

--
dm-devel mailing list
dm-devel@xxxxxxxxxx
https://listman.redhat.com/mailman/listinfo/dm-devel




[Index of Archives]     [DM Crypt]     [Fedora Desktop]     [ATA RAID]     [Fedora Marketing]     [Fedora Packaging]     [Fedora SELinux]     [Yosemite Discussion]     [KDE Users]     [Fedora Docs]

  Powered by Linux