Skip to content

Commit

Permalink
Drivers: platform: x86: remove __dev* attributes.
Browse files Browse the repository at this point in the history
CONFIG_HOTPLUG is going away as an option.  As a result, the __dev*
markings need to be removed.

This change removes the use of __devinit, __devexit_p, __devinitdata,
__devinitconst, and __devexit from these drivers.

Based on patches originally written by Bill Pemberton, but redone by me
in order to handle some of the coding style issues better, by hand.

Cc: Bill Pemberton <wfp5p@virginia.edu>
Cc: Joey Lee <jlee@novell.com>
Cc: Matthew Garrett <mjg@redhat.com>
Cc: Peter Feuerer <peter@piie.net>
Cc: Corentin Chary <corentin.chary@gmail.com>
Cc: Cezary Jackiewicz <cezary.jackiewicz@gmail.com>
Cc: Robert Gerlach <khnz@gmx.de>
Cc: Ike Panhc <ike.pan@canonical.com>
Cc: Henrique de Moraes Holschuh <ibm-acpi@hmh.eng.br>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
  • Loading branch information
Greg Kroah-Hartman committed Jan 3, 2013
1 parent 4c62e97 commit b859f15
Show file tree
Hide file tree
Showing 20 changed files with 65 additions and 69 deletions.
8 changes: 4 additions & 4 deletions drivers/platform/x86/acer-wmi.c
Original file line number Diff line number Diff line change
Expand Up @@ -335,7 +335,7 @@ static struct quirk_entry quirk_lenovo_ideapad_s205 = {
};

