From mboxrd@z Thu Jan 1 00:00:00 1970 From: Heiko Schocher Date: Tue, 24 Sep 2013 08:33:55 +0200 Subject: [U-Boot] [RFC] i2c_reloc_fixup fails on m68k In-Reply-To: <5240473A.2040208@bus-elektronik.de> References: <5240473A.2040208@bus-elektronik.de> Message-ID: <52413253.4020603@denx.de> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Hello Jens, Am 23.09.2013 15:50, schrieb Jens Scharsig: > Hello, > > I have a access violation problem with i2c_reloc_fixup on coldfire > m68k systems. > > I found out, the i2c_reloc_fixup tries to relocate the adapter itself, > but at this time i2c_adap_p is already relocated. Which toolchain? > Can anybody confirm this? Added Mike Frysinger, Sonic Zhang (for blackfin) Jason Jin (for m68k) and Macpaul Lin (for nds32) to Cc ... > I think also m68k, backfin and nds32 systems are affected Sorry, I have no such system ... maybe you are the first who stepped in it ... > --- > diff --git a/drivers/i2c/i2c_core.c b/drivers/i2c/i2c_core.c > index d1072e8..bb5d4db 100644 > --- a/drivers/i2c/i2c_core.c > +++ b/drivers/i2c/i2c_core.c > @@ -53,10 +53,6 @@ void i2c_reloc_fixup(void) > return; > > for (i = 0; i< max; i++) { > - /* adapter itself */ > - addr = (unsigned long)i2c_adap_p; > - addr += gd->reloc_off; > - i2c_adap_p = (struct i2c_adapter *)addr; > /* i2c_init() */ > addr = (unsigned long)i2c_adap_p->init; > addr += gd->reloc_off; bye, Heiko -- DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany