Skip to content

Commit ecedfa4

Browse files
Vladislav Kulikovjic23
authored andcommitted
dt-bindings: iio: magnetometer: add MEMSIC MMC5983MA
Add a Devicetree binding for the MEMSIC MMC5983MA 3-axis magnetometer. MMC5983MA is not register-compatible with the existing MEMSIC magnetometer drivers. It has a different register map, 18-bit output data format, and I2C/SPI transport support. Reviewed-by: David Lechner <dlechner@baylibre.com> Acked-by: Conor Dooley <conor.dooley@microchip.com> Signed-off-by: Vladislav Kulikov <vlad.kulikov.c@gmail.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org>
1 parent f608e9c commit ecedfa4

2 files changed

Lines changed: 69 additions & 0 deletions

File tree

Lines changed: 63 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,63 @@
1+
# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
2+
%YAML 1.2
3+
---
4+
$id: http://devicetree.org/schemas/iio/magnetometer/memsic,mmc5983.yaml#
5+
$schema: http://devicetree.org/meta-schemas/core.yaml#
6+
7+
title: MEMSIC MMC5983MA 3-axis magnetic sensor
8+
9+
maintainers:
10+
- Vladislav Kulikov <vlad.kulikov.c@gmail.com>
11+
12+
properties:
13+
compatible:
14+
const: memsic,mmc5983
15+
16+
reg:
17+
maxItems: 1
18+
19+
interrupts:
20+
maxItems: 1
21+
22+
vdd-supply:
23+
description: Regulator that provides power to the sensor
24+
25+
vddio-supply:
26+
description: Regulator that provides power to the digital interface and INT pin
27+
28+
required:
29+
- compatible
30+
- reg
31+
- vdd-supply
32+
33+
allOf:
34+
- $ref: /schemas/spi/spi-peripheral-props.yaml#
35+
36+
unevaluatedProperties: false
37+
38+
examples:
39+
- |
40+
i2c {
41+
#address-cells = <1>;
42+
#size-cells = <0>;
43+
44+
magnetometer@30 {
45+
compatible = "memsic,mmc5983";
46+
reg = <0x30>;
47+
vdd-supply = <&vdd_3v3_reg>;
48+
vddio-supply = <&vdd_3v3_reg>;
49+
};
50+
};
51+
- |
52+
spi {
53+
#address-cells = <1>;
54+
#size-cells = <0>;
55+
56+
magnetometer@0 {
57+
compatible = "memsic,mmc5983";
58+
reg = <0>;
59+
spi-max-frequency = <10000000>;
60+
vdd-supply = <&vdd_3v3_reg>;
61+
vddio-supply = <&vdd_3v3_reg>;
62+
};
63+
};

MAINTAINERS

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17179,6 +17179,12 @@ F: drivers/mtd/
1717917179
F: include/linux/mtd/
1718017180
F: include/uapi/mtd/
1718117181

17182+
MEMSIC MMC5983 MAGNETOMETER DRIVER
17183+
M: Vladislav Kulikov <vlad.kulikov.c@gmail.com>
17184+
L: linux-iio@vger.kernel.org
17185+
S: Maintained
17186+
F: Documentation/devicetree/bindings/iio/magnetometer/memsic,mmc5983.yaml
17187+
1718217188
MEN A21 WATCHDOG DRIVER
1718317189
M: Johannes Thumshirn <morbidrsa@gmail.com>
1718417190
L: linux-watchdog@vger.kernel.org

0 commit comments

Comments
 (0)