lkml.org 
[lkml]   [2015]   [Jun]   [25]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
SubjectRe: [PATCH v3 16/19] staging: sm750fb: fix brace placement
From
On Thu, Jun 25, 2015 at 5:17 AM, Sudip Mukherjee
<sudipm.mukherjee@gmail.com> wrote:
> On Wed, Jun 24, 2015 at 09:25:17AM -0700, Juston Li wrote:
>> Fix brace placement errors caught by checkpatch.pl
>> ERROR: that open brace { should be on the previous line
>>
>> Signed-off-by: Juston Li <juston.h.li@gmail.com>
>> ---
> <snip>
>> @@ -71,14 +66,11 @@ static void setDisplayControl(int ctrl, int dispState)
>> POKE32(PANEL_DISPLAY_CTRL, ulDisplayCtrlReg);
>> }
>>
>> - }
>> /* Set the secondary display control */
>> - else
>> - {
>> + } else {
> just a thought. The comment previously was at the beginning of the else
> block, but now it will be placed inside the if block - at the end.
> will it confuse code readers afterwards?
>
> regards
> sudip

I placed it above the else to make it consistent with the if statement with
similar comment that the else corresponds to:

/* Set the primary display control */
- if (!ctrl)+ if (!ctrl) {

Thanks
Juston


\
 
 \ /
  Last update: 2015-06-25 18:21    [W:0.074 / U:0.488 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site