/* The Aspire One has a dummy ACPI-WMI interface - disable it */
static struct dmi_system_id __devinitdata acer_blacklist[] = {
static struct dmi_system_id acer_blacklist[] = {
{
.ident = "Acer Aspire One (SSD)",
.matches = {
Expand Down Expand Up @@ -1330,7 +1330,7 @@ static struct led_classdev mail_led = {
.brightness_set = mail_led_set,
};

static int __devinit acer_led_init(struct device *dev)
static int acer_led_init(struct device *dev)
{
return led_classdev_register(dev, &mail_led);
}
Expand Down Expand Up @@ -1372,7 +1372,7 @@ static const struct backlight_ops acer_bl_ops = {
.update_status = update_bl_status,
};

static int __devinit acer_backlight_init(struct device *dev)
static int acer_backlight_init(struct device *dev)
{
struct backlight_properties props;
struct backlight_device *bd;
Expand Down Expand Up @@ -1961,7 +1961,7 @@ static u32 get_wmid_devices(void)
/*
* Platform device
*/
static int __devinit acer_platform_probe(struct platform_device *device)
static int acer_platform_probe(struct platform_device *device)
{
int err;

Expand Down
2 changes: 1 addition & 1 deletion drivers/platform/x86/acerhdf.c
Original file line number Diff line number Diff line change
Expand Up @@ -515,7 +515,7 @@ static int acerhdf_suspend(struct device *dev)
return 0;
}

static int __devinit acerhdf_probe(struct platform_device *device)
static int acerhdf_probe(struct platform_device *device)
{
return 0;
}
Expand Down
4 changes: 2 additions & 2 deletions drivers/platform/x86/amilo-rfkill.c
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ static const struct rfkill_ops amilo_m7440_rfkill_ops = {
.set_block = amilo_m7440_rfkill_set_block
};

static const struct dmi_system_id __devinitconst amilo_rfkill_id_table[] = {
static const struct dmi_system_id amilo_rfkill_id_table[] = {
{
.matches = {
DMI_MATCH(DMI_SYS_VENDOR, "FUJITSU SIEMENS"),
Expand All @@ -95,7 +95,7 @@ static const struct dmi_system_id __devinitconst amilo_rfkill_id_table[] = {
static struct platform_device *amilo_rfkill_pdev;
static struct rfkill *amilo_rfkill_dev;

static int __devinit amilo_rfkill_probe(struct platform_device *device)
static int amilo_rfkill_probe(struct platform_device *device)
{
int rc;
const struct dmi_system_id *system_id =
Expand Down
7 changes: 3 additions & 4 deletions drivers/platform/x86/apple-gmux.c
Original file line number Diff line number Diff line change
Expand Up @@ -411,8 +411,7 @@ static int gmux_resume(struct pnp_dev *pnp)
return 0;
}

static int __devinit gmux_probe(struct pnp_dev *pnp,
const struct pnp_device_id *id)
static int gmux_probe(struct pnp_dev *pnp, const struct pnp_device_id *id)
{
struct apple_gmux_data *gmux_data;
struct resource *res;
Expand Down Expand Up @@ -577,7 +576,7 @@ static int __devinit gmux_probe(struct pnp_dev *pnp,
return ret;
}

static void __devexit gmux_remove(struct pnp_dev *pnp)
static void gmux_remove(struct pnp_dev *pnp)
{
struct apple_gmux_data *gmux_data = pnp_get_drvdata(pnp);

Expand Down Expand Up @@ -609,7 +608,7 @@ static const struct pnp_device_id gmux_device_ids[] = {
static struct pnp_driver gmux_pnp_driver = {
.name = "apple-gmux",
.probe = gmux_probe,
.remove = __devexit_p(gmux_remove),
.remove = gmux_remove,
.id_table = gmux_device_ids,
.suspend = gmux_suspend,
.resume = gmux_resume
Expand Down
6 changes: 3 additions & 3 deletions drivers/platform/x86/asus-laptop.c
Original file line number Diff line number Diff line change
Expand Up @@ -1763,7 +1763,7 @@ static int asus_laptop_get_info(struct asus_laptop *asus)
return AE_OK;
}

static int __devinit asus_acpi_init(struct asus_laptop *asus)
static int asus_acpi_init(struct asus_laptop *asus)
{
int result = 0;

Expand Down Expand Up @@ -1823,7 +1823,7 @@ static int __devinit asus_acpi_init(struct asus_laptop *asus)
return result;
}

static void __devinit asus_dmi_check(void)
static void asus_dmi_check(void)
{
const char *model;

Expand All @@ -1839,7 +1839,7 @@ static void __devinit asus_dmi_check(void)

static bool asus_device_present;

static int __devinit asus_acpi_add(struct acpi_device *device)
static int asus_acpi_add(struct acpi_device *device)
{
struct asus_laptop *asus;
int result;
Expand Down
10 changes: 5 additions & 5 deletions drivers/platform/x86/compal-laptop.c
Original file line number Diff line number Diff line change
Expand Up @@ -713,15 +713,15 @@ static struct attribute_group compal_attribute_group = {
.attrs = compal_attributes
};

static int __devinit compal_probe(struct platform_device *);
static int __devexit compal_remove(struct platform_device *);
static int compal_probe(struct platform_device *);
static int compal_remove(struct platform_device *);
static struct platform_driver compal_driver = {
.driver = {
.name = DRIVER_NAME,
.owner = THIS_MODULE,
},
.probe = compal_probe,
.remove = __devexit_p(compal_remove)
.remove = compal_remove,
};

static enum power_supply_property compal_bat_properties[] = {
Expand Down Expand Up @@ -1015,7 +1015,7 @@ static int __init compal_init(void)
return ret;
}

static int __devinit compal_probe(struct platform_device *pdev)
static int compal_probe(struct platform_device *pdev)
{
int err;
struct compal_data *data;
Expand Down Expand Up @@ -1067,7 +1067,7 @@ static void __exit compal_cleanup(void)
pr_info("Driver unloaded\n");
}

static int __devexit compal_remove(struct platform_device *pdev)
static int compal_remove(struct platform_device *pdev)
{
struct compal_data *data;

Expand Down
4 changes: 2 additions & 2 deletions drivers/platform/x86/dell-laptop.c
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ static const struct dmi_system_id dell_device_table[] __initconst = {
};
MODULE_DEVICE_TABLE(dmi, dell_device_table);

static struct dmi_system_id __devinitdata dell_quirks[] = {
static struct dmi_system_id dell_quirks[] = {
{
.callback = dmi_matched,
.ident = "Dell Vostro V130",
Expand Down Expand Up @@ -503,7 +503,7 @@ static struct led_classdev touchpad_led = {
.flags = LED_CORE_SUSPENDRESUME,
};

static int __devinit touchpad_led_init(struct device *dev)
static int touchpad_led_init(struct device *dev)
{
return led_classdev_register(dev, &touchpad_led);
}
Expand Down
6 changes: 3 additions & 3 deletions drivers/platform/x86/eeepc-laptop.c
Original file line number Diff line number Diff line change
Expand Up @@ -1375,7 +1375,7 @@ static void cmsg_quirks(struct eeepc_laptop *eeepc)
cmsg_quirk(eeepc, CM_ASL_TPD, "TPD");
}

static int __devinit eeepc_acpi_init(struct eeepc_laptop *eeepc)
static int eeepc_acpi_init(struct eeepc_laptop *eeepc)
{
unsigned int init_flags;
int result;
Expand Down Expand Up @@ -1407,7 +1407,7 @@ static int __devinit eeepc_acpi_init(struct eeepc_laptop *eeepc)
return 0;
}

static void __devinit eeepc_enable_camera(struct eeepc_laptop *eeepc)
static void eeepc_enable_camera(struct eeepc_laptop *eeepc)
{
/*
* If the following call to set_acpi() fails, it's because there's no
Expand All @@ -1419,7 +1419,7 @@ static void __devinit eeepc_enable_camera(struct eeepc_laptop *eeepc)

static bool eeepc_device_present;

static int __devinit eeepc_acpi_add(struct acpi_device *device)
static int eeepc_acpi_add(struct acpi_device *device)
{
struct eeepc_laptop *eeepc;
int result;
Expand Down
17 changes: 8 additions & 9 deletions drivers/platform/x86/fujitsu-tablet.c
Original file line number Diff line number Diff line change
Expand Up @@ -192,8 +192,8 @@ static void fujitsu_reset(void)
fujitsu_send_state();
}

static int __devinit input_fujitsu_setup(struct device *parent,
const char *name, const char *phys)
static int input_fujitsu_setup(struct device *parent, const char *name,
const char *phys)
{
struct input_dev *idev;
int error;
Expand Down Expand Up @@ -277,21 +277,21 @@ static irqreturn_t fujitsu_interrupt(int irq, void *dev_id)
return IRQ_HANDLED;
}

static void __devinit fujitsu_dmi_common(const struct dmi_system_id *dmi)
static void fujitsu_dmi_common(const struct dmi_system_id *dmi)
{
pr_info("%s\n", dmi->ident);
memcpy(fujitsu.config.keymap, dmi->driver_data,
sizeof(fujitsu.config.keymap));
}

static int __devinit fujitsu_dmi_lifebook(const struct dmi_system_id *dmi)
static int fujitsu_dmi_lifebook(const struct dmi_system_id *dmi)
{
fujitsu_dmi_common(dmi);
fujitsu.config.quirks |= INVERT_TABLET_MODE_BIT;
return 1;
}

static int __devinit fujitsu_dmi_stylistic(const struct dmi_system_id *dmi)
static int fujitsu_dmi_stylistic(const struct dmi_system_id *dmi)
{
fujitsu_dmi_common(dmi);
fujitsu.config.quirks |= FORCE_TABLET_MODE_IF_UNDOCK;
Expand Down Expand Up @@ -366,8 +366,7 @@ static const struct dmi_system_id dmi_ids[] __initconst = {
{ NULL }
};

static acpi_status __devinit
fujitsu_walk_resources(struct acpi_resource *res, void *data)
static acpi_status fujitsu_walk_resources(struct acpi_resource *res, void *data)
{
switch (res->type) {
case ACPI_RESOURCE_TYPE_IRQ:
Expand All @@ -390,7 +389,7 @@ fujitsu_walk_resources(struct acpi_resource *res, void *data)
}
}

static int __devinit acpi_fujitsu_add(struct acpi_device *adev)
static int acpi_fujitsu_add(struct acpi_device *adev)
{
acpi_status status;
int error;
Expand Down Expand Up @@ -432,7 +431,7 @@ static int __devinit acpi_fujitsu_add(struct acpi_device *adev)
return 0;
}

static int __devexit acpi_fujitsu_remove(struct acpi_device *adev, int type)
static int acpi_fujitsu_remove(struct acpi_device *adev, int type)
{
free_irq(fujitsu.irq, fujitsu_interrupt);
release_region(fujitsu.io_base, fujitsu.io_length);
Expand Down
8 changes: 4 additions & 4 deletions drivers/platform/x86/hp-wmi.c
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ enum hp_wmi_event_ids {
HPWMI_LOCK_SWITCH = 7,
};

static int __devinit hp_wmi_bios_setup(struct platform_device *device);
static int hp_wmi_bios_setup(struct platform_device *device);
static int __exit hp_wmi_bios_remove(struct platform_device *device);
static int hp_wmi_resume_handler(struct device *device);

Expand Down Expand Up @@ -619,7 +619,7 @@ static void cleanup_sysfs(struct platform_device *device)
device_remove_file(&device->dev, &dev_attr_tablet);
}

static int __devinit hp_wmi_rfkill_setup(struct platform_device *device)
static int hp_wmi_rfkill_setup(struct platform_device *device)
{
int err;
int wireless = 0;
Expand Down Expand Up @@ -698,7 +698,7 @@ static int __devinit hp_wmi_rfkill_setup(struct platform_device *device)
return err;
}

static int __devinit hp_wmi_rfkill2_setup(struct platform_device *device)
static int hp_wmi_rfkill2_setup(struct platform_device *device)
{
int err, i;
struct bios_rfkill2_state state;
Expand Down Expand Up @@ -778,7 +778,7 @@ static int __devinit hp_wmi_rfkill2_setup(struct platform_device *device)
return err;
}

static int __devinit hp_wmi_bios_setup(struct platform_device *device)
static int hp_wmi_bios_setup(struct platform_device *device)
{
int err;

Expand Down
13 changes: 6 additions & 7 deletions drivers/platform/x86/ideapad-laptop.c
Original file line number Diff line number Diff line change
Expand Up @@ -298,7 +298,7 @@ static const struct file_operations debugfs_cfg_fops = {
.release = single_release,
};

static int __devinit ideapad_debugfs_init(struct ideapad_private *priv)
static int ideapad_debugfs_init(struct ideapad_private *priv)
{
struct dentry *node;

Expand Down Expand Up @@ -468,8 +468,7 @@ static void ideapad_sync_rfk_state(struct ideapad_private *priv)
rfkill_set_hw_state(priv->rfk[i], hw_blocked);
}

static int __devinit ideapad_register_rfkill(struct acpi_device *adevice,
int dev)
static int ideapad_register_rfkill(struct acpi_device *adevice, int dev)
{
struct ideapad_private *priv = dev_get_drvdata(&adevice->dev);
int ret;
Expand Down Expand Up @@ -519,7 +518,7 @@ static void ideapad_unregister_rfkill(struct acpi_device *adevice, int dev)
/*
* Platform device
*/
static int __devinit ideapad_platform_init(struct ideapad_private *priv)
static int ideapad_platform_init(struct ideapad_private *priv)
{
int result;

Expand Down Expand Up @@ -569,7 +568,7 @@ static const struct key_entry ideapad_keymap[] = {
{ KE_END, 0 },
};

static int __devinit ideapad_input_init(struct ideapad_private *priv)
static int ideapad_input_init(struct ideapad_private *priv)
{
struct input_dev *inputdev;
int error;
Expand Down Expand Up @@ -776,7 +775,7 @@ static void ideapad_sync_touchpad_state(struct acpi_device *adevice)
}
}

static int __devinit ideapad_acpi_add(struct acpi_device *adevice)
static int ideapad_acpi_add(struct acpi_device *adevice)
{
int ret, i;
int cfg;
Expand Down Expand Up @@ -835,7 +834,7 @@ static int __devinit ideapad_acpi_add(struct acpi_device *adevice)
return ret;
}

static int __devexit ideapad_acpi_remove(struct acpi_device *adevice, int type)
static int ideapad_acpi_remove(struct acpi_device *adevice, int type)
{
struct ideapad_private *priv = dev_get_drvdata(&adevice->dev);
int i;
Expand Down
6 changes: 3 additions & 3 deletions drivers/platform/x86/intel_mid_powerbtn.c
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ static irqreturn_t mfld_pb_isr(int irq, void *dev_id)
return IRQ_HANDLED;
}

static int __devinit mfld_pb_probe(struct platform_device *pdev)
static int mfld_pb_probe(struct platform_device *pdev)
{
struct input_dev *input;
int irq = platform_get_irq(pdev, 0);
Expand Down Expand Up @@ -121,7 +121,7 @@ static int __devinit mfld_pb_probe(struct platform_device *pdev)
return error;
}

static int __devexit mfld_pb_remove(struct platform_device *pdev)
static int mfld_pb_remove(struct platform_device *pdev)
{
struct input_dev *input = platform_get_drvdata(pdev);
int irq = platform_get_irq(pdev, 0);
Expand All @@ -139,7 +139,7 @@ static struct platform_driver mfld_pb_driver = {
.owner = THIS_MODULE,
},
.probe = mfld_pb_probe,
.remove = __devexit_p(mfld_pb_remove),
.remove = mfld_pb_remove,
};

module_platform_driver(mfld_pb_driver);
Expand Down
2 changes: 1 addition & 1 deletion drivers/platform/x86/intel_mid_thermal.c
Original file line number Diff line number Diff line change
Expand Up @@ -563,7 +563,7 @@ static struct platform_driver mid_thermal_driver = {
.pm = &mid_thermal_pm,
},
.probe = mid_thermal_probe,
.remove = __devexit_p(mid_thermal_remove),
.remove = mid_thermal_remove,
.id_table = therm_id_table,
};

Expand Down
Loading

0 comments on commit b859f15

Please sign in to comment.