From mboxrd@z Thu Jan 1 00:00:00 1970 From: Hannes Reinecke Date: Thu, 04 Mar 2004 12:05:27 +0000 Subject: Re: %c option does not handle LF as a seperator Message-Id: <40471B87.6080806@suse.de> List-Id: References: <2F75A5CCEF1E6A4C8CA2E75CF7F529E902036598@orsmsx409.jf.intel.com> In-Reply-To: <2F75A5CCEF1E6A4C8CA2E75CF7F529E902036598@orsmsx409.jf.intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable To: linux-hotplug@vger.kernel.org Patrick Mansfield wrote: > On Tue, Mar 02, 2004 at 04:42:43PM -0800, Greg KH wrote: >=20 >>On Tue, Mar 02, 2004 at 04:36:57PM -0800, Sabharwal, Atul wrote: >> >>>=20 >>> >>>>Greg, >>>> >>>>There is a problem with %c as it only accepts the space de-limitted >>>>fields. The last >>>>Field may be delimitted rather than space de-limitted.=20 >>>> >>>>I am not able to reference the last field. My rules is like >>>> >>>>BUS=3D"scsi", PROGRAM=3D"/sbin/scsi_id", RESULT=3D"SSEAGATE ST318436LW >>>>3BM07NKA000070456Z6B",=20 >>>> NAME=3D"disk-sda-%c{3}" >>>> >>>>%c{1} & %c{2} options in NAME key work fine. %c{0} gives whole string >>>>and %c{3} does not work >>>>Although it should return the serial number. >> >>Care to send a patch? Or how about a scsi_id fix? >=20 >=20 > I haven't ever seen a LF in the SCSI vendor, model, or page 0x80. I am not > sure if it is allowed by the standards. >=20 It's not. At least not for page 0x80: ASCII data fields shall contain only ASCII graphic codes (i.e., code=20 values 20h through 7Eh) (from SPC-3). But actually it's not page 0x80 which is the culprit (0x80 returns only=20 the serial number, which seems to be ok), but rather the model name=20 (from INQUIRY or page 0x83). What does the device say at initialisation? There should be boot messages from the SCSI layer; if something's dodgy=20 with the data it should show up there, too. Care to send me the output of dmesg? Cheers, Hannes --=20 Dr. Hannes Reinecke hare@suse.de SuSE Linux AG S390 & zSeries Maxfeldstra=DFe 5 +49 911 74053 688 90409 N=FCrnberg http://www.suse.de ------------------------------------------------------- This SF.Net email is sponsored by: IBM Linux Tutorials Free Linux tutorial presented by Daniel Robbins, President and CEO of GenToo technologies. Learn everything from fundamentals to system administration.http://ads.osdn.com/?ad_id=1470&alloc_id638&op=CCk _______________________________________________ Linux-hotplug-devel mailing list http://linux-hotplug.sourceforge.net Linux-hotplug-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linux-hotplug-devel