Skip to content

Commit a94ef81

Browse files
Lina Iyerrafaeljw
authored andcommitted
PM: domains: replace -ENOTSUPP with -EOPNOTSUPP
While submitting a patch to add next_wakeup, checkpatch reported this - WARNING: ENOTSUPP is not a SUSV4 error code, prefer EOPNOTSUPP + return -ENOTSUPP; Address the above warning in other functions in pm_domain.h. Reviewed-by: Ulf Hansson <[email protected]> Signed-off-by: Lina Iyer <[email protected]> Signed-off-by: Rafael J. Wysocki <[email protected]>
1 parent 418baf2 commit a94ef81

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

include/linux/pm_domain.h

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -255,24 +255,24 @@ static inline int pm_genpd_init(struct generic_pm_domain *genpd,
255255
}
256256
static inline int pm_genpd_remove(struct generic_pm_domain *genpd)
257257
{
258-
return -ENOTSUPP;
258+
return -EOPNOTSUPP;
259259
}
260260

261261
static inline int dev_pm_genpd_set_performance_state(struct device *dev,
262262
unsigned int state)
263263
{
264-
return -ENOTSUPP;
264+
return -EOPNOTSUPP;
265265
}
266266

267267
static inline int dev_pm_genpd_add_notifier(struct device *dev,
268268
struct notifier_block *nb)
269269
{
270-
return -ENOTSUPP;
270+
return -EOPNOTSUPP;
271271
}
272272

273273
static inline int dev_pm_genpd_remove_notifier(struct device *dev)
274274
{
275-
return -ENOTSUPP;
275+
return -EOPNOTSUPP;
276276
}
277277

278278
#define simple_qos_governor (*(struct dev_power_governor *)(NULL))
@@ -325,13 +325,13 @@ struct device *genpd_dev_pm_attach_by_name(struct device *dev,
325325
static inline int of_genpd_add_provider_simple(struct device_node *np,
326326
struct generic_pm_domain *genpd)
327327
{
328-
return -ENOTSUPP;
328+
return -EOPNOTSUPP;
329329
}
330330

331331
static inline int of_genpd_add_provider_onecell(struct device_node *np,
332332
struct genpd_onecell_data *data)
333333
{
334-
return -ENOTSUPP;
334+
return -EOPNOTSUPP;
335335
}
336336

337337
static inline void of_genpd_del_provider(struct device_node *np) {}
@@ -387,7 +387,7 @@ static inline struct device *genpd_dev_pm_attach_by_name(struct device *dev,
387387
static inline
388388
struct generic_pm_domain *of_genpd_remove_last(struct device_node *np)
389389
{
390-
return ERR_PTR(-ENOTSUPP);
390+
return ERR_PTR(-EOPNOTSUPP);
391391
}
392392
#endif /* CONFIG_PM_GENERIC_DOMAINS_OF */
393393

0 commit comments

Comments
 (0)