linux-stable/drivers/fsi
Jiasheng Jiang 2f921d62c2 fsi: core: Check error number after calling ida_simple_get
[ Upstream commit 35af9fb49b ]

If allocation fails, the ida_simple_get() will return error number.
So master->idx could be error number and be used in dev_set_name().
Therefore, it should be better to check it and return error if fails,
like the ida_simple_get() in __fsi_get_new_minor().

Fixes: 09aecfab93 ("drivers/fsi: Add fsi master definition")
Signed-off-by: Jiasheng Jiang <jiasheng@iscas.ac.cn>
Reviewed-by: Eddie James <eajames@linux.ibm.com>
Link: https://lore.kernel.org/r/20220111073411.614138-1-jiasheng@iscas.ac.cn
Signed-off-by: Joel Stanley <joel@jms.id.au>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2022-10-26 12:35:17 +02:00
..
cf-fsi-fw.h fsi: cf-fsi-fw: Use the correct style for SPDX License Identifier 2019-06-19 19:35:51 +02:00
fsi-core.c fsi: core: Check error number after calling ida_simple_get 2022-10-26 12:35:17 +02:00
fsi-master-aspeed.c fsi: Aspeed: Fix a potential double free 2022-04-08 14:23:44 +02:00
fsi-master-ast-cf.c fsi: master-ast-cf: Remove redundant error printing in fsi_master_acf_probe() 2021-06-04 15:02:55 +09:30
fsi-master-gpio.c fsi: Add missing MODULE_DEVICE_TABLE 2021-06-04 14:10:45 +09:30
fsi-master-hub.c fsi: master: Constify hub_master_ids 2020-09-10 12:22:50 +09:30
fsi-master.h fsi: master: Add boolean parameter to link_enable function 2020-09-10 12:22:47 +09:30
fsi-occ.c fsi: occ: Force sequence numbering per OCC 2022-07-07 17:53:32 +02:00
fsi-sbefifo.c fsi/sbefifo: Fix reset timeout 2021-06-04 16:06:57 +09:30
fsi-scom.c fsi: scom: Remove retries in indirect scoms 2022-04-08 14:23:44 +02:00
Kconfig treewide: replace '---help---' in Kconfig files with 'help' 2020-06-14 01:57:21 +09:00
Makefile fsi: Add ast2600 master driver 2019-11-08 11:28:20 +01:00