Received: by 2002:a05:6359:c8b:b0:c7:702f:21d4 with SMTP id go11csp1841015rwb; Tue, 27 Sep 2022 20:20:41 -0700 (PDT) X-Google-Smtp-Source: AMsMyM59Uhbg0xzJYHxb1CbgxKJVme0ez8Oi9hqEUJju63dWk7XJLI21WxY/S1Lsh6xqgDkDbiSD X-Received: by 2002:a17:902:a50a:b0:178:b06f:ea1f with SMTP id s10-20020a170902a50a00b00178b06fea1fmr30597611plq.13.1664335240827; Tue, 27 Sep 2022 20:20:40 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1664335240; cv=none; d=google.com; s=arc-20160816; b=bDKS3l/GcALTWoyHM0vQB82TUPGw75K7cfHxRWdGVKLqZAplqgQsF7EwfrmkvtTqxF zvK7FOiNumfUSUbFwW4A32gZEJy7CSm0PZIffsGeavsgY8EkcTtju1eeBV86pGJJj6V8 Lexd3GOPkHCGuRzGdRIROGDBAlzOh8eIeuxYXvbWBQ7o4vcjWge8TQKKrFHOJo6HVkbc tU4oSiwqykZWnaLTFCYSHWu6sslGwHdrWE8CIq6pAd3B0+xgJzI0yWYP/ZijlO7IVF6z G5bqN79Z/uoVu15mYViACBehQ2J7EjxHpYx+PpEdAwSBfkqRTVQXyX+Vah72/JzSwoQN xV9w== 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=dmCETYE3MFv2kTPYln5E4bDHXMnPKxqN/NTzcZAlgp0=; b=COtiVfIyTYGrcw4N1yrAc1NbjwNz+LJJ1qYpVVzEx85Z03gkeYXXiQye3zpvdaEkmf Nra8e0KPrNaVB4cg5hz0ZLHeReyV4Xg78LKEmmcXcA2gWT4cnrr/GlgTae3RrcyEjNAr vNqD0udvl5Grj60oLU42mwG7Q0XmzGIYEZ0WoSYZBVtW8sf9b6RaPwpWseJVWPdble8g 1pkdCpdT+27g2ZIH4m0c11q1/MHcMncbmPoyxdZSFuNygQDccRiDjACCM4neLsDrDbom GSPM8/IhSjMst67bz2SixLxOO9KkmqO7owW/twGeN3pgvlQcIYFM1bYEd1e/iY2+NZbL AJ+g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@microchip.com header.s=mchp header.b=NH3ZumNc; 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=QUARANTINE sp=QUARANTINE dis=NONE) header.from=microchip.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id u69-20020a638548000000b0043c7b0510cfsi4303147pgd.463.2022.09.27.20.20.29; Tue, 27 Sep 2022 20:20:40 -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=@microchip.com header.s=mchp header.b=NH3ZumNc; 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=QUARANTINE sp=QUARANTINE dis=NONE) header.from=microchip.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232538AbiI1DMl (ORCPT + 99 others); Tue, 27 Sep 2022 23:12:41 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:35542 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232201AbiI1DMj (ORCPT ); Tue, 27 Sep 2022 23:12:39 -0400 Received: from esa.microchip.iphmx.com (esa.microchip.iphmx.com [68.232.154.123]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id DE4451D6259; Tue, 27 Sep 2022 20:12:36 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=microchip.com; i=@microchip.com; q=dns/txt; s=mchp; t=1664334756; x=1695870756; h=from:to:cc:subject:date:message-id:mime-version: content-transfer-encoding; bh=NIyJwUMK/mB2Bn8MukYK4I2XtfngeEYlcBH/NQGSr08=; b=NH3ZumNcINNOar3ciWWtYYTaohhwDq4em1HsmsSa5iTDopJQgwc2+tqf XeJgtJbeWQd8MXIEx09A4npWYUXqutfXXm17OuBP9fek3RjzmVJBkgFYy /Fg/kRDO/F6qHoUGyTD2gepdi7eV9l3EXKoqSok/HQJn2Zl2VMwiEzPLP +rzfWL1ZXwMEeFtSnfeg4NfhTXBZjEghn2xQmRA8gdmack1CizhqwU1lq GODNjFpzRFmDEsCTtr4XyF3Cnlh/ogw+raO1WRpi3F71LdvOzM3ma6CJA DGeBWgwD7Ko7DpkMu3PQB5VnBBYvW1HrKOOlKKh9s0W1HZxBGb7tIkREI g==; X-IronPort-AV: E=Sophos;i="5.93,350,1654585200"; d="scan'208";a="179238022" Received: from unknown (HELO email.microchip.com) ([170.129.1.10]) by esa2.microchip.iphmx.com with ESMTP/TLS/AES256-SHA256; 27 Sep 2022 20:12:35 -0700 Received: from chn-vm-ex03.mchp-main.com (10.10.85.151) by chn-vm-ex02.mchp-main.com (10.10.85.144) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.12; Tue, 27 Sep 2022 20:12:33 -0700 Received: from localhost.localdomain (10.10.115.15) by chn-vm-ex03.mchp-main.com (10.10.85.151) with Microsoft SMTP Server id 15.1.2507.12 via Frontend Transport; Tue, 27 Sep 2022 20:12:30 -0700 From: Raju Lakkaraju To: CC: , , , , , , Subject: [PATCH net V3] eth: lan743x: reject extts for non-pci11x1x devices Date: Wed, 28 Sep 2022 08:41:28 +0530 Message-ID: <20220928031128.123926-1-Raju.Lakkaraju@microchip.com> X-Mailer: git-send-email 2.25.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-Spam-Status: No, score=-4.5 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_MED, SPF_HELO_PASS,SPF_PASS 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 Remove PTP_PF_EXTTS support for non-PCI11x1x devices since they do not support the PTP-IO Input event triggered timestamping mechanisms added Fixes: 60942c397af6 ("Add support for PTP-IO Event Input External Timestamp (extts)") Signed-off-by: Raju Lakkaraju Reviewed-by: Jakub Kicinski --- Changes: ======== V2 -> V3: - Correct the Fixes tag V1 -> V2: - Repost against net with a Fixes tag drivers/net/ethernet/microchip/lan743x_ptp.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/drivers/net/ethernet/microchip/lan743x_ptp.c b/drivers/net/ethernet/microchip/lan743x_ptp.c index 6a11e2ceb013..da3ea905adbb 100644 --- a/drivers/net/ethernet/microchip/lan743x_ptp.c +++ b/drivers/net/ethernet/microchip/lan743x_ptp.c @@ -1049,6 +1049,10 @@ static int lan743x_ptpci_verify_pin_config(struct ptp_clock_info *ptp, enum ptp_pin_function func, unsigned int chan) { + struct lan743x_ptp *lan_ptp = + container_of(ptp, struct lan743x_ptp, ptp_clock_info); + struct lan743x_adapter *adapter = + container_of(lan_ptp, struct lan743x_adapter, ptp); int result = 0; /* Confirm the requested function is supported. Parameter @@ -1057,7 +1061,10 @@ static int lan743x_ptpci_verify_pin_config(struct ptp_clock_info *ptp, switch (func) { case PTP_PF_NONE: case PTP_PF_PEROUT: + break; case PTP_PF_EXTTS: + if (!adapter->is_pci11x1x) + result = -1; break; case PTP_PF_PHYSYNC: default: -- 2.25.1