dev.dpdk.org archive mirror
 help / color / mirror / Atom feed
From: Jyotiswarup Raiturkar <jyotisr5-gM/Ye1E23mwN+BqQ9rBEUg@public.gmane.org>
To: "dev-VfR2kkLFssw@public.gmane.org" <dev-VfR2kkLFssw@public.gmane.org>
Cc: Jyotiswarup Raiturkar
	<jyoti-kcDrbOQDZCdv6pq1l3V1OdBPR1lH4CV8@public.gmane.org>
Subject: couple of minor compilation errors in DPDK 1.6 (/lib/librte_eal/linuxapp/eal/eal_ivshmem.c)
Date: Tue, 4 Feb 2014 09:02:39 +0530	[thread overview]
Message-ID: <CAJn5u1=yv2izSpVJXKR7HyXHbtNOmqMSey6cEkWGQLAaBfEd_A@mail.gmail.com> (raw)

Hi

I downloaded DPDK 1.6 from the Intel website and ran into couple of
compilation errors with /lib/librte_eal/linuxapp/eal/eal_ivshmem.c. The
following changes seem to fix it.  Have other people seen these?

Thanks
Jyoti


@@ -472,7 +472,7 @@
  rte_snprintf(path, sizeof(path), IVSHMEM_CONFIG_PATH,
  internal_config.hugefile_prefix);

- fd = open(path, O_CREAT | O_RDWR);
+ fd = open(path, O_CREAT | O_RDWR, S_IRWXU | S_IRWXG | S_IRWXO );

  if (fd < 0) {
  RTE_LOG(ERR, EAL, "Could not open %s: %s\n", path, strerror(errno));
@@ -486,7 +486,8 @@
  return -1;
  }

- ftruncate(fd, sizeof(struct ivshmem_shared_config));
+ if (ftruncate(fd, sizeof(struct ivshmem_shared_config))) {
+                close(fd); return -1;
+      }

  ivshmem_config = mmap(NULL, sizeof(struct ivshmem_shared_config),
  PROT_READ | PROT_WRITE, MAP_SHARED, fd, 0);

             reply	other threads:[~2014-02-04  3:32 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-02-04  3:32 Jyotiswarup Raiturkar [this message]
2014-02-04 11:23 ` FW: couple of minor compilation errors in DPDK 1.6 (/lib/librte_eal/linuxapp/eal/eal_ivshmem.c) Burakov, Anatoly

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='CAJn5u1=yv2izSpVJXKR7HyXHbtNOmqMSey6cEkWGQLAaBfEd_A@mail.gmail.com' \
    --to=jyotisr5-gm/ye1e23mwn+bqq9rbeug@public.gmane.org \
    --cc=dev-VfR2kkLFssw@public.gmane.org \
    --cc=jyoti-kcDrbOQDZCdv6pq1l3V1OdBPR1lH4CV8@public.gmane.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).