i2c: Remove legacy CONFIG_SYS_I2C_SOFT
PATCH 1/1 i2c: Remove legacy CONFIG_SYS_I2C_SOFT
The last users of this legacy i2c stack have been removed or converted to a modern part of the stack instead. Remove this code and references to it.
Signed-off-by Tom Rini <[email protected]>
--- README | 92 -------- board/nxp/m53017evb/README | 4 - board/nxp/m5373evb/README | 4 - drivers/i2c/Kconfig | 20 -- drivers/i2c/Makefile | 1 - drivers/i2c/soft_i2c.c | 418 ------------------------------------- 6 files changed, 539 deletions(-)
README +0 -92
@@ -628,98 +628,6 @@ The following options need to be configured: If you do not have i2c muxes on your board, omit this define. -- 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): - - I2C_INIT - - (Optional). Any commands necessary to enable the I2C - controller or configure ports. - - eg: #define I2C_INIT (immr->im_cpm.cp_pbdir |= PB_SCL) - - I2C_ACTIVE - - The code necessary to make the I2C data line active - (driven). If the data line is open collector, this - define can be null. - - eg: #define I2C_ACTIVE (immr->im_cpm.cp_pbdir |= PB_SDA) - - I2C_TRISTATE - - The code necessary to make the I2C data line tri-stated - (inactive). If the data line is open collector, this - define can be null. - - eg: #define I2C_TRISTATE (immr->im_cpm.cp_pbdir &= ~PB_SDA) - - I2C_READ - - Code that returns true if the I2C data line is high, - false if it is low. - - eg: #define I2C_READ ((immr->im_cpm.cp_pbdat & PB_SDA) != 0) - - I2C_SDA(bit) - - If <bit> is true, sets the I2C data line high. If it - is false, it clears it (low). - - eg: #define I2C_SDA(bit) \ - if(bit) immr->im_cpm.cp_pbdat |= PB_SDA; \ - else immr->im_cpm.cp_pbdat &= ~PB_SDA - - I2C_SCL(bit) - - If <bit> is true, sets the I2C clock line high. If it - is false, it clears it (low). - - eg: #define I2C_SCL(bit) \ - if(bit) immr->im_cpm.cp_pbdat |= PB_SCL; \ - else immr->im_cpm.cp_pbdat &= ~PB_SCL - - I2C_DELAY - - This delay is invoked four times per clock cycle so this - controls the rate of data transfer. The data rate thus - is 1 / (I2C_DELAY * 4). Often defined to be something - like: - - #define I2C_DELAY udelay(2) - - CONFIG_SOFT_I2C_GPIO_SCL / CONFIG_SOFT_I2C_GPIO_SDA - - If your arch supports the generic GPIO framework (asm/gpio.h), - then you may alternatively define the two GPIOs that are to be - used as SCL / SDA. Any of the previous I2C_xxx macros will - have GPIO-based defaults assigned to them as appropriate. - - You should define these to the GPIO value as given directly to - the generic GPIO functions. - - CFG_SYS_I2C_NOPROBES - - This option specifies a list of I2C devices that will be skipped - when the 'i2c probe' command is issued. - - e.g. - #define CFG_SYS_I2C_NOPROBES {0x50,0x68} - - will skip addresses 0x50 and 0x68 on a board with one I2C bus - - CONFIG_SOFT_I2C_READ_REPEATED_START - - defining this will force the i2c_read() function in - the soft_i2c driver to perform an I2C repeated start - between writing the address pointer and reading the - data. If this define is omitted the default behaviour - of doing a stop-start sequence will be used. Most I2C - devices can use either method, but some require one or - the other. - - SPI Support: CONFIG_SPI Enables SPI driver (so far only tested with
board/nxp/m53017evb/README +0 -4
@@ -90,10 +90,6 @@ MCFFEC_TOUT_LOOP -- set FEC timeout loop CONFIG_MCFTMR -- define to use DMA timer CONFIG_SYS_I2C_FSL -- define to use FSL common I2C driver -CONFIG_SYS_I2C_SOFT -- define for I2C bit-banged -CONFIG_SYS_I2C_SPEED -- define for I2C speed -CONFIG_SYS_I2C_SLAVE -- define for I2C slave address -CONFIG_SYS_I2C_OFFSET -- define for I2C base address offset CONFIG_SYS_IMMR -- define for MBAR offset CFG_SYS_MBAR -- define MBAR offset
board/nxp/m5373evb/README +0 -4
@@ -89,10 +89,6 @@ MCFFEC_TOUT_LOOP -- set FEC timeout loop CONFIG_MCFTMR -- define to use DMA timer CONFIG_SYS_I2C_FSL -- define to use FSL common I2C driver -CONFIG_SYS_I2C_SOFT -- define for I2C bit-banged -CONFIG_SYS_I2C_SPEED -- define for I2C speed -CONFIG_SYS_I2C_SLAVE -- define for I2C slave address -CONFIG_SYS_I2C_OFFSET -- define for I2C base address offset CONFIG_SYS_IMMR -- define for MBAR offset CFG_SYS_MBAR -- define MBAR offset
drivers/i2c/Kconfig +0 -20
@@ -624,26 +624,6 @@ config SH_I2C_CLOCK default 104000000 endif -config SYS_I2C_SOFT - bool "Legacy software I2C interface" - depends on !COMPILE_TEST - help - Enable the legacy software defined I2C interface - -config SYS_I2C_SOFT_SPEED - int "Software I2C bus speed" - depends on SYS_I2C_SOFT - default 100000 - help - Speed of the software I2C bus - -config SYS_I2C_SOFT_SLAVE - hex "Software I2C slave address" - depends on SYS_I2C_SOFT - default 0xfe - help - Slave address of the software I2C bus - config SYS_I2C_OCTEON bool "Octeon II/III/TX/TX2 I2C driver" depends on (ARCH_OCTEON || ARCH_OCTEONTX || ARCH_OCTEONTX2) && DM_I2C
drivers/i2c/Makefile +0 -1
@@ -47,7 +47,6 @@ obj-$(CONFIG_SYS_I2C_RZ_RIIC) += rz_riic.o obj-$(CONFIG_SYS_I2C_S3C24X0) += s3c24x0_i2c.o exynos_hs_i2c.o obj-$(CONFIG_SYS_I2C_SANDBOX) += sandbox_i2c.o i2c-emul-uclass.o obj-$(CONFIG_SYS_I2C_SH) += sh_i2c.o -obj-$(CONFIG_SYS_I2C_SOFT) += soft_i2c.o obj-$(CONFIG_SYS_I2C_STM32F7) += stm32f7_i2c.o obj-$(CONFIG_SYS_I2C_SUN6I_P2WI) += sun6i_p2wi.o obj-$(CONFIG_SYS_I2C_SUN8I_RSB) += sun8i_rsb.o
drivers/i2c/soft_i2c.c +0 -418
418 lines not on this page · raw message
Signature · 1 line
2.43.0
Hello Tom,
Quoted 5 lines · Tom Rini
The last users of this legacy i2c stack have been removed or converted to a modern part of the stack instead. Remove this code and references to it.
Signed-off-by Tom Rini <[email protected]>
Quoted 8 lines
--- README | 92 -------- board/nxp/m53017evb/README | 4 - board/nxp/m5373evb/README | 4 - drivers/i2c/Kconfig | 20 -- drivers/i2c/Makefile | 1 - drivers/i2c/soft_i2c.c | 418 ------------------------------------- 6 files changed, 539 deletions(-)
Thanks!
Reviewed-by Heiko Schocher <[email protected]>
bye,
Heiko
Signature · 5 lines
Nabla Software Engineering HRB 40522 Augsburg Phone: +49 821 45592596 E-Mail: [email protected] Geschäftsführer : Stefano Babic
Hello Tom,
Quoted 5 lines · Tom Rini
The last users of this legacy i2c stack have been removed or converted to a modern part of the stack instead. Remove this code and references to it.
Signed-off-by Tom Rini <[email protected]>
Quoted 8 lines
--- README | 92 -------- board/nxp/m53017evb/README | 4 - board/nxp/m5373evb/README | 4 - drivers/i2c/Kconfig | 20 -- drivers/i2c/Makefile | 1 - drivers/i2c/soft_i2c.c | 418 ------------------------------------- 6 files changed, 539 deletions(-)
Applied to u-boot-i2c
Thanks!
bye,
Heiko
Signature · 5 lines
Nabla Software Engineering HRB 40522 Augsburg Phone: +49 821 45592596 E-Mail: [email protected] Geschäftsführer : Stefano Babic