[U-Boot-Users] [PATCH] Add support for setting the I2C bus speed in fsl_i2c.c

Liew Tsi Chung
2008-03-27T17:30:34Z

547x/548x are not the only ColdFire affected, 5235, 5373, 5275, 5329,
54455, 52277, and 5271 are required to update as well.

-----Original Message-----
From: Tabi Timur
Sent: Thursday, March 27, 2008 9:46 AM
To: Luigi 'Comio' Mantellini
Cc: U-boot-Users; Liew Tsi Chung
Subject: Re: [U-Boot-Users] [PATCH] Add support for setting the I2C bus
speed in fsl_i2c.c

Luigi 'Comio' Mantellini wrote:
> This patch should resolve the compilation issues on 547x/548x cpus.

Sorry, I didn't even think to check for anything outside of PowerPC. I
had no idea m68k used fsl_i2c.c.

> @@ -47,6 +47,9 @@ typedef struct global_data {
> unsigned long vco_clk;
> unsigned long flb_clk;
> #endif
> +#ifdef CONFIG_MCF547x_8x
> + u32 i2c1_clk;
> +#endif
> unsigned long ram_size; /* RAM size */
> unsigned long reloc_off; /* Relocation Offset */
> unsigned long reset_status; /* reset status register at boot
*/

I suggest that you get rid of the #ifdef and always define i2c1_clk.
The value will be set to 0 on systems that don't have an I2C. I'm
planning on submitting patches to asm-ppc/global_data.h to get rid of a
bunch of #ifdefs because it's getting too messy.

Either way, I ACK this patch.

--
Timur Tabi
Linux kernel developer at Freescale