You are not logged in.

#1 2017-08-28 08:11:18

Archtefact
Member
Registered: 2017-05-15
Posts: 5

Problem connecting IPhone on USB

Hello Archers,
I have a strange problem connecting my IPhone on arch trough USB.
When I just booted the system and then connect the phone : no problem.
After that, the phone need a new USB port to work, if I connect it on a port on which it was already connected before, it do not work.
When I have used every USB port available, I must to restart the system to get it work anymore !!

This affect USB thetering like ifuse, cause the phone is even not showing in lsusb.

Have anyone experienced same problem ? What can I do to investigate this ?

Thanks for reading

Last edited by Archtefact (2017-08-28 08:12:05)

Offline

#2 2017-08-28 08:49:41

cyyyyc123
Member
Registered: 2017-03-03
Posts: 6

Re: Problem connecting IPhone on USB

I have met this problem too ! Hope someone could solve it!

A related issue was posted in https://forum.manjaro.org/t/ios-or-ipho … ging/29356

Offline

#3 2017-08-28 10:14:27

Starfish
Member
From: Germany
Registered: 2015-10-21
Posts: 134

Re: Problem connecting IPhone on USB

This is how I would start:
(1) Reboot and run

lsusb -t > temp_1

(2) Plug in your phone, wait a moment and run

lsusb -t > temp_2

(3) Run

diff temp_1 temp_2

The shell should show you now the device plus port. Now you could pull it out and see if it is still in lsusb's output and at the same port

Last edited by Starfish (2017-08-28 10:16:43)


"Yesterday is history, tomorrow is a mystery, but today is a gift. That is why it is called the present." - Master Oogway

Offline

#4 2017-08-28 11:40:17

cyyyyc123
Member
Registered: 2017-03-03
Posts: 6

Re: Problem connecting IPhone on USB

@Starfish Thanks! After trying your suggestion, I get the following message:

temp_1: (pluging my iphone in the usb at the first time)
/:  Bus 02.Port 1: Dev 1, Class=root_hub, Driver=xhci_hcd/10p, 5000M
/:  Bus 01.Port 1: Dev 1, Class=root_hub, Driver=xhci_hcd/16p, 480M
    |__ Port 1: Dev 2, If 0, Class=Human Interface Device, Driver=usbhid, 1.5M
    |__ Port 7: Dev 3, If 0, Class=Human Interface Device, Driver=usbhid, 12M
    |__ Port 7: Dev 3, If 1, Class=Human Interface Device, Driver=usbhid, 12M
    |__ Port 7: Dev 3, If 2, Class=Human Interface Device, Driver=usbhid, 12M
    |__ Port 11: Dev 4, If 2, Class=Vendor Specific Class, Driver=ipheth, 480M
    |__ Port 11: Dev 4, If 0, Class=Imaging, Driver=, 480M
    |__ Port 11: Dev 4, If 1, Class=Vendor Specific Class, Driver=usbfs, 480M

temp_2: (pulling it out and pluging it again)
/:  Bus 02.Port 1: Dev 1, Class=root_hub, Driver=xhci_hcd/10p, 5000M
/:  Bus 01.Port 1: Dev 1, Class=root_hub, Driver=xhci_hcd/16p, 480M
    |__ Port 1: Dev 2, If 0, Class=Human Interface Device, Driver=usbhid, 1.5M
    |__ Port 7: Dev 3, If 0, Class=Human Interface Device, Driver=usbhid, 12M
    |__ Port 7: Dev 3, If 1, Class=Human Interface Device, Driver=usbhid, 12M
    |__ Port 7: Dev 3, If 2, Class=Human Interface Device, Driver=usbhid, 12M

It seems that the usb port was disabled when I pull the phone out. Any more suggestions? Thank you for your kindness!

Last edited by cyyyyc123 (2017-08-28 11:40:41)

Offline

#5 2017-08-28 14:28:45

Archtefact
Member
Registered: 2017-05-15
Posts: 5

Re: Problem connecting IPhone on USB

Thanks a lot Starfish !

Here the obtained files :

temp_1:
/:  Bus 02.Port 1: Dev 1, Class=root_hub, Driver=xhci_hcd/4p, 5000M
/:  Bus 01.Port 1: Dev 1, Class=root_hub, Driver=xhci_hcd/11p, 480M
    |__ Port 4: Dev 2, If 0, Class=Vendor Specific Class, Driver=rtsx_usb, 480M
    |__ Port 6: Dev 3, If 0, Class=Video, Driver=uvcvideo, 480M
    |__ Port 6: Dev 3, If 1, Class=Video, Driver=uvcvideo, 480M
    |__ Port 7: Dev 4, If 0, Class=Wireless, Driver=btusb, 12M
    |__ Port 7: Dev 4, If 1, Class=Wireless, Driver=btusb, 12M


