linux-spi.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] spi: lantiq-ssc: Convert to use GPIO descriptors
@ 2020-06-25 20:21 Linus Walleij
  2020-07-01 22:24 ` Mark Brown
  0 siblings, 1 reply; 2+ messages in thread
From: Linus Walleij @ 2020-06-25 20:21 UTC (permalink / raw)
  To: Mark Brown, linux-spi; +Cc: Linus Walleij, Hauke Mehrtens

This switches the Lantiq SSC driver over to use GPIO descriptor
handling in the core.

The driver was already utilizing the core to look up and request
GPIOs from the device tree so this is a pretty small change
just switching it over to use descriptors directly instead.

Cc: Hauke Mehrtens <hauke@hauke-m.de>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
---
 drivers/spi/spi-lantiq-ssc.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/spi/spi-lantiq-ssc.c b/drivers/spi/spi-lantiq-ssc.c
index 1fd7ee53d451..1cf650e25e31 100644
--- a/drivers/spi/spi-lantiq-ssc.c
+++ b/drivers/spi/spi-lantiq-ssc.c
@@ -15,7 +15,6 @@
 #include <linux/completion.h>
 #include <linux/spinlock.h>
 #include <linux/err.h>
-#include <linux/gpio.h>
 #include <linux/pm_runtime.h>
 #include <linux/spi/spi.h>
 
@@ -391,7 +390,7 @@ static int lantiq_ssc_setup(struct spi_device *spidev)
 	u32 gpocon;
 
 	/* GPIOs are used for CS */
-	if (gpio_is_valid(spidev->cs_gpio))
+	if (spidev->cs_gpiod)
 		return 0;
 
 	dev_dbg(spi->dev, "using internal chipselect %u\n", cs);
@@ -888,6 +887,7 @@ static int lantiq_ssc_probe(struct platform_device *pdev)
 
 	master->dev.of_node = pdev->dev.of_node;
 	master->num_chipselect = num_cs;
+	master->use_gpio_descriptors = true;
 	master->setup = lantiq_ssc_setup;
 	master->set_cs = lantiq_ssc_set_cs;
 	master->handle_err = lantiq_ssc_handle_err;
-- 
2.25.4


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] spi: lantiq-ssc: Convert to use GPIO descriptors
  2020-06-25 20:21 [PATCH] spi: lantiq-ssc: Convert to use GPIO descriptors Linus Walleij
@ 2020-07-01 22:24 ` Mark Brown
  0 siblings, 0 replies; 2+ messages in thread
From: Mark Brown @ 2020-07-01 22:24 UTC (permalink / raw)
  To: linux-spi, Linus Walleij; +Cc: Hauke Mehrtens

On Thu, 25 Jun 2020 22:21:49 +0200, Linus Walleij wrote:
> This switches the Lantiq SSC driver over to use GPIO descriptor
> handling in the core.
> 
> The driver was already utilizing the core to look up and request
> GPIOs from the device tree so this is a pretty small change
> just switching it over to use descriptors directly instead.

Applied to

   https://git.kernel.org/pub/scm/linux/kernel/git/broonie/spi.git for-next

Thanks!

[1/1] spi: lantiq-ssc: Convert to use GPIO descriptors
      commit: 95f2fd2e52a49b76f896e03802123567b8a89912

All being well this means that it will be integrated into the linux-next
tree (usually sometime in the next 24 hours) and sent to Linus during
the next merge window (or sooner if it is a bug fix), however if
problems are discovered then the patch may be dropped or reverted.

You may get further e-mails resulting from automated or manual testing
and review of the tree, please engage with people reporting problems and
send followup patches addressing any issues that are reported if needed.

If any updates are required or you are submitting further changes they
should be sent as incremental updates against current git, existing
patches will not be replaced.

Please add any relevant lists and maintainers to the CCs when replying
to this mail.

Thanks,
Mark

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2020-07-01 22:24 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-06-25 20:21 [PATCH] spi: lantiq-ssc: Convert to use GPIO descriptors Linus Walleij
2020-07-01 22:24 ` Mark Brown

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).