The correct error value for not having enough storage is E2BIG, not
ENOMEM. The manpage and ichss(4) are correct.
This commit is contained in:
parent
2adbdedf6e
commit
feaf9a380e
@ -401,7 +401,7 @@ acpi_px_settings(device_t dev, struct cf_setting *sets, int *count, int *type)
|
||||
if (sets == NULL || count == NULL)
|
||||
return (EINVAL);
|
||||
if (*count < sc->px_count - sc->px_max_avail)
|
||||
return (ENOMEM);
|
||||
return (E2BIG);
|
||||
|
||||
/* Return a list of settings that are currently valid. */
|
||||
y = 0;
|
||||
|
@ -329,7 +329,7 @@ acpi_thr_settings(device_t dev, struct cf_setting *sets, int *count, int *type)
|
||||
if (sets == NULL || count == NULL)
|
||||
return (EINVAL);
|
||||
if (*count < CPU_MAX_SPEED)
|
||||
return (ENOMEM);
|
||||
return (E2BIG);
|
||||
|
||||
/* Return a list of valid settings for this driver. */
|
||||
memset(sets, CPUFREQ_VAL_UNKNOWN, sizeof(*sets) * CPU_MAX_SPEED);
|
||||
|
Loading…
Reference in New Issue
Block a user