From: Roel Kluin <roel.kluin@gmail.com>
To: adaplas@gmail.com
Cc: Andrew Morton <akpm@linux-foundation.org>,
linux-fbdev-devel@lists.sourceforge.net
Subject: [PATCH] arkfb: misplaced parentheses?
Date: Sun, 15 Feb 2009 16:57:56 +0100 [thread overview]
Message-ID: <49983B84.7010002@gmail.com> (raw)
I think below is what was intended? otherwise we could as well have written:
regval || (code[0] & 4) ? 0x80 : 0)
But it doesn't seem likely that regval should be considered as boolean
please review.
-------------------------->8------------------8<---------------------------
fix misplaced parentheses
Signed-off-by: Roel Kluin <roel.kluin@gmail.com>
---
diff --git a/drivers/video/arkfb.c b/drivers/video/arkfb.c
index 314d186..d583bea 100644
--- a/drivers/video/arkfb.c
+++ b/drivers/video/arkfb.c
@@ -470,7 +470,7 @@ static void ark_dac_read_regs(void *data, u8 *code, int count)
while (count != 0)
{
- vga_wseq(NULL, 0x1C, regval | (code[0] & 4) ? 0x80 : 0);
+ vga_wseq(NULL, 0x1C, regval | (code[0] & 4 ? 0x80 : 0));
code[1] = vga_r(NULL, dac_regs[code[0] & 3]);
count--;
code += 2;
@@ -485,7 +485,7 @@ static void ark_dac_write_regs(void *data, u8 *code, int count)
while (count != 0)
{
- vga_wseq(NULL, 0x1C, regval | (code[0] & 4) ? 0x80 : 0);
+ vga_wseq(NULL, 0x1C, regval | (code[0] & 4 ? 0x80 : 0));
vga_w(NULL, dac_regs[code[0] & 3], code[1]);
count--;
code += 2;
------------------------------------------------------------------------------
Open Source Business Conference (OSBC), March 24-25, 2009, San Francisco, CA
-OSBC tackles the biggest issue in open source: Open Sourcing the Enterprise
-Strategies to boost innovation and cut costs with open source participation
-Receive a $600 discount off the registration fee with the source code: SFAD
http://p.sf.net/sfu/XcvMzF8H
next reply other threads:[~2009-02-15 15:58 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-02-15 15:57 Roel Kluin [this message]
2009-02-15 22:01 ` [PATCH] arkfb: misplaced parentheses? Ondrej Zajicek
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=49983B84.7010002@gmail.com \
--to=roel.kluin@gmail.com \
--cc=adaplas@gmail.com \
--cc=akpm@linux-foundation.org \
--cc=linux-fbdev-devel@lists.sourceforge.net \
/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;
as well as URLs for NNTP newsgroup(s).