# \[PATCH\] radeonfb: Give i2c buses nicer names

- Status: REVIEWED · 1 review, 1 by a maintainer (M Benjamin Herrenschmidt)
- Reviewed.
- 1 review trailer.
- List: linux-fbdev
- 2 messages, 2 authors
- Page: https://ratatoskr.run/linux-fbdev/2008/06/13458392/t

## \[PATCH\] radeonfb: Give i2c buses nicer names

- From: Jean Delvare \<hidden\>
- Date: 2008-06-17 12:46:39 
- Message: https://ratatoskr.run/linux-fbdev/2008/06/13458392.md

```text
The name of the i2c buses shows in the output of "i2cdetect -l", so
it's important to give informative names.

Signed-off-by: Jean Delvare <redacted>
Acked-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
---
Antonino, can you please push this upstream? Thanks.

 drivers/video/aty/radeon_i2c.c |    3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

--- linux-2.6.26-rc5.orig/drivers/video/aty/radeon_i2c.c	2008-06-03 09:57:31.000000000 +0200
+++ linux-2.6.26-rc5/drivers/video/aty/radeon_i2c.c	2008-06-06 08:43:51.000000000 +0200
@@ -69,7 +69,8 @@ static int radeon_setup_i2c_bus(struct r
 {
 	int rc;
 
-	strcpy(chan->adapter.name, name);
+	snprintf(chan->adapter.name, sizeof(chan->adapter.name),
+		 "radeonfb %s", name);
 	chan->adapter.owner		= THIS_MODULE;
 	chan->adapter.id		= I2C_HW_B_RADEON;
 	chan->adapter.algo_data		= &chan->algo;


-- 
Jean Delvare

-------------------------------------------------------------------------
Check out the new SourceForge.net Marketplace.
It's the best place to buy or sell services for
just about anything Open Source.
http://sourceforge.net/services/buy/index.php
```

## Re: \[PATCH\] radeonfb: Give i2c buses nicer names

- From: Krzysztof Helt \<hidden\>
- Date: 2008-06-18 18:57:15 
- Message: https://ratatoskr.run/linux-fbdev/2008/06/13458397.md

```text
On Tue, 17 Jun 2008 14:46:15 +0200
Jean Delvare [ref] wrote:

> The name of the i2c buses shows in the output of "i2cdetect -l", so
> it's important to give informative names.
> 
> Signed-off-by: Jean Delvare <redacted>
> Acked-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
> ---
> Antonino, can you please push this upstream? Thanks.
> 
Please send these patches to Andrew Morton.

Regards,
Krzysztof

----------------------------------------------------------------------
Backstage na The Police + bilet na koncert!
kliknij >>> http://link.interia.pl/f1e3d


-------------------------------------------------------------------------
Check out the new SourceForge.net Marketplace.
It's the best place to buy or sell services for
just about anything Open Source.
http://sourceforge.net/services/buy/index.php
```
