diff options
author | Lee Jones <lee.jones@linaro.org> | 2014-08-13 08:52:27 -0400 |
---|---|---|
committer | Lee Jones <lee.jones@linaro.org> | 2014-09-26 03:15:30 -0400 |
commit | 41cc08e955187b96867fa0f625c55496961699ba (patch) | |
tree | 203ceb5b5fb73c10f761527f57e1706793e6d881 /drivers/mfd/htc-i2cpld.c | |
parent | fe4b7ea8e7c1f03601f6521c24898a688e565626 (diff) |
mfd: htc-i2cpld: Use '!variable' instead of 'variable == NULL'
This aids in consistency, as the rest of the checks in the file use this
notation.
Signed-off-by: Lee Jones <lee.jones@linaro.org>
Diffstat (limited to 'drivers/mfd/htc-i2cpld.c')
-rw-r--r-- | drivers/mfd/htc-i2cpld.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/mfd/htc-i2cpld.c b/drivers/mfd/htc-i2cpld.c index 8e3ea076568e..073e1801cdab 100644 --- a/drivers/mfd/htc-i2cpld.c +++ b/drivers/mfd/htc-i2cpld.c | |||
@@ -232,7 +232,7 @@ static void htcpld_chip_set(struct gpio_chip *chip, unsigned offset, int val) | |||
232 | unsigned long flags; | 232 | unsigned long flags; |
233 | 233 | ||
234 | client = chip_data->client; | 234 | client = chip_data->client; |
235 | if (client == NULL) | 235 | if (!client) |
236 | return; | 236 | return; |
237 | 237 | ||
238 | spin_lock_irqsave(&chip_data->lock, flags); | 238 | spin_lock_irqsave(&chip_data->lock, flags); |
@@ -373,7 +373,7 @@ static int htcpld_register_chip_i2c( | |||
373 | plat_chip_data = &pdata->chip[chip_index]; | 373 | plat_chip_data = &pdata->chip[chip_index]; |
374 | 374 | ||
375 | adapter = i2c_get_adapter(pdata->i2c_adapter_id); | 375 | adapter = i2c_get_adapter(pdata->i2c_adapter_id); |
376 | if (adapter == NULL) { | 376 | if (!adapter) { |
377 | /* Eek, no such I2C adapter! Bail out. */ | 377 | /* Eek, no such I2C adapter! Bail out. */ |
378 | dev_warn(dev, "Chip at i2c address 0x%x: Invalid i2c adapter %d\n", | 378 | dev_warn(dev, "Chip at i2c address 0x%x: Invalid i2c adapter %d\n", |
379 | plat_chip_data->addr, pdata->i2c_adapter_id); | 379 | plat_chip_data->addr, pdata->i2c_adapter_id); |