From patchwork Tue Feb 23 08:30:30 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christian Melki X-Patchwork-Id: 12100035 X-Patchwork-Delegate: kuba@kernel.org Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-15.2 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER,INCLUDES_PATCH, MAILING_LIST_MULTI,MSGID_FROM_MTA_HEADER,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED, USER_AGENT_SANE_1 autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id EDECAC433DB for ; Tue, 23 Feb 2021 08:31:11 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 9FBB064E4D for ; Tue, 23 Feb 2021 08:31:11 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232086AbhBWIbK (ORCPT ); Tue, 23 Feb 2021 03:31:10 -0500 Received: from mail-vi1eur05on2076.outbound.protection.outlook.com ([40.107.21.76]:54624 "EHLO EUR05-VI1-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S232201AbhBWIbC (ORCPT ); Tue, 23 Feb 2021 03:31:02 -0500 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=GILjkwfr/nRLy0+68Dsrjefg5O34tSsL4qitCwNI/ci/vDxXZgTQri4YlMpLEqqICzNAG6xF/YyPdExKelaSuSmpZGRadVpVFlt/uMctRsW+Ildqu/K8k5RUIDrSR/5Lg2s9BomaLLEAyIF3x8y5gHlHk6e1sVhcDuxIKV0Uz5ul7ZrQM9bmC6Hi+G5/256kuRm40E133OoodZDr9yBrA6Rwa8gNeEpyGMpOzkGiFBg+/DZLHpXYNDTcc7k3QNImTqJ6hBbOU+LYYrBOBUal8y40yu6z14p3fiayG2BKlhMQowGJHv7jCiMnX0NcKBVT3jzeRB5h6AOWPacc+OZSZA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=4jZwi4U2l2p5e5rYTtFGutJKrabMizmwqdYk8rOCRqs=; b=g1RWfEFusWt/19it7tYZSBGfSM5Ja3GlNPS2byz9VJnhRcXG4TB/kMQAAmRrPRadR2/Yw+uL7ptvhb/L9Cjt0WAAjUvhcpVQP4FYfZ4Mcqx07oxOPfYKXu3ygpAfziaWeqIxk0YLesyRhzEXKDunrnThlJpAeaKzCaENQ2tRi++sdkFW4d6491ZWVsn15ceeSXW64BIypK7HHt343T+UUAqm78NbakAQtEKzGSWxoxnyYCCvA3Dou9s2VOmw+UcHTsrY1QoxCcgPYlaqHXfAKBuhMXiQ7zbJEJ2jbAv3xAb8RS9aDiZEPFPM1wgdFAMclnqEd79G+H8FfubXWpCQGw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=t2data.com; dmarc=pass action=none header.from=t2data.com; dkim=pass header.d=t2data.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=t2datacom.onmicrosoft.com; s=selector1-t2datacom-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=4jZwi4U2l2p5e5rYTtFGutJKrabMizmwqdYk8rOCRqs=; b=dcWDr70t0Onp6ZjbpP+5PfcjyUqdYC9k1ky131jx9Yihr6xRg/MLf6VS/bxSSuJBdWJCax6487UQEWG+uWsnAvqHoukZ1jEhUckF2ajfa5X6aGGXy6zoUBN9MPLDMm8mYwqgduYqwuf7YH6gloaGGDcfVenAQtqCncgFi+s4mik= Authentication-Results: kernel.org; dkim=none (message not signed) header.d=none;kernel.org; dmarc=none action=none header.from=t2data.com; Received: from HE1PR0602MB2858.eurprd06.prod.outlook.com (2603:10a6:3:da::10) by HE1PR0602MB3323.eurprd06.prod.outlook.com (2603:10a6:7:20::33) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3868.29; Tue, 23 Feb 2021 08:30:11 +0000 Received: from HE1PR0602MB2858.eurprd06.prod.outlook.com ([fe80::a40f:7a6e:fca8:eedb]) by HE1PR0602MB2858.eurprd06.prod.outlook.com ([fe80::a40f:7a6e:fca8:eedb%8]) with mapi id 15.20.3868.031; Tue, 23 Feb 2021 08:30:11 +0000 Reply-To: christian.melki@t2data.com To: netdev@vger.kernel.org Cc: andrew@lunn.ch, hkallweit1@gmail.com, f.fainelli@gmail.com, kuba@kernel.org From: Christian Melki Subject: [PATCH v2 net] net: phy: micrel: set soft_reset callback to genphy_soft_reset for KSZ8081 Message-ID: Date: Tue, 23 Feb 2021 09:30:30 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.7.1 Content-Language: en-US X-Originating-IP: [81.234.39.46] X-ClientProxiedBy: HE1PR0102CA0008.eurprd01.prod.exchangelabs.com (2603:10a6:7:14::21) To HE1PR0602MB2858.eurprd06.prod.outlook.com (2603:10a6:3:da::10) MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 Received: from [192.168.7.217] (81.234.39.46) by HE1PR0102CA0008.eurprd01.prod.exchangelabs.com (2603:10a6:7:14::21) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3868.27 via Frontend Transport; Tue, 23 Feb 2021 08:30:11 +0000 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 2e70fbef-e62a-4eeb-5310-08d8d7d53c4e X-MS-TrafficTypeDiagnostic: HE1PR0602MB3323: X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:8273; X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: tYk3+lvnMdJdhHP2tnQ2y61W1TueBMllaz72S2PRDn+T2zFJZHIlff1UR1LXBhhr0eI2vPyhloPLirETklxvzfB1fRpA8krI8SILUvqeaOp2fy0yMFZmdbT6LuLFkkyrR60g2SvPzZk0aY8A5CepRDOUljXvkRhbgmpbRupFy/pA1nPZGNi+llI3C4y2JCtwV4Jpruu/lU5SJBt+dbW9tAMRgYN7aXIoo36z+a2GneEXTI9RYDGqYt5tiLrJ8LqS/mjkomKE7Qj9ZRz1CH6Fx+U0BJXBZ/O4kPkKJjIZemnS+4uSWo9gvQ7OeypDZTu/ZM4fvatrrDcLTLY2/bdsasoJGBL9c2ZZAi224wWp8llLIFZpmLje7C+k+SEfAai2z6UYt794AcauAhmBnndO2Iv/RmR2S55nK9GsUypoNdGxcA/P60WUR9n3EmtNeTKEzNZHA0fnZq9T1igN/N+dh9PvT5FopWXr1dasj+shw5MtPkoFEvDAM8ScYbhrfDxNH/o127uRJ3tz5t+5cF5N13genXBgO0oysDw9uz6cl67nMsvCCRSBGi6luT3587Alou1NSIrShlo0q+1v5N4uBw== X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:HE1PR0602MB2858.eurprd06.prod.outlook.com;PTR:;CAT:NONE;SFS:(376002)(42606007)(366004)(39830400003)(136003)(396003)(346002)(31686004)(26005)(16526019)(186003)(36756003)(8936002)(44832011)(2616005)(956004)(31696002)(3450700001)(2906002)(86362001)(316002)(52116002)(8676002)(16576012)(478600001)(6666004)(4326008)(6916009)(6486002)(66556008)(66476007)(66946007)(5660300002)(43740500002);DIR:OUT;SFP:1101;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wMIAk8Sk9aMRpo2eB2Ig1ML72WKogfM4ZuE0nRCZSz+4U6jTFby0AcU?= =?utf-8?q?De2Mkq/WBjG6QCMtVamCGH8wTSj61+zXbcIPLyxrFAEgbFz9TXy7fE05BOXJ+mDax?= =?utf-8?q?NkIaN77H7ksfcudmeYP0NFiEyUTJLANqct0wraauDdwSZFiZ6X4+DNpnlVchhZ9Ba?= =?utf-8?q?uBMV0ms0fxful979eSYJhMJzP8oJ8OLpg/XWHokUQYTTTI2GMGhV/RCTKCoJRdh4I?= =?utf-8?q?AQylv3KaftegWsIgcvatL/4Fp0JrRj4hEC3N5oMYOEgJcvzAAkbhCvn1zyCdVI1DF?= =?utf-8?q?IlCCH1+M2mlE2rkwyLBzp89aRDlmVVGx5e1l+f1wkaic1/UX8hxZSo7bNQalQl9Yk?= =?utf-8?q?8G4n9UW1+Svm6twY94ipBBwpwI3QxP5oWFFZCdTb/EfqY7hXi1cEkJc3vnKqITy2i?= =?utf-8?q?unnSElZ5TK+oNL?= X-OriginatorOrg: t2data.com X-MS-Exchange-CrossTenant-Network-Message-Id: 2e70fbef-e62a-4eeb-5310-08d8d7d53c4e X-MS-Exchange-CrossTenant-AuthSource: HE1PR0602MB2858.eurprd06.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 23 Feb 2021 08:30:11.3896 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 27928da5-aacd-4ba1-9566-c748a6863e6c X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: MzkFAa81G5XF2nHWQJ57t9nU78IsLbwsbAAm0ggDDHVDC/GGlQ4+VYkmyxvTY+9zBqJWdTSUENtL1dfRFCpHSKIe8dWYCXq08DIcqns1Wyc= X-MS-Exchange-Transport-CrossTenantHeadersStamped: HE1PR0602MB3323 Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org X-Patchwork-Delegate: kuba@kernel.org Following a similar reinstate for the KSZ9031. Older kernels would use the genphy_soft_reset if the PHY did not implement a .soft_reset. Bluntly removing that default may expose a lot of situations where various PHYs/board implementations won't recover on various changes. Like with tgus implementation during a 4.9.x to 5.4.x LTS transition. I think it's a good thing to remove unwanted soft resets but wonder if it did open a can of worms? Atleast this fixes one iMX6 FEC/RMII/8081 combo. Fixes: 6e2d85ec0559 ("net: phy: Stop with excessive soft reset") Signed-off-by: Christian Melki --- -- diff --git a/drivers/net/phy/micrel.c b/drivers/net/phy/micrel.c index 7ec6f70d6a82..a14a00328fa3 100644 --- a/drivers/net/phy/micrel.c +++ b/drivers/net/phy/micrel.c @@ -1303,6 +1303,7 @@ static struct phy_driver ksphy_driver[] = { .driver_data = &ksz8081_type, .probe = kszphy_probe, .config_init = ksz8081_config_init, + .soft_reset = genphy_soft_reset, .config_intr = kszphy_config_intr, .handle_interrupt = kszphy_handle_interrupt, .get_sset_count = kszphy_get_sset_count,