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=-9.5 required=3.0 tests=DKIM_INVALID,DKIM_SIGNED, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI,SIGNED_OFF_BY, SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED,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 7829DC2D0B1 for ; Thu, 6 Feb 2020 11:07:59 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 367BD206CC for ; Thu, 6 Feb 2020 11:07:59 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=fail reason="key not found in DNS" (0-bit key) header.d=mg.codeaurora.org header.i=@mg.codeaurora.org header.b="uVJ8xlfq" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727524AbgBFLH6 (ORCPT ); Thu, 6 Feb 2020 06:07:58 -0500 Received: from mail25.static.mailgun.info ([104.130.122.25]:48240 "EHLO mail25.static.mailgun.info" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727519AbgBFLH6 (ORCPT ); Thu, 6 Feb 2020 06:07:58 -0500 DKIM-Signature: a=rsa-sha256; v=1; c=relaxed/relaxed; d=mg.codeaurora.org; q=dns/txt; s=smtp; t=1580987277; h=Content-Transfer-Encoding: MIME-Version: Message-Id: Date: Subject: Cc: To: From: Sender; bh=ZdCkCOcMqPtIwbtgtVCoQbi25mM6d5npDdSqNC2vdms=; b=uVJ8xlfqN6lS9LC9fBVR9vd+eIF0PvnB8kPeRjG8PcKdvI4fZVQRAfz88czuCuQMZcoxii7X 6DdyamizaXPM/sNjG+hvfyTkvDB8BQ6dHrUE6dOHKMeGAiWI5t+b87YODkagGuHAnlHvlsZb 4UC6DpVudWZw+Ld6TLGT9URqMPQ= X-Mailgun-Sending-Ip: 104.130.122.25 X-Mailgun-Sid: WyJlM2NhZSIsICJuZXRmaWx0ZXItZGV2ZWxAdmdlci5rZXJuZWwub3JnIiwgImJlOWU0YSJd Received: from smtp.codeaurora.org (ec2-35-166-182-171.us-west-2.compute.amazonaws.com [35.166.182.171]) by mxa.mailgun.org with ESMTP id 5e3bf385.7fa687ca0068-smtp-out-n01; Thu, 06 Feb 2020 11:07:49 -0000 (UTC) Received: by smtp.codeaurora.org (Postfix, from userid 1001) id BD3D6C447A2; Thu, 6 Feb 2020 11:07:48 +0000 (UTC) Received: from manojbm-linux.qualcomm.com (blr-c-bdr-fw-01_GlobalNAT_AllZones-Outside.qualcomm.com [103.229.19.19]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-SHA256 (128/128 bits)) (No client certificate requested) (Authenticated sender: manojbm) by smtp.codeaurora.org (Postfix) with ESMTPSA id 3066DC433CB; Thu, 6 Feb 2020 11:07:43 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 smtp.codeaurora.org 3066DC433CB Authentication-Results: aws-us-west-2-caf-mail-1.web.codeaurora.org; dmarc=none (p=none dis=none) header.from=codeaurora.org Authentication-Results: aws-us-west-2-caf-mail-1.web.codeaurora.org; spf=none smtp.mailfrom=manojbm@codeaurora.org From: Manoj Basapathi To: netfilter-devel@vger.kernel.org Cc: fw@strlen.de, pablo@netfilter.org, sharathv@qti.qualcomm.com, ssaha@qti.qualcomm.com, vidulak@qti.qualcomm.com, manojbm@qti.qualcomm.com, Manoj Basapathi , Subash Abhinov Kasiviswanathan Subject: [PATCH] [nf-next,v4] netfilter: xtables: Add snapshot of hardidletimer target Date: Thu, 6 Feb 2020 16:37:29 +0530 Message-Id: <20200206110729.30027-1-manojbm@codeaurora.org> X-Mailer: git-send-email 2.25.0 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: netfilter-devel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: netfilter-devel@vger.kernel.org This is a snapshot of hardidletimer netfilter target. This patch implements a hardidletimer Xtables target that can be used to identify when interfaces have been idle for a certain period of time. Timers are identified by labels and are created when a rule is set with a new label. The rules also take a timeout value (in seconds) as an option. If more than one rule uses the same timer label, the timer will be restarted whenever any of the rules get a hit. One entry for each timer is created in sysfs. This attribute contains the timer remaining for the timer to expire. The attributes are located under the xt_idletimer class: /sys/class/xt_idletimer/timers/