[Armadeus-commitlog] armadeus branch, master, updated. release-3.2-69-geb136b9
Brought to you by:
sszy
|
From: Julien B a. A. <ar...@us...> - 2009-12-20 17:11:52
|
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "armadeus".
The branch, master has been updated
via eb136b98483dbc452f997a12f393aec2e35aaad0 (commit)
via d7c160b38937bc010dc5141e6d83c3671e4babc8 (commit)
via b4fe72c9aeb7dbd1f8b25c0015c508b5556b7b32 (commit)
from cfe393fb8913d5ab2c93326cabff9c3f34994abc (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit eb136b98483dbc452f997a12f393aec2e35aaad0
Author: Julien Boibessot <jul...@ar...>
Date: Sun Dec 20 18:09:50 2009 +0100
[BUILD] improve target/linux/.gitignore
commit d7c160b38937bc010dc5141e6d83c3671e4babc8
Author: Julien Boibessot <jul...@ar...>
Date: Sun Dec 20 18:08:29 2009 +0100
[LINUX] Makes MAX9768 driver more verbose when errors occur
commit b4fe72c9aeb7dbd1f8b25c0015c508b5556b7b32
Author: Julien Boibessot <jul...@ar...>
Date: Sun Dec 20 12:35:58 2009 +0100
[LINUX] apf9328: update default config with new LCDs
-----------------------------------------------------------------------
Summary of changes:
.../armadeus/apf9328/apf9328-linux-2.6.29.config | 15 ++++--
target/linux/.gitignore | 1 +
target/linux/modules/Makefile.in | 1 +
target/linux/modules/max9768/max9768.c | 44 ++++++++++++-------
target/linux/modules/max9768/max9768.h | 4 +-
5 files changed, 42 insertions(+), 23 deletions(-)
diff --git a/buildroot/target/device/armadeus/apf9328/apf9328-linux-2.6.29.config b/buildroot/target/device/armadeus/apf9328/apf9328-linux-2.6.29.config
index ae18428..58967f6 100644
--- a/buildroot/target/device/armadeus/apf9328/apf9328-linux-2.6.29.config
+++ b/buildroot/target/device/armadeus/apf9328/apf9328-linux-2.6.29.config
@@ -1,7 +1,7 @@
#
# Automatically generated make config: don't edit
# Linux kernel version: 2.6.29.6
-# Thu Dec 3 21:58:38 2009
+# Sun Dec 20 12:29:08 2009
#
CONFIG_ARM=y
CONFIG_SYS_SUPPORTS_APM_EMULATION=y
@@ -895,12 +895,15 @@ CONFIG_FB_MODE_HELPERS=y
# Frame buffer hardware drivers
#
CONFIG_FB_IMX=y
-CONFIG_FB_IMX_SHARP_LQ043_TFT=y
+# CONFIG_FB_IMX_CHIMEI_LW700AT9003_TFT is not set
+# CONFIG_FB_IMX_HITACHI_TX12D17VM1BDP_TFT is not set
# CONFIG_FB_IMX_MICROTIPS_MTF_T035_TFT is not set
-# CONFIG_FB_IMX_SHARP_LQ057_TFT is not set
-# CONFIG_FB_IMX_OPTREX_F51900_CSTN is not set
# CONFIG_FB_IMX_MOTOROLA_A910_TFT is not set
-# CONFIG_FB_IMX_CHIMEI_LW700AT9003_TFT is not set
+# CONFIG_FB_IMX_OPTREX_F51900_CSTN is not set
+# CONFIG_FB_IMX_OPTREX_T51638D084_TFT is not set
+CONFIG_FB_IMX_SHARP_LQ043_TFT=y
+# CONFIG_FB_IMX_SHARP_LQ057_TFT is not set
+# CONFIG_FB_IMX_CUSTOM_LCD is not set
# CONFIG_FB_S1D13XXX is not set
# CONFIG_FB_VIRTUAL is not set
# CONFIG_FB_METRONOME is not set
@@ -909,8 +912,10 @@ CONFIG_BACKLIGHT_LCD_SUPPORT=y
CONFIG_LCD_CLASS_DEVICE=m
# CONFIG_LCD_LTV350QV is not set
# CONFIG_LCD_ILI9320 is not set
+# CONFIG_LCD_HX5116 is not set
# CONFIG_LCD_TDO24M is not set
# CONFIG_LCD_VGG2432A4 is not set
+# CONFIG_LCD_P0340WQL is not set
# CONFIG_LCD_PLATFORM is not set
CONFIG_BACKLIGHT_CLASS_DEVICE=m
CONFIG_BACKLIGHT_GENERIC=m
diff --git a/target/linux/.gitignore b/target/linux/.gitignore
index b76bac3..5b9e868 100644
--- a/target/linux/.gitignore
+++ b/target/linux/.gitignore
@@ -8,3 +8,4 @@
*~
.tmp_versions
Module.symvers
+Module.markers
diff --git a/target/linux/modules/Makefile.in b/target/linux/modules/Makefile.in
index 00fea76..550db8f 100755
--- a/target/linux/modules/Makefile.in
+++ b/target/linux/modules/Makefile.in
@@ -10,4 +10,5 @@ clean:
$(MAKE) -C $(KDIR) SUBDIRS=$(PWD) clean
rm -f modules.order
rm -rf .tmp_versions/
+ rm -f Module.markers
diff --git a/target/linux/modules/max9768/max9768.c b/target/linux/modules/max9768/max9768.c
index 2bc3160..1ec1f54 100644
--- a/target/linux/modules/max9768/max9768.c
+++ b/target/linux/modules/max9768/max9768.c
@@ -1,5 +1,5 @@
/*
- * Max9768 audio amplifier driver
+ * MAX9768 audio amplifier driver
*
* Copyright (C) 2009 Armadeus Project / Armadeus Systems
* Author: Nicolas Colombain
@@ -63,24 +63,28 @@ static void max9768_mute(struct max9768 *max9768, int mute)
max9768->mute_state = mute;
}
-static void max9768_send( struct i2c_client *client, int value )
+static int max9768_send(struct i2c_client *client, int value)
{
char msg = value & 0xff;
- i2c_master_send(client, &msg, 1);
+ return i2c_master_send(client, &msg, 1);
}
-/* sysfs hook functions */
+/* sysfs hook functions */
static ssize_t max9768_set_volume(struct device *dev,
struct device_attribute *attr, const char *buf, size_t count)
{
struct i2c_client *client = to_i2c_client(dev);
char msg;
+ int err;
msg = (simple_strtol(buf, NULL, 10)) & MAX9768_VOLUME_MASK;
pr_debug("%s: 0x%02x\n", __FUNCTION__, msg);
- max9768_send( client, msg);
+ err = max9768_send(client, msg);
+ if (err) {
+ dev_err(dev, "couldn't set volume\n");
+ }
return count;
}
@@ -122,15 +126,15 @@ static int max9768_create_sys_entries(struct i2c_client *client)
int status = 0;
if ((status = device_create_file(&client->dev, &dev_attr_volume))) {
- printk(KERN_WARNING "Unable to create sysfs attribute for max9768 volume register\n");
+ dev_warn(&client->dev, "Unable to create sysfs attribute for volume register\n");
goto exit;
}
if ((status = device_create_file(&client->dev, &dev_attr_mute))) {
- printk(KERN_WARNING "Unable to create sysfs attribute for max9768 mute register\n");
+ dev_warn(&client->dev, "Unable to create sysfs attribute for mute register\n");
goto exit;
}
if ((status = device_create_file(&client->dev, &dev_attr_shutdown))) {
- printk(KERN_WARNING "Unable to create sysfs attribute for max9768 shutdown register\n");
+ dev_warn(&client->dev, "Unable to create sysfs attribute for shutdown register\n");
goto exit;
}
@@ -169,7 +173,7 @@ static int max9768_probe(struct i2c_client *client,
i2c_set_clientdata(client, max9768);
dev_set_drvdata(&client->dev, max9768);
- /* Create /sys entries */
+ /* create /sys entries */
result = max9768_create_sys_entries(client);
if (result)
goto out_free;
@@ -177,24 +181,31 @@ static int max9768_probe(struct i2c_client *client,
if (platform_data->init) {
result = platform_data->init();
if (result) {
- printk(KERN_WARNING DRIVER_NAME ": can't reserve gpios\n");
+ dev_err(&client->dev, "can't reserve gpios\n");
goto out_sys;
}
}
max9768->mute_pin = platform_data->mute_pin;
max9768->shdn_pin = platform_data->shdn_pin;
- /* shutdown amplifier and activate mute */
+ /* set filter mode */
+ result = max9768_send(client, platform_data->filter_mode);
+ if (result) {
+ dev_err(&client->dev, "can't communicate with chip\n");
+ goto out_gpio;
+ }
+
+ /* shutdown amplifier and activate mute */
max9768_shutdown(max9768, 1);
max9768_mute(max9768, 1);
- /* set filter mode */
- max9768_send(client, platform_data->filter_mode);
-
- printk(DRIVER_NAME " v" DRIVER_VERSION " successfully probed !\n");
+ dev_notice(&client->dev, "successfully probed !\n");
return 0;
+out_gpio:
+ if (platform_data->exit)
+ platform_data->exit();
out_sys:
max9768_remove_sys_entries(client);
out_free:
@@ -268,9 +279,10 @@ static int __init max9768_init(void)
{
int ret;
+ printk(DRIVER_NAME " v" DRIVER_VERSION "\n");
ret = i2c_add_driver(&max9768_driver);
if (ret)
- printk(KERN_ERR "Unable to register max9768 driver\n");
+ printk(KERN_ERR "unable to register to I2C bus !\n");
return ret;
}
diff --git a/target/linux/modules/max9768/max9768.h b/target/linux/modules/max9768/max9768.h
index a92b1ac..3411f60 100644
--- a/target/linux/modules/max9768/max9768.h
+++ b/target/linux/modules/max9768/max9768.h
@@ -28,8 +28,8 @@
struct max9768_platform_data {
u8 filter_mode;
- int mute_pin; /*gpio for mute ctrl */
- int shdn_pin; /*gpio for shutdown ctrl */
+ int mute_pin; /* gpio for mute ctrl */
+ int shdn_pin; /* gpio for shutdown ctrl */
int (*init)(void);
int (*exit)(void);
};
hooks/post-receive
--
armadeus
|