Skip to content

Commit

Permalink
m68k: Remove big kernel lock in cache flush code
Browse files Browse the repository at this point in the history
The cache flush code doesn't need a lock, so we can remove the use of the BKL.

Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
Reported-by: Arnd Bergmann <arnd@arndb.de>
Suggested-by: Andreas Schwab <schwab@linux-m68k.org>
  • Loading branch information
Geert Uytterhoeven committed Oct 22, 2010
1 parent 22e58f9 commit 2f81a18
Showing 1 changed file with 0 additions and 3 deletions.
3 changes: 0 additions & 3 deletions arch/m68k/kernel/sys_m68k.c
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@
#include <linux/mm.h>
#include <linux/fs.h>
#include <linux/smp.h>
#include <linux/smp_lock.h>
#include <linux/sem.h>
#include <linux/msg.h>
#include <linux/shm.h>
Expand Down Expand Up @@ -377,7 +376,6 @@ sys_cacheflush (unsigned long addr, int scope, int cache, unsigned long len)
struct vm_area_struct *vma;
int ret = -EINVAL;

lock_kernel();
if (scope < FLUSH_SCOPE_LINE || scope > FLUSH_SCOPE_ALL ||
cache & ~FLUSH_CACHE_BOTH)
goto out;
Expand Down Expand Up @@ -446,7 +444,6 @@ sys_cacheflush (unsigned long addr, int scope, int cache, unsigned long len)
}
}
out:
unlock_kernel();
return ret;
}

Expand Down

0 comments on commit 2f81a18

Please sign in to comment.