lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20070306230215.0fab528b.akpm@linux-foundation.org>
Date:	Tue, 6 Mar 2007 23:02:15 -0800
From:	Andrew Morton <akpm@...ux-foundation.org>
To:	bryan.wu@...log.com
Cc:	Alexey Dobriyan <adobriyan@...il.com>,
	Sonic Zhang <sonic.adi@...il.com>,
	Mike Frysinger <vapier.adi@...il.com>, khali@...ux-fr.org,
	linux-kernel@...r.kernel.org, mhfan@...c.edu,
	Roman Zippel <zippel@...ux-m68k.org>
Subject: Re: [PATCH -mm] Blackfin: blackfin i2c driver

On Wed, 07 Mar 2007 13:57:58 +0800 "Wu, Bryan" <bryan.wu@...log.com> wrote:

> Here is the updated blackfin i2c driver.
> 
> [PATCH] Blackfin: blackfin i2c driver
> 
> The i2c linux driver for blackfin architecture which supports both GPIO
> i2c operation and blackfin on-chip TWI controller i2c operation.
> 
> Signed-off-by: Bryan Wu <bryan.wu@...log.com> 
> ---
>  drivers/i2c/busses/Kconfig         |   47 ++++
>  drivers/i2c/busses/i2c-bfin-gpio.c |   98 +++++++++
>  drivers/i2c/busses/i2c-bfin-twi.c  |  589 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++
>  3 files changed, 734 insertions(+)
> 
> Index: linux-2.6/drivers/i2c/busses/Kconfig
> ===================================================================
> --- linux-2.6.orig/drivers/i2c/busses/Kconfig	2007-03-07 13:32:02.000000000 +0800
> +++ linux-2.6/drivers/i2c/busses/Kconfig	2007-03-07 13:44:19.000000000 +0800
> @@ -5,6 +5,53 @@
>  menu "I2C Hardware Bus support"
>  	depends on I2C
>  
> +config I2C_BFIN_GPIO
> +	tristate "Generic Blackfin and HHBF533/561 development board I2C support"
> +	depends on I2C && EXPERIMENTAL
> +	select I2C_ALGOBIT
> +	help
> +	--
> +
> +menu "BFIN I2C SDA/SCL Selection"
> +	depends on I2C_BFIN_GPIO
> +config BFIN_SDA
> +	int "SDA is GPIO Number"
> +	range 0 15 if (BF533 || BF532 || BF531) 
> +	range 0 47 if (BF534 || BF536 || BF537)
> +	range 0 47 if BF561
> +	default 2 if (BF533 || BF532 || BF531) 
> +
> +config BFIN_SCL
> +	int "SCL is GPIO Number"
> +	range 0 15 if (BF533 || BF532 || BF531) 
> +	range 0 47 if (BF534 || BF536 || BF537)
> +	range 0 47 if BF561
> +	default 3 
> +endmenu
> +
> +config I2C_BFIN_GPIO_CYCLE_DELAY
> +	int "Cycle Delay in usec"
> +	depends on I2C_BFIN_GPIO
> +	range 1 100 
> +	default 40
> +
> +config I2C_BFIN_TWI
> +	tristate "Blackfin TWI I2C support"
> +	depends on I2C && (BF534 || BF536 || BF537)
> +	help
> +	  This the TWI I2C device driver for Blackfin 534/536/537.
> +
> +	  This driver can also be built as a module.  If so, the module
> +	  will be called i2c-bfin-twi.
> +
> +config TWICLK_KHZ
> +	int "TWI clock (kHZ)"
> +	depends on I2C_BFIN_TWI
> +	default 50
> +	help
> +	  The unit of the TWI clock is kilo HZ. Please divide the clock 
> +	  by 1024 if you count it in HZ. The value should be less than 400.
> +

Well that's cute.  This patch causes an i386 `make allmodconfig' to spew
these:

    SDA is GPIO Number (BFIN_SDA) [] (NEW) 
    SDA is GPIO Number (BFIN_SDA) [] (NEW) 
    SDA is GPIO Number (BFIN_SDA) [] (NEW) 
    SDA is GPIO Number (BFIN_SDA) [] (NEW) 
    SDA is GPIO Number (BFIN_SDA) [] (NEW) 
    SDA is GPIO Number (BFIN_SDA) [] (NEW) 
    SDA is GPIO Number (BFIN_SDA) [] (NEW) 
    SDA is GPIO Number (BFIN_SDA) [] (NEW) 
    SDA is GPIO Number (BFIN_SDA) [] (NEW) 
    SDA is GPIO Number (BFIN_SDA) [] (NEW) 
    SDA is GPIO Number (BFIN_SDA) [] (NEW) 
    SDA is GPIO Number (BFIN_SDA) [] (NEW) 
    SDA is GPIO Number (BFIN_SDA) [] (NEW) 
    SDA is GPIO Number (BFIN_SDA) [] (NEW) 
    SDA is GPIO Number (BFIN_SDA) [] (NEW) 
    SDA is GPIO Number (BFIN_SDA) [] (NEW) 
    SDA is GPIO Number (BFIN_SDA) [] (NEW) 
    SDA is GPIO Number (BFIN_SDA) [] (NEW) 
    SDA is GPIO Number (BFIN_SDA) [] (NEW) 
    SDA is GPIO Number (BFIN_SDA) [] (NEW) 
    SDA is GPIO Number (BFIN_SDA) [] (NEW) 
    SDA is GPIO Number (BFIN_SDA) [] (NEW) 
    SDA is GPIO Number (BFIN_SDA) [] (NEW) 
    SDA is GPIO Number (BFIN_SDA) [] (NEW) 
    SDA is GPIO Number (BFIN_SDA) [] (NEW) 
    SDA is GPIO Number (BFIN_SDA) [] (NEW) 
    SDA is GPIO Number (BFIN_SDA) [] (NEW) 

out at about 1,000,000/sec, infinitely.

I'll put a `depends on BFIN' in there to shut it up, but I think you've
tickled a Kconfig bug.

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