From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from NAM03-DM3-obe.outbound.protection.outlook.com (mail-dm3nam03on0072.outbound.protection.outlook.com [104.47.41.72]) by dpdk.org (Postfix) with ESMTP id 09B861B693 for ; Sun, 8 Apr 2018 10:06:35 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=CAVIUMNETWORKS.onmicrosoft.com; s=selector1-cavium-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=QyazVIK3CxQh5KxnD52cNyx1rJERQ+eyS0bAa/pcTQc=; b=R49mAmPcUkIsxJI1MsqJFf+Aw31hmgYiSFBiqI6uPvHQPufByg4/tf95UoKq3Cf6v7qnjlnU3ni4fbIFlC9YiDev9plspwijynwmhlaSoE5Yw8GQsAYm5SYa3NF6655TZhdjyvsQr9UHHHFtBBcYRrxAzVrpfyChlM1f4As81ak= Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=Jerin.JacobKollanukkaran@cavium.com; Received: from jerin (122.178.210.9) by SN2PR07MB2528.namprd07.prod.outlook.com (2603:10b6:804:7::6) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P256) id 15.20.653.12; Sun, 8 Apr 2018 08:06:31 +0000 Date: Sun, 8 Apr 2018 13:36:16 +0530 From: Jerin Jacob To: Pavan Nikhilesh Cc: santosh.shukla@caviumnetworks.com, erik.g.carrillo@intel.com, dev@dpdk.org Message-ID: <20180408080615.GE6880@jerin> References: <20180216213700.3415-1-pbhagavatula@caviumnetworks.com> <20180403150514.24201-1-pbhagavatula@caviumnetworks.com> <20180403150514.24201-9-pbhagavatula@caviumnetworks.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20180403150514.24201-9-pbhagavatula@caviumnetworks.com> User-Agent: Mutt/1.9.4 (2018-02-28) X-Originating-IP: [122.178.210.9] X-ClientProxiedBy: MAXPR0101CA0069.INDPRD01.PROD.OUTLOOK.COM (2603:1096:a00:e::31) To SN2PR07MB2528.namprd07.prod.outlook.com (2603:10b6:804:7::6) X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 5556c379-180a-467b-37d1-08d59d27a497 X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(7020095)(4652020)(5600026)(4604075)(2017052603328)(7153060)(7193020); SRVR:SN2PR07MB2528; X-Microsoft-Exchange-Diagnostics: 1; SN2PR07MB2528; 3:9lGGMHOzuaOQx5V4qzw3JU7IIHoeAlyY2tvUuHKH1qNTtAb8A+2dlCvfKWoK3AZVgGu0DAyimc99IgbBtsfUtbIRUZ8iZOQXJh+fLKRBkvnf8ukMGwNKeQ+1d7qvSuKJkwy4SdiODQmzGsJCxwMDcy7zuUrPi+73G4xMtgwzXF/dyyrvurDM/OoV5KJBqEDYEE3dqOMgKu33e7tweqjbmjt/MvQHY/FMGZJ0MGcCXkWFNBTTfhmOBJUPSmQ44Q+8; 25:T0+JTb4CRgvIlEmqz4749HptZ1U4bLfzMg8eumR+ozbVOhxeNEQKNiIk1CxOLyksQp2jgQypYesOArsQtd56qp3BftPSPmhOT5r4pxNNzEsokoxBhmMP0BtSCgdnt86syS8/dYnBA6YbkkbU1OdRHo1HEIR0RL1TLMiooINpIw/yCIOpgEgHR7/Bzsgf5DtP7vnvPXr61DcyGjeeSCei8/qR3TW2ICUYArvPLr1H3VUTzP0Yv9IpBYcXcsY45eS24YsmTYAIK3N0ijaUCborlQcNl/ijnL+0y61xIfgKCZbdcoa8HRT0j1v1+IjzBt6HAKqwoe9Hg01TswJE9NLCFQ==; 31:w9diCzn32C4PA+Jerp4EheG7L+hbc6nunvFQnStWH9s8Kk7DwcsR23esvEZOUbNJmO+FF9JVoyti6CjfyrkdB1Ncq3zHX0OtHmBGBAP0lNlhC8eY8/TeFzNaM8BqeVm4dI9TDkdq0wdKCIYMso31cctw55BzyMEihZEsSzOShzi4AJ9HJj0AYo46B2dIwtQ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soft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:(228905959029699); X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(8211001083)(6040522)(2401047)(5005006)(8121501046)(3002001)(10201501046)(93006095)(3231221)(944501327)(52105095)(6041310)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(20161123562045)(20161123560045)(20161123558120)(20161123564045)(6072148)(201708071742011); SRVR:SN2PR07MB2528; BCL:0; PCL:0; RULEID:; SRVR:SN2PR07MB2528; X-Forefront-PRVS: 0636271852 X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10009020)(396003)(376002)(39850400004)(346002)(366004)(39380400002)(199004)(13464003)(189003)(16586007)(486006)(446003)(42882007)(11346002)(8676002)(8936002)(81166006)(81156014)(956004)(58126008)(16526019)(26005)(316002)(68736007)(476003)(6862004)(3846002)(59450400001)(6116002)(4326008)(386003)(52116002)(33896004)(2906002)(1076002)(72206003)(7736002)(53936002)(33716001)(66066001)(33656002)(305945005)(229853002)(55016002)(6666003)(6636002)(106356001)(23726003)(76176011)(50466002)(9686003)(97736004)(6246003)(575784001)(25786009)(478600001)(6496006)(105586002)(5660300001)(47776003)(18370500001); DIR:OUT; SFP:1101; SCL:1; SRVR:SN2PR07MB2528; H:jerin; FPR:; SPF:None; LANG:en; PTR:InfoNoRecords; A:1; MX:1; Received-SPF: None (protection.outlook.com: cavium.com does not designate permitted sender hosts) X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; SN2PR07MB2528; 23:jxwWP5F+nn8F1m7WqOY6U3Zs4JNF3pQ6+Fi6OzRzJ?= =?us-ascii?Q?wWUjNZfuD49EAFxk08qODwZYqUEVYejyEcP3O7LV0HgwT8PLZiJmAySvEB8+?= =?us-ascii?Q?Gc+fCZFwhtLbThdv3+J0jZJERnX/SXVHONyXo34eWut/rIwp0yGGlGM1ojhL?= =?us-ascii?Q?umcPV+NF+I2mI25BA/kpIEnJZP44zSz+oJPE+b1aAydChKbww5W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UhlDUL3g==; 5:sHFwyYreCdBGm4t8pLNUIYwmDoKJi9boy8xYsOZHT6ueZI87ee5D5he3umt1HscDg7OIbCVtB2ph/fnV8QHm34nJKVHwRMmPc9EzYUDNhcQ8zUSiP3fALtv+KcwL4VWsguLx+d+DuDtUj81swMb5AjbD9ZrLSOEcCLGDg3GAVp8=; 24:2zhjeuRxaE6DCjw2SFV5hJkI5BxrKfPaJ+uzILQ+2/q8agmam9ryWPCeAa1AKcB2dvuXBbDkrHUcGfu3dY/d15mAMjzclTMFQt1O3DvrnaA= SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-Microsoft-Exchange-Diagnostics: 1; SN2PR07MB2528; 7:pBD0fP8dyaEz5fKa9znCZgaveBnlKiUg065Rr7qqmjJSpEViytP2FALSrhm3lfb+gdQGumQujGg+uKWHRgcrvwxmQOXOju1TYJhfMy4+NeN8JNF/+9uXd/bUWq2AsgSqIf9d4UrBXYr2AeuD92YQ3v70qZl909waPKQZB1Ci4y3VmAmz9XEYOVHh9Fe5oDNvDpxqsvQNukyNgo3STyox7bC9ti0QJrPFPSG7UrCKNDmkPyeT396Tb/+UL0ZWkItK X-OriginatorOrg: caviumnetworks.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 08 Apr 2018 08:06:31.7983 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 5556c379-180a-467b-37d1-08d59d27a497 X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 711e4ccf-2e9b-4bcf-a551-4094005b6194 X-MS-Exchange-Transport-CrossTenantHeadersStamped: SN2PR07MB2528 Subject: Re: [dpdk-dev] [PATCH v3 08/12] event/octeontx: add burst mode for timer arm X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 08 Apr 2018 08:06:35 -0000 -----Original Message----- > Date: Tue, 3 Apr 2018 20:35:10 +0530 > From: Pavan Nikhilesh > To: jerin.jacob@caviumnetworks.com, santosh.shukla@caviumnetworks.com, > erik.g.carrillo@intel.com > Cc: dev@dpdk.org, Pavan Nikhilesh > Subject: [dpdk-dev] [PATCH v3 08/12] event/octeontx: add burst mode for > timer arm > X-Mailer: git-send-email 2.16.3 > > Signed-off-by: Pavan Nikhilesh > --- > drivers/event/octeontx/timvf_evdev.c | 1 + > drivers/event/octeontx/timvf_evdev.h | 3 ++ > drivers/event/octeontx/timvf_worker.c | 38 ++++++++++++++ > drivers/event/octeontx/timvf_worker.h | 95 +++++++++++++++++++++++++++++++++++ > 4 files changed, 137 insertions(+) > > diff --git a/drivers/event/octeontx/timvf_evdev.c b/drivers/event/octeontx/timvf_evdev.c > index a32892107..b23500e0d 100644 > --- a/drivers/event/octeontx/timvf_evdev.c > +++ b/drivers/event/octeontx/timvf_evdev.c > @@ -333,6 +333,7 @@ timvf_timer_adapter_caps_get(const struct rte_eventdev *dev, uint64_t flags, > else > timvf_ops.arm_burst = timvf_timer_reg_burst_mp; > > + timvf_ops.arm_tmo_tick_burst = timvf_timer_reg_brst; IMO, To inline with spec name, may we could use arm_burst/cancel_burst instead of reg_brst or unreg_burst. > timvf_ops.cancel_burst = timvf_timer_unreg_burst; > > *caps = RTE_EVENT_TIMER_ADAPTER_CAP_INTERNAL_PORT; > diff --git a/drivers/event/octeontx/timvf_evdev.h b/drivers/event/octeontx/timvf_evdev.h > index ab2de678f..d8a6d111f 100644 > --- a/drivers/event/octeontx/timvf_evdev.h > +++ b/drivers/event/octeontx/timvf_evdev.h > @@ -200,6 +200,9 @@ uint16_t timvf_timer_reg_burst_sp(const struct rte_event_timer_adapter *adptr, > struct rte_event_timer **tim, const uint16_t nb_timers); > uint16_t timvf_timer_reg_burst_mp(const struct rte_event_timer_adapter *adptr, > struct rte_event_timer **tim, const uint16_t nb_timers); > +uint16_t timvf_timer_reg_brst(const struct rte_event_timer_adapter *adptr, > + struct rte_event_timer **tim, const uint64_t timeout_tick, > + const uint16_t nb_timers); > void timvf_set_chunk_refill(struct timvf_ring * const timr); > > #endif /* __TIMVF_EVDEV_H__ */ > diff --git a/drivers/event/octeontx/timvf_worker.c b/drivers/event/octeontx/timvf_worker.c > index 139dfdc07..f4f40d150 100644 > --- a/drivers/event/octeontx/timvf_worker.c > +++ b/drivers/event/octeontx/timvf_worker.c > @@ -113,6 +113,44 @@ timvf_timer_reg_burst_mp(const struct rte_event_timer_adapter *adptr, > return index; > } > > +/* Burst mode functions */ > +static inline int > +timvf_add_entry_brst(struct timvf_ring * const timr, const uint16_t rel_bkt, > + struct rte_event_timer ** const tim, > + const struct tim_mem_entry *ents, > + const uint16_t nb_timers) > +{ > + int16_t rem; > + int16_t crem = 0; > + uint8_t lock_cnt; > + uint16_t index = 0; > + uint16_t chunk_remainder = 0; Looks like above all assignments to 'zero' is unnecessary.