diff options
author | Thomas Gleixner <tglx@linutronix.de> | 2005-11-07 06:15:40 -0500 |
---|---|---|
committer | Thomas Gleixner <tglx@mtd.linutronix.de> | 2005-11-07 09:06:59 -0500 |
commit | e5580fbe8a950131b9ccccce0f962811dfb9ef43 (patch) | |
tree | d7558eea2208a7b8fbc83c9a94f588b67aa5a3cc /drivers/mtd/devices/doc2001.c | |
parent | 69f34c98c1416eb74c55e38a21dbf3e294966514 (diff) |
[MTD] devices: Clean up trailing white spaces
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Diffstat (limited to 'drivers/mtd/devices/doc2001.c')
-rw-r--r-- | drivers/mtd/devices/doc2001.c | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/drivers/mtd/devices/doc2001.c b/drivers/mtd/devices/doc2001.c index 1e704915ef08..fcb28a6fd89f 100644 --- a/drivers/mtd/devices/doc2001.c +++ b/drivers/mtd/devices/doc2001.c | |||
@@ -4,7 +4,7 @@ | |||
4 | * (c) 1999 Machine Vision Holdings, Inc. | 4 | * (c) 1999 Machine Vision Holdings, Inc. |
5 | * (c) 1999, 2000 David Woodhouse <dwmw2@infradead.org> | 5 | * (c) 1999, 2000 David Woodhouse <dwmw2@infradead.org> |
6 | * | 6 | * |
7 | * $Id: doc2001.c,v 1.48 2005/01/05 18:05:12 dwmw2 Exp $ | 7 | * $Id: doc2001.c,v 1.49 2005/11/07 11:14:24 gleixner Exp $ |
8 | */ | 8 | */ |
9 | 9 | ||
10 | #include <linux/kernel.h> | 10 | #include <linux/kernel.h> |
@@ -196,10 +196,10 @@ static int DoC_IdentChip(struct DiskOnChip *doc, int floor, int chip) | |||
196 | DoC_Command(doc->virtadr, NAND_CMD_RESET, CDSN_CTRL_WP); | 196 | DoC_Command(doc->virtadr, NAND_CMD_RESET, CDSN_CTRL_WP); |
197 | DoC_WaitReady(doc->virtadr); | 197 | DoC_WaitReady(doc->virtadr); |
198 | 198 | ||
199 | /* Read the NAND chip ID: 1. Send ReadID command */ | 199 | /* Read the NAND chip ID: 1. Send ReadID command */ |
200 | DoC_Command(doc->virtadr, NAND_CMD_READID, CDSN_CTRL_WP); | 200 | DoC_Command(doc->virtadr, NAND_CMD_READID, CDSN_CTRL_WP); |
201 | 201 | ||
202 | /* Read the NAND chip ID: 2. Send address byte zero */ | 202 | /* Read the NAND chip ID: 2. Send address byte zero */ |
203 | DoC_Address(doc->virtadr, 1, 0x00, CDSN_CTRL_WP, 0x00); | 203 | DoC_Address(doc->virtadr, 1, 0x00, CDSN_CTRL_WP, 0x00); |
204 | 204 | ||
205 | /* Read the manufacturer and device id codes of the flash device through | 205 | /* Read the manufacturer and device id codes of the flash device through |
@@ -223,7 +223,7 @@ static int DoC_IdentChip(struct DiskOnChip *doc, int floor, int chip) | |||
223 | for (j = 0; nand_manuf_ids[j].id != 0x0; j++) { | 223 | for (j = 0; nand_manuf_ids[j].id != 0x0; j++) { |
224 | if (nand_manuf_ids[j].id == mfr) | 224 | if (nand_manuf_ids[j].id == mfr) |
225 | break; | 225 | break; |
226 | } | 226 | } |
227 | printk(KERN_INFO "Flash chip found: Manufacturer ID: %2.2X, " | 227 | printk(KERN_INFO "Flash chip found: Manufacturer ID: %2.2X, " |
228 | "Chip ID: %2.2X (%s:%s)\n", | 228 | "Chip ID: %2.2X (%s:%s)\n", |
229 | mfr, id, nand_manuf_ids[j].name, nand_flash_ids[i].name); | 229 | mfr, id, nand_manuf_ids[j].name, nand_flash_ids[i].name); |
@@ -275,7 +275,7 @@ static void DoC_ScanChips(struct DiskOnChip *this) | |||
275 | return; | 275 | return; |
276 | } | 276 | } |
277 | 277 | ||
278 | /* Fill out the chip array with {floor, chipno} for each | 278 | /* Fill out the chip array with {floor, chipno} for each |
279 | * detected chip in the device. */ | 279 | * detected chip in the device. */ |
280 | for (floor = 0, ret = 0; floor < MAX_FLOORS_MIL; floor++) { | 280 | for (floor = 0, ret = 0; floor < MAX_FLOORS_MIL; floor++) { |
281 | for (chip = 0 ; chip < numchips[floor] ; chip++) { | 281 | for (chip = 0 ; chip < numchips[floor] ; chip++) { |
@@ -309,7 +309,7 @@ static int DoCMil_is_alias(struct DiskOnChip *doc1, struct DiskOnChip *doc2) | |||
309 | tmp2 = ReadDOC(doc2->virtadr, AliasResolution); | 309 | tmp2 = ReadDOC(doc2->virtadr, AliasResolution); |
310 | if (tmp1 != tmp2) | 310 | if (tmp1 != tmp2) |
311 | return 0; | 311 | return 0; |
312 | 312 | ||
313 | WriteDOC((tmp1+1) % 0xff, doc1->virtadr, AliasResolution); | 313 | WriteDOC((tmp1+1) % 0xff, doc1->virtadr, AliasResolution); |
314 | tmp2 = ReadDOC(doc2->virtadr, AliasResolution); | 314 | tmp2 = ReadDOC(doc2->virtadr, AliasResolution); |
315 | if (tmp2 == (tmp1+1) % 0xff) | 315 | if (tmp2 == (tmp1+1) % 0xff) |
@@ -425,7 +425,7 @@ static int doc_read_ecc (struct mtd_info *mtd, loff_t from, size_t len, | |||
425 | return -EINVAL; | 425 | return -EINVAL; |
426 | 426 | ||
427 | /* Don't allow a single read to cross a 512-byte block boundary */ | 427 | /* Don't allow a single read to cross a 512-byte block boundary */ |
428 | if (from + len > ((from | 0x1ff) + 1)) | 428 | if (from + len > ((from | 0x1ff) + 1)) |
429 | len = ((from | 0x1ff) + 1) - from; | 429 | len = ((from | 0x1ff) + 1) - from; |
430 | 430 | ||
431 | /* Find the chip which is to be used and select it */ | 431 | /* Find the chip which is to be used and select it */ |
@@ -552,7 +552,7 @@ static int doc_write_ecc (struct mtd_info *mtd, loff_t to, size_t len, | |||
552 | 552 | ||
553 | #if 0 | 553 | #if 0 |
554 | /* Don't allow a single write to cross a 512-byte block boundary */ | 554 | /* Don't allow a single write to cross a 512-byte block boundary */ |
555 | if (to + len > ( (to | 0x1ff) + 1)) | 555 | if (to + len > ( (to | 0x1ff) + 1)) |
556 | len = ((to | 0x1ff) + 1) - to; | 556 | len = ((to | 0x1ff) + 1) - to; |
557 | #else | 557 | #else |
558 | /* Don't allow writes which aren't exactly one block */ | 558 | /* Don't allow writes which aren't exactly one block */ |
@@ -632,7 +632,7 @@ static int doc_write_ecc (struct mtd_info *mtd, loff_t to, size_t len, | |||
632 | 632 | ||
633 | /* write the block status BLOCK_USED (0x5555) at the end of ECC data | 633 | /* write the block status BLOCK_USED (0x5555) at the end of ECC data |
634 | FIXME: this is only a hack for programming the IPL area for LinuxBIOS | 634 | FIXME: this is only a hack for programming the IPL area for LinuxBIOS |
635 | and should be replace with proper codes in user space utilities */ | 635 | and should be replace with proper codes in user space utilities */ |
636 | WriteDOC(0x55, docptr, Mil_CDSN_IO); | 636 | WriteDOC(0x55, docptr, Mil_CDSN_IO); |
637 | WriteDOC(0x55, docptr, Mil_CDSN_IO + 1); | 637 | WriteDOC(0x55, docptr, Mil_CDSN_IO + 1); |
638 | 638 | ||
@@ -802,7 +802,7 @@ int doc_erase (struct mtd_info *mtd, struct erase_info *instr) | |||
802 | void __iomem *docptr = this->virtadr; | 802 | void __iomem *docptr = this->virtadr; |
803 | struct Nand *mychip = &this->chips[ofs >> this->chipshift]; | 803 | struct Nand *mychip = &this->chips[ofs >> this->chipshift]; |
804 | 804 | ||
805 | if (len != mtd->erasesize) | 805 | if (len != mtd->erasesize) |
806 | printk(KERN_WARNING "Erase not right size (%x != %x)n", | 806 | printk(KERN_WARNING "Erase not right size (%x != %x)n", |
807 | len, mtd->erasesize); | 807 | len, mtd->erasesize); |
808 | 808 | ||
@@ -870,9 +870,9 @@ static void __exit cleanup_doc2001(void) | |||
870 | while ((mtd=docmillist)) { | 870 | while ((mtd=docmillist)) { |
871 | this = mtd->priv; | 871 | this = mtd->priv; |
872 | docmillist = this->nextdoc; | 872 | docmillist = this->nextdoc; |
873 | 873 | ||
874 | del_mtd_device(mtd); | 874 | del_mtd_device(mtd); |
875 | 875 | ||
876 | iounmap(this->virtadr); | 876 | iounmap(this->virtadr); |
877 | kfree(this->chips); | 877 | kfree(this->chips); |
878 | kfree(mtd); | 878 | kfree(mtd); |