Hi,

These files are only hooked up to the build on arm64, and I don't have this 
arch, so this is not even compile tested by me. Hopefully, did not miss 
anything in grepping. Can somebody with arm64 please compile and report any 
issues?

Thanks



Index: dev/fdt/amlpwm.c
===================================================================
RCS file: /cvs/src/sys/dev/fdt/amlpwm.c,v
retrieving revision 1.1
diff -u -p -u -p -r1.1 amlpwm.c
--- dev/fdt/amlpwm.c    30 Sep 2019 20:42:45 -0000      1.1
+++ dev/fdt/amlpwm.c    13 Mar 2020 01:38:32 -0000
@@ -181,7 +181,7 @@ amlpwm_set_state(void *cookie, uint32_t 
                return EINVAL;
 
        /* Hardware doesn't support polarity inversion. */
-       if (ps->ps_flags & PWM_POLARITY_INVERTED)
+       if (ps->ps_pwmflags & PWM_POLARITY_INVERTED)
                return EINVAL;
 
        if (!ps->ps_enabled) {
Index: dev/fdt/rkpwm.c
===================================================================
RCS file: /cvs/src/sys/dev/fdt/rkpwm.c,v
retrieving revision 1.1
diff -u -p -u -p -r1.1 rkpwm.c
--- dev/fdt/rkpwm.c     3 Dec 2019 09:08:48 -0000       1.1
+++ dev/fdt/rkpwm.c     13 Mar 2020 01:38:32 -0000
@@ -170,7 +170,7 @@ rkpwm_set_state(void *cookie, uint32_t *
        HCLR4(sc, PWM_V2_CTRL, PWM_V2_CTRL_INACTIVE_POSITIVE);
        HCLR4(sc, PWM_V2_CTRL, PWM_V2_CTRL_DUTY_POSITIVE);
 
-       if (ps->ps_flags & PWM_POLARITY_INVERTED)
+       if (ps->ps_pwmflags & PWM_POLARITY_INVERTED)
                HSET4(sc, PWM_V2_CTRL, PWM_V2_CTRL_INACTIVE_POSITIVE);
        else
                HSET4(sc, PWM_V2_CTRL, PWM_V2_CTRL_DUTY_POSITIVE);
Index: dev/fdt/sxipwm.c
===================================================================
RCS file: /cvs/src/sys/dev/fdt/sxipwm.c,v
retrieving revision 1.1
diff -u -p -u -p -r1.1 sxipwm.c
--- dev/fdt/sxipwm.c    21 Oct 2019 20:52:33 -0000      1.1
+++ dev/fdt/sxipwm.c    13 Mar 2020 01:38:32 -0000
@@ -217,7 +217,7 @@ sxipwm_set_state(void *cookie, uint32_t 
                reg |= (PWM_CH0_EN | SCLK_CH0_GATING);
        else
                reg &= ~(PWM_CH0_EN | SCLK_CH0_GATING);
-       if (ps->ps_flags & PWM_POLARITY_INVERTED)
+       if (ps->ps_pwmflags & PWM_POLARITY_INVERTED)
                reg &= ~PWM_CH0_ACT_STA;
        else
                reg |= PWM_CH0_ACT_STA;
Index: dev/ofw/ofw_misc.c
===================================================================
RCS file: /cvs/src/sys/dev/ofw/ofw_misc.c,v
retrieving revision 1.14
diff -u -p -u -p -r1.14 ofw_misc.c
--- dev/ofw/ofw_misc.c  1 Mar 2020 18:00:12 -0000       1.14
+++ dev/ofw/ofw_misc.c  13 Mar 2020 01:38:32 -0000
@@ -304,7 +304,7 @@ pwm_init_state(uint32_t *cells, struct p
                        if (pd->pd_cells > 2)
                                ps->ps_period = cells[2];
                        if (pd->pd_cells > 3)
-                               ps->ps_flags = cells[3];
+                               ps->ps_pwmflags = cells[3];
                        return 0;
                }
        }
Index: dev/ofw/ofw_misc.h
===================================================================
RCS file: /cvs/src/sys/dev/ofw/ofw_misc.h,v
retrieving revision 1.10
diff -u -p -u -p -r1.10 ofw_misc.h
--- dev/ofw/ofw_misc.h  21 Feb 2020 15:46:16 -0000      1.10
+++ dev/ofw/ofw_misc.h  13 Mar 2020 01:38:32 -0000
@@ -93,7 +93,7 @@ int   sfp_get_sffpage(uint32_t, struct if_
 struct pwm_state {
        uint32_t ps_period;
        uint32_t ps_pulse_width;
-       uint32_t ps_flags;
+       uint32_t ps_pwmflags;
        int ps_enabled;
 };
 

Reply via email to