Commit 70218113 authored by Li ZhiGang's avatar Li ZhiGang
Browse files

drivers/gmjstcm: fix a dev_err() call in spi tcm device probe

driver inclusion
category: bugfix
bugzilla: https://gitee.com/openeuler/kernel/issues/I4W1R1



-------------------------------------------------

fix a bug in spi tcm probe, that call dev_err(chip->dev, ..)
while chip is NULL.

Signed-off-by: default avatarLi ZhiGang <lizhigang@kylinos.cn>
parent 0c49500f
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -695,7 +695,7 @@ static int tcm_tis_spi_probe(struct spi_device *spi)
	/* regiter tcm hw */
	chip = tcm_register_hardware(&spi->dev, &tcm_tis);
	if (!chip) {
		dev_err(chip->dev, "tcm register hardware err\n");
		dev_err(&spi->dev, "tcm tis register hardware err\n");
		return -ENODEV;
	}