* [PATCH 1/3 v5] dt-bindings: dspi: added for MikcroBus socket
@ 2022-04-26 2:24 Changming Huang
2022-04-26 2:24 ` [PATCH 2/3 v5] arm64: dts: fsl-ls1028a: add dspi2 support Changming Huang
` (4 more replies)
0 siblings, 5 replies; 6+ messages in thread
From: Changming Huang @ 2022-04-26 2:24 UTC (permalink / raw)
To: broonie, robh+dt, krzysztof.kozlowski+dt, linux-spi, devicetree,
linux-kernel, shawnguo, leoyang.li, linux-arm-kernel
Cc: Changming Huang
Signed-off-by: Changming Huang <jerry.huang@nxp.com>
---
changes in v5:
- rename compatible name to mikcroe,mikcroe-socket
changes in v4:
- rename example node, adjust description
changes in v3:
- add the dt-bindings
.../bindings/spi/mikcroe,mikcroe-socket.yaml | 50 +++++++++++++++++++
1 file changed, 50 insertions(+)
create mode 100644 Documentation/devicetree/bindings/spi/mikcroe,mikcroe-socket.yaml
diff --git a/Documentation/devicetree/bindings/spi/mikcroe,mikcroe-socket.yaml b/Documentation/devicetree/bindings/spi/mikcroe,mikcroe-socket.yaml
new file mode 100644
index 000000000000..2b0abf7f1d84
--- /dev/null
+++ b/Documentation/devicetree/bindings/spi/mikcroe,mikcroe-socket.yaml
@@ -0,0 +1,50 @@
+# SPDX-License-Identifier: GPL-2.0
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/spi/mikcroe,mikcroe-spi#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: MikcroBus SPI device bindings
+
+maintainers:
+ - Changming Huang <jerry.huang@nxp.com>
+
+allOf:
+ - $ref: "spi-controller.yaml"
+
+properties:
+ compatible:
+ const: mikcroe,mikcroe-socket
+
+ reg:
+ maxItems: 1
+
+ spi-max-frequency: true
+
+ fsl,spi-cs-sck-delay: true
+
+ fsl,spi-sck-cs-delay: true
+
+required:
+ - compatible
+ - reg
+ - spi-max-frequency
+
+additionalProperties: false
+
+examples:
+ - |
+ &dspi2 {
+ bus-num = <2>;
+ status = "okay";
+
+ spi@0 {
+ compatible = "mikcroe,mikcroe-socket";
+ reg = <0>;
+ spi-max-frequency = <2000000>;
+ fsl,spi-cs-sck-delay = <1000000>;
+ fsl,spi-sck-cs-delay = <50>;
+ };
+ };
+
+...
--
2.25.1
^ permalink raw reply related [flat|nested] 6+ messages in thread
* [PATCH 2/3 v5] arm64: dts: fsl-ls1028a: add dspi2 support
2022-04-26 2:24 [PATCH 1/3 v5] dt-bindings: dspi: added for MikcroBus socket Changming Huang
@ 2022-04-26 2:24 ` Changming Huang
2022-04-26 2:24 ` [PATCH 3/3 v5] spi: spidev: add MikcroBus socket to device tree compatibility list Changming Huang
` (3 subsequent siblings)
4 siblings, 0 replies; 6+ messages in thread
From: Changming Huang @ 2022-04-26 2:24 UTC (permalink / raw)
To: broonie, robh+dt, krzysztof.kozlowski+dt, linux-spi, devicetree,
linux-kernel, shawnguo, leoyang.li, linux-arm-kernel
Cc: Changming Huang
Enable MikroBUS SPI port.
Signed-off-by: Changming Huang <jerry.huang@nxp.com>
---
changes in v5:
- rename compatible name to mikcroe,mikcroe-socket
changes in v3:
- add the dt-bindings
arch/arm64/boot/dts/freescale/fsl-ls1028a-rdb.dts | 14 ++++++++++++++
1 file changed, 14 insertions(+)
diff --git a/arch/arm64/boot/dts/freescale/fsl-ls1028a-rdb.dts b/arch/arm64/boot/dts/freescale/fsl-ls1028a-rdb.dts
index 68c31cb8eead..d2cea39d4966 100644
--- a/arch/arm64/boot/dts/freescale/fsl-ls1028a-rdb.dts
+++ b/arch/arm64/boot/dts/freescale/fsl-ls1028a-rdb.dts
@@ -117,6 +117,20 @@ &duart1 {
status = "okay";
};
+&dspi2 {
+ bus-num = <2>;
+ status = "okay";
+
+ /* MikcroBus1 */
+ spi@0 {
+ compatible = "mikcroe,mikcroe-socket";
+ reg = <0>;
+ spi-max-frequency = <2000000>;
+ fsl,spi-cs-sck-delay = <1000000>;
+ fsl,spi-sck-cs-delay = <50>;
+ };
+};
+
&enetc_mdio_pf3 {
sgmii_phy0: ethernet-phy@2 {
reg = <0x2>;
--
2.25.1
^ permalink raw reply related [flat|nested] 6+ messages in thread
* [PATCH 3/3 v5] spi: spidev: add MikcroBus socket to device tree compatibility list
2022-04-26 2:24 [PATCH 1/3 v5] dt-bindings: dspi: added for MikcroBus socket Changming Huang
2022-04-26 2:24 ` [PATCH 2/3 v5] arm64: dts: fsl-ls1028a: add dspi2 support Changming Huang
@ 2022-04-26 2:24 ` Changming Huang
2022-04-26 13:39 ` [PATCH 1/3 v5] dt-bindings: dspi: added for MikcroBus socket Rob Herring
` (2 subsequent siblings)
4 siblings, 0 replies; 6+ messages in thread
From: Changming Huang @ 2022-04-26 2:24 UTC (permalink / raw)
To: broonie, robh+dt, krzysztof.kozlowski+dt, linux-spi, devicetree,
linux-kernel, shawnguo, leoyang.li, linux-arm-kernel
Cc: Changming Huang
Signed-off-by: Changming Huang <jerry.huang@nxp.com>
---
changes in v5:
- add compatible to spidev
drivers/spi/spidev.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/spi/spidev.c b/drivers/spi/spidev.c
index 53a551714265..f9ecedd1dc23 100644
--- a/drivers/spi/spidev.c
+++ b/drivers/spi/spidev.c
@@ -703,6 +703,7 @@ static const struct of_device_id spidev_dt_ids[] = {
{ .compatible = "menlo,m53cpld" },
{ .compatible = "cisco,spi-petra" },
{ .compatible = "micron,spi-authenta" },
+ { .compatible = "mikcroe,mikcroe-socket" },
{},
};
MODULE_DEVICE_TABLE(of, spidev_dt_ids);
--
2.25.1
^ permalink raw reply related [flat|nested] 6+ messages in thread
* Re: [PATCH 1/3 v5] dt-bindings: dspi: added for MikcroBus socket
2022-04-26 2:24 [PATCH 1/3 v5] dt-bindings: dspi: added for MikcroBus socket Changming Huang
2022-04-26 2:24 ` [PATCH 2/3 v5] arm64: dts: fsl-ls1028a: add dspi2 support Changming Huang
2022-04-26 2:24 ` [PATCH 3/3 v5] spi: spidev: add MikcroBus socket to device tree compatibility list Changming Huang
@ 2022-04-26 13:39 ` Rob Herring
2022-04-26 15:55 ` Rob Herring
2022-04-27 9:37 ` Michael Walle
4 siblings, 0 replies; 6+ messages in thread
From: Rob Herring @ 2022-04-26 13:39 UTC (permalink / raw)
To: Changming Huang
Cc: linux-kernel, shawnguo, linux-spi, broonie,
krzysztof.kozlowski+dt, robh+dt, leoyang.li, devicetree,
linux-arm-kernel
On Tue, 26 Apr 2022 10:24:11 +0800, Changming Huang wrote:
> Signed-off-by: Changming Huang <jerry.huang@nxp.com>
> ---
> changes in v5:
> - rename compatible name to mikcroe,mikcroe-socket
> changes in v4:
> - rename example node, adjust description
> changes in v3:
> - add the dt-bindings
>
> .../bindings/spi/mikcroe,mikcroe-socket.yaml | 50 +++++++++++++++++++
> 1 file changed, 50 insertions(+)
> create mode 100644 Documentation/devicetree/bindings/spi/mikcroe,mikcroe-socket.yaml
>
My bot found errors running 'make DT_CHECKER_FLAGS=-m dt_binding_check'
on your patch (DT_CHECKER_FLAGS is new in v5.13):
yamllint warnings/errors:
dtschema/dtc warnings/errors:
/builds/robherring/linux-dt-review/Documentation/devicetree/bindings/spi/mikcroe,mikcroe-socket.yaml: $id: 'http://devicetree.org/schemas/spi/mikcroe,mikcroe-spi#' does not match 'http://devicetree.org/schemas/.*\\.yaml#'
from schema $id: http://devicetree.org/meta-schemas/base.yaml#
/builds/robherring/linux-dt-review/Documentation/devicetree/bindings/spi/mikcroe,mikcroe-socket.yaml: properties:fsl,spi-cs-sck-delay: True is not of type 'object'
hint: Vendor specific properties must have a type and description unless they have a defined, common suffix.
from schema $id: http://devicetree.org/meta-schemas/vendor-props.yaml#
/builds/robherring/linux-dt-review/Documentation/devicetree/bindings/spi/mikcroe,mikcroe-socket.yaml: properties:fsl,spi-cs-sck-delay: More than one condition true in oneOf schema:
{'description': 'Vendor specific properties must have a type and '
'description unless they have a defined, common '
'suffix.',
'oneOf': [{'additionalProperties': False,
'description': 'A vendor boolean property can use "type: '
'boolean"',
'properties': {'deprecated': True,
'description': True,
'type': {'const': 'boolean'}},
'required': ['type', 'description']},
{'additionalProperties': False,
'description': 'A vendor string property with exact values '
'has an implicit type',
'oneOf': [{'required': ['enum']}, {'required': ['const']}],
'properties': {'const': {'type': 'string'},
'deprecated': True,
'description': True,
'enum': {'items': {'type': 'string'}}},
'required': ['description']},
{'description': 'A vendor property needs a $ref to '
'types.yaml',
'oneOf': [{'required': ['$ref']}, {'required': ['allOf']}],
'properties': {'$ref': {'pattern': 'types.yaml#/definitions/'},
'allOf': {'items': [{'properties': {'$ref': {'pattern': 'types.yaml#/definitions/'}},
'required': ['$ref']}]}},
'required': ['description']},
{'description': 'A vendor property can have a $ref to a a '
'$defs schema',
'properties': {'$ref': {'pattern': '^#/(definitions|$defs)/'}},
'required': ['$ref']}],
'type': 'object'}
hint: Vendor specific properties must have a type and description unless they have a defined, common suffix.
from schema $id: http://devicetree.org/meta-schemas/vendor-props.yaml#
/builds/robherring/linux-dt-review/Documentation/devicetree/bindings/spi/mikcroe,mikcroe-socket.yaml: properties:fsl,spi-sck-cs-delay: True is not of type 'object'
hint: Vendor specific properties must have a type and description unless they have a defined, common suffix.
from schema $id: http://devicetree.org/meta-schemas/vendor-props.yaml#
/builds/robherring/linux-dt-review/Documentation/devicetree/bindings/spi/mikcroe,mikcroe-socket.yaml: properties:fsl,spi-sck-cs-delay: More than one condition true in oneOf schema:
{'description': 'Vendor specific properties must have a type and '
'description unless they have a defined, common '
'suffix.',
'oneOf': [{'additionalProperties': False,
'description': 'A vendor boolean property can use "type: '
'boolean"',
'properties': {'deprecated': True,
'description': True,
'type': {'const': 'boolean'}},
'required': ['type', 'description']},
{'additionalProperties': False,
'description': 'A vendor string property with exact values '
'has an implicit type',
'oneOf': [{'required': ['enum']}, {'required': ['const']}],
'properties': {'const': {'type': 'string'},
'deprecated': True,
'description': True,
'enum': {'items': {'type': 'string'}}},
'required': ['description']},
{'description': 'A vendor property needs a $ref to '
'types.yaml',
'oneOf': [{'required': ['$ref']}, {'required': ['allOf']}],
'properties': {'$ref': {'pattern': 'types.yaml#/definitions/'},
'allOf': {'items': [{'properties': {'$ref': {'pattern': 'types.yaml#/definitions/'}},
'required': ['$ref']}]}},
'required': ['description']},
{'description': 'A vendor property can have a $ref to a a '
'$defs schema',
'properties': {'$ref': {'pattern': '^#/(definitions|$defs)/'}},
'required': ['$ref']}],
'type': 'object'}
hint: Vendor specific properties must have a type and description unless they have a defined, common suffix.
from schema $id: http://devicetree.org/meta-schemas/vendor-props.yaml#
./Documentation/devicetree/bindings/spi/mikcroe,mikcroe-socket.yaml: $id: relative path/filename doesn't match actual path or filename
expected: http://devicetree.org/schemas/spi/mikcroe,mikcroe-socket.yaml#
/builds/robherring/linux-dt-review/Documentation/devicetree/bindings/spi/mikcroe,mikcroe-socket.yaml: ignoring, error in schema: $id
Error: Documentation/devicetree/bindings/spi/mikcroe,mikcroe-socket.example.dts:20.9-15 syntax error
FATAL ERROR: Unable to parse input tree
make[1]: *** [scripts/Makefile.lib:364: Documentation/devicetree/bindings/spi/mikcroe,mikcroe-socket.example.dtb] Error 1
make[1]: *** Waiting for unfinished jobs....
make: *** [Makefile:1401: dt_binding_check] Error 2
doc reference errors (make refcheckdocs):
See https://patchwork.ozlabs.org/patch/
This check can fail if there are any dependencies. The base for a patch
series is generally the most recent rc1.
If you already ran 'make dt_binding_check' and didn't see the above
error(s), then make sure 'yamllint' is installed and dt-schema is up to
date:
pip3 install dtschema --upgrade
Please check and re-submit.
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH 1/3 v5] dt-bindings: dspi: added for MikcroBus socket
2022-04-26 2:24 [PATCH 1/3 v5] dt-bindings: dspi: added for MikcroBus socket Changming Huang
` (2 preceding siblings ...)
2022-04-26 13:39 ` [PATCH 1/3 v5] dt-bindings: dspi: added for MikcroBus socket Rob Herring
@ 2022-04-26 15:55 ` Rob Herring
2022-04-27 9:37 ` Michael Walle
4 siblings, 0 replies; 6+ messages in thread
From: Rob Herring @ 2022-04-26 15:55 UTC (permalink / raw)
To: Changming Huang
Cc: Mark Brown, Krzysztof Kozlowski, linux-spi, devicetree,
linux-kernel, Shawn Guo, Yang-Leo Li, linux-arm-kernel
On Mon, Apr 25, 2022 at 9:24 PM Changming Huang <jerry.huang@nxp.com> wrote:
>
> Signed-off-by: Changming Huang <jerry.huang@nxp.com>
> ---
> changes in v5:
> - rename compatible name to mikcroe,mikcroe-socket
This is not right. The mikrobus socket is more than just SPI which was
already pointed out. I also sketched out how I think it needs to look.
Maybe it ends up looking a bit different, but fundamentally, how you
remap I2C, SPI, GPIO, PWM, etc. thru a connector in order to have
overlays which are independent of the base platform has to be solved.
So far, we have done interrupts and GPIOs.
Rob
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH 1/3 v5] dt-bindings: dspi: added for MikcroBus socket
2022-04-26 2:24 [PATCH 1/3 v5] dt-bindings: dspi: added for MikcroBus socket Changming Huang
` (3 preceding siblings ...)
2022-04-26 15:55 ` Rob Herring
@ 2022-04-27 9:37 ` Michael Walle
4 siblings, 0 replies; 6+ messages in thread
From: Michael Walle @ 2022-04-27 9:37 UTC (permalink / raw)
To: jerry.huang
Cc: broonie, devicetree, krzysztof.kozlowski+dt, leoyang.li,
linux-arm-kernel, linux-kernel, linux-spi, robh+dt, shawnguo,
Michael Walle
Hi,
> Signed-off-by: Changming Huang <jerry.huang@nxp.com>
> ---
> changes in v5:
> - rename compatible name to mikcroe,mikcroe-socket
> changes in v4:
> - rename example node, adjust description
> changes in v3:
> - add the dt-bindings
Please keep people who reply to your patches on CC in the next versions.
Thanks,
-michael
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2022-04-27 9:42 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-04-26 2:24 [PATCH 1/3 v5] dt-bindings: dspi: added for MikcroBus socket Changming Huang
2022-04-26 2:24 ` [PATCH 2/3 v5] arm64: dts: fsl-ls1028a: add dspi2 support Changming Huang
2022-04-26 2:24 ` [PATCH 3/3 v5] spi: spidev: add MikcroBus socket to device tree compatibility list Changming Huang
2022-04-26 13:39 ` [PATCH 1/3 v5] dt-bindings: dspi: added for MikcroBus socket Rob Herring
2022-04-26 15:55 ` Rob Herring
2022-04-27 9:37 ` Michael Walle
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).