From eb5ba3aefdf0f6cbd61684eeb61428f11fa7613c Mon Sep 17 00:00:00 2001 From: Simon Glass Date: Fri, 12 May 2017 21:09:49 -0600 Subject: i2c: Drop use of CONFIG_I2C_HARD This option is pretty old. It predates CONFIG_SYS_I2C which is itself deprecated in favour of driver model. Disable it for all boards. Also drop I2C options which depend on this. Signed-off-by: Simon Glass --- README | 17 ++--------------- 1 file changed, 2 insertions(+), 15 deletions(-) (limited to 'README') diff --git a/README b/README index 2ca0102b57b..86f0814f792 100644 --- a/README +++ b/README @@ -2213,22 +2213,9 @@ The following options need to be configured: - approved multibus support - better i2c mux support - ** Please consider updating your I2C driver now. ** + ** CONFIG_HARD_I2C is now being removed ** - These enable legacy I2C serial bus commands. Defining - CONFIG_HARD_I2C will include the appropriate I2C driver - for the selected CPU. - - This will allow you to use i2c commands at the u-boot - command line (as long as you set CONFIG_CMD_I2C in - CONFIG_COMMANDS) and communicate with i2c based realtime - clock chips. See common/cmd_i2c.c for a description of the - command line interface. - - CONFIG_HARD_I2C selects a hardware I2C controller. - - There are several other quantities that must also be - defined when you define CONFIG_HARD_I2C. +----under removal: In both cases you will need to define CONFIG_SYS_I2C_SPEED to be the frequency (in Hz) at which you wish your i2c bus -- cgit v1.2.3 From 69153988a6f4eda44257c6bc5afac484f8f95930 Mon Sep 17 00:00:00 2001 From: Simon Glass Date: Fri, 12 May 2017 21:09:56 -0600 Subject: i2c: Finish dropping use of CONFIG_I2C_HARD Drop use of this long-deprecated option. Signed-off-by: Simon Glass Reviewed-by: Tom Rini --- README | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) (limited to 'README') diff --git a/README b/README index 86f0814f792..11fa84ccc45 100644 --- a/README +++ b/README @@ -2204,7 +2204,9 @@ The following options need to be configured: If you do not have i2c muxes on your board, omit this define. -- Legacy I2C Support: CONFIG_HARD_I2C +----under removal: + +- Legacy I2C Support: CONFIG_SOFT_I2C NOTE: It is intended to move drivers to CONFIG_SYS_I2C which provides the following compelling advantages: @@ -2213,14 +2215,12 @@ The following options need to be configured: - approved multibus support - better i2c mux support - ** CONFIG_HARD_I2C is now being removed ** - -----under removal: + ** CONFIG_SOFT_I2C is now being removed ** - In both cases you will need to define CONFIG_SYS_I2C_SPEED - to be the frequency (in Hz) at which you wish your i2c bus - to run and CONFIG_SYS_I2C_SLAVE to be the address of this node (ie - the CPU's i2c node address). + With CONFIG_SOFT_I2C you will need to define + CONFIG_SYS_I2C_SPEED to be the frequency (in Hz) at which you + wish your i2c bus to run and CONFIG_SYS_I2C_SLAVE to be the + address of this node (ie the CPU's i2c node address). Now, the u-boot i2c code for the mpc8xx (arch/powerpc/cpu/mpc8xx/i2c.c) sets the CPU up as a master node -- cgit v1.2.3 From b238c9dce5e487092531fb6e61c4d9f334f86686 Mon Sep 17 00:00:00 2001 From: Simon Glass Date: Fri, 12 May 2017 21:09:57 -0600 Subject: i2c: README: Drop CONFIG_SYS_I2C_INIT_MPC5XXX This option is not used in U-Boot. Drop it. Signed-off-by: Simon Glass --- README | 2 -- 1 file changed, 2 deletions(-) (limited to 'README') diff --git a/README b/README index 11fa84ccc45..9f9265dc6d7 100644 --- a/README +++ b/README @@ -2228,8 +2228,6 @@ The following options need to be configured: eg, MPC823e User's Manual p.16-473). So, set CONFIG_SYS_I2C_SLAVE to 0. - CONFIG_SYS_I2C_INIT_MPC5XXX - When a board is reset during an i2c bus transfer chips might think that the current transfer is still in progress. Reset the slave devices by sending start -- cgit v1.2.3 From b0103f33b45286eef53239d3c80e21d7eafd9cb4 Mon Sep 17 00:00:00 2001 From: Simon Glass Date: Fri, 12 May 2017 21:09:58 -0600 Subject: i2c: Drop CONFIG_SYS_I2C_BOARD_LATE_INIT This option is not used by any boards. Drop it. Signed-off-by: Simon Glass --- README | 11 ----------- 1 file changed, 11 deletions(-) (limited to 'README') diff --git a/README b/README index 9f9265dc6d7..96ce6289ea9 100644 --- a/README +++ b/README @@ -2323,17 +2323,6 @@ The following options need to be configured: custom i2c_init_board() routine in boards/xxx/board.c is run early in the boot sequence. - CONFIG_SYS_I2C_BOARD_LATE_INIT - - An alternative to CONFIG_SYS_I2C_INIT_BOARD. If this option is - defined a custom i2c_board_late_init() routine in - boards/xxx/board.c is run AFTER the operations in i2c_init() - is completed. This callpoint can be used to unreset i2c bus - using CPU i2c controller register accesses for CPUs whose i2c - controller provide such a method. It is called at the end of - i2c_init() to allow i2c_init operations to setup the i2c bus - controller on the CPU (e.g. setting bus speed & slave address). - CONFIG_I2CFAST (PPC405GP|PPC405EP only) This option enables configuration of bi_iic_fast[] flags -- cgit v1.2.3 From 213f27f3f9c89dbf32e38cb031b303193e6e8627 Mon Sep 17 00:00:00 2001 From: Simon Glass Date: Fri, 12 May 2017 21:09:59 -0600 Subject: Drop CONFIG_I2CFAST This option is not used in U-Boot. Drop it. Signed-off-by: Simon Glass --- README | 6 ------ 1 file changed, 6 deletions(-) (limited to 'README') diff --git a/README b/README index 96ce6289ea9..71d8de0ba8f 100644 --- a/README +++ b/README @@ -2323,12 +2323,6 @@ The following options need to be configured: custom i2c_init_board() routine in boards/xxx/board.c is run early in the boot sequence. - CONFIG_I2CFAST (PPC405GP|PPC405EP only) - - This option enables configuration of bi_iic_fast[] flags - in u-boot bd_info structure based on u-boot environment - variable "i2cfast". (see also i2cfast) - CONFIG_I2C_MULTI_BUS This option allows the use of multiple I2C buses, each of which -- cgit v1.2.3 From ce3b5d69112b1adc878e06586c1bc819414309be Mon Sep 17 00:00:00 2001 From: Simon Glass Date: Fri, 12 May 2017 21:10:00 -0600 Subject: Drop use of CONFIG_I2C_SOFT This option is not used in U-Boot. Drop it. Signed-off-by: Simon Glass --- README | 32 +------------------------------- 1 file changed, 1 insertion(+), 31 deletions(-) (limited to 'README') diff --git a/README b/README index 71d8de0ba8f..95251995519 100644 --- a/README +++ b/README @@ -2204,37 +2204,7 @@ The following options need to be configured: If you do not have i2c muxes on your board, omit this define. -----under removal: - -- Legacy I2C Support: CONFIG_SOFT_I2C - - NOTE: It is intended to move drivers to CONFIG_SYS_I2C which - provides the following compelling advantages: - - - more than one i2c adapter is usable - - approved multibus support - - better i2c mux support - - ** CONFIG_SOFT_I2C is now being removed ** - - With CONFIG_SOFT_I2C you will need to define - CONFIG_SYS_I2C_SPEED to be the frequency (in Hz) at which you - wish your i2c bus to run and CONFIG_SYS_I2C_SLAVE to be the - address of this node (ie the CPU's i2c node address). - - Now, the u-boot i2c code for the mpc8xx - (arch/powerpc/cpu/mpc8xx/i2c.c) sets the CPU up as a master node - and so its address should therefore be cleared to 0 (See, - eg, MPC823e User's Manual p.16-473). So, set - CONFIG_SYS_I2C_SLAVE to 0. - - When a board is reset during an i2c bus transfer - chips might think that the current transfer is still - in progress. Reset the slave devices by sending start - commands until the slave device responds. - - That's all that's required for CONFIG_HARD_I2C. - +- Legacy I2C Support: If you use the software i2c interface (CONFIG_SYS_I2C_SOFT) then the following macros need to be defined (examples are from include/configs/lwmon.h): -- cgit v1.2.3