NetBSD-Bugs archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

kern/41813: Real EIO being returned to userland as EFAULT



>Number:         41813
>Category:       kern
>Synopsis:       Real EIO being returned to userland as EFAULT
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    kern-bug-people
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Tue Aug 04 12:45:00 +0000 2009
>Originator:     Paul Ripke
>Release:        NetBSD 5.99.15, HEAD 20090731T0002Z
>Organization:
>Environment:
System: NetBSD kitt.stix.org.au 5.99.15 NetBSD 5.99.15 (KITT) #0: Sun Aug 2 
11:46:28 EST 2009 
stix%hex.stix.org.au@localhost:/u/netbsd/20090731T0002/obj.mac68k/u/netbsd/20090731T0002/src/sys/arch/mac68k/compile/KITT
 mac68k

Architecture: m68k
Machine: mac68k
>Description:
I have some bad blocks on a SCSI disk. Doing a dd of a file with bad
blocks to /dev/null results in "dd: /u/misc.tgz: Bad address", meanwhile
SCSI media errors are logged to syslog. Surely this should return EIO,
not EFAULT?

Confirmed return code via ktrace:

$ dd if=/u/misc.tgz of=/dev/null bs=64k
...
11662      1 dd       read(0x3, 0x4201000, 0x10000) Err#14 EFAULT

It's also worth noting that a dd of the disk raw device returns EIO,
as expected.

>How-To-Repeat:
Read a file with a bad block.
>Fix:
Had a quick look to see where this is coming from, didn't find anything
obvious. I'm also not sure if this is architecture specific, although I
would think/hope not.



Home | Main Index | Thread Index | Old Index