chiark / gitweb /
[PATCH] update udev to scsi_id 0.7
authorpatmans@us.ibm.com <patmans@us.ibm.com>
Sat, 16 Oct 2004 06:04:44 +0000 (23:04 -0700)
committerGreg KH <gregkh@suse.de>
Wed, 27 Apr 2005 05:02:45 +0000 (22:02 -0700)
Update udev's scsi_id to version 0.7, this fixes a bad bug in scsi_id on
64 bit systems.

extras/scsi_id/ChangeLog
extras/scsi_id/Makefile
extras/scsi_id/release-notes
extras/scsi_id/scsi_id.c

index 724977dbf49169a170e56e9c581459cd0a7c30b5..d2a8be5b18b3548120da439c44f1d83396f63a86 100644 (file)
@@ -1,3 +1,9 @@
+2004-oct-15:
+       * Makefile: Add $(QUIET) to sync with the udev version.
+
+2004-oct-06:
+       * scsi_id.c: fix alignment for use with 64 bit pointers
+
 2004-jul-30:
        * scsi_id.c, scsi_serial.c: Align the buffer passed to scsi_serial,
          don't bother aligning and memcpy-ing the result in scsi_inquiry.
 2004-jul-30:
        * scsi_id.c, scsi_serial.c: Align the buffer passed to scsi_serial,
          don't bother aligning and memcpy-ing the result in scsi_inquiry.
index 2f134bcdbdd17ba2daafadcb8bb8f1bacae17c80..610faac4b70227c2b5958ab6fe3bc8701f21fd1e 100644 (file)
@@ -14,7 +14,7 @@
 # along with this program; if not, write to the Free Software
 # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
 
 # along with this program; if not, write to the Free Software
 # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
 
-SCSI_ID_VERSION=0.6
+SCSI_ID_VERSION=0.7
 
 prefix =
 etcdir =        ${prefix}/etc
 
 prefix =
 etcdir =        ${prefix}/etc
index 302817ea7f0e0fa478f0daa93beef00d672bb09c..c7ea51679c813d70800b61de387c347824fc1e95 100644 (file)
@@ -1,6 +1,6 @@
-Version 0.6 of scsi_id is available at:
+Version 0.7 of scsi_id is available at:
 
 
-http://www-124.ibm.com/storageio/scsi_id/scsi_id-0.6.tar.gz
+http://www-124.ibm.com/storageio/scsi_id/scsi_id-0.7.tar.gz
 
 scsi_id is a program to generate a unique identifier for a given SCSI
 device.
 
 scsi_id is a program to generate a unique identifier for a given SCSI
 device.
@@ -14,13 +14,10 @@ Requires:
 - Linux kernel 2.6
 - libsysfs 0.4.0
 
 - Linux kernel 2.6
 - libsysfs 0.4.0
 
-Major changes since the last release:
+Changes since the last release:
        
        
-       - add -u option, patch from Christoph Varoqui, to substitute white
-         space with underscores so it is easier to use the output as a
-         device name.
+       - Fix a bug introduced in version 0.6 so that buffer alignement
+         works on 64 bit systems. Without this fix, it crashes on 64 bit
+         systems.
 
 
-       - Use 254 bytes for SCSI INQUIRY commands, patch from Hannes
-         Reinecke.
-
-See ChangeLog for more details.
+       - Add $(QUIET) to sync up with the udev Makefile
index 6395b822ced7925ff0118d0c89feb728796d7ee0..d2155e68663908a88f43458c687bebe91f1ce090 100644 (file)
@@ -713,7 +713,8 @@ static int scsi_id(const char *target_path, char *maj_min_dev)
 
 #define ALIGN   512
        unaligned_buf = malloc(MAX_SERIAL_LEN + ALIGN);
 
 #define ALIGN   512
        unaligned_buf = malloc(MAX_SERIAL_LEN + ALIGN);
-       serial = (char*) (((int) unaligned_buf + (ALIGN - 1)) & ~(ALIGN - 1));
+       serial = (char*) (((unsigned long) unaligned_buf + (ALIGN - 1))
+                         & ~(ALIGN - 1));
        dprintf("buffer unaligned 0x%p; aligned 0x%p\n", unaligned_buf, serial);
 #undef ALIGN
 
        dprintf("buffer unaligned 0x%p; aligned 0x%p\n", unaligned_buf, serial);
 #undef ALIGN