From owner-svn-src-head@FreeBSD.ORG Wed May 12 07:24:25 2010 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id B73B41065670; Wed, 12 May 2010 07:24:25 +0000 (UTC) (envelope-from ronald-freebsd8@klop.yi.org) Received: from smtp-out3.tiscali.nl (smtp-out3.tiscali.nl [195.241.79.178]) by mx1.freebsd.org (Postfix) with ESMTP id 72EE28FC0A; Wed, 12 May 2010 07:24:24 +0000 (UTC) Received: from [212.123.145.58] (helo=sjakie.klop.ws) by smtp-out3.tiscali.nl with esmtp (Exim) (envelope-from ) id 1OC6Ip-0005CR-P4; Wed, 12 May 2010 09:24:23 +0200 Received: from 212-123-145-58.ip.telfort.nl (localhost [127.0.0.1]) by sjakie.klop.ws (Postfix) with ESMTP id 715A8BFC3; Wed, 12 May 2010 09:24:17 +0200 (CEST) Content-Type: text/plain; charset=us-ascii; format=flowed; delsp=yes To: "Matt Jacob" , src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org References: <201005112222.o4BMM1uq012874@svn.freebsd.org> Date: Wed, 12 May 2010 09:24:17 +0200 MIME-Version: 1.0 From: "Ronald Klop" Message-ID: In-Reply-To: <201005112222.o4BMM1uq012874@svn.freebsd.org> User-Agent: Opera Mail/10.10 (FreeBSD) Content-Transfer-Encoding: quoted-printable Cc: Subject: Re: svn commit: r207933 - head/sys/cam/scsi X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 12 May 2010 07:24:25 -0000 On Wed, 12 May 2010 00:22:01 +0200, Matt Jacob wrote= : > Author: mjacob > Date: Tue May 11 22:22:01 2010 > New Revision: 207933 > URL: http://svn.freebsd.org/changeset/base/207933 > > Log: > Deal sensibly with more than 26 sg devices. It isn't a complete > solution. > Sponsored by: Panasas > MFC after: 1 week > > Modified: > head/sys/cam/scsi/scsi_sg.c > > Modified: head/sys/cam/scsi/scsi_sg.c > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D > --- head/sys/cam/scsi/scsi_sg.c Tue May 11 21:07:47 2010 (r207932) > +++ head/sys/cam/scsi/scsi_sg.c Tue May 11 22:22:01 2010 (r207933) > @@ -303,7 +303,12 @@ sgregister(struct cam_periph *periph, vo > softc->dev =3D make_dev(&sg_cdevsw, periph->unit_number, > UID_ROOT, GID_OPERATOR, 0600, "%s%d", > periph->periph_name, periph->unit_number); > - (void)make_dev_alias(softc->dev, "sg%c", 'a' + periph->unit_number); > + if (periph->unit_number < 26) { > + (void)make_dev_alias(softc->dev, "sg%c", periph->unit_number + 'a'); > + } else { > + (void)make_dev_alias(softc->dev, "sg%c%c", > + ((periph->unit_number / 26) - 1) + 'a', periph->unit_number + =20 > 'a'); > + } > cam_periph_lock(periph); > softc->dev->si_drv1 =3D periph; Wow, did you copy this from windows? :-)