Unable to reset USB LTE modem after -EPROTO error
up vote
1
down vote
favorite
BLUF
I can no longer toggle the power of an LTE Modem via sysfs because it is now being removed from sysfs after an error occurs. How can I get it back into the usb sysfs and toggle the power?
Background
I am using an USB LTE modem with the qmi-based drivers that infrequently experiences an error that requires a reset. In the past I have been able to fix it by toggling power to it via the sysfs as seen below:
echo "0" > /sys/bus/usb/devices/usb2/2-1/power/autosuspend_delay_ms
echo "auto" > /sys/bus/usb/devices/usb2/2-1/power/control
sleep 1
echo "0" > /sys/bus/usb/devices/usb2/2-1/power/autosuspend
sleep 1
echo "2-1" > /sys/bus/usb/drivers/usb/unbind
sleep 1
echo "2-1" > /sys/bus/usb/drivers/usb/bind
sleep 1
Not ideal, but workable. The problem is that that after migrating to the 4.14 kernel, I cannot find the device in the sysfs after an error, /sys/bus/usb/devices/usb2/2-1
does not exist, and therefor I cannot reset the modem with it. The dmesg
output at the time of the error is the following:
[1889271.903016] qmi_wwan 2-1:1.8: nonzero urb status received: -71
[1889271.903039] qmi_wwan 2-1:1.8: wdm_int_callback - 0 bytes
[1889274.174239] usb 2-1: USB disconnect, device number 2
[1889274.185873] qcserial ttyUSB0: Qualcomm USB modem converter now disconnected from ttyUSB0
[1889274.186457] qcserial 2-1:1.0: device disconnected
[1889274.188294] qcserial ttyUSB1: Qualcomm USB modem converter now disconnected from ttyUSB1
[1889274.188916] qcserial 2-1:1.2: device disconnected
[1889274.206507] qcserial ttyUSB2: Qualcomm USB modem converter now disconnected from ttyUSB2
[1889274.211120] qcserial 2-1:1.3: device disconnected
[1889274.220564] qmi_wwan 2-1:1.8 wwan0: unregister 'qmi_wwan' usb-ci_hdrc.1-1, WWAN/QMI device
[1889274.263106] qmi_wwan 2-1:1.10 wwan1: unregister 'qmi_wwan' usb-ci_hdrc.1-1, WWAN/QMI device
The error 71 corresponds to an EPROTO
error, which from what i read triggers the kernel to disable the port. I'd like to know how to re-enable to port so it appears back in the USB section of sysfs so I can toggle its power.
linux usb linux-device-driver embedded-linux sysfs
add a comment |
up vote
1
down vote
favorite
BLUF
I can no longer toggle the power of an LTE Modem via sysfs because it is now being removed from sysfs after an error occurs. How can I get it back into the usb sysfs and toggle the power?
Background
I am using an USB LTE modem with the qmi-based drivers that infrequently experiences an error that requires a reset. In the past I have been able to fix it by toggling power to it via the sysfs as seen below:
echo "0" > /sys/bus/usb/devices/usb2/2-1/power/autosuspend_delay_ms
echo "auto" > /sys/bus/usb/devices/usb2/2-1/power/control
sleep 1
echo "0" > /sys/bus/usb/devices/usb2/2-1/power/autosuspend
sleep 1
echo "2-1" > /sys/bus/usb/drivers/usb/unbind
sleep 1
echo "2-1" > /sys/bus/usb/drivers/usb/bind
sleep 1
Not ideal, but workable. The problem is that that after migrating to the 4.14 kernel, I cannot find the device in the sysfs after an error, /sys/bus/usb/devices/usb2/2-1
does not exist, and therefor I cannot reset the modem with it. The dmesg
output at the time of the error is the following:
[1889271.903016] qmi_wwan 2-1:1.8: nonzero urb status received: -71
[1889271.903039] qmi_wwan 2-1:1.8: wdm_int_callback - 0 bytes
[1889274.174239] usb 2-1: USB disconnect, device number 2
[1889274.185873] qcserial ttyUSB0: Qualcomm USB modem converter now disconnected from ttyUSB0
[1889274.186457] qcserial 2-1:1.0: device disconnected
[1889274.188294] qcserial ttyUSB1: Qualcomm USB modem converter now disconnected from ttyUSB1
[1889274.188916] qcserial 2-1:1.2: device disconnected
[1889274.206507] qcserial ttyUSB2: Qualcomm USB modem converter now disconnected from ttyUSB2
[1889274.211120] qcserial 2-1:1.3: device disconnected
[1889274.220564] qmi_wwan 2-1:1.8 wwan0: unregister 'qmi_wwan' usb-ci_hdrc.1-1, WWAN/QMI device
[1889274.263106] qmi_wwan 2-1:1.10 wwan1: unregister 'qmi_wwan' usb-ci_hdrc.1-1, WWAN/QMI device
The error 71 corresponds to an EPROTO
error, which from what i read triggers the kernel to disable the port. I'd like to know how to re-enable to port so it appears back in the USB section of sysfs so I can toggle its power.
linux usb linux-device-driver embedded-linux sysfs
It’s not a programming question, what you need to do is to take Linux kernel sources from Git, compile enough times to bisect down to the changing commit and report to corresponding developers. Not easy for newbie, unfortunately.
– 0andriy
Nov 21 at 8:13
I’m not so concerned about the EPROTO error coming from the device driver, which would require the debug method you outlined to fix, but the core mechanism of a USB node being removed from the sysfs (for whatever reason) and how to at least attempt to re-add it to sysfs. If I just had access to the VBUS enable pin for a moment, I can force the client device to reset.
– Liam Kelly
Nov 25 at 15:01
add a comment |
up vote
1
down vote
favorite
up vote
1
down vote
favorite
BLUF
I can no longer toggle the power of an LTE Modem via sysfs because it is now being removed from sysfs after an error occurs. How can I get it back into the usb sysfs and toggle the power?
Background
I am using an USB LTE modem with the qmi-based drivers that infrequently experiences an error that requires a reset. In the past I have been able to fix it by toggling power to it via the sysfs as seen below:
echo "0" > /sys/bus/usb/devices/usb2/2-1/power/autosuspend_delay_ms
echo "auto" > /sys/bus/usb/devices/usb2/2-1/power/control
sleep 1
echo "0" > /sys/bus/usb/devices/usb2/2-1/power/autosuspend
sleep 1
echo "2-1" > /sys/bus/usb/drivers/usb/unbind
sleep 1
echo "2-1" > /sys/bus/usb/drivers/usb/bind
sleep 1
Not ideal, but workable. The problem is that that after migrating to the 4.14 kernel, I cannot find the device in the sysfs after an error, /sys/bus/usb/devices/usb2/2-1
does not exist, and therefor I cannot reset the modem with it. The dmesg
output at the time of the error is the following:
[1889271.903016] qmi_wwan 2-1:1.8: nonzero urb status received: -71
[1889271.903039] qmi_wwan 2-1:1.8: wdm_int_callback - 0 bytes
[1889274.174239] usb 2-1: USB disconnect, device number 2
[1889274.185873] qcserial ttyUSB0: Qualcomm USB modem converter now disconnected from ttyUSB0
[1889274.186457] qcserial 2-1:1.0: device disconnected
[1889274.188294] qcserial ttyUSB1: Qualcomm USB modem converter now disconnected from ttyUSB1
[1889274.188916] qcserial 2-1:1.2: device disconnected
[1889274.206507] qcserial ttyUSB2: Qualcomm USB modem converter now disconnected from ttyUSB2
[1889274.211120] qcserial 2-1:1.3: device disconnected
[1889274.220564] qmi_wwan 2-1:1.8 wwan0: unregister 'qmi_wwan' usb-ci_hdrc.1-1, WWAN/QMI device
[1889274.263106] qmi_wwan 2-1:1.10 wwan1: unregister 'qmi_wwan' usb-ci_hdrc.1-1, WWAN/QMI device
The error 71 corresponds to an EPROTO
error, which from what i read triggers the kernel to disable the port. I'd like to know how to re-enable to port so it appears back in the USB section of sysfs so I can toggle its power.
linux usb linux-device-driver embedded-linux sysfs
BLUF
I can no longer toggle the power of an LTE Modem via sysfs because it is now being removed from sysfs after an error occurs. How can I get it back into the usb sysfs and toggle the power?
Background
I am using an USB LTE modem with the qmi-based drivers that infrequently experiences an error that requires a reset. In the past I have been able to fix it by toggling power to it via the sysfs as seen below:
echo "0" > /sys/bus/usb/devices/usb2/2-1/power/autosuspend_delay_ms
echo "auto" > /sys/bus/usb/devices/usb2/2-1/power/control
sleep 1
echo "0" > /sys/bus/usb/devices/usb2/2-1/power/autosuspend
sleep 1
echo "2-1" > /sys/bus/usb/drivers/usb/unbind
sleep 1
echo "2-1" > /sys/bus/usb/drivers/usb/bind
sleep 1
Not ideal, but workable. The problem is that that after migrating to the 4.14 kernel, I cannot find the device in the sysfs after an error, /sys/bus/usb/devices/usb2/2-1
does not exist, and therefor I cannot reset the modem with it. The dmesg
output at the time of the error is the following:
[1889271.903016] qmi_wwan 2-1:1.8: nonzero urb status received: -71
[1889271.903039] qmi_wwan 2-1:1.8: wdm_int_callback - 0 bytes
[1889274.174239] usb 2-1: USB disconnect, device number 2
[1889274.185873] qcserial ttyUSB0: Qualcomm USB modem converter now disconnected from ttyUSB0
[1889274.186457] qcserial 2-1:1.0: device disconnected
[1889274.188294] qcserial ttyUSB1: Qualcomm USB modem converter now disconnected from ttyUSB1
[1889274.188916] qcserial 2-1:1.2: device disconnected
[1889274.206507] qcserial ttyUSB2: Qualcomm USB modem converter now disconnected from ttyUSB2
[1889274.211120] qcserial 2-1:1.3: device disconnected
[1889274.220564] qmi_wwan 2-1:1.8 wwan0: unregister 'qmi_wwan' usb-ci_hdrc.1-1, WWAN/QMI device
[1889274.263106] qmi_wwan 2-1:1.10 wwan1: unregister 'qmi_wwan' usb-ci_hdrc.1-1, WWAN/QMI device
The error 71 corresponds to an EPROTO
error, which from what i read triggers the kernel to disable the port. I'd like to know how to re-enable to port so it appears back in the USB section of sysfs so I can toggle its power.
linux usb linux-device-driver embedded-linux sysfs
linux usb linux-device-driver embedded-linux sysfs
asked Nov 19 at 19:08
Liam Kelly
1,444816
1,444816
It’s not a programming question, what you need to do is to take Linux kernel sources from Git, compile enough times to bisect down to the changing commit and report to corresponding developers. Not easy for newbie, unfortunately.
– 0andriy
Nov 21 at 8:13
I’m not so concerned about the EPROTO error coming from the device driver, which would require the debug method you outlined to fix, but the core mechanism of a USB node being removed from the sysfs (for whatever reason) and how to at least attempt to re-add it to sysfs. If I just had access to the VBUS enable pin for a moment, I can force the client device to reset.
– Liam Kelly
Nov 25 at 15:01
add a comment |
It’s not a programming question, what you need to do is to take Linux kernel sources from Git, compile enough times to bisect down to the changing commit and report to corresponding developers. Not easy for newbie, unfortunately.
– 0andriy
Nov 21 at 8:13
I’m not so concerned about the EPROTO error coming from the device driver, which would require the debug method you outlined to fix, but the core mechanism of a USB node being removed from the sysfs (for whatever reason) and how to at least attempt to re-add it to sysfs. If I just had access to the VBUS enable pin for a moment, I can force the client device to reset.
– Liam Kelly
Nov 25 at 15:01
It’s not a programming question, what you need to do is to take Linux kernel sources from Git, compile enough times to bisect down to the changing commit and report to corresponding developers. Not easy for newbie, unfortunately.
– 0andriy
Nov 21 at 8:13
It’s not a programming question, what you need to do is to take Linux kernel sources from Git, compile enough times to bisect down to the changing commit and report to corresponding developers. Not easy for newbie, unfortunately.
– 0andriy
Nov 21 at 8:13
I’m not so concerned about the EPROTO error coming from the device driver, which would require the debug method you outlined to fix, but the core mechanism of a USB node being removed from the sysfs (for whatever reason) and how to at least attempt to re-add it to sysfs. If I just had access to the VBUS enable pin for a moment, I can force the client device to reset.
– Liam Kelly
Nov 25 at 15:01
I’m not so concerned about the EPROTO error coming from the device driver, which would require the debug method you outlined to fix, but the core mechanism of a USB node being removed from the sysfs (for whatever reason) and how to at least attempt to re-add it to sysfs. If I just had access to the VBUS enable pin for a moment, I can force the client device to reset.
– Liam Kelly
Nov 25 at 15:01
add a comment |
active
oldest
votes
active
oldest
votes
active
oldest
votes
active
oldest
votes
active
oldest
votes
Thanks for contributing an answer to Stack Overflow!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Some of your past answers have not been well-received, and you're in danger of being blocked from answering.
Please pay close attention to the following guidance:
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53381106%2funable-to-reset-usb-lte-modem-after-eproto-error%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
It’s not a programming question, what you need to do is to take Linux kernel sources from Git, compile enough times to bisect down to the changing commit and report to corresponding developers. Not easy for newbie, unfortunately.
– 0andriy
Nov 21 at 8:13
I’m not so concerned about the EPROTO error coming from the device driver, which would require the debug method you outlined to fix, but the core mechanism of a USB node being removed from the sysfs (for whatever reason) and how to at least attempt to re-add it to sysfs. If I just had access to the VBUS enable pin for a moment, I can force the client device to reset.
– Liam Kelly
Nov 25 at 15:01