On Fri, Feb 24, 2023 at 11:44:55AM -0600, Mike Christie wrote: > + /* > + * Assume we are using 128-bit host IDs and allocate a buffer large > + * enough to get enough keys to fill the return keys buffer. > + */ > + rs_len = sizeof(*rs) + > + num_keys * sizeof(struct nvme_registered_ctrl_ext); Any reason not to use struct_size() here? Or does the union prevent us from doing so? Otherwise this looks good to me.