* [Bluez-devel] Reboot notifier
@ 2006-08-01 14:17 Milind Dumbare
2006-08-01 17:15 ` Ulisses Furquim
0 siblings, 1 reply; 9+ messages in thread
From: Milind Dumbare @ 2006-08-01 14:17 UTC (permalink / raw)
To: bluez-devel
Hi all,
I think bluetooth stack for linux needs reboot notifier. I am thinking
of writing it. Shall I?
--
-Milind
"There is no place like 127.0.0.1"
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys -- and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Bluez-devel mailing list
Bluez-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/bluez-devel
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [Bluez-devel] Reboot notifier
2006-08-01 14:17 [Bluez-devel] Reboot notifier Milind Dumbare
@ 2006-08-01 17:15 ` Ulisses Furquim
2006-08-02 6:11 ` Milind Dumbare
0 siblings, 1 reply; 9+ messages in thread
From: Ulisses Furquim @ 2006-08-01 17:15 UTC (permalink / raw)
To: BlueZ development
Hi Milind,
On 8/1/06, Milind Dumbare <milind@linsyssoft.com> wrote:
> I think bluetooth stack for linux needs reboot notifier. I am thinking
> of writing it. Shall I?
Sorry, but I don't know what this "reboot notifier" feature really is.
Do you mind explaining it, please?
-- Ulisses
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys -- and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Bluez-devel mailing list
Bluez-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/bluez-devel
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [Bluez-devel] Reboot notifier
2006-08-01 17:15 ` Ulisses Furquim
@ 2006-08-02 6:11 ` Milind Dumbare
2006-08-02 10:34 ` Marcel Holtmann
0 siblings, 1 reply; 9+ messages in thread
From: Milind Dumbare @ 2006-08-02 6:11 UTC (permalink / raw)
To: BlueZ development
Hi,
Reboot notifier will register bluetooth driver to reboot notification
list of kernel. Whenever machine will get rebooted bluetooth drvier will
get notified by type of reboot(Halt/reboot/poweroff). We can do
interesting things after we get notified that reboot will be there.
On Tue, 2006-08-01 at 14:15 -0300, Ulisses Furquim wrote:
> Hi Milind,
>
> On 8/1/06, Milind Dumbare <milind@linsyssoft.com> wrote:
> > I think bluetooth stack for linux needs reboot notifier. I am thinking
> > of writing it. Shall I?
>
> Sorry, but I don't know what this "reboot notifier" feature really is.
> Do you mind explaining it, please?
>
> -- Ulisses
>
> -------------------------------------------------------------------------
> Take Surveys. Earn Cash. Influence the Future of IT
> Join SourceForge.net's Techsay panel and you'll get the chance to share your
> opinions on IT & business topics through brief surveys -- and earn cash
> http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
> _______________________________________________
> Bluez-devel mailing list
> Bluez-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/bluez-devel
>
>
--
-Milind
"There is no place like 127.0.0.1"
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys -- and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Bluez-devel mailing list
Bluez-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/bluez-devel
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [Bluez-devel] Reboot notifier
2006-08-02 10:34 ` Marcel Holtmann
@ 2006-08-02 8:51 ` Milind Dumbare
2006-08-02 13:32 ` Marcel Holtmann
0 siblings, 1 reply; 9+ messages in thread
From: Milind Dumbare @ 2006-08-02 8:51 UTC (permalink / raw)
To: BlueZ development
The first most useful think is doing module cleanup while rebooting.
About other things, you will know them more deeply. May be like keeping
informing user level utilities to do some interesting stuff like.
Keeping connection settings live post reboot or other.
On Wed, 2006-08-02 at 12:34 +0200, Marcel Holtmann wrote:
> Hi Milind,
>
> > Reboot notifier will register bluetooth driver to reboot notification
> > list of kernel. Whenever machine will get rebooted bluetooth drvier will
> > get notified by type of reboot(Halt/reboot/poweroff). We can do
> > interesting things after we get notified that reboot will be there.
>
> you must be more specific, because I don't see any need for such a
> notifier. What do we get from knowing such events.
>
> Regards
>
> Marcel
>
>
>
> -------------------------------------------------------------------------
> Take Surveys. Earn Cash. Influence the Future of IT
> Join SourceForge.net's Techsay panel and you'll get the chance to share your
> opinions on IT & business topics through brief surveys -- and earn cash
> http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
> _______________________________________________
> Bluez-devel mailing list
> Bluez-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/bluez-devel
>
>
--
-Milind
"There is no place like 127.0.0.1"
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys -- and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Bluez-devel mailing list
Bluez-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/bluez-devel
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [Bluez-devel] Reboot notifier
2006-08-02 6:11 ` Milind Dumbare
@ 2006-08-02 10:34 ` Marcel Holtmann
2006-08-02 8:51 ` Milind Dumbare
0 siblings, 1 reply; 9+ messages in thread
From: Marcel Holtmann @ 2006-08-02 10:34 UTC (permalink / raw)
To: BlueZ development
Hi Milind,
> Reboot notifier will register bluetooth driver to reboot notification
> list of kernel. Whenever machine will get rebooted bluetooth drvier will
> get notified by type of reboot(Halt/reboot/poweroff). We can do
> interesting things after we get notified that reboot will be there.
you must be more specific, because I don't see any need for such a
notifier. What do we get from knowing such events.
Regards
Marcel
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys -- and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Bluez-devel mailing list
Bluez-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/bluez-devel
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [Bluez-devel] Reboot notifier
2006-08-02 13:32 ` Marcel Holtmann
@ 2006-08-02 12:08 ` Milind Dumbare
2006-08-02 14:21 ` Milind Dumbare
1 sibling, 0 replies; 9+ messages in thread
From: Milind Dumbare @ 2006-08-02 12:08 UTC (permalink / raw)
To: BlueZ development
On Wed, 2006-08-02 at 15:32 +0200, Marcel Holtmann wrote:
> Hi Milind,
>
> > The first most useful think is doing module cleanup while rebooting.
> > About other things, you will know them more deeply. May be like keeping
> > informing user level utilities to do some interesting stuff like.
> > Keeping connection settings live post reboot or other.
>
> there is no need for a module cleanup. And unloading of kernel modules
> still has to be considered as a race condition.
>
> Once you reset the USB bus for example all USB Bluetooth dongles will
> disconnect and be powered off and all connections will go away anyway.
> There is no real chance to keep connections over reboot.
> So I don't see any need for this, but feel free to send in patches for
> it and convince me otherwise.
>
I will definitly. Give me some time. :-)
> Regards
>
> Marcel
>
>
>
> -------------------------------------------------------------------------
> Take Surveys. Earn Cash. Influence the Future of IT
> Join SourceForge.net's Techsay panel and you'll get the chance to share your
> opinions on IT & business topics through brief surveys -- and earn cash
> http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
> _______________________________________________
> Bluez-devel mailing list
> Bluez-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/bluez-devel
>
>
--
-Milind
"There is no place like 127.0.0.1"
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys -- and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Bluez-devel mailing list
Bluez-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/bluez-devel
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [Bluez-devel] Reboot notifier
2006-08-02 8:51 ` Milind Dumbare
@ 2006-08-02 13:32 ` Marcel Holtmann
2006-08-02 12:08 ` Milind Dumbare
2006-08-02 14:21 ` Milind Dumbare
0 siblings, 2 replies; 9+ messages in thread
From: Marcel Holtmann @ 2006-08-02 13:32 UTC (permalink / raw)
To: BlueZ development
Hi Milind,
> The first most useful think is doing module cleanup while rebooting.
> About other things, you will know them more deeply. May be like keeping
> informing user level utilities to do some interesting stuff like.
> Keeping connection settings live post reboot or other.
there is no need for a module cleanup. And unloading of kernel modules
still has to be considered as a race condition.
Once you reset the USB bus for example all USB Bluetooth dongles will
disconnect and be powered off and all connections will go away anyway.
There is no real chance to keep connections over reboot.
So I don't see any need for this, but feel free to send in patches for
it and convince me otherwise.
Regards
Marcel
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys -- and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Bluez-devel mailing list
Bluez-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/bluez-devel
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [Bluez-devel] Reboot notifier
2006-08-02 13:32 ` Marcel Holtmann
2006-08-02 12:08 ` Milind Dumbare
@ 2006-08-02 14:21 ` Milind Dumbare
2006-08-08 10:19 ` Milind Dumbare
1 sibling, 1 reply; 9+ messages in thread
From: Milind Dumbare @ 2006-08-02 14:21 UTC (permalink / raw)
To: BlueZ development
[-- Attachment #1: Type: text/plain, Size: 1508 bytes --]
Hi Marcel,
I have attached patch for reboot notifier. Any suggestions are
appreciated.
Thanks
On Wed, 2006-08-02 at 15:32 +0200, Marcel Holtmann wrote:
> Hi Milind,
>
> > The first most useful think is doing module cleanup while rebooting.
> > About other things, you will know them more deeply. May be like keeping
> > informing user level utilities to do some interesting stuff like.
> > Keeping connection settings live post reboot or other.
>
> there is no need for a module cleanup. And unloading of kernel modules
> still has to be considered as a race condition.
>
> Once you reset the USB bus for example all USB Bluetooth dongles will
> disconnect and be powered off and all connections will go away anyway.
> There is no real chance to keep connections over reboot.
>
> So I don't see any need for this, but feel free to send in patches for
> it and convince me otherwise.
>
> Regards
>
> Marcel
>
>
>
> -------------------------------------------------------------------------
> Take Surveys. Earn Cash. Influence the Future of IT
> Join SourceForge.net's Techsay panel and you'll get the chance to share your
> opinions on IT & business topics through brief surveys -- and earn cash
> http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
> _______________________________________________
> Bluez-devel mailing list
> Bluez-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/bluez-devel
>
>
--
-Milind
"There is no place like 127.0.0.1"
[-- Attachment #2: blue_reboot.patch --]
[-- Type: text/x-patch, Size: 1779 bytes --]
Singed Off: Milind Dumbare <milind@linsyssoft.com>
hci_usb.c | 32 +++++++++++++++++++++++++++++++-
1 file changed, 31 insertions(+), 1 deletion(-)
Index: linux-2.6.15-pre3/drivers/bluetooth/hci_usb.c
===================================================================
--- linux-2.6.15-pre3.orig/drivers/bluetooth/hci_usb.c 2006-08-02 08:44:42.000000000 -0500
+++ linux-2.6.15-pre3/drivers/bluetooth/hci_usb.c 2006-08-02 09:15:22.000000000 -0500
@@ -46,6 +46,9 @@
#include <linux/errno.h>
#include <linux/string.h>
#include <linux/skbuff.h>
+#include <linux/notifier.h>
+#include <linux/reboot.h>
+
#include <linux/usb.h>
@@ -133,6 +136,13 @@
{ } /* Terminating entry */
};
+static int hci_usb_notify_reboot(struct notifier_block *this,
+ unsigned long code ,void *x);
+
+static struct notifier_block hci_usb_reboot_notifier = {
+ .notifier_call = hci_usb_notify_reboot,
+ };
+
static struct _urb *_urb_alloc(int isoc, gfp_t gfp)
{
struct _urb *_urb = kmalloc(sizeof(struct _urb) +
@@ -1053,10 +1063,15 @@
static int __init hci_usb_init(void)
{
- int err;
+ int err, ret;
BT_INFO("HCI USB driver ver %s", VERSION);
+ ret = register_reboot_notifier(&hci_usb_reboot_notifier);
+ if(ret)
+ BT_ERR("Could not register to reboot notifier list");
+
+
if ((err = usb_register(&hci_usb_driver)) < 0)
BT_ERR("Failed to register HCI USB driver");
@@ -1068,6 +1083,21 @@
usb_deregister(&hci_usb_driver);
}
+static int hci_usb_notify_reboot(struct notifier_block *this,
+ unsigned long event ,void *unused)
+{
+ switch(event) {
+ /*FIXME*/
+ case SYS_RESTART:
+ case SYS_HALT:
+ case SYS_POWER_OFF:
+ default:
+ hci_usb_exit();
+ break;
+ }
+
+ return NOTIFY_DONE;
+}
module_init(hci_usb_init);
module_exit(hci_usb_exit);
[-- Attachment #3: Type: text/plain, Size: 348 bytes --]
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys -- and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
[-- Attachment #4: Type: text/plain, Size: 164 bytes --]
_______________________________________________
Bluez-devel mailing list
Bluez-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/bluez-devel
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [Bluez-devel] Reboot notifier
2006-08-02 14:21 ` Milind Dumbare
@ 2006-08-08 10:19 ` Milind Dumbare
0 siblings, 0 replies; 9+ messages in thread
From: Milind Dumbare @ 2006-08-08 10:19 UTC (permalink / raw)
To: BlueZ development
Marcel,
I didn't get any reply.
On Wed, 2006-08-02 at 19:51 +0530, Milind Dumbare wrote:
> Hi Marcel,
> I have attached patch for reboot notifier. Any suggestions are
> appreciated.
>
> Thanks
> On Wed, 2006-08-02 at 15:32 +0200, Marcel Holtmann wrote:
> > Hi Milind,
> >
> > > The first most useful think is doing module cleanup while rebooting.
> > > About other things, you will know them more deeply. May be like keeping
> > > informing user level utilities to do some interesting stuff like.
> > > Keeping connection settings live post reboot or other.
> >
> > there is no need for a module cleanup. And unloading of kernel modules
> > still has to be considered as a race condition.
> >
> > Once you reset the USB bus for example all USB Bluetooth dongles will
> > disconnect and be powered off and all connections will go away anyway.
> > There is no real chance to keep connections over reboot.
> >
> > So I don't see any need for this, but feel free to send in patches for
> > it and convince me otherwise.
> >
> > Regards
> >
> > Marcel
> >
> >
> >
> > -------------------------------------------------------------------------
> > Take Surveys. Earn Cash. Influence the Future of IT
> > Join SourceForge.net's Techsay panel and you'll get the chance to share your
> > opinions on IT & business topics through brief surveys -- and earn cash
> > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
> > _______________________________________________
> > Bluez-devel mailing list
> > Bluez-devel@lists.sourceforge.net
> > https://lists.sourceforge.net/lists/listinfo/bluez-devel
> >
> >
> -------------------------------------------------------------------------
> Take Surveys. Earn Cash. Influence the Future of IT
> Join SourceForge.net's Techsay panel and you'll get the chance to share your
> opinions on IT & business topics through brief surveys -- and earn cash
> http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
> _______________________________________________ Bluez-devel mailing list Bluez-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/bluez-devel
--
-Milind
"There is no place like 127.0.0.1"
-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
Bluez-devel mailing list
Bluez-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/bluez-devel
^ permalink raw reply [flat|nested] 9+ messages in thread
end of thread, other threads:[~2006-08-08 10:19 UTC | newest]
Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-08-01 14:17 [Bluez-devel] Reboot notifier Milind Dumbare
2006-08-01 17:15 ` Ulisses Furquim
2006-08-02 6:11 ` Milind Dumbare
2006-08-02 10:34 ` Marcel Holtmann
2006-08-02 8:51 ` Milind Dumbare
2006-08-02 13:32 ` Marcel Holtmann
2006-08-02 12:08 ` Milind Dumbare
2006-08-02 14:21 ` Milind Dumbare
2006-08-08 10:19 ` Milind Dumbare
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).