Re: [PATCH] PM / OPP: 'UNKNOWN' status of opp-table->shared

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

 



On Thu, Jun 16, 2016 at 2:48 PM, Viresh Kumar <viresh.kumar@xxxxxxxxxx> wrote:
> On 16-06-16, 14:25, Rafael J. Wysocki wrote:
>> On Thu, Jun 16, 2016 at 8:33 AM, Viresh Kumar <viresh.kumar@xxxxxxxxxx> wrote:
>> > +                       if (opp_table->shared_opp == OPP_TABLE_IS_SHARED)
>> > +                               return opp_table;
>> > +
>> > +                       return NULL;
>>
>> That still can be
>>
>> return opp_table->shared_opp == OPP_TABLE_IS_SHARED ? opp_table : NULL;
>>
>> >                 }
>> >         }
>> >
>
>> > +       if (of_property_read_bool(opp_np, "opp-shared"))
>> > +               opp_table->shared_opp = OPP_TABLE_IS_SHARED;
>> > +       else
>> > +               opp_table->shared_opp = OPP_TABLE_IS_NOT_SHARED;
>>
>> And here
>>
>> opp_table->shared_opp = of_property_read_bool(opp_np, "opp-shared") ?
>>                                             OPP_TABLE_IS_SHARED :
>> OPP_TABLE_IS_NOT_SHARED;
>
> Conditional statement for both these cases is getting very long and
> if/else looks much more readable. And so I would like to stick with
> that, if you allow.

Fair enough.
--
To unsubscribe from this list: send the line "unsubscribe linux-tegra" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [ARM Kernel]     [Linux ARM]     [Linux ARM MSM]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux