# This is a BitKeeper generated patch for the following project:
# Project Name: Linux kernel tree
# This patch format is intended for GNU patch command version 2.5 or higher.
# This patch includes the following deltas:
#	           ChangeSet	1.1081  -> 1.1082 
#	  drivers/char/mem.c	1.36    -> 1.37   
#	drivers/scsi/sym53c8xx_2/sym_malloc.c	1.3     -> 1.4    
#
# The following is the BitKeeper ChangeSet Log
# --------------------------------------------
# 03/05/14	davidm@tiger.hpl.hp.com	1.1079.1.7
# Check in new SN2 file from Jes' gettimeoffset() patch.
# --------------------------------------------
# 03/05/14	davidm@tiger.hpl.hp.com	1.1082
# Small driver fixes.
# --------------------------------------------
#
diff -Nru a/drivers/char/mem.c b/drivers/char/mem.c
--- a/drivers/char/mem.c	Thu May 15 13:42:10 2003
+++ b/drivers/char/mem.c	Thu May 15 13:42:10 2003
@@ -540,7 +540,7 @@
 {
 	loff_t ret;
 
-	lock_kernel();
+	down(&file->f_dentry->d_inode->i_sem);
 	switch (orig) {
 		case 0:
 			file->f_pos = offset;
@@ -555,7 +555,7 @@
 		default:
 			ret = -EINVAL;
 	}
-	unlock_kernel();
+	up(&file->f_dentry->d_inode->i_sem);
 	return ret;
 }
 
diff -Nru a/drivers/scsi/sym53c8xx_2/sym_malloc.c b/drivers/scsi/sym53c8xx_2/sym_malloc.c
--- a/drivers/scsi/sym53c8xx_2/sym_malloc.c	Thu May 15 13:42:10 2003
+++ b/drivers/scsi/sym53c8xx_2/sym_malloc.c	Thu May 15 13:42:10 2003
@@ -150,6 +150,7 @@
 			((m_link_p) a)->next = h[i].next;
 			h[i].next = (m_link_p) a;
 #endif
+			break;
 		}
 		b = a ^ s;
 		q = &h[i];