From mboxrd@z Thu Jan  1 00:00:00 1970
Return-Path: <vincent.jardin@6wind.com>
Received: from mail-wm0-f47.google.com (mail-wm0-f47.google.com [74.125.82.47])
 by dpdk.org (Postfix) with ESMTP id 725081D90
 for <dev@dpdk.org>; Thu, 12 Oct 2017 09:59:55 +0200 (CEST)
Received: by mail-wm0-f47.google.com with SMTP id u138so10887195wmu.4
 for <dev@dpdk.org>; Thu, 12 Oct 2017 00:59:55 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=6wind-com.20150623.gappssmtp.com; s=20150623;
 h=subject:to:cc:references:from:organization:message-id:date
 :user-agent:mime-version:in-reply-to:content-language
 :content-transfer-encoding;
 bh=xInM+S7+t0Li8AjPYkd10e9pH/D1fuobOLRm7mu6kkg=;
 b=sgfa/8Myzj8GXbBvaTb9ahH69rbdNX0wTCTbnI6vruKcTgtUF9WK+iuLri/on99eJ5
 az4KKHrR7s+S0I1lXNTaSwZdRWV4j4fbovuT6ikO/auW5vGM72Q0Ac95jkHvB1CBR9QZ
 24vbUakkN/dZ1Fcm4HjxUw4D6hhf46Jr4h+3XPhXp3/PTW0mZwHxjV9ffLw2YCQfHsiw
 vVRx7kZOQ5aYN8QUkFxkTdD5rLYaCqzBKpuVwot0QB2wlysbYwF7ZZ7TtAeg4C0iw07E
 CNdHXwBtioEd+pUJ/IR4ziG0pZq9SYTQR4pOvc6/kI8lumCQGDRKLQlISEQTvLhR8hu2
 VwgQ==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=1e100.net; s=20161025;
 h=x-gm-message-state:subject:to:cc:references:from:organization
 :message-id:date:user-agent:mime-version:in-reply-to
 :content-language:content-transfer-encoding;
 bh=xInM+S7+t0Li8AjPYkd10e9pH/D1fuobOLRm7mu6kkg=;
 b=BcaMLiy4EHa3Wn68JhNe39YUId0Uh5ouMNKlGI7StQXxWyTdIx7yVhpAO5B5nlpud1
 phPLmVLcJfgi8SToqj/eZ2JlDCrFDZMhE7AKQRglXCdkq67FcrmgaoTzKZTu87iowolu
 HXRf7ZnIQWy8tzdXwAOgKuf/q40enVNBrPL4bKO8zPww09pjiKwoGWwT9hD3JVQpiXu7
 QDDNjVoAWvF2eJ0lM4kUIk8T+uKq81TEEP66h4QwDlkOZSR0E5Zti1U+7fIkvkHj/L2M
 xJlGjh8PU7LhfetVYmSsvoExQSzjj2YRvPq4fby9tTS4Gd4qbypPV9Md3laQLsXgadgb
 mnXQ==
X-Gm-Message-State: AMCzsaVt2J+bG/hdfCOKl8s/2bVf7gvWBmNghtQLZCGej7FF6LO9Z7lk
 GdlOCV5GBb5PMoGiMboe6zQt/w==
X-Google-Smtp-Source: AOwi7QCwTFfRrcec2pbqRX25cDvbCwWimXK/IgicARJGBcx5C+7InrehngFkUaVAqHtg7TSbLeEVpA==
X-Received: by 10.223.136.137 with SMTP id f9mr1207359wrf.130.1507795194848;
 Thu, 12 Oct 2017 00:59:54 -0700 (PDT)
Received: from ?IPv6:2a01:e35:8a8e:1b70:605a:6384:b7e3:aad0?
 ([2a01:e35:8a8e:1b70:605a:6384:b7e3:aad0])
 by smtp.gmail.com with ESMTPSA id b11sm31461068wrd.91.2017.10.12.00.59.52
 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128);
 Thu, 12 Oct 2017 00:59:53 -0700 (PDT)
To: Tomasz Duszynski <tdu@semihalf.com>, Thomas Monjalon <thomas@monjalon.net>
Cc: dev@dpdk.org, mw@semihalf.com, dima@marvell.com, nsamsono@marvell.com,
 Jianbo.liu@linaro.org, Jacek Siuda <jck@semihalf.com>
References: <1507031500-11473-1-git-send-email-tdu@semihalf.com>
 <1507561244-20115-1-git-send-email-tdu@semihalf.com>
 <1507561244-20115-3-git-send-email-tdu@semihalf.com> <9041127.34t6OW5FrT@xps>
 <20171012065104.GC19106@tdu>
From: Vincent JARDIN <vincent.jardin@6wind.com>
Organization: www.6wind.com
Message-ID: <6bfe47de-c5b4-2b01-7991-2ac48913b2c3@6wind.com>
Date: Thu, 12 Oct 2017 09:59:49 +0200
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101
 Thunderbird/52.3.0
MIME-Version: 1.0
In-Reply-To: <20171012065104.GC19106@tdu>
Content-Type: text/plain; charset=utf-8; format=flowed
Content-Language: en-US
Content-Transfer-Encoding: 8bit
Subject: Re: [dpdk-dev] [PATCH v4 02/16] net/mrvl: add mrvl net pmd driver
 skeleton
X-BeenThere: dev@dpdk.org
X-Mailman-Version: 2.1.15
Precedence: list
List-Id: DPDK patches and discussions <dev.dpdk.org>
List-Unsubscribe: <http://dpdk.org/ml/options/dev>,
 <mailto:dev-request@dpdk.org?subject=unsubscribe>
List-Archive: <http://dpdk.org/ml/archives/dev/>
List-Post: <mailto:dev@dpdk.org>
List-Help: <mailto:dev-request@dpdk.org?subject=help>
List-Subscribe: <http://dpdk.org/ml/listinfo/dev>,
 <mailto:dev-request@dpdk.org?subject=subscribe>
X-List-Received-Date: Thu, 12 Oct 2017 07:59:55 -0000

+1 with Thomas, see below,

Le 12/10/2017 à 08:51, Tomasz Duszynski a écrit :
>> What is MUSDK_DMA_MEMSIZE?
>> If the value cannot change, it must be a constant in the code.
>> If it can change, it should be a run-time driver option.
> It's up to the user what MUSDK_DMA_MEMSIZE is going to be. Currently it's
> set to value that should work it all cases.
> 
> Except that, MUSDK_DMA_MEMSIZE is used as synchronization point for net
> and crypto (on condition they are used together i.e ipsec-secgw).
> 
> Suppose we have two different MUSDK_DMA_MEMSIZE defined for net/crypto then
> dma memsize allocated will depend on driver probing sequence which might
> confuse user.
It does not make sense,
+	/*
+	 * ret == -EEXIST is correct, it means DMA
+	 * has been already initialized (by another PMD).
+	 */
+	ret = mv_sys_dma_mem_init(RTE_MRVL_MUSDK_DMA_MEMSIZE

int mv_sys_dma_mem_init(u64 size)
{
         struct sys_dma  *i_sys_dma;
         int err;

         if (sys_dma) {
                 pr_err("Dma object already exits.\n");
                 return -EEXIST;
         }

So, I do not understand why you cannot add some checks into the drivers 
to assert that users must have set the same value for both when calling:
   ret = mv_sys_dma_mem_init(my_best_size);
maybe, you need to fix and improve musdk first to avoid DPDK from 
getting such compilation issues.

best regards,
   Vincent