summaryrefslogtreecommitdiffstats
path: root/drivers/thunderbolt/switch.c
diff options
context:
space:
mode:
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>2023-04-19 11:42:44 +0200
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2023-04-19 11:42:44 +0200
commitced7c981f382fc34b941ee3b861d49bdd9180af4 (patch)
tree4992380b86c6f172aec9dea46a3bbfbe2f475e16 /drivers/thunderbolt/switch.c
parentMerge 6.3-rc6 into usb-next (diff)
parentthunderbolt: Introduce usb4_port_sb_opcode_err_to_errno() helper (diff)
downloadlinux-ced7c981f382fc34b941ee3b861d49bdd9180af4.tar.xz
linux-ced7c981f382fc34b941ee3b861d49bdd9180af4.zip
Merge tag 'thunderbolt-for-v6.4-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/westeri/thunderbolt into usb-next
Mika writes: thunderbolt: Changes for v6.4 merge window This includes following Thunderbolt/USB4 changes for the v6.4 merge window: - Refactoring of DROM read code paths - Convert to use SI units from units.h - A couple of cleanups All these have been in linux-next with no reported issues. * tag 'thunderbolt-for-v6.4-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/westeri/thunderbolt: thunderbolt: Introduce usb4_port_sb_opcode_err_to_errno() helper thunderbolt: Make use of SI units from units.h thunderbolt: Get rid of redundant 'else' thunderbolt: Refactor DROM reading thunderbolt: use `tb_eeprom_get_drom_offset` to discover DROM offset
Diffstat (limited to 'drivers/thunderbolt/switch.c')
-rw-r--r--drivers/thunderbolt/switch.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/thunderbolt/switch.c b/drivers/thunderbolt/switch.c
index da373ac38285..51e86b5171c7 100644
--- a/drivers/thunderbolt/switch.c
+++ b/drivers/thunderbolt/switch.c
@@ -271,9 +271,9 @@ static int nvm_authenticate(struct tb_switch *sw, bool auth_only)
}
sw->nvm->authenticating = true;
return usb4_switch_nvm_authenticate(sw);
- } else if (auth_only) {
- return -EOPNOTSUPP;
}
+ if (auth_only)
+ return -EOPNOTSUPP;
sw->nvm->authenticating = true;
if (!tb_route(sw)) {