From patchwork Thu Mar 24 16:19:31 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bartosz Golaszewski X-Patchwork-Id: 64400 Delivered-To: patch@linaro.org Received: by 10.112.199.169 with SMTP id jl9csp756370lbc; Thu, 24 Mar 2016 09:20:17 -0700 (PDT) X-Received: by 10.66.65.201 with SMTP id z9mr3812513pas.143.1458836411171; Thu, 24 Mar 2016 09:20:11 -0700 (PDT) Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id g3si463783pap.29.2016.03.24.09.20.10; Thu, 24 Mar 2016 09:20:11 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-i2c-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@baylibre-com.20150623.gappssmtp.com; spf=pass (google.com: best guess record for domain of linux-i2c-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-i2c-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754687AbcCXQUI (ORCPT + 1 other); Thu, 24 Mar 2016 12:20:08 -0400 Received: from mail-wm0-f54.google.com ([74.125.82.54]:36880 "EHLO mail-wm0-f54.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754668AbcCXQTs (ORCPT ); Thu, 24 Mar 2016 12:19:48 -0400 Received: by mail-wm0-f54.google.com with SMTP id p65so73379640wmp.0 for ; Thu, 24 Mar 2016 09:19:47 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=ZPOO13g5rTCMK7zvmh0RoXtTOzwaH1vbSVf28bOTiaQ=; b=YjUdun6ZITtqWVAdP6KDitep61jo+Mxb9IY3nRlQQ4W7xw7Ws+TQGBVfRRdX+Ka+WF 88LrZ5dmkFQdJtYdJ5NVdDgWtRu/SHDJp2FBHCOtoqIW1djy4+tBfCd4Aw69XBEN26Dm EYGMgaqFVupp1FcGidkullJNPx+a/qmFt2HO62vQq922+dkVf08hEPbUtTuwhV21h6KZ OXmVyVOxDV5dvBqTpAp2iAci/94M/fdZtbMHsW4SKQ+oQMzbnpWFI3gdMwbgLW5l1i0b +ymkRkJ7rPbdD/wV2/mVlkWM+hAwpuPc/y7Ey7OFtuzy3wguwPZdaPpEqIwj2AdD0h07 AMOg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=ZPOO13g5rTCMK7zvmh0RoXtTOzwaH1vbSVf28bOTiaQ=; b=iY2XAbrRPQVVjLxzw5PknZjaQ+KffdyMCXWQDSrN4UWrjRrpW0FCZZNEKAB0TIVMpm /7g/eaR3H3OoK7/Vh08hnvwnGDSt/eAYKjIvvGl/uxgeO5tEViGFzSkejlIkWI3kLUlh c9+cBrAXgqZp5PNOYs3nYydw3bD2m5hFDRoJHpko14lf5QZNCWF3+LYzBMI3K/KmsUOn O20Z2LCKLTNLHVzl7eTF34VYDexvw9c9hNiPRQs10Bs3EYE0qJTNWAD+BXQiJ1nHHGAc zKjs5puNAALqS0dzv+2bkoMACExNDOoEPPmzLjXgJi8jpudnJBbY151mIhLvnj1BBVcc JmAg== X-Gm-Message-State: AD7BkJLIPRwlVxvfruoVdMNMVM4RagJjtopy2hjSXMU158pB2cTr8FPgH/TGjNyMElFAsKw0 X-Received: by 10.28.32.16 with SMTP id g16mr11467076wmg.13.1458836387236; Thu, 24 Mar 2016 09:19:47 -0700 (PDT) Received: from localhost.localdomain ([90.63.244.31]) by smtp.gmail.com with ESMTPSA id k124sm8370718wmb.11.2016.03.24.09.19.46 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Thu, 24 Mar 2016 09:19:46 -0700 (PDT) From: Bartosz Golaszewski To: Wolfram Sang , linux-i2c , LKML Cc: Andrew Lunn , Bartosz Golaszewski Subject: [PATCH v2 01/13] eeprom: at24: remove a reduntant if Date: Thu, 24 Mar 2016 17:19:31 +0100 Message-Id: <1458836383-6668-2-git-send-email-bgolaszewski@baylibre.com> X-Mailer: git-send-email 2.1.4 In-Reply-To: <1458836383-6668-1-git-send-email-bgolaszewski@baylibre.com> References: <1458836383-6668-1-git-send-email-bgolaszewski@baylibre.com> Sender: linux-i2c-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-i2c@vger.kernel.org It seems as if the second check for I2C_FUNC_I2C functionality had been introduced accidentally during a merge. Tt's reduntant, so remove it. Signed-off-by: Bartosz Golaszewski --- drivers/misc/eeprom/at24.c | 3 --- 1 file changed, 3 deletions(-) -- 2.7.4 -- To unsubscribe from this list: send the line "unsubscribe linux-i2c" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html diff --git a/drivers/misc/eeprom/at24.c b/drivers/misc/eeprom/at24.c index 089d694..001a9af 100644 --- a/drivers/misc/eeprom/at24.c +++ b/drivers/misc/eeprom/at24.c @@ -544,10 +544,7 @@ static int at24_probe(struct i2c_client *client, const struct i2c_device_id *id) } else { return -EPFNOSUPPORT; } - } - /* Use I2C operations unless we're stuck with SMBus extensions. */ - if (!i2c_check_functionality(client->adapter, I2C_FUNC_I2C)) { if (i2c_check_functionality(client->adapter, I2C_FUNC_SMBUS_WRITE_I2C_BLOCK)) { use_smbus_write = I2C_SMBUS_I2C_BLOCK_DATA;