Skip to content

Commit

Permalink
spi: spi-adi-v3: Remove redundant OOM message
Browse files Browse the repository at this point in the history
Let memory subsystem do the error logging.

Signed-off-by: Sachin Kamat <sachin.kamat@samsung.com>
Reviewed-by: Naveen Krishna Chatradhi <ch.naveen@samsung.com>
Signed-off-by: Mark Brown <broonie@linaro.org>
  • Loading branch information
Sachin Kamat authored and Mark Brown committed Jun 21, 2014
1 parent 7171511 commit 1380caa
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions drivers/spi/spi-adi-v3.c
Original file line number Diff line number Diff line change
Expand Up @@ -660,10 +660,9 @@ static int adi_spi_setup(struct spi_device *spi)
struct adi_spi3_chip *chip_info = spi->controller_data;

chip = kzalloc(sizeof(*chip), GFP_KERNEL);
if (!chip) {
dev_err(&spi->dev, "can not allocate chip data\n");
if (!chip)
return -ENOMEM;
}

if (chip_info) {
if (chip_info->control & ~ctl_reg) {
dev_err(&spi->dev,
Expand Down

0 comments on commit 1380caa

Please sign in to comment.