diff options
author | Takashi Iwai <tiwai@suse.de> | 2011-12-01 16:32:18 +0100 |
---|---|---|
committer | Takashi Iwai <tiwai@suse.de> | 2011-12-01 16:32:18 +0100 |
commit | cf54d47c13c2b171f946289de445102c676d4258 (patch) | |
tree | c7e88f33402257f3e06bc708e58843518d8ca17b /include | |
parent | 88d686027bb43f585914c77dd363f6e817b42c2a (diff) | |
parent | bda63586bc5929e97288cdb371bb6456504867ed (diff) |
Merge branch 'fix/asoc' into for-linus
Diffstat (limited to 'include')
-rw-r--r-- | include/linux/sigma.h | 13 |
1 files changed, 4 insertions, 9 deletions
diff --git a/include/linux/sigma.h b/include/linux/sigma.h index e2accb3164d..d0de882c0d9 100644 --- a/include/linux/sigma.h +++ b/include/linux/sigma.h @@ -24,7 +24,7 @@ struct sigma_firmware { struct sigma_firmware_header { unsigned char magic[7]; u8 version; - u32 crc; + __le32 crc; }; enum { @@ -40,19 +40,14 @@ enum { struct sigma_action { u8 instr; u8 len_hi; - u16 len; - u16 addr; + __le16 len; + __be16 addr; unsigned char payload[]; }; static inline u32 sigma_action_len(struct sigma_action *sa) { - return (sa->len_hi << 16) | sa->len; -} - -static inline size_t sigma_action_size(struct sigma_action *sa, u32 payload_len) -{ - return sizeof(*sa) + payload_len + (payload_len % 2); + return (sa->len_hi << 16) | le16_to_cpu(sa->len); } extern int process_sigma_firmware(struct i2c_client *client, const char *name); |