Rafael Vanoni wrote:
> Li, Aubrey wrote:
>   
>> Rafael Vanoni wrote:
>>
>>     
>>> Just noticed that 6682365 changed the kstat module 'battery' to
>>> 'acpi_drv'. I'm pushing the update in a couple of minutes.
>>>
>>>       
>> Not perfect, does this mean power usage feature in the new
>> powertop will not work on the old revision of ON?
>>
>> I would suggest we implement a simple probe mechanism here.
>> Something like below:
>>
>> char *
>> battery_probe()
>> {
>>      ksp = kstat_lookup(kc, "battery", 0, "battery BIF0");
>>      if (ksp)
>>              return "battery";
>>      ksp = kstat_lookup(kc, "acpi_drv", 0, "battery BIF0");
>>      if (ksp)
>>              return "acpi_drv";
>>      return NULL;
>> }
>>
>> And battery_stat_snapshot() calls battery probe to do the rest job.
>> I can make a patch for it if you like.
>>
>> Thoughts?
>>     
>
> Good point.
>
> I can back out my patch if you prefer (I just don't know how to) and put 
> the code you suggested, but feel free to push your changes if you 
> prefer. I'm in Prague for the OpenSolaris conference, so not always online.
>
> I wish the change to the module name had been communicated somewhere in 
> OpenSolaris. Has anyone seen anything about it ?
>   

Seems like such a change should have been ARC'd. I assume that this 
change was made as part of PSARC/2008/021. But I don't see any mention 
of the kstat module name change.

> thanks
> Rafael
> _______________________________________________
> tesla-dev mailing list
> tesla-dev at opensolaris.org
> http://mail.opensolaris.org/mailman/listinfo/tesla-dev
>   


Reply via email to