From owner-freebsd-scsi@FreeBSD.ORG Tue Apr 5 11:53:14 2011 Return-Path: Delivered-To: freebsd-scsi@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 9CB941065675; Tue, 5 Apr 2011 11:53:14 +0000 (UTC) (envelope-from borjam@sarenet.es) Received: from proxypop2b.sarenet.es (proxypop2.sarenet.es [194.30.0.95]) by mx1.freebsd.org (Postfix) with ESMTP id 5BFD78FC12; Tue, 5 Apr 2011 11:53:13 +0000 (UTC) Received: from [172.16.1.55] (ssglan.sare.net [192.148.167.100]) by proxypop2b.sarenet.es (Postfix) with ESMTP id F0D7973A5D; Tue, 5 Apr 2011 13:53:11 +0200 (CEST) Mime-Version: 1.0 (Apple Message framework v1084) Content-Type: text/plain; charset=us-ascii From: Borja Marcos In-Reply-To: Date: Tue, 5 Apr 2011 13:53:11 +0200 Content-Transfer-Encoding: quoted-printable Message-Id: References: <4D9AF9B7.9030107@FreeBSD.org> To: Borja Marcos X-Mailer: Apple Mail (2.1084) Cc: freebsd-scsi@FreeBSD.org, Andriy Gapon Subject: Re: propose: change some sense codes handling X-BeenThere: freebsd-scsi@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SCSI subsystem List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 05 Apr 2011 11:53:14 -0000 On Apr 5, 2011, at 1:30 PM, Borja Marcos wrote: >=20 > On Apr 5, 2011, at 1:15 PM, Andriy Gapon wrote: >=20 > As far as I know, this shouldn't be reported by a non-removable media = device. It should be used by removable media such as tape units, = magneto-optical drives, CDROM drives, WORMs... >=20 >=20 > If a card read reports this, I assume that either the reader has = crappy firmware _or_ it has an electrical contact problem with the = media. But ignoring this error just could lead to data loss. In the case = of a user replacing a memory card with a mounted filesystem, it would be = certainly a data loss (blocks intended for one card written to a = different card?) To clarify my somewhat fuzzy message. I assume a card reader should = report this in the following cases: - User has replaced the card - User has extracted and reinserted the card - Electrical contact problem - Crappy reader firmware In either case it shouldn't be ignored causing just a retry. In the case of a fixed memory pendrive, well, it would indicate either = some serious internal error (this message is intended for removable = media) or, again, maybe an unplugged and plugged on USB device, at most? = Of course there's the option of buggy firmware reporting this for a = non-removable media unit. When you unplug a USB drive from the USB bus you are unplugging both the = media and the controller.=20 Borja.