temp_2:
/:  Bus 02.Port 1: Dev 1, Class=root_hub, Driver=xhci_hcd/4p, 5000M
/:  Bus 01.Port 1: Dev 1, Class=root_hub, Driver=xhci_hcd/11p, 480M
    |__ Port 1: Dev 5, If 1, Class=Vendor Specific Class, Driver=usbfs, 480M
    |__ Port 1: Dev 5, If 2, Class=Vendor Specific Class, Driver=ipheth, 480M
    |__ Port 1: Dev 5, If 0, Class=Imaging, Driver=, 480M
    |__ Port 4: Dev 2, If 0, Class=Vendor Specific Class, Driver=rtsx_usb, 480M
    |__ Port 6: Dev 3, If 0, Class=Video, Driver=uvcvideo, 480M
    |__ Port 6: Dev 3, If 1, Class=Video, Driver=uvcvideo, 480M
    |__ Port 7: Dev 4, If 0, Class=Wireless, Driver=btusb, 12M
    |__ Port 7: Dev 4, If 1, Class=Wireless, Driver=btusb, 12M


temp_diff:
2a3,5
>     |__ Port 1: Dev 5, If 1, Class=Vendor Specific Class, Driver=usbfs, 480M
>     |__ Port 1: Dev 5, If 2, Class=Vendor Specific Class, Driver=ipheth, 480M
>     |__ Port 1: Dev 5, If 0, Class=Imaging, Driver=, 480M

Now I plugged a second time the phone and made a new diff between the first and second time I plugged it :
3,5c3,5
<     |__ Port 1: Dev 5, If 1, Class=Vendor Specific Class, Driver=usbfs, 480M
<     |__ Port 1: Dev 5, If 2, Class=Vendor Specific Class, Driver=ipheth, 480M
<     |__ Port 1: Dev 5, If 0, Class=Imaging, Driver=, 480M
---
>     |__ Port 2: Dev 16, If 2, Class=Vendor Specific Class, Driver=ipheth, 480M
>     |__ Port 2: Dev 16, If 0, Class=Imaging, Driver=, 480M
>     |__ Port 2: Dev 16, If 1, Class=Vendor Specific Class, Driver=usbfs, 480M

But I'm not sure how to interpret that and I'm again looking on it smile

Edit:
Maybe the stack assume the device was not plugged out from the port ... I note also that this problem appeared a week ago. Maybe after an IOS or a pacman update hmm

Last edited by Archtefact (2017-08-28 14:59:29)

Offline

#6 2017-08-28 17:24:55

Starfish
Member
From: Germany
Registered: 2015-10-21
Posts: 134

Re: Problem connecting IPhone on USB

@Archtefact:
To me it looks like when you detach the phone, the system doesn't realize it and keeps the device-node associated with the port, making it unusable until the next reboot.
The only solution that comes into my mind is writing your own udev rule, which could manually remove the device file and free the port as soon as you plug it out:
https://wiki.archlinux.org/index.php/Udev

Last edited by Starfish (2017-08-28 17:27:54)


"Yesterday is history, tomorrow is a mystery, but today is a gift. That is why it is called the present." - Master Oogway

Offline

#7 2017-08-28 17:30:38

Archtefact
Member
Registered: 2017-05-15
Posts: 5

Re: Problem connecting IPhone on USB

Ok !! Thxs a lot for your answer !

What you say is exactly what i though, but well said wink
The problem is I do not knew what to do to solve this problem. I'll check the link you provided and let you know.
Thxs for you time smile

Offline

#8 2017-08-29 06:10:26

cyyyyc123
Member
Registered: 2017-03-03
Posts: 6

Re: Problem connecting IPhone on USB

I find an interesting thing. After pull the device out, 'usbmuxd' is killed. If I run 'sudo usbmuxd -f' again, the device can be recognized when plug it in the usb port.

Offline

#9 2017-08-29 06:28:36

cyyyyc123
Member
Registered: 2017-03-03
Posts: 6

Re: Problem connecting IPhone on USB

I just find a wordaround. The udev rule of usbmuxd (in /lib/udev/rules.d/39-usbmuxd.rules) is as following:

============================================================
# usbmuxd (Apple Mobile Device Muxer listening on /var/run/usbmuxd)
 
# Initialize iOS devices into "deactivated" USB configuration state and activate usbmuxd
ACTION=="add", SUBSYSTEM=="usb", ATTR{idVendor}=="05ac", ATTR{idProduct}=="12[9a][0-9a-f]", ENV{USBMUX_SUPPORTED}="1", ATTR{bConfigurationValue}="0", OWNER="usbmux", TAG+="systemd", ENV{SYSTEMD_WANTS}="usbmuxd.service"

# Exit usbmuxd when the last device is removed
ACTION=="remove", SUBSYSTEM=="usb", ENV{PRODUCT}=="5ac/12[9a][0-9a-f]/*", ENV{INTERFACE}=="255/*", RUN+="/usr/bin/usbmuxd -x"
============================================================


It seems that when the last device is removed, the usbmuxd will exit automatically. So I comment out the last line of this file, then my phone can be recognized at everytime it is pluged in.

Last edited by cyyyyc123 (2017-08-29 06:29:05)

Offline

#10 2017-08-29 12:09:05

Archtefact
Member
Registered: 2017-05-15
Posts: 5

Re: Problem connecting IPhone on USB

Hi cyyyyc123,

sudo usbmuxd -f works also for me, but I already had the same udev rule you posted, in in /lib/udev/rules.d/39-usbmuxd.rules ...

Thanks a lot for sharing smile

[EDIT] : Ok I had not red carefully your post, the workaround you posted seem to work also in my case. Thanks smile

Last edited by Archtefact (2017-08-29 19:03:10)

Offline

Board footer

Powered by FluxBB