All of lore.kernel.org
 help / color / mirror / Atom feed
From: Shawn Guo <shawn.guo-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org>
To: Maxime Ripard
	<maxime.ripard-wi1+55ScJUtKEb57/3fJTNBPR1lH4CV8@public.gmane.org>
Cc: spi-devel-general-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org,
	Mark Brown
	<broonie-yzvPICuk2AATkU/dhu1WVueM+bqZidxxQQ4Iyu8u01E@public.gmane.org>,
	brian-ZKiFAVwZFM2FeswfMrDH8w@public.gmane.org,
	linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org
Subject: Re: [PATCH 1/2] spi: spidev: Add device tree bindings
Date: Fri, 19 Oct 2012 16:28:15 +0800	[thread overview]
Message-ID: <20121019082811.GB21078@S2101-09.ap.freescale.net> (raw)
In-Reply-To: <1350568768-4374-2-git-send-email-maxime.ripard-wi1+55ScJUtKEb57/3fJTNBPR1lH4CV8@public.gmane.org>

Mark is maintaining spi subsystem recently as Grant has been off line
for a while.

Shawn

On Thu, Oct 18, 2012 at 03:59:27PM +0200, Maxime Ripard wrote:
> This will allow to probe spidev from device tree
> 
> Signed-off-by: Maxime Ripard <maxime.ripard-wi1+55ScJUtKEb57/3fJTNBPR1lH4CV8@public.gmane.org>
> ---
>  drivers/spi/spidev.c |   10 ++++++++++
>  1 file changed, 10 insertions(+)
> 
> diff --git a/drivers/spi/spidev.c b/drivers/spi/spidev.c
> index 830adbe..8ae0660 100644
> --- a/drivers/spi/spidev.c
> +++ b/drivers/spi/spidev.c
> @@ -31,6 +31,8 @@
>  #include <linux/mutex.h>
>  #include <linux/slab.h>
>  #include <linux/compat.h>
> +#include <linux/of.h>
> +#include <linux/of_device.h>
>  
>  #include <linux/spi/spi.h>
>  #include <linux/spi/spidev.h>
> @@ -642,10 +644,18 @@ static int __devexit spidev_remove(struct spi_device *spi)
>  	return 0;
>  }
>  
> +static const struct of_device_id spidev_dt_ids[] = {
> +	{ .compatible = "linux,spidev" },
> +	{},
> +};
> +
> +MODULE_DEVICE_TABLE(of, spidev_dt_ids);
> +
>  static struct spi_driver spidev_spi_driver = {
>  	.driver = {
>  		.name =		"spidev",
>  		.owner =	THIS_MODULE,
> +		.of_match_table = of_match_ptr(spidev_dt_ids),
>  	},
>  	.probe =	spidev_probe,
>  	.remove =	__devexit_p(spidev_remove),
> -- 
> 1.7.9.5
> 

------------------------------------------------------------------------------
Everyone hates slow websites. So do we.
Make your web apps faster with AppDynamics
Download AppDynamics Lite for free today:
http://p.sf.net/sfu/appdyn_sfd2d_oct

WARNING: multiple messages have this Message-ID (diff)
From: shawn.guo@linaro.org (Shawn Guo)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 1/2] spi: spidev: Add device tree bindings
Date: Fri, 19 Oct 2012 16:28:15 +0800	[thread overview]
Message-ID: <20121019082811.GB21078@S2101-09.ap.freescale.net> (raw)
In-Reply-To: <1350568768-4374-2-git-send-email-maxime.ripard@free-electrons.com>

Mark is maintaining spi subsystem recently as Grant has been off line
for a while.

Shawn

