From 14862ee308bbcaae0ac9927b6cbccccb51386b6c Mon Sep 17 00:00:00 2001 From: Yehezkel Bernat Date: Mon, 22 Jan 2018 12:50:09 +0200 Subject: thunderbolt: Add 'boot' attribute for devices In various cases, Thunderbolt device can be connected by ICM on boot without waiting for approval from user. Most cases are related to OEM-specific BIOS configurations. This information is interesting for user-space as if the device isn't in SW ACL, it may create a friction in the user experience where the device is automatically authorized if it's connected on boot but requires an explicit user action if connected after OS is up. User-space can use this information to suggest adding the device to SW ACL for auto-authorization on later connections. Signed-off-by: Yehezkel Bernat Signed-off-by: Mika Westerberg Reviewed-by: Andy Shevchenko --- drivers/thunderbolt/tb.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'drivers/thunderbolt/tb.h') diff --git a/drivers/thunderbolt/tb.h b/drivers/thunderbolt/tb.h index 2cd6085a6e10..9c9cef875ca8 100644 --- a/drivers/thunderbolt/tb.h +++ b/drivers/thunderbolt/tb.h @@ -66,6 +66,7 @@ struct tb_switch_nvm { * @nvm: Pointer to the NVM if the switch has one (%NULL otherwise) * @no_nvm_upgrade: Prevent NVM upgrade of this switch * @safe_mode: The switch is in safe-mode + * @boot: Whether the switch was already authorized on boot or not * @authorized: Whether the switch is authorized by user or policy * @work: Work used to automatically authorize a switch * @security_level: Switch supported security level @@ -99,6 +100,7 @@ struct tb_switch { struct tb_switch_nvm *nvm; bool no_nvm_upgrade; bool safe_mode; + bool boot; unsigned int authorized; struct work_struct work; enum tb_security_level security_level; -- cgit v1.2.3