From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-qk0-f180.google.com (mail-qk0-f180.google.com [209.85.220.180]) by dpdk.org (Postfix) with ESMTP id 365F6AD9C for ; Tue, 10 May 2016 17:18:06 +0200 (CEST) Received: by mail-qk0-f180.google.com with SMTP id r184so8572987qkc.1 for ; Tue, 10 May 2016 08:18:06 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:from:date:message-id:subject:to; bh=QrahxXPiE2ot7/fgSS0oB0yw0xSTL3lTc+PfHZcSyZg=; b=U1CjV2nLOyqzNXf+0EROw4jPACGLsMfLH2/KEtOirXeWSEw9b+qI9RqRx22hZIzKCU PIDjlZOT4g8xdZs29+xDsMZVgHiVd4H8T32xOjmZcKqQS2pwabkpQ+r0/BnjwZ99vNIV T/YCCUrB/ENeUI3jThuPMO0AwwQ2XvkE81w+FJRyHXhEhUkRbgT2sJLm1L+Fji+KyVK9 TJFFsUG1AkYtTloT6Oa5oeeDWQA/CbC7qSZiI50nNszzZGQZMS0MJC2LLufQXMtrEr99 2VSd3ybdH7U+NXfZg6OFoCx2xDLk3uugyd6smgbUHmO33ruz5j1z5CC9YPWEouR1uxti ZT8Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to; bh=QrahxXPiE2ot7/fgSS0oB0yw0xSTL3lTc+PfHZcSyZg=; b=cD/soNCrsUK6TF+GSks3SMb4Q78tO0vzpbYRMbmj8Rq1ZUXqUKT848QYTXeV+W4qsU JtpB0Kk8i9dUUPk/Nl5EZEorBCrQU4HPtzcgKDeCvbN9HQ+ZZ9nfwba6z0x0bayFh33I wGBsFWp0eiB+5x8VqNIBXhvCLe+5Gqg5QXWcNoLcLXoZ3J/JQVBV6q6/z1b4pi/r1iCW 36I20gA/yxbhYak+b3qH1D/aWs3hOgH8lOnHu+yszEUB6QnS52wV9bq+KiPa4O9fJC9R 2GeqSsMNLR3TZRlZTEIDLwdeFd5fLlP0V+tHzw1QaKhT72c9hmLoYks+1gbYylObOeD7 Kmtw== X-Gm-Message-State: AOPr4FULoGT0ADn5Vbe/OMLU1oeD1+tnsxcektCLgU70z6W9NC0hgPEshqA4DIYjtPeXTh8Z0p6zph97GhUV1A== X-Received: by 10.55.19.138 with SMTP id 10mr25681406qkt.119.1462893485737; Tue, 10 May 2016 08:18:05 -0700 (PDT) MIME-Version: 1.0 Received: by 10.140.31.134 with HTTP; Tue, 10 May 2016 08:17:26 -0700 (PDT) In-Reply-To: <6cbfe6bd-b4c4-c0c8-3969-9d362193d8b3@intel.com> References: <6cbfe6bd-b4c4-c0c8-3969-9d362193d8b3@intel.com> From: Mahdi Moradmand Badie Date: Tue, 10 May 2016 11:17:26 -0400 Message-ID: To: Sergio Gonzalez Monroy , dev@dpdk.org Content-Type: text/plain; charset=UTF-8 X-Content-Filtered-By: Mailman/MimeDel 2.1.15 Subject: Re: [dpdk-dev] rte_malloc 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: Tue, 10 May 2016 15:18:06 -0000 Thanks Sergio, Yes sure, I attached files, it seems so easy but doesn't work. Thanks, On 10 May 2016 at 04:12, Sergio Gonzalez Monroy < sergio.gonzalez.monroy@intel.com> wrote: > Hi, > > On 09/05/2016 18:32, Mahdi Moradmand Badie wrote: > >> Hello All, >> >> I had a problem regarding use the rte_malloc. >> I want to know if I want to use rte_malloc instead of malloc just mak >> change like this >> struct lcore_params *p = malloc >> < >> http://dpdk.org/doc/api/rte__malloc_8h.html#afb7316a4ec228ed9b8ffc1864b03d85b >> > >> (sizeof(*p)); ==> >> struct lcore_params *p = rte_malloc >> < >> http://dpdk.org/doc/api/rte__malloc_8h.html#afb7316a4ec228ed9b8ffc1864b03d85b >> >(NULL, >> sizeof(*p), 0); >> is enough ? >> > > Yes, malloc(sizeof(*p)) has an equivalent behavior to rte_malloc(NULL, > sizeof(*p), 0) > in the context of a DPDK application. > > Because I have problem and Segmentation fault (core dumped) ?? >> > > Could you provide more details of how to reproduce or could you try to > reproduce your problem using a very simple example like > examples/helloworld ? > > Sergio > > Thanks in advance, >> >> >> > -- M@hdi Mor@dm@nd B@die