All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jean Delvare <jdelvare@suse.de>
To: Linux I2C <linux-i2c@vger.kernel.org>
Cc: Mika Westerberg <mika.westerberg@linux.intel.com>,
	Christian Fetzer <fetzer.ch@gmail.com>,
	Wolfram Sang <wsa@the-dreams.de>
Subject: [PATCH 2/3] i2c-piix4: Always use the same type for port
Date: Fri, 29 Jan 2016 10:45:30 +0100	[thread overview]
Message-ID: <20160129104530.1ba78e8b@endymion.delvare> (raw)
In-Reply-To: <20160129104146.50f06562@endymion.delvare>

Sometimes u8 is used to store the port number, sometimes unsigned
short is used. Consistently stick to a single type, for consistency
and to avoid implicit casts.

Signed-off-by: Jean Delvare <jdelvare@suse.de>
Cc: Mika Westerberg <mika.westerberg@linux.intel.com>
Cc: Christian Fetzer <fetzer.ch@gmail.com>
Cc: Wolfram Sang <wsa@the-dreams.de>
---
 drivers/i2c/busses/i2c-piix4.c |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

--- linux-4.5-rc0.orig/drivers/i2c/busses/i2c-piix4.c	2016-01-29 07:54:35.135765313 +0100
+++ linux-4.5-rc0/drivers/i2c/busses/i2c-piix4.c	2016-01-29 07:57:13.706365999 +0100
@@ -158,7 +158,7 @@ struct i2c_piix4_adapdata {
 
 	/* SB800 */
 	bool sb800_main;
-	unsigned short port;
+	u8 port;
 };
 
 static int piix4_setup(struct pci_dev *PIIX4_dev,
@@ -649,7 +649,7 @@ static struct i2c_adapter *piix4_main_ad
 static struct i2c_adapter *piix4_aux_adapter;
 
 static int piix4_add_adapter(struct pci_dev *dev, unsigned short smba,
-			     bool sb800_main, unsigned short port,
+			     bool sb800_main, u8 port,
 			     const char *name, struct i2c_adapter **padap)
 {
 	struct i2c_adapter *adap;

-- 
Jean Delvare
SUSE L3 Support

  parent reply	other threads:[~2016-01-29  9:45 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-01-29  9:41 [PATCH 0/3] Improvements to the i2c-piix4 driver Jean Delvare
2016-01-29  9:44 ` [PATCH 1/3] i2c-piix4: Support alternative port selection register Jean Delvare
2016-01-29 10:59   ` Mika Westerberg
2016-01-29 12:04     ` Jean Delvare
2016-02-12 19:27   ` Wolfram Sang
2016-02-13 21:51     ` Jean Delvare
2016-02-14  8:39       ` fetzerch
2016-02-14  9:55         ` Jean Delvare
2016-02-15 17:30       ` Jean Delvare
2016-02-15 17:37         ` Wolfram Sang
2016-02-15 20:52           ` Jean Delvare
2016-01-29  9:45 ` Jean Delvare [this message]
2016-01-29 10:59   ` [PATCH 2/3] i2c-piix4: Always use the same type for port Mika Westerberg
2016-02-24 10:40   ` Wolfram Sang
2016-01-29  9:46 ` [PATCH 3/3] i2c-piix4: Pre-shift the port number Jean Delvare
2016-01-29 11:02   ` Mika Westerberg
2016-01-29 11:09     ` Jean Delvare
2016-02-24 10:42   ` Wolfram Sang

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20160129104530.1ba78e8b@endymion.delvare \
    --to=jdelvare@suse.de \
    --cc=fetzer.ch@gmail.com \
    --cc=linux-i2c@vger.kernel.org \
    --cc=mika.westerberg@linux.intel.com \
    --cc=wsa@the-dreams.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.