aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorThierry Reding <thierry.reding@gmail.com>2015-07-27 05:57:28 -0400
committerThierry Reding <thierry.reding@gmail.com>2015-08-17 09:40:19 -0400
commit6bc7064a69fc5b1f774771ea9e2c50e497311766 (patch)
tree66d8e89eea0c0dc8f1e54b606ccf352082aad141
parent412820dd536fe2d01a35f0d68982ea225ec255b3 (diff)
pwm: Remove useless whitespace
Remove useless tabs used for padding in structure definitions as well as some blank lines. Signed-off-by: Thierry Reding <thierry.reding@gmail.com>
-rw-r--r--drivers/pwm/core.c1
-rw-r--r--include/linux/pwm.h71
2 files changed, 32 insertions, 40 deletions
diff --git a/drivers/pwm/core.c b/drivers/pwm/core.c
index f7c11d2dec37..257cbcdd3ec3 100644
--- a/drivers/pwm/core.c
+++ b/drivers/pwm/core.c
@@ -924,6 +924,5 @@ static int __init pwm_debugfs_init(void)
924 924
925 return 0; 925 return 0;
926} 926}
927
928subsys_initcall(pwm_debugfs_init); 927subsys_initcall(pwm_debugfs_init);
929#endif /* CONFIG_DEBUG_FS */ 928#endif /* CONFIG_DEBUG_FS */
diff --git a/include/linux/pwm.h b/include/linux/pwm.h
index 6f286df30021..7c4b6f35241d 100644
--- a/include/linux/pwm.h
+++ b/include/linux/pwm.h
@@ -80,16 +80,16 @@ enum {
80}; 80};
81 81
82struct pwm_device { 82struct pwm_device {
83 const char *label; 83 const char *label;
84 unsigned long flags; 84 unsigned long flags;
85 unsigned int hwpwm; 85 unsigned int hwpwm;
86 unsigned int pwm; 86 unsigned int pwm;
87 struct pwm_chip *chip; 87 struct pwm_chip *chip;
88 void *chip_data; 88 void *chip_data;
89 89
90 unsigned int period; /* in nanoseconds */ 90 unsigned int period;
91 unsigned int duty_cycle; /* in nanoseconds */ 91 unsigned int duty_cycle;
92 enum pwm_polarity polarity; 92 enum pwm_polarity polarity;
93}; 93};
94 94
95static inline bool pwm_is_enabled(const struct pwm_device *pwm) 95static inline bool pwm_is_enabled(const struct pwm_device *pwm)
@@ -141,25 +141,18 @@ static inline enum pwm_polarity pwm_get_polarity(const struct pwm_device *pwm)
141 * @owner: helps prevent removal of modules exporting active PWMs 141 * @owner: helps prevent removal of modules exporting active PWMs
142 */ 142 */
143struct pwm_ops { 143struct pwm_ops {
144 int (*request)(struct pwm_chip *chip, 144 int (*request)(struct pwm_chip *chip, struct pwm_device *pwm);
145 struct pwm_device *pwm); 145 void (*free)(struct pwm_chip *chip, struct pwm_device *pwm);
146 void (*free)(struct pwm_chip *chip, 146 int (*config)(struct pwm_chip *chip, struct pwm_device *pwm,
147 struct pwm_device *pwm); 147 int duty_ns, int period_ns);
148 int (*config)(struct pwm_chip *chip, 148 int (*set_polarity)(struct pwm_chip *chip, struct pwm_device *pwm,
149 struct pwm_device *pwm, 149 enum pwm_polarity polarity);
150 int duty_ns, int period_ns); 150 int (*enable)(struct pwm_chip *chip, struct pwm_device *pwm);
151 int (*set_polarity)(struct pwm_chip *chip, 151 void (*disable)(struct pwm_chip *chip, struct pwm_device *pwm);
152 struct pwm_device *pwm,
153 enum pwm_polarity polarity);
154 int (*enable)(struct pwm_chip *chip,
155 struct pwm_device *pwm);
156 void (*disable)(struct pwm_chip *chip,
157 struct pwm_device *pwm);
158#ifdef CONFIG_DEBUG_FS 152#ifdef CONFIG_DEBUG_FS
159 void (*dbg_show)(struct pwm_chip *chip, 153 void (*dbg_show)(struct pwm_chip *chip, struct seq_file *s);
160 struct seq_file *s);
161#endif 154#endif
162 struct module *owner; 155 struct module *owner;
163}; 156};
164 157
165/** 158/**
@@ -174,18 +167,18 @@ struct pwm_ops {
174 * operations may sleep 167 * operations may sleep
175 */ 168 */
176struct pwm_chip { 169struct pwm_chip {
177 struct device *dev; 170 struct device *dev;
178 struct list_head list; 171 struct list_head list;
179 const struct pwm_ops *ops; 172 const struct pwm_ops *ops;
180 int base; 173 int base;
181 unsigned int npwm; 174 unsigned int npwm;
182 175
183 struct pwm_device *pwms; 176 struct pwm_device *pwms;
184 177
185 struct pwm_device * (*of_xlate)(struct pwm_chip *pc, 178 struct pwm_device * (*of_xlate)(struct pwm_chip *pc,
186 const struct of_phandle_args *args); 179 const struct of_phandle_args *args);
187 unsigned int of_pwm_n_cells; 180 unsigned int of_pwm_n_cells;
188 bool can_sleep; 181 bool can_sleep;
189}; 182};
190 183
191#if IS_ENABLED(CONFIG_PWM) 184#if IS_ENABLED(CONFIG_PWM)