Unverified Commit 64b91750 authored by Arnd Bergmann's avatar Arnd Bergmann
Browse files

Merge tag 'optee-fix-for-v6.8' of...

Merge tag 'optee-fix-for-v6.8' of https://git.linaro.org/people/jens.wiklander/linux-tee into arm/fixes

Fix kernel panic in OP-TEE driver

* tag 'optee-fix-for-v6.8' of https://git.linaro.org/people/jens.wiklander/linux-tee:
  tee: optee: Fix kernel panic caused by incorrect error handling

Link: https://lore.kernel.org/r/20240304132727.GA3501807@rayden


Signed-off-by: default avatarArnd Bergmann <arnd@arndb.de>
parents 35edcf68 95915ba4
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -90,13 +90,14 @@ static int optee_register_device(const uuid_t *device_uuid, u32 func)
	if (rc) {
		pr_err("device registration failed, err: %d\n", rc);
		put_device(&optee_device->dev);
		return rc;
	}

	if (func == PTA_CMD_GET_DEVICES_SUPP)
		device_create_file(&optee_device->dev,
				   &dev_attr_need_supplicant);

	return rc;
	return 0;
}

static int __optee_enumerate_devices(u32 func)