* [PATCH 0/2] misc: add support for the cc1101 RF transceiver chip from TI
@ 2019-09-22 6:03 Heiko Schocher
2019-09-22 6:03 ` [PATCH 1/2] misc: add cc1101 devicetree binding Heiko Schocher
0 siblings, 1 reply; 4+ messages in thread
From: Heiko Schocher @ 2019-09-22 6:03 UTC (permalink / raw)
To: linux-kernel
Cc: Heiko Schocher, Arnd Bergmann, Derek Kiernan, Dragan Cvetic,
Greg Kroah-Hartman, Jonathan Corbet, Mark Rutland, Rob Herring,
devicetree, linux-doc
This driver provides support for the Low-Power Sub-1 GHz RF
Transceiver chip from Texas Instruments. It provides a
simple message based protocol to set chip registers, send
and receive packets to/from the chip.
Heiko Schocher (2):
misc: add cc1101 devicetree binding
misc: add support for the cc1101 RF transceiver chip from TI
.../devicetree/bindings/misc/cc1101.txt | 27 +
Documentation/misc-devices/cc1101.txt | 446 ++++
drivers/misc/Kconfig | 11 +
drivers/misc/Makefile | 1 +
drivers/misc/cc1101.c | 2004 +++++++++++++++++
drivers/misc/cc1101.h | 89 +
include/uapi/linux/cc1101_user.h | 255 +++
7 files changed, 2833 insertions(+)
create mode 100644 Documentation/devicetree/bindings/misc/cc1101.txt
create mode 100644 Documentation/misc-devices/cc1101.txt
create mode 100644 drivers/misc/cc1101.c
create mode 100644 drivers/misc/cc1101.h
create mode 100644 include/uapi/linux/cc1101_user.h
--
2.21.0
^ permalink raw reply [flat|nested] 4+ messages in thread
* [PATCH 1/2] misc: add cc1101 devicetree binding
2019-09-22 6:03 [PATCH 0/2] misc: add support for the cc1101 RF transceiver chip from TI Heiko Schocher
@ 2019-09-22 6:03 ` Heiko Schocher
2019-10-02 14:19 ` Rob Herring
0 siblings, 1 reply; 4+ messages in thread
From: Heiko Schocher @ 2019-09-22 6:03 UTC (permalink / raw)
To: linux-kernel; +Cc: Heiko Schocher, Mark Rutland, Rob Herring, devicetree
add devicetree binding for cc1101 misc driver.
Signed-off-by: Heiko Schocher <hs@denx.de>
---
.../devicetree/bindings/misc/cc1101.txt | 27 +++++++++++++++++++
1 file changed, 27 insertions(+)
create mode 100644 Documentation/devicetree/bindings/misc/cc1101.txt
diff --git a/Documentation/devicetree/bindings/misc/cc1101.txt b/Documentation/devicetree/bindings/misc/cc1101.txt
new file mode 100644
index 0000000000000..afea6acf4a9c5
--- /dev/null
+++ b/Documentation/devicetree/bindings/misc/cc1101.txt
@@ -0,0 +1,27 @@
+driver cc1101 Low-Power Sub-1 GHz RF Transceiver chip from Texas
+Instruments.
+
+Requires node properties:
+- compatible : should be "ti,cc1101";
+- reg : Chip select address of device, see:
+ Documentation/devicetree/bindings/spi/spi-bus.txt
+- gpios : list of 2 gpios, first gpio is for GDO0 pin
+ second for GDO2 pin, see more:
+ Documentation/devicetree/bindings/gpio/gpio.txt
+
+Recommended properties:
+ - spi-max-frequency: Definition as per
+ Documentation/devicetree/bindings/spi/spi-bus.txt
+ - freq : used spi frequency for communication with cc1101 chip
+
+example:
+
+&ecspi4 {
+ cc1101@0 {
+ compatible = "ti,cc1101";
+ spi-max-frequency = <10000000>;
+ reg = <0>;
+ freq = <5000000>;
+ gpios = <&gpio2 11 GPIO_ACTIVE_HIGH &gpio5 8 GPIO_ACTIVE_HIGH>;
+ };
+};
--
2.21.0
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH 1/2] misc: add cc1101 devicetree binding
2019-09-22 6:03 ` [PATCH 1/2] misc: add cc1101 devicetree binding Heiko Schocher
@ 2019-10-02 14:19 ` Rob Herring
2019-10-03 5:21 ` Heiko Schocher
0 siblings, 1 reply; 4+ messages in thread
From: Rob Herring @ 2019-10-02 14:19 UTC (permalink / raw)
To: Heiko Schocher; +Cc: linux-kernel, Mark Rutland, devicetree
On Sun, Sep 22, 2019 at 08:03:55AM +0200, Heiko Schocher wrote:
> add devicetree binding for cc1101 misc driver.
>
> Signed-off-by: Heiko Schocher <hs@denx.de>
> ---
>
> .../devicetree/bindings/misc/cc1101.txt | 27 +++++++++++++++++++
> 1 file changed, 27 insertions(+)
> create mode 100644 Documentation/devicetree/bindings/misc/cc1101.txt
Can you please convert this to DT schema.
>
> diff --git a/Documentation/devicetree/bindings/misc/cc1101.txt b/Documentation/devicetree/bindings/misc/cc1101.txt
> new file mode 100644
> index 0000000000000..afea6acf4a9c5
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/misc/cc1101.txt
Normal naming is to use compatible string. So ti,cc1101.yaml for schema.
> @@ -0,0 +1,27 @@
> +driver cc1101 Low-Power Sub-1 GHz RF Transceiver chip from Texas
> +Instruments.
> +
> +Requires node properties:
> +- compatible : should be "ti,cc1101";
> +- reg : Chip select address of device, see:
> + Documentation/devicetree/bindings/spi/spi-bus.txt
> +- gpios : list of 2 gpios, first gpio is for GDO0 pin
> + second for GDO2 pin, see more:
Is there a GDO1? Would be hard to add later because you can't change the
indices once defined.
> + Documentation/devicetree/bindings/gpio/gpio.txt
> +
> +Recommended properties:
> + - spi-max-frequency: Definition as per
> + Documentation/devicetree/bindings/spi/spi-bus.txt
Notice that this file is now just in redirection...
> + - freq : used spi frequency for communication with cc1101 chip
What's this? Doesn't spi-max-frequency cover it?
> +
> +example:
> +
> +&ecspi4 {
> + cc1101@0 {
> + compatible = "ti,cc1101";
> + spi-max-frequency = <10000000>;
> + reg = <0>;
> + freq = <5000000>;
> + gpios = <&gpio2 11 GPIO_ACTIVE_HIGH &gpio5 8 GPIO_ACTIVE_HIGH>;
> + };
> +};
> --
> 2.21.0
>
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH 1/2] misc: add cc1101 devicetree binding
2019-10-02 14:19 ` Rob Herring
@ 2019-10-03 5:21 ` Heiko Schocher
0 siblings, 0 replies; 4+ messages in thread
From: Heiko Schocher @ 2019-10-03 5:21 UTC (permalink / raw)
To: Rob Herring; +Cc: linux-kernel, Mark Rutland, devicetree
Hello Rob,
Am 02.10.2019 um 16:19 schrieb Rob Herring:
> On Sun, Sep 22, 2019 at 08:03:55AM +0200, Heiko Schocher wrote:
>> add devicetree binding for cc1101 misc driver.
>>
>> Signed-off-by: Heiko Schocher <hs@denx.de>
>> ---
>>
>> .../devicetree/bindings/misc/cc1101.txt | 27 +++++++++++++++++++
>> 1 file changed, 27 insertions(+)
>> create mode 100644 Documentation/devicetree/bindings/misc/cc1101.txt
>
> Can you please convert this to DT schema.
Of course, missed this point, sorry, reworked. Is there a HowTo
for writting a schema?
(beside Documentation/devicetree/bindings/example-schema.yaml)
>> diff --git a/Documentation/devicetree/bindings/misc/cc1101.txt b/Documentation/devicetree/bindings/misc/cc1101.txt
>> new file mode 100644
>> index 0000000000000..afea6acf4a9c5
>> --- /dev/null
>> +++ b/Documentation/devicetree/bindings/misc/cc1101.txt
>
> Normal naming is to use compatible string. So ti,cc1101.yaml for schema.
renamed.
>
>> @@ -0,0 +1,27 @@
>> +driver cc1101 Low-Power Sub-1 GHz RF Transceiver chip from Texas
>> +Instruments.
>> +
>> +Requires node properties:
>> +- compatible : should be "ti,cc1101";
>> +- reg : Chip select address of device, see:
>> + Documentation/devicetree/bindings/spi/spi-bus.txt
>> +- gpios : list of 2 gpios, first gpio is for GDO0 pin
>> + second for GDO2 pin, see more:
>
> Is there a GDO1? Would be hard to add later because you can't change the
> indices once defined.
Good point. There is a GDO1, so yes, this makes sense, added.
>
>> + Documentation/devicetree/bindings/gpio/gpio.txt
>> +
>> +Recommended properties:
>> + - spi-max-frequency: Definition as per
>> + Documentation/devicetree/bindings/spi/spi-bus.txt
>
> Notice that this file is now just in redirection...
Ok.
>
>> + - freq : used spi frequency for communication with cc1101 chip
>
> What's this? Doesn't spi-max-frequency cover it?
Of course, removed.
Thanks for your time and review.
bye,
Heiko
--
DENX Software Engineering GmbH, Managing Director: Wolfgang Denk
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: +49-8142-66989-52 Fax: +49-8142-66989-80 Email: hs@denx.de
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2019-10-03 5:21 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-09-22 6:03 [PATCH 0/2] misc: add support for the cc1101 RF transceiver chip from TI Heiko Schocher
2019-09-22 6:03 ` [PATCH 1/2] misc: add cc1101 devicetree binding Heiko Schocher
2019-10-02 14:19 ` Rob Herring
2019-10-03 5:21 ` Heiko Schocher
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).