Commit 96372446 authored by Harvey Harrison's avatar Harvey Harrison Committed by David Woodhouse

[MTD] [NAND] diskonchip.c fix sparse endian warnings

Signed-off-by: default avatarHarvey Harrison <harvey.harrison@gmail.com>
Cc: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: default avatarDavid Woodhouse <David.Woodhouse@intel.com>
parent fc1f397b
...@@ -1125,9 +1125,9 @@ static inline int __init nftl_partscan(struct mtd_info *mtd, struct mtd_partitio ...@@ -1125,9 +1125,9 @@ static inline int __init nftl_partscan(struct mtd_info *mtd, struct mtd_partitio
goto out; goto out;
mh = (struct NFTLMediaHeader *)buf; mh = (struct NFTLMediaHeader *)buf;
mh->NumEraseUnits = le16_to_cpu(mh->NumEraseUnits); le16_to_cpus(&mh->NumEraseUnits);
mh->FirstPhysicalEUN = le16_to_cpu(mh->FirstPhysicalEUN); le16_to_cpus(&mh->FirstPhysicalEUN);
mh->FormattedSize = le32_to_cpu(mh->FormattedSize); le32_to_cpus(&mh->FormattedSize);
printk(KERN_INFO " DataOrgID = %s\n" printk(KERN_INFO " DataOrgID = %s\n"
" NumEraseUnits = %d\n" " NumEraseUnits = %d\n"
...@@ -1235,12 +1235,12 @@ static inline int __init inftl_partscan(struct mtd_info *mtd, struct mtd_partiti ...@@ -1235,12 +1235,12 @@ static inline int __init inftl_partscan(struct mtd_info *mtd, struct mtd_partiti
doc->mh1_page = doc->mh0_page + (4096 >> this->page_shift); doc->mh1_page = doc->mh0_page + (4096 >> this->page_shift);
mh = (struct INFTLMediaHeader *)buf; mh = (struct INFTLMediaHeader *)buf;
mh->NoOfBootImageBlocks = le32_to_cpu(mh->NoOfBootImageBlocks); le32_to_cpus(&mh->NoOfBootImageBlocks);
mh->NoOfBinaryPartitions = le32_to_cpu(mh->NoOfBinaryPartitions); le32_to_cpus(&mh->NoOfBinaryPartitions);
mh->NoOfBDTLPartitions = le32_to_cpu(mh->NoOfBDTLPartitions); le32_to_cpus(&mh->NoOfBDTLPartitions);
mh->BlockMultiplierBits = le32_to_cpu(mh->BlockMultiplierBits); le32_to_cpus(&mh->BlockMultiplierBits);
mh->FormatFlags = le32_to_cpu(mh->FormatFlags); le32_to_cpus(&mh->FormatFlags);
mh->PercentUsed = le32_to_cpu(mh->PercentUsed); le32_to_cpus(&mh->PercentUsed);
printk(KERN_INFO " bootRecordID = %s\n" printk(KERN_INFO " bootRecordID = %s\n"
" NoOfBootImageBlocks = %d\n" " NoOfBootImageBlocks = %d\n"
...@@ -1277,12 +1277,12 @@ static inline int __init inftl_partscan(struct mtd_info *mtd, struct mtd_partiti ...@@ -1277,12 +1277,12 @@ static inline int __init inftl_partscan(struct mtd_info *mtd, struct mtd_partiti
/* Scan the partitions */ /* Scan the partitions */
for (i = 0; (i < 4); i++) { for (i = 0; (i < 4); i++) {
ip = &(mh->Partitions[i]); ip = &(mh->Partitions[i]);
ip->virtualUnits = le32_to_cpu(ip->virtualUnits); le32_to_cpus(&ip->virtualUnits);
ip->firstUnit = le32_to_cpu(ip->firstUnit); le32_to_cpus(&ip->firstUnit);
ip->lastUnit = le32_to_cpu(ip->lastUnit); le32_to_cpus(&ip->lastUnit);
ip->flags = le32_to_cpu(ip->flags); le32_to_cpus(&ip->flags);
ip->spareUnits = le32_to_cpu(ip->spareUnits); le32_to_cpus(&ip->spareUnits);
ip->Reserved0 = le32_to_cpu(ip->Reserved0); le32_to_cpus(&ip->Reserved0);
printk(KERN_INFO " PARTITION[%d] ->\n" printk(KERN_INFO " PARTITION[%d] ->\n"
" virtualUnits = %d\n" " virtualUnits = %d\n"
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment