From patchwork Fri Jun 10 09:24:13 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Claudiu Beznea X-Patchwork-Id: 12877140 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 D2C5CC433EF for ; Fri, 10 Jun 2022 09:27:31 +0000 (UTC) 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:References:In-Reply-To: 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: List-Owner; bh=qNfhh9ivYyrS44HEb+5UoGC/xfISDfi8engFbSWraQQ=; b=J+W2DqowROZHdZ tW7hMMvhPxTzqfuWzap/yBbnhvQP/YxNqJ2Y+0gZ/xT69tifPTr2NDJ+pSagQtTG8r4bH2NQ6Msij fJYht0BmEkjnS/My/ho7ysKfgKecPx6Npl22Aroa5kpM4lAsaWQ3EEsV8AT6n8m09qsa52QbuMc0H MQag3CdYPhPqCRAnXEszwouOfle/+UbyXMg3re1XXvWx1khhdXpq1SSwip6UZFS2d6mQJyN7SFGIo HXIXtGlZ91HRNazqeJCtAGQvOBfz6xJgCyBLbYLdnyAusKgVT7L5o53Xv4y5hGWbfr2WESUInS876 74pFqjh7zr+oOAR0+HXA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1nzauR-00793c-Ma; Fri, 10 Jun 2022 09:26:28 +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 1nzar1-0077Aw-98 for linux-arm-kernel@lists.infradead.org; Fri, 10 Jun 2022 09:22:56 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=microchip.com; i=@microchip.com; q=dns/txt; s=mchp; t=1654852975; x=1686388975; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=FtrPQo6eJC0n8mbpc1MGOlIBMfbjD6HScBOn5JTyeWQ=; b=wPzzea6mJeHfNiBo4zUXReJctj/Bb1vIPSuwy5S+9m3LRAlz6fOFU7KQ 4JeayNGbqLQPzJEl+34ncQwaryeXUQhHpLcPoeVf9SBM58d3XxS7KmJW4 3nUnNqpBIuJjIhpPWpT3DDnz+F1MRO5f8hXg7vtpgonucC4X7yMzc+v69 XlJQ61suuFkj8NeFqLiqD7suIiS8Cz3IDCMVQOVW/LjS4ERL39AyqNlm6 6tMLwzpMTfYRRQnhRp1yRrbh+s1WbFJljjNzhFYFaHasLyoB+EsJ4L0Xy ABMN/Vp1URZOgePIJQtTaDlhqzGc1wZq/NeYgFrjAXAJ03/dyxI4nxf0B Q==; X-IronPort-AV: E=Sophos;i="5.91,288,1647327600"; d="scan'208";a="167889078" Received: from unknown (HELO email.microchip.com) ([170.129.1.10]) by esa3.microchip.iphmx.com with ESMTP/TLS/AES256-SHA256; 10 Jun 2022 02:22:54 -0700 Received: from chn-vm-ex04.mchp-main.com (10.10.85.152) by chn-vm-ex01.mchp-main.com (10.10.85.143) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.17; Fri, 10 Jun 2022 02:22:54 -0700 Received: from localhost.localdomain (10.10.115.15) by chn-vm-ex04.mchp-main.com (10.10.85.152) with Microsoft SMTP Server id 15.1.2375.17 via Frontend Transport; Fri, 10 Jun 2022 02:22:50 -0700 From: Claudiu Beznea To: , , , , , CC: , , , , Claudiu Beznea Subject: [PATCH v5 8/9] power: reset: at91-reset: add support for SAMA7G5 Date: Fri, 10 Jun 2022 12:24:13 +0300 Message-ID: <20220610092414.1816571-9-claudiu.beznea@microchip.com> X-Mailer: git-send-email 2.33.0 In-Reply-To: <20220610092414.1816571-1-claudiu.beznea@microchip.com> References: <20220610092414.1816571-1-claudiu.beznea@microchip.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220610_022255_401143_8D179C43 X-CRM114-Status: GOOD ( 11.48 ) 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 Add support for SAMA7G5 including reset_controller_dev support for 3 lines (which are USB PHYs). Signed-off-by: Claudiu Beznea --- drivers/power/reset/at91-reset.c | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/drivers/power/reset/at91-reset.c b/drivers/power/reset/at91-reset.c index bc9f1d9e7867..741e44a017c3 100644 --- a/drivers/power/reset/at91-reset.c +++ b/drivers/power/reset/at91-reset.c @@ -22,6 +22,8 @@ #include #include +#include + #define AT91_RSTC_CR 0x00 /* Reset Controller Control Register */ #define AT91_RSTC_PROCRST BIT(0) /* Processor Reset */ #define AT91_RSTC_PERRST BIT(2) /* Peripheral Reset */ @@ -206,6 +208,13 @@ static const struct at91_reset_data samx7 = { .reset_args = AT91_RSTC_KEY | AT91_RSTC_PROCRST, }; +static const struct at91_reset_data sama7g5 = { + .reset_args = AT91_RSTC_KEY | AT91_RSTC_PROCRST, + .n_device_reset = 3, + .device_reset_min_id = SAMA7G5_RESET_USB_PHY1, + .device_reset_max_id = SAMA7G5_RESET_USB_PHY3, +}; + static const struct of_device_id at91_reset_of_match[] = { { .compatible = "atmel,at91sam9260-rstc", @@ -227,6 +236,10 @@ static const struct of_device_id at91_reset_of_match[] = { .compatible = "microchip,sam9x60-rstc", .data = &samx7, }, + { + .compatible = "microchip,sama7g5-rstc", + .data = &sama7g5, + }, { /* sentinel */ } }; MODULE_DEVICE_TABLE(of, at91_reset_of_match);