From patchwork Sun Mar 13 18:51:54 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Cosmin-Gabriel Samoila X-Patchwork-Id: 8573681 Return-Path: X-Original-To: patchwork-linux-spi@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 50A69C0553 for ; Sun, 13 Mar 2016 18:52:05 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 471CA20272 for ; Sun, 13 Mar 2016 18:52:04 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 4DDEC20263 for ; Sun, 13 Mar 2016 18:52:03 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751731AbcCMSwC (ORCPT ); Sun, 13 Mar 2016 14:52:02 -0400 Received: from mail-wm0-f52.google.com ([74.125.82.52]:33166 "EHLO mail-wm0-f52.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751563AbcCMSwA (ORCPT ); Sun, 13 Mar 2016 14:52:00 -0400 Received: by mail-wm0-f52.google.com with SMTP id l68so76625287wml.0; Sun, 13 Mar 2016 11:52:00 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id; bh=eMCe+9MAw20GPAaZQ6mK3zns60KU39RkYCmNr73SsKQ=; b=BMHjDVVdtqJ+8P7m6YK6YNFtJkWbDHEsiknCegWHb4+YnRIACEAy8GNQxgLYGvcSMS fpUqApv81ZAdSZ1dqnk83nsaYLBzdKf3mr0QbmaTRz7iHC37kt935CnmGD0VuBfnLG6q xbNrL+ZkuxrFzWYRDqqglsGLKFpYU0RDieR1rd8kKknLi9dA/nhODzOaEYcijfBMvjtK 9TKRcPBb4L8/dGj/X2IHjxTDmgRVLI7dC+IftRzzQ29bFTEKNBNmj1/WRNsMZtiaBqQ3 53W5syLQdAMlUegx1NgB3hUwbflxr5fXMXUmU87Aqk+xdzGKU9eWR6bRLp5lQPLb9Rl1 J8BA== 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; bh=eMCe+9MAw20GPAaZQ6mK3zns60KU39RkYCmNr73SsKQ=; b=YSbTAHtlGe2meg5DlQb6b3utbCCD2PN8ezVB3mt/85kCIYbtnTn0BGDPEgGGD2KOrY eUtFnqvDQUxg5zWVOjtzxIpYsaQSPckRz55xyjHZnGkR65lBCBNT/BReRIvX4GjaWW/L 03n98mWxWsJceqieKC+cfQ0EnZl2ffTcTd/fDNGQ4Gea5mZ5l2kCJqACJ5mswPVFwYIL VjrbWMzQp/baXsHuz7I6dCqh8QDGqrJeHL+HR2xC19aJoTLPBzMlVzCYzpulGXJG0zTC +2Yz7gf0OPNQfPhFBF4kWCcOmUkXQo6LP2NTbWzFLqEF+Dicr9IYgWmr3FgLRdjRlpHA HXIQ== X-Gm-Message-State: AD7BkJKpOhObmSFC3xPr3oKCHjlSYauYebRGjBhT959AE2KFWWW6Fy3IGPnrVVLTJQQ7uA== X-Received: by 10.194.143.44 with SMTP id sb12mr20076529wjb.58.1457895119274; Sun, 13 Mar 2016 11:51:59 -0700 (PDT) Received: from localhost.localdomain (p16.eregie.pub.ro. [141.85.0.116]) by smtp.googlemail.com with ESMTPSA id z127sm12673138wme.5.2016.03.13.11.51.57 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Sun, 13 Mar 2016 11:51:58 -0700 (PDT) From: Cosmin-Gabriel Samoila To: broonie@kernel.org Cc: linux-spi@vger.kernel.org, linux-kernel@vger.kernel.org, Cosmin-Gabriel Samoila Subject: [PATCH] spi: spi-adi-v3: fixed coding style issues. Date: Sun, 13 Mar 2016 20:51:54 +0200 Message-Id: <1457895114-4946-1-git-send-email-gabrielcsmo@gmail.com> X-Mailer: git-send-email 1.9.1 Sender: linux-spi-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-spi@vger.kernel.org X-Spam-Status: No, score=-6.8 required=5.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, T_DKIM_INVALID, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Fixed coding style issues detected using checkpatch.pl. Signed-off-by: Cosmin-Gabriel Samoila --- drivers/spi/spi-adi-v3.c | 18 ++++++++++++------ 1 file changed, 12 insertions(+), 6 deletions(-) diff --git a/drivers/spi/spi-adi-v3.c b/drivers/spi/spi-adi-v3.c index a16b25d..06121cc 100644 --- a/drivers/spi/spi-adi-v3.c +++ b/drivers/spi/spi-adi-v3.c @@ -43,9 +43,9 @@ enum adi_spi_state { struct adi_spi_master; struct adi_spi_transfer_ops { - void (*write) (struct adi_spi_master *); - void (*read) (struct adi_spi_master *); - void (*duplex) (struct adi_spi_master *); + void (*write)(struct adi_spi_master *); + void (*read)(struct adi_spi_master *); + void (*duplex)(struct adi_spi_master *); }; /* runtime info for spi master */ @@ -150,10 +150,12 @@ static int adi_spi_flush(struct adi_spi_master *drv_data) } /* Chip select operation functions for cs_change flag */ -static void adi_spi_cs_active(struct adi_spi_master *drv_data, struct adi_spi_device *chip) +static void adi_spi_cs_active(struct adi_spi_master *drv_data, + struct adi_spi_device *chip) { if (likely(chip->cs < MAX_CTRL_CS)) { u32 reg; + reg = ioread32(&drv_data->regs->ssel); reg &= ~chip->ssel; iowrite32(reg, &drv_data->regs->ssel); @@ -167,6 +169,7 @@ static void adi_spi_cs_deactive(struct adi_spi_master *drv_data, { if (likely(chip->cs < MAX_CTRL_CS)) { u32 reg; + reg = ioread32(&drv_data->regs->ssel); reg |= chip->ssel; iowrite32(reg, &drv_data->regs->ssel); @@ -185,6 +188,7 @@ static inline void adi_spi_cs_enable(struct adi_spi_master *drv_data, { if (chip->cs < MAX_CTRL_CS) { u32 reg; + reg = ioread32(&drv_data->regs->ssel); reg |= chip->ssel >> 8; iowrite32(reg, &drv_data->regs->ssel); @@ -196,6 +200,7 @@ static inline void adi_spi_cs_disable(struct adi_spi_master *drv_data, { if (chip->cs < MAX_CTRL_CS) { u32 reg; + reg = ioread32(&drv_data->regs->ssel); reg &= ~(chip->ssel >> 8); iowrite32(reg, &drv_data->regs->ssel); @@ -686,8 +691,9 @@ static int adi_spi_setup(struct spi_device *spi) } } else { chip->cs_gpio = chip->cs - MAX_CTRL_CS; - ret = gpio_request_one(chip->cs_gpio, GPIOF_OUT_INIT_HIGH, - dev_name(&spi->dev)); + ret = gpio_request_one(chip->cs_gpio, + GPIOF_OUT_INIT_HIGH, + dev_name(&spi->dev)); if (ret) { dev_err(&spi->dev, "gpio_request_one() error\n"); goto error;