From huntting@hunkular.glarp.com Fri May 14 20:36:37 1999
Return-Path: <huntting@hunkular.glarp.com>
Received: from hunkular.glarp.com (hunkular.glarp.com [199.117.25.251])
	by hub.freebsd.org (Postfix) with ESMTP id 3BC8014D69
	for <FreeBSD-gnats-submit@freebsd.org>; Fri, 14 May 1999 20:36:36 -0700 (PDT)
	(envelope-from huntting@hunkular.glarp.com)
Received: (from huntting@localhost)
	by hunkular.glarp.com (8.9.2/8.9.2) id VAA11460;
	Fri, 14 May 1999 21:36:36 -0600 (MDT)
	(envelope-from huntting)
Message-Id: <199905150336.VAA11460@hunkular.glarp.com>
Date: Fri, 14 May 1999 21:36:36 -0600 (MDT)
From: Brad Huntting <huntting@hunkular.glarp.com>
Reply-To: huntting@hunkular.glarp.com
To: FreeBSD-gnats-submit@freebsd.org
Subject: scsi scanning causes "cam_periph_mapmem" kernel message
X-Send-Pr-Version: 3.2

>Number:         11719
>Category:       kern
>Synopsis:       scsi scanning causes "cam_periph_mapmem" kernel message
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    freebsd-bugs
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Fri May 14 20:40:01 PDT 1999
>Closed-Date:    Sun May 16 17:21:44 PDT 1999
>Last-Modified:  Sun May 16 17:22:14 PDT 1999
>Originator:     Brad Huntting
>Release:        FreeBSD 3.1-RELEASE i386
>Organization:
marginal
>Environment:

	I have a UMAX Vista-S6E SCSI scanner connected to a single
	processor 686 system with on board Adaptech SCSI which
	attaches itself to /dev/pass4.  I'm using "scanimage" and
	"xscanimage" from the graphics/sane ports collection to
	try to scan a simple image.

>Description:

	When I use scanimage or xscanimage (part of the "sane"
	port), the software is able to scan small images (low
	res/preview/line art) ok, but at a 100dpi it fails and
	quietly outputs a truncated image file.  In the process it
	causes the kernel to spit out the error:

		cam_periph_mapmem: attempt to map 130050 bytes, which is greater than DFLTPHYS

	Ktrace shows that the following ioctl() caused the message:

		10955 scanimage CALL  open(0xefbf552c,0x2,0x2809c294)
		10955 scanimage NAMI  "/dev/pass4"
		10955 scanimage RET   open 4
		... (fork) ...
		10956 scanimage CALL  madvise(0x8076000,0x1000,0x5)
		10956 scanimage RET   madvise 0
		10956 scanimage CALL  ioctl(0x4,CAMIOCOMMAND,0x8076000)
		10956 scanimage RET   ioctl -1 errno 7 Argument list too long

	I recompiled sane with -g, and got as far as learning that
	the error occurs during the first call to the libsane.so
	function sane_read().  Unfortunately that's as far as I've
	gotten.

>How-To-Repeat:

	Well, if the error occurs with all SCSI scanners using
	/dev/pass* then this is pretty easy to duplicate:  Just
	install "sane", and try to scan any full page image at
	100dpi resolution.

>Fix:
	
	Nothing yet.


>Release-Note:
>Audit-Trail:

From: "Kenneth D. Merry" <ken@plutotech.com>
To: huntting@hunkular.glarp.com
Cc: FreeBSD-gnats-submit@FreeBSD.ORG
Subject: Re: kern/11719: scsi scanning causes "cam_periph_mapmem" kernel message
Date: Fri, 14 May 1999 21:46:31 -0600 (MDT)

 Brad Huntting wrote...
 > 
 > >Number:         11719
 > >Category:       kern
 > >Synopsis:       scsi scanning causes "cam_periph_mapmem" kernel message
 > >Confidential:   no
 > >Severity:       serious
 > >Priority:       medium
 > >Responsible:    freebsd-bugs
 > >State:          open
 > >Quarter:        
 > >Keywords:       
 > >Date-Required:
 > >Class:          sw-bug
 > >Submitter-Id:   current-users
 > >Arrival-Date:   Fri May 14 20:40:01 PDT 1999
 > >Closed-Date:
 > >Last-Modified:
 > >Originator:     Brad Huntting
 > >Release:        FreeBSD 3.1-RELEASE i386
 > >Organization:
 > marginal
 > >Environment:
 > 
 > 	I have a UMAX Vista-S6E SCSI scanner connected to a single
 > 	processor 686 system with on board Adaptech SCSI which
 > 	attaches itself to /dev/pass4.  I'm using "scanimage" and
 > 	"xscanimage" from the graphics/sane ports collection to
 > 	try to scan a simple image.
 > 
 > >Description:
 > 
 > 	When I use scanimage or xscanimage (part of the "sane"
 > 	port), the software is able to scan small images (low
 > 	res/preview/line art) ok, but at a 100dpi it fails and
 > 	quietly outputs a truncated image file.  In the process it
 > 	causes the kernel to spit out the error:
 > 
 > 		cam_periph_mapmem: attempt to map 130050 bytes, which is greater than DFLTPHYS
 > 
 
 This is a bug in SANE, not FreeBSD.  In any case, it has been fixed in the
 ports tree.  Grab the latest version of the SANE port from the ports tree
 and recompile.
 
 Ken
 -- 
 Kenneth Merry
 ken@plutotech.com
 

From: Brad.Huntting@qwest.com
To: "Kenneth D. Merry" <ken@plutotech.com>
Cc: FreeBSD-gnats-submit@FreeBSD.ORG
Subject: Re: kern/11719: scsi scanning causes "cam_periph_mapmem" kernel message 
Date: Fri, 14 May 1999 22:54:37 -0600

 > This is a bug in SANE, not FreeBSD.  In any case, it has been fixed in the
 > ports tree.  Grab the latest version of the SANE port from the ports tree
 > and recompile.
 
 thanx!
 
State-Changed-From-To: open->closed 
State-Changed-By: steve 
State-Changed-When: Sun May 16 17:21:44 PDT 1999 
State-Changed-Why:  
This problem has been fixed in the current sane port. 
>Unformatted:
