public inbox for linux-mtd@lists.infradead.org
 help / color / mirror / Atom feed
* RE: Invalid ioctl answer + another question
@ 2001-05-07 12:34 Williams, Kevin M.
  2001-05-11  3:29 ` Errors getting JFFS to work Edmund Troche
  0 siblings, 1 reply; 3+ messages in thread
From: Williams, Kevin M. @ 2001-05-07 12:34 UTC (permalink / raw)
  To: 'edmund@troche.org', linux-mtd

Edmund, 

I just posted a similar problem last week and David's suggestion fixed my
problem....

I was running a 2.4.4 kernel, but using the utilities built from an older
kernel (2.4.3-pre-3).  I rebuilt everything in the 'util' directory with the
new kernel headers from 2.4.4 and my ioctl error went away.  Try rebuilding
the mkfs.jffs binary with the new kernel headers.

However, I now have the following timeout error and question:

bash#>sbin/erase /dev/mtd2 0 6
MTD_open
Erase Total 6 Units
MTD_ioctlMTD_ioctl
Erase Unit Size MTD_ioctl
Performing Flash Erase of length 131072 at offset 0x0waiting for erase to
complete timed out.
MTD Erase failure: Input/output error<6>MTD_close

Can anyone give me any ideas on why I am getting this?  I just
double-checked, and the old 'erase' utility works with this same hardware
and my 2.4.3-pre-3 kernel (with the 5 April mtd snapsnot).

Thank you in advance for any help!

Kevin

-----Original Message-----
From: Edmund Troche [mailto:edmund@troche.org]
Sent: Sunday, May 06, 2001 3:23 PM
To: MTD Mailing List
Subject: Re: Invalid ioctl


I have  the same results with a 48MB DoC 2000 also.


Edmund

Edmund Troche wrote:

> I created a 8MB partition (nftla1) on a 8MB DoC 2000, and tried to cp a
jffs
> image that was created with mkfs.jffs, and got the following message:
>     Invalid ioctl 5401 (MEMGETINFO = 80204d01)
>     ECC needs a full sector write (adr: 9de00 size 134)
>
> The DiskOnChip is being found @ address 0xD6000 and it correctly detects
it as
> 8MB. JFFS and MTD support is compiled in, no modules in this case.
>
> Anyone familiar with what may be the problem? Thanks in advance for any
help.
>
> Edmund Troche
>
> ______________________________________________________
> Linux MTD discussion mailing list
> http://lists.infradead.org/mailman/listinfo/linux-mtd/


______________________________________________________
Linux MTD discussion mailing list
http://lists.infradead.org/mailman/listinfo/linux-mtd/

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Errors getting JFFS to work
  2001-05-07 12:34 Invalid ioctl answer + another question Williams, Kevin M.
@ 2001-05-11  3:29 ` Edmund Troche
  2001-05-11 16:37   ` David Woodhouse
  0 siblings, 1 reply; 3+ messages in thread
From: Edmund Troche @ 2001-05-11  3:29 UTC (permalink / raw)
  To: linux-mtd

Hi,

I've been following the mtd-howto instructions on how to get JFFS mounted in a
DoC, but with no luck so far, perhaps I'm missing something that might be
obvious to some of you. In a nutshell, I have a 386EX board with a 8MB DoC
2000, which I have had running with Linux 2.4.3 and the M-Systems code. I would
very much prefer to use the MTD code instead of the M-Systems code, therefore
I've been trying to get this working for the last couple of nights. The kernel
( 2.4.3) has the MTD support compiled in, no modules. When I boot it recognizes
the DoC correctly and it seems like I can ntfl_format and fdisk without
problems. The problems seems to start when I try to copy and image created with
mkfs.jffs into the mtd character device 0. Below I have attached some of the
terminal output from some of my commands. The utilities are being built from a
"util" directory that I created under my 2.4.3 kernel distribution (
/usr/src/linux/util ) according to the README in the mtd/util directory. So I
imagine my utilities are using the distribution header files. If anyone needs
some more information regarding this, please let me know and I will be happy to
provide it.


Thanks for your help.

Edmund



----------------------------- TERMINAL OUTPUT ---------------------------

/ # ./fdisk /dev/nftla

Command (m for help): p

Disk /dev/nftla: 16 heads, 1 sectors, 1020 cylinders
Units = cylinders of 16 * 512 bytes

     Device Boot    Start       End    Blocks   Id  System
/dev/nftla1             1      1020      8159+  83  Linux

Command (m for help): q

/ # cp /jffs.image /dev/mtd0
MTD_open
MTD_ioctl
Invalid ioctl 5401 (MEMGETINFO = 80204d01)
MTD_write
.......
....... (lots of MTD_write)
.......
MTD_write
ECC needs a full sector write (adr: 9de00 size 134)
MTD_close
/ # mount -t jffs /dev/mtdblock0 /mnt/jffs
mtdblock_open
ok
JFFS: Trying to mount device 1f:00.
jffs_scan_flash(): start pos = 0x0, end = 0x800000
check_partly_erased_sector():checking sector which contains offset 0x0 for
flipp
ing bits..
Kernel panic: Didn't read all bytes in flash_safe_read(). Returned 0

-----------------------------------------------------------------------

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Errors getting JFFS to work
  2001-05-11  3:29 ` Errors getting JFFS to work Edmund Troche
@ 2001-05-11 16:37   ` David Woodhouse
  0 siblings, 0 replies; 3+ messages in thread
From: David Woodhouse @ 2001-05-11 16:37 UTC (permalink / raw)
  To: edmund; +Cc: linux-mtd

edmund@troche.org said:
> When I boot it recognizes the DoC correctly and it seems like I can
> ntfl_format and fdisk without problems. The problems seems to start
> when I try to copy and image created with mkfs.jffs into the mtd
> character device 0.

You can't use JFFS on the DiskOnChip yet. Small amounts of hacking on the 
hardware driver are required - to make it deal with large reads and writes, 
etc.

Either you need to make the necessary changes, or just use NFTL on it.

--
dwmw2

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2001-05-11 16:33 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2001-05-07 12:34 Invalid ioctl answer + another question Williams, Kevin M.
2001-05-11  3:29 ` Errors getting JFFS to work Edmund Troche
2001-05-11 16:37   ` David Woodhouse

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox