Re: [PATCH 18/46] Staging: hv: storvsc: Add code to handle IDE devices using the storvsc driver

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

 



On Sat, Aug 27, 2011 at 11:31:17AM -0700, K. Y. Srinivasan wrote:
> @@ -59,6 +59,17 @@ struct storvsc_cmd_request {
>  	struct hv_storvsc_request request;
>  };
>  
> +static void storvsc_get_ide_info(struct hv_device *dev, int *target, int *path)
> +{
> +	*target =
> +		dev->dev_instance.b[5] << 8 | dev->dev_instance.b[4];
> +
> +	*path =
> +		dev->dev_instance.b[3] << 24 |
> +		dev->dev_instance.b[2] << 16 |
> +		dev->dev_instance.b[1] << 8  | dev->dev_instance.b[0];
> +}
> +

Does endianness matter here?  It seems like *path isn't actually used
anywhere.  Probably target and path should be u32 types?

regards,
dan carpenter

_______________________________________________
Virtualization mailing list
Virtualization@xxxxxxxxxxxxxxxxxxxxxxxxxx
https://lists.linux-foundation.org/mailman/listinfo/virtualization


[Index of Archives]     [KVM Development]     [Libvirt Development]     [Libvirt Users]     [CentOS Virtualization]     [Netdev]     [Ethernet Bridging]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Bugtraq]     [Yosemite Forum]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux Admin]     [Samba]

  Powered by Linux