Re: [U-Boot] [PATCH v2 4/7] board: dlvision-10g: Compile fix

2014-11-18 Thread Stefan Roese

On 13.11.2014 19:21, dirk.eib...@gdsys.cc wrote:

From: Dirk Eibach dirk.eib...@gdsys.cc

Signed-off-by: Dirk Eibach dirk.eib...@gdsys.cc


Applied to u-boot-ppc4xx/master.

Thanks,
Stefan

___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


[U-Boot] [PATCH v2 4/7] board: dlvision-10g: Compile fix

2014-11-13 Thread dirk . eibach
From: Dirk Eibach dirk.eib...@gdsys.cc

Signed-off-by: Dirk Eibach dirk.eib...@gdsys.cc
---

Changes in v2:
- fix compiler warning

 board/gdsys/common/osd.c | 7 +++
 1 file changed, 3 insertions(+), 4 deletions(-)

diff --git a/board/gdsys/common/osd.c b/board/gdsys/common/osd.c
index 1c765e4..55ecdf1 100644
--- a/board/gdsys/common/osd.c
+++ b/board/gdsys/common/osd.c
@@ -289,7 +289,6 @@ int osd_probe(unsigned screen)
 {
u16 version;
u16 features;
-   u8 value;
int old_bus = i2c_get_bus_num();
bool pixclock_present = false;
bool output_driver_present = false;
@@ -330,7 +329,8 @@ int osd_probe(unsigned screen)
 #ifdef CONFIG_SYS_CH7301_I2C
i2c_set_bus_num(ch7301_i2c[screen]);
if (!i2c_probe(CH7301_I2C_ADDR)) {
-   value = i2c_reg_read(CH7301_I2C_ADDR, CH7301_DID);
+   u8 value = i2c_reg_read(CH7301_I2C_ADDR, CH7301_DID);
+
if (value == 0x17) {
i2c_reg_write(CH7301_I2C_ADDR, CH7301_TPCP, 0x08);
i2c_reg_write(CH7301_I2C_ADDR, CH7301_TPD, 0x16);
@@ -345,8 +345,7 @@ int osd_probe(unsigned screen)
 #ifdef CONFIG_SYS_SIL1178_I2C
i2c_set_bus_num(sil1178_i2c[screen]);
if (!i2c_probe(SIL1178_SLAVE_I2C_ADDRESS)) {
-   value = i2c_reg_read(SIL1178_SLAVE_I2C_ADDRESS, 0x02);
-   if (value == 0x06) {
+   if (i2c_reg_read(SIL1178_SLAVE_I2C_ADDRESS, 0x02) == 0x06) {
/*
 * magic initialization sequence,
 * adapted from datasheet
-- 
1.8.3

___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot