From patchwork Thu Oct 15 10:31:30 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Alexey Starikovskiy X-Patchwork-Id: 54005 Received: from vger.kernel.org (vger.kernel.org [209.132.176.167]) by demeter.kernel.org (8.14.2/8.14.2) with ESMTP id n9FAWS0X026793 for ; Thu, 15 Oct 2009 10:32:28 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756996AbZJOKcJ (ORCPT ); Thu, 15 Oct 2009 06:32:09 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1757117AbZJOKcJ (ORCPT ); Thu, 15 Oct 2009 06:32:09 -0400 Received: from charybdis-ext.suse.de ([195.135.221.2]:39491 "EHLO emea5-mh.id5.novell.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1756996AbZJOKcI (ORCPT ); Thu, 15 Oct 2009 06:32:08 -0400 Received: from [127.0.1.1] ([149.44.162.75]) by emea5-mh.id5.novell.com with ESMTP; Thu, 15 Oct 2009 12:31:31 +0200 From: Alexey Starikovskiy To: Len Brown Cc: Linux-acpi@vger.kernel.org Subject: [PATCH 2/4] POWER: Add support for cycle_count Date: Thu, 15 Oct 2009 14:31:30 +0400 Message-ID: <20091015103130.3853.89932.stgit@thinkpad> In-Reply-To: <20091015103122.3853.34760.stgit@thinkpad> References: <20091015103122.3853.34760.stgit@thinkpad> User-Agent: StGIT/0.14.2 MIME-Version: 1.0 Sender: linux-acpi-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-acpi@vger.kernel.org diff --git a/drivers/power/power_supply_sysfs.c b/drivers/power/power_supply_sysfs.c index 0814439..2a52345 100644 --- a/drivers/power/power_supply_sysfs.c +++ b/drivers/power/power_supply_sysfs.c @@ -96,6 +96,7 @@ static struct device_attribute power_supply_attrs[] = { POWER_SUPPLY_ATTR(present), POWER_SUPPLY_ATTR(online), POWER_SUPPLY_ATTR(technology), + POWER_SUPPLY_ATTR(cycle_count), POWER_SUPPLY_ATTR(voltage_max), POWER_SUPPLY_ATTR(voltage_min), POWER_SUPPLY_ATTR(voltage_max_design), diff --git a/include/linux/power_supply.h b/include/linux/power_supply.h index b5d096d..ebd2b8f 100644 --- a/include/linux/power_supply.h +++ b/include/linux/power_supply.h @@ -82,6 +82,7 @@ enum power_supply_property { POWER_SUPPLY_PROP_PRESENT, POWER_SUPPLY_PROP_ONLINE, POWER_SUPPLY_PROP_TECHNOLOGY, + POWER_SUPPLY_PROP_CYCLE_COUNT, POWER_SUPPLY_PROP_VOLTAGE_MAX, POWER_SUPPLY_PROP_VOLTAGE_MIN, POWER_SUPPLY_PROP_VOLTAGE_MAX_DESIGN,