From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-3.0 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_PASS,UNPARSEABLE_RELAY,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 011FAC43381 for ; Fri, 22 Feb 2019 14:01:01 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id BDEDF20818 for ; Fri, 22 Feb 2019 14:01:00 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726540AbfBVOA7 (ORCPT ); Fri, 22 Feb 2019 09:00:59 -0500 Received: from mail-il-dmz.mellanox.com ([193.47.165.129]:44677 "EHLO mellanox.co.il" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726303AbfBVOA7 (ORCPT ); Fri, 22 Feb 2019 09:00:59 -0500 Received: from Internal Mail-Server by MTLPINE1 (envelope-from vladbu@mellanox.com) with ESMTPS (AES256-SHA encrypted); 22 Feb 2019 16:00:57 +0200 Received: from reg-r-vrt-018-180.mtr.labs.mlnx. (reg-r-vrt-018-180.mtr.labs.mlnx [10.213.18.180]) by labmailer.mlnx (8.13.8/8.13.8) with ESMTP id x1ME0vLx000465; Fri, 22 Feb 2019 16:00:57 +0200 From: Vlad Buslov To: netdev@vger.kernel.org Cc: jhs@mojatatu.com, xiyou.wangcong@gmail.com, davem@davemloft.net, shuah@kernel.org, batuhanosmantaskaya@gmail.com, lucasb@mojatatu.com, dcaratti@redhat.com, marcelo.leitner@gmail.com, chrism@mellanox.com, Vlad Buslov Subject: [PATCH net-next 0/8] Add tests for unlocked flower classifier implementation Date: Fri, 22 Feb 2019 16:00:39 +0200 Message-Id: <20190222140047.13215-1-vladbu@mellanox.com> X-Mailer: git-send-email 2.13.6 Sender: netdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org Implement tests for tdc testsuite to verify concurrent rules update with rtnl-unlocked flower classifier implementation. The goal of these tests is to verify general flower classifier correctness by updating filters on same classifier instance in parallel and to verify its atomicity by concurrently updating filters in same handle range. All three filter update operations (add, replace, delete) are tested. Existing script tdc_batch.py is re-used for batch file generation. It is extended with several optional CLI arguments that are needed for concurrency tests. Thin wrapper tdc_multibatch.py is implemented on top of tdc_batch.py to simplify its usage when generating multiple batch files for several test configurations. Parallelism in tests is implemented by running multiple instances of tc in batch mode with xargs tool. Xargs is chosen for its ease of use and because it is available by default on most modern Linux distributions. Vlad Buslov (8): selftests: tdc_batch.py: add options needed for concurrency tests selftests: concurrency: add test to verify parallel rules insertion selftests: concurrency: add test to verify parallel rules deletion selftests: concurrency: add test to verify parallel rules replace selftests: concurrency: add test to verify concurrent replace selftests: concurrency: add test to verify concurrent delete selftests: concurrency: add test to verify parallel add/delete selftests: concurrency: add test to verify parallel replace/delete .../tc-testing/tc-tests/filters/concurrency.json | 177 +++++++++++++++++++++ tools/testing/selftests/tc-testing/tdc_batch.py | 58 ++++++- tools/testing/selftests/tc-testing/tdc_config.py | 1 + .../testing/selftests/tc-testing/tdc_multibatch.py | 65 ++++++++ 4 files changed, 297 insertions(+), 4 deletions(-) create mode 100644 tools/testing/selftests/tc-testing/tc-tests/filters/concurrency.json create mode 100755 tools/testing/selftests/tc-testing/tdc_multibatch.py -- 2.13.6