From 864a5a37aa8c344209482d568ed8abecc38a3600 Mon Sep 17 00:00:00 2001 From: Malcolm Priestley Date: Wed, 20 Aug 2014 22:30:30 +0100 Subject: staging: vt6655: card.c change BBvCalculateParameter to vnt_get_phy_field Using vnt_get_phy_field means the values are not in the correct write order the lower word and the upper word need to be swapped over for an u32 write out. Rather create another data variable to manipulate this structure. Create a new union vnt_phy_field_swap with struct vnt_phy_field, the u16 word swap and the u32 write out. Signed-off-by: Malcolm Priestley Signed-off-by: Greg Kroah-Hartman --- drivers/staging/vt6655/desc.h | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'drivers/staging/vt6655/desc.h') diff --git a/drivers/staging/vt6655/desc.h b/drivers/staging/vt6655/desc.h index 1dd38f7..1842723 100644 --- a/drivers/staging/vt6655/desc.h +++ b/drivers/staging/vt6655/desc.h @@ -384,6 +384,12 @@ struct vnt_phy_field { __le16 len; } __packed; +union vnt_phy_field_swap { + struct vnt_phy_field field_read; + u16 swap[2]; + u32 field_write; +}; + typedef struct tagSRTS_g { struct vnt_phy_field b; struct vnt_phy_field a; -- cgit v1.1