@@ -46,9 +46,6 @@ static int gb_pwm_activate_operation(struct pwm_chip *chip, u8 which)
46
46
struct gbphy_device * gbphy_dev ;
47
47
int ret ;
48
48
49
- if (which > pwmc -> pwm_max )
50
- return - EINVAL ;
51
-
52
49
request .which = which ;
53
50
54
51
gbphy_dev = to_gbphy_dev (pwmchip_parent (chip ));
@@ -71,9 +68,6 @@ static int gb_pwm_deactivate_operation(struct pwm_chip *chip, u8 which)
71
68
struct gbphy_device * gbphy_dev ;
72
69
int ret ;
73
70
74
- if (which > pwmc -> pwm_max )
75
- return - EINVAL ;
76
-
77
71
request .which = which ;
78
72
79
73
gbphy_dev = to_gbphy_dev (pwmchip_parent (chip ));
@@ -97,9 +91,6 @@ static int gb_pwm_config_operation(struct pwm_chip *chip,
97
91
struct gbphy_device * gbphy_dev ;
98
92
int ret ;
99
93
100
- if (which > pwmc -> pwm_max )
101
- return - EINVAL ;
102
-
103
94
request .which = which ;
104
95
request .duty = cpu_to_le32 (duty );
105
96
request .period = cpu_to_le32 (period );
@@ -125,9 +116,6 @@ static int gb_pwm_set_polarity_operation(struct pwm_chip *chip,
125
116
struct gbphy_device * gbphy_dev ;
126
117
int ret ;
127
118
128
- if (which > pwmc -> pwm_max )
129
- return - EINVAL ;
130
-
131
119
request .which = which ;
132
120
request .polarity = polarity ;
133
121
@@ -151,9 +139,6 @@ static int gb_pwm_enable_operation(struct pwm_chip *chip, u8 which)
151
139
struct gbphy_device * gbphy_dev ;
152
140
int ret ;
153
141
154
- if (which > pwmc -> pwm_max )
155
- return - EINVAL ;
156
-
157
142
request .which = which ;
158
143
159
144
gbphy_dev = to_gbphy_dev (pwmchip_parent (chip ));
@@ -176,9 +161,6 @@ static int gb_pwm_disable_operation(struct pwm_chip *chip, u8 which)
176
161
struct gbphy_device * gbphy_dev ;
177
162
int ret ;
178
163
179
- if (which > pwmc -> pwm_max )
180
- return - EINVAL ;
181
-
182
164
request .which = which ;
183
165
184
166
ret = gb_operation_sync (pwmc -> connection , GB_PWM_TYPE_DISABLE ,
0 commit comments