On 13 Jul 2022, at 12:59, Van Haaren, Harry wrote:
>> -----Original Message----- >> From: Eelco Chaudron <[email protected]> >> Sent: Wednesday, July 13, 2022 9:55 AM >> To: Finn, Emma <[email protected]> >> Cc: Pai G, Sunil <[email protected]>; [email protected]; >> [email protected]; Van Haaren, Harry <[email protected]>; Amber, >> Kumar <[email protected]> >> Subject: Re: [ovs-dev] [v8 01/10] odp-execute: Add function pointers to >> odp-execute >> for different action implementations. > > <snip unrelated code> > >>>>> - switch ((enum ovs_action_attr) type) { >>>>> + /* If type is set in the active actions implementation, call the >>>>> + * function-pointer and continue to the next action. >>>>> + */ >>>>> + if (actions_active_impl->funcs[attr_type] && >>>>> + attr_type <= OVS_ACTION_ATTR_MAX) { >>>> >>>> I would rather prefer using the __OVS_ACTION_ATTR_MAX over the >>>> OVS_ACTION_ATTR_MAX with "<" semantics than "<=" >>>> Lets try to be consistent in terms of usage as well ๐ >>>> >>> >>> Sure, I will fix in next revision. >> >> Please undo this, we should use OVS_ACTION_ATTR_MAX here. The __ indicates >> this >> is a more private variable, so you should use this in the switch() cases >> where itโs a >> must. > > Ok, moving back to "<= OVS_ACTION_ATTR_MAX" here for this instance. > Note there is no functional difference. If required, wider > clean-ups/consistency > improvements can be done after patchset merge. ACK! _______________________________________________ dev mailing list [email protected] https://mail.openvswitch.org/mailman/listinfo/ovs-dev
