aboutsummaryrefslogtreecommitdiffstats
path: root/package/broadcom-diag/src/diag.h
diff options
context:
space:
mode:
authorFelix Fietkau <nbd@openwrt.org>2007-06-25 08:32:25 +0000
committerFelix Fietkau <nbd@openwrt.org>2007-06-25 08:32:25 +0000
commit8c41e51e92fda935eb907b9263ae44a30f9977bc (patch)
tree4e365ae77cdc155df20d51f6b0b97fff828b3756 /package/broadcom-diag/src/diag.h
parenta99b79e9ad865990e0a6c438cfbb8adc88ccf6a0 (diff)
downloadupstream-8c41e51e92fda935eb907b9263ae44a30f9977bc.tar.gz
upstream-8c41e51e92fda935eb907b9263ae44a30f9977bc.tar.bz2
upstream-8c41e51e92fda935eb907b9263ae44a30f9977bc.zip
fix failsafe on broadcom, send netlink events in diag when running linux 2.6
SVN-Revision: 7722
Diffstat (limited to 'package/broadcom-diag/src/diag.h')
-rw-r--r--package/broadcom-diag/src/diag.h18
1 files changed, 13 insertions, 5 deletions
diff --git a/package/broadcom-diag/src/diag.h b/package/broadcom-diag/src/diag.h
index 9b6dc36336..93fdedb85c 100644
--- a/package/broadcom-diag/src/diag.h
+++ b/package/broadcom-diag/src/diag.h
@@ -74,9 +74,16 @@ struct platform_t {
struct event_t {
struct work_struct wq;
- char buf[256];
- char *argv[3];
- char *envp[6];
+ unsigned long seen;
+ char *name, *action;
+#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,0)
+ struct sk_buff *skb;
+#else
+ char *scratch;
+ char *argv[4];
+ char *envp[7];
+ u8 enr, anr;
+#endif
};
extern char *nvram_get(char *str);
@@ -88,12 +95,13 @@ static struct platform_t platform;
static void register_buttons(struct button_t *b);
static void unregister_buttons(struct button_t *b);
-#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,20)
+#ifndef LINUX_2_4
static void hotplug_button(struct work_struct *work);
+static irqreturn_t button_handler(int irq, void *dev_id);
#else
static void hotplug_button(struct event_t *event);
-#endif
static irqreturn_t button_handler(int irq, void *dev_id, struct pt_regs *regs);
+#endif
/* leds */