Received: by 2002:a25:ab43:0:0:0:0:0 with SMTP id u61csp2120478ybi; Sun, 9 Jun 2019 04:18:38 -0700 (PDT) X-Google-Smtp-Source: APXvYqwtYURfHGUsEVMGD7zscGEbydhSeDCBqEH7WlS2jUX/WoWL/KY2BoASzkpGAGBm8bEjVQen X-Received: by 2002:a63:5b5c:: with SMTP id l28mr10941164pgm.158.1560079118288; Sun, 09 Jun 2019 04:18:38 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1560079118; cv=none; d=google.com; s=arc-20160816; b=Zi+m8aUP0lXXYbJ3MtELtSNaxAZye/jqrSQvbuJQANNsdhZhsW2sMWBOPX3WB01uSV BAkbqx7IaLjP9DrJQlsSTWYha6G/GYxMByAu5rqyeFrQTQYsNDsIZ3yjYqBjFx7xrJaR OtM8zsqWwR17Q+uZFOJSsZ959zbN8n6cVjLU5HgKWHWu3ea0C/ZM9YPi6bk1rd6e7Ua0 L8ed3jQOyoj+1Zxcu21xMRescmceK7La3TJTXaQIbJw/AmVmbme9t7h9EeA2APP4ALmq UN8GJNvM397uPWsV+nxqTp/YDBCsNFanSbpunLehTrRqcHUNE7eyfpYFvOf0jfLL1Jjl eLlw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=s/fUteCvaVpiibl3vzNcflQGTndLn/xpMi2KZEAPHLI=; b=r+7Vv1GNNLHQBSsZtJiBQXUghGtx4jyXA+p2xRodi4fekZKiHdqLRBj60QRKKfWZrJ Sy9Zvaqi9BOSEmFVhpaDUWz7QgCETQiwrDXeOMbkQcbU4YmczkgNFrdYlTb1HJRGOjhf 6aoUOGyLxJmw1jK2r6PwOdqROSwy0iDDV0SOT7ljnTW8/PRifNNNyVfwy2Pv1xqoZMTe R7dSyX9dIPhXLdU75bEzdOwnDBmbEpBFgJHLW59tR+wbQ8x8V+vkPb8t9nJgfyQ8HBuk ak8kHduu6+OoZ88N4D5yx1VrqLoWhueGDqtyBSE4ItNf5NaCB5eu8A/CwW56697lQvNI H8yg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=Zmr0Iy4g; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id y17si6682643plp.59.2019.06.09.04.18.22; Sun, 09 Jun 2019 04:18:38 -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=@kernel.org header.s=default header.b=Zmr0Iy4g; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728361AbfFILHO (ORCPT + 99 others); Sun, 9 Jun 2019 07:07:14 -0400 Received: from mail.kernel.org ([198.145.29.99]:43602 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728095AbfFILHO (ORCPT ); Sun, 9 Jun 2019 07:07:14 -0400 Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 67FD92083D; Sun, 9 Jun 2019 11:07:13 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1560078433; bh=BoVXawOIy+yoXWu7Sh5tusd2+DJEUCMI4+wVXPSiYoU=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=Zmr0Iy4glMkx23TrS5wmlVRG9KaBxeJ2RSz3E+odSlQ2p1xlxRSBszUfvTM8Yp/ak QELHA1+QuS3NnMyptffrQ2fNyJGdbB2RSdJMiRZUrp3RWfyuXmASwXHgWL7CUVXz79 jcI+q/tAdNlReep8A/Lste96R2UEOWD9EUVg7a38= Date: Sun, 9 Jun 2019 13:07:11 +0200 From: Greg KH To: Geordan Neukum Cc: Hao Xu , devel@driverdev.osuosl.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH 1/2] staging: kpc2000: kpc2000_i2c: void* -> void * Message-ID: <20190609110711.GA5666@kroah.com> References: <1559978867-3693-1-git-send-email-haoxu.linuxkernel@gmail.com> <20190608134505.GA963@arch-01.home> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20190608134505.GA963@arch-01.home> User-Agent: Mutt/1.12.0 (2019-05-25) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sat, Jun 08, 2019 at 01:45:05PM +0000, Geordan Neukum wrote: > On Sat, Jun 08, 2019 at 03:27:46PM +0800, Hao Xu wrote: > > modify void* to void * for #define inb_p(a) readq((void*)a) > > and #define outb_p(d,a) writeq(d,(void*)a) > > > > Signed-off-by: Hao Xu > > --- > > drivers/staging/kpc2000/kpc2000_i2c.c | 4 ++-- > > 1 file changed, 2 insertions(+), 2 deletions(-) > > > > diff --git a/drivers/staging/kpc2000/kpc2000_i2c.c b/drivers/staging/kpc2000/kpc2000_i2c.c > > index a434dd0..de3a0c8 100644 > > --- a/drivers/staging/kpc2000/kpc2000_i2c.c > > +++ b/drivers/staging/kpc2000/kpc2000_i2c.c > > @@ -124,9 +124,9 @@ struct i2c_device { > > > > // FIXME! > > #undef inb_p > > -#define inb_p(a) readq((void*)a) > > +#define inb_p(a) readq((void *)a) > > #undef outb_p > > -#define outb_p(d,a) writeq(d,(void*)a) > > +#define outb_p(d,a) writeq(d,(void *)a) > > Alternatively to fixing up the style here, did you consider just > removing these two macros altogether and calling [read|write]q > directly throughout the kpc_i2c driver (per the '//FIXME' comment)? > > Unless, I'm misunderstanding something, these macros are shadowing the > functions [in|out]b_p, which already exist in io.h. [in|out]b_p are for > 8-bit i/o transactions and [read|write]q are for 64-bit transactions, so > shadowing the original [in|out]b_p with something that actually does > 64-bit transactions is probably potentially misleading here. Yes, these should be fixed up "properly". But I'll take the coding style cleanups for now. thanks, greg k-h