From patchwork Thu Sep 4 12:01:26 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Viresh Kumar X-Patchwork-Id: 36692 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-ob0-f200.google.com (mail-ob0-f200.google.com [209.85.214.200]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id C7AF2202E4 for ; Thu, 4 Sep 2014 12:02:51 +0000 (UTC) Received: by mail-ob0-f200.google.com with SMTP id va2sf51936432obc.7 for ; Thu, 04 Sep 2014 05:02:51 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:delivered-to:from:to:cc:subject :date:message-id:in-reply-to:references:in-reply-to:references :sender:precedence:list-id:x-original-sender :x-original-authentication-results:mailing-list:list-post:list-help :list-archive:list-unsubscribe; bh=buYj7E4hoOHqHhpnLB0sPQ9jeARi1UWMPj6fdRe0jzM=; b=CdD3xKi7c5V12m1it7yUxcRYYJSVfLx9SRLkRHbeWumS12FRlyfA3nXn/PmubIU0PY +G6tPyskaenDDNa7TeXEhz7lSoO+mIrcf8yaWi9PpIx9qX66ENOClc9LV4V/j+9M0Zw2 Do+XGVlSV0/KWnndfZ/ec1KgvmZD2fWoKrVDNEZhWmVa9RroUpm4GXrkQiMHjpOoFtiH F4oTLmjGNEgPk1ddYuQwoxVlELohsaqI+r01+dIsExsRT3EC00nMbNq5VuQoPNk+UHiI mhDRfYU+jFEIzZeKzLc5xjprAFCjcNJ9vqKJ6xCLTvTK0UlOUDsvdgu8moBjlv9porqM jBmg== X-Gm-Message-State: ALoCoQkrRZ8c+i5ByaF8u2tZEzuIUyo/ApHyzxyvGmk+WmDxwB3+90Cat8jsSHaeyGNWZl1himgw X-Received: by 10.42.62.73 with SMTP id x9mr2209308ich.15.1409832171274; Thu, 04 Sep 2014 05:02:51 -0700 (PDT) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.140.49.235 with SMTP id q98ls228958qga.91.gmail; Thu, 04 Sep 2014 05:02:51 -0700 (PDT) X-Received: by 10.52.164.199 with SMTP id ys7mr2657931vdb.42.1409832170990; Thu, 04 Sep 2014 05:02:50 -0700 (PDT) Received: from mail-vc0-f170.google.com (mail-vc0-f170.google.com [209.85.220.170]) by mx.google.com with ESMTPS id xj13si5457411vcb.60.2014.09.04.05.02.50 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Thu, 04 Sep 2014 05:02:50 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.220.170 as permitted sender) client-ip=209.85.220.170; Received: by mail-vc0-f170.google.com with SMTP id la4so10602159vcb.1 for ; Thu, 04 Sep 2014 05:02:50 -0700 (PDT) X-Received: by 10.52.119.229 with SMTP id kx5mr2596441vdb.40.1409832170401; Thu, 04 Sep 2014 05:02:50 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patch@linaro.org Received: by 10.221.45.67 with SMTP id uj3csp824290vcb; Thu, 4 Sep 2014 05:02:48 -0700 (PDT) X-Received: by 10.70.100.133 with SMTP id ey5mr7680479pdb.153.1409832167977; Thu, 04 Sep 2014 05:02:47 -0700 (PDT) Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id lp3si3076549pab.230.2014.09.04.05.02.42 for ; Thu, 04 Sep 2014 05:02:42 -0700 (PDT) Received-SPF: none (google.com: linux-pm-owner@vger.kernel.org does not designate permitted sender hosts) client-ip=209.132.180.67; Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753873AbaIDMCb (ORCPT + 15 others); Thu, 4 Sep 2014 08:02:31 -0400 Received: from mail-pa0-f48.google.com ([209.85.220.48]:52997 "EHLO mail-pa0-f48.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753774AbaIDMCa (ORCPT ); Thu, 4 Sep 2014 08:02:30 -0400 Received: by mail-pa0-f48.google.com with SMTP id ey11so19768132pad.7 for ; Thu, 04 Sep 2014 05:02:27 -0700 (PDT) X-Received: by 10.66.248.199 with SMTP id yo7mr7656401pac.107.1409832145877; Thu, 04 Sep 2014 05:02:25 -0700 (PDT) Received: from localhost ([122.167.123.172]) by mx.google.com with ESMTPSA id l4sm1529036pdp.66.2014.09.04.05.02.24 for (version=TLSv1.2 cipher=RC4-SHA bits=128/128); Thu, 04 Sep 2014 05:02:25 -0700 (PDT) From: Viresh Kumar To: sre@kernel.org, dbaryshkov@gmail.com, dwmw2@infradead.org, anton@enomsg.org Cc: linux-pm@vger.kernel.org, linaro-kernel@lists.linaro.org, Viresh Kumar Subject: [PATCH 05/15] power-supply: Drop unnecessary typecasts Date: Thu, 4 Sep 2014 17:31:26 +0530 Message-Id: <0ac40f9754bce63d88f6ee14948802ca9a7878d7.1409831636.git.viresh.kumar@linaro.org> X-Mailer: git-send-email 2.0.3.693.g996b0fd In-Reply-To: <2eacd908a8094887cc1796f75ae0513be8a3e36d.1409831636.git.viresh.kumar@linaro.org> References: <2eacd908a8094887cc1796f75ae0513be8a3e36d.1409831636.git.viresh.kumar@linaro.org> In-Reply-To: References: Sender: linux-pm-owner@vger.kernel.org Precedence: list List-ID: X-Mailing-List: linux-pm@vger.kernel.org X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: viresh.kumar@linaro.org X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.220.170 as permitted sender) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org X-Google-Group-Id: 836684582541 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , Typecast from 'void *' to any other pointer type falls under implicit typecasts category and so doesn't require explicit typecasts. Drop them. Signed-off-by: Viresh Kumar --- drivers/power/power_supply_core.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/power/power_supply_core.c b/drivers/power/power_supply_core.c index 414384a..71d00ec 100644 --- a/drivers/power/power_supply_core.c +++ b/drivers/power/power_supply_core.c @@ -58,7 +58,7 @@ static bool __power_supply_is_supplied_by(struct power_supply *supplier, static int __power_supply_changed_work(struct device *dev, void *data) { - struct power_supply *psy = (struct power_supply *)data; + struct power_supply *psy = data; struct power_supply *pst = dev_get_drvdata(dev); if (__power_supply_is_supplied_by(psy, pst)) { @@ -119,7 +119,7 @@ EXPORT_SYMBOL_GPL(power_supply_changed); static int __power_supply_populate_supplied_from(struct device *dev, void *data) { - struct power_supply *psy = (struct power_supply *)data; + struct power_supply *psy = data; struct power_supply *epsy = dev_get_drvdata(dev); struct device_node *np; int i = 0; @@ -158,7 +158,7 @@ static int power_supply_populate_supplied_from(struct power_supply *psy) static int __power_supply_find_supply_from_node(struct device *dev, void *data) { - struct device_node *np = (struct device_node *)data; + struct device_node *np = data; struct power_supply *epsy = dev_get_drvdata(dev); /* return error breaks out of class_for_each_device loop */ @@ -257,7 +257,7 @@ static inline int power_supply_check_supplies(struct power_supply *psy) static int __power_supply_am_i_supplied(struct device *dev, void *data) { union power_supply_propval ret = {0,}; - struct power_supply *psy = (struct power_supply *)data; + struct power_supply *psy = data; struct power_supply *epsy = dev_get_drvdata(dev); if (__power_supply_is_supplied_by(epsy, psy))