From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-wm1-f48.google.com (mail-wm1-f48.google.com [209.85.128.48]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 2342134EF05 for ; Mon, 23 Feb 2026 12:56:03 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.128.48 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1771851364; cv=none; b=vDUGi9Bfh5UXMCB0IcmEc8cuCAS5hdxxFchFjzr+mH9I/XQ5M1RC+96zJ1soXhS3Z58tTxUqzY/QXz/yQHHDu194xEMNzPGlDcG5q65Q94P0fMIJZ5dTDLfHnGUFDC0agHuGz9lyjKJbHyJ5XaxjxCRjDDCD2FB3OYzU34DHAjc= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1771851364; c=relaxed/simple; bh=Xl/HdZ0Xz7pnVC0/2kX9AhiqVRoMrSVXH9WW0P3Rnzg=; h=Message-ID:Date:MIME-Version:Subject:To:Cc:References:From: In-Reply-To:Content-Type; b=FezUHQAE/vKevVnWKKbRmCbXunWT3c1157wasUlEoQXJ4xOzZ59ct/EdPaVIGkJleNXyHBbWtrfi3HAp4vBL8YvgqUeTQkxR1G9LfiWVTq9qa5AxJivhM9wg9nWBf4zmkqytNIk3cdODUTFihOQRCBwqMTY1CEnKfR6MDBu0G3E= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=suse.com; spf=pass smtp.mailfrom=suse.com; dkim=pass (2048-bit key) header.d=suse.com header.i=@suse.com header.b=MPDy00UQ; arc=none smtp.client-ip=209.85.128.48 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=suse.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=suse.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=suse.com header.i=@suse.com header.b="MPDy00UQ" Received: by mail-wm1-f48.google.com with SMTP id 5b1f17b1804b1-4806cc07ce7so40394595e9.1 for ; Mon, 23 Feb 2026 04:56:02 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.com; s=google; t=1771851361; x=1772456161; darn=vger.kernel.org; h=content-transfer-encoding:in-reply-to:from:content-language :references:cc:to:subject:user-agent:mime-version:date:message-id :from:to:cc:subject:date:message-id:reply-to; bh=9Akf89EDkdJqcKB70GP7i70JWOZbBgZZx2ziMdQHjMY=; b=MPDy00UQz951Con8mK7H+qJWCnThliNXoKVEKwVkD38HBKOkWI5oojR2byMdvRHdJn 64Rw1Yzqxmw2n02+msNbWxC4vDdkFS64MpeMXidu+LLuATD38Y4ZwfIs+8F/BesOwlAI RDhFrHIZa5fj7ksPF8okrGrwsgYATNmmsZwcpIQ8tfV9IRN4zn5TQ8q3HIVdrXl5eSsj rrAmh68oG6M3m0o6FzZNHDPJ+5bKCcS6LkSvu5SluE1i6OZStWKolbd/BOmOsUkBTlAu Y4R51kgr9qeJAHgy/zAEBrV1T8Ra1qfZQCi0bhlaE1JLDQLnU6TIrtEXQ00KXfEsO9+/ sSIw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1771851361; x=1772456161; h=content-transfer-encoding:in-reply-to:from:content-language :references:cc:to:subject:user-agent:mime-version:date:message-id :x-gm-gg:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=9Akf89EDkdJqcKB70GP7i70JWOZbBgZZx2ziMdQHjMY=; b=vi0hpA2PnpGOABxR+FrRuYldTMerBtR/+Y76ZvifdFBmQwRmGfcyUvXI/ekGJxOnht jHA/eoAp0bz8Z3MzP+rXvwvjdJMARSDJZMtnApBih369iBMpbCodnT74iqZzeNbarMMn dS5sUXx9E02/kO4zITRquIJWxgM6PP8+Yww0+0AZGH23zLxg+XNX+mi+ZM4eKBHzZUHn T0wJQAHCiW3NJvoxNihYEa1zQCJCU1j4mQslpIxLU7gL99qcJM/IXa8Es4PKRrvQ5sfR AJl0d/49eVZmPb1UKOXC/QdAMA3Oap2J/hlQ4df4Imq/rqbDVOEAhzeCEvbVAF5a3uQd RA5Q== X-Forwarded-Encrypted: i=1; AJvYcCULX0Q2A8s4xpXGJ3cprT5PqYqgPc2l6r7v2boN5r9i9Gpvg9ve9+Rl0fFSgon6msSDqG3GnUSMlUGbX6Y=@vger.kernel.org X-Gm-Message-State: AOJu0YxE986FnpFkadbPLZsjCbbPAmn3iZwj4tz9b/WQ0QlTkLL5bOWG oo6H47aMHTa4KkCUvN3iipQYYe3aH8R73z8Oc/icPUyGlMavkbnDN1FfbyU0k8UZqgQ= X-Gm-Gg: AZuq6aLygY7bScGD/zjjVDLQupRSIgx6S+zqXGIkhQOWHR7JYV9nBjpTfytMqP/yxL3 w0vQAtEemaeVTqVzTk6dbbA7w8uR3LDOvThh/P1m+KP1uoDhlIA+U+zl4culAnchRR53N1c+wpS zM8qIlx42qS6FPt8VvIahY5CyRu+XgtO2bZHRQVjnmOObt4iBabItzkNJs18IwZYwJJoZOyDcai SbFr9yr9C+ST1Nmsv1Ix7wiYgyVTL0PaprbV19jihAAIr4D4lUgk80XnoHWGEpGzOGx7Q5bFk+n UJzQ0EmzQ1rRdCMtAgKHMmpOv5974ObHtP85U0vRdL9e8d8AQhWO/dd9eGPo2w9NpU0ZXowFMtT +LlAW4qZr44YRmbdQbsCnzO4tTpYcgJVS7NLW4SdCEoTVPJR8MeJzmo5UO2+0JJy2MrFFv6YT9W Zt92JxORsrbrSgP3W2yql3PqBahSMA7yatdwExdN3U76P9xdHstNpoGhxujRm5rEHewro68c8KE bWNHw== X-Received: by 2002:a05:600c:3e8d:b0:46e:761b:e7ff with SMTP id 5b1f17b1804b1-483a95f5a48mr131674475e9.28.1771851361497; Mon, 23 Feb 2026 04:56:01 -0800 (PST) Received: from ?IPV6:2001:a61:13fe:e401:a6d6:a7a0:a277:a99e? ([2001:a61:13fe:e401:a6d6:a7a0:a277:a99e]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-483a31f0370sm461207825e9.11.2026.02.23.04.56.01 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Mon, 23 Feb 2026 04:56:01 -0800 (PST) Message-ID: <1ff10cd4-d3bb-4c9e-9164-056b04b55473@suse.com> Date: Mon, 23 Feb 2026 13:55:55 +0100 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH v2] usb: misc: uss720: properly clean up reference in uss720_probe() To: Greg Kroah-Hartman , Oliver Neukum Cc: linux-usb@vger.kernel.org, linux-kernel@vger.kernel.org, stable References: <2026022327-exhaust-constrain-e21d@gregkh> <04778e0c-e15c-4acd-ade2-5cb8dc4319b1@suse.com> <2026022316-strobe-zombie-335f@gregkh> Content-Language: en-US From: Oliver Neukum In-Reply-To: <2026022316-strobe-zombie-335f@gregkh> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit On 23.02.26 13:14, Greg Kroah-Hartman wrote: > It's tricky stuff like this which makes me can't wait for rust to be > possible for USB drivers, someday... Well, as you wish to touch upon that topic ... I am afraid this is not a problem of language. Rust solves the issue of object life time. Unfortunately that is useless in this case. I know we all wish to solve the issue, but let me explain. Now, before you either start despairing or get angry, we need to look at concepts. It seems to my you're looking at the problem in terms of life time and basically something that can be solved by reference counting respectively life time rules. That is unfortunately not true. Our problem with USB drivers is a question of binding. probe() does not mean that a device has been plugged in, nor does disconnect() mean that a device has gone away. It means that the binding between an interface and a driver is requested respectively goes away. Hotplug is merely the most common cause of these requests. Nevertheless you have to cease using the interface as disconnect() is called. References cannot change that. There are two reasons for that a) there is no object representing the binding. It is technically a pointer not a data structure. There is nothing to refcount and no object whose lifetime you can specify. There is a variable that is changing b) there is a state transition, not a life time question. There is an event that changes the state of a binding if you will. Sorry you don't like this, but this is a design issue, not a language issue. Regards Oliver