Received: by 2002:a25:ab43:0:0:0:0:0 with SMTP id u61csp6070577ybi; Tue, 4 Jun 2019 18:12:41 -0700 (PDT) X-Google-Smtp-Source: APXvYqz/AITHAXePO8xlPWgV8fh9zs0EBeYUhdxLKIRFr7Ae4hXVg6s8CA8ZF7hChIuQrUOxfwlx X-Received: by 2002:a63:5207:: with SMTP id g7mr712436pgb.356.1559697161347; Tue, 04 Jun 2019 18:12:41 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1559697161; cv=none; d=google.com; s=arc-20160816; b=LUF5VYXvxLkyLk1zrq0OqkrEu8jj4mhzeuuJr1EoCMAht7WAI9xGl39x+G8RAfQaWx dEzkafSN0WLLSmYxHiojt7EmR+IgZj1t44+lmz2fqmL80LJTvKSkWAEmQgavNbQUxQh+ uP6+Df+Coj0ov+N1bumY8tEGjBiKyKdRYB7ROwwysSridgVlQ6/5a+Rt4VS4/b68zHqT u9HbdrnMjyS+Tyoe9buRmnx5w/fB9bnLMt2+RUg+PbBN7k4zQSYrucBbfRdFTeTh+OMS Cjybjh0WSORDvulr4gN/1kyOQPKzxC2m142E3OCXdNeCDDUQ0wU2w89z+XU7EGwFI3QM lHtQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=VlHxMBMSfeEvLUylf2B3zOxUXUQHYZ4p3EWUpLSdpOU=; b=RC8wpITY+n/Vam6dgpnD4EHcSy+b6T9LNdS9zlS5sGL2BQ3ydFP3wiql+SeReWZezp d3lqxSqI4DjUtqCjV8YFdAlE6c7NjlVa5kYKZz4zUtG5UGTb9RIn18rsXuuZZZfEW6Tl ICFLjuZOWSvimeGU2eGps0GGNJsYI74LXSUCtpavhSBpBaDrKjFa1jfGCZt/SavrukkF w97Nh75ZyoGtBeSKNLqItyarR+qzWVjptLSxpwHGOLjMqAyFxEY62dwUQRIgDgnCFVqo E2/rANPBd+88eG7B8jlUOEuTtcDxYoBI+Zs43ffYeYWCJ5Ao4S+Hww1Jyt7VdaBatIha eDnA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=ST94zn4f; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id a7si25950385pgq.453.2019.06.04.18.12.07; Tue, 04 Jun 2019 18:12:41 -0700 (PDT) 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; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=ST94zn4f; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726664AbfFEBKQ (ORCPT + 99 others); Tue, 4 Jun 2019 21:10:16 -0400 Received: from mail-qt1-f196.google.com ([209.85.160.196]:35423 "EHLO mail-qt1-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726341AbfFEBKL (ORCPT ); Tue, 4 Jun 2019 21:10:11 -0400 Received: by mail-qt1-f196.google.com with SMTP id d23so16197272qto.2 for ; Tue, 04 Jun 2019 18:10:10 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=VlHxMBMSfeEvLUylf2B3zOxUXUQHYZ4p3EWUpLSdpOU=; b=ST94zn4fENWmSqKcu/gQgcIVE9zAdBriCQX2zGUJSwk0C7O+5PbAsWtzJCLX7xKdBL jrPAGArOVsdsrgTV7odUJ0kbosYG/UUaYTrGW3oMstkM9jLO524ZBYjq5Zy06sq4R8h4 yT+B+8iL3Glz8ktqMAM8Q2vq1ke5XeC3nwDEDHsAS3lNqszkxVeOabFm8RvJdwXbyvuI ImiDA9uy3cYHmVKtXJH1OKVeOgZNsoQVOp1qCN6meDeVxwH79K4qYnY5c0VXXlzEVdgR zuzE7TXlgCe/WvIbo2cHZ7DL4t242LHkioV666WPo7jY3DHs6wJ+FWjj7gxYyZNhsckz pqUw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=VlHxMBMSfeEvLUylf2B3zOxUXUQHYZ4p3EWUpLSdpOU=; b=dzEl/Hj5aSauAcSddQIQSkXm2uiJfcePHXRSFYmWFJdzi5j9UPCYN1PxFLCZENbEi8 nZmZhdcO7Jd0BIHR9gg/zQeACVWYi6yzqpbPLDAcXvGvqpyGwmB9pHHNIrGcQuBZl8Nm 7Qie98IziLKb0rs4aVrLk2ZQ/8ZZ2DodllLTXTiZAyTG6M57HU2cLJUK8XBLcFy8Blg8 3TCOt9ifAVV+Z5QPEX8iMQRFwXmVzSPWjfOQIvoQmB8Qlcvl2N/nudKhQHEL91HXx8ED t+lvLoa+WEDSyn17u2sKBtGbm3PS/3/tc7ieAk39Y4ZEQvoasa++XJnHydpBDaAFcWuQ J+sw== X-Gm-Message-State: APjAAAV71bKm7vQCOddEohEUNuO8bj2AZv6yaNOQvcwjH8gPsftXCggr uDJIt/Y+aC3jSS7XNvOVT3g= X-Received: by 2002:a0c:fde5:: with SMTP id m5mr10497044qvu.192.1559697010532; Tue, 04 Jun 2019 18:10:10 -0700 (PDT) Received: from arch-01.home (c-73-132-202-198.hsd1.md.comcast.net. [73.132.202.198]) by smtp.gmail.com with ESMTPSA id v41sm7169401qta.78.2019.06.04.18.10.09 (version=TLS1_3 cipher=AEAD-AES256-GCM-SHA384 bits=256/256); Tue, 04 Jun 2019 18:10:10 -0700 (PDT) From: Geordan Neukum To: Greg Kroah-Hartman Cc: Geordan Neukum , Mao Wenan , Jeremy Sowden , devel@driverdev.osuosl.org, linux-kernel@vger.kernel.org Subject: [PATCH 6/6] staging: kpc2000: kpc_spi: remove unnecessary cast in [read|write]_reg() Date: Wed, 5 Jun 2019 01:09:13 +0000 Message-Id: <243b8c78084e46606e78bed26a575181648099fd.1559696611.git.gneukum1@gmail.com> X-Mailer: git-send-email 2.21.0 In-Reply-To: References: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The kpc_spi driver unnecessarily casts from a (u64 __iomem *) to a (void *) when invoking readq and writeq which both take a (void __iomem *) arg. There is no need for this cast, and it actually harms us by discarding the sparse cookie, __iomem. Make the driver stop performing this casting operation. Signed-off-by: Geordan Neukum --- drivers/staging/kpc2000/kpc2000_spi.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/staging/kpc2000/kpc2000_spi.c b/drivers/staging/kpc2000/kpc2000_spi.c index 4f517afc6239..28132e9e260d 100644 --- a/drivers/staging/kpc2000/kpc2000_spi.c +++ b/drivers/staging/kpc2000/kpc2000_spi.c @@ -167,7 +167,7 @@ kp_spi_read_reg(struct kp_spi_controller_state *cs, int idx) if ((idx == KP_SPI_REG_CONFIG) && (cs->conf_cache >= 0)){ return cs->conf_cache; } - val = readq((void*)addr); + val = readq(addr); return val; } @@ -176,7 +176,7 @@ kp_spi_write_reg(struct kp_spi_controller_state *cs, int idx, u64 val) { u64 __iomem *addr = cs->base; addr += idx; - writeq(val, (void*)addr); + writeq(val, addr); if (idx == KP_SPI_REG_CONFIG) cs->conf_cache = val; } -- 2.21.0