From patchwork Mon Oct 7 15:06:01 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Radhey Shyam Pandey X-Patchwork-Id: 13824900 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id EB652CFB446 for ; Mon, 7 Oct 2024 15:11:25 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:List-Subscribe:List-Help :List-Post:List-Archive:List-Unsubscribe:List-Id:Content-Type:MIME-Version: References:In-Reply-To:Message-ID:Date:Subject:CC:To:From:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=bXZOcttCcNKF06ZH/EOUl92KAIgU1q5QSWG11onV2SI=; b=xCzdcU7I0Np6hvnYh1EaG6tLjC cv4FUZ7hOVy4S4D0AiZPAsdvsv97wQms/8l/3CrjeuqYA6LA8M6R3XdWIrpRr599YWAFJkUu+XfR0 ed+KNPQxGmYrJNCTxSEYLsiKqXAsQB6xHDdIAPQEAhdim0Jww5yP77oYcEsZuLStxSfDXqwZfBvkq GHlYNqCS3Myp6KGin01LZ8LMxfMU5cmhp0EqfZfuwFETvCeO5AfzlTnhxc7H+QHjn7yJTFG2Dz1Hm qdge4f4PYaBdN1k5q4yRsVm4PScaKbIIUk1r095Rxrv7vVmOp5u9d4OAPhclBZqA0fOwJO40Nru4t anzDq3DA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.98 #2 (Red Hat Linux)) id 1sxpOE-00000002tKT-3gRV; Mon, 07 Oct 2024 15:11:14 +0000 Received: from mail-mw2nam12on2062b.outbound.protection.outlook.com ([2a01:111:f403:200a::62b] helo=NAM12-MW2-obe.outbound.protection.outlook.com) by bombadil.infradead.org with esmtps (Exim 4.98 #2 (Red Hat Linux)) id 1sxpJk-00000002rvU-3IIH for linux-arm-kernel@lists.infradead.org; Mon, 07 Oct 2024 15:06:38 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=ra+lUFbQNgsmtTXHB4r2y6N3+l8l91+A0E6AQen5WZR0Y32Yh4VuIiW7rlLEYvTxBwK4ZQtaq9ENFGF/Q6szrgUgVlVsG9KlTIRnG9j39TUm7Enov+kkf92Jybpa8xJRwo38j7+FxkzRWJf6iv8w8SCNtXKxujK8LRjUcN6btrgrdbLo9ldtRdXu5F0Y5/hfv5wSCxdnyLWjsjvqgy8RyU5KmrylYpFLbTWBVPuiKilvva6dWpcLaaH1550HP+j/5uTwxNDmNh9fN+KneonAeJbSqh5/YhoinWW3JX7d0gGLPoW8U5xP8RsjOoWxSWzkQbaW22vXzSOYD4oKuHPQDw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=bXZOcttCcNKF06ZH/EOUl92KAIgU1q5QSWG11onV2SI=; b=h7fxfYQBqDGAt6UjC/6S/1nYnYiluuZjuZRVdxPWpyzsHVVqW6D197qdZRUVl+LIdZ6VXYyk3abMXYyY5D8Uf76Az47yhb0jIgsEf4wlrvgpOlmmThqb4Ps5AXsqoVkKbrVm94uN9EX7aQQHx5VNreTLs0gw6nZqbCdmfx1O3phN+3sijkAXf8QVH2RMz2Zb1ee8xtlnAmxt22vZfptGgAYprZEPrPupsqMp8bGS8paEd11LHeyik6atcfviLNgDLNdRTlf2Lcd3m/PXZINOIBJzaMpPE4tswPVcPi4o6s50ORnGyWUU+Y0F0Ctnqov2Zf2sKk1lp0a4p25CYzAuVQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 165.204.84.17) smtp.rcpttodomain=davemloft.net smtp.mailfrom=amd.com; dmarc=pass (p=quarantine sp=quarantine pct=100) action=none header.from=amd.com; dkim=none (message not signed); arc=none (0) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amd.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=bXZOcttCcNKF06ZH/EOUl92KAIgU1q5QSWG11onV2SI=; b=PXM502KE0SKd7ZzwuXLKyIz+Xlc0szLmMMz4AUKs8xGAyMrv50juEJ4v7Uef5POPkn0KOO/n+lymK9wXv2+tkc91T1v1LBBDdP9WVyxlSubUHd2XfFhobx4CBby3k2lFFWoFA8OjciYzRWJPsamSW5Y+J9fsG2qdLd5ui6tonLM= Received: from PH8PR22CA0014.namprd22.prod.outlook.com (2603:10b6:510:2d1::29) by DM4PR12MB5841.namprd12.prod.outlook.com (2603:10b6:8:64::13) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.8026.22; Mon, 7 Oct 2024 15:06:27 +0000 Received: from CY4PEPF0000E9D8.namprd05.prod.outlook.com (2603:10b6:510:2d1:cafe::78) by PH8PR22CA0014.outlook.office365.com (2603:10b6:510:2d1::29) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.8026.23 via Frontend Transport; Mon, 7 Oct 2024 15:06:26 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 165.204.84.17) smtp.mailfrom=amd.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=amd.com; Received-SPF: Pass (protection.outlook.com: domain of amd.com designates 165.204.84.17 as permitted sender) receiver=protection.outlook.com; client-ip=165.204.84.17; helo=SATLEXMB04.amd.com; pr=C Received: from SATLEXMB04.amd.com (165.204.84.17) by CY4PEPF0000E9D8.mail.protection.outlook.com (10.167.241.71) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.20.8048.13 via Frontend Transport; Mon, 7 Oct 2024 15:06:26 +0000 Received: from SATLEXMB04.amd.com (10.181.40.145) by SATLEXMB04.amd.com (10.181.40.145) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.39; Mon, 7 Oct 2024 10:06:24 -0500 Received: from xhdradheys41.xilinx.com (10.180.168.240) by SATLEXMB04.amd.com (10.181.40.145) with Microsoft SMTP Server id 15.1.2507.39 via Frontend Transport; Mon, 7 Oct 2024 10:06:20 -0500 From: Radhey Shyam Pandey To: , , , , , , , , CC: , , , , , Abin Joseph , Radhey Shyam Pandey Subject: [PATCH net-next v2 1/3] dt-bindings: net: emaclite: Add clock support Date: Mon, 7 Oct 2024 20:36:01 +0530 Message-ID: <1728313563-722267-2-git-send-email-radhey.shyam.pandey@amd.com> X-Mailer: git-send-email 2.1.1 In-Reply-To: <1728313563-722267-1-git-send-email-radhey.shyam.pandey@amd.com> References: <1728313563-722267-1-git-send-email-radhey.shyam.pandey@amd.com> MIME-Version: 1.0 Received-SPF: None (SATLEXMB04.amd.com: radhey.shyam.pandey@amd.com does not designate permitted sender hosts) X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: CY4PEPF0000E9D8:EE_|DM4PR12MB5841:EE_ X-MS-Office365-Filtering-Correlation-Id: 08ddaa96-7aa7-4ec6-9a4a-08dce6e19d8d X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0;ARA:13230040|82310400026|1800799024|36860700013|376014|7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LBtCjKuaVG008d94NxgGoYxZGwLthsnfNJ18fUU1unj9z0aDpw8hGEb5hfXoUQV9P1FOh/Nuqxxh+n3iPknac+Q0QVPEJUHEgSB5gmet6DGF7maNL0YDMAJa+s5a3Y3Tb7K2dE9Sh1k/Xze41JsAmYJYZy5P8++3j6oL6yy/GbJQrKkf3pGAqVu9rOV83SK9rb/1AMCo/QWp7wtdHQral08DXdC5P3SyF93mYofsHH9T3ojZhbbUYsnSLtW7n/+pzteDyuBAKbCs6ORPDUhq9EqDC1h/TE0zrrmjemsxa9D1gmTUhwhVUZIGThWJIq+07FqL1Pw X-Forefront-Antispam-Report: CIP:165.204.84.17;CTRY:US;LANG:en;SCL:1;SRV:;IPV:CAL;SFV:NSPM;H:SATLEXMB04.amd.com;PTR:InfoDomainNonexistent;CAT:NONE;SFS:(13230040)(82310400026)(1800799024)(36860700013)(376014)(7416014);DIR:OUT;SFP:1101; X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 07 Oct 2024 15:06:26.3382 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 08ddaa96-7aa7-4ec6-9a4a-08dce6e19d8d X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=3dd8961f-e488-4e60-8e11-a82d994e183d;Ip=[165.204.84.17];Helo=[SATLEXMB04.amd.com] X-MS-Exchange-CrossTenant-AuthSource: CY4PEPF0000E9D8.namprd05.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM4PR12MB5841 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20241007_080636_852998_80F16346 X-CRM114-Status: GOOD ( 11.00 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org From: Abin Joseph Add s_axi_aclk AXI4 clock support. Traditionally this IP was used on microblaze platforms which had fixed clocks enabled all the time. But since its a PL IP, it can also be used on SoC platforms like Zynq UltraScale+ MPSoC which combines processing system (PS) and user programmable logic (PL) into the same device. On these platforms instead of fixed enabled clocks it is mandatory to explicitly enable IP clocks for proper functionality. So make clock a required property and also define max supported clock constraints. Signed-off-by: Abin Joseph Signed-off-by: Radhey Shyam Pandey Acked-by: Conor Dooley --- Changes for v2: - Describe clocks as required property. --- Documentation/devicetree/bindings/net/xlnx,emaclite.yaml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/Documentation/devicetree/bindings/net/xlnx,emaclite.yaml b/Documentation/devicetree/bindings/net/xlnx,emaclite.yaml index 92d8ade988f6..e16384aff557 100644 --- a/Documentation/devicetree/bindings/net/xlnx,emaclite.yaml +++ b/Documentation/devicetree/bindings/net/xlnx,emaclite.yaml @@ -29,6 +29,9 @@ properties: interrupts: maxItems: 1 + clocks: + maxItems: 1 + phy-handle: true local-mac-address: true @@ -45,6 +48,7 @@ required: - compatible - reg - interrupts + - clocks - phy-handle additionalProperties: false @@ -56,6 +60,7 @@ examples: reg = <0x40e00000 0x10000>; interrupt-parent = <&axi_intc_1>; interrupts = <1>; + clocks = <&dummy>; local-mac-address = [00 00 00 00 00 00]; phy-handle = <&phy0>; xlnx,rx-ping-pong; From patchwork Mon Oct 7 15:06:02 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Radhey Shyam Pandey X-Patchwork-Id: 13824901 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 9F90BCFB446 for ; Mon, 7 Oct 2024 15:12:45 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:List-Subscribe:List-Help :List-Post:List-Archive:List-Unsubscribe:List-Id:Content-Type:MIME-Version: References:In-Reply-To:Message-ID:Date:Subject:CC:To:From:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=vLyN30bJzNuhmIRRGdJUrSTAkk8c7HWdgEAlsDDTxX0=; b=TaDjPjzsb2DvsR3Rk3SFNxoyLU BuyxbVt3EoXdkX8wFQzeugMLfwQaC0IFx9ZUGXwcpqi2ADwWFk8QCqFh/GbFVEA3EJseWjc5MwFi+ 3zq6vPrilN2F4dqEMnU/YGZ3WovpWMNPwMxs9on4+QsYbEgnWwGsqte+3G/e44AyIesupGXa5UshJ lfrzOoZ8TUgYNBXXGM/vUJ+1COncKKe9ch+qGAD69MX09mWeDtYwF9ntr7eB1/finEEhSS4pI2o6q +SwcgAEouioUhI4Y6JxRBVpMkB789cBfq98ywGPFkzn6nyEoj//VmgvpnBMXClOyVr+I2LCF6Ar09 PIFB2Zug==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.98 #2 (Red Hat Linux)) id 1sxpPV-00000002tet-2iOV; Mon, 07 Oct 2024 15:12:33 +0000 Received: from mail-bn1nam02on2060f.outbound.protection.outlook.com ([2a01:111:f403:2407::60f] helo=NAM02-BN1-obe.outbound.protection.outlook.com) by bombadil.infradead.org with esmtps (Exim 4.98 #2 (Red Hat Linux)) id 1sxpJn-00000002rwE-35lq for linux-arm-kernel@lists.infradead.org; Mon, 07 Oct 2024 15:06:41 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=FQ10TH89QnD2vT9X4pObjxRrG9aQenGcX5+j7esCSe0Xe7rcpkAME0CrHPNFQhyWCkVgEeELVnuqyE99JaJYAmpy0qm8APdnUUpCvnazBu3Vq0RiRSS9Alezt26fOK4iwVYPpgncefX1Ki/qqtyBIhqUhW+gtUrTWOEAKs8xlXNRMG1kWFPNmd+/gx4QSRyksACkdpAIo6rKEaIaBGiEXaqmEUmqy2nS7ZUTKpAQISVc2+B4uGSvmWNCNw0CNW5RS4V9gx7Ud/T0cSURndSF4Mul68y9nY2dR1H9M021FaQ/LdSak/nuU5v0JcDcQMJJuUkBbWtwdsHh+zI2po6aEg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=vLyN30bJzNuhmIRRGdJUrSTAkk8c7HWdgEAlsDDTxX0=; b=D7LNK1phztLaVdgWlmz0eVZHPWfYuRGdS/VgFjNRhRpT59W6FKiS70jbLNOwUE2Dx5euJ9SgjlDZM0JWh1NVgRujVAE48ZtaNmLyHDeuUmsRT7zSckwRPh2aL3d9fdoK+iswz8/KawZLtrXdI/ZQQUB5IG7WAOoO4PPorY6xC20rq4ksF8wElZvlwmM2ANRjeBp8FElrV0iE7gtPnx6hoy0rua34/XAh/RMo3z/wKc1qwT5owu6RGjBI+EcG8NKzbdiX7L6m/LG20oPx+jpNW5SWxYz+0STFsti2viK2+m8WULUGKD5+q+Pzh+noPi7TcUN56mMat72TPcrvrbB3Ow== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 165.204.84.17) smtp.rcpttodomain=davemloft.net smtp.mailfrom=amd.com; dmarc=pass (p=quarantine sp=quarantine pct=100) action=none header.from=amd.com; dkim=none (message not signed); arc=none (0) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amd.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=vLyN30bJzNuhmIRRGdJUrSTAkk8c7HWdgEAlsDDTxX0=; b=nryH+0X+3g2oLw+EHYcYMjqmJZyzTn0bAjG2FdvcrHLfdEJCevP8HA00cMd/XdOlgEr8m0VYgKGYFpU5uHdlHSxAQPUBp6o3m4t3HFI9lpfiJN4/NfSSoNKQIBi/UXObcL2siE4HZcJPz7xIie2ehz9kDOYZVkjdczWkMUEGAY4= Received: from PH8PR05CA0011.namprd05.prod.outlook.com (2603:10b6:510:2cc::28) by CH3PR12MB9027.namprd12.prod.outlook.com (2603:10b6:610:120::15) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.8026.22; Mon, 7 Oct 2024 15:06:31 +0000 Received: from CY4PEPF0000E9DC.namprd05.prod.outlook.com (2603:10b6:510:2cc:cafe::80) by PH8PR05CA0011.outlook.office365.com (2603:10b6:510:2cc::28) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.8048.16 via Frontend Transport; Mon, 7 Oct 2024 15:06:31 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 165.204.84.17) smtp.mailfrom=amd.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=amd.com; Received-SPF: Pass (protection.outlook.com: domain of amd.com designates 165.204.84.17 as permitted sender) receiver=protection.outlook.com; client-ip=165.204.84.17; helo=SATLEXMB04.amd.com; pr=C Received: from SATLEXMB04.amd.com (165.204.84.17) by CY4PEPF0000E9DC.mail.protection.outlook.com (10.167.241.75) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.20.8048.13 via Frontend Transport; Mon, 7 Oct 2024 15:06:30 +0000 Received: from SATLEXMB04.amd.com (10.181.40.145) by SATLEXMB04.amd.com (10.181.40.145) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.39; Mon, 7 Oct 2024 10:06:29 -0500 Received: from xhdradheys41.xilinx.com (10.180.168.240) by SATLEXMB04.amd.com (10.181.40.145) with Microsoft SMTP Server id 15.1.2507.39 via Frontend Transport; Mon, 7 Oct 2024 10:06:25 -0500 From: Radhey Shyam Pandey To: , , , , , , , , CC: , , , , , Abin Joseph , Radhey Shyam Pandey Subject: [PATCH net-next v2 2/3] net: emaclite: Replace alloc_etherdev() with devm_alloc_etherdev() Date: Mon, 7 Oct 2024 20:36:02 +0530 Message-ID: <1728313563-722267-3-git-send-email-radhey.shyam.pandey@amd.com> X-Mailer: git-send-email 2.1.1 In-Reply-To: <1728313563-722267-1-git-send-email-radhey.shyam.pandey@amd.com> References: <1728313563-722267-1-git-send-email-radhey.shyam.pandey@amd.com> MIME-Version: 1.0 Received-SPF: None (SATLEXMB04.amd.com: radhey.shyam.pandey@amd.com does not designate permitted sender hosts) X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: CY4PEPF0000E9DC:EE_|CH3PR12MB9027:EE_ X-MS-Office365-Filtering-Correlation-Id: da40e6d3-0e97-4238-fa13-08dce6e1a034 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0;ARA:13230040|1800799024|36860700013|376014|7416014|82310400026; X-Microsoft-Antispam-Message-Info: /ZUGFBb4nWUY1Zmf+AUxCx3+rPxZ3Qw3MMpwaGg5RPv4CnwBAp80rrU8hF2R6AHqoum13BGHvJX1hyxqL+iQrVmr+G06TPHtpUPD9E+lUP17MUHIdMHNoTHO/mkzZ8xTPscPk9r70sWEySoyeKOj5hQOsiGUUzoVIJj73LgydKckmmPT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ZHosVbZSHFHm3/2J4qffdq+v5o5qkWR1TSZBeFpdcF32WE6eQBQUhyl3k9Ci7NPBvR6TShBxCuLLLd40qArkfSpAFtiQOXPJX+Hyitmexn7wZIgft250riBqKk7c+6pDH7/aJN8egSRolTUwsnp0BpIY2k X-Forefront-Antispam-Report: CIP:165.204.84.17;CTRY:US;LANG:en;SCL:1;SRV:;IPV:CAL;SFV:NSPM;H:SATLEXMB04.amd.com;PTR:InfoDomainNonexistent;CAT:NONE;SFS:(13230040)(1800799024)(36860700013)(376014)(7416014)(82310400026);DIR:OUT;SFP:1101; X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 07 Oct 2024 15:06:30.8061 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: da40e6d3-0e97-4238-fa13-08dce6e1a034 X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=3dd8961f-e488-4e60-8e11-a82d994e183d;Ip=[165.204.84.17];Helo=[SATLEXMB04.amd.com] X-MS-Exchange-CrossTenant-AuthSource: CY4PEPF0000E9DC.namprd05.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: CH3PR12MB9027 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20241007_080639_823029_7BBA17ED X-CRM114-Status: GOOD ( 12.51 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org From: Abin Joseph Use device managed ethernet device allocation to simplify the error handling logic. No functional change. Signed-off-by: Abin Joseph Signed-off-by: Radhey Shyam Pandey --- changes for v2: - None. --- drivers/net/ethernet/xilinx/xilinx_emaclite.c | 14 ++++---------- 1 file changed, 4 insertions(+), 10 deletions(-) diff --git a/drivers/net/ethernet/xilinx/xilinx_emaclite.c b/drivers/net/ethernet/xilinx/xilinx_emaclite.c index 2eb7f23538a6..418587942527 100644 --- a/drivers/net/ethernet/xilinx/xilinx_emaclite.c +++ b/drivers/net/ethernet/xilinx/xilinx_emaclite.c @@ -1097,7 +1097,7 @@ static int xemaclite_of_probe(struct platform_device *ofdev) dev_info(dev, "Device Tree Probing\n"); /* Create an ethernet device instance */ - ndev = alloc_etherdev(sizeof(struct net_local)); + ndev = devm_alloc_etherdev(dev, sizeof(struct net_local)); if (!ndev) return -ENOMEM; @@ -1110,15 +1110,13 @@ static int xemaclite_of_probe(struct platform_device *ofdev) /* Get IRQ for the device */ rc = platform_get_irq(ofdev, 0); if (rc < 0) - goto error; + return rc; ndev->irq = rc; lp->base_addr = devm_platform_get_and_ioremap_resource(ofdev, 0, &res); - if (IS_ERR(lp->base_addr)) { - rc = PTR_ERR(lp->base_addr); - goto error; - } + if (IS_ERR(lp->base_addr)) + return PTR_ERR(lp->base_addr); ndev->mem_start = res->start; ndev->mem_end = res->end; @@ -1167,8 +1165,6 @@ static int xemaclite_of_probe(struct platform_device *ofdev) put_node: of_node_put(lp->phy_node); -error: - free_netdev(ndev); return rc; } @@ -1197,8 +1193,6 @@ static void xemaclite_of_remove(struct platform_device *of_dev) of_node_put(lp->phy_node); lp->phy_node = NULL; - - free_netdev(ndev); } #ifdef CONFIG_NET_POLL_CONTROLLER From patchwork Mon Oct 7 15:06:03 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Radhey Shyam Pandey X-Patchwork-Id: 13824902 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 36FD7CFB446 for ; Mon, 7 Oct 2024 15:14:11 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:List-Subscribe:List-Help :List-Post:List-Archive:List-Unsubscribe:List-Id:Content-Type:MIME-Version: References:In-Reply-To:Message-ID:Date:Subject:CC:To:From:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=KCKzUG30wjF/lWvieBvsSNDEgleYP4VcwrDEA0dQGkU=; b=491MkTq1DdsN30eZUzz53xVztq HCoTZBxFaSfB58VWll8Kz5jwTEcgcrMMUvHGSz+B9wxlaOtqWMxPmeV4vT8TVf1SOxn0LUCQLn9CN Xc0dtckyJXbWPaHCWK5O7HwBf408qSOk7xfUTOcqR66A3kBQn/cSnLTr8dQ/SCNrUsvf4rrXu7ees D1HncS1kB0Wrri+zXBw0JelUw5A1s33Jo4WgTdo7f/uwUr1AEX0OUZXw7vjzF+pwt6kOPZtoV/NWT kxTAklERuXJOtehsZiPNE5VsKhzcZy4KmuhVhV3LzXmCjH2eMakMeQsGTqZUJjnHiUfjda7BqjXSA 6oHyzzkQ==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.98 #2 (Red Hat Linux)) id 1sxpQp-00000002u08-1hdd; Mon, 07 Oct 2024 15:13:55 +0000 Received: from mail-dm3nam02on20628.outbound.protection.outlook.com ([2a01:111:f403:2405::628] helo=NAM02-DM3-obe.outbound.protection.outlook.com) by bombadil.infradead.org with esmtps (Exim 4.98 #2 (Red Hat Linux)) id 1sxpJq-00000002rxS-1D0R for linux-arm-kernel@lists.infradead.org; Mon, 07 Oct 2024 15:06:43 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=Z4yJW+uqL2EjL8A6LeSyQ/okQJTtvmqOjqIFq2CIpBgKeL2YgKXCQ2Z69sj7JMqdRdOyK8aznNVNB5PQsWrXeHCwoUd+3gEpJXmD6+vBZsNbhTMd/GB2RUWMjXgisXjC7/yEe5bK1SOCXqOEVPA2YJ7FfH3W3XPREjUMSxxS0At/OKYXEtsCByfG4z5jG9FlxEbEMVRG/8AuTOVocsoeNM25nVCIl3Nt8yY2WgpZA1B1qTFSmoO7PEOr/p5UaitLw6CdasLhPR/s8umafdKT6k1btGdfR5OAelcdrmLN6deY3KUrBwwLxUikxjvEGvVAZcm36vIVvvleN1aE6RJXSQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=KCKzUG30wjF/lWvieBvsSNDEgleYP4VcwrDEA0dQGkU=; b=QCdfT5JEgjWimH0NtlJqTEeblZLJu9B4ra0fwRuT09ZKPtCPyswqwE+65WtPV3B3t/s1ckXzr8+8HqUgn7/7u1rfSIenfV7Jv0ltPt41J9cwQ9HLMJTJRSJ0B8Bb+OKBS37yIBdamPu8wRWgaWU9Q6oe3EGL3xBD3tFzjtzvPEZc5owq7bpWu0RghKdkUE4ff1+q8wNxuhmUM/2JYNF6cOGLGt6dK52qxP5pnFKewWlPzF4I5jgTtHKqRUi+pcJn0P3pQ6TAR3coAY7lE52sHte3cw2HKm4P6iMv4iaJalT4NCLHaJoqH+7a/0dizDjWJ39yh7MvlzF5ZFfU+TU5CQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 165.204.84.17) smtp.rcpttodomain=davemloft.net smtp.mailfrom=amd.com; dmarc=pass (p=quarantine sp=quarantine pct=100) action=none header.from=amd.com; dkim=none (message not signed); arc=none (0) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amd.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=KCKzUG30wjF/lWvieBvsSNDEgleYP4VcwrDEA0dQGkU=; b=rRiLqEaOOluYKV9Oxwed3MWiQ6o0I17FTCjQo/JVpJzm2qZydFJ9egtllWlZea7mGjf417pLIhgUgynIxq0bK9nDcjt3YMNYJwv3hCI8wequN6ZStmPFtImSWSYdkhMGtjgK4LQHicUSFNvH+iWfd0enBQTl9sLlBGfs9NIk144= Received: from SA1PR02CA0013.namprd02.prod.outlook.com (2603:10b6:806:2cf::11) by CH3PR12MB8972.namprd12.prod.outlook.com (2603:10b6:610:169::11) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.8026.19; Mon, 7 Oct 2024 15:06:36 +0000 Received: from SN1PEPF0002636C.namprd02.prod.outlook.com (2603:10b6:806:2cf:cafe::b8) by SA1PR02CA0013.outlook.office365.com (2603:10b6:806:2cf::11) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.8026.23 via Frontend Transport; Mon, 7 Oct 2024 15:06:36 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 165.204.84.17) smtp.mailfrom=amd.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=amd.com; Received-SPF: Pass (protection.outlook.com: domain of amd.com designates 165.204.84.17 as permitted sender) receiver=protection.outlook.com; client-ip=165.204.84.17; helo=SATLEXMB03.amd.com; pr=C Received: from SATLEXMB03.amd.com (165.204.84.17) by SN1PEPF0002636C.mail.protection.outlook.com (10.167.241.137) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.20.8048.13 via Frontend Transport; Mon, 7 Oct 2024 15:06:35 +0000 Received: from SATLEXMB04.amd.com (10.181.40.145) by SATLEXMB03.amd.com (10.181.40.144) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.39; Mon, 7 Oct 2024 10:06:33 -0500 Received: from xhdradheys41.xilinx.com (10.180.168.240) by SATLEXMB04.amd.com (10.181.40.145) with Microsoft SMTP Server id 15.1.2507.39 via Frontend Transport; Mon, 7 Oct 2024 10:06:29 -0500 From: Radhey Shyam Pandey To: , , , , , , , , CC: , , , , , Abin Joseph , Radhey Shyam Pandey Subject: [PATCH net-next v2 3/3] net: emaclite: Adopt clock support Date: Mon, 7 Oct 2024 20:36:03 +0530 Message-ID: <1728313563-722267-4-git-send-email-radhey.shyam.pandey@amd.com> X-Mailer: git-send-email 2.1.1 In-Reply-To: <1728313563-722267-1-git-send-email-radhey.shyam.pandey@amd.com> References: <1728313563-722267-1-git-send-email-radhey.shyam.pandey@amd.com> MIME-Version: 1.0 Received-SPF: None (SATLEXMB03.amd.com: radhey.shyam.pandey@amd.com does not designate permitted sender hosts) X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: SN1PEPF0002636C:EE_|CH3PR12MB8972:EE_ X-MS-Office365-Filtering-Correlation-Id: 6a61d57a-be6c-4d60-1f05-08dce6e1a2ed X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0;ARA:13230040|376014|7416014|36860700013|82310400026|1800799024; X-Microsoft-Antispam-Message-Info: xTTxjG2DN3HEMTACXs6G1p9wY3Vl2CzabZmTUIQOxntV4cFaMzi0xckB5W/9GNgGzthsMqHImHatQQZ2S6wN67AT6AagNSPZpN5wb9MI9vEzle+uRgag7CMG3J3N/Z4HwdZkFSkFJNlh3FzdpZIXwnd9V7Qb8RY/J7ag8wtY6IiLhpMiyGeETzM1TX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UGdj9YS/UuF+lncnT7k+rFK9MOiO0cOoNvQssGMSNJOMev0L0q4DJCi2GbsX6FWBMz8li6p/yan2+l68cMhMt6boxQeiPspDenhKOgNDDopGfJOj2Cc3/WbC1We/a7x9itzlseXID91+j8jKhz X-Forefront-Antispam-Report: CIP:165.204.84.17;CTRY:US;LANG:en;SCL:1;SRV:;IPV:CAL;SFV:NSPM;H:SATLEXMB03.amd.com;PTR:InfoDomainNonexistent;CAT:NONE;SFS:(13230040)(376014)(7416014)(36860700013)(82310400026)(1800799024);DIR:OUT;SFP:1101; X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 07 Oct 2024 15:06:35.4465 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 6a61d57a-be6c-4d60-1f05-08dce6e1a2ed X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=3dd8961f-e488-4e60-8e11-a82d994e183d;Ip=[165.204.84.17];Helo=[SATLEXMB03.amd.com] X-MS-Exchange-CrossTenant-AuthSource: SN1PEPF0002636C.namprd02.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: CH3PR12MB8972 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20241007_080642_359449_E75348C7 X-CRM114-Status: GOOD ( 13.42 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org From: Abin Joseph Adapt to use the clock framework. Add s_axi_aclk clock from the processor bus clock domain and make clk optional to keep DTB backward compatibility. Signed-off-by: Abin Joseph Signed-off-by: Radhey Shyam Pandey --- changes for v2: - None. --- drivers/net/ethernet/xilinx/xilinx_emaclite.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/drivers/net/ethernet/xilinx/xilinx_emaclite.c b/drivers/net/ethernet/xilinx/xilinx_emaclite.c index 418587942527..fe901af5ddfa 100644 --- a/drivers/net/ethernet/xilinx/xilinx_emaclite.c +++ b/drivers/net/ethernet/xilinx/xilinx_emaclite.c @@ -7,6 +7,7 @@ * Copyright (c) 2007 - 2013 Xilinx, Inc. */ +#include #include #include #include @@ -1091,6 +1092,7 @@ static int xemaclite_of_probe(struct platform_device *ofdev) struct net_device *ndev = NULL; struct net_local *lp = NULL; struct device *dev = &ofdev->dev; + struct clk *clkin; int rc = 0; @@ -1127,6 +1129,12 @@ static int xemaclite_of_probe(struct platform_device *ofdev) lp->tx_ping_pong = get_bool(ofdev, "xlnx,tx-ping-pong"); lp->rx_ping_pong = get_bool(ofdev, "xlnx,rx-ping-pong"); + clkin = devm_clk_get_optional_enabled(&ofdev->dev, NULL); + if (IS_ERR(clkin)) { + return dev_err_probe(&ofdev->dev, PTR_ERR(clkin), + "Failed to get and enable clock from Device Tree\n"); + } + rc = of_get_ethdev_address(ofdev->dev.of_node, ndev); if (rc) { dev_warn(dev, "No MAC address found, using random\n");