[coreboot-gerrit] New patch to review for coreboot: soc/intel/common: Fix unsigned warnings

Lee Leahy (leroy.p.leahy@intel.com) gerrit at coreboot.org
Fri Mar 10 22:51:41 CET 2017


Lee Leahy (leroy.p.leahy at intel.com) just uploaded a new patch set to gerrit, which you can find at https://review.coreboot.org/18756

-gerrit

commit 0fbaaa7bf310bcdb1839e0960ad5e61f24d0612d
Author: Lee Leahy <leroy.p.leahy at intel.com>
Date:   Fri Mar 10 13:46:32 2017 -0800

    soc/intel/common: Fix unsigned warnings
    
    Fix the following warning detected by checkpatach.pl:
    
    WARNING: Prefer 'unsigned int' to bare use of 'unsigned'
    
    TEST=Build and run on Galileo Gen2
    
    Change-Id: Ic266c077eb115e0c7d934c15bcc4cc9b9e530a39
    Signed-off-by: Lee Leahy <Leroy.P.Leahy at intel.com>
---
 src/soc/intel/common/lpss_i2c.c | 10 +++++-----
 src/soc/intel/common/lpss_i2c.h |  6 +++---
 2 files changed, 8 insertions(+), 8 deletions(-)

diff --git a/src/soc/intel/common/lpss_i2c.c b/src/soc/intel/common/lpss_i2c.c
index c391ffe..8dfa3af 100644
--- a/src/soc/intel/common/lpss_i2c.c
+++ b/src/soc/intel/common/lpss_i2c.c
@@ -346,7 +346,7 @@ static int lpss_i2c_transfer_byte(struct lpss_i2c_regs *regs,
 }
 
 /* Global I2C bus handler, defined in include/i2c.h */
-int platform_i2c_transfer(unsigned bus, struct i2c_seg *segments, int count)
+int platform_i2c_transfer(unsigned int bus, struct i2c_seg *segments, int count)
 {
 	struct stopwatch sw;
 	struct lpss_i2c_regs *regs;
@@ -476,7 +476,7 @@ static void lpss_i2c_acpi_write_speed_config(
 	acpigen_pop_len();
 }
 
-static int lpss_i2c_set_speed_config(unsigned bus,
+static int lpss_i2c_set_speed_config(unsigned int bus,
 				const struct lpss_i2c_speed_config *config)
 {
 	struct lpss_i2c_regs *regs;
@@ -651,7 +651,7 @@ static int lpss_i2c_gen_speed_config(struct lpss_i2c_regs *regs,
 	return 0;
 }
 
-static int lpss_i2c_set_speed(unsigned bus, enum i2c_speed speed,
+static int lpss_i2c_set_speed(unsigned int bus, enum i2c_speed speed,
 				const struct lpss_i2c_bus_config *bcfg)
 {
 	struct lpss_i2c_regs *regs;
@@ -690,7 +690,7 @@ static int lpss_i2c_set_speed(unsigned bus, enum i2c_speed speed,
 	return 0;
 }
 
-void lpss_i2c_acpi_fill_ssdt(unsigned bus,
+void lpss_i2c_acpi_fill_ssdt(unsigned int bus,
 				const struct lpss_i2c_bus_config *bcfg)
 {
 	struct lpss_i2c_regs *regs;
@@ -721,7 +721,7 @@ void lpss_i2c_acpi_fill_ssdt(unsigned bus,
 	}
 }
 
-int lpss_i2c_init(unsigned bus, const struct lpss_i2c_bus_config *bcfg)
+int lpss_i2c_init(unsigned int bus, const struct lpss_i2c_bus_config *bcfg)
 {
 	struct lpss_i2c_regs *regs;
 	enum i2c_speed speed;
diff --git a/src/soc/intel/common/lpss_i2c.h b/src/soc/intel/common/lpss_i2c.h
index 19cf6ce..dbfabf3 100644
--- a/src/soc/intel/common/lpss_i2c.h
+++ b/src/soc/intel/common/lpss_i2c.h
@@ -79,13 +79,13 @@ struct lpss_i2c_bus_config {
  * This function *must* be implemented by the SOC and return the appropriate
  * base address for the I2C registers that correspond to the provided bus.
  */
-uintptr_t lpss_i2c_base_address(unsigned bus);
+uintptr_t lpss_i2c_base_address(unsigned int bus);
 
 /*
  * Generate I2C timing information into the SSDT for the OS driver to consume,
  * optionally applying override values provided by the caller.
  */
-void lpss_i2c_acpi_fill_ssdt(unsigned bus,
+void lpss_i2c_acpi_fill_ssdt(unsigned int bus,
 				const struct lpss_i2c_bus_config *bcfg);
 
 /*
@@ -97,6 +97,6 @@ void lpss_i2c_acpi_fill_ssdt(unsigned bus,
  * The SOC *must* define CONFIG_SOC_INTEL_COMMON_LPSS_I2C_CLOCK for the
  * bus speed calculation to be correct.
  */
-int lpss_i2c_init(unsigned bus, const struct lpss_i2c_bus_config *bcfg);
+int lpss_i2c_init(unsigned int bus, const struct lpss_i2c_bus_config *bcfg);
 
 #endif



More information about the coreboot-gerrit mailing list