Skip to content

Commit

Permalink
net: qca_spi: Fix log level if probe fails
Browse files Browse the repository at this point in the history
[ Upstream commit 5097399 ]

In cases the probing fails the log level of the messages should
be an error.

Signed-off-by: Stefan Wahren <stefan.wahren@i2se.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Sasha Levin <alexander.levin@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
  • Loading branch information
Stefan Wahren authored and Greg Kroah-Hartman committed Aug 24, 2018
1 parent e77b152 commit 780e559
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions drivers/net/ethernet/qualcomm/qca_spi.c
Original file line number Diff line number Diff line change
Expand Up @@ -868,22 +868,22 @@ qca_spi_probe(struct spi_device *spi)

if ((qcaspi_clkspeed < QCASPI_CLK_SPEED_MIN) ||
(qcaspi_clkspeed > QCASPI_CLK_SPEED_MAX)) {
dev_info(&spi->dev, "Invalid clkspeed: %d\n",
qcaspi_clkspeed);
dev_err(&spi->dev, "Invalid clkspeed: %d\n",
qcaspi_clkspeed);
return -EINVAL;
}

if ((qcaspi_burst_len < QCASPI_BURST_LEN_MIN) ||
(qcaspi_burst_len > QCASPI_BURST_LEN_MAX)) {
dev_info(&spi->dev, "Invalid burst len: %d\n",
qcaspi_burst_len);
dev_err(&spi->dev, "Invalid burst len: %d\n",
qcaspi_burst_len);
return -EINVAL;
}

if ((qcaspi_pluggable < QCASPI_PLUGGABLE_MIN) ||
(qcaspi_pluggable > QCASPI_PLUGGABLE_MAX)) {
dev_info(&spi->dev, "Invalid pluggable: %d\n",
qcaspi_pluggable);
dev_err(&spi->dev, "Invalid pluggable: %d\n",
qcaspi_pluggable);
return -EINVAL;
}

Expand Down Expand Up @@ -944,8 +944,8 @@ qca_spi_probe(struct spi_device *spi)
}

if (register_netdev(qcaspi_devs)) {
dev_info(&spi->dev, "Unable to register net device %s\n",
qcaspi_devs->name);
dev_err(&spi->dev, "Unable to register net device %s\n",
qcaspi_devs->name);
free_netdev(qcaspi_devs);
return -EFAULT;
}
Expand Down

0 comments on commit 780e559

Please sign in to comment.