Dear Heikki,
Am 22.11.23 um 09:56 schrieb Heikki Krogerus:
On Tue, Nov 21, 2023 at 03:25:59PM +0100, Paul Menzel wrote:
Am 21.11.23 um 15:08 schrieb Heikki Krogerus:
On Tue, Nov 21, 2023 at 12:50:43PM +0100, Paul Menzel wrote:
On the Dell XPS 13, BIOS 2.21.0 06/02/2022, with Debian sid/unstable and
Linux 6.5.10, when unplugging the (Dell) USB Type-C charger cable, Linux
logs the error below:
ucsi_acpi USBC000:00: ucsi_handle_connector_change: ACK failed (-110)
As this is logged with level error, can this be somehow fixed?
drivers/usb/typec/ucsi/ucsi.c: dev_err(ucsi->dev, "%s: ACK failed (%d)", __func__, ret);
Please find the output of `dmesg` attached.
Thanks. The firmware not reacting to the ACK command is weird, but I'm
not sure if it's critical. Does the interface continue working after
that? Do you see the partner devices appearing under /sys/class/typec/
when you plug them, and disappearing when you unplug them?
```
$ LANG= grep . /sys/class/typec/port0/device/power_supply/ucsi-source-psy-USBC000\:001/*
/sys/class/typec/port0/device/power_supply/ucsi-source-psy-USBC000:001/current_max:0
/sys/class/typec/port0/device/power_supply/ucsi-source-psy-USBC000:001/current_now:0
[…]
```
Now I unplugged the device, and the error is *not* logged. (I had a USB
Type-C port replicator plugged in during the day before.)
The directory is still there:
```
$ LANG= grep . /sys/class/typec/port0/device/power_supply/ucsi-source-psy-USBC000\:001/*
/sys/class/typec/port0/device/power_supply/ucsi-source-psy-USBC000:001/current_max:0
/sys/class/typec/port0/device/power_supply/ucsi-source-psy-USBC000:001/current_now:0
[…]
```
I guess, that is the wrong directory I look at though?
(I am going to monitor the logs over the next days.)
Just list what you have in /sys/class/typec/ before and after plugging
a device to the port:
ls /sys/class/typec/
Sorry, here you go:
With charger:
$ ls /sys/class/typec/
port0 port0-partner
After unplugging the charger:
$ LANG= ls /sys/class/typec/
port0
By the way, Linux logs the ucsi_handle_connector_change line around five
second after unplugging the USB Type-C charger cable.
Kind regards,
Paul
PS: In the logs since October 30th, I see the three distinct lines below:
1. ucsi_acpi USBC000:00: failed to re-enable notifications (-110)
2. ucsi_acpi USBC000:00: GET_CONNECTOR_STATUS failed (-110)
3. ucsi_acpi USBC000:00: ucsi_handle_connector_change: ACK failed (-110)
Is it documented somewhere what -100 means?