From: Bhuvanchandra DV <bhuvanchandra.dv-2KBjVHiyJgBBDgjK7y7TUQ@public.gmane.org>
To: Mark Brown <broonie-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>
Cc: <gregkh-hQyY1W1yCW8ekmWlsbkhG0B+6BGkLq7r@public.gmane.org>,
<stefan-XLVq0VzYD2Y@public.gmane.org>,
<linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org>,
<linux-spi-u79uwXL29TY76Z2rM5mHXA@public.gmane.org>,
Stefan Agner
<stefan.agner-2KBjVHiyJgBBDgjK7y7TUQ@public.gmane.org>,
Bhuvanchandra
<bhuvanchandra.dv-2KBjVHiyJgBBDgjK7y7TUQ@public.gmane.org>
Subject: Re: [RFC 1/2] spi: spidev: Use 'new_id' sysfs file for enabling spidev
Date: Wed, 20 Apr 2016 17:43:32 +0530 [thread overview]
Message-ID: <5717726C.2090302@toradex.com> (raw)
In-Reply-To: <20160418130126.GC3217-GFdadSzt00ze9xe1eoZjHA@public.gmane.org>
On 04/18/2016 06:31 PM, Mark Brown wrote:
> On Mon, Apr 18, 2016 at 04:48:27PM +0530, Bhuvanchandra DV wrote:
>
>> +++ b/Documentation/ABI/testing/sysfs-bus-spi-spidev
>> @@ -0,0 +1,8 @@
>> +What: /sys/bus/spi/drivers/spidev/new_id
>> +Date: March 2016
>> +Description:
>> + This allows to load spidev at runtime. new_id file accepts bus
>> + number and chip select in 'B.C' format.
>> + e.g.
>> + To load spidev1.1 at runtime:
>> + $ echo 1.1 > /sys/bus/spi/drivers/spidev/new_id
>
> I would expect a new_id file to allow a new device identifier to be
> added to a driver at runtime but this isn't doing that, it's specifying
> by bus and chip select instead which is totally different to how we
> normally bind SPI devices. That seems likely to cause confusion down
> the line. I'd expect to be able to supply a DT compatible string or a
> Linux SPI ID.
SPI drivers bind to the device as configured in DT, but in case of
spidev(non DT approach) the device is not available in hand to bind the
driver. So tried this approach of creating the device and then bind
spidev. I agree this is not a standard way we bind SPI devices. With out
a device available, seems it is not possible to bind spidev in non DT
approach. Please correct me if i'm wrong.
>
--
Best regards,
Bhuvan
--
To unsubscribe from this list: send the line "unsubscribe linux-spi" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
WARNING: multiple messages have this Message-ID (diff)
From: Bhuvanchandra DV <bhuvanchandra.dv@toradex.com>
To: Mark Brown <broonie@kernel.org>
Cc: <gregkh@linuxfoundation.org>, <stefan@agner.ch>,
<linux-kernel@vger.kernel.org>, <linux-spi@vger.kernel.org>,
Stefan Agner <stefan.agner@toradex.com>,
Bhuvanchandra <bhuvanchandra.dv@toradex.com>
Subject: Re: [RFC 1/2] spi: spidev: Use 'new_id' sysfs file for enabling spidev
Date: Wed, 20 Apr 2016 17:43:32 +0530 [thread overview]
Message-ID: <5717726C.2090302@toradex.com> (raw)
In-Reply-To: <20160418130126.GC3217@sirena.org.uk>
On 04/18/2016 06:31 PM, Mark Brown wrote:
> On Mon, Apr 18, 2016 at 04:48:27PM +0530, Bhuvanchandra DV wrote:
>
>> +++ b/Documentation/ABI/testing/sysfs-bus-spi-spidev
>> @@ -0,0 +1,8 @@
>> +What: /sys/bus/spi/drivers/spidev/new_id
>> +Date: March 2016
>> +Description:
>> + This allows to load spidev at runtime. new_id file accepts bus
>> + number and chip select in 'B.C' format.
>> + e.g.
>> + To load spidev1.1 at runtime:
>> + $ echo 1.1 > /sys/bus/spi/drivers/spidev/new_id
>
> I would expect a new_id file to allow a new device identifier to be
> added to a driver at runtime but this isn't doing that, it's specifying
> by bus and chip select instead which is totally different to how we
> normally bind SPI devices. That seems likely to cause confusion down
> the line. I'd expect to be able to supply a DT compatible string or a
> Linux SPI ID.
SPI drivers bind to the device as configured in DT, but in case of
spidev(non DT approach) the device is not available in hand to bind the
driver. So tried this approach of creating the device and then bind
spidev. I agree this is not a standard way we bind SPI devices. With out
a device available, seems it is not possible to bind spidev in non DT
approach. Please correct me if i'm wrong.
>
--
Best regards,
Bhuvan
next prev parent reply other threads:[~2016-04-20 12:13 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-04-18 11:18 [RFC 0/2] sysfs new_id file support for spidev Bhuvanchandra DV
[not found] ` <1460978308-8062-1-git-send-email-bhuvanchandra.dv-2KBjVHiyJgBBDgjK7y7TUQ@public.gmane.org>
2016-04-18 11:18 ` [RFC 1/2] spi: spidev: Use 'new_id' sysfs file for enabling spidev Bhuvanchandra DV
2016-04-18 11:18 ` Bhuvanchandra DV
[not found] ` <1460978308-8062-2-git-send-email-bhuvanchandra.dv-2KBjVHiyJgBBDgjK7y7TUQ@public.gmane.org>
2016-04-18 13:01 ` Mark Brown
2016-04-18 13:01 ` Mark Brown
[not found] ` <20160418130126.GC3217-GFdadSzt00ze9xe1eoZjHA@public.gmane.org>
2016-04-20 12:13 ` Bhuvanchandra DV [this message]
2016-04-20 12:13 ` Bhuvanchandra DV
[not found] ` <5717726C.2090302-2KBjVHiyJgBBDgjK7y7TUQ@public.gmane.org>
2016-04-20 12:17 ` Mark Brown
2016-04-20 12:17 ` Mark Brown
[not found] ` <20160420121704.GI3217-GFdadSzt00ze9xe1eoZjHA@public.gmane.org>
2016-04-20 13:11 ` Bhuvanchandra DV
2016-04-20 13:11 ` Bhuvanchandra DV
2016-04-20 13:52 ` Mark Brown
2016-04-18 11:18 ` [RFC 2/2] spi core: Add new sysfs 'num_chipselect' file Bhuvanchandra DV
[not found] ` <1460978308-8062-3-git-send-email-bhuvanchandra.dv-2KBjVHiyJgBBDgjK7y7TUQ@public.gmane.org>
2016-04-18 12:14 ` Mark Brown
2016-04-18 12:14 ` Mark Brown
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=5717726C.2090302@toradex.com \
--to=bhuvanchandra.dv-2kbjvhiyjgbbdgjk7y7tuq@public.gmane.org \
--cc=broonie-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org \
--cc=gregkh-hQyY1W1yCW8ekmWlsbkhG0B+6BGkLq7r@public.gmane.org \
--cc=linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=linux-spi-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=stefan-XLVq0VzYD2Y@public.gmane.org \
--cc=stefan.agner-2KBjVHiyJgBBDgjK7y7TUQ@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.