2013-05-15 00:04:15 +08:00
|
|
|
* Universal Flash Storage (UFS) Host Controller
|
|
|
|
|
|
|
|
UFSHC nodes are defined to describe on-chip UFS host controllers.
|
|
|
|
Each UFS controller instance should have its own node.
|
|
|
|
|
|
|
|
Required properties:
|
scsi: dt-bindings: ufs: Fix the compatible string definition
If you look at the bindings for the UFS Host Controller it says:
- compatible: must contain "jedec,ufs-1.1" or "jedec,ufs-2.0", may
also list one or more of the following:
"qcom,msm8994-ufshc"
"qcom,msm8996-ufshc"
"qcom,ufshc"
My reading of that is that it's fine to just have either of these:
1. "qcom,msm8996-ufshc", "jedec,ufs-2.0"
2. "qcom,ufshc", "jedec,ufs-2.0"
As far as I can tell neither of the above is actually a good idea.
For #1 it turns out that the driver currently only keys off the
compatible string "qcom,ufshc" so it won't actually probe.
For #2 the driver won't probe but it's not a good idea to keep the SoC
name out of the compatible string.
Let's update the compatible string to make it really explicit. We'll
include a nod to the existing driver and the old binding and say that
we should always include the "qcom,ufshc" string in addition to the
SoC compatible string.
While we're at it we'll also include another example SoC known to have
UFS: sdm845.
Fixes: 47555a5c8a11 ("scsi: ufs: make the UFS variant a platform device")
Signed-off-by: Douglas Anderson <dianders@chromium.org>
Reviewed-by: Vivek Gautam <vivek.gautam@codeaurora.org>
Reviewed-by: Rob Herring <robh@kernel.org>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
2018-10-13 05:39:26 +08:00
|
|
|
- compatible : must contain "jedec,ufs-1.1" or "jedec,ufs-2.0"
|
|
|
|
|
|
|
|
For Qualcomm SoCs must contain, as below, an
|
|
|
|
SoC-specific compatible along with "qcom,ufshc" and
|
|
|
|
the appropriate jedec string:
|
|
|
|
"qcom,msm8994-ufshc", "qcom,ufshc", "jedec,ufs-2.0"
|
|
|
|
"qcom,msm8996-ufshc", "qcom,ufshc", "jedec,ufs-2.0"
|
2019-02-25 20:17:02 +08:00
|
|
|
"qcom,msm8998-ufshc", "qcom,ufshc", "jedec,ufs-2.0"
|
scsi: dt-bindings: ufs: Fix the compatible string definition
If you look at the bindings for the UFS Host Controller it says:
- compatible: must contain "jedec,ufs-1.1" or "jedec,ufs-2.0", may
also list one or more of the following:
"qcom,msm8994-ufshc"
"qcom,msm8996-ufshc"
"qcom,ufshc"
My reading of that is that it's fine to just have either of these:
1. "qcom,msm8996-ufshc", "jedec,ufs-2.0"
2. "qcom,ufshc", "jedec,ufs-2.0"
As far as I can tell neither of the above is actually a good idea.
For #1 it turns out that the driver currently only keys off the
compatible string "qcom,ufshc" so it won't actually probe.
For #2 the driver won't probe but it's not a good idea to keep the SoC
name out of the compatible string.
Let's update the compatible string to make it really explicit. We'll
include a nod to the existing driver and the old binding and say that
we should always include the "qcom,ufshc" string in addition to the
SoC compatible string.
While we're at it we'll also include another example SoC known to have
UFS: sdm845.
Fixes: 47555a5c8a11 ("scsi: ufs: make the UFS variant a platform device")
Signed-off-by: Douglas Anderson <dianders@chromium.org>
Reviewed-by: Vivek Gautam <vivek.gautam@codeaurora.org>
Reviewed-by: Rob Herring <robh@kernel.org>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
2018-10-13 05:39:26 +08:00
|
|
|
"qcom,sdm845-ufshc", "qcom,ufshc", "jedec,ufs-2.0"
|
2019-10-24 15:48:00 +08:00
|
|
|
"qcom,sm8150-ufshc", "qcom,ufshc", "jedec,ufs-2.0"
|
2013-05-15 00:04:15 +08:00
|
|
|
- interrupts : <interrupt mapping for UFS host controller IRQ>
|
|
|
|
- reg : <registers mapping>
|
|
|
|
|
2014-09-25 20:32:22 +08:00
|
|
|
Optional properties:
|
2015-10-28 19:15:49 +08:00
|
|
|
- phys : phandle to UFS PHY node
|
|
|
|
- phy-names : the string "ufsphy" when is found in a node, along
|
|
|
|
with "phys" attribute, provides phandle to UFS PHY node
|
2014-09-25 20:32:24 +08:00
|
|
|
- vdd-hba-supply : phandle to UFS host controller supply regulator node
|
2014-09-25 20:32:22 +08:00
|
|
|
- vcc-supply : phandle to VCC supply regulator node
|
|
|
|
- vccq-supply : phandle to VCCQ supply regulator node
|
|
|
|
- vccq2-supply : phandle to VCCQ2 supply regulator node
|
|
|
|
- vcc-supply-1p8 : For embedded UFS devices, valid VCC range is 1.7-1.95V
|
|
|
|
or 2.7-3.6V. This boolean property when set, specifies
|
|
|
|
to use low voltage range of 1.7-1.95V. Note for external
|
|
|
|
UFS cards this property is invalid and valid VCC range is
|
|
|
|
always 2.7-3.6V.
|
|
|
|
- vcc-max-microamp : specifies max. load that can be drawn from vcc supply
|
|
|
|
- vccq-max-microamp : specifies max. load that can be drawn from vccq supply
|
|
|
|
- vccq2-max-microamp : specifies max. load that can be drawn from vccq2 supply
|
|
|
|
|
2014-09-25 20:32:23 +08:00
|
|
|
- clocks : List of phandle and clock specifier pairs
|
|
|
|
- clock-names : List of clock input name strings sorted in the same
|
|
|
|
order as the clocks property.
|
2018-10-16 16:59:41 +08:00
|
|
|
"ref_clk" indicates reference clock frequency.
|
|
|
|
UFS host supplies reference clock to UFS device and UFS device
|
|
|
|
specification allows host to provide one of the 4 frequencies (19.2 MHz,
|
|
|
|
26 MHz, 38.4 MHz, 52MHz) for reference clock. This "ref_clk" entry is
|
|
|
|
parsed and used to update the reference clock setting in device.
|
|
|
|
Defaults to 26 MHz(as per specification) if not specified by host.
|
2014-09-25 20:32:33 +08:00
|
|
|
- freq-table-hz : Array of <min max> operating frequencies stored in the same
|
|
|
|
order as the clocks property. If this property is not
|
|
|
|
defined or a value in the array is "0" then it is assumed
|
|
|
|
that the frequency is set by the parent clock or a
|
|
|
|
fixed rate clock source.
|
2016-03-10 23:37:05 +08:00
|
|
|
-lanes-per-direction : number of lanes available per direction - either 1 or 2.
|
|
|
|
Note that it is assume same number of lanes is used both
|
|
|
|
directions at once. If not specified, default is 2 lanes per direction.
|
2019-03-22 01:17:53 +08:00
|
|
|
- #reset-cells : Must be <1> for Qualcomm UFS controllers that expose
|
|
|
|
PHY reset from the UFS controller.
|
2018-07-17 17:36:57 +08:00
|
|
|
- resets : reset node register
|
|
|
|
- reset-names : describe reset node register, the "rst" corresponds to reset the whole UFS IP.
|
2019-08-29 03:17:55 +08:00
|
|
|
- reset-gpios : A phandle and gpio specifier denoting the GPIO connected
|
|
|
|
to the RESET pin of the UFS memory device.
|
2014-09-25 20:32:23 +08:00
|
|
|
|
2014-09-25 20:32:22 +08:00
|
|
|
Note: If above properties are not defined it can be assumed that the supply
|
2014-09-25 20:32:23 +08:00
|
|
|
regulators or clocks are always on.
|
2014-09-25 20:32:22 +08:00
|
|
|
|
2013-05-15 00:04:15 +08:00
|
|
|
Example:
|
2017-11-30 04:55:15 +08:00
|
|
|
ufshc@fc598000 {
|
2013-05-15 00:04:15 +08:00
|
|
|
compatible = "jedec,ufs-1.1";
|
|
|
|
reg = <0xfc598000 0x800>;
|
|
|
|
interrupts = <0 28 0>;
|
2014-09-25 20:32:22 +08:00
|
|
|
|
2014-09-25 20:32:24 +08:00
|
|
|
vdd-hba-supply = <&xxx_reg0>;
|
2014-09-25 20:32:22 +08:00
|
|
|
vcc-supply = <&xxx_reg1>;
|
|
|
|
vcc-supply-1p8;
|
|
|
|
vccq-supply = <&xxx_reg2>;
|
|
|
|
vccq2-supply = <&xxx_reg3>;
|
|
|
|
vcc-max-microamp = 500000;
|
|
|
|
vccq-max-microamp = 200000;
|
|
|
|
vccq2-max-microamp = 200000;
|
2014-09-25 20:32:23 +08:00
|
|
|
|
2018-07-17 17:36:57 +08:00
|
|
|
clocks = <&core 0>, <&ref 0>, <&phy 0>, <&iface 0>;
|
|
|
|
clock-names = "core_clk", "ref_clk", "phy_clk", "iface_clk";
|
|
|
|
freq-table-hz = <100000000 200000000>, <0 0>, <0 0>, <0 0>;
|
|
|
|
resets = <&reset 0 1>;
|
|
|
|
reset-names = "rst";
|
2015-10-28 19:15:49 +08:00
|
|
|
phys = <&ufsphy1>;
|
|
|
|
phy-names = "ufsphy";
|
2019-03-22 01:17:53 +08:00
|
|
|
#reset-cells = <1>;
|
2013-05-15 00:04:15 +08:00
|
|
|
};
|