@@ -158,7 +158,7 @@ struct devfreq_stats {
158
158
* functions except for the context of callbacks defined in struct
159
159
* devfreq_governor, the governor should protect its access with the
160
160
* struct mutex lock in struct devfreq. A governor may use this mutex
161
- * to protect its own private data in void *data as well.
161
+ * to protect its own private data in `` void *data`` as well.
162
162
*/
163
163
struct devfreq {
164
164
struct list_head node ;
@@ -201,64 +201,62 @@ struct devfreq_freqs {
201
201
};
202
202
203
203
#if defined(CONFIG_PM_DEVFREQ )
204
- extern struct devfreq * devfreq_add_device (struct device * dev ,
205
- struct devfreq_dev_profile * profile ,
206
- const char * governor_name ,
207
- void * data );
208
- extern int devfreq_remove_device (struct devfreq * devfreq );
209
- extern struct devfreq * devm_devfreq_add_device (struct device * dev ,
210
- struct devfreq_dev_profile * profile ,
211
- const char * governor_name ,
212
- void * data );
213
- extern void devm_devfreq_remove_device (struct device * dev ,
214
- struct devfreq * devfreq );
204
+ struct devfreq * devfreq_add_device (struct device * dev ,
205
+ struct devfreq_dev_profile * profile ,
206
+ const char * governor_name ,
207
+ void * data );
208
+ int devfreq_remove_device (struct devfreq * devfreq );
209
+ struct devfreq * devm_devfreq_add_device (struct device * dev ,
210
+ struct devfreq_dev_profile * profile ,
211
+ const char * governor_name ,
212
+ void * data );
213
+ void devm_devfreq_remove_device (struct device * dev , struct devfreq * devfreq );
215
214
216
215
/* Supposed to be called by PM callbacks */
217
- extern int devfreq_suspend_device (struct devfreq * devfreq );
218
- extern int devfreq_resume_device (struct devfreq * devfreq );
216
+ int devfreq_suspend_device (struct devfreq * devfreq );
217
+ int devfreq_resume_device (struct devfreq * devfreq );
219
218
220
- extern void devfreq_suspend (void );
221
- extern void devfreq_resume (void );
219
+ void devfreq_suspend (void );
220
+ void devfreq_resume (void );
222
221
223
222
/**
224
223
* update_devfreq() - Reevaluate the device and configure frequency
225
224
* @devfreq: the devfreq device
226
225
*
227
226
* Note: devfreq->lock must be held
228
227
*/
229
- extern int update_devfreq (struct devfreq * devfreq );
228
+ int update_devfreq (struct devfreq * devfreq );
230
229
231
230
/* Helper functions for devfreq user device driver with OPP. */
232
- extern struct dev_pm_opp * devfreq_recommended_opp (struct device * dev ,
233
- unsigned long * freq , u32 flags );
234
- extern int devfreq_register_opp_notifier (struct device * dev ,
235
- struct devfreq * devfreq );
236
- extern int devfreq_unregister_opp_notifier (struct device * dev ,
237
- struct devfreq * devfreq );
238
- extern int devm_devfreq_register_opp_notifier (struct device * dev ,
239
- struct devfreq * devfreq );
240
- extern void devm_devfreq_unregister_opp_notifier (struct device * dev ,
241
- struct devfreq * devfreq );
242
- extern int devfreq_register_notifier (struct devfreq * devfreq ,
243
- struct notifier_block * nb ,
244
- unsigned int list );
245
- extern int devfreq_unregister_notifier (struct devfreq * devfreq ,
246
- struct notifier_block * nb ,
247
- unsigned int list );
248
- extern int devm_devfreq_register_notifier (struct device * dev ,
231
+ struct dev_pm_opp * devfreq_recommended_opp (struct device * dev ,
232
+ unsigned long * freq , u32 flags );
233
+ int devfreq_register_opp_notifier (struct device * dev ,
234
+ struct devfreq * devfreq );
235
+ int devfreq_unregister_opp_notifier (struct device * dev ,
236
+ struct devfreq * devfreq );
237
+ int devm_devfreq_register_opp_notifier (struct device * dev ,
238
+ struct devfreq * devfreq );
239
+ void devm_devfreq_unregister_opp_notifier (struct device * dev ,
240
+ struct devfreq * devfreq );
241
+ int devfreq_register_notifier (struct devfreq * devfreq ,
242
+ struct notifier_block * nb ,
243
+ unsigned int list );
244
+ int devfreq_unregister_notifier (struct devfreq * devfreq ,
245
+ struct notifier_block * nb ,
246
+ unsigned int list );
247
+ int devm_devfreq_register_notifier (struct device * dev ,
249
248
struct devfreq * devfreq ,
250
249
struct notifier_block * nb ,
251
250
unsigned int list );
252
- extern void devm_devfreq_unregister_notifier (struct device * dev ,
251
+ void devm_devfreq_unregister_notifier (struct device * dev ,
253
252
struct devfreq * devfreq ,
254
253
struct notifier_block * nb ,
255
254
unsigned int list );
256
- extern struct devfreq * devfreq_get_devfreq_by_phandle (struct device * dev ,
257
- int index );
255
+ struct devfreq * devfreq_get_devfreq_by_phandle (struct device * dev , int index );
258
256
259
257
#if IS_ENABLED (CONFIG_DEVFREQ_GOV_SIMPLE_ONDEMAND )
260
258
/**
261
- * struct devfreq_simple_ondemand_data - void *data fed to struct devfreq
259
+ * struct devfreq_simple_ondemand_data - `` void *data`` fed to struct devfreq
262
260
* and devfreq_add_device
263
261
* @upthreshold: If the load is over this value, the frequency jumps.
264
262
* Specify 0 to use the default. Valid value = 0 to 100.
@@ -278,7 +276,7 @@ struct devfreq_simple_ondemand_data {
278
276
279
277
#if IS_ENABLED (CONFIG_DEVFREQ_GOV_PASSIVE )
280
278
/**
281
- * struct devfreq_passive_data - void *data fed to struct devfreq
279
+ * struct devfreq_passive_data - `` void *data`` fed to struct devfreq
282
280
* and devfreq_add_device
283
281
* @parent: the devfreq instance of parent device.
284
282
* @get_target_freq: Optional callback, Returns desired operating frequency
@@ -311,9 +309,9 @@ struct devfreq_passive_data {
311
309
312
310
#else /* !CONFIG_PM_DEVFREQ */
313
311
static inline struct devfreq * devfreq_add_device (struct device * dev ,
314
- struct devfreq_dev_profile * profile ,
315
- const char * governor_name ,
316
- void * data )
312
+ struct devfreq_dev_profile * profile ,
313
+ const char * governor_name ,
314
+ void * data )
317
315
{
318
316
return ERR_PTR (- ENOSYS );
319
317
}
@@ -350,31 +348,31 @@ static inline void devfreq_suspend(void) {}
350
348
static inline void devfreq_resume (void ) {}
351
349
352
350
static inline struct dev_pm_opp * devfreq_recommended_opp (struct device * dev ,
353
- unsigned long * freq , u32 flags )
351
+ unsigned long * freq , u32 flags )
354
352
{
355
353
return ERR_PTR (- EINVAL );
356
354
}
357
355
358
356
static inline int devfreq_register_opp_notifier (struct device * dev ,
359
- struct devfreq * devfreq )
357
+ struct devfreq * devfreq )
360
358
{
361
359
return - EINVAL ;
362
360
}
363
361
364
362
static inline int devfreq_unregister_opp_notifier (struct device * dev ,
365
- struct devfreq * devfreq )
363
+ struct devfreq * devfreq )
366
364
{
367
365
return - EINVAL ;
368
366
}
369
367
370
368
static inline int devm_devfreq_register_opp_notifier (struct device * dev ,
371
- struct devfreq * devfreq )
369
+ struct devfreq * devfreq )
372
370
{
373
371
return - EINVAL ;
374
372
}
375
373
376
374
static inline void devm_devfreq_unregister_opp_notifier (struct device * dev ,
377
- struct devfreq * devfreq )
375
+ struct devfreq * devfreq )
378
376
{
379
377
}
380
378
@@ -393,22 +391,22 @@ static inline int devfreq_unregister_notifier(struct devfreq *devfreq,
393
391
}
394
392
395
393
static inline int devm_devfreq_register_notifier (struct device * dev ,
396
- struct devfreq * devfreq ,
397
- struct notifier_block * nb ,
398
- unsigned int list )
394
+ struct devfreq * devfreq ,
395
+ struct notifier_block * nb ,
396
+ unsigned int list )
399
397
{
400
398
return 0 ;
401
399
}
402
400
403
401
static inline void devm_devfreq_unregister_notifier (struct device * dev ,
404
- struct devfreq * devfreq ,
405
- struct notifier_block * nb ,
406
- unsigned int list )
402
+ struct devfreq * devfreq ,
403
+ struct notifier_block * nb ,
404
+ unsigned int list )
407
405
{
408
406
}
409
407
410
408
static inline struct devfreq * devfreq_get_devfreq_by_phandle (struct device * dev ,
411
- int index )
409
+ int index )
412
410
{
413
411
return ERR_PTR (- ENODEV );
414
412
}
0 commit comments