On Thu, Oct 18, 2012 at 03:59:27PM +0200, Maxime Ripard wrote:
> This will allow to probe spidev from device tree
> 
> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com>
> ---
>  drivers/spi/spidev.c |   10 ++++++++++
>  1 file changed, 10 insertions(+)
> 
> diff --git a/drivers/spi/spidev.c b/drivers/spi/spidev.c
> index 830adbe..8ae0660 100644
> --- a/drivers/spi/spidev.c
> +++ b/drivers/spi/spidev.c
> @@ -31,6 +31,8 @@
>  #include <linux/mutex.h>
>  #include <linux/slab.h>
>  #include <linux/compat.h>
> +#include <linux/of.h>
> +#include <linux/of_device.h>
>  
>  #include <linux/spi/spi.h>
>  #include <linux/spi/spidev.h>
> @@ -642,10 +644,18 @@ static int __devexit spidev_remove(struct spi_device *spi)
>  	return 0;
>  }
>  
> +static const struct of_device_id spidev_dt_ids[] = {
> +	{ .compatible = "linux,spidev" },
> +	{},
> +};
> +
> +MODULE_DEVICE_TABLE(of, spidev_dt_ids);
> +
>  static struct spi_driver spidev_spi_driver = {
>  	.driver = {
>  		.name =		"spidev",
>  		.owner =	THIS_MODULE,
> +		.of_match_table = of_match_ptr(spidev_dt_ids),
>  	},
>  	.probe =	spidev_probe,
>  	.remove =	__devexit_p(spidev_remove),
> -- 
> 1.7.9.5
> 

  parent reply	other threads:[~2012-10-19  8:28 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-10-18 13:59 [RESEND][PATCH 0/2] Add spidev to the CFA-10049 Maxime Ripard
2012-10-18 13:59 ` Maxime Ripard
     [not found] ` <1350568768-4374-1-git-send-email-maxime.ripard-wi1+55ScJUtKEb57/3fJTNBPR1lH4CV8@public.gmane.org>
2012-10-18 13:59   ` [PATCH 1/2] spi: spidev: Add device tree bindings Maxime Ripard
2012-10-18 13:59     ` Maxime Ripard
     [not found]     ` <1350568768-4374-2-git-send-email-maxime.ripard-wi1+55ScJUtKEb57/3fJTNBPR1lH4CV8@public.gmane.org>
2012-10-19  8:28       ` Shawn Guo [this message]
2012-10-19  8:28         ` Shawn Guo
2012-10-18 13:59   ` [PATCH 2/2] ARM: dts: cfa10049: Add spidev to drive the DAC on SSP3 Maxime Ripard
2012-10-18 13:59     ` Maxime Ripard
  -- strict thread matches above, loose matches on Subject: below --
2012-10-26  8:07 [RESEND][PATCH 0/2] Add spidev to the CFA-10049 Maxime Ripard
     [not found] ` <1351238873-25230-1-git-send-email-maxime.ripard-wi1+55ScJUtKEb57/3fJTNBPR1lH4CV8@public.gmane.org>
2012-10-26  8:07   ` [PATCH 1/2] spi: spidev: Add device tree bindings Maxime Ripard
2012-10-26  8:07     ` Maxime Ripard
2012-10-27 22:19     ` Mark Brown
2012-10-27 22:19       ` Mark Brown
     [not found]       ` <20121027221955.GO4564-yzvPICuk2AATkU/dhu1WVueM+bqZidxxQQ4Iyu8u01E@public.gmane.org>
2012-10-29 15:26         ` Maxime Ripard
2012-10-29 15:26           ` Maxime Ripard
2012-10-29 16:10           ` Mark Brown
2012-10-29 16:10             ` Mark Brown
2012-09-28 12:50 [PATCH 0/2] Add spidev to the CFA-10049 Maxime Ripard
     [not found] ` <1348836616-29783-1-git-send-email-maxime.ripard-wi1+55ScJUtKEb57/3fJTNBPR1lH4CV8@public.gmane.org>
2012-09-28 12:50   ` [PATCH 1/2] spi: spidev: Add device tree bindings Maxime Ripard
2012-09-28 12:50     ` Maxime Ripard

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20121019082811.GB21078@S2101-09.ap.freescale.net \
    --to=shawn.guo-qsej5fyqhm4dnm+yrofe0a@public.gmane.org \
    --cc=brian-ZKiFAVwZFM2FeswfMrDH8w@public.gmane.org \
    --cc=broonie-yzvPICuk2AATkU/dhu1WVueM+bqZidxxQQ4Iyu8u01E@public.gmane.org \
    --cc=linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org \
    --cc=maxime.ripard-wi1+55ScJUtKEb57/3fJTNBPR1lH4CV8@public.gmane.org \
    --cc=spi-devel-general-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.