public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: "Son P. Nguyen" <fastmutex@gmail.com>
To: w.d.hubbs@gmail.com
Cc: chris@the-brannons.com, kirk@reisers.ca,
	samuel.thibault@ens-lyon.org, gregkh@linuxfoundation.org,
	speakup@braille.uwo.ca, devel@driverdev.osuosl.org,
	linux-kernel@vger.kernel.org,
	"Son P. Nguyen" <fastmutex@gmail.com>
Subject: [PATCH] Staging: speakup: fixed reporting_keystroke variable type
Date: Sat, 17 May 2014 00:46:43 +0000	[thread overview]
Message-ID: <1400287603-9362-1-git-send-email-fastmutex@gmail.com> (raw)

From: "Son P. Nguyen" <fastmutex@gmail.com>

Fixed reporting_keystroke type to int instead of bool to quiet sparse
complaints of error cannot size expression.

This is a part of eudyptula-challenge.

Signed-off-by: Son P. Nguyen <fastmutex@gmail.com>
---
 drivers/staging/speakup/fakekey.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/drivers/staging/speakup/fakekey.c b/drivers/staging/speakup/fakekey.c
index 4299cf4..44ebb36 100644
--- a/drivers/staging/speakup/fakekey.c
+++ b/drivers/staging/speakup/fakekey.c
@@ -28,7 +28,7 @@
 #define PRESSED 1
 #define RELEASED 0
 
-static DEFINE_PER_CPU(bool, reporting_keystroke);
+static DEFINE_PER_CPU(int, reporting_keystroke);
 
 static struct input_dev *virt_keyboard;
 
@@ -78,10 +78,10 @@ void speakup_fake_down_arrow(void)
 	/* don't change CPU */
 	preempt_disable();
 
-	__this_cpu_write(reporting_keystroke, true);
+	__this_cpu_write(reporting_keystroke, 1);
 	input_report_key(virt_keyboard, KEY_DOWN, PRESSED);
 	input_report_key(virt_keyboard, KEY_DOWN, RELEASED);
-	__this_cpu_write(reporting_keystroke, false);
+	__this_cpu_write(reporting_keystroke, 0);
 
 	/* reenable preemption */
 	preempt_enable();
-- 
1.8.1.2


             reply	other threads:[~2014-05-17  0:46 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-05-17  0:46 Son P. Nguyen [this message]
2014-05-17  7:56 ` [PATCH] Staging: speakup: fixed reporting_keystroke variable type Dan Carpenter

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=1400287603-9362-1-git-send-email-fastmutex@gmail.com \
    --to=fastmutex@gmail.com \
    --cc=chris@the-brannons.com \
    --cc=devel@driverdev.osuosl.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=kirk@reisers.ca \
    --cc=linux-kernel@vger.kernel.org \
    --cc=samuel.thibault@ens-lyon.org \
    --cc=speakup@braille.uwo.ca \
    --cc=w.d.hubbs@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
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