On Thu, Oct 6, 2011 at 6:30 PM, Jesse Gross <[email protected]> wrote:
> On Thu, Oct 6, 2011 at 3:13 PM, Pravin B Shelar <[email protected]> wrote:
>> Following patch removes RT kernel support. This allows us to cleanup
>> the loop detection.
>> Along with this BH is now disabled while running execute_actions()
>> for packet from user-space.
>> As a result we can simplify the stats code as entire send and receive
>> path runs in BH context on all supported platforms.
>>
>> Signed-off-by: Pravin B Shelar <[email protected]>
>> Bug #7621
>> ---
>>  datapath/Modules.mk                               |    2 -
>>  datapath/actions.c                                |   27 +++++++-
>>  datapath/datapath.c                               |   20 ++----
>>  datapath/flow.c                                   |    4 +-
>>  datapath/linux/compat/include/linux/bottom_half.h |   19 ------
>>  datapath/loop_counter.c                           |   72 
>> ---------------------
>>  datapath/loop_counter.h                           |   28 --------
>>  datapath/tunnel.c                                 |    8 +-
>>  datapath/vport-internal_dev.c                     |    5 +-
>>  datapath/vport.c                                  |   10 +--
>>  10 files changed, 41 insertions(+), 154 deletions(-)
>>  delete mode 100644 datapath/linux/compat/include/linux/bottom_half.h
>>  delete mode 100644 datapath/loop_counter.c
>>  delete mode 100644 datapath/loop_counter.h
>
> You need to remove bottom_half.h from linux/Modules.mk as well or make
> dist fails.
>
>> diff --git a/datapath/actions.c b/datapath/actions.c
>> index 36437a4..a868164 100644
>> --- a/datapath/actions.c
>> +++ b/datapath/actions.c
>> @@ -388,7 +409,7 @@ int execute_actions(struct datapath *dp, struct sk_buff 
>> *skb)
>>        int error;
>>
>>        /* Check whether we've looped too much. */
>> -       loop = loop_get_counter();
>> +       loop = &get_cpu_var(loop_counters);
>
> Since bottom halves are disabled here, the CPU can't change out from
> under us and we can use __get_cpu_var and drop put_cpu_var.
>
> Otherwise looks good:
> Acked-by: Jesse Gross <[email protected]>
>
Thanks,
Pushed to master.
_______________________________________________
dev mailing list
[email protected]
http://openvswitch.org/mailman/listinfo/dev

Reply via email to