Received: by 2002:ab2:7407:0:b0:1f4:b336:87c4 with SMTP id e7csp59733lqn; Thu, 11 Apr 2024 13:52:51 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCXvgHaU3gaA48RNL2WGtkQuP+A364WVRGusPHw4WcQgzgyoSpNpTmwhce9kwvl6/v9bBLiwRsOZYYZSBpebVwLYjNjF2zdvKw1xi+CNaw== X-Google-Smtp-Source: AGHT+IFT89kNZ4okPJnG/IWvm1DoFlqaAKdmQGnkdhfafDNgXv6x2i4ojiQNbOEfev7d+5r9Sxwg X-Received: by 2002:ad4:5582:0:b0:699:2674:929e with SMTP id f2-20020ad45582000000b006992674929emr838937qvx.10.1712868771681; Thu, 11 Apr 2024 13:52:51 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1712868771; cv=pass; d=google.com; s=arc-20160816; b=OYNY22UKsHnBeBWXoE8K0LjLww+x8mE4G01deme/7KF3up2p8CU3++TLAuHjZJ5Pt9 5V7wXHqdJ/momTpcP2KAboKIHE+UTn6lPM6KV/eap/i0y9rmzMTTlXCTuFXwC3RTduoW OpS5gHrPIMJnNnryHD8cB6LxX12YdYvXhIKyMgc9rTid9cuohtgolq48+04iqaM43Cn/ nQI+ou0BkwIjKuJsvFRuwrXERZGzqASZ5FfiiLlTdPCIY1L5NNs2FJpbvbMzEEEaMDyh zI9hbmLHWpnj9aJLp6oJVqM88RET2jjwGApCtOeYx43QvoGv0ltTekV9Z8Qsc41k5ITW Virw== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:in-reply-to:from:content-language :references:cc:to:subject:user-agent:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:date:message-id:dkim-signature; bh=J5dGfMryEizOv053XWps+n251C26VsvIA27q5i2uHTk=; fh=KBQ17tyAl0iu6kDMaS3mvm3OA8w+oo8Ru9OLlyCcr10=; b=q2b+uktppH0M9e2/mIwD8u8rXKaJ72NdVuyFpTS5G5NbsbJ2U7NpkzuAsdRrpkS/cO GcCNjQZ7amjHO+nM1vwcRI32qosBV25r5z28qCzTzKJeq+b8BIOf4tqiATCDlNgcPDe5 fqPh5FUvC/hm4C9kg5lnhGfg1NZw8hWsHClyRR3IEmT5OSCACisoPujCUQQpqJGYPJbe sJwbWbFccsjbXFdB+7nJ3OCepa7K0XjJ4sUKmvkjSpB1YPV03NO4QdiM3c8R0cyuqWIt SnSoME1KNTSAuIxbyFLCI0ddedMtZIIifFVotc2b6DB53zX7JPNhn/k4oZhc1FrlETvT IUcw==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=G65oDiQ6; arc=pass (i=1 spf=pass spfdomain=gmail.com dkim=pass dkdomain=gmail.com dmarc=pass fromdomain=gmail.com); spf=pass (google.com: domain of linux-kernel+bounces-141594-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-141594-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [2604:1380:45d1:ec00::1]) by mx.google.com with ESMTPS id f13-20020a0ccc8d000000b0069926b01df4si2266184qvl.298.2024.04.11.13.52.51 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 11 Apr 2024 13:52:51 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-141594-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) client-ip=2604:1380:45d1:ec00::1; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=G65oDiQ6; arc=pass (i=1 spf=pass spfdomain=gmail.com dkim=pass dkdomain=gmail.com dmarc=pass fromdomain=gmail.com); spf=pass (google.com: domain of linux-kernel+bounces-141594-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-141594-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ny.mirrors.kernel.org (Postfix) with ESMTPS id 621091C211D4 for ; Thu, 11 Apr 2024 20:52:51 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 0C6C72941F; Thu, 11 Apr 2024 20:52:42 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="G65oDiQ6" Received: from mail-ed1-f42.google.com (mail-ed1-f42.google.com [209.85.208.42]) (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 B3E0C17C8D; Thu, 11 Apr 2024 20:52:39 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.208.42 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1712868761; cv=none; b=AeQpvsqLfR1z21NmX6CC85ahcfW+oik9uI5s3AwsXVN/fd8XJFLbqJK/cTiwBDShhSrXKD7MdpJjwn0GqjbpygON6Rr4XzaQ2nL+3CwKJNu+LHGm1zxErb6LFFSDPprbo6f+QzXz0w6G5BXmJ8b3OFlvgkZXe5gVsh+Ibh26QhY= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1712868761; c=relaxed/simple; bh=JrvX8um+EbICvWw9zskL/ERHC4Vwe09tGcMdO/xTJqU=; h=Message-ID:Date:MIME-Version:Subject:To:Cc:References:From: In-Reply-To:Content-Type; b=HNPMKHTDtilQyzBNZ+RG5XLZlfwCucxZi4wE7Zpm9X94YHOGiIROKYg11GlUkp8VMQ2wUKZ2TnRmKR8unCC2YejEVE9Q1dAZqdM9CFbtrn1Rk1GBqQbHJnI0igLm+r5At4UClHpacfK657rRCoohgmPm/XoQwbHC9xM407/Avmg= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=G65oDiQ6; arc=none smtp.client-ip=209.85.208.42 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Received: by mail-ed1-f42.google.com with SMTP id 4fb4d7f45d1cf-56c5d05128dso215816a12.0; Thu, 11 Apr 2024 13:52:39 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1712868758; x=1713473558; 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=J5dGfMryEizOv053XWps+n251C26VsvIA27q5i2uHTk=; b=G65oDiQ6RFRV6x+hSkpJIJgTE4VvTRNnauWGb0oPpqBp4nUJyU+pY7h+7IbxuH5gSm qfC1CHE6zmvkUU7A4kMX/t6V+tF5MkS/JOVu5q4y0Btm20mE1V4KGZZxZ07SN77j+JAL RXeSDsa8LX7TvQbDQPfTWRzW7rI1kjX2h/W2CSp9HIXECNU0oeoNyFf1GoIC8n7yEkV3 +b6v+4pRe03KBEC+vMArhzre7E4dbjzTEU90ugb8JjRVcLYr9tyL2PxVa3HzsSXBl7Eh sXsOKpMqsCl7oge2dByExIFm137VKSFcTpfTbYPZeVWngKeg0nyN2jxWiUoVB9k+6oi3 tXpQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1712868758; x=1713473558; h=content-transfer-encoding:in-reply-to:from:content-language :references:cc:to:subject:user-agent:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=J5dGfMryEizOv053XWps+n251C26VsvIA27q5i2uHTk=; b=lhaaHtwapIAyurkk4aaafEl0CLwYFARgliWxdbMRP1TdX2k3cI/fkN2DrncJD50Kdi +Lb4wIWNSip9pIPc6Z58c59XJ+mEn/+2/zs+q/HNwUDo1nOFkWOx4WVNjTqNozC/a6xD AuKWboHDbJVZryLCSQF45QKQ3OYZEFD3qbbF96ZHghcbATjgwrkxfeARAvZ8oqQsfuDU s9Ve2KuqiSmO19+NmelzntyT1aen4GNeQKBA8pkT5OkxrKISxLUoOLAcggbua1Wg/QOn oySiqqeVblXGe2vl5J3HDsNXi5AVOaCgms4RDWPmma93GjaddBND9H0jzFNZIJeEyuRD NM6Q== X-Forwarded-Encrypted: i=1; AJvYcCUuSydR7bBqJYIw7AU4kNjvL4o4pDcjRsX9r0Yt8nIiTSc2uXxr6px/9PR52pQJgckbEsCM2WbMlPfR+AV/wpgfjZyoyJ+XzSXG0S22z9qCuViHtb3OCHSnAsAuPHgFMCXHkbf2ViK7 X-Gm-Message-State: AOJu0Yz496tqoO2JZPAku4i5lt9o1BAr4LL4qFtdUVcmReL5a//Teg0/ XwjQwbgZUzCfw+c+N4MHnXYev4CFwAT5LDNW2LySu7lwo+feUNb8 X-Received: by 2002:a50:9317:0:b0:56e:2add:12eb with SMTP id m23-20020a509317000000b0056e2add12ebmr492478eda.13.1712868757791; Thu, 11 Apr 2024 13:52:37 -0700 (PDT) Received: from ?IPV6:2a02:a466:68ed:1:56f0:b227:d4c1:42e7? (2a02-a466-68ed-1-56f0-b227-d4c1-42e7.fixed6.kpn.net. [2a02:a466:68ed:1:56f0:b227:d4c1:42e7]) by smtp.gmail.com with ESMTPSA id n18-20020a05640204d200b0056fed8e7817sm620670edw.20.2024.04.11.13.52.37 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Thu, 11 Apr 2024 13:52:37 -0700 (PDT) Message-ID: Date: Thu, 11 Apr 2024 22:52:36 +0200 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 v4] usb: gadget: u_ether: Replace netif_stop_queue with netif_device_detach To: Andy Shevchenko , Hardik Gajjar Cc: gregkh@linuxfoundation.org, s.hauer@pengutronix.de, jonathanh@nvidia.com, linux-usb@vger.kernel.org, linux-kernel@vger.kernel.org, quic_linyyuan@quicinc.com, paul@crapouillou.net, quic_eserrao@quicinc.com, erosca@de.adit-jv.com References: <20231006153808.9758-1-hgajjar@de.adit-jv.com> <20231006155646.12938-1-hgajjar@de.adit-jv.com> <20240115132720.GA98840@vmlxhi-118.adit-jv.com> <20240405113855.GA121923@vmlxhi-118.adit-jv.com> <321e908e-0d10-4e36-8dc4-6997c73fe2eb@gmail.com> <20240411142637.GA110162@vmlxhi-118.adit-jv.com> Content-Language: en-US From: Ferry Toth In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit Hi Op 11-04-2024 om 18:39 schreef Andy Shevchenko: > On Thu, Apr 11, 2024 at 04:26:37PM +0200, Hardik Gajjar wrote: >> On Wed, Apr 10, 2024 at 08:37:42PM +0300, Andy Shevchenko wrote: >>> On Sun, Apr 07, 2024 at 10:51:51PM +0200, Ferry Toth wrote: >>>> Op 05-04-2024 om 13:38 schreef Hardik Gajjar: > ... > >>>> Exactly. And this didn't happen before the 2 patches. >>>> >>>> To be precise: /sys/class/net/usb0 is not removed and it is a link, the link >>>> target /sys/devices/pci0000:00/0000:00:11.0/dwc3.0.auto/gadget.0/net/usb0 no >>>> longer exists >> So, it means that the /sys/class/net/usb0 is present, but the symlink is >> broken. In that case, the dwc3 driver should recreate the device, and the >> symlink should become active again Yes, on first enabling gadget (when device mode is activated): root@yuna:~# ls /sys/devices/pci0000:00/0000:00:11.0/dwc3.0.auto/gadget.0/ driver  net  power  sound  subsystem  suspended  uevent Then switching to host mode: root@yuna:~# ls /sys/devices/pci0000:00/0000:00:11.0/dwc3.0.auto/gadget.0/ ls: cannot access '/sys/devices/pci0000:00/0000:00:11.0/dwc3.0.auto/gadget.0/': No such file or directory Then back to device mode: root@yuna:~# ls /sys/devices/pci0000:00/0000:00:11.0/dwc3.0.auto/gadget.0/ driver  power  sound  subsystem  suspended  uevent net is missing. But, network functions: root@yuna:~# ping 10.42.0.1 PING 10.42.0.1 (10.42.0.1): 56 data bytes Mass storage device is created and removed each time as expected. >> I have the dwc3 IP base usb controller, Let me check with this patch and >> share result here. May be we need some fix in dwc3 Would have been nice if someone could test on other controller as well. But another instance of dwc3 is also very welcome. > It's quite possible, please test on your side. > We are happy to test any fixes if you come up with. >