lkml.org 
[lkml]   [2022]   [Aug]   [4]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
Subjectsoundwire qcom slimbus dependency (was Re: [PATCH 0/2] arm64 defconfig: Get faddr2line working)
From
On 28/07/2022 13:03, Arnd Bergmann wrote:
> On Thu, Jul 28, 2022 at 1:57 PM Jonathan Marek <jonathan@marek.ca> wrote:
>> On 7/28/22 5:09 AM, Arnd Bergmann wrote:
>>> diff --git a/drivers/soundwire/qcom.c b/drivers/soundwire/qcom.c
>>> index 22b706350ead..f65c7737c2db 100644
>>> --- a/drivers/soundwire/qcom.c
>>> +++ b/drivers/soundwire/qcom.c
>>> @@ -1289,11 +1289,7 @@ static int qcom_swrm_probe(struct platform_device *pdev)
>>> data = of_device_get_match_data(dev);
>>> ctrl->rows_index = sdw_find_row_index(data->default_rows);
>>> ctrl->cols_index = sdw_find_col_index(data->default_cols);
>>> -#if IS_REACHABLE(CONFIG_SLIMBUS)
>>> - if (dev->parent->bus == &slimbus_bus) {
>>> -#else
>>> - if (false) {
>>> -#endif
>>> + if (IS_ENABLED(CONFIG_SLIMBUS) && dev->parent->bus == &slimbus_bus) {
>>> ctrl->reg_read = qcom_swrm_ahb_reg_read;
>>> ctrl->reg_write = qcom_swrm_ahb_reg_write;
>>> ctrl->regmap = dev_get_regmap(dev->parent, NULL);
>>>
>>
>> This relies on the compiler optimizing out the reference to slimbus_bus,
>> which doesn't exist in the CONFIG_SLIMBUS=n case (not tested, but I
>> think this means an O0 build will fail?).
>
> That is correct: We rely on this everywhere in the kernel, which is why
> it is impossible to build kernels with -O0.
>

Was there any patch sent to fix/improve this? I could not see any. Or
any plan to do so?

Thanks,
John

\
 
 \ /
  Last update: 2022-08-04 12:36    [W:1.570 / U:0.776 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site