Commit 7755265a authored by Mike Rapoport's avatar Mike Rapoport Committed by Greg Kroah-Hartman

staging: sm750fb: setDisplayControl: rename local vairables

Remove HungarianCamelCase notation.
Signed-off-by: default avatarMike Rapoport <mike.rapoport@gmail.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent c436e6ba
...@@ -9,25 +9,25 @@ ...@@ -9,25 +9,25 @@
static void setDisplayControl(int ctrl, int disp_state) static void setDisplayControl(int ctrl, int disp_state)
{ {
/* state != 0 means turn on both timing & plane en_bit */ /* state != 0 means turn on both timing & plane en_bit */
unsigned long ulDisplayCtrlReg, ulReservedBits; unsigned long reg, reserved;
int cnt; int cnt;
cnt = 0; cnt = 0;
/* Set the primary display control */ /* Set the primary display control */
if (!ctrl) { if (!ctrl) {
ulDisplayCtrlReg = PEEK32(PANEL_DISPLAY_CTRL); reg = PEEK32(PANEL_DISPLAY_CTRL);
/* Turn on/off the Panel display control */ /* Turn on/off the Panel display control */
if (disp_state) { if (disp_state) {
/* Timing should be enabled first before enabling the plane /* Timing should be enabled first before enabling the plane
* because changing at the same time does not guarantee that * because changing at the same time does not guarantee that
* the plane will also enabled or disabled. * the plane will also enabled or disabled.
*/ */
ulDisplayCtrlReg = FIELD_SET(ulDisplayCtrlReg, reg = FIELD_SET(reg,
PANEL_DISPLAY_CTRL, TIMING, ENABLE); PANEL_DISPLAY_CTRL, TIMING, ENABLE);
POKE32(PANEL_DISPLAY_CTRL, ulDisplayCtrlReg); POKE32(PANEL_DISPLAY_CTRL, reg);
ulDisplayCtrlReg = FIELD_SET(ulDisplayCtrlReg, reg = FIELD_SET(reg,
PANEL_DISPLAY_CTRL, PLANE, ENABLE); PANEL_DISPLAY_CTRL, PLANE, ENABLE);
/* Added some masks to mask out the reserved bits. /* Added some masks to mask out the reserved bits.
...@@ -35,7 +35,7 @@ static void setDisplayControl(int ctrl, int disp_state) ...@@ -35,7 +35,7 @@ static void setDisplayControl(int ctrl, int disp_state)
* writing to the PRIMARY_DISPLAY_CTRL, therefore, the register * writing to the PRIMARY_DISPLAY_CTRL, therefore, the register
* reserved bits are needed to be masked out. * reserved bits are needed to be masked out.
*/ */
ulReservedBits = FIELD_SET(0, PANEL_DISPLAY_CTRL, RESERVED_1_MASK, ENABLE) | reserved = FIELD_SET(0, PANEL_DISPLAY_CTRL, RESERVED_1_MASK, ENABLE) |
FIELD_SET(0, PANEL_DISPLAY_CTRL, RESERVED_2_MASK, ENABLE) | FIELD_SET(0, PANEL_DISPLAY_CTRL, RESERVED_2_MASK, ENABLE) |
FIELD_SET(0, PANEL_DISPLAY_CTRL, RESERVED_3_MASK, ENABLE); FIELD_SET(0, PANEL_DISPLAY_CTRL, RESERVED_3_MASK, ENABLE);
...@@ -45,9 +45,9 @@ static void setDisplayControl(int ctrl, int disp_state) ...@@ -45,9 +45,9 @@ static void setDisplayControl(int ctrl, int disp_state)
*/ */
do { do {
cnt++; cnt++;
POKE32(PANEL_DISPLAY_CTRL, ulDisplayCtrlReg); POKE32(PANEL_DISPLAY_CTRL, reg);
} while ((PEEK32(PANEL_DISPLAY_CTRL) & ~ulReservedBits) != } while ((PEEK32(PANEL_DISPLAY_CTRL) & ~reserved) !=
(ulDisplayCtrlReg & ~ulReservedBits)); (reg & ~reserved));
printk("Set Panel Plane enbit:after tried %d times\n", cnt); printk("Set Panel Plane enbit:after tried %d times\n", cnt);
} else { } else {
/* When turning off, there is no rule on the programming /* When turning off, there is no rule on the programming
...@@ -57,28 +57,28 @@ static void setDisplayControl(int ctrl, int disp_state) ...@@ -57,28 +57,28 @@ static void setDisplayControl(int ctrl, int disp_state)
* next vertical sync. Need to find out if it is necessary to * next vertical sync. Need to find out if it is necessary to
* wait for 1 vsync before modifying the timing enable bit. * wait for 1 vsync before modifying the timing enable bit.
* */ * */
ulDisplayCtrlReg = FIELD_SET(ulDisplayCtrlReg, reg = FIELD_SET(reg,
PANEL_DISPLAY_CTRL, PLANE, DISABLE); PANEL_DISPLAY_CTRL, PLANE, DISABLE);
POKE32(PANEL_DISPLAY_CTRL, ulDisplayCtrlReg); POKE32(PANEL_DISPLAY_CTRL, reg);
ulDisplayCtrlReg = FIELD_SET(ulDisplayCtrlReg, reg = FIELD_SET(reg,
PANEL_DISPLAY_CTRL, TIMING, DISABLE); PANEL_DISPLAY_CTRL, TIMING, DISABLE);
POKE32(PANEL_DISPLAY_CTRL, ulDisplayCtrlReg); POKE32(PANEL_DISPLAY_CTRL, reg);
} }
} else { } else {
/* Set the secondary display control */ /* Set the secondary display control */
ulDisplayCtrlReg = PEEK32(CRT_DISPLAY_CTRL); reg = PEEK32(CRT_DISPLAY_CTRL);
if (disp_state) { if (disp_state) {
/* Timing should be enabled first before enabling the plane because changing at the /* Timing should be enabled first before enabling the plane because changing at the
same time does not guarantee that the plane will also enabled or disabled. same time does not guarantee that the plane will also enabled or disabled.
*/ */
ulDisplayCtrlReg = FIELD_SET(ulDisplayCtrlReg, reg = FIELD_SET(reg,
CRT_DISPLAY_CTRL, TIMING, ENABLE); CRT_DISPLAY_CTRL, TIMING, ENABLE);
POKE32(CRT_DISPLAY_CTRL, ulDisplayCtrlReg); POKE32(CRT_DISPLAY_CTRL, reg);
ulDisplayCtrlReg = FIELD_SET(ulDisplayCtrlReg, reg = FIELD_SET(reg,
CRT_DISPLAY_CTRL, PLANE, ENABLE); CRT_DISPLAY_CTRL, PLANE, ENABLE);
/* Added some masks to mask out the reserved bits. /* Added some masks to mask out the reserved bits.
...@@ -87,16 +87,16 @@ static void setDisplayControl(int ctrl, int disp_state) ...@@ -87,16 +87,16 @@ static void setDisplayControl(int ctrl, int disp_state)
* reserved bits are needed to be masked out. * reserved bits are needed to be masked out.
*/ */
ulReservedBits = FIELD_SET(0, CRT_DISPLAY_CTRL, RESERVED_1_MASK, ENABLE) | reserved = FIELD_SET(0, CRT_DISPLAY_CTRL, RESERVED_1_MASK, ENABLE) |
FIELD_SET(0, CRT_DISPLAY_CTRL, RESERVED_2_MASK, ENABLE) | FIELD_SET(0, CRT_DISPLAY_CTRL, RESERVED_2_MASK, ENABLE) |
FIELD_SET(0, CRT_DISPLAY_CTRL, RESERVED_3_MASK, ENABLE) | FIELD_SET(0, CRT_DISPLAY_CTRL, RESERVED_3_MASK, ENABLE) |
FIELD_SET(0, CRT_DISPLAY_CTRL, RESERVED_4_MASK, ENABLE); FIELD_SET(0, CRT_DISPLAY_CTRL, RESERVED_4_MASK, ENABLE);
do { do {
cnt++; cnt++;
POKE32(CRT_DISPLAY_CTRL, ulDisplayCtrlReg); POKE32(CRT_DISPLAY_CTRL, reg);
} while ((PEEK32(CRT_DISPLAY_CTRL) & ~ulReservedBits) != } while ((PEEK32(CRT_DISPLAY_CTRL) & ~reserved) !=
(ulDisplayCtrlReg & ~ulReservedBits)); (reg & ~reserved));
printk("Set Crt Plane enbit:after tried %d times\n", cnt); printk("Set Crt Plane enbit:after tried %d times\n", cnt);
} else { } else {
/* When turning off, there is no rule on the programming /* When turning off, there is no rule on the programming
...@@ -106,13 +106,13 @@ static void setDisplayControl(int ctrl, int disp_state) ...@@ -106,13 +106,13 @@ static void setDisplayControl(int ctrl, int disp_state)
* vertical sync. Need to find out if it is necessary to * vertical sync. Need to find out if it is necessary to
* wait for 1 vsync before modifying the timing enable bit. * wait for 1 vsync before modifying the timing enable bit.
*/ */
ulDisplayCtrlReg = FIELD_SET(ulDisplayCtrlReg, reg = FIELD_SET(reg,
CRT_DISPLAY_CTRL, PLANE, DISABLE); CRT_DISPLAY_CTRL, PLANE, DISABLE);
POKE32(CRT_DISPLAY_CTRL, ulDisplayCtrlReg); POKE32(CRT_DISPLAY_CTRL, reg);
ulDisplayCtrlReg = FIELD_SET(ulDisplayCtrlReg, reg = FIELD_SET(reg,
CRT_DISPLAY_CTRL, TIMING, DISABLE); CRT_DISPLAY_CTRL, TIMING, DISABLE);
POKE32(CRT_DISPLAY_CTRL, ulDisplayCtrlReg); POKE32(CRT_DISPLAY_CTRL, reg);
} }
} }
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment