From patchwork Thu Feb 20 08:53:16 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sachin Kamat X-Patchwork-Id: 24992 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-qa0-f71.google.com (mail-qa0-f71.google.com [209.85.216.71]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id E85852066E for ; Thu, 20 Feb 2014 09:02:40 +0000 (UTC) Received: by mail-qa0-f71.google.com with SMTP id j5sf2935649qaq.6 for ; Thu, 20 Feb 2014 01:02:40 -0800 (PST) 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:sender:precedence:list-id :x-original-sender:x-original-authentication-results:mailing-list :list-post:list-help:list-archive:list-unsubscribe; bh=DfpqBYpyTq3SUOLIOq5gZ9gVvY2i28WycszyliYdv0g=; b=gfJsiVPJmuKgev0G2ZGL0gt4pnHvxov/4K+g91PWBslbzpTJ1R97m3Qgl6WP468jX5 MvlbewrcqOSWCEhe7MlV2k8TITzKxaTVnBFWg9T8doVUpZTdGPowVcpVOGp3fx6nxGMV Jsiy6XxFO1SNOGRR4BQkXC1TYvggP6jQZ5Wgq8tt4o41KsEVkynQYFW0Y5CgTHk/bdw0 aQ+aarFK5YWClgcexngun+Sr9/oIQkfE0zB9+YoKeTYxvBX5eqU2t8mIftv2Ty09A32g LqwMhdakON3VzDcr9NHyBLW4k9F6wdg7N34aPpnbAN5DkwV6rOheNboGTTfJNUeDl9O9 5T2w== X-Gm-Message-State: ALoCoQk2gFaPGAJD7SMYsfLUEQrrkjCPwjRbmqPWYzHtRjlvUmTZO3CNap2+p0+falHo/799Z39x X-Received: by 10.236.209.134 with SMTP id s6mr221811yho.40.1392886960515; Thu, 20 Feb 2014 01:02:40 -0800 (PST) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.140.48.161 with SMTP id o30ls467762qga.94.gmail; Thu, 20 Feb 2014 01:02:40 -0800 (PST) X-Received: by 10.52.185.196 with SMTP id fe4mr276286vdc.27.1392886960433; Thu, 20 Feb 2014 01:02:40 -0800 (PST) Received: from mail-vc0-f175.google.com (mail-vc0-f175.google.com [209.85.220.175]) by mx.google.com with ESMTPS id n17si1194920vcq.135.2014.02.20.01.02.40 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Thu, 20 Feb 2014 01:02:40 -0800 (PST) Received-SPF: neutral (google.com: 209.85.220.175 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) client-ip=209.85.220.175; Received: by mail-vc0-f175.google.com with SMTP id ij19so1558053vcb.6 for ; Thu, 20 Feb 2014 01:02:40 -0800 (PST) X-Received: by 10.52.61.168 with SMTP id q8mr314844vdr.40.1392886960362; Thu, 20 Feb 2014 01:02:40 -0800 (PST) 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.220.174.196 with SMTP id u4csp40980vcz; Thu, 20 Feb 2014 01:02:39 -0800 (PST) X-Received: by 10.69.19.139 with SMTP id gu11mr604886pbd.149.1392886959551; Thu, 20 Feb 2014 01:02:39 -0800 (PST) Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id gp2si2646539pac.331.2014.02.20.01.02.38; Thu, 20 Feb 2014 01:02:38 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754970AbaBTI7l (ORCPT + 26 others); Thu, 20 Feb 2014 03:59:41 -0500 Received: from mail-pb0-f44.google.com ([209.85.160.44]:58066 "EHLO mail-pb0-f44.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754927AbaBTI7h (ORCPT ); Thu, 20 Feb 2014 03:59:37 -0500 Received: by mail-pb0-f44.google.com with SMTP id rq2so1623259pbb.17 for ; Thu, 20 Feb 2014 00:59:37 -0800 (PST) X-Received: by 10.66.129.133 with SMTP id nw5mr747323pab.98.1392886777205; Thu, 20 Feb 2014 00:59:37 -0800 (PST) Received: from linaro.sisodomain.com ([115.113.119.130]) by mx.google.com with ESMTPSA id eo11sm21100112pac.0.2014.02.20.00.59.34 for (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Thu, 20 Feb 2014 00:59:36 -0800 (PST) From: Sachin Kamat To: linux-kernel@vger.kernel.org Cc: broonie@kernel.org, lgirdwood@gmail.com, sachin.kamat@linaro.org Subject: [PATCH 16/23] regulator: tps6524x: Remove redundant error message Date: Thu, 20 Feb 2014 14:23:16 +0530 Message-Id: <1392886403-10640-16-git-send-email-sachin.kamat@linaro.org> X-Mailer: git-send-email 1.7.9.5 In-Reply-To: <1392886403-10640-1-git-send-email-sachin.kamat@linaro.org> References: <1392886403-10640-1-git-send-email-sachin.kamat@linaro.org> Sender: linux-kernel-owner@vger.kernel.org Precedence: list List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: sachin.kamat@linaro.org X-Original-Authentication-Results: mx.google.com; spf=neutral (google.com: 209.85.220.175 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) 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: , kzalloc prints its own OOM message upon failure. Signed-off-by: Sachin Kamat --- drivers/regulator/tps6524x-regulator.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/drivers/regulator/tps6524x-regulator.c b/drivers/regulator/tps6524x-regulator.c index 9f6bfda711b7..5b494db9f95c 100644 --- a/drivers/regulator/tps6524x-regulator.c +++ b/drivers/regulator/tps6524x-regulator.c @@ -593,10 +593,9 @@ static int pmic_probe(struct spi_device *spi) } hw = devm_kzalloc(&spi->dev, sizeof(struct tps6524x), GFP_KERNEL); - if (!hw) { - dev_err(dev, "cannot allocate regulator private data\n"); + if (!hw) return -ENOMEM; - } + spi_set_drvdata(spi, hw); memset(hw, 0, sizeof(struct tps6524x));