From: wdenk Date: Mon, 1 Apr 2002 17:47:25 +0000 (+0000) Subject: Das U-Boot: Universal Boot Loader X-Git-Tag: U_BOOT_0_1_0~171 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=f4721931785f2232c2a139aeda61ae7c1c164dcb;p=u-boot Das U-Boot: Universal Boot Loader --- diff --git a/cpu/mpc824x/drivers/i2c/i2c2.S b/cpu/mpc824x/drivers/i2c/i2c2.S new file mode 100644 index 0000000000..5cc7c98764 --- /dev/null +++ b/cpu/mpc824x/drivers/i2c/i2c2.S @@ -0,0 +1,54 @@ +/************************************** + * + * copyright @ Motorola, 1999 + * + **************************************/ + +#include +#ifdef CONFIG_HARD_I2C +#include +#include +/********************************************************** + * function: load_runtime_reg + * + * input: r3 - value of eumbbar + * r4 - register offset in embedded utility space + * + * output: r3 - register content + **********************************************************/ + .text + .align 2 + .global load_runtime_reg +load_runtime_reg: + +/* xor r5,r5,r5 +* or r5,r5,r3 +* +* lwbrx r3,r4,r5 +*/ + lwbrx r3,r4,r3 + sync + + bclr 20, 0 + +/**************************************************************** + * function: store_runtime_reg + * + * input: r3 - value of eumbbar + * r4 - register offset in embedded utility space + * r5 - new value to be stored + * + ****************************************************************/ + .text + .align 2 + .global store_runtime_reg +store_runtime_reg: + + stwbrx r5, r4, r3 + sync + + bclr 20,0 + + + +#endif /* CONFIG_HARD_I2C */