public inbox for linuxppc-dev@ozlabs.org 
 help / color / mirror / Atom feed
From: "majianpeng" <majianpeng@gmail•com>
To: "linuxppc-dev" <linuxppc-dev@lists•ozlabs.org>
Subject: Using existing function instead statement
Date: Fri, 3 Feb 2012 14:46:00 +0800	[thread overview]
Message-ID: <201202031445537184460@gmail.com> (raw)

>From 53bcbc301e72ed951f67abb6428199e7edfccc16 Mon Sep 17 00:00:00 2001
From: majianpeng <majianpeng@gmail•com>
Date: Fri, 3 Feb 2012 14:35:59 +0000
Subject: [PATCH] Using existing function instead statement.


Signed-off-by: majianpeng <majianpeng@gmail•com>
---
 drivers/macintosh/adb.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/macintosh/adb.c b/drivers/macintosh/adb.c
index 75049e7..b026896 100644
--- a/drivers/macintosh/adb.c
+++ b/drivers/macintosh/adb.c
@@ -710,7 +710,7 @@ static ssize_t adb_read(struct file *file, char __user *buf,
 	req = NULL;
 	spin_lock_irqsave(&state->lock, flags);
 	add_wait_queue(&state->wait_queue, &wait);
-	current->state = TASK_INTERRUPTIBLE;
+	set_current_state(TASK_INTERRUPTIBLE);
 
 	for (;;) {
 		req = state->completed;
@@ -734,7 +734,7 @@ static ssize_t adb_read(struct file *file, char __user *buf,
 		spin_lock_irqsave(&state->lock, flags);
 	}
 
-	current->state = TASK_RUNNING;
+	set_current_state(TASK_RUNNING);
 	remove_wait_queue(&state->wait_queue, &wait);
 	spin_unlock_irqrestore(&state->lock, flags);
 	
-- 
1.7.3

 				
--------------
majianpeng
2012-02-03

                 reply	other threads:[~2012-02-03  6:45 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=201202031445537184460@gmail.com \
    --to=majianpeng@gmail$(echo .)com \
    --cc=linuxppc-dev@lists$(echo .)ozlabs.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox