From mboxrd@z Thu Jan 1 00:00:00 1970 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 phobos.denx.de (phobos.denx.de [85.214.62.61]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 1F76EC433EF for ; Wed, 16 Mar 2022 15:28:29 +0000 (UTC) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 8767883955; Wed, 16 Mar 2022 16:28:26 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=none (p=none dis=none) header.from=amarulasolutions.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (1024-bit key; unprotected) header.d=amarulasolutions.com header.i=@amarulasolutions.com header.b="l3s9n+/7"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id F3F4983ADA; Wed, 16 Mar 2022 16:28:22 +0100 (CET) Received: from mail-ej1-x62b.google.com (mail-ej1-x62b.google.com [IPv6:2a00:1450:4864:20::62b]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id BD3DC83CA8 for ; Wed, 16 Mar 2022 16:28:16 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=none (p=none dis=none) header.from=amarulasolutions.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=tommaso.merciai@amarulasolutions.com Received: by mail-ej1-x62b.google.com with SMTP id hw13so4912352ejc.9 for ; Wed, 16 Mar 2022 08:28:16 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amarulasolutions.com; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=I3doQQRpxNdmK7OXLUgLA4zmjIYN9IYO6GRW7dtU4DU=; b=l3s9n+/7DQdBi7xKXFwiEmDRq7zPRPXq7VnzAIaNpbOc4U1AiKDUuzTalqR7OpWoEq s48m+HrsPMcbTUTVxXSdIDrTMJosfSpeu/e6POQprWrk2f6BQPw22DayBanxKupi9WUU kpNpaEfnlvxNoFS8+E7yLOIx84S35eYUUcD1g= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=I3doQQRpxNdmK7OXLUgLA4zmjIYN9IYO6GRW7dtU4DU=; b=ZWv6E2Z4T+HAg7EHdSgz17NzGTvru8Qnm0akf9q18JtNKKxjLocuErSYm5N1CBVcSV +Nnd85ulL83g8somNckpG0eOzV0QWvxvt5OJ3lSD1tiI5nl4LvBJ/POW6z3zpuMoZzx7 g9mynBBl178KaI/rC0XSeqO5mkk7I4ChvEh9aFjWYJ6yvLT5DkHzZrAcbdTdSOKmdKJP zWI4R9tfI2nWxerP7k88DH0AqtyiQ0M+thRyq94M9YziJTHCWumJXN1wUdqRqfzK5xv4 kwpvsNgYktDgcZ1LamMpzohvqiazRTka94PI6Dcxd9V1ZHy5L68cBfIzNyW59KkvZeCb 3qjQ== X-Gm-Message-State: AOAM531PywdH0uBoTFdDSUWKYZBS7TvnttM5SkWMgymiDmIcLUbidg09 TTZWMnmWnmoNdQUG7sp1OhGYdw== X-Google-Smtp-Source: ABdhPJwhF2h6Mu15mRU+s2whiL6loDANib0SnPnX2SXuq6DpylfU+BnmShG5WJ04WJ+gx+uThgwlJw== X-Received: by 2002:a17:907:97c7:b0:6da:b3ba:6d9f with SMTP id js7-20020a17090797c700b006dab3ba6d9fmr480554ejc.256.1647444496327; Wed, 16 Mar 2022 08:28:16 -0700 (PDT) Received: from tom-ThinkPad-T14s-Gen-2i.station (net-188-217-56-61.cust.vodafonedsl.it. [188.217.56.61]) by smtp.gmail.com with ESMTPSA id v10-20020a170906380a00b006a68610908asm1022219ejc.24.2022.03.16.08.28.15 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 16 Mar 2022 08:28:16 -0700 (PDT) From: Tommaso Merciai To: Cc: tommaso.merciai@amarulasolutions.com, Peng Fan , Andrey Zhizhikin , Alice Guo , Ye Li , u-boot@lists.denx.de Subject: [PATCH v2 2/9] arch: mach-imx: imx8m: add pwm ctrl registers fields defines Date: Wed, 16 Mar 2022 16:27:38 +0100 Message-Id: <20220316152746.47768-3-tommaso.merciai@amarulasolutions.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20220316152746.47768-1-tommaso.merciai@amarulasolutions.com> References: <20220316152746.47768-1-tommaso.merciai@amarulasolutions.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.39 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" X-Virus-Scanned: clamav-milter 0.103.5 at phobos.denx.de X-Virus-Status: Clean Add pwm control registers fields defines into imx-regs.h: - prescaler - dozeen - waiten - dbgen - clksrc_ipg_high - clksrc_ipg, en field References: - iMX8MMRM.pdf p 3884 Signed-off-by: Tommaso Merciai --- arch/arm/include/asm/arch-imx8m/imx-regs.h | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/arch/arm/include/asm/arch-imx8m/imx-regs.h b/arch/arm/include/asm/arch-imx8m/imx-regs.h index 38f8ba41c3..13538ba5f6 100644 --- a/arch/arm/include/asm/arch-imx8m/imx-regs.h +++ b/arch/arm/include/asm/arch-imx8m/imx-regs.h @@ -353,6 +353,14 @@ struct src { u32 ddr2_rcr; }; +#define PWMCR_PRESCALER(x) (((x - 1) & 0xFFF) << 4) +#define PWMCR_DOZEEN (1 << 24) +#define PWMCR_WAITEN (1 << 23) +#define PWMCR_DBGEN (1 << 22) +#define PWMCR_CLKSRC_IPG_HIGH (2 << 16) +#define PWMCR_CLKSRC_IPG (1 << 16) +#define PWMCR_EN (1 << 0) + #define WDOG_WDT_MASK BIT(3) #define WDOG_WDZST_MASK BIT(0) struct wdog_regs { -- 2.25.1