Received: by 2002:a05:7412:3b8b:b0:fc:a2b0:25d7 with SMTP id nd11csp283874rdb; Thu, 8 Feb 2024 06:04:49 -0800 (PST) X-Google-Smtp-Source: AGHT+IFaDB6SLfrf+pq7XK7PlGIBtnRo/teHZu+ae/BXbK1WEUUVlTSt5FwIrUgvnz1dp0JPSY9F X-Received: by 2002:a05:6a20:8622:b0:19c:9ac1:4347 with SMTP id l34-20020a056a20862200b0019c9ac14347mr5875689pze.34.1707401089089; Thu, 08 Feb 2024 06:04:49 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1707401089; cv=pass; d=google.com; s=arc-20160816; b=H18j9gUpT1HWkXG3Hc47hwy4p+kS/WfvcLc8tLLYuNlYYPQGgpmBJJN71DovFYDNbT 6GbA915Ndw06foVmk0E+va8D8jzE5lgkrZILJsqsyviC6jEvIw9Zo3bIUQhvZTRfe2lA cgU4WnDk3roRYs//DstEaXQhohTsGiaOGsvpi380dHTLpEF6YMUva4mgHNDwPbhgc4pJ AbRtQK7iF2kthVPw6deLMCeX4uMKxSsqfETJUKF2wPV8KsklKahgRQVtwb2hGR+WIzVd 9FYdDo9L969oNEU1vJFKqclpi4b1d1WMKxyaJSY2Eu5usGLNRvdAEcaNrPuTDzeU7u2S Whsg== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:in-reply-to:message-id :date:subject:cc:to:from:dkim-signature; bh=dzqxKaIV5lycuIt7a1okhuIIh6nU9oeZCJpLQ+HKFAg=; fh=YmwCA6JA0gjJtFC6FBzpxkcDwGhY44bFdscCko65Ltk=; b=qRt/cxs2nf2/SH4kzk2+cDcEpwfnB56+eOt42jcdi/ZOCtTihwf7IKIFu7DG/10KZE ZWt6fkXVSAcvUU3tR089ULIaE04q9jDuwF5WqPZvuofxEijsKMHQY7QUkiMgajj60/s1 mu7P5nRLvpOZlawvSCpGBR5vvsIMXrxWmBxfqg8vIPM2MXWsl9IHVk/LFcJccYS5Pc4M 0AKNh2oJ8+yHl/OQXif2LYesXV6XnR0YvN7y7hTMDTvUeHWn6/9sifPx0mMJxFh1zUMn OL60zC5AHm4saJ8Z9w1tcUM8e/vAUbIYwFyjoib9Z90WQviiUZcmkSN2jhWj2KOU0It5 Dj4Q==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=MfDQL3PU; arc=pass (i=1 spf=pass spfdomain=linaro.org dkim=pass dkdomain=linaro.org dmarc=pass fromdomain=linaro.org); spf=pass (google.com: domain of linux-kernel+bounces-58187-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-58187-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org X-Forwarded-Encrypted: i=2; AJvYcCVdOAZso/w2Begp7tUkAlEU5U/DsJTHRqIir6bgjBIPNu8upe2os0nCpRc9B0fUDZgp37a9eqTwOjV5qPV6mdtZ/GTUHuMWA/bUeTpe9A== Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [2604:1380:45e3:2400::1]) by mx.google.com with ESMTPS id q201-20020a632ad2000000b005cd783d410csi3799603pgq.610.2024.02.08.06.04.48 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 08 Feb 2024 06:04:49 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-58187-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) client-ip=2604:1380:45e3:2400::1; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=MfDQL3PU; arc=pass (i=1 spf=pass spfdomain=linaro.org dkim=pass dkdomain=linaro.org dmarc=pass fromdomain=linaro.org); spf=pass (google.com: domain of linux-kernel+bounces-58187-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-58187-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id DA7E92818DF for ; Thu, 8 Feb 2024 13:53:52 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id E136B823BA; Thu, 8 Feb 2024 13:51:09 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b="MfDQL3PU" Received: from mail-wm1-f48.google.com (mail-wm1-f48.google.com [209.85.128.48]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id A98CF7EF0C for ; Thu, 8 Feb 2024 13:51:06 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.128.48 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707400269; cv=none; b=iVJ4tjUNVY7wUWIZLd+pOx7zKBhgATR1SwYKC3SyGHW9isx8VuiktYyO78wWIdaZvHzuULaYcLB7cPY+jULGUgYsGOFzmfbluTiJ/opDPBCAsjcQAa8ryxUQ8DwNPYq0jMULXRq+rpsyDY8aXLyNfYli5PrpW98jdiu7DutvAt8= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707400269; c=relaxed/simple; bh=QDMQ1KkcYtiV6MjOl7LHm4vYVsmfWSXZLbn40VwBYc8=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=YqDLrnD9Y3TMpdYZBftGCv2AgfybpmMedniKc3StTaE4e0VaScGtj3HUncYW8nHencw5PY9htij7csQuC/xPEqjChQinhigtmlBvSqEHP8VYFsox5PCYm40TnAlmLlrlZ5H4liFkQPty0PCM7CitFE3asCnl4f6jJ4bG73yURCU= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org; spf=pass smtp.mailfrom=linaro.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b=MfDQL3PU; arc=none smtp.client-ip=209.85.128.48 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linaro.org Received: by mail-wm1-f48.google.com with SMTP id 5b1f17b1804b1-4104ebb01fdso1355435e9.2 for ; Thu, 08 Feb 2024 05:51:06 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1707400265; x=1708005065; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=dzqxKaIV5lycuIt7a1okhuIIh6nU9oeZCJpLQ+HKFAg=; b=MfDQL3PUQaKxfMJmVH5Lu7nQMEdxejTo9BdsdN0SGShXXgCtgCk8RpNeO/C7PeSkAR hdo3mfmUdNY+HRbQU3+Sr+Fmolc9dN9gnKbJuOopFyHksLUBYh1ytrOI3P/ZOXcN5Cm6 gptbT43sdpVXufKe51qwZwCADuvyiM/6yuc1m+30/G+VfUll4TOljgKUuFB/nvCE15xD aoUwxyXsiSXu2GS/C1A5tljTIrVZFLGCus9KVt4cmV0q8iMHgPGyhWc+CAIpu8xX/8Dl FhvpGfqqqKKQMU1Oex2cSLstzDrtvNk47LacbwLWEmf70JlZz3N2RScpKsjzHVwBNeUV rENA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1707400265; x=1708005065; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=dzqxKaIV5lycuIt7a1okhuIIh6nU9oeZCJpLQ+HKFAg=; b=FpbfKTKWSbk35OeU/vYkltgXR3PtGcdWiLGaVzo0CXqmZfK934+lzgtXJC/4HN1Wdy NkWHBL/5/UPOJGcE5XtyPiDh5f1d/ERNXgf/rseTeva4WsrfpRLVoU59UXqF31p/fJVX CzhuzdxY7irPigjWWqxIRhhfF1p86XIqXT5OeWOrHOHXrZrRrLztLDTYJ9fZJtCCkv9w qFKLjXop+ZIiALtEa3MWaX58Kvsg4lDBljWLxDMjpOEQvaa2XZHpkP1QoDFsVAPOQFZP SQaJEjMZRXRlTdxJjb7FiAur7vAJ1mqKhdaMDFWXUy3x0TEx86n9faBkPCYTEFdQ8Ebk N+kw== X-Gm-Message-State: AOJu0YwqByOo/sZbsBBu1IRjxpUVBYF65J2mMw+d1VJy74nnp/52Dv9F wb0BVrsh1tAr7GFmzq5/t6MuECoD1T4QIN/S0nal/2LeQNpaq117Qj18Cnok8XY= X-Received: by 2002:a5d:5915:0:b0:33b:5955:80f0 with SMTP id v21-20020a5d5915000000b0033b595580f0mr1256423wrd.21.1707400265049; Thu, 08 Feb 2024 05:51:05 -0800 (PST) X-Forwarded-Encrypted: i=1; AJvYcCV0g5/QpwgVtEE+r/3+XY/sOhedUizACmG5fdHi6VpzcVaBsZdi6cByCvkvZEIO3ZlW0QNef4727PNWVfQtjQwvDhW1c7sA99vH/Z4wwTJfAGNmblZzzuSb5q1yC1jSXHQrao9emy/77l6oVWMPbvObQWFw5cIycpm/owUy/H/OLpkobNFWm1Tdp2UGNHkPIKuUfDBsyzu1q+V+h2Po6cxe5dQg6Ey9ZfwkbiPLWeGHwq790T9/hORNfXtVSgPg7xruKOfADvxxggItqPiohmyoRw2tD+at0PCxH3cDmNPoNFdtNVIztl6r6NNnfrPF9Y92iyFO45RpqCJnP29SiuJpMeDHDKEAbSvSS4AU3KpJIgxSXAJh1Tr+JElVQPaoy6dOKTzOK4pxZ4GVRbY8TZw/DGqD2AwryQvg03FXsJ/JJEvGj6gjeubnozOKzfLoMLQkMQyIg+pb6LKH1p8oOu8MqhFOj4OdBhwIrU9arwKijcC+edxb7O/eeQSqi4JZOXhe00lwMdT1ff2sGKJeafo8ZB7xqb87ZyxkBCNjSrnQj2qLYnNbWnlUQ+6Qn4R09EPNXTrnFq0pwZaYpt4WSS6DvZBxu/ey/S2MWvhLuQ== Received: from ta2.c.googlers.com.com (105.168.195.35.bc.googleusercontent.com. [35.195.168.105]) by smtp.gmail.com with ESMTPSA id m20-20020a056000181400b0033b43a5f53csm3618820wrh.103.2024.02.08.05.51.04 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 08 Feb 2024 05:51:04 -0800 (PST) From: Tudor Ambarus To: broonie@kernel.org, robh@kernel.org, andi.shyti@kernel.org, semen.protsenko@linaro.org Cc: krzysztof.kozlowski@linaro.org, alim.akhtar@samsung.com, linux-spi@vger.kernel.org, linux-samsung-soc@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, andre.draszik@linaro.org, peter.griffin@linaro.org, kernel-team@android.com, willmcvicker@google.com, conor+dt@kernel.org, devicetree@vger.kernel.org, arnd@arndb.de, Tudor Ambarus Subject: [PATCH 12/12] spi: s3c64xx: switch exynos850 to new port config data Date: Thu, 8 Feb 2024 13:50:45 +0000 Message-ID: <20240208135045.3728927-13-tudor.ambarus@linaro.org> X-Mailer: git-send-email 2.43.0.687.g38aa6559b0-goog In-Reply-To: <20240208135045.3728927-1-tudor.ambarus@linaro.org> References: <20240208135045.3728927-1-tudor.ambarus@linaro.org> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Exynos850 has the same version of USI SPI (v2.1) as GS101. Drop the fifo_lvl_mask and rx_lvl_offset and switch to the new port config data. Backward compatibility with DT is not broken because when alises are set: - the SPI core will set the bus number according to the alias ID - the FIFO depth is always the same size for exynos850 (64 bytes) no matter the alias ID number. Advantages of the change: - drop dependency on the OF alias ID. - FIFO depth is inferred from the compatible. Exynos850 integrates 3 SPI IPs, all with 64 bytes FIFO depths. - use full mask for SPI_STATUS.{RX, TX}_FIFO_LVL fields. Using partial masks is misleading and can hide problems of the driver logic. Just compiled tested. Signed-off-by: Tudor Ambarus --- drivers/spi/spi-s3c64xx.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/drivers/spi/spi-s3c64xx.c b/drivers/spi/spi-s3c64xx.c index 784786407d2e..9fcbe040cb2f 100644 --- a/drivers/spi/spi-s3c64xx.c +++ b/drivers/spi/spi-s3c64xx.c @@ -1576,10 +1576,9 @@ static const struct s3c64xx_spi_port_config exynos5433_spi_port_config = { }; static const struct s3c64xx_spi_port_config exynos850_spi_port_config = { - /* fifo_lvl_mask is deprecated. Use {rx, tx}_fifomask instead. */ - .fifo_lvl_mask = { 0x7f, 0x7f, 0x7f }, - /* rx_lvl_offset is deprecated. Use {rx, tx}_fifomask instead. */ - .rx_lvl_offset = 15, + .fifo_depth = 64, + .rx_fifomask = S3C64XX_SPI_ST_RX_FIFO_RDY_V2, + .tx_fifomask = S3C64XX_SPI_ST_TX_FIFO_RDY_V2, .tx_st_done = 25, .clk_div = 4, .high_speed = true, -- 2.43.0.687.g38aa6559b0-goog