thunderbolt: Move vendor specific NVM handling into nvm.c
authorSzuying Chen <Chloe_Chen@asmedia.com.tw>
Fri, 2 Sep 2022 09:40:08 +0000 (17:40 +0800)
committerMika Westerberg <mika.westerberg@linux.intel.com>
Wed, 7 Sep 2022 06:06:51 +0000 (09:06 +0300)
commitaef9c693e7e550954fc526b919342cc7d8047ed1
treed3ab3a31009aca6639df143f0e5ecb6b5a62e765
parent8b02b2da77c89d9b9031f522e50af9eb2270585a
thunderbolt: Move vendor specific NVM handling into nvm.c

As there will be more USB4 devices that support NVM firmware upgrade from
various vendors, it makes sense to split out the Intel specific NVM
image handling from the generic code. This moves the Intel specific NVM
handling into a new structure that will be matched by the device type
and the vendor ID. Do this for both routers and retimers.

This makes it easier to extend the NVM support to cover new vendors and
NVM image formats in the future.

Signed-off-by: Szuying Chen <Chloe_Chen@asmedia.com.tw>
Signed-off-by: Mika Westerberg <mika.westerberg@linux.intel.com>
drivers/thunderbolt/nvm.c
drivers/thunderbolt/retimer.c
drivers/thunderbolt/switch.c
drivers/thunderbolt/tb.h