lkml.org 
[lkml]   [2005]   [Jul]   [5]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
Subjectmissing "platform_remove_devices" in kernel 2.6
From
Hi,

I attached patch for kernel 2.6.12 which add missing
"platform_remove_devices" function in "drivers/base/platform.c" file.

Pawel Kolodziejski

diff -u -r -N -P old/kernel26/drivers/base/platform.c new/kernel26/drivers/base/platform.c
--- old/kernel26/drivers/base/platform.c 2005-07-01 06:48:46.000000000 +0200
+++ new/kernel26/drivers/base/platform.c 2005-07-01 07:33:44.000000000 +0200
@@ -114,6 +114,22 @@
}

/**
+ * platform_remove_devices - remove a numbers of platform devices
+ * @devs: array of platform devices to remove
+ * @num: number of platform devices in array
+ */
+int platform_remove_devices(struct platform_device **devs, int num)
+{
+ int i;
+
+ for (i = 0; i < num; i++) {
+ platform_device_unregister(devs[i]);
+ }
+
+ return 0;
+}
+
+/**
* platform_device_register - add a platform-level device
* @pdev: platform device we're adding
*
@@ -347,6 +363,7 @@
EXPORT_SYMBOL_GPL(platform_bus);
EXPORT_SYMBOL_GPL(platform_bus_type);
EXPORT_SYMBOL_GPL(platform_add_devices);
+EXPORT_SYMBOL_GPL(platform_remove_devices);
EXPORT_SYMBOL_GPL(platform_device_register);
EXPORT_SYMBOL_GPL(platform_device_register_simple);
EXPORT_SYMBOL_GPL(platform_device_unregister);
\
 
 \ /
  Last update: 2005-07-05 23:16    [W:0.034 / U:3.016 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site