Re: cifs causes BUG: soft lockup detected on CPU

From: Andrew Morton
Date: Thu Mar 29 2007 - 05:21:57 EST


On Thu, 29 Mar 2007 11:13:04 +0200 "Valentin Zaharov" <karlos_@xxxxxxxxxxxxxxxx> wrote:

> I've tried different kernel versions.
> Right now iam using generic 2.6.9-42 on one machine and 2.6.20.1 on
> another one.
> I also tried various distributions ( Suse, CentOS, RHEL4 ) - not sure it
> is relevant.
> Tried installing latest cifs modules, tried changing CIFSMaxBufSize to
> 15000, without luck.
> Freezes are totally random - sometimes they happen 2-4 times a day,
> sometimes it can take 2 weeks.

Yeah, it's a relatively recently known-bug, I'm afraid.

Probably this will keep you out of trouble until it gets fixed
for real:

--- a/include/linux/fs.h~a
+++ a/include/linux/fs.h
@@ -627,25 +627,7 @@ extern void inode_double_unlock(struct i
*/
static inline loff_t i_size_read(const struct inode *inode)
{
-#if BITS_PER_LONG==32 && defined(CONFIG_SMP)
- loff_t i_size;
- unsigned int seq;
-
- do {
- seq = read_seqcount_begin(&inode->i_size_seqcount);
- i_size = inode->i_size;
- } while (read_seqcount_retry(&inode->i_size_seqcount, seq));
- return i_size;
-#elif BITS_PER_LONG==32 && defined(CONFIG_PREEMPT)
- loff_t i_size;
-
- preempt_disable();
- i_size = inode->i_size;
- preempt_enable();
- return i_size;
-#else
return inode->i_size;
-#endif
}

/*
_

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/