updating from 20230614 to 20231030 breaks udev rule for pixel 6a
dkwo opened this issue · 5 comments
this is on void linux (using runit, eudev).
i think the udev rule does not get applied anymore, as running
aft-mtp-mount ~/mnt
connect failed: no MTP device found
while running it as root is fine.
works on 20230614 but broken on 20231030 on a google pixel 6a.
could you point to some culprit commits to test?
Hi @dkwo,
Some functions were intentionally changed from a blanket accept "anything" from vendor X, to a more limited, accept what we do know, and drop the rest. This is necessary to avoid accepting unwanted devices like keyboards, mice, and other USB devices which aren't android devices. You will see near line 250 where this was changed:
# Other vendors that also used duplicated Google's idVendor code follows:
# IDEA XDS-1078 (debug=2c11)
ATTR{idProduct}=="2c11", ENV{adb_adb}="yes"
-GOTO="android_usb_rule_match"
+GOTO="android_usb_rules_end"
LABEL="not_Google"
There were also several lines removed, with the expectation that they would then be picked-up later by 69-libmtp.rules since it would make sense for that project to take care of android devices running in a "non-debug" mode while 51-android.rules takes care of android devices running in "debug" mode - however - it looks like 69-libmtp.rules is not there.
I need to know what idVendor:idProduct values you get for the Pixel 6a.
Can you please run at the commandline `lsusb' or better yet 'lsusb -v' and printout the information for the pixel 6a?
Thanks for helping. It turns out, I just need to install libmtp
, with that everything works.
Sorry for the useless noise, I just was not aware of it.
btw, do you recommend that android-udev-rules
package depends on libmtp
?
Thanks for helping. It turns out, I just need to install
libmtp
, with that everything works. Sorry for the useless noise, I just was not aware of it.
For every question asked, you can imagine that there are 10+ other people with the same question looking through issues for an answer, so, your question, and the reply maybe helps 10+ other readers, so we can probably consider this was useful noise ;-P
btw, do you recommend that
android-udev-rules
package depends onlibmtp
?
Some time ago in the past, some contributors who knew far better than us, began including patches with the curious lines containing SYMLINK+="libmtp-%k", ENV{ID_MTP_DEVICE}="1", ENV{ID_MEDIA_PLAYER}="1"
, at the time, we didn't really know where that came from, but with time saw that it was a bit of 69-libmtp.rules.
In summary, that is when android-rules-udev
became a dependent of libmtp
. So to answer your question, yes, it's recommended to make the void android-udev-rules
dependent on libmtp
(if some sort of dependency-tree is maintained by void linux). You could see it mentioned here in arch, while other distros may handle it the same, or maybe differently.
...this is on void linux (using runit, eudev).
I'm curious about this. Where is 51-android.rules located when installed (by void distro)?
Is it still in /usr/lib/udev/rules.d/
, or in /etc/udev/rules.d/
, or is it located elsewhere?
Thanks in advance for a reply.
Thanks for the recommendation, I'll open a PR to add it.
Currently, it's installed (644) in /usr/lib/udev/rules.d
.