From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from NAM01-BN3-obe.outbound.protection.outlook.com (mail-bn3nam01on0045.outbound.protection.outlook.com [104.47.33.45]) by dpdk.org (Postfix) with ESMTP id 322BD2C09 for ; Mon, 17 Oct 2016 06:18:41 +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=jNxszzEn7PjQG4WkUdSqh7vwLChIwtzA82F4CtQm1Tc=; b=QqQU2paD6Rcm//8Ih5A3snRNk1bhjZD1bx12LLgcRS99ktcV4yfaQ34lKkVxTonoeDDdFpgn0Whr9LvTQVZmcRfzehHSAAJC0d/8CfSKbj8ijXUjAE6WIO+0Lu3nd0K0tqaFAhw8gxjN3ZYv/UeTFF7MT7AYvOe1T7LsG39dWb4= Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=Jerin.Jacob@cavium.com; Received: from localhost.localdomain (171.48.29.61) by BY1PR0701MB1721.namprd07.prod.outlook.com (10.162.111.140) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P384) id 15.1.649.16; Mon, 17 Oct 2016 04:18:35 +0000 Date: Mon, 17 Oct 2016 09:48:13 +0530 From: Jerin Jacob To: "Eads, Gage" CC: "dev@dpdk.org" , "thomas.monjalon@6wind.com" , "Richardson, Bruce" , "Vangati, Narender" , "hemant.agrawal@nxp.com" Message-ID: <20161017041812.GA3543@localhost.localdomain> References: <20161005072451.GA2358@localhost.localdomain> <1476214216-31982-1-git-send-email-jerin.jacob@caviumnetworks.com> <9184057F7FC11744A2107296B6B8EB1E01E179E0@FMSMSX108.amr.corp.intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Disposition: inline In-Reply-To: <9184057F7FC11744A2107296B6B8EB1E01E179E0@FMSMSX108.amr.corp.intel.com> User-Agent: Mutt/1.6.2 (2016-07-01) X-Originating-IP: [171.48.29.61] X-ClientProxiedBy: BM1PR01CA0012.INDPRD01.PROD.OUTLOOK.COM (10.163.198.147) To BY1PR0701MB1721.namprd07.prod.outlook.com (10.162.111.140) X-MS-Office365-Filtering-Correlation-Id: 51a2497a-fea9-4604-46ea-08d3f644ab65 X-Microsoft-Exchange-Diagnostics: 1; BY1PR0701MB1721; 2:ICvnv9LNNvwhOi5eAd8Uib7CQYl7ZpZchgLwB1lXP3U1VXSdrddFnbJ6mw4hm14hpJr3DBDy3N6CocP6S6V0jZWTuj7cNMPvenzKNlC088FO6nbuNEhhPAwiqTUSghNQAz3+dlqPEm84JFmN9y/uNEtrS1jxNecmRIHtzNfEHrXfCKNawkFo4pwkAlKARgXiOmQMfQGsR7t8L6eyp5TBjA==; 3:spFaqmeMyqoNz0I4NNeHWZlrgIldo7696DodvAbL0i25T528OredGldQMd7I9sNs1fgTz5+aIfyPCIYTTmFoA2olQ5wENfPsWKNvoYFre2GJK7Ukl+DfgGongdhcqRM7nTyYSzoLo6EpoGpKUbylkw== X-Microsoft-Antispam: UriScan:;BCL:0;PCL:0;RULEID:;SRVR:BY1PR0701MB1721; X-Microsoft-Exchange-Diagnostics: 1; BY1PR0701MB1721; 25:afoplcQ1A6qVL95Vc/ULCQAb5ZfQLb3zeq/CvvFo0WbM71EeKnv/UvxRVLHi/oS2wI8y7Ccdq9Drr5fOBzDDS7dbDgJSM7eOSTcdc1LxZGh03EjTlhI9V6Q99xv5vWoApgk/w6AD+dmyZ6UpOpwOgZzmV+NXRkK+eBgCvbGS/vtJhu6fL85blkq415LHQVeXCLBt8Ae4+wQ2ubCWbHqvF1klyxck6WIJGuxNM19+dgXHuRvGjdCYcpTA+pV2kqHNSIjPaMYoDCUkaSoTjxAbB0sEhmUvIKZ3F/zSQESyQx/pKJkjAGkpNt1NVKDtWj6f5SuV2knjY/+b5n7AroskO7zXNYQL7acV/MF1VXX+8O3GSPRu0eKz4AvWDkzFg+hh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N6L1vRfo72wdWWYaX/VKxgyXFo64j6y7jHn5lUJiWpZLtzX3PqAQFqLjuoNU0Ihg33sZcSBGMkIX96N79j2xVhYCQod1eMZBeWYWm8sKNi2EcRpZGBhUGHyP/yX3qKX0p1PuLWxIdbvylLsaSxM/LKDB/Rb8iPNufRxeG2C15USYhhcJvzFznINVt44e75NnWi4rc5aTDkgdGdb22ChSbqpTiYP678QQMEpe3TtIn5Z2C/6+k6BGitonW/0Kbqwg1AVEPt4Y= X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:; X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(6040176)(601004)(2401047)(8121501046)(5005006)(10201501046)(3002001); SRVR:BY1PR0701MB1721; BCL:0; PCL:0; RULEID:; SRVR:BY1PR0701MB1721; X-Microsoft-Exchange-Diagnostics: 1; BY1PR0701MB1721; 4:gv2uKubtg23NoU+pSGglALRKsKpgwgJaPsUi/NvwUDC8VQGcjUkSfXVjoxRKEOmiBiGnE7rJB7T1oYkOnTu/0aFevWGvlnaWa6/htPBLaW2WhzXWcepuNmK80VjbrAu8S6sMPNr2w+yWrCTGziZxNCgP46zGDRhaW8t3uN9GjtXVXB2z00a+gxiB5+98JsLoTY6IHAlbz114SVAX4I/Oiw4GklNdR2KkRPqskGQh8odcQ2EVFXpkSicQjWi6xP3Cp/uCF9w2XzcuAiMuPeW6nRkXNv+K0bpS5Z2nWunIEUk2AYYrJF56J5IpxTHUYuUapABZ38adigG0hL124kQxYTkhprDjf1v7d1ZcBaaU8/mnkZxorReH8f7XPAYuvsutw1/ThBwAqMFutAxm2dYh+g== X-Forefront-PRVS: 0098BA6C6C X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10009020)(4630300001)(6069001)(6009001)(7916002)(199003)(189002)(24454002)(50466002)(81166006)(2906002)(9686002)(6666003)(42882006)(586003)(46406003)(4326007)(6116002)(8676002)(23726003)(68736007)(77096005)(3846002)(42186005)(6916009)(81156014)(2950100002)(61506002)(76176999)(4001350100001)(66066001)(189998001)(1076002)(7846002)(105586002)(33656002)(97756001)(110136003)(83506001)(54356999)(92566002)(5660300001)(305945005)(47776003)(97736004)(101416001)(8666005)(50986999)(7736002)(106356001)(18370500001)(7059030); DIR:OUT; SFP:1101; SCL:1; SRVR:BY1PR0701MB1721; H:localhost.localdomain; FPR:; SPF:None; PTR:InfoNoRecords; A:1; MX:1; LANG:en; Received-SPF: None (protection.outlook.com: cavium.com does not designate permitted sender hosts) X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; BY1PR0701MB1721; 23:4PrATcjcyisika0M8hpFt3R6PIeL1M4iY/eUu5i?= =?us-ascii?Q?/l/ddv/FR5ofoJCAbBwB6VO9a8bdpgUs8xkF3paGsHphtoYLYvfux1C91n2y?= =?us-ascii?Q?wVQ60f2uC+sbztZpoSyxxgLDwbY3aJHOrbblQ7yHd7wUH/vUY0c8MNvslzck?= =?us-ascii?Q?EY/smEfytkuspx2VMXq7fGelyVXHx6UTE/XZ4VGq9Ewj6xo7ry6Jw0o95csK?= =?us-ascii?Q?0cWmuVhNasQRI0FBOrRiQGZ7Sg7hnEZ2F/+qIiYyhiPgNag/rwbSBS5M7vEV?= =?us-ascii?Q?/+WI6yhSyZAeDzN8Nvny8adywCRJVGpqz5xTyPcTz1ic4oWIeEhJQHKbFJdF?= =?us-ascii?Q?piRwJS2Xc3hb3zmkT05Ehop4IsCPWr4LUL/goR0bb9CF461xeKVFauhv7lEg?= =?us-ascii?Q?uEQIv6CsM6neYc304dLeA7WHvgjku2arUL6uq8CEfijrLKJXK+/2uThYt3Aa?= =?us-ascii?Q?/2Af5jkpSnll6kIvlBCzRJbrsqKfUvrLgR8jOf03r/LaM+u435cBzCFQjjxP?= =?us-ascii?Q?B48WntEnqaGIDjmFgw5H5s+I0wMsvP6j4cGGwzAml1qRWqwpyIRRR06p+s3E?= =?us-ascii?Q?lL8pIAi9QcZSRQpNuhX2UFnMRG+PY5NgkBrUhiXxuFl5s4P9rZ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I+Cqj7aGnjydq/V0dFRq1BuQ/tzR0av6HwlZ8B6c7/zTmB6OOIyo9flDVpxD9cwBxRoxxSZbAftgN30; 5:htGoMYfEqRVuVO+Ot5vWEF98ipMCI/wsuvD9GgtQ+TyKcVQb/BE/NqdOnLUsOfiK5NzFqT/309XrRk2D+RzkcYq5EFLAZoKNHVrLTAORCLkXR8XkKBcCP05IMxiy7Hlwigix8hQtrf07/se+F03huLVgS9qcLjy5qvi7+QT1+TU=; 24:T2kDUr3ceQLgYWHQ4SErzroBWhgO4X1zhld69HZ5mw3OrXFPz6q8YigObOFec0k7QaIJMSfWE3XrYBA3QowAOzcqfOXyk5Dt8/gp/sM5bf4= SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-Microsoft-Exchange-Diagnostics: 1; BY1PR0701MB1721; 7:jQeP8IGeHJnRd5CKlleUKINVlRFGwUMwIvd0z7T9pczoDLv1ivMq4T1hGRywl3cJWblwqykkyL5jwTYYOGUmPb/95VyZVZV0kwyRm8DbShjZVyMFAPcdPaIzeLIwqxbd7Pk8JYm3gwUhqvKXLWXyrYFQqS5zIz1UuYS8oJiqc3kdgx3XyreOXnGSjWg3172/JgrLyytNd3Jhnq/JCh1MTw++tJK/68vtY0Gu8OM7XaHJD4XySov7jpuodMCCkHDJCxhSYdOysfDFr8zpt/pXozy1BfhFwugJkXs6KtigL/BKLdWStQuHOa6ypQeAXPByK7/SQR4EUwYrdErSPHhfRid6+CA7xCjr8ZqpgwyypbY= X-OriginatorOrg: caviumnetworks.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 17 Oct 2016 04:18:35.8712 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-Transport-CrossTenantHeadersStamped: BY1PR0701MB1721 Subject: Re: [dpdk-dev] [RFC] [PATCH v2] libeventdev: event driven programming model framework for DPDK X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 17 Oct 2016 04:18:41 -0000 On Fri, Oct 14, 2016 at 03:00:57PM +0000, Eads, Gage wrote: > Thanks Jerin, this looks good. I've put a few notes/questions inline. Thanks Gage. > > > + > > +/** > > + * Get the device identifier for the named event device. > > + * > > + * @param name > > + * Event device name to select the event device identifier. > > + * > > + * @return > > + * Returns event device identifier on success. > > + * - <0: Failure to find named event device. > > + */ > > +extern uint8_t > > +rte_event_dev_get_dev_id(const char *name); > > This return type should be int8_t, or some signed type, to support the failure case. Makes sense. I will change to int to make consistent with rte_cryptodev_get_dev_id() > > > +}; > > + > > +/** > > + * Schedule one or more events in the event dev. > > + * > > + * An event dev implementation may define this is a NOOP, for instance if > > + * the event dev performs its scheduling in hardware. > > + * > > + * @param dev_id > > + * The identifier of the device. > > + */ > > +extern void > > +rte_event_schedule(uint8_t dev_id); > > One idea: Have the function return the number of scheduled packets (or 0 for implementations that do scheduling in hardware). This could be a helpful diagnostic for the software scheduler. How about returning an implementation specific value ? Rather than defining certain function associated with returned value. Just to make sure it works with all HW/SW implementations. Something like below, /** * Schedule one or more events in the event dev. * * An event dev implementation may define this is a NOOP, for instance if * the event dev performs its scheduling in hardware. * * @param dev_id * The identifier of the device. * @return * Implementation specific value from the event driver for diagnostic purpose */ extern int rte_event_schedule(uint8_t dev_id);