From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wm0-f67.google.com (mail-wm0-f67.google.com [74.125.82.67]) by dpdk.org (Postfix) with ESMTP id CBE322BF5 for ; Wed, 12 Jul 2017 21:59:02 +0200 (CEST) Received: by mail-wm0-f67.google.com with SMTP id u23so949697wma.2 for ; Wed, 12 Jul 2017 12:59:02 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references; bh=5wvlMZwEvSThBK/Jsm5MpEJ60V+w094Ml0ewwRDCeLc=; b=ZRhfwDIBRExrBWmkDwybMMfaf7gZdlNX5tsUxrFC9VjbMARyZCzwee9eLIfodS5nxQ yQuhf6WGCRmLintVkO4K6UQuyAYH0S5SGL4sJk0g0n6eLdYe6CV00NlGMLorRcBpZKCy UtGoHrt2xctN/ytIbBWPYRSJKX9XN+a3Uflmou4qB0L2N2sSBTdTeURrKmcljXvmcaUL 9RzTTqZDCJGyIikL4S83vd3y0t1IqXyWAtPbVyIxvqk9JJCuakSchdmeho9RV/oRAQ8l 0e6GwqLUPqkjI5BI+z987fvBTFH2wNugsoty7a55mwV+CIxX8GiExYvxD3pw7t7WfGqe E6hQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references; bh=5wvlMZwEvSThBK/Jsm5MpEJ60V+w094Ml0ewwRDCeLc=; b=ft/4By9ZidXuOhlZ6fCcpclanfhSeGjoN8FJhK0XFB5ETGvjM8+ICxBZzcMim0tPuj igB1ahV9IojATJUt+3Ct5HxBcDdCsUhaBCCDUE3TA0b7oTMz8hcFdfvDNQRSSGU3ySuV ZqCvYPv+YMqvQ0TxGxTfaL3uaMctzcHqNVTsjeYdTVSxmDBRaB9oKk2R/uUrG9V0DtA4 YuMHr60fEod4MNa1Pq8v/fdO8mmGzvPCDBSPcrRZ4W2++/l6WkDXYKZpqQS2GiVqs58f OcEodgfZmIrwsjN5nfcATcyYdvFjMybyw+dTVBlVKzOB3/97dVebG+gsrwGSfqGiaSq7 jO1w== X-Gm-Message-State: AIVw1132tV5kXTKZhcZsAygUTqioOxthKuqthSQRdiJHvxyoXDSTdzU9 e22UuUS1cNT8Dwtc X-Received: by 10.80.134.139 with SMTP id r11mr158587eda.77.1499889542413; Wed, 12 Jul 2017 12:59:02 -0700 (PDT) Received: from localhost.localdomain ([37.228.147.16]) by smtp.gmail.com with ESMTPSA id t3sm1420660edh.1.2017.07.12.12.59.01 (version=TLS1 cipher=AES128-SHA bits=128/128); Wed, 12 Jul 2017 12:59:01 -0700 (PDT) Sender: Jan Blunck From: Jan Blunck To: dev@dpdk.org Cc: declan.doherty@intel.com, pablo.de.lara.guarch@intel.com Date: Wed, 12 Jul 2017 15:58:44 -0400 Message-Id: <20170712195846.65286-3-jblunck@infradead.org> X-Mailer: git-send-email 2.13.2 In-Reply-To: <20170712195846.65286-1-jblunck@infradead.org> References: <20170712075940.58559-1-jblunck@infradead.org> <20170712195846.65286-1-jblunck@infradead.org> Subject: [dpdk-dev] [PATCH v2 2/4] cryptodev: move initialization 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: Wed, 12 Jul 2017 19:59:03 -0000 Signed-off-by: Jan Blunck --- lib/librte_cryptodev/rte_cryptodev.c | 3 +++ lib/librte_cryptodev/rte_cryptodev_pmd.c | 6 ------ 2 files changed, 3 insertions(+), 6 deletions(-) diff --git a/lib/librte_cryptodev/rte_cryptodev.c b/lib/librte_cryptodev/rte_cryptodev.c index 8ee5d47a9..09e4671be 100644 --- a/lib/librte_cryptodev/rte_cryptodev.c +++ b/lib/librte_cryptodev/rte_cryptodev.c @@ -587,6 +587,9 @@ rte_cryptodev_pmd_allocate(const char *name, int socket_id) cryptodev->data->socket_id = socket_id; cryptodev->data->dev_started = 0; + /* init user callbacks */ + TAILQ_INIT(&(cryptodev->link_intr_cbs)); + cryptodev->attached = RTE_CRYPTODEV_ATTACHED; cryptodev_globals.nb_devs++; diff --git a/lib/librte_cryptodev/rte_cryptodev_pmd.c b/lib/librte_cryptodev/rte_cryptodev_pmd.c index a57faadcf..ec6eeffa1 100644 --- a/lib/librte_cryptodev/rte_cryptodev_pmd.c +++ b/lib/librte_cryptodev/rte_cryptodev_pmd.c @@ -101,9 +101,6 @@ rte_cryptodev_vdev_pmd_init(const char *name, size_t dev_private_size, cryptodev->device = &vdev->device; - /* initialise user call-back tail queue */ - TAILQ_INIT(&(cryptodev->link_intr_cbs)); - return cryptodev; } @@ -188,9 +185,6 @@ rte_cryptodev_pci_generic_probe(struct rte_pci_device *pci_dev, cryptodev->device = &pci_dev->device; - /* init user callbacks */ - TAILQ_INIT(&(cryptodev->link_intr_cbs)); - /* Invoke PMD device initialization function */ RTE_FUNC_PTR_OR_ERR_RET(*dev_init, -EINVAL); retval = dev_init(cryptodev); -- 2.13.2