diff mbox series

[U-Boot,v3,3/6] am335x-fb: cosmetic: fix coding style

Message ID 1515520896-18833-4-git-send-email-oe5hpm@oevsv.at
State Accepted
Delegated to: Anatolij Gustschin
Headers show
Series am335x-fb: support display PLL for lcd-clock / pixel-clock | expand

Commit Message

Hannes Schmelzer Jan. 9, 2018, 6:01 p.m. UTC
Signed-off-by: Hannes Schmelzer <oe5hpm@oevsv.at>
---

Changes in v3: None
Changes in v2:
- am335x-fb: avoid compiler warning

 drivers/video/am335x-fb.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

Comments

Anatolij Gustschin Jan. 10, 2018, 1:05 p.m. UTC | #1
On Tue,  9 Jan 2018 19:01:33 +0100
Hannes Schmelzer oe5hpm@oevsv.at wrote:

> Signed-off-by: Hannes Schmelzer <oe5hpm@oevsv.at>

Reviewed-by: Anatolij Gustschin <agust@denx.de>
diff mbox series

Patch

diff --git a/drivers/video/am335x-fb.c b/drivers/video/am335x-fb.c
index c8100d8..697b701 100644
--- a/drivers/video/am335x-fb.c
+++ b/drivers/video/am335x-fb.c
@@ -108,11 +108,11 @@  int am335xfb_init(struct am335x_lcdpanel *panel)
 {
 	u32 raster_ctrl = 0;
 
-	if (0 == gd->fb_base) {
+	if (gd->fb_base == 0) {
 		printf("ERROR: no valid fb_base stored in GLOBAL_DATA_PTR!\n");
 		return -1;
 	}
-	if (0 == panel) {
+	if (panel == NULL) {
 		printf("ERROR: missing ptr to am335x_lcdpanel!\n");
 		return -1;
 	}
@@ -147,7 +147,7 @@  int am335xfb_init(struct am335x_lcdpanel *panel)
 	gd->fb_base += 0x20;
 
 	/* turn ON display through powercontrol function if accessible */
-	if (0 != panel->panel_power_ctrl)
+	if (panel->panel_power_ctrl != NULL)
 		panel->panel_power_ctrl(1);
 
 	debug("am335x-fb: wait for stable power ...\n");