diff mbox series

[v2,1/2] dt-bindings: iio: bmc150_magn: Document and fix missing compatibles

Message ID 20200622060110.23192-1-krzk@kernel.org (mailing list archive)
State New, archived
Headers show
Series [v2,1/2] dt-bindings: iio: bmc150_magn: Document and fix missing compatibles | expand

Commit Message

Krzysztof Kozlowski June 22, 2020, 6:01 a.m. UTC
The driver supports also BMC156B and BMM150B but these compatibles had
redundant suffix "_magn".  Add existing compatibles marking them
deprecated along with adding a new, proper one for this family of
devices.

Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org>

---

Changes since v1:
1. Mark old compatibles as deprecated, add new one.
---
 .../devicetree/bindings/iio/magnetometer/bmc150_magn.txt    | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

Comments

Jonathan Cameron June 27, 2020, 1:43 p.m. UTC | #1
On Mon, 22 Jun 2020 08:01:09 +0200
Krzysztof Kozlowski <krzk@kernel.org> wrote:

> The driver supports also BMC156B and BMM150B but these compatibles had
> redundant suffix "_magn".  Add existing compatibles marking them
> deprecated along with adding a new, proper one for this family of
> devices.
Thanks for tidying this up.

The BMC156B is a dual magnetometer and accelerometer chip
so for that one the _magn postfix probably is needed.

Or am I missing something?

The way this does SPI is rather odd but seems to be the same as the bmc150
(two chips with non overlapping register maps).

Jonathan

> 
> Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org>
> 
> ---
> 
> Changes since v1:
> 1. Mark old compatibles as deprecated, add new one.
> ---
>  .../devicetree/bindings/iio/magnetometer/bmc150_magn.txt    | 6 +++++-
>  1 file changed, 5 insertions(+), 1 deletion(-)
> 
> diff --git a/Documentation/devicetree/bindings/iio/magnetometer/bmc150_magn.txt b/Documentation/devicetree/bindings/iio/magnetometer/bmc150_magn.txt
> index fd5fca90fb39..efeda055be6a 100644
> --- a/Documentation/devicetree/bindings/iio/magnetometer/bmc150_magn.txt
> +++ b/Documentation/devicetree/bindings/iio/magnetometer/bmc150_magn.txt
> @@ -4,7 +4,11 @@ http://ae-bst.resource.bosch.com/media/products/dokumente/bmc150/BST-BMC150-DS00
>  
>  Required properties:
>  
> -  - compatible : should be "bosch,bmc150_magn"
> +  - compatible : should be one of:
> +                 "bosch,bmc150_magn"
> +                 "bosch,bmc156"
> +                 "bosch,bmc156_magn" (DEPRECATED, use bosch,bmc156)
> +                 "bosch,bmm150_magn" (DEPRECATED, use bosch,bmc156)
>    - reg : the I2C address of the magnetometer
>  
>  Optional properties:
Krzysztof Kozlowski June 29, 2020, 6:52 a.m. UTC | #2
On Sat, Jun 27, 2020 at 02:43:59PM +0100, Jonathan Cameron wrote:
> On Mon, 22 Jun 2020 08:01:09 +0200
> Krzysztof Kozlowski <krzk@kernel.org> wrote:
> 
> > The driver supports also BMC156B and BMM150B but these compatibles had
> > redundant suffix "_magn".  Add existing compatibles marking them
> > deprecated along with adding a new, proper one for this family of
> > devices.
> Thanks for tidying this up.
> 
> The BMC156B is a dual magnetometer and accelerometer chip
> so for that one the _magn postfix probably is needed.
> 
> Or am I missing something?
> 
> The way this does SPI is rather odd but seems to be the same as the bmc150
> (two chips with non overlapping register maps).

You're right, only one compatible should be trimmed from suffix. I'll
send v3.

Best regards,
Krzysztof
diff mbox series

Patch

diff --git a/Documentation/devicetree/bindings/iio/magnetometer/bmc150_magn.txt b/Documentation/devicetree/bindings/iio/magnetometer/bmc150_magn.txt
index fd5fca90fb39..efeda055be6a 100644
--- a/Documentation/devicetree/bindings/iio/magnetometer/bmc150_magn.txt
+++ b/Documentation/devicetree/bindings/iio/magnetometer/bmc150_magn.txt
@@ -4,7 +4,11 @@  http://ae-bst.resource.bosch.com/media/products/dokumente/bmc150/BST-BMC150-DS00
 
 Required properties:
 
-  - compatible : should be "bosch,bmc150_magn"
+  - compatible : should be one of:
+                 "bosch,bmc150_magn"
+                 "bosch,bmc156"
+                 "bosch,bmc156_magn" (DEPRECATED, use bosch,bmc156)
+                 "bosch,bmm150_magn" (DEPRECATED, use bosch,bmc156)
   - reg : the I2C address of the magnetometer
 
 Optional properties: