Re: [PATCH v1] hyper-v: Use UUID API for exporting the GUID

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

 



On Wed, Apr 22, 2020 at 03:59:37PM +0300, Andy Shevchenko wrote:
> There is export_guid() function which exports guid_t to the u8 array.
> Use it instead of open coding variant.
> 
> This allows to hide the uuid_t internals.
> 
> Signed-off-by: Andy Shevchenko <andriy.shevchenko@xxxxxxxxxxxxxxx>
> ---
>  drivers/hv/hv_trace.h | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/hv/hv_trace.h b/drivers/hv/hv_trace.h
> index a43bc76c2d5d0..579d19bdc0981 100644
> --- a/drivers/hv/hv_trace.h
> +++ b/drivers/hv/hv_trace.h
> @@ -286,8 +286,8 @@ TRACE_EVENT(vmbus_send_tl_connect_request,
>  		    __field(int, ret)
>  		    ),
>  	    TP_fast_assign(
> -		    memcpy(__entry->guest_id, &msg->guest_endpoint_id.b, 16);
> -		    memcpy(__entry->host_id, &msg->host_service_id.b, 16);
> +		    export_guid(__entry->guest_id, &msg->guest_endpoint_id);
> +		    export_guid(__entry->host_id, &msg->host_service_id);

I was about to say I couldn't find this function but it seems to have
been introduced in d01cd62400b which is currently in Linus' master
branch. That's fine then.

I will queue this up to hyperv-fixes for 5.7.

Wei.

>  		    __entry->ret = ret;
>  		    ),
>  	    TP_printk("sending guest_endpoint_id %pUl, host_service_id %pUl, "
> -- 
> 2.26.1
> 



[Index of Archives]     [Linux Samsung SoC]     [Linux Rockchip SoC]     [Linux Actions SoC]     [Linux for Synopsys ARC Processors]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]


  Powered by Linux