diff mbox series

[ovs-dev,branch-22.03] northd: Do not report WARN for empty requested-chassis

Message ID 20220916092155.888975-1-amusil@redhat.com
State Accepted
Headers show
Series [ovs-dev,branch-22.03] northd: Do not report WARN for empty requested-chassis | expand

Checks

Context Check Description
ovsrobot/apply-robot success apply and check: success
ovsrobot/github-robot-_Build_and_Test success github build: passed
ovsrobot/github-robot-_ovn-kubernetes fail github build: failed

Commit Message

Ales Musil Sept. 16, 2022, 9:21 a.m. UTC
Reported-at: https://bugzilla.redhat.com/2126400
Signed-off-by: Ales Musil <amusil@redhat.com>
---
This patch should be applied only to 22.03 and below,
because it was fixed as side effect of RFE on 22.06, 22.09
and main [0].

[0] https://github.com/ovn-org/ovn/commit/eaf9832be248daca6d96202d504cc789d6dfec6d
---
 northd/northd.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Mark Michelson Sept. 20, 2022, 8:08 p.m. UTC | #1
Thanks Ales.

Acked-by: Mark Michelson <mmichels@redhat.com>

On 9/16/22 05:21, Ales Musil wrote:
> Reported-at: https://bugzilla.redhat.com/2126400
> Signed-off-by: Ales Musil <amusil@redhat.com>
> ---
> This patch should be applied only to 22.03 and below,
> because it was fixed as side effect of RFE on 22.06, 22.09
> and main [0].
> 
> [0] https://github.com/ovn-org/ovn/commit/eaf9832be248daca6d96202d504cc789d6dfec6d
> ---
>   northd/northd.c | 2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/northd/northd.c b/northd/northd.c
> index 294a59bd7..aeb2da436 100644
> --- a/northd/northd.c
> +++ b/northd/northd.c
> @@ -3318,7 +3318,7 @@ ovn_port_update_sbrec(struct northd_input *input_data,
>               bool reset_requested_chassis = false;
>               requested_chassis = smap_get(&op->nbsp->options,
>                                            "requested-chassis");
> -            if (requested_chassis) {
> +            if (requested_chassis && requested_chassis[0]) {
>                   const struct sbrec_chassis *chassis; /* May be NULL. */
>                   chassis = chassis_lookup_by_name(sbrec_chassis_by_name,
>                                                    requested_chassis);
Dumitru Ceara Sept. 26, 2022, 10:44 a.m. UTC | #2
On 9/20/22 22:08, Mark Michelson wrote:
> Thanks Ales.
> 
> Acked-by: Mark Michelson <mmichels@redhat.com>
> 

Applied to branch-22.03, thanks!

> On 9/16/22 05:21, Ales Musil wrote:
>> Reported-at: https://bugzilla.redhat.com/2126400
>> Signed-off-by: Ales Musil <amusil@redhat.com>
>> ---
>> This patch should be applied only to 22.03 and below,
>> because it was fixed as side effect of RFE on 22.06, 22.09
>> and main [0].
>>
>> [0]
>> https://github.com/ovn-org/ovn/commit/eaf9832be248daca6d96202d504cc789d6dfec6d
>>
>> ---
>>   northd/northd.c | 2 +-
>>   1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/northd/northd.c b/northd/northd.c
>> index 294a59bd7..aeb2da436 100644
>> --- a/northd/northd.c
>> +++ b/northd/northd.c
>> @@ -3318,7 +3318,7 @@ ovn_port_update_sbrec(struct northd_input
>> *input_data,
>>               bool reset_requested_chassis = false;
>>               requested_chassis = smap_get(&op->nbsp->options,
>>                                            "requested-chassis");
>> -            if (requested_chassis) {
>> +            if (requested_chassis && requested_chassis[0]) {
>>                   const struct sbrec_chassis *chassis; /* May be NULL. */
>>                   chassis = chassis_lookup_by_name(sbrec_chassis_by_name,
>>                                                    requested_chassis);
> 
> _______________________________________________
> dev mailing list
> dev@openvswitch.org
> https://mail.openvswitch.org/mailman/listinfo/ovs-dev
>
diff mbox series

Patch

diff --git a/northd/northd.c b/northd/northd.c
index 294a59bd7..aeb2da436 100644
--- a/northd/northd.c
+++ b/northd/northd.c
@@ -3318,7 +3318,7 @@  ovn_port_update_sbrec(struct northd_input *input_data,
             bool reset_requested_chassis = false;
             requested_chassis = smap_get(&op->nbsp->options,
                                          "requested-chassis");
-            if (requested_chassis) {
+            if (requested_chassis && requested_chassis[0]) {
                 const struct sbrec_chassis *chassis; /* May be NULL. */
                 chassis = chassis_lookup_by_name(sbrec_chassis_by_name,
                                                  requested_chassis);