aboutsummaryrefslogtreecommitdiffstats
path: root/arch/mips/sibyte/sb1250/bcm1250_tbprof.c
diff options
context:
space:
mode:
authorRalf Baechle <ralf@linux-mips.org>2005-02-03 08:37:41 -0500
committerRalf Baechle <ralf@linux-mips.org>2005-10-29 14:30:22 -0400
commitdb89a48c1f2fa9197404ca511d9df808196ca25d (patch)
treec9332b5c9d8dcb0f900927d177139d6124608058 /arch/mips/sibyte/sb1250/bcm1250_tbprof.c
parente3c4807825501f0b445fe34b627669be24b59320 (diff)
Replace deprecated interruptible_sleep_on() function call with direct
wait-queue usage. Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Diffstat (limited to 'arch/mips/sibyte/sb1250/bcm1250_tbprof.c')
-rw-r--r--arch/mips/sibyte/sb1250/bcm1250_tbprof.c11
1 files changed, 9 insertions, 2 deletions
diff --git a/arch/mips/sibyte/sb1250/bcm1250_tbprof.c b/arch/mips/sibyte/sb1250/bcm1250_tbprof.c
index 7f813ae9eaff..dba3d0872e7e 100644
--- a/arch/mips/sibyte/sb1250/bcm1250_tbprof.c
+++ b/arch/mips/sibyte/sb1250/bcm1250_tbprof.c
@@ -28,6 +28,7 @@
28#include <linux/fs.h> 28#include <linux/fs.h>
29#include <linux/errno.h> 29#include <linux/errno.h>
30#include <linux/reboot.h> 30#include <linux/reboot.h>
31#include <linux/wait.h>
31#include <asm/uaccess.h> 32#include <asm/uaccess.h>
32#include <asm/io.h> 33#include <asm/io.h>
33#include <asm/sibyte/sb1250.h> 34#include <asm/sibyte/sb1250.h>
@@ -231,6 +232,7 @@ int sbprof_zbprof_start(struct file *filp)
231 232
232int sbprof_zbprof_stop(void) 233int sbprof_zbprof_stop(void)
233{ 234{
235 DEFINE_WAIT(wait);
234 DBG(printk(DEVNAME ": stopping\n")); 236 DBG(printk(DEVNAME ": stopping\n"));
235 237
236 if (sbp.tb_enable) { 238 if (sbp.tb_enable) {
@@ -240,7 +242,9 @@ int sbprof_zbprof_stop(void)
240 this sleep happens. */ 242 this sleep happens. */
241 if (sbp.tb_armed) { 243 if (sbp.tb_armed) {
242 DBG(printk(DEVNAME ": wait for disarm\n")); 244 DBG(printk(DEVNAME ": wait for disarm\n"));
243 interruptible_sleep_on(&sbp.tb_sync); 245 prepare_to_wait(&sbp.tb_sync, &wait, TASK_INTERRUPTIBLE);
246 schedule();
247 finish_wait(&sbp.tb_sync, &wait);
244 DBG(printk(DEVNAME ": disarm complete\n")); 248 DBG(printk(DEVNAME ": disarm complete\n"));
245 } 249 }
246 free_irq(K_INT_TRACE_FREEZE, &sbp); 250 free_irq(K_INT_TRACE_FREEZE, &sbp);
@@ -348,7 +352,10 @@ static int sbprof_tb_ioctl(struct inode *inode,
348 error = sbprof_zbprof_stop(); 352 error = sbprof_zbprof_stop();
349 break; 353 break;
350 case SBPROF_ZBWAITFULL: 354 case SBPROF_ZBWAITFULL:
351 interruptible_sleep_on(&sbp.tb_read); 355 DEFINE_WAIT(wait);
356 prepare_to_wait(&sbp.tb_read, &wait, TASK_INTERRUPTIBLE);
357 schedule();
358 finish_wait(&sbp.tb_read, &wait);
352 /* XXXKW check if interrupted? */ 359 /* XXXKW check if interrupted? */
353 return put_user(TB_FULL, (int *) arg); 360 return put_user(TB_FULL, (int *) arg);
354 default: 361 default: