summaryrefslogtreecommitdiff
path: root/include/linux
diff options
context:
space:
mode:
authorVojtech Pavlik <vojtech@suse.cz>2004-03-12 02:29:52 +0100
committerVojtech Pavlik <vojtech@suse.cz>2004-03-12 02:29:52 +0100
commit7ed820153475a74c46164997cf73941679f46c5c (patch)
treed2e2f6c5f33235d9c1556406fac2420f644bb646 /include/linux
parent0a912921292ec744448f9462e46c31928f422f01 (diff)
parentc9d14734db3b79a901bbf46245b62fc391d70b55 (diff)
Merge suse.cz:/home/vojtech/bk/linus into suse.cz:/home/vojtech/bk/input
Diffstat (limited to 'include/linux')
-rw-r--r--include/linux/hiddev.h74
-rw-r--r--include/linux/init.h22
-rw-r--r--include/linux/miscdevice.h1
-rw-r--r--include/linux/moduleparam.h9
-rw-r--r--include/linux/serio.h2
5 files changed, 68 insertions, 40 deletions
diff --git a/include/linux/hiddev.h b/include/linux/hiddev.h
index 9e6d27476a74..75c1fa0d2189 100644
--- a/include/linux/hiddev.h
+++ b/include/linux/hiddev.h
@@ -39,33 +39,33 @@ struct hiddev_event {
};
struct hiddev_devinfo {
- unsigned int bustype;
- unsigned int busnum;
- unsigned int devnum;
- unsigned int ifnum;
- short vendor;
- short product;
- short version;
- unsigned num_applications;
+ __u32 bustype;
+ __u32 busnum;
+ __u32 devnum;
+ __u32 ifnum;
+ __s16 vendor;
+ __s16 product;
+ __s16 version;
+ __u32 num_applications;
};
struct hiddev_collection_info {
- unsigned index;
- unsigned type;
- unsigned usage;
- unsigned level;
+ __u32 index;
+ __u32 type;
+ __u32 usage;
+ __u32 level;
};
#define HID_STRING_SIZE 256
struct hiddev_string_descriptor {
- int index;
+ __s32 index;
char value[HID_STRING_SIZE];
};
struct hiddev_report_info {
- unsigned report_type;
- unsigned report_id;
- unsigned num_fields;
+ __u32 report_type;
+ __u32 report_id;
+ __u32 num_fields;
};
/* To do a GUSAGE/SUSAGE, fill in at least usage_code, report_type and
@@ -88,20 +88,20 @@ struct hiddev_report_info {
#define HID_REPORT_TYPE_MAX 3
struct hiddev_field_info {
- unsigned report_type;
- unsigned report_id;
- unsigned field_index;
- unsigned maxusage;
- unsigned flags;
- unsigned physical; /* physical usage for this field */
- unsigned logical; /* logical usage for this field */
- unsigned application; /* application usage for this field */
+ __u32 report_type;
+ __u32 report_id;
+ __u32 field_index;
+ __u32 maxusage;
+ __u32 flags;
+ __u32 physical; /* physical usage for this field */
+ __u32 logical; /* logical usage for this field */
+ __u32 application; /* application usage for this field */
__s32 logical_minimum;
__s32 logical_maximum;
__s32 physical_minimum;
__s32 physical_maximum;
- unsigned unit_exponent;
- unsigned unit;
+ __u32 unit_exponent;
+ __u32 unit;
};
/* Fill in report_type, report_id and field_index to get the information on a
@@ -118,14 +118,22 @@ struct hiddev_field_info {
#define HID_FIELD_BUFFERED_BYTE 0x100
struct hiddev_usage_ref {
- unsigned report_type;
- unsigned report_id;
- unsigned field_index;
- unsigned usage_index;
- unsigned usage_code;
+ __u32 report_type;
+ __u32 report_id;
+ __u32 field_index;
+ __u32 usage_index;
+ __u32 usage_code;
__s32 value;
};
+/* hiddev_usage_ref_multi is used for sending multiple bytes to a control.
+ * It really manifests itself as setting the value of consecutive usages */
+struct hiddev_usage_ref_multi {
+ struct hiddev_usage_ref uref;
+ __u32 num_values;
+ __s32 values[HID_MAX_USAGES];
+};
+
/* FIELD_INDEX_NONE is returned in read() data from the kernel when flags
* is set to (HIDDEV_FLAG_UREF | HIDDEV_FLAG_REPORT) and a new report has
* been sent by the device
@@ -161,6 +169,10 @@ struct hiddev_usage_ref {
#define HIDIOCGCOLLECTIONINFO _IOWR('H', 0x11, struct hiddev_collection_info)
#define HIDIOCGPHYS(len) _IOC(_IOC_READ, 'H', 0x12, len)
+/* For writing/reading to multiple/consecutive usages */
+#define HIDIOCGUSAGES _IOWR('H', 0x13, struct hiddev_usage_ref_multi)
+#define HIDIOCSUSAGES _IOW('H', 0x14, struct hiddev_usage_ref_multi)
+
/*
* Flags to be used in HIDIOCSFLAG
*/
diff --git a/include/linux/init.h b/include/linux/init.h
index 0ab73cff6c48..45069e275b3d 100644
--- a/include/linux/init.h
+++ b/include/linux/init.h
@@ -110,12 +110,21 @@ struct obs_kernel_param {
};
/* OBSOLETE: see moduleparam.h for the right way. */
-#define __setup(str, fn) \
- static char __setup_str_##fn[] __initdata = str; \
- static struct obs_kernel_param __setup_##fn \
+#define __setup_param(str, unique_id, fn) \
+ static char __setup_str_##unique_id[] __initdata = str; \
+ static struct obs_kernel_param __setup_##unique_id \
__attribute_used__ \
__attribute__((__section__(".init.setup"))) \
- = { __setup_str_##fn, fn }
+ = { __setup_str_##unique_id, fn }
+
+#define __setup_null_param(str, unique_id) \
+ __setup_param(str, unique_id, NULL)
+
+#define __setup(str, fn) \
+ __setup_param(str, fn, fn)
+
+#define __obsolete_setup(str) \
+ __setup_null_param(str, __LINE__)
#endif /* __ASSEMBLY__ */
@@ -172,7 +181,10 @@ struct obs_kernel_param {
{ return exitfn; } \
void cleanup_module(void) __attribute__((alias(#exitfn)));
-#define __setup(str,func) /* nothing */
+#define __setup_param(str, unique_id, fn) /* nothing */
+#define __setup_null_param(str, unique_id) /* nothing */
+#define __setup(str, func) /* nothing */
+#define __obsolete_setup(str) /* nothing */
#endif
/* Data marked not to be saved by software_suspend() */
diff --git a/include/linux/miscdevice.h b/include/linux/miscdevice.h
index 98f61665d4c2..89b87832c769 100644
--- a/include/linux/miscdevice.h
+++ b/include/linux/miscdevice.h
@@ -3,7 +3,6 @@
#include <linux/module.h>
#include <linux/major.h>
-#define BUSMOUSE_MINOR 0
#define PSMOUSE_MINOR 1
#define MS_BUSMOUSE_MINOR 2
#define ATIXL_BUSMOUSE_MINOR 3
diff --git a/include/linux/moduleparam.h b/include/linux/moduleparam.h
index cbca00722b5c..e9d6a16d3fef 100644
--- a/include/linux/moduleparam.h
+++ b/include/linux/moduleparam.h
@@ -126,13 +126,16 @@ extern int param_get_invbool(char *buffer, struct kernel_param *kp);
#define param_check_invbool(name, p) __param_check(name, p, int)
/* Comma-separated array: num is set to number they actually specified. */
-#define module_param_array(name, type, num, perm) \
+#define module_param_array_named(name, array, type, num, perm) \
static struct kparam_array __param_arr_##name \
- = { ARRAY_SIZE(name), &num, param_set_##type, param_get_##type, \
- sizeof(name[0]), name }; \
+ = { ARRAY_SIZE(array), &num, param_set_##type, param_get_##type,\
+ sizeof(array[0]), array }; \
module_param_call(name, param_array_set, param_array_get, \
&__param_arr_##name, perm)
+#define module_param_array(name, type, num, perm) \
+ module_param_array_named(name, name, type, num, perm)
+
extern int param_array_set(const char *val, struct kernel_param *kp);
extern int param_array_get(char *buffer, struct kernel_param *kp);
diff --git a/include/linux/serio.h b/include/linux/serio.h
index d99e973302de..28f62471af10 100644
--- a/include/linux/serio.h
+++ b/include/linux/serio.h
@@ -117,6 +117,7 @@ static __inline__ void serio_cleanup(struct serio *serio)
#define SERIO_MZ 0x05
#define SERIO_MZP 0x06
#define SERIO_MZPP 0x07
+#define SERIO_VSXXXAA 0x08
#define SERIO_SUNKBD 0x10
#define SERIO_WARRIOR 0x18
#define SERIO_SPACEORB 0x19
@@ -134,6 +135,7 @@ static __inline__ void serio_cleanup(struct serio *serio)
#define SERIO_HIL 0x25
#define SERIO_SNES232 0x26
#define SERIO_SEMTECH 0x27
+#define SERIO_LKKBD 0x28
#define SERIO_ID 0xff00UL
#define SERIO_EXTRA 0xff0000UL