On Wed, Jul 16, 2008 at 9:17 PM, Chris Frey <[EMAIL PROTECTED]> wrote: > On Tue, Jul 15, 2008 at 12:20:50AM +0200, Niels de Vos wrote: >> just hacked a little script together which uses the sysfs-structure >> for finding any BlackBerries (well, at least my BB8100). After some >> small sanity checks the script disconnects the BlackBerry from >> usb-storage using the 'unbind' file. > > Thanks Niels! > > This is an improvement over dropping usb_storage in the module blacklist.
That's the point. Still only roughly tested though. Someone already mentioned it some months ago in this thread, I just kept on thinking about it :) ...searching archive... It was Martin Owens: <http://sourceforge.net/mailarchive/message.php?msg_id=69ff73b20710091437r1335496am691a4ea2054eb754%40mail.gmail.com> >> Instead of a script, it would of course also be possible to add a >> C/C++-function to libbarry. The logic is pretty straight forward, >> however writing it in C/C++ would require quite some more lines ;) For >> the adventurous wanting to write this code, please see these notes >> about _not_ using libsysfs: >> <http://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=blob;f=Documentation/filesystems/sysfs.txt>. > > Is this the document you meant to link to? I didn't see any mention > of libsysfs. You're right, it should be <http://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=blob;f=Documentation/sysfs-rules.txt>. >> I hope this script helps somebody and explains a bit more how >> usb-storage can be kept loaded while using barry. I provide this >> script for inclusion in barry as utility, testcase and/or >> documentation. Have fun wit it! > > Do you run this manually, or do you launch it via hal or udev? > It would be nice to include this as an optional(?) feature in the binary > packages, and have this run automatically. Well, I run it manually and start bcharge/btool after that. It would also be possible to change the udev-rules to start the script too/instead/before bcharge. However I also do think it would be most convenient if libbarry provides comparable functions (or handle it automagically). Niels ------------------------------------------------------------------------- This SF.Net email is sponsored by the Moblin Your Move Developer's challenge Build the coolest Linux based applications with Moblin SDK & win great prizes Grand prize is a trip for two to an Open Source event anywhere in the world http://moblin-contest.org/redirect.php?banner_id=100&url=/ _______________________________________________ Barry-devel mailing list Barry-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/barry-devel