All of lore.kernel.org
 help / color / mirror / Atom feed
* DbAu1550 copy file corruption
@ 2005-11-30 10:14 ` David Sanchez
  0 siblings, 0 replies; 11+ messages in thread
From: David Sanchez @ 2005-11-30 10:14 UTC (permalink / raw)
  To: linux-mips

Hi,

I still have a problem of file corruption after a big copy (around 300M)
and no solution at this time...

Who have a dbau1550 and who could try the following script to check
copies on big files?


####################################
#!/bin/sh

path_file=$1
if test -z $path_file ; then
	path_file=`pwd`
fi

# You can modify the source and the destination filename, the source
file 
# size and the number of iterations.

# Source and destination filename
src_file=${path_file}/src_test_file
dst_file=${path_file}/dst_test_file
# Source file size: 300M
src_file_size=300000
# Number of iterations
let max_it=50

# Create source file
if test ! -f ${src_file} ; then
	echo "* Generating ${src_file}..."
	dd bs=1024 count=${src_file_size} if=/dev/urandom of=${src_file}
	echo ""
fi

# Check if source exists
if test -f ${src_file} ; then
	echo "* Check copy from $src_file to $dst_file:"
	echo ""
else
	echo "$src_file does NOT exist" ; exec false
fi

# Clear destination
if test -f ${dst_file} ; then
	rm ${dst_file}
fi

# Go
let i=0
let nb_err=0
while [ $i -lt $max_it ]
do
	cp ${src_file} ${dst_file}
	cmp ${src_file} ${dst_file}
	if [ $? -eq 0 ]
		then
			echo ${src_file} ${dst_file} IDENTICAL
		else
			let nb_err=nb_err+1
		fi
	rm ${dst_file}
	let i=i+1
done

# Result
echo ""
echo "Done"
echo -e "\t$nb_err error(s) over $max_it iteration(s)"
echo ""
####################################

On my DbAu155 + Sata HDD on PDC20579 + Linux Kernel 2.6.10 + busybox
1.0:
Each destination differs from the source:

####################################
* Generating ./src_test_file...
300000+0 records in
300000+0 records out

* Check copy from ./src_test_file to ./dst_test_file:

./src_test_file ./dst_test_file differ: char 10388254, line 40877
./src_test_file ./dst_test_file differ: char 69932960, line 274140
./src_test_file ./dst_test_file differ: char 36867840, line 144723
...

Done
        50 error(s) over 50 iteration(s)
####################################

Thanks'

David

^ permalink raw reply	[flat|nested] 11+ messages in thread
* RE: DbAu1550 copy file corruption
@ 2005-11-30 13:18 ` David Sanchez
  0 siblings, 0 replies; 11+ messages in thread
From: David Sanchez @ 2005-11-30 13:18 UTC (permalink / raw)
  To: linux-mips

Hi,

I forgot to mention that I'm making my test on a ext2 filesystem...

More can somebody launch the test on another Alchemy board ? Dbau1500,
Dbau1200, etc...

Thanks

