From mboxrd@z Thu Jan 1 00:00:00 1970 From: Stefan Roese Date: Fri, 24 Oct 2014 07:57:19 +0200 Subject: [U-Boot] [PATCH] i2c: designware: Convert driver to multibus/multiadapter framework In-Reply-To: <1414085138.3741.20.camel@abrodkin-8560l.internal.synopsys.com> References: <1414062378-30776-1-git-send-email-sr@denx.de> <1414085138.3741.20.camel@abrodkin-8560l.internal.synopsys.com> Message-ID: <5449EA3F.4080900@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 Hi Alexey, On 23.10.2014 19:25, Alexey Brodkin wrote: > On Thu, 2014-10-23 at 13:06 +0200, Stefan Roese wrote: >> In preparation for the SoCFPGA support of the designware I2C driver, >> convert this driver to the common CONFIG_SYS_I2C framework. >> >> This patch converts all users of this driver, this is: >> >> - ST spearxxx boards >> - AXS101 (ARC700 platform) >> >> I couldn't test this patch on those boards. Only compile tested for all >> spear boards. And tested on SoCFPGA. >> >> Signed-off-by: Stefan Roese >> Cc: Heiko Schocher >> Cc: Marek Vasut >> Cc: Vipin Kumar >> Cc: Alexey Brodkin >> --- >> arch/arm/cpu/arm926ejs/spear/cpu.c | 2 +- >> drivers/i2c/Makefile | 2 +- >> drivers/i2c/designware_i2c.c | 294 ++++++++++++++++--------------------- >> include/configs/axs101.h | 9 +- >> include/configs/spear-common.h | 4 +- >> include/configs/x600.h | 4 +- >> 6 files changed, 142 insertions(+), 173 deletions(-) > >> -static struct i2c_regs *i2c_regs_p = >> - (struct i2c_regs *)CONFIG_SYS_I2C_BASE; >> + default: >> + printf("wrong hwadapnr: %d\n", adap->hwadapnr); >> + } > > Well, I'd say "wrong hwadapnr" is not very informative. > Maybe something more human-friendly? Yes, now that you mention it, this really is ugly. Copy-n-pasted from some other driver. I'll change it in the next version. Thanks, Stefan