Results 1 to 1 of 1
Hi all
I have a char driver that has been working fine for some time.
Simple Problem Statement:
Linux 2.6.9-42 kernel Uniprocesssor.
The Char device driver is opened by two ...
- 08-21-2009 #1Just Joined!
- Join Date
- Aug 2009
- Posts
- 1
SMP and Driver Problem
Hi all
I have a char driver that has been working fine for some time.
Simple Problem Statement:
Linux 2.6.9-42 kernel Uniprocesssor.
The Char device driver is opened by two applications from User space.
I use copy_from_user and copy_to_user to Recv and transfer information.
Every one is happy.
Now we decided to try out linux 2.6.9-78 large SMP and the same driver
now freezes the kernel.
The way I initiate a transfer is
if(down_trylock(&lock))
return FAIL;
// PASSED
err = copy_from_user(&kbuf, userbuf, sizeof(kbuf));
if (err)
{
ret = -EFAULT;
}
up(&lock);
.....
When I transfer to user space,
if(down_trylock(&lock))
return FAIL;
// PASSED
copy_to_user(XX, XX); // Similar to above...
up(&lock);
My question is, do I have to do anything special for large SMP to get it to working.
I also removed the locks to see if anything different happens. Nothing. Still the
kernel locks up.
Any help or suggestion would be very helpful.
Thanks
Nav


Reply With Quote
