-
Notifications
You must be signed in to change notification settings - Fork 902
misc: Kconfig: ensure adi-axi-data-offload.c compiled as module #2931
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
@pamolloy easy-review, just a driver that supports as a module but wrong kconfig type. |
The drivers depends on the following methods: - axi_data_offload_ctrl_bypass - axi_data_offload_ctrl_oneshot - devm_axi_data_offload_get_optional If optional, a proper ops interface needs to be added. Signed-off-by: Jorge Marques <[email protected]>
As a bool, the driver cannot be compile as a module, even though the driver supports it. Signed-off-by: Jorge Marques <[email protected]>
d73a8e2
to
dc65546
Compare
Required for CF_AXI_DDS. Signed-off-by: Jorge Marques <[email protected]>
Required for CF_AXI_DDS. Signed-off-by: Jorge Marques <[email protected]>
Updated defconfigs.
|
tristate "Analog Devices CoreFPGA AXI DDS driver" | ||
depends on SPI | ||
depends on COMMON_CLK | ||
depends on ADI_AXI_DATA_OFFLOAD |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hmm I think this is only because we dropped the stubs for the methods you mention in the commit message. AFAIR, data offloading is an optional feature so I think depending on it is "too much".
We might need something better than #ifdef CONFIG_ADI_AXI_DATA_OFFLOAD
though
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yes, this is only required because we made this way, we added the methods directly in the axi dds driver and used a define in the include of the offload to make it optional, but this approach doesn't work with tristates.
it needs to be done through ops, where the offload pointer is acquired during runtime.
the focus of the pr is to allow the offload to be compiled as a module
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Well, I guess the original author indeed did not wanted it to be compiled as a module :).
but this approach doesn't work with tristates
Why not? Can't we use IS_REACHABLE() or something like that? And compromise that it won't be available if the DDS is builtin but OFFLOAD is a module?
Anyways, I'm not 100% happy that we now depend on an "optional" feature.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I agree we can use IS_REACHABLE in this driver to fallback . making it only compatible with built-in offload for now, or discard this pr and keep built-in only
.
CONFIG_BLK_DEV_LOOP=y | ||
CONFIG_BLK_DEV_RAM=y | ||
CONFIG_BLK_DEV_RAM_SIZE=16384 | ||
CONFIG_ADI_AXI_DATA_OFFLOAD=y |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Again, I feel this is required because we "made" it that way
PR Description
As a bool, the driver cannot be compile as a module, even though the driver supports it.
PR Type
PR Checklist