From patchwork Thu Dec 28 12:57:53 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tudor Ambarus X-Patchwork-Id: 13505985 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 01E76C3DA6E for ; Thu, 28 Dec 2023 12:58:39 +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: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=v6EuzkxEdyrY2nMKwTkVzU38U9bSSexSsAadunBGWIc=; b=rjUR50xjQUyYlW lbMGfYYl4dwIBPowCSddfv5z8a0Hr6lz3LLSTH0/Vc66pvwn1AuHdGgbN2EpLxHMUo/HaCs0cbHDP a4NHk3agXuTPg5TlGfg+slrHDO1oJFx0bl0jnxo2PSGutRJP9D72bHtibaPZNIs9DTLAI1JuTPSgo k2Su0dh+lcFX6fdlLOSCEboSiyqjexl1e1jBbVrEObySiBQuzsyzMk3JB8jOQicnLDym7EnWL/GcK Iz+KbJ1h+V8xfBGbqqrYBehnTLDN6IcooXDq1PhIz5uPNSqQTbOe4O/eb0qZebfrZXCEqueLiB1OZ MJsWBpF7fcw5kuoO1QqA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1rIpxo-00GqzA-0l; Thu, 28 Dec 2023 12:58:16 +0000 Received: from mail-wm1-x332.google.com ([2a00:1450:4864:20::332]) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1rIpxl-00Gqxf-0r for linux-arm-kernel@lists.infradead.org; Thu, 28 Dec 2023 12:58:14 +0000 Received: by mail-wm1-x332.google.com with SMTP id 5b1f17b1804b1-40d5095834aso40487925e9.2 for ; Thu, 28 Dec 2023 04:58:12 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703768291; x=1704373091; darn=lists.infradead.org; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=PsbdU9VAZ2t0ZraxiZCzdliAmxrS9fPUQ39YR7Q+Pfc=; b=NFYw0twrz503wvtR5WihEYkOh6rHDp9qMU8pRDUfDoD9DVaEUkD/sBb3rdthNkwzY7 s5hMeGsg/JS+/Lkc/IA2LGDc+uk9AUHkWSXovZS7fmUOwJjdy/YBQHx22yE6kyJJbwpq tFY0dvLI94OxV/crBE0etRoTBC8yVY00r11um32AwsgdJRkRozpOM7IZXrHqjsrO9qcr niQAxrSXMmrTb9kkq538u3T6xKGC9WlgUEiNbGjmwGRu8DfMgru0PUOi6fQwrX/7NDCB lRcWx6usuuKaYqdiDY4PCBLn1CS9rRmL79/iohqGkz+WbFLU1cxRBpJZJW3GItxW47Sf K0BA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703768291; x=1704373091; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=PsbdU9VAZ2t0ZraxiZCzdliAmxrS9fPUQ39YR7Q+Pfc=; b=ZU5+/LDsg1ZhXOHZT7EiVgKFyAoTVPguTxFT9THmFsc6CnUZ9F3CbjavvUKq+Ue5rc CHOJNcb9qjripOUdT0gBJ19a2h9GKk6YpgokZWvMn45fS5Ra8YPItXjdX+xpSgwEGV+L yF/b3pVNp10hCKJ68Ya44vYTU3EoQLYoamByLReCkJHc4a9XffXObKUA08bCKt/jIo49 QC8agltKH5Rth5IKPdPlTKtxTYwqOIg7CQwqV0fg1UD4F8Hyzjqkbtc9YybyqmBiq1ZV 2Ix+SFN4GV9COsPgCZh3EUcK+DAKJdTFUQC8QzWX79ew1U0uyA9mIIT/f6FZAc220xNH a4/Q== X-Gm-Message-State: AOJu0Yw+qCarmY/zUpUBzXI133uc8HNYMMle1KqMETGEhjy8Jfq3qBn4 rziiN8Dxuar05Wci99E6USRBLND3eaHgnA== X-Google-Smtp-Source: AGHT+IGT7Y/qsBkm1bYAfjc8+SVNa4uWWCNwMUN+bOyOZVmpbQ+Xf82nttKJqv9IsUBfmEvzJTA/nQ== X-Received: by 2002:a05:600c:468c:b0:40d:4d91:609b with SMTP id p12-20020a05600c468c00b0040d4d91609bmr2711558wmo.355.1703768290528; Thu, 28 Dec 2023 04:58:10 -0800 (PST) Received: from ta2.c.googlers.com.com (216.131.76.34.bc.googleusercontent.com. [34.76.131.216]) by smtp.gmail.com with ESMTPSA id h9-20020a05600c350900b0040d5aca25f1sm8615807wmq.17.2023.12.28.04.58.09 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 28 Dec 2023 04:58:09 -0800 (PST) From: Tudor Ambarus To: peter.griffin@linaro.org, robh+dt@kernel.org, krzysztof.kozlowski+dt@linaro.org, mturquette@baylibre.com, sboyd@kernel.org, conor+dt@kernel.org, andi.shyti@kernel.org, alim.akhtar@samsung.com, gregkh@linuxfoundation.org, jirislaby@kernel.org, s.nawrocki@samsung.com, tomasz.figa@gmail.com, cw00.choi@samsung.com, arnd@arndb.de, semen.protsenko@linaro.org Cc: andre.draszik@linaro.org, saravanak@google.com, willmcvicker@google.com, linux-arm-kernel@lists.infradead.org, linux-samsung-soc@vger.kernel.org, linux-clk@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-i2c@vger.kernel.org, linux-serial@vger.kernel.org, kernel-team@android.com, Tudor Ambarus Subject: [PATCH v2 00/12] GS101 Oriole: CMU_PERIC0 support and USI updates Date: Thu, 28 Dec 2023 12:57:53 +0000 Message-ID: <20231228125805.661725-1-tudor.ambarus@linaro.org> X-Mailer: git-send-email 2.43.0.472.g3155946c3a-goog MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20231228_045813_361068_BD128C65 X-CRM114-Status: GOOD ( 13.46 ) 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 PERIC0 clocks. Use them for USI in serial and I2C configurations. Tested the serial at different baudrates (115200, 1M, 3M) and the I2C with an at24 eeprom, all went fine. Apart of the DT and defconfig changes, the patch set spans through the tty and clk subsystems. The expectation is that Krzysztof will apply the whole series through the Samsung SoC tree. If the tty and clk subsystem maintainers can give an acked-by or reviewed-by on the relevant patches that would be most appreciated! Thanks! ta changes in v2: - gs101 serial - infer the reg-io-width from the compatible as the entire PERIC block allows just 32-bit register accesses. - identify the critical clocks from PERIC0 and mark them accordingly (if disabled these clocks hang the system even if their parents are still enabled). - update dtsi and use USI's gate clocks instead of the dividers clocks - move hsi2c_8 cells and pinctrls into dtsi - address Sam's cosmetic changes in the device tree files - drop defconfig patches (savedefconfig output & at24 eeprom enablement) - collect Acked-by and Reviewed-by tags - changes log in each patch as well, in the comments section under ```---``` Tudor Ambarus (12): dt-bindings: clock: google,gs101-clock: add PERIC0 clock management unit dt-bindings: i2c: exynos5: add google,gs101-hsi2c compatible dt-bindings: serial: samsung: do not allow reg-io-width for gs101 tty: serial: samsung: prepare for different IO types tty: serial: samsung: set UPIO_MEM32 iotype for gs101 tty: serial: samsung: add gs101 earlycon support clk: samsung: gs101: add support for cmu_peric0 arm64: dts: exynos: gs101: remove reg-io-width from serial arm64: dts: exynos: gs101: enable cmu-peric0 clock controller arm64: dts: exynos: gs101: update USI UART to use peric0 clocks arm64: dts: exynos: gs101: define USI8 with I2C configuration arm64: dts: exynos: gs101: enable eeprom on gs101-oriole .../bindings/clock/google,gs101-clock.yaml | 25 +- .../devicetree/bindings/i2c/i2c-exynos5.yaml | 1 + .../bindings/serial/samsung_uart.yaml | 2 + .../boot/dts/exynos/google/gs101-oriole.dts | 14 + arch/arm64/boot/dts/exynos/google/gs101.dtsi | 56 +- drivers/clk/samsung/clk-gs101.c | 583 ++++++++++++++++++ drivers/tty/serial/samsung_tty.c | 58 +- include/dt-bindings/clock/google,gs101.h | 81 +++ 8 files changed, 796 insertions(+), 24 deletions(-)