Message ID | 1690487690-2428-6-git-send-email-nunodasneves@linux.microsoft.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
Series | Introduce /dev/mshv drivers | expand |
On Thu, Jul 27, 2023 at 12:54:40PM -0700, Nuno Das Neves wrote: > This structure should be in hyperv-tlfs.h anyway, since it is part of > the TLFS document. Missing blank line here. > The definition conflicts with one added in hvgdk.h as part of the mshv > driver so must be moved to hyperv-tlfs.h. > > Signed-off-by: Nuno Das Neves <nunodasneves@linux.microsoft.com> > --- > include/asm-generic/hyperv-tlfs.h | 9 +++++++++ > include/linux/hyperv.h | 9 --------- > 2 files changed, 9 insertions(+), 9 deletions(-) > > diff --git a/include/asm-generic/hyperv-tlfs.h b/include/asm-generic/hyperv-tlfs.h > index 373f26efa18a..8fc5e5a9d7cb 100644 > --- a/include/asm-generic/hyperv-tlfs.h > +++ b/include/asm-generic/hyperv-tlfs.h > @@ -845,4 +845,13 @@ struct hv_mmio_write_input { > u8 data[HV_HYPERCALL_MMIO_MAX_DATA_LENGTH]; > } __packed; > > +/* Define connection identifier type. */ > +union hv_connection_id { > + u32 asu32; > + struct { > + u32 id:24; > + u32 reserved:8; > + } u; > +}; > + Missing __packed here, but since this is already aligned it probably doesn't matter much. > #endif > diff --git a/include/linux/hyperv.h b/include/linux/hyperv.h > index bfbc37ce223b..f90de5abcd50 100644 > --- a/include/linux/hyperv.h > +++ b/include/linux/hyperv.h > @@ -748,15 +748,6 @@ struct vmbus_close_msg { > struct vmbus_channel_close_channel msg; > }; > > -/* Define connection identifier type. */ > -union hv_connection_id { > - u32 asu32; > - struct { > - u32 id:24; > - u32 reserved:8; > - } u; > -}; > - > enum vmbus_device_type { > HV_IDE = 0, > HV_SCSI, > -- > 2.25.1 >
On 8/2/2023 4:55 PM, Wei Liu wrote: > On Thu, Jul 27, 2023 at 12:54:40PM -0700, Nuno Das Neves wrote: >> This structure should be in hyperv-tlfs.h anyway, since it is part of >> the TLFS document. > > Missing blank line here. > Thanks, will fix. >> The definition conflicts with one added in hvgdk.h as part of the mshv >> driver so must be moved to hyperv-tlfs.h. >> >> Signed-off-by: Nuno Das Neves <nunodasneves@linux.microsoft.com> >> --- >> include/asm-generic/hyperv-tlfs.h | 9 +++++++++ >> include/linux/hyperv.h | 9 --------- >> 2 files changed, 9 insertions(+), 9 deletions(-) >> >> diff --git a/include/asm-generic/hyperv-tlfs.h b/include/asm-generic/hyperv-tlfs.h >> index 373f26efa18a..8fc5e5a9d7cb 100644 >> --- a/include/asm-generic/hyperv-tlfs.h >> +++ b/include/asm-generic/hyperv-tlfs.h >> @@ -845,4 +845,13 @@ struct hv_mmio_write_input { >> u8 data[HV_HYPERCALL_MMIO_MAX_DATA_LENGTH]; >> } __packed; >> >> +/* Define connection identifier type. */ >> +union hv_connection_id { >> + u32 asu32; >> + struct { >> + u32 id:24; >> + u32 reserved:8; >> + } u; >> +}; >> + > > Missing __packed here, but since this is already aligned it probably > doesn't matter much. > Yes, it should be fine without __packed. >> #endif >> diff --git a/include/linux/hyperv.h b/include/linux/hyperv.h >> index bfbc37ce223b..f90de5abcd50 100644 >> --- a/include/linux/hyperv.h >> +++ b/include/linux/hyperv.h >> @@ -748,15 +748,6 @@ struct vmbus_close_msg { >> struct vmbus_channel_close_channel msg; >> }; >> >> -/* Define connection identifier type. */ >> -union hv_connection_id { >> - u32 asu32; >> - struct { >> - u32 id:24; >> - u32 reserved:8; >> - } u; >> -}; >> - >> enum vmbus_device_type { >> HV_IDE = 0, >> HV_SCSI, >> -- >> 2.25.1 >>
diff --git a/include/asm-generic/hyperv-tlfs.h b/include/asm-generic/hyperv-tlfs.h index 373f26efa18a..8fc5e5a9d7cb 100644 --- a/include/asm-generic/hyperv-tlfs.h +++ b/include/asm-generic/hyperv-tlfs.h @@ -845,4 +845,13 @@ struct hv_mmio_write_input { u8 data[HV_HYPERCALL_MMIO_MAX_DATA_LENGTH]; } __packed; +/* Define connection identifier type. */ +union hv_connection_id { + u32 asu32; + struct { + u32 id:24; + u32 reserved:8; + } u; +}; + #endif diff --git a/include/linux/hyperv.h b/include/linux/hyperv.h index bfbc37ce223b..f90de5abcd50 100644 --- a/include/linux/hyperv.h +++ b/include/linux/hyperv.h @@ -748,15 +748,6 @@ struct vmbus_close_msg { struct vmbus_channel_close_channel msg; }; -/* Define connection identifier type. */ -union hv_connection_id { - u32 asu32; - struct { - u32 id:24; - u32 reserved:8; - } u; -}; - enum vmbus_device_type { HV_IDE = 0, HV_SCSI,
This structure should be in hyperv-tlfs.h anyway, since it is part of the TLFS document. The definition conflicts with one added in hvgdk.h as part of the mshv driver so must be moved to hyperv-tlfs.h. Signed-off-by: Nuno Das Neves <nunodasneves@linux.microsoft.com> --- include/asm-generic/hyperv-tlfs.h | 9 +++++++++ include/linux/hyperv.h | 9 --------- 2 files changed, 9 insertions(+), 9 deletions(-)