From mboxrd@z Thu Jan 1 00:00:00 1970 From: Matthew Dharm Date: Tue, 20 Mar 2001 21:12:47 +0000 Subject: Matching semantics for version numbers.... MIME-Version: 1 Content-Type: multipart/mixed; boundary="xB0nW4MQa6jZONgY" Message-Id: List-Id: To: linux-hotplug@vger.kernel.org --xB0nW4MQa6jZONgY Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable I recently discovered a small problem in the code that matches devices to drivers in the way version numbers are handled. The tests used against version numbers are < and > -- while this doesn't seem like a problem at first, consider usb-storage where we need to have one entry for a device up to rev 3.00, and a different entry for devices rev 3.00 and higher. The current mechanism means that the first entry must test against less than 3.00 and the second against greater than 2.99, which is counter-intuitive at best.=20 I'd like to change these to <=3D and >=3D -- and yes, I understand what a m= ajor change that is. The drivers which use the version numbers would have to be changed, and so would the hotplug scripts. But I wanted to throw this idea out there for consideration. It's certainly much easier to maintain the code with the <=3D and >=3D semantics, since I can give a definate terminat= ion point to my entries. With these semantics, the above example uses <=3D 2.99 and >=3D 3.00 as the test values respectively, which is much clearer. Matt --=20 Matthew Dharm Home: mdharm-usb@one-eyed-alien.= net=20 Maintainer, Linux USB Mass Storage Driver THEY CASTRATED MY QUAKE BITS! I WANT THEM BACK!!!! -- Greg User Friendly, 3/27/1998 --xB0nW4MQa6jZONgY Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.0.4 (GNU/Linux) Comment: For info see http://www.gnupg.org iD8DBQE6t8fPz64nssGU+ykRApneAKDY+3BJE+N68llaB4GY7KGC1ozl2wCeLaI5 U6RZQnmzrpNs/sr/q3YHLHk= =c4xc -----END PGP SIGNATURE----- --xB0nW4MQa6jZONgY-- _______________________________________________ Linux-hotplug-devel mailing list http://linux-hotplug.sourceforge.net Linux-hotplug-devel@lists.sourceforge.net http://lists.sourceforge.net/lists/listinfo/linux-hotplug-devel