Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

drivers/crypto/hifn_795x.c trivial endianness annotations

NB: remaining endianness warnings in the file are, AFAICS, real bugs.

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>

authored by

Al Viro and committed by
Linus Torvalds
e68970cd 97968358

+14 -14
+14 -14
drivers/crypto/hifn_795x.c
··· 392 392 393 393 struct hifn_desc 394 394 { 395 - volatile u32 l; 396 - volatile u32 p; 395 + volatile __le32 l; 396 + volatile __le32 p; 397 397 }; 398 398 399 399 struct hifn_dma { ··· 481 481 482 482 struct hifn_base_command 483 483 { 484 - volatile u16 masks; 485 - volatile u16 session_num; 486 - volatile u16 total_source_count; 487 - volatile u16 total_dest_count; 484 + volatile __le16 masks; 485 + volatile __le16 session_num; 486 + volatile __le16 total_source_count; 487 + volatile __le16 total_dest_count; 488 488 }; 489 489 490 490 #define HIFN_BASE_CMD_COMP 0x0100 /* enable compression engine */ ··· 504 504 */ 505 505 struct hifn_crypt_command 506 506 { 507 - volatile u16 masks; 508 - volatile u16 header_skip; 509 - volatile u16 source_count; 510 - volatile u16 reserved; 507 + volatile __le16 masks; 508 + volatile __le16 header_skip; 509 + volatile __le16 source_count; 510 + volatile __le16 reserved; 511 511 }; 512 512 513 513 #define HIFN_CRYPT_CMD_ALG_MASK 0x0003 /* algorithm: */ ··· 670 670 { 671 671 u32 ret; 672 672 673 - ret = readl((char *)(dev->bar[0]) + reg); 673 + ret = readl(dev->bar[0] + reg); 674 674 675 675 return ret; 676 676 } ··· 679 679 { 680 680 u32 ret; 681 681 682 - ret = readl((char *)(dev->bar[1]) + reg); 682 + ret = readl(dev->bar[1] + reg); 683 683 684 684 return ret; 685 685 } 686 686 687 687 static inline void hifn_write_0(struct hifn_device *dev, u32 reg, u32 val) 688 688 { 689 - writel(val, (char *)(dev->bar[0]) + reg); 689 + writel(val, dev->bar[0] + reg); 690 690 } 691 691 692 692 static inline void hifn_write_1(struct hifn_device *dev, u32 reg, u32 val) 693 693 { 694 - writel(val, (char *)(dev->bar[1]) + reg); 694 + writel(val, dev->bar[1] + reg); 695 695 } 696 696 697 697 static void hifn_wait_puc(struct hifn_device *dev)