Re: [PATCH 1/2] usb: dwc3: dwc3-qcom: Find USB connector and register role switch

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 01/07/2021 02:12, Jack Pham wrote:
I'm afraid I'm not too familiar with weak symbols. Would that still work
if dwc3 & dwc3-qcom are built as modules? Also is it supported with
Clang/LLVM?

__weak would work fine, until you tried to have two strong implementations.

Your linker should choke if dwc3-meson-g12a, dwc3-qcom and dwc3-drd linked together with both wrappers implementing normal linkage.

However, I do think its possible to use role switching to have dwc3-drd trigger dwc3-qcom.

The role switch code is resilient to deferral so we don't have to solve the problem we had with get_drvdata() in the notifier solution and it gets us out of the business of having dwc3-qcom relay the role-switch onto the core - or indeed care about what sort of connector is attached.

dwc3-qcom shouldn't have to know or care what sort of connector is attached to it, ecros, gpio-typec, tcpm or a raw type-c driver and like Bjorn said, it shouldn't be the case that the wrapper relays onto the core.

Anyway I'm playing with that prototype now



[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux