From patchwork Thu Feb 8 13:50:33 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tudor Ambarus X-Patchwork-Id: 13549841 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 F2C39C4828F for ; Thu, 8 Feb 2024 13:51:10 +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=40qHNtm/hgoBmrr+aSEd1KwP5A9R5w9O7LDtxceCT/M=; b=C7vLYvT4OXwNoP j23NCEa7NDNZYp26tlVBOJbxYVIqEE2cfxEtkSoGsiP27QvPMZGg4BMs+y8d0kHSPLmWgnQuv/B4k atUeRR1Y4UwN8Af60psxzmo2447rGdzCb27UJYkbNpZc20mIqBVg8V4/2ro49C/nmlxHTKPRP619G HaVED0gkbiYfsSh9U3pwk6Tzg5HTRB8dAWRhINfZtD2/cBhcbU9PD6Ylz7TzYSeoZpm67TgE+YUCm aWaohSwFGWtEuNmHJlW1wcVlClFZy+7ef1Uj9+5a0L/uryzpH/3P9It9uoSy9rFQM3XfMgoSrTeDb TP8kqKJv6u5ZPZhBcOWQ==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1rY4nu-0000000DwXa-0x0Y; Thu, 08 Feb 2024 13:51:02 +0000 Received: from mail-wr1-x432.google.com ([2a00:1450:4864:20::432]) by bombadil.infradead.org with esmtps (Exim 4.97.1 #2 (Red Hat Linux)) id 1rY4nn-0000000DwUh-3fOq for linux-arm-kernel@lists.infradead.org; Thu, 08 Feb 2024 13:50:57 +0000 Received: by mail-wr1-x432.google.com with SMTP id ffacd0b85a97d-33b0ecb1965so1192149f8f.1 for ; Thu, 08 Feb 2024 05:50:54 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1707400253; x=1708005053; 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=ezIckqSjaHOJly+ofLnXueELrOHkQXapSLYglkjVtiI=; b=Ite8KQuuhgiVntj5CuIer/UaHCfEM3D9csjHBcF5U1WVnvOyV8y0pJsojccPGBj1Lb bG+qqWLsiqtH+f7UAWFqE4IZAWHWyHPxStuUg9pOCQyQHebB5Ylm/hVMILNR36Qy2lq0 4XlYMKWj9rpaqCQH3X2TQGhdg+8kJDe0CwnFvDJkoYszL8n48J0YcS+5JRHUff/WQkmc M56bel0jeZU98uYkZD+EnHZV0nGyNiEVtn/G3iYaNlIfT6mHtK3YxdERsJcmxUjgUNBa DK5+eEFzJ2RvEP5wk+H/ReogE/nq67dm8KgL9q5CmRbA3GKHJJKNhn0kjYUdi5g+mous nRYw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1707400253; x=1708005053; 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=ezIckqSjaHOJly+ofLnXueELrOHkQXapSLYglkjVtiI=; b=cPQpyMYcZGisOI39I49agi1D/XYnfC6IpGOhLISzbyfyWXElJON/5TQgR/vBD/FdoF I9DNGHphfUIC0uoGwagZI69BubZjOEO2lSUQuCIGzYyKGIppvEUajbu1kaTGHhLq9Q2z iKESnHbtv/To+wF6xc96SLLbUjFHHsQrp2PZdQWDsvrDE9cpkK8Ns8efvF1g5NjnaGR4 mnA9tdEEaK6+DnKOgH+CPIEHLsqnjZg5i/oPzmwoinIMk1/wFMmDnBfkKf7WfVz5oHrU iT50GQT+oyN5aDaktO2QBzBu5xKew3sNmsKN8C0HuF3pc3xFHSgS/vy7TIZHEGtdCRQE liRA== X-Gm-Message-State: AOJu0YzPNrvMZvSF36T/PbxZGzxXm4i76qA024hyNYonWM4mxWfJMZmF tVK816Sm2LP8DXczl1EZW8cKMZJ6AESJm0P7BIO67H1xi52tE1rpURz8dseVUNU= X-Google-Smtp-Source: AGHT+IHzTtRxu7JH2TlR7R5xySYChv9QNwLinyCxGoft1hqELdQlULHFUPWhMHqOWJvibWIos/yV1w== X-Received: by 2002:a05:6000:1208:b0:33b:3ceb:99cf with SMTP id e8-20020a056000120800b0033b3ceb99cfmr5543737wrx.67.1707400252929; Thu, 08 Feb 2024 05:50:52 -0800 (PST) X-Forwarded-Encrypted: i=1; AJvYcCUe+IA8lClHorFvbt+R7LYrtzl9JaTfah+IU2ztSQn2l67Okgaei3aZz4l8mQjnMAtX65LLUAuq8KW9RX6Xejg3SPycB7enkRe/JD4vuAn2TWGDR3OkAkhhA6sRJEL6DwLNi4bPyCsEw8KS35tAj4AoO23/RhqfO0hHVn6BtuwrWbtQarWlEBAXjxSyBRkRJtK6drm7xDeJqVbvghCVRDFnSVAwr8P9W1UevPnA/Q9uEKdvfdIo3awYkoDvyWIsVuWV/Sz8ELSzlPWZ1/ebQof/VC4yCEWVjOM6edN+zz2C31ItxIlhiTk+7zfkvfrRBckeQTH7BmHhOy7vfI8NUO5NoUI8+NxVrRzmbvUnQLxGcMjHn47EqK7KwS5w/xS5xCUoruB98DC17flAcA/9ykOzp2V3sH8vI3Rgp66FWjG5gUo1i3C0JaXSueYB/ZTrKtw07bjVaLDqaf8B1Psm5/0h89ZiSLkOe60LnwaGK4O/m7/DxtJcwYqOF2RjL3ehs2LBvTXU7v5aKH3uv1kr1rMIW25K/nNRqW+D+a0A2rBwBuNC5axZAmCLgjO0Q6cRcsVC/2p0aZJtHWDq0k+R/YMFrKombP0nST5YR2EjSg== 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.50.52 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 08 Feb 2024 05:50:52 -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 00/12] spi: s3c64xx: remove OF alias ID dependency Date: Thu, 8 Feb 2024 13:50:33 +0000 Message-ID: <20240208135045.3728927-1-tudor.ambarus@linaro.org> X-Mailer: git-send-email 2.43.0.687.g38aa6559b0-goog MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240208_055055_952472_9DC63A8F X-CRM114-Status: UNSURE ( 9.84 ) X-CRM114-Notice: Please train this message. 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 The driver was wrong as it assumed that the alias values in devicetree have a particular meaning in identifying instances. This immediately breaks when there is a dtb file that does not use the same alias values, e.g. because it only needs some of the SPI ports. Tested gs101 SPI with spi-loopback-test, all went fine. I updated exynos850 as it uses the same USI.SPI_VERSION as gs101. Maybe Sam can test exynos850, if not, we can drop that patch. The patch set has some dependencies. One has to apply first the gs101 addition [1], then the simple cleanup from [2], then this patch set. [1] https://lore.kernel.org/linux-spi/20240207111516.2563218-1-tudor.ambarus@linaro.org/ [2] https://lore.kernel.org/linux-spi/20240207120431.2766269-1-tudor.ambarus@linaro.org/ Cheers, ta Tudor Ambarus (12): spi: dt-bindings: introduce the ``fifo-depth`` property spi: s3c64xx: define a magic value spi: s3c64xx: allow full FIFO masks spi: s3c64xx: determine the fifo depth only once spi: s3c64xx: retrieve the FIFO depth from the device tree spi: s3c64xx: allow FIFO depth to be determined from the compatible spi: s3c64xx: let the SPI core determine the bus number spi: s3c64xx: introduce s3c64xx_spi_set_port_id() spi: s3c64xx: get rid of the OF alias ID dependency spi: s3c64xx: deprecate fifo_lvl_mask, rx_lvl_offset and port_id spi: s3c64xx: switch gs101 to new port config data spi: s3c64xx: switch exynos850 to new port config data .../bindings/spi/spi-controller.yaml | 5 + drivers/spi/spi-s3c64xx.c | 142 ++++++++++++++---- 2 files changed, 116 insertions(+), 31 deletions(-)