From fdbb740d7c3fd701ca3af1f6033060cfd358c2bc Mon Sep 17 00:00:00 2001
From: Przemyslaw Marczak
Date: Tue, 27 Oct 2015 13:07:55 +0100
Subject: s5p: cpu_info: print "cpu-model" if exists in dts
The CPU name for Exynos was concatenated with cpu id,
but for new Exynos platforms, like Chromebook Peach Pi
based on Exynos5800, the name of SoC variant does not
include the real SoC cpu id (0x5422).
For such case, the CPU name should be defined in device tree.
This commit introduces new device-tree property for Exynos:
- "cpu-model" - with cpu name string
If defined, then the cpu id is not printed.
Signed-off-by: Przemyslaw Marczak
Cc: Minkyu Kang
Cc: Simon Glass
Reviewed-by: Simon Glass
Tested-by: Anand Moon
Signed-off-by: Minkyu Kang
---
doc/device-tree-bindings/exynos/soc.txt | 21 +++++++++++++++++++++
1 file changed, 21 insertions(+)
create mode 100644 doc/device-tree-bindings/exynos/soc.txt
(limited to 'doc')
diff --git a/doc/device-tree-bindings/exynos/soc.txt b/doc/device-tree-bindings/exynos/soc.txt
new file mode 100644
index 0000000000..9ba6f3b9f8
--- /dev/null
+++ b/doc/device-tree-bindings/exynos/soc.txt
@@ -0,0 +1,21 @@
+Exynos SoC model
+
+The "cpu-model" property is a non-standard extension for the device tree root
+node. Since the cpu id of some Exynos variants does not correspond to product
+name, this property fills the gap.
+
+For almost all Exynos based boards in the kernel, the product name corresponds
+to the device tree file name. The same name is generated in U-Boot, so the new
+property allows doing it automatically.
+
+Required properties:
+ - cpu-model : Exynos product name
+
+Example:
+
+/ {
+ model = "Samsung/Google Peach Pi board based on Exynos5800";
+ cpu-model = "Exynos5800";
+
+ compatible = ...
+};
--
cgit
From 35d460fbc8ced954fe23812e706d3eebc1dd2b4d Mon Sep 17 00:00:00 2001
From: Przemyslaw Marczak
Date: Tue, 27 Oct 2015 13:07:58 +0100
Subject: dm: pmic: add s2mps11 PMIC I/O driver
This driver allows I/O operations on the Samsung S2MPS11 PMIC,
which provides lots of LDO/BUCK outputs.
To enable it, update defconfig with:
- CONFIG_PMIC_S2MPS11
and additional, if were not defined:
- CONFIG_CMD_PMIC
- CONFIG_ERRNO_STR
The binding info: doc/device-tree-bindings/pmic/s2mps11.txt
Signed-off-by: Przemyslaw Marczak
Reviewed-by: Simon Glass
Tested-by: Anand Moon
Signed-off-by: Minkyu Kang
---
doc/device-tree-bindings/pmic/s2mps11.txt | 17 +++++++++++++++++
1 file changed, 17 insertions(+)
create mode 100644 doc/device-tree-bindings/pmic/s2mps11.txt
(limited to 'doc')
diff --git a/doc/device-tree-bindings/pmic/s2mps11.txt b/doc/device-tree-bindings/pmic/s2mps11.txt
new file mode 100644
index 0000000000..422f14f13e
--- /dev/null
+++ b/doc/device-tree-bindings/pmic/s2mps11.txt
@@ -0,0 +1,17 @@
+SAMSUNG, S2MPS11 PMIC
+
+This file describes the binding info for the PMIC driver:
+- drivers/power/pmic/s2mps11.c
+
+Required properties:
+- compatible: "samsung,s2mps11-pmic"
+- reg = 0x66
+
+With those two properties, the pmic device can be used for read/write only.
+
+Example:
+
+s2mps11@66 {
+ compatible = "samsung,s2mps11-pmic";
+ reg = <0x66>;
+};
--
cgit
From 5decbf53006c8e2aed8e5506b3961810c1544b3c Mon Sep 17 00:00:00 2001
From: Przemyslaw Marczak
Date: Tue, 27 Oct 2015 13:08:00 +0100
Subject: dm: adc: add simple ADC uclass implementation
This commit adds:
- new uclass id: UCLASS_ADC
- new uclass driver: drivers/adc/adc-uclass.c
The new uclass's API allows for ADC operation on:
* single-channel with channel selection by a number
* multti-channel with channel selection by bit mask
ADC uclass's functions:
* single-channel:
- adc_start_channel() - start channel conversion
- adc_channel_data() - get conversion data
- adc_channel_single_shot() - start/get conversion data
* multi-channel:
- adc_start_channels() - start selected channels conversion
- adc_channels_data() - get conversion data
- adc_channels_single_shot() - start/get conversion data for channels
selected by bit mask
* general:
- adc_stop() - stop the conversion
- adc_vdd_value() - positive reference Voltage value with polarity [uV]
- adc_vss_value() - negative reference Voltage value with polarity [uV]
- adc_data_mask() - conversion data bit mask
The device tree can provide below constraints/properties:
- vdd-polarity-negative: if true: Vdd = vdd-microvolts * (-1)
- vss-polarity-negative: if true: Vss = vss-microvolts * (-1)
- vdd-supply: phandle to Vdd regulator's node
- vss-supply: phandle to Vss regulator's node
And optional, checked only if the above corresponding, doesn't exist:
- vdd-microvolts: positive reference Voltage [uV]
- vss-microvolts: negative reference Voltage [uV]
Signed-off-by: Przemyslaw Marczak
Cc: Simon Glass
Signed-off-by: Minkyu Kang
---
doc/device-tree-bindings/adc/adc.txt | 62 ++++++++++++++++++++++++++++++++++++
1 file changed, 62 insertions(+)
create mode 100644 doc/device-tree-bindings/adc/adc.txt
(limited to 'doc')
diff --git a/doc/device-tree-bindings/adc/adc.txt b/doc/device-tree-bindings/adc/adc.txt
new file mode 100644
index 0000000000..463de3c8c2
--- /dev/null
+++ b/doc/device-tree-bindings/adc/adc.txt
@@ -0,0 +1,62 @@
+ADC device binding
+
+There are no mandatory properties for ADC. However, if Voltage info is required,
+then there are two options:
+- use microvolts constraint or
+- use regulator phandle to enable/read supply's Voltage
+
+Properties and constraints:
+*optional and always checked, Voltage polarity info:
+- vdd-polarity-negative: positive reference Voltage has a negative polarity
+- vss-polarity-negative: negative reference Voltage has a negative polarity
+
+Chose one option, for each supply (Vdd/Vss):
+
+*optional and always checked, supply Voltage constants:
+- vdd-supply: phandle to Vdd regulator's node
+- vss-supply: phandle to Vss regulator's node
+
+*optional and checked only if the above corresponding, doesn't exist:
+- vdd-microvolts: positive reference Voltage value [uV]
+- vss-microvolts: negative reference Voltage value [uV]
+
+Example with constant 'Vdd' value:
+adc@1000000 {
+ compatible = "some-adc";
+ reg = <0xaabb000 0x100>;
+ status = "enabled";
+ vdd-microvolts = <1800000>;
+};
+
+Example of supply phandle usage, for the ADC's VDD/VSS references as below:
+ _______ _______
+ |Sandbox| |Sandbox|
+ : PMIC : : ADC :
+ . . . .
+ | | (Vdd) | AIN0|-->
+ | BUCK2|-------|VDDref |
+ | (3.3V)| _|VSSref |
+ |_______| | |_______|
+ _|_
+
+For the above PMIC, the node can be defined as follows:
+sandbox_pmic {
+ compatible = "sandbox,pmic";
+ ...
+ buck2: buck2 {
+ regulator-name = "SUPPLY_3.3V";
+ regulator-min-microvolt = <3300000>;
+ regulator-max-microvolt = <3300000>;
+ };
+ ...
+};
+
+For the above ADC, the node can be defined as follows:
+adc@0 {
+ compatible = "sandbox,adc";
+ vdd-supply = <&buck2>;
+ vss-microvolts = <0>;
+};
+
+The ADC uclass code, will enable the supply before start of the conversion,
+but it will not configure the regulator settings.
--
cgit