[lkml]   [2006]   [Sep]   [19]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: [linux-pm] [PATCH] PowerOP, PowerOP Core, 1/2

| From: Pavel Machek<>
| > >>+struct powerop_driver {
| > >>+ char *name;
| > >>+ void *(*create_point) (const char *pwr_params, va_list args);
| > >>+ int (*set_point) (void *md_opt);
| > >>+ int (*get_point) (void *md_opt, const char *pwr_params, va_list
| > >>args);
| > >>+};
| > >
| > >We can certainly get better interface than va_list, right?
| >
| > Please elaborate.
| va_list does not provide adequate type checking. I do not think it
| suitable in driver<->core interface.

Well, in this particular case the typing probably has to be weak, one
way or another. The meaning of the parameters is arguably opaque at
the interface - the attributes may be meaningful to specific components
of the system, but are not defined in the standardized interface (which
would otherwise have to know about all possible kinds of power
attributes and be changed every time a new one is added).

So, if you'd rather have an array of char* or void* values, that would
probably also meet the need, but my guess is that the typing is
intentionally opaque.

| ...
| > >How is it going to work on 8cpu box? will
| > >you have states like cpu1_800MHz_cpu2_1600MHz_cpu3_800MHz_... ?
| >
| > i do not operate with term 'state' so I don't understand what it means here.
| Okay, state here means "operating point". How will operating points
| look on 8cpu box? That's 256 states if cpus only support "low" and
| "high". How do you name them?

I don't think you would name the compounded states. Each CPU would need
to have its own defined set of operating points (since the capabilities
of the CPUs can reasonably be different).

scott preece
motorola mobile devices, il67, 1800 s. oak st., champaign, il 61820
e-mail: fax: +1-217-384-8550
phone: +1-217-384-8589 cell: +1-217-433-6114 pager:

To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
More majordomo info at
Please read the FAQ at

 \ /
  Last update: 2006-09-19 21:49    [W:0.063 / U:12.544 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site