Skip to contentSkip to conversation

patch to leave cfi in read-array on suspend(reposted)

PATCH David Anders 3 participants 3 messages Oct 19, 2006 Memory technology devices (MTD)

lore
Share & tools
lore
#0 lore raw

greetings,

during some testing with several samsung s3c24xx based devices it was discovered that often the cfi_cmdset_0001.c would not leave the chip in read-array mode on suspend. this is an issue if the same flash chip is used for the bootloader that needs to be read on resume. attached is a patch generated against the 2.6.18 kernel and has been tested with several s3c24xx based devices as well as several sharp lh79520 devices. your feedback would be appreciated.

__________________________________________________
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
http://mail.yahoo.com

drivers/mtd/chips/cfi_cmdset_0001.c +2 -0
@@ -2224,6 +2224,8 @@
 		case FL_CFI_QUERY:
 		case FL_JEDEC_QUERY:
 			if (chip->oldstate == FL_READY) {
+				/* place the chip in a known state before suspend */
+				map_write(map, CMD(0xFF), cfi->chips[i].start);
 				chip->oldstate = chip->state;
 				chip->state = FL_PM_SUSPENDED;
 				/* No need to wake_up() on this state change -
#1 lore raw
Quoted 12 lines · David Anders

greetings,

during some testing with several samsung s3c24xx based devices it was discovered that often the cfi_cmdset_0001.c would not leave the chip in read-array mode on suspend. this is an issue if the same flash chip is used for the bootloader that needs to be read on resume. attached is a patch generated against the 2.6.18 kernel and has been tested with several s3c24xx based devices as well as several sharp lh79520 devices. your feedback would be appreciated.

Quoted 1 line
#2 lore raw
Quoted 10 lines · Nicolas Pitre
Quoted 10 lines

during some testing with several samsung s3c24xx based devices it was discovered that often the cfi_cmdset_0001.c would not leave the chip in read-array mode on suspend. this is an issue if the same flash chip is used for the bootloader that needs to be read on resume. attached is a patch generated against the 2.6.18 kernel and has been tested with several s3c24xx based devices as well as several sharp lh79520 devices. your feedback would be appreciated.

Quoted 3 lines
Quoted 1 line

Thanks,

will add it to my git tree and take care about its destiny.

Signature · 2 lines
Best regards,
Artem Bityutskiy (Битюцкий Артём)