]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - drivers/pcmcia/pcmcia_ioctl.c
[ACPI] merge 3549 4320 4485 4588 4980 5483 5651 acpica asus fops pnpacpi branches...
[linux-2.6-omap-h63xx.git] / drivers / pcmcia / pcmcia_ioctl.c
index b883bc151ed00f58b9be03c994974b7e2aaca0cb..80969f7e7a0be4eddc31e675ab404e6f144593f3 100644 (file)
@@ -31,7 +31,6 @@
 #include <linux/workqueue.h>
 
 #define IN_CARD_SERVICES
-#include <pcmcia/version.h>
 #include <pcmcia/cs_types.h>
 #include <pcmcia/cs.h>
 #include <pcmcia/cistpl.h>
@@ -71,29 +70,6 @@ extern int ds_pc_debug;
 #define ds_dbg(lvl, fmt, arg...) do { } while (0)
 #endif
 
-static const char *release = "Linux Kernel Card Services";
-
-/** pcmcia_get_card_services_info
- *
- * Return information about this version of Card Services
- */
-static int pcmcia_get_card_services_info(servinfo_t *info)
-{
-       unsigned int socket_count = 0;
-       struct list_head *tmp;
-       info->Signature[0] = 'C';
-       info->Signature[1] = 'S';
-       down_read(&pcmcia_socket_list_rwsem);
-       list_for_each(tmp, &pcmcia_socket_list)
-               socket_count++;
-       up_read(&pcmcia_socket_list_rwsem);
-       info->Count = socket_count;
-       info->Revision = CS_RELEASE_CODE;
-       info->CSLevel = 0x0210;
-       info->VendorString = (char *)release;
-       return CS_SUCCESS;
-} /* get_card_services_info */
-
 
 /* backwards-compatible accessing of driver --- by name! */
 
@@ -400,6 +376,7 @@ static int ds_open(struct inode *inode, struct file *file)
     socket_t i = iminor(inode);
     struct pcmcia_socket *s;
     user_info_t *user;
+    static int warning_printed = 0;
 
     ds_dbg(0, "ds_open(socket %d)\n", i);
 
@@ -431,6 +408,17 @@ static int ds_open(struct inode *inode, struct file *file)
     s->user = user;
     file->private_data = user;
 
+    if (!warning_printed) {
+           printk(KERN_INFO "pcmcia: Detected deprecated PCMCIA ioctl "
+                       "usage.\n");
+           printk(KERN_INFO "pcmcia: This interface will soon be removed from "
+                       "the kernel; please expect breakage unless you upgrade "
+                       "to new tools.\n");
+           printk(KERN_INFO "pcmcia: see http://www.kernel.org/pub/linux/"
+                       "utils/kernel/pcmcia/pcmcia.html for details.\n");
+           warning_printed = 1;
+    }
+
     if (s->pcmcia_state.present)
        queue_event(user, CS_EVENT_CARD_INSERTION);
     return 0;
@@ -591,9 +579,6 @@ static int ds_ioctl(struct inode * inode, struct file * file,
     case DS_ADJUST_RESOURCE_INFO:
        ret = pcmcia_adjust_resource_info(&buf->adjust);
        break;
-    case DS_GET_CARD_SERVICES_INFO:
-       ret = pcmcia_get_card_services_info(&buf->servinfo);
-       break;
     case DS_GET_CONFIGURATION_INFO:
        if (buf->config.Function &&
           (buf->config.Function >= s->functions))