^ permalink raw reply	[flat|nested] 11+ messages in thread
* RE: DbAu1550 copy file corruption
@ 2005-11-30 13:27 ` David Sanchez
  0 siblings, 0 replies; 11+ messages in thread
From: David Sanchez @ 2005-11-30 13:27 UTC (permalink / raw)
  To: linux-mips

Hi,

I forgot to mention that I'm making my test on a ext2 filesystem...

More can somebody launch the test on another Alchemy board ? Dbau1500, Dbau1200, etc...

Thanks

David

-----Message d'origine-----
De : David Sanchez 
Envoyé : mercredi 30 novembre 2005 11:14
À : 'linux-mips@linux-mips.org'
Objet : DbAu1550 copy file corruption

Hi,

I still have a problem of file corruption after a big copy (around 300M) and no solution at this time...

Who have a dbau1550 and who could try the following script to check copies on big files?


####################################
#!/bin/sh

path_file=$1
if test -z $path_file ; then
	path_file=`pwd`
fi

# You can modify the source and the destination filename, the source file 
# size and the number of iterations.

# Source and destination filename
src_file=${path_file}/src_test_file
dst_file=${path_file}/dst_test_file
# Source file size: 300M
src_file_size=300000
# Number of iterations
let max_it=50

# Create source file
if test ! -f ${src_file} ; then
	echo "* Generating ${src_file}..."
	dd bs=1024 count=${src_file_size} if=/dev/urandom of=${src_file}
	echo ""
fi

# Check if source exists
if test -f ${src_file} ; then
	echo "* Check copy from $src_file to $dst_file:"
	echo ""
else
	echo "$src_file does NOT exist" ; exec false
fi

# Clear destination
if test -f ${dst_file} ; then
	rm ${dst_file}
fi

# Go
let i=0
let nb_err=0
while [ $i -lt $max_it ]
do
	cp ${src_file} ${dst_file}
	cmp ${src_file} ${dst_file}
	if [ $? -eq 0 ]
		then
			echo ${src_file} ${dst_file} IDENTICAL
		else
			let nb_err=nb_err+1
		fi
	rm ${dst_file}
	let i=i+1
done

# Result
echo ""
echo "Done"
echo -e "\t$nb_err error(s) over $max_it iteration(s)"
echo ""
####################################

On my DbAu155 + Sata HDD on PDC20579 + Linux Kernel 2.6.10 + busybox 1.0:
Each destination differs from the source:

####################################
* Generating ./src_test_file...
300000+0 records in
300000+0 records out

* Check copy from ./src_test_file to ./dst_test_file:

./src_test_file ./dst_test_file differ: char 10388254, line 40877
./src_test_file ./dst_test_file differ: char 69932960, line 274140
./src_test_file ./dst_test_file differ: char 36867840, line 144723
...

Done
        50 error(s) over 50 iteration(s)
####################################

Thanks'

David

^ permalink raw reply	[flat|nested] 11+ messages in thread
* RE: DbAu1550 copy file corruption
@ 2005-12-01 13:10 ` David Sanchez
  0 siblings, 0 replies; 11+ messages in thread
From: David Sanchez @ 2005-12-01 13:10 UTC (permalink / raw)
  To: Sergei Shtylylov, linux-mips

Hi,

As all my pci sata controllers operate up to 66Mhz, I add a divider to the pci clock in the board_setup.c of the au1550 to obtain 32 Mhz pci clock. But the problem still appear... (More the bus is slow, less the problem appear: maybe because it is a timing issue ?)

I try the HPT371B (which works for us). I try several PCI sata controllers (Promise PDC20779, PDC 20579, SiliconImage Sil3112, etc...). More I try the drivers provided by Promise instead of the libata. But the problem still appear...

Sergei, is the PCI clock frequency issue only for the HPT371N or even for PCI sata controller ? Do you mean that all the users of the dbau1550 needs to set the PCI clock to 32Mhz?
Have you try my script on your board? 

Thanks.

David

-----Message d'origine-----
De : Sergei Shtylylov [mailto:sshtylyov@ru.mvista.com] 
Envoyé : mercredi 30 novembre 2005 18:46
À : Dan Malek
Cc : David Sanchez
Objet : Re: DbAu1550 copy file corruption

Hello.

Dan Malek wrote:

> Have you tested this on an NFS partition?  Does
> the on-board HPT371 work?  I know the latter two
> used to work, but I don't remember testing a 2.6.10
> kernel, I've been using newer ones.

   Do you mean HPT371N? It shouldn't work (and does not work for us) since the 
current driver has severe clocking problems with anything but HPT370/374 on a 
66 MHz PCI. So with the default 64 MHz Au1550 PCI clock the driver just locks 
up; it can only work if you plug in a 33 MHz PCI card to get Au1550 PCI 
clocked at 32 MHz. I was in the process of fixing this but this work is 
currently preempted by more urgent stuff... :-(

WBR, Sergei

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

end of thread, other threads:[~2005-12-01 13:10 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-11-30 10:14 DbAu1550 copy file corruption David Sanchez
2005-11-30 10:14 ` David Sanchez
2005-11-30 16:27 ` Dan Malek
2005-11-30 16:27   ` Dan Malek
2005-11-30 17:35   ` Sergei Shtylylov
  -- strict thread matches above, loose matches on Subject: below --
2005-11-30 13:18 David Sanchez
2005-11-30 13:18 ` David Sanchez
2005-11-30 13:27 David Sanchez
2005-11-30 13:27 ` David Sanchez
2005-12-01 13:10 David Sanchez
2005-12-01 13:10 ` David Sanchez

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.