[PATCH v10 01/11] usb: typec: Add notifier functions
Chaoyi Chen
chaoyi.chen at rock-chips.com
Tue Nov 25 17:46:19 PST 2025
On 11/25/2025 7:49 PM, Greg Kroah-Hartman wrote:
>> +static umode_t typec_is_visible(struct kobject *kobj, struct attribute *attr, int n)
>> +{
>> + if (is_typec_port(kobj_to_dev(kobj)->parent))
>
> Why look at the parent? Doesn't the device have a type that should show
> this?
>
> Otherwise, looks good to me.
They have same deivce type "typec_altmode_dev_type".
The parent device has a different device type to distinguish between
port device and partner device.
>
> thanks,
>
> greg k-h
>
>
--
Best,
Chaoyi
More information about the Linux-rockchip
mailing list