patch-2.3.35 linux/include/pcmcia/ss.h

Next file: linux/include/video/sbusfb.h
Previous file: linux/include/pcmcia/cs.h
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.3.34/linux/include/pcmcia/ss.h linux/include/pcmcia/ss.h
@@ -30,12 +30,6 @@
 #ifndef _LINUX_SS_H
 #define _LINUX_SS_H
 
-/* For RegisterCallback */
-typedef struct ss_callback_t {
-    void	(*handler)(void *info, u_int events);
-    void	*info;
-} ss_callback_t;
-
 /* Definitions for card status flags for GetStatus */
 #define SS_WRPROT	0x0001
 #define SS_CARDLOCK	0x0002
@@ -120,11 +114,28 @@
     u_int	start, stop;
 } cb_bridge_map;
 
-enum ss_service {
-    SS_RegisterCallback, SS_InquireSocket,
-    SS_GetStatus, SS_GetSocket, SS_SetSocket,
-    SS_GetIOMap, SS_SetIOMap, SS_GetMemMap, SS_SetMemMap,
-    SS_GetBridge, SS_SetBridge, SS_ProcSetup
+/*
+ * Socket operations.
+ */
+struct pccard_operations {
+	int (*register_callback)(unsigned int sock, void (*handler)(void *, unsigned int), void * info);
+	int (*inquire_socket)(unsigned int sock, socket_cap_t *cap);
+	int (*get_status)(unsigned int sock, u_int *value);
+	int (*get_socket)(unsigned int sock, socket_state_t *state);
+	int (*set_socket)(unsigned int sock, socket_state_t *state);
+	int (*get_io_map)(unsigned int sock, struct pccard_io_map *io);
+	int (*set_io_map)(unsigned int sock, struct pccard_io_map *io);
+	int (*get_mem_map)(unsigned int sock, struct pccard_mem_map *mem);
+	int (*set_mem_map)(unsigned int sock, struct pccard_mem_map *mem);
+	int (*get_bridge)(unsigned int sock, struct cb_bridge_map *m);
+	int (*set_bridge)(unsigned int sock, struct cb_bridge_map *m);
+	void (*proc_setup)(unsigned int sock, struct proc_dir_entry *base);
 };
+
+/*
+ *  Calls to set up low-level "Socket Services" drivers
+ */
+extern int register_ss_entry(int nsock, struct pccard_operations *ops);
+extern void unregister_ss_entry(struct pccard_operations *ops);
 
 #endif /* _LINUX_SS_H */

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)