From: Jonathan Corbet Date: Thu, 15 May 2008 22:09:48 +0000 (-0600) Subject: gdth: cdev lock_kernel() pushdown X-Git-Tag: v2.6.27-rc1~1103^2~116 X-Git-Url: http://pilppa.com/gitweb/?a=commitdiff_plain;h=46787b481be00d5443d385480d12470728406cf4;p=linux-2.6-omap-h63xx.git gdth: cdev lock_kernel() pushdown Signed-off-by: Jonathan Corbet --- diff --git a/drivers/scsi/gdth.c b/drivers/scsi/gdth.c index 46771d4c81b..822d5214692 100644 --- a/drivers/scsi/gdth.c +++ b/drivers/scsi/gdth.c @@ -120,6 +120,7 @@ #include #include #include +#include #ifdef GDTH_RTC #include @@ -4019,10 +4020,12 @@ static int gdth_open(struct inode *inode, struct file *filep) { gdth_ha_str *ha; + lock_kernel(); list_for_each_entry(ha, &gdth_instances, list) { if (!ha->sdev) ha->sdev = scsi_get_host_dev(ha->shost); } + unlock_kernel(); TRACE(("gdth_open()\n")); return 0;