Message ID | 20220311164628.378849-2-gengcixi@gmail.com (mailing list archive) |
---|---|
State | Changes Requested |
Headers | show |
Series | iio: adc: sc27xx: adjust structure and add PMIC's support | expand |
On Sat, 12 Mar 2022 00:46:22 +0800 Cixi Geng <gengcixi@gmail.com> wrote: > From: Cixi Geng <cixi.geng1@unisoc.com> In title, use dt-binding instead of dtbindings at the end. > > sprd,ump9620-adc is one variant of sc27xx series, add ump9620 in > dtbindings. dt-bindings. > > Signed-off-by: Chunyan Zhang <zhang.lyra@gmail.com> > Signed-off-by: Cixi Geng <cixi.geng1@unisoc.com> If the patch was authored by Chunyan Zhang, it should be From: Chunyan Zhang, if it is more complex than you simply passing the patch on then we should see a co-developed to indicate that. Patch looks good to me Jonathan > --- > .../bindings/iio/adc/sprd,sc2720-adc.yaml | 30 +++++++++++++++++-- > 1 file changed, 27 insertions(+), 3 deletions(-) > > diff --git a/Documentation/devicetree/bindings/iio/adc/sprd,sc2720-adc.yaml b/Documentation/devicetree/bindings/iio/adc/sprd,sc2720-adc.yaml > index caa3ee0b4b8c..331b08fb1761 100644 > --- a/Documentation/devicetree/bindings/iio/adc/sprd,sc2720-adc.yaml > +++ b/Documentation/devicetree/bindings/iio/adc/sprd,sc2720-adc.yaml > @@ -20,6 +20,7 @@ properties: > - sprd,sc2723-adc > - sprd,sc2730-adc > - sprd,sc2731-adc > + - sprd,ump9620-adc > > reg: > maxItems: 1 > @@ -37,9 +38,32 @@ properties: > maxItems: 2 > > nvmem-cell-names: > - items: > - - const: big_scale_calib > - - const: small_scale_calib > + description: Names for each nvmem-cells specified. > + > +if: > + not: > + properties: > + compatible: > + contains: > + enum: > + - sprd,ump9620-adc > +then: > + properties: > + nvmem-cell-names: > + items: > + - const: big_scale_calib > + - const: small_scale_calib > + > +else: > + properties: > + nvmem-cell-names: > + items: > + - const: big_scale_calib1 > + - const: big_scale_calib2 > + - const: small_scale_calib1 > + - const: small_scale_calib2 > + - const: vbat_det_cal1 > + - const: vbat_det_cal2 > > required: > - compatible
On 11/03/2022 17:46, Cixi Geng wrote: > From: Cixi Geng <cixi.geng1@unisoc.com> > > sprd,ump9620-adc is one variant of sc27xx series, add ump9620 in > dtbindings. > > Signed-off-by: Chunyan Zhang <zhang.lyra@gmail.com> > Signed-off-by: Cixi Geng <cixi.geng1@unisoc.com> > --- > .../bindings/iio/adc/sprd,sc2720-adc.yaml | 30 +++++++++++++++++-- > 1 file changed, 27 insertions(+), 3 deletions(-) > > diff --git a/Documentation/devicetree/bindings/iio/adc/sprd,sc2720-adc.yaml b/Documentation/devicetree/bindings/iio/adc/sprd,sc2720-adc.yaml > index caa3ee0b4b8c..331b08fb1761 100644 > --- a/Documentation/devicetree/bindings/iio/adc/sprd,sc2720-adc.yaml > +++ b/Documentation/devicetree/bindings/iio/adc/sprd,sc2720-adc.yaml > @@ -20,6 +20,7 @@ properties: > - sprd,sc2723-adc > - sprd,sc2730-adc > - sprd,sc2731-adc > + - sprd,ump9620-adc > > reg: > maxItems: 1 > @@ -37,9 +38,32 @@ properties: > maxItems: 2 > > nvmem-cell-names: > - items: > - - const: big_scale_calib > - - const: small_scale_calib Please test your changes with dt_binding_check and dtbs_check. Your change looks not complete - you have still nvmem-cells = 2. Best regards, Krzysztof
Jonathan Cameron <jic23@kernel.org> 于2022年3月20日周日 21:22写道: > > On Sat, 12 Mar 2022 00:46:22 +0800 > Cixi Geng <gengcixi@gmail.com> wrote: > > > From: Cixi Geng <cixi.geng1@unisoc.com> > > In title, use dt-binding instead of dtbindings at the end. > > > > > sprd,ump9620-adc is one variant of sc27xx series, add ump9620 in > > dtbindings. > > dt-bindings. > > > > > Signed-off-by: Chunyan Zhang <zhang.lyra@gmail.com> > > Signed-off-by: Cixi Geng <cixi.geng1@unisoc.com> > > If the patch was authored by Chunyan Zhang, it should be From: Chunyan Zhang, > if it is more complex than you simply passing the patch on then we should > see a co-developed to indicate that. Thanks your advise, I will fix the comment and add correct Signed message > > Patch looks good to me > > Jonathan > > > --- > > .../bindings/iio/adc/sprd,sc2720-adc.yaml | 30 +++++++++++++++++-- > > 1 file changed, 27 insertions(+), 3 deletions(-) > > > > diff --git a/Documentation/devicetree/bindings/iio/adc/sprd,sc2720-adc.yaml b/Documentation/devicetree/bindings/iio/adc/sprd,sc2720-adc.yaml > > index caa3ee0b4b8c..331b08fb1761 100644 > > --- a/Documentation/devicetree/bindings/iio/adc/sprd,sc2720-adc.yaml > > +++ b/Documentation/devicetree/bindings/iio/adc/sprd,sc2720-adc.yaml > > @@ -20,6 +20,7 @@ properties: > > - sprd,sc2723-adc > > - sprd,sc2730-adc > > - sprd,sc2731-adc > > + - sprd,ump9620-adc > > > > reg: > > maxItems: 1 > > @@ -37,9 +38,32 @@ properties: > > maxItems: 2 > > > > nvmem-cell-names: > > - items: > > - - const: big_scale_calib > > - - const: small_scale_calib > > + description: Names for each nvmem-cells specified. > > + > > +if: > > + not: > > + properties: > > + compatible: > > + contains: > > + enum: > > + - sprd,ump9620-adc > > +then: > > + properties: > > + nvmem-cell-names: > > + items: > > + - const: big_scale_calib > > + - const: small_scale_calib > > + > > +else: > > + properties: > > + nvmem-cell-names: > > + items: > > + - const: big_scale_calib1 > > + - const: big_scale_calib2 > > + - const: small_scale_calib1 > > + - const: small_scale_calib2 > > + - const: vbat_det_cal1 > > + - const: vbat_det_cal2 > > > > required: > > - compatible >
Krzysztof Kozlowski <krzk@kernel.org> 于2022年3月20日周日 22:50写道: > > On 11/03/2022 17:46, Cixi Geng wrote: > > From: Cixi Geng <cixi.geng1@unisoc.com> > > > > sprd,ump9620-adc is one variant of sc27xx series, add ump9620 in > > dtbindings. > > > > Signed-off-by: Chunyan Zhang <zhang.lyra@gmail.com> > > Signed-off-by: Cixi Geng <cixi.geng1@unisoc.com> > > --- > > .../bindings/iio/adc/sprd,sc2720-adc.yaml | 30 +++++++++++++++++-- > > 1 file changed, 27 insertions(+), 3 deletions(-) > > > > diff --git a/Documentation/devicetree/bindings/iio/adc/sprd,sc2720-adc.yaml b/Documentation/devicetree/bindings/iio/adc/sprd,sc2720-adc.yaml > > index caa3ee0b4b8c..331b08fb1761 100644 > > --- a/Documentation/devicetree/bindings/iio/adc/sprd,sc2720-adc.yaml > > +++ b/Documentation/devicetree/bindings/iio/adc/sprd,sc2720-adc.yaml > > @@ -20,6 +20,7 @@ properties: > > - sprd,sc2723-adc > > - sprd,sc2730-adc > > - sprd,sc2731-adc > > + - sprd,ump9620-adc > > > > reg: > > maxItems: 1 > > @@ -37,9 +38,32 @@ properties: > > maxItems: 2 > > > > nvmem-cell-names: > > - items: > > - - const: big_scale_calib > > - - const: small_scale_calib > > Please test your changes with dt_binding_check and dtbs_check. Your > change looks not complete - you have still nvmem-cells = 2. > Hi Krzysztof I test all is PASS on my local. could you tell how did you test? my_logs: cixi.geng1@tj10039pcu:~/upsteatming/linux$ make DT_CHECKER_FLAGS=-m dt_binding_check &>dt_check.log cixi.geng1@tj10039pcu:~/upsteatming/linux$ cat dt_check.log |grep sprd,sc2720 DTEX Documentation/devicetree/bindings/iio/adc/sprd,sc2720-adc.example.dts DTC Documentation/devicetree/bindings/iio/adc/sprd,sc2720-adc.example.dt.yaml CHECK Documentation/devicetree/bindings/iio/adc/sprd,sc2720-adc.example.dt.yaml cixi.geng1@tj10039pcu:~/upsteatming/linux$ tuxmake -C ${kernel_src} -b ${topdir}/obj/gcc -o ${topdir}/dist/gcc -a $ARCH -t gcc -K CONFIG_ARCH_${PLAT}=y -K CONFIG_MFD_SC27XX_PMIC=y -K CONFIG_SC27XX_ADC=y I: config: PASS in 0:00:00.000549 I: default: PASS in 0:10:20.931602 I: kernel: PASS in 0:01:10.643458 I: xipkernel: SKIP in 0:00:00.003244 I: modules: PASS in 0:00:35.658938 I: dtbs: PASS in 0:00:18.696416 I: dtbs-legacy: SKIP in 0:00:00.005625 I: debugkernel: PASS in 0:00:11.541855 I: headers: PASS in 0:00:11.778253 I: build output in /home/cixi.geng1/upsteatming/dist/gcc > > Best regards, > Krzysztof
On 24/03/2022 07:22, Cixi Geng wrote: > Krzysztof Kozlowski <krzk@kernel.org> 于2022年3月20日周日 22:50写道: >> >> On 11/03/2022 17:46, Cixi Geng wrote: >>> From: Cixi Geng <cixi.geng1@unisoc.com> >>> >>> sprd,ump9620-adc is one variant of sc27xx series, add ump9620 in >>> dtbindings. >>> >>> Signed-off-by: Chunyan Zhang <zhang.lyra@gmail.com> >>> Signed-off-by: Cixi Geng <cixi.geng1@unisoc.com> >>> --- >>> .../bindings/iio/adc/sprd,sc2720-adc.yaml | 30 +++++++++++++++++-- >>> 1 file changed, 27 insertions(+), 3 deletions(-) >>> >>> diff --git a/Documentation/devicetree/bindings/iio/adc/sprd,sc2720-adc.yaml b/Documentation/devicetree/bindings/iio/adc/sprd,sc2720-adc.yaml >>> index caa3ee0b4b8c..331b08fb1761 100644 >>> --- a/Documentation/devicetree/bindings/iio/adc/sprd,sc2720-adc.yaml >>> +++ b/Documentation/devicetree/bindings/iio/adc/sprd,sc2720-adc.yaml >>> @@ -20,6 +20,7 @@ properties: >>> - sprd,sc2723-adc >>> - sprd,sc2730-adc >>> - sprd,sc2731-adc >>> + - sprd,ump9620-adc >>> >>> reg: >>> maxItems: 1 >>> @@ -37,9 +38,32 @@ properties: >>> maxItems: 2 >>> >>> nvmem-cell-names: >>> - items: >>> - - const: big_scale_calib >>> - - const: small_scale_calib >> >> Please test your changes with dt_binding_check and dtbs_check. Your >> change looks not complete - you have still nvmem-cells = 2. >> > Hi Krzysztof > I test all is PASS on my local. could you tell how did you test? > my_logs: > cixi.geng1@tj10039pcu:~/upsteatming/linux$ make DT_CHECKER_FLAGS=-m > dt_binding_check &>dt_check.log > cixi.geng1@tj10039pcu:~/upsteatming/linux$ cat dt_check.log |grep sprd,sc2720 > DTEX Documentation/devicetree/bindings/iio/adc/sprd,sc2720-adc.example.dts > DTC Documentation/devicetree/bindings/iio/adc/sprd,sc2720-adc.example.dt.yaml > CHECK Documentation/devicetree/bindings/iio/adc/sprd,sc2720-adc.example.dt.yaml > cixi.geng1@tj10039pcu:~/upsteatming/linux$ tuxmake -C ${kernel_src} -b > ${topdir}/obj/gcc -o ${topdir}/dist/gcc -a $ARCH -t gcc -K > CONFIG_ARCH_${PLAT}=y -K CONFIG_MFD_SC27XX_PMIC=y -K > CONFIG_SC27XX_ADC=y > The method is correct, just please test sprd,ump9620-adc (either in example in the binding or your DTS with `make dtbs_check DT_SCHEMA_FILES=sprd,sc2720-adc.yaml). Best regards, Krzysztof
diff --git a/Documentation/devicetree/bindings/iio/adc/sprd,sc2720-adc.yaml b/Documentation/devicetree/bindings/iio/adc/sprd,sc2720-adc.yaml index caa3ee0b4b8c..331b08fb1761 100644 --- a/Documentation/devicetree/bindings/iio/adc/sprd,sc2720-adc.yaml +++ b/Documentation/devicetree/bindings/iio/adc/sprd,sc2720-adc.yaml @@ -20,6 +20,7 @@ properties: - sprd,sc2723-adc - sprd,sc2730-adc - sprd,sc2731-adc + - sprd,ump9620-adc reg: maxItems: 1 @@ -37,9 +38,32 @@ properties: maxItems: 2 nvmem-cell-names: - items: - - const: big_scale_calib - - const: small_scale_calib + description: Names for each nvmem-cells specified. + +if: + not: + properties: + compatible: + contains: + enum: + - sprd,ump9620-adc +then: + properties: + nvmem-cell-names: + items: + - const: big_scale_calib + - const: small_scale_calib + +else: + properties: + nvmem-cell-names: + items: + - const: big_scale_calib1 + - const: big_scale_calib2 + - const: small_scale_calib1 + - const: small_scale_calib2 + - const: vbat_det_cal1 + - const: vbat_det_cal2 required: - compatible