Closed dschrempf closed 6 years ago
To apply power savings for the newly attached USB device, we invoke LMT. That in turn runs through all the modules, resulting in the remounted that you are seeing.
This is normal behaviour. Is it causing you any trouble?
PS: There is an option in LMT to invoke on a module basis. This behaviour is still used in chromium os. But it had particular corner case bugs, hence I disabled it for upstream
Some context is available in https://github.com/rickysarraf/laptop-mode-tools/issues/80
Unless you have an erratic behaviour, I'd leave it as is. I'm closing this bug report but please feel free to reopen it if it is causing any trouble
Thank you for your fast reply. No, it doesn't lead to errativ behavior. The only problem is that the drives spin up because they are remounted and I'd rather not trigger a spin-up every time I attach the DAC. Is there a way to not invoke LMT for a specific USB device because I manually manage the power supply of the DAC anyways.
Thanks a lot!
I wasn't aware that a remount, that just fiddles with the commit internal, triggers an fsync.
You could change the udev invocation for subsystem type usb, to limit itself just for the runtime-pm module
s3nt fr0m a $martph0ne, excuse typ0s
On 25-Nov-2017 8:54 PM, "Dominik Schrempf" notifications@github.com wrote:
Thank you for your fast reply. No, it doesn't lead to errativ behavior. The only problem is that the drives spin up because they are remounted and I'd rather not trigger a spin-up every time I attach the DAC. Is there a way to not invoke LMT for a specific USB device because I manually manage the power supply of the DAC anyways.
Thanks a lot!
— You are receiving this because you modified the open/close state. Reply to this email directly, view it on GitHub https://github.com/rickysarraf/laptop-mode-tools/issues/120#issuecomment-346947018, or mute the thread https://github.com/notifications/unsubscribe-auth/AAD_yNm4wnNzYej_Sy1LEdXTV-EoRGs9ks5s6DE1gaJpZM4Qpuw5 .
@dschrempf You could change the USB type invocation to below.
ACTION=="add|remove", SUBSYSTEM=="usb", RUN+="lmt-udev force modules=runtime-pm
devices=%k"
This would force execution of the runtime-pm module only.
Hi, thank you very much for you help. I changed the line to
ACTION=="add", SUBSYSTEM=="usb", RUN+="lmt-udev force modules=runtime-pm devices=%k"
Like this it only triggers the runtime-pm module when USB devices are attached, not removed. Works like a charm, thank you!
I have a short question. Is it normal that all partitions are remounted when I connect a USB device (a DAC)?
I get the following output in
dmesg
:It might be that this remount is triggered by
mpd
because a sound card is attached and part of the database is on sda2 and on sdb1. sdc1 is a backup drive that should not be remounted in any case. Do you have any ideas?