Received: by 2002:a05:6358:4e97:b0:b3:742d:4702 with SMTP id ce23csp5192779rwb; Wed, 17 Aug 2022 12:49:25 -0700 (PDT) X-Google-Smtp-Source: AA6agR7BYpJg9YIBz7rtAhlYCHHj5Dp0tvIWzr5JUuHYCKikCl12/smaC1k2yZ+1qfySC68tcQvv X-Received: by 2002:a17:90b:35c3:b0:1f5:8a88:3b94 with SMTP id nb3-20020a17090b35c300b001f58a883b94mr5148603pjb.201.1660765765002; Wed, 17 Aug 2022 12:49:25 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1660765764; cv=none; d=google.com; s=arc-20160816; b=lxt/RxclDsfwl5ty1d50gJSd1HkHmgEO7iaiVMMdoOjx09hRWpE0sbJGzN37yYW3/7 ALJGM0aJ9z6k3Kg6rZJ6TqVoB5j0IfU3NN+pjlhyO/M1LbeeeDI4O0NgsNCFTcOngvw1 Ui0UtHQLKfPcKMOP9bAG6AyB1zSEnfyaRncsLvJ4nbzfGVR3gK8tXw3RZqqwStwdyKqd CkjfsNRf1gBGlEiM21++CMqO0xeCfKXRTtoQvQeX53vs+h4yfNUWVIdVIXlHrB9weg8o PDiz/IL89rhkcjpYjr3w12HM15B6LD7TC3z38JaLZPcEeAdDNHMQuhhPlDFcWZztrT5f edIg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=cP4aKR+foH/6I0CwVCpNzH2X5xuB80YYPnMu2s2X7NE=; b=e+Ecfe2iXF77vIKK+k3XyYXRH0UBBhFAlTopSie7+zl2EwMqEphdh+hrohOLgWoNH9 fxFlEQQEvonQroQuqTJGkgl/WblkWFbPVnk21x/EC5mBBtEWsL5+/Qjpa0MQriY9mVyc 0o320cv/wSeuSlTEH1+rcA5Sy2XGy5vje/V+DZtcn1XHFeir+7gtBOLIJ9Cn33pK7V4a X4OdUmcMbn7Xr0A7Vjg2b2sOElj3PybUHdhdaFTSj3czzE779i8TY3kGjZjpWLx391x8 dK4CZfpghkmd5puRFp2diaBPRTSwOPt6Lr7W/e6+5Wa7CLz8N7N9FihPOFhY6Hru1jA9 nMig== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=cBDJ7Odw; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id r186-20020a632bc3000000b0041c26691e57si1542301pgr.725.2022.08.17.12.49.12; Wed, 17 Aug 2022 12:49:24 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=cBDJ7Odw; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S241565AbiHQTc2 (ORCPT + 99 others); Wed, 17 Aug 2022 15:32:28 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:52516 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S241511AbiHQTcA (ORCPT ); Wed, 17 Aug 2022 15:32:00 -0400 Received: from ams.source.kernel.org (ams.source.kernel.org [145.40.68.75]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 21800A4B3D for ; Wed, 17 Aug 2022 12:31:28 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id 4C3CEB81F0B for ; Wed, 17 Aug 2022 19:31:26 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 9FF80C433D6; Wed, 17 Aug 2022 19:31:22 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1660764685; bh=folaEiqwvPtEOi1ekaQcirtyCHSCVGrI+j/lwWcW9o4=; h=From:To:Cc:Subject:Date:From; b=cBDJ7OdwSban6nhrj+lYajXImQUp/x28+Vh//RpP1ThS8CLRlGJYbseB5U+LQh98P 8jLEihOuV+itRpV4zyUuXusoF3qJqRmJZ6b9XqORWlrHLUiGvcpw7ppWVoWm0boDHM 6mDDmOIM5GRXCIFzXbMJgNkRShMbmhjjUNl6h99ezfCqFZFQaC51tOUQ5U4jKmmNS4 rpyZZrV3v3al3Dy3mM1sgjmQsptXMyOip2f/goUqzNU8KbNhlzQMPgQdFcPWVkoEpd 63b3DkTFgFfOHbdj49L2jUq+Da+fvF5R0SNplPZuwhVRhN9q9QEHoW6ccKHJJafi8o G14hfwD8UywYg== From: =?UTF-8?q?Marek=20Beh=C3=BAn?= To: Vinod Koul , Kishon Vijay Abraham I , Linux Phy , Gregory Clement , Andy Shevchenko , Daniel Scally , Heikki Krogerus , Sakari Ailus Cc: Kees Cook , linux-kernel@vger.kernel.org, pali@kernel.org, josef.schlehofer@nic.cz, =?UTF-8?q?Marek=20Beh=C3=BAn?= Subject: [PATCH linux-phy 0/4] mvebu a3720 comphy: Fix serdes transmit amplitude Date: Wed, 17 Aug 2022 21:31:15 +0200 Message-Id: <20220817193119.4463-1-kabel@kernel.org> X-Mailer: git-send-email 2.35.1 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-7.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org This series adds support for setting serdes transmit amplitude for ethernet modes (sgmii, 1000base-x, 2500base-x) in the Marvell A3720 comphy driver. The amplitude is set according to setting in device tree. Finally the Turris MOX device tree is changed to set the 2500base-x mode tx amplitude to 1025 mV. This is needed to fix a weird issue wherein when A3720 sends a packet to Topaz, and the packet contains a long sequence of 'J's or '\xb5' bytes (these translate to '010101010101'... in 8b/10b encoding), the packet may be lost on Topaz due to FCS error. The probability of loss grows with number of 'J's: loss ______ 100% .-^ / / 50% / / / 0% ______.-^ 90 114 125 number of consecutive 'J's Marek BehĂșn (4): string.h: Add str_has_proper_prefix() device property: Add {fwnode/device}_get_tx_p2p_amplitude() phy: marvell: phy-mvebu-a3700-comphy: Support changing tx amplitude for ethernet arm64: dts: armada-3720-turris-mox: Change comphy tx amplitude for 2500base-x mode .../dts/marvell/armada-3720-turris-mox.dts | 10 ++ drivers/base/property.c | 130 ++++++++++++++++++ drivers/phy/marvell/phy-mvebu-a3700-comphy.c | 109 ++++++++++++++- include/linux/property.h | 5 + include/linux/string.h | 18 +++ 5 files changed, 271 insertions(+), 1 deletion(-) -- 2.35.1