lkml.org 
[lkml]   [2010]   [Mar]   [9]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
SubjectRe: [PATCH 58/62] msi-laptop: Support some MSI 3G netbook that is need load SCM
Hi Greg, 

Please kindly review the attached patch for removed the non-standard
interface "threeg" in msi-laptop driver.



Thank's a lot!
Joey Lee

於 五,2010-03-05 於 06:10 +0000,joeyli(Joey Lee) 提到:
> Hi Matthew,
> 於 四,2010-03-04 於 17:09 +0000,Matthew Garrett 提到:
> > On Thu, Mar 04, 2010 at 10:07:53AM -0700, Joey Lee wrote:
> > > Thank's for your review and suggestion.
> > > Per discuss for msi-laptop patchset, I will submit a bit patch for the
> > > following change:
> > > - remove threeg sysfs interface.
> > > - add KEY_RFKILL keymapping to msi-laptop.
> >
> > If the key event comes through the keyboard controller, there's no need
> > to add the mapping to msi-laptop. Doing it through udev or hal is fine.
> >
>
> Thank's fully undertood, now, will send patch for remove threeg sysfs
> interface.
>
>
> Joey Lee

From c9dc06048fcb0b8fadd510ef26b5af7b466aeab6 Mon Sep 17 00:00:00 2001
From: Lee, Chun-Yi <jlee@novell.com>
Date: Tue, 9 Mar 2010 20:25:42 +0800
Subject: [PATCH] Removed non-standard interface "threeg"

There already have standard rfkill wwan interface for 3G device, so, removed
non-standard interface "threeg".

Signed-off-by: Lee, Chun-Yi <jlee@novell.com>
---
drivers/platform/x86/msi-laptop.c | 36 ------------------------------------
1 files changed, 0 insertions(+), 36 deletions(-)
diff --git a/drivers/platform/x86/msi-laptop.c b/drivers/platform/x86/msi-laptop.c
index c2b05da..c891522 100644
--- a/drivers/platform/x86/msi-laptop.c
+++ b/drivers/platform/x86/msi-laptop.c
@@ -311,29 +311,6 @@ static ssize_t store_bluetooth(struct device *dev,
return set_device_state(buf, count, MSI_STANDARD_EC_BLUETOOTH_MASK);
}

-static ssize_t show_threeg(struct device *dev,
- struct device_attribute *attr, char *buf)
-{
-
- int ret;
-
- /* old msi ec not support 3G */
- if (old_ec_model)
- return -1;
-
- ret = get_wireless_state_ec_standard();
- if (ret < 0)
- return ret;
-
- return sprintf(buf, "%i\n", threeg_s);
-}
-
-static ssize_t store_threeg(struct device *dev,
- struct device_attribute *attr, const char *buf, size_t count)
-{
- return set_device_state(buf, count, MSI_STANDARD_EC_3G_MASK);
-}
-
static ssize_t show_lcd_level(struct device *dev,
struct device_attribute *attr, char *buf)
{
@@ -396,7 +373,6 @@ static DEVICE_ATTR(lcd_level, 0644, show_lcd_level, store_lcd_level);
static DEVICE_ATTR(auto_brightness, 0644, show_auto_brightness, store_auto_brightness);
static DEVICE_ATTR(bluetooth, 0444, show_bluetooth, NULL);
static DEVICE_ATTR(wlan, 0444, show_wlan, NULL);
-static DEVICE_ATTR(threeg, 0444, show_threeg, NULL);

static struct attribute *msipf_attributes[] = {
&dev_attr_lcd_level.attr,
@@ -635,10 +611,8 @@ static int load_scm_model_init(struct platform_device *sdev)
/* allow userland write sysfs file */
dev_attr_bluetooth.store = store_bluetooth;
dev_attr_wlan.store = store_wlan;
- dev_attr_threeg.store = store_threeg;
dev_attr_bluetooth.attr.mode |= S_IWUSR;
dev_attr_wlan.attr.mode |= S_IWUSR;
- dev_attr_threeg.attr.mode |= S_IWUSR;

/* disable hardware control by fn key */
result = ec_read(MSI_STANDARD_EC_SCM_LOAD_ADDRESS, &data);
@@ -715,14 +689,6 @@ static int __init msi_init(void)
if (ret)
goto fail_platform_device2;

- if (!old_ec_model) {
- if (threeg_exists)
- ret = device_create_file(&msipf_device->dev,
- &dev_attr_threeg);
- if (ret)
- goto fail_platform_device2;
- }
-
/* Disable automatic brightness control by default because
* this module was probably loaded to do brightness control in
* software. */
@@ -757,8 +723,6 @@ static void __exit msi_cleanup(void)
{

sysfs_remove_group(&msipf_device->dev.kobj, &msipf_attribute_group);
- if (!old_ec_model && threeg_exists)
- device_remove_file(&msipf_device->dev, &dev_attr_threeg);
platform_device_unregister(msipf_device);
platform_driver_unregister(&msipf_driver);
backlight_device_unregister(msibl_device);
--
1.6.0.2
\
 
 \ /
  Last update: 2010-03-09 13:45    [from the cache]
©2003-2011 Jasper Spaans