Received: by 2002:a05:7412:419a:b0:f3:1519:9f41 with SMTP id i26csp3152949rdh; Mon, 27 Nov 2023 07:31:39 -0800 (PST) X-Google-Smtp-Source: AGHT+IEjxWujLL/jQfZ8LpzRUSCu1bx2SByb0JBV5QmrlYJ496SvCIgsp52MzOJzO5Qonx3VfN8J X-Received: by 2002:a17:90b:1650:b0:285:34c4:a0c8 with SMTP id il16-20020a17090b165000b0028534c4a0c8mr10256617pjb.39.1701099099362; Mon, 27 Nov 2023 07:31:39 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1701099099; cv=none; d=google.com; s=arc-20160816; b=oCaRJb3ppgWk9qtMWKxmq9r6noLLTSegipgq0eGo88bMO5QZFqQWXqv2hBTghYEwNE /7ycmgvAfnD6WMcNqmTtVTQMsiVI52gkX1oeG1Hc2BbYyAblsk6pYsQKWOH8VdfGPX+X dEwTSXlVhfRQIqW1evKSSkdGKh/Jj1l3IyjGUqPIs7VmgvsSZq7gZobrlOxXA0RncGTk UrelRBEgLfglagTisE06JQls2ca/AIz7QY//qMaDY2qquPcx/lDAPCUMe6Dyptg/VgmB WUI6TJUa5qxzfOOMT5vRvDlm2bpjhV4pYrzYjNMFNU5Ihzn/Ruso41Zxj8zOdMSX84IB q27A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-transfer-encoding :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=0nEvDUTA+VvuaYc5IvEcHoTln/14hfyXc63Vrf+U23o=; fh=T3DHuA7AoQucbSf7mTzTTBhkgM7QT36HhmX9iK9qnUI=; b=dN/w+iBbPhqZ4oxIkvmbbSQtk0wniBhQ0zZ2T/f2fR+e823Racq5hqIwrMd6HUEcaq FxY0ukBWr9ZRVwSoSBnFkTTewg2Nuf29h0i0ywMdgboSFL3QMZORe/TRaMtWFuAx2WwT DvxFePsC/Dh5I7/hoK6T3/qZrCgLC4J8I6+/l/GoSPposEdizLjuR9y5EEsq0Gy0B4tI 8zzzsnDk6PmyX55TkdntdL+By5L0hXuo4XCJmPuGX6M3BhYosLmQdbD5mr6kPN2IGIl3 U8U80yrhfahIYN/oJUSEzYtCrAv9q+RmToID4lHLwGsvc18/ZkH1s/dE+hNXuvSmesrs 16kw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@ferroamp-se.20230601.gappssmtp.com header.s=20230601 header.b=TdaqAdOH; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.31 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from morse.vger.email (morse.vger.email. [23.128.96.31]) by mx.google.com with ESMTPS id q16-20020a631f50000000b00578c8ce14edsi9788750pgm.252.2023.11.27.07.31.37 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 27 Nov 2023 07:31:39 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.31 as permitted sender) client-ip=23.128.96.31; Authentication-Results: mx.google.com; dkim=pass header.i=@ferroamp-se.20230601.gappssmtp.com header.s=20230601 header.b=TdaqAdOH; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.31 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by morse.vger.email (Postfix) with ESMTP id 3580780BEF3F; Mon, 27 Nov 2023 07:31:35 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at morse.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233948AbjK0PbT (ORCPT + 99 others); Mon, 27 Nov 2023 10:31:19 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:59002 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233775AbjK0Pas (ORCPT ); Mon, 27 Nov 2023 10:30:48 -0500 Received: from mail-lf1-x12b.google.com (mail-lf1-x12b.google.com [IPv6:2a00:1450:4864:20::12b]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 3CE6F1988 for ; Mon, 27 Nov 2023 07:30:38 -0800 (PST) Received: by mail-lf1-x12b.google.com with SMTP id 2adb3069b0e04-507a29c7eefso5700548e87.1 for ; Mon, 27 Nov 2023 07:30:38 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ferroamp-se.20230601.gappssmtp.com; s=20230601; t=1701099036; x=1701703836; darn=vger.kernel.org; h=in-reply-to:content-transfer-encoding:content-disposition :mime-version:references:message-id:subject:cc:to:from:date:from:to :cc:subject:date:message-id:reply-to; bh=0nEvDUTA+VvuaYc5IvEcHoTln/14hfyXc63Vrf+U23o=; b=TdaqAdOHGHRUQIQ58Zzi1ivA/gkcWgUKlHkgv2qJRjAfz0y1u6k2xlua3CjJeQMnCN jAm7bQuvGMU5gTCbNwLI2n4XMuWJR6iHumE009SlERLd+8eI40jXcL4ZVd9jaD/yipbY A/7LEA+EHylsqz9MxCV7O/e0YKqelB7ktAHP93NJ9s8m/V2KawJpUj02pbqb8Fh6cxgB +iFVNha29qee0qGnEIOBhmtOR6rjVZwosdWjAqq8pGednvkjMGlZoLKoGGIlcGD3Ncs+ JbfGSs0YlAgflFyd7TDU9yZH3SW3xTSVsK7YVfIxOabqry2641OjInXswVtmGnfLp6SV o3tQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1701099036; x=1701703836; h=in-reply-to:content-transfer-encoding:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=0nEvDUTA+VvuaYc5IvEcHoTln/14hfyXc63Vrf+U23o=; b=jq3CAdoWFECeDvLyRiQxlCV3X8bXD1r/b4ypdVIY4f0EMLnCvggZomf8/EG0Y8/tsf J/1F8RFDIRxieWs59z3C7Df8Ie96kBKQz3F8+iPx673NkbZbhWAPDLlEXpWB6NWowaIn 3LgGPzfbgzLCtzk3AmsY4DIaUTNIKe0HCzoduKcUr3D+MHG9ZH9S68ZZDna8Rh7GNuJv X3si7TAdCoGhnThGBFHIZ2MrS4rX+GfYPEKZg1eAbKMAAFqFHmGSRP4TjS7e+e32Quw3 sO3bytNd1EmnRlotfz2cnAkE/CrXrW6ocrttEWP/Hscll4W8qc2LXwL4jAAQfFRToEYb suOw== X-Gm-Message-State: AOJu0YwpMgBFDuhjRw0qpxE5FSjIc7s1HGCaQbKjGFgpJ3Mm2eV/+U0K 8VGCVtdUbDUX4KSK2zB81rc9iA== X-Received: by 2002:a05:6512:31ce:b0:50b:aedd:6d53 with SMTP id j14-20020a05651231ce00b0050baedd6d53mr4159551lfe.62.1701099036331; Mon, 27 Nov 2023 07:30:36 -0800 (PST) Received: from debian ([185.117.107.42]) by smtp.gmail.com with ESMTPSA id x5-20020a19f605000000b0050aa491e86esm1510684lfe.83.2023.11.27.07.30.35 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 27 Nov 2023 07:30:35 -0800 (PST) Date: Mon, 27 Nov 2023 16:30:33 +0100 From: =?iso-8859-1?Q?Ram=F3n?= Nordin Rodriguez To: Andrew Lunn Cc: Heiner Kallweit , Russell King , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , netdev@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH 0/3] net: microchip_t1s: additional phy support and collision detect handling Message-ID: References: <20231127104045.96722-1-ramon.nordin.rodriguez@ferroamp.se> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: X-Spam-Status: No, score=-0.8 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE, SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on morse.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (morse.vger.email [0.0.0.0]); Mon, 27 Nov 2023 07:31:35 -0800 (PST) On Mon, Nov 27, 2023 at 02:58:32PM +0100, Andrew Lunn wrote: > > Collision detection > > This has been tested on a setup where one ARM system with a LAN8650 > > mac-phy is daisy-chained to 8 mcus using lan8670 phys. Without the patch we > > were limited to really short cables, about 1m per node, but we were > > still getting a lot of connection drops. > > With the patch we could increase the total cable length to at least 40M. > > Did you do any testing of collision detection enabled, PLCA disabled? > In our dev system we've only tested with PLCA enabled, bit too tricky changing internals on the microcontrollers. But I have a lot of usb eval dongles that I can test with. > You say you think this is noise related. But the noise should be the > same with or without PLCA. I'm just thinking maybe collision detection > is just plain broken and should always be disabled? > I don't have access to the equipment to measure noise or reflections, I've looked at the link with an oscilloscope and it looked fine to me. The reason I'm mentioning noise is just me parroting the datasheet, for context I'll quote the footnote here "No physical collisions will occur when all nodes in a mixing segment are properly configured for PLCA operation. As a result, for improved performance in high noise environments where false collisions may be detected leading to dropped packets, it is recommended that the user write this bit to a ‘0’ to disable collision detection when PLCA is enabled. When collision detection is disabled, the PLCA reconciliation sublayer will still assert logical collisions to the MAC as part of normal operation." LAN8650 datasheet 11.5.51 > I've not read much about T1S, but if we assume it is doing good old > fashioned CSMA/CD, with short cables the CS bit works well and the CD > is less important. CD was needed when you have 1000m cable, and you > can fit 64 bytes on the 1000m cable. So always turning of CD might be > appropriate. > > Andrew As you assume when PLCA is disabled the phy runs in CSMA/CD mode. I'll do some tests with both PLCA and CD off/disabled. My thinking is that a adequate test bench would look like * 3-4 nodes (depending on how many usb ports and dongles I have) * run iperf with long cables and CSMA/CD * run iperf with long cables and CMSA/No CD I'll report back the results. Anything you'd like to add/focus on with evaluation? Ramón