From: YU Bo <tsu.yubo@gmail.com>
To: Dan Carpenter <dan.carpenter@oracle.com>
Cc: Patard <arnaud.patard@rtp-net.org>,
Kroah-Hartman <gregkh@linuxfoundation.org>,
Sim <nicholassimws@gmail.com>, Goyal <bhumirks@gmail.com>,
Barnes <clifton.a.barnes@gmail.com>,
Sachdeva <aquannie@gmail.com>, Frederick <fabf@skynet.be>,
Ravichandran <janani.rvchndrn@gmail.com>,
yuzibode@126.com, devel@driverdev.osuosl.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH] staging:xgifb: Fix Comparisons should place the constant on the right side of the test warning
Date: Wed, 27 Apr 2016 10:31:43 -0400 [thread overview]
Message-ID: <20160427143141.GB19115@yubo-2> (raw)
In-Reply-To: <20160427135836.GM4298@mwanda>
On Wed, Apr 27, 2016 at 04:58:36PM +0300, Dan Carpenter wrote:
>On Wed, Apr 27, 2016 at 09:27:39AM -0400, YU Bo wrote:
>> Fixed checkpatch.pl's warning 'Comparisons should place the constant on
>> the right side of the test'
>>
>> Signed-off-by: YU Bo <tsu.yubo@gmail.com>
>> ---
>> drivers/staging/xgifb/vb_setmode.c | 4 ++--
>> 1 file changed, 2 insertions(+), 2 deletions(-)
>>
>> diff --git a/drivers/staging/xgifb/vb_setmode.c b/drivers/staging/xgifb/vb_setmode.c
>> index 50c8ea4f5ab7..8bf253c224ad 100644
>> --- a/drivers/staging/xgifb/vb_setmode.c
>> +++ b/drivers/staging/xgifb/vb_setmode.c
>> @@ -1208,7 +1208,7 @@ static void const *XGI_GetLcdPtr(struct XGI330_LCDDataTablStruct const *table,
>> if (pVBInfo->LCDInfo & EnableScalingLCD)
>> tempdx &= (~PanelResInfo);
>>
>> - if (table[i].PANELID == tempdx) {
>> + if (tempdx == table[i].PANELID) {
>
>I don't understand why checkpatch is complaining about this one... It
>seems like a false positive. Maybe it's because .PANELID is a rubbish
>variable name.
Here, it seems like to notice upper case identifier on the left.
https://lkml.org/lkml/diff/2015/8/27/469/1
Best Regards,
>
>regards,
>dan carpetner
>
prev parent reply other threads:[~2016-04-27 14:31 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-04-27 13:27 [PATCH] staging:xgifb: Fix Comparisons should place the constant on the right side of the test warning YU Bo
2016-04-27 13:58 ` Dan Carpenter
2016-04-27 14:13 ` YU Bo
2016-04-27 14:31 ` YU Bo [this message]
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=20160427143141.GB19115@yubo-2 \
--to=tsu.yubo@gmail.com \
--cc=aquannie@gmail.com \
--cc=arnaud.patard@rtp-net.org \
--cc=bhumirks@gmail.com \
--cc=clifton.a.barnes@gmail.com \
--cc=dan.carpenter@oracle.com \
--cc=devel@driverdev.osuosl.org \
--cc=fabf@skynet.be \
--cc=gregkh@linuxfoundation.org \
--cc=janani.rvchndrn@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=nicholassimws@gmail.com \
--cc=yuzibode@126.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