[ltp] A new udev rule gives me 3min startup delay
Henrique de Moraes Holschuh
linux-thinkpad@linux-thinkpad.org
Wed, 26 Aug 2009 07:49:21 -0300
On Wed, 26 Aug 2009, Daniel Castro wrote:
> > If you need to run it only on changes (i.e. dock/undock), key it on the
> > action "change" and not all actions (such as "add" and "remove") like you
> > seem to be doing by not keying to an action at all...
>
> So yes as you said it seems to be on change action.
>
> Do I need to change the contents of /etc/udev/rules.d/80-thinkpad-T61.rules?
> To something like:
>
> KERNEL=="dock.0", ATTR{docked}=="1", ACTION==change,
> RUN+="/etc/thinkpad/dock.sh 1"
> KERNEL=="dock.0", ATTR{docked}=="0", ACTION==change,
> RUN+="/etc/thinkpad/dock.sh 0"
Yes, if you don't care that the script won't always run during boot.
--
"One disk to rule them all, One disk to find them. One disk to bring
them all and in the darkness grind them. In the Land of Redmond
where the shadows lie." -- The Silicon Valley Tarot
Henrique Holschuh