lkml.org 
[lkml]   [2006]   [Oct]   [23]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    Date
    From
    SubjectRe: Battery class driver.
    On Mon, Oct 23, 2006 at 07:20:33PM +0100, David Woodhouse wrote:

    > +BATTERY_DEVICE_ATTR("temp1",TEMP1,milli);
    > +BATTERY_DEVICE_ATTR("temp1_name",TEMP1_NAME,string);
    > +BATTERY_DEVICE_ATTR("temp2",TEMP2,milli);
    > +BATTERY_DEVICE_ATTR("temp2_name",TEMP2_NAME,string);
    > +BATTERY_DEVICE_ATTR("voltage",VOLTAGE,milli);
    > +BATTERY_DEVICE_ATTR("voltage_design",VOLTAGE_DESIGN,milli);
    > +BATTERY_DEVICE_ATTR("current",CURRENT,milli);
    > +BATTERY_DEVICE_ATTR("charge_rate",CHARGE_RATE,milli);
    > +BATTERY_DEVICE_ATTR("charge_max",CHARGE_MAX,milli);
    > +BATTERY_DEVICE_ATTR("charge_last",CHARGE_LAST,milli);
    > +BATTERY_DEVICE_ATTR("charge_low",CHARGE_LOW,milli);
    > +BATTERY_DEVICE_ATTR("charge_warn",CHARGE_WARN,milli);
    > +BATTERY_DEVICE_ATTR("charge_unit",CHARGE_UNITS,string);
    > +BATTERY_DEVICE_ATTR("charge_percent",CHARGE_PCT,int);
    > +BATTERY_DEVICE_ATTR("time_remaining",TIME_REMAINING,int);
    > +BATTERY_DEVICE_ATTR("manufacturer",MANUFACTURER,string);
    > +BATTERY_DEVICE_ATTR("technology",TECHNOLOGY,string);
    > +BATTERY_DEVICE_ATTR("model",MODEL,string);
    > +BATTERY_DEVICE_ATTR("serial",SERIAL,string);
    > +BATTERY_DEVICE_ATTR("type",TYPE,string);
    > +BATTERY_DEVICE_ATTR("oem_info",OEM_INFO,string);

    Without commenting on the rest:

    The tp_smapi code also provides average current and power, the charge
    cycle count, the date of first use, the date of manufacture and controls
    for altering the charge behaviour of the battery. Are these things that
    should go in the generic class?

    --
    Matthew Garrett | mjg59@srcf.ucam.org
    -
    To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
    the body of a message to majordomo@vger.kernel.org
    More majordomo info at http://vger.kernel.org/majordomo-info.html
    Please read the FAQ at http://www.tux.org/lkml/

    \
     
     \ /
      Last update: 2006-10-23 20:29    [W:0.023 / U:30.120 seconds]
    ©2003-2016 Jasper Spaans. hosted at Digital OceanAdvertise on this site