@@ -55,7 +55,7 @@ struct dummy_cpufreq_driver_s
55
55
struct cpufreq_driver driver ;
56
56
const struct cpufreq_frequency_table * table ;
57
57
size_t table_len ;
58
- int current ;
58
+ struct cpufreq_frequency_table current ;
59
59
};
60
60
61
61
/****************************************************************************
@@ -268,31 +268,32 @@ static int dummy_zdev_set_trips(FAR struct thermal_zone_device_s *zdev,
268
268
269
269
#ifdef CONFIG_THERMAL_DUMMY_CPUFREQ
270
270
static FAR const struct cpufreq_frequency_table * dummy_cpufreq_get_table (
271
- FAR struct cpufreq_policy * driver )
271
+ FAR struct cpufreq_policy * policy )
272
272
{
273
- FAR struct dummy_cpufreq_driver_s * * dummy =
274
- (FAR struct dummy_cpufreq_driver_s * * )driver ;
275
- return (* dummy )-> table ;
273
+ FAR struct dummy_cpufreq_driver_s * driver =
274
+ (FAR struct dummy_cpufreq_driver_s * )policy -> driver ;
275
+
276
+ return driver -> table ;
276
277
}
277
278
278
- static int dummy_cpufreq_target_index (FAR struct cpufreq_policy * driver ,
279
+ static int dummy_cpufreq_target_index (FAR struct cpufreq_policy * policy ,
279
280
unsigned int index )
280
281
{
281
- FAR struct dummy_cpufreq_driver_s * * dummy =
282
- (FAR struct dummy_cpufreq_driver_s * * ) driver ;
282
+ FAR struct dummy_cpufreq_driver_s * driver =
283
+ (FAR struct dummy_cpufreq_driver_s * ) policy -> driver ;
283
284
284
- DEBUGASSERT (index < ( * dummy ) -> table_len );
285
+ DEBUGASSERT (index < driver -> table_len );
285
286
286
- ( * dummy ) -> current = ( * dummy ) -> table [index ].frequency ;
287
+ driver -> current . frequency = driver -> table [index ].frequency ;
287
288
return 0 ;
288
289
}
289
290
290
- static int dummy_cpufreq_get_frequency (FAR struct cpufreq_policy * driver )
291
+ static int dummy_cpufreq_get_frequency (FAR struct cpufreq_policy * policy )
291
292
{
292
- FAR struct dummy_cpufreq_driver_s * * dummy =
293
- (FAR struct dummy_cpufreq_driver_s * * ) driver ;
293
+ FAR struct dummy_cpufreq_driver_s * driver =
294
+ (FAR struct dummy_cpufreq_driver_s * ) policy -> driver ;
294
295
295
- return ( * dummy ) -> current ;
296
+ return driver -> current . frequency ;
296
297
}
297
298
298
299
static int dummy_cpufreq_suspend (FAR struct cpufreq_policy * driver )
0 commit comments