From patchwork Fri Aug 27 09:26:23 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kavyasree Kotagiri X-Patchwork-Id: 12461609 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=-17.5 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER, INCLUDES_PATCH,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,USER_AGENT_GIT autolearn=unavailable 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 86759C432BE for ; Fri, 27 Aug 2021 09:28:36 +0000 (UTC) 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 mail.kernel.org (Postfix) with ESMTPS id 5228660F39 for ; Fri, 27 Aug 2021 09:28:36 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org 5228660F39 Authentication-Results: mail.kernel.org; dmarc=fail (p=quarantine dis=none) header.from=microchip.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:Message-ID:Date:Subject:CC :To:From:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References: List-Owner; bh=QxGRNS7yX4rW9a3XKJPz5FHbFEl8/ah7J/1Kd0yV4E8=; b=Ngn242ka4a8uo+ uoMGs4b8/SsxIWU2R5NgPBzOz/KI/TFRKKEHSsuzRWG5ZF/pKfgeV/Oqpg+qvolNvnNlaCUkGCpmi UHAS6Gl177HVV4/2TWHfcgd7clguV+6OBnPMijaygPR/V9KSLtzWtsB2IVuz8QMCfJ/M/LHl9EzKE 0d+h7dQs/lO7kZKrLZ5dHCdolZoADwGar7Kv+pbK0s6V+uwi2FQ86VGLeBiO13A/cD8I786sQH2BW DIsa8O9L401qURzPBZr5XUJkN7K8kbw6ahNFVODJSVXdIhTEsY7MNvexu4z36sVwJrfcGicNlBV9j yWYIGdiD1Nitla/CGi7g==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1mJY8O-00C2Zi-90; Fri, 27 Aug 2021 09:26:48 +0000 Received: from esa.microchip.iphmx.com ([68.232.153.233]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1mJY8H-00C2Yu-2j for linux-arm-kernel@lists.infradead.org; Fri, 27 Aug 2021 09:26:45 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=microchip.com; i=@microchip.com; q=dns/txt; s=mchp; t=1630056402; x=1661592402; h=from:to:cc:subject:date:message-id:mime-version; bh=J3i9uBz3EG1ucQmcepffYGi/MTUpR71z9RNb52yBNBM=; b=xf+k4R++ulQBQvhYHZc3RGiDZ7DJ/PqSdxDZ66eYA7pCl1bdWrheVk2n JLe9iL4OvoJLUqXwE9ngxZ3lNCWmQFjexcq9MEFB+d2EbBEL/lmMVfybM iJoAt94FzobYwGcTF5F2U/pIYTndvVhZpmHg7r7YZTMoeNAkACmSRZSCL uvHFJnwKxlAUBBo5195B9r0+v0d4oG4NkRR9aGWSnnqnmIh9Yf1rifRT+ DpnwgPQfwsi0D4orhRfTewr5eP7WZ/z8sX0V72elCqk68OYN4KwAcKHL/ iRPNNBhlNKZwZbNB3x5b/tAJNTb3WOG5tVU2Tqbbmz7BpEWDqA3V3QbGc g==; IronPort-SDR: WQMlE/SKoDrKt+PMq0eLk352Hwz5nTAFqmiuu0jmPCUpZy0oU8CfYEjyvWkVDXY5H2HMCoCgaz RLN3FbLcfoRYQD9K2FngKfeFo7FA68/DsbOkK53ohyDZus7j6INmlvygdRLnkS+PRbbzOmU06Z 4F169O+c1Sns0nO9FtbhueFUhmexCsCwZMeJoDjr6F83NCjvyUDpVkUVbiioorkl7wcstdL6tA 8RlENh0B9msbV/ylq1esqJovy6YcTNGOYMvwyq3DC3cLxL8RHYQeotT4bAqllYsNig79t2cqzy dBoqqpYBculQut68iy/x0peo X-IronPort-AV: E=Sophos;i="5.84,356,1620716400"; d="scan'208";a="133873674" Received: from smtpout.microchip.com (HELO email.microchip.com) ([198.175.253.82]) by esa5.microchip.iphmx.com with ESMTP/TLS/AES256-SHA256; 27 Aug 2021 02:26:39 -0700 Received: from chn-vm-ex04.mchp-main.com (10.10.85.152) by chn-vm-ex04.mchp-main.com (10.10.85.152) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2176.14; Fri, 27 Aug 2021 02:26:37 -0700 Received: from kavya-HP-Compaq-6000-Pro-SFF-PC.microchip.com (10.10.115.15) by chn-vm-ex04.mchp-main.com (10.10.85.152) with Microsoft SMTP Server id 15.1.2176.14 via Frontend Transport; Fri, 27 Aug 2021 02:26:34 -0700 From: To: , , CC: , , , , , Subject: [PATCH] ARM: at91: add basic support for new SoC lan966x Date: Fri, 27 Aug 2021 14:56:23 +0530 Message-ID: <20210827092623.10677-1-kavyasree.kotagiri@microchip.com> X-Mailer: git-send-email 2.17.1 MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20210827_022641_181897_C5D36DE6 X-CRM114-Status: GOOD ( 12.99 ) 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: Kavyasree Kotagiri This patch introduces Microchip LAN966X ARMv7 based SoC family of multiport gigabit AVB/TSN-capable ethernet switches. It supports two SKUs: 4-port LAN9662 with multiprotocol processing support and 8-port LAN9668 switch. LAN966X includes copper and serial ethernet interfaces, peripheral interfaces such as PCIe, USB, TWI, SPI, UART, QSPI, SD/eMMC, Parallel Interface (PI) as well as synchronization and trigger inputs/outputs. Signed-off-by: Kavya Sree Kotagiri --- arch/arm/mach-at91/Kconfig | 13 +++++++++++++ arch/arm/mach-at91/Makefile | 1 + arch/arm/mach-at91/lan966x.c | 31 +++++++++++++++++++++++++++++++ 3 files changed, 45 insertions(+) create mode 100644 arch/arm/mach-at91/lan966x.c -- 2.17.1 diff --git a/arch/arm/mach-at91/Kconfig b/arch/arm/mach-at91/Kconfig index ccd7e80ce943..06cb425af761 100644 --- a/arch/arm/mach-at91/Kconfig +++ b/arch/arm/mach-at91/Kconfig @@ -122,6 +122,14 @@ config SOC_SAM9X60 help Select this if you are using Microchip's SAM9X60 SoC +config SOC_LAN966X + bool "ARMv7 based Microchip LAN966X SoC family" + depends on ARCH_MULTI_V7 + select SOC_LAN966 + select DW_APB_TIMER_OF + help + This enables support for ARMv7 based Microchip LAN966X SoC family. + comment "Clocksource driver selection" config ATMEL_CLOCKSOURCE_PIT @@ -188,6 +196,11 @@ config SOC_SAMA5 select SOC_SAM_V7 select SRAM if PM +config SOC_LAN966 + bool + select ARM_GIC + select MEMORY + config ATMEL_PM bool diff --git a/arch/arm/mach-at91/Makefile b/arch/arm/mach-at91/Makefile index f565490f1b70..93cfd5b4e6d4 100644 --- a/arch/arm/mach-at91/Makefile +++ b/arch/arm/mach-at91/Makefile @@ -6,6 +6,7 @@ # CPU-specific support obj-$(CONFIG_SOC_AT91RM9200) += at91rm9200.o obj-$(CONFIG_SOC_AT91SAM9) += at91sam9.o +obj-$(CONFIG_SOC_LAN966X) += lan966x.o obj-$(CONFIG_SOC_SAM9X60) += sam9x60.o obj-$(CONFIG_SOC_SAMA5) += sama5.o obj-$(CONFIG_SOC_SAMV7) += samv7.o diff --git a/arch/arm/mach-at91/lan966x.c b/arch/arm/mach-at91/lan966x.c new file mode 100644 index 000000000000..de689f854068 --- /dev/null +++ b/arch/arm/mach-at91/lan966x.c @@ -0,0 +1,31 @@ +// SPDX-License-Identifier: GPL-2.0-or-later +/* + * Setup code for LAN966X + * + * Copyright (C) 2021 Microchip Technology, Inc. and its subsidiaries + * + */ + +#include +#include + +#include +#include + +#include "generic.h" + +static void __init lan966x_dt_device_init(void) +{ + of_platform_default_populate(NULL, NULL, NULL); +} + +static const char *const lan966x_dt_board_compat[] __initconst = { + "microchip,lan966x", + NULL +}; + +DT_MACHINE_START(lan966x_dt, "Microchip LAN966X") + /* Maintainer: Microchip */ + .init_machine = lan966x_dt_device_init, + .dt_compat = lan966x_dt_board_compat, +MACHINE_END