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=-8.1 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,USER_AGENT_SANE_1 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 C97EAC43331 for ; Mon, 11 Nov 2019 06:56:48 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 8142E206BB for ; Mon, 11 Nov 2019 06:56:48 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=fail reason="key not found in DNS" (0-bit key) header.d=codeaurora.org header.i=@codeaurora.org header.b="mtOuc7oO"; dkim=fail reason="key not found in DNS" (0-bit key) header.d=codeaurora.org header.i=@codeaurora.org header.b="CeBqyYrU" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726804AbfKKG4s (ORCPT ); Mon, 11 Nov 2019 01:56:48 -0500 Received: from smtp.codeaurora.org ([198.145.29.96]:32976 "EHLO smtp.codeaurora.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726793AbfKKG4s (ORCPT ); Mon, 11 Nov 2019 01:56:48 -0500 Received: by smtp.codeaurora.org (Postfix, from userid 1000) id 51C9D60A24; Mon, 11 Nov 2019 06:56:46 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=codeaurora.org; s=default; t=1573455406; bh=86iLnW3Z4phXLOdJ0OzFB/gNMQK/K3ejcax2lkcPf7M=; h=Date:From:To:Cc:Subject:From; b=mtOuc7oOLTUNxuqpmduzSbUMIzQDFdh6zns9JCV2Wh+I5vCnN5kZPk5LcxfipmSqd DH06CRwUGPVleeor4PtAJq8AJDiUVWo9AQTRNvdOWn6Cs/fE9Qnz/SPwX8W0/WtEjd LIWVFceiQqZJ/yalpBITOvKAyTQcXSdr8jRw8cPs= Received: from manojbm-linux.ap.qualcomm.com (blr-c-bdr-fw-01_globalnat_allzones-outside.qualcomm.com [103.229.19.19]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) (Authenticated sender: manojbm@smtp.codeaurora.org) by smtp.codeaurora.org (Postfix) with ESMTPSA id 849DC60A0B; Mon, 11 Nov 2019 06:56:41 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=codeaurora.org; s=default; t=1573455404; bh=86iLnW3Z4phXLOdJ0OzFB/gNMQK/K3ejcax2lkcPf7M=; h=Date:From:To:Cc:Subject:From; b=CeBqyYrUT1MMidGfpLePy03rcPo/Tt/8IcHkaPdLX+cwUcCIcVWZR7zuSaJPYWw1H I54VStl79vIFjEhmnNGeFWcpzmOoWrR0X9XJ6Q6Yii+S1ZMvGSD/4SlWxQjz3PpG/b YB/XJ/JvWgI7zcGkWXUZKBw7miLB8T8O8qklRqCc= DMARC-Filter: OpenDMARC Filter v1.3.2 smtp.codeaurora.org 849DC60A0B Authentication-Results: pdx-caf-mail.web.codeaurora.org; dmarc=none (p=none dis=none) header.from=codeaurora.org Authentication-Results: pdx-caf-mail.web.codeaurora.org; spf=none smtp.mailfrom=manojbm@codeaurora.org Date: Mon, 11 Nov 2019 12:26:29 +0530 From: Manoj Basapathi To: netfilter-devel@vger.kernel.org Cc: subashab@quicinc.com, sharathv@qti.qualcomm.com, ssaha@qti.qualcomm.com, vidulak@qti.qualcomm.com, bryanh@quicinc.com, jovanar@qti.qualcomm.com, manojbm@qti.qualcomm.com Subject: [PATCH] netfilter: xtables: Add snapshot of hardidletimer target Message-ID: <20191111065617.GA29048@manojbm-linux.ap.qualcomm.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.5.24 (2015-08-30) Sender: netfilter-devel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: netfilter-devel@vger.kernel.org This is a snapshot of hardifletimer netfilter target as of msm-4.4 commit 469a150b7426 ("netfilter: xtables: hardidletimer target implementation") 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_hardidletimer/timers/