From: "Ouyang, Changchun" <changchun.ouyang@intel.com>
To: "Xie, Huawei" <huawei.xie@intel.com>, "dev@dpdk.org" <dev@dpdk.org>
Subject: Re: [dpdk-dev] [PATCH 1/3] vhost: add log if fails to bind a socket
Date: Fri, 3 Jul 2015 01:57:32 +0000 [thread overview]
Message-ID: <F52918179C57134FAEC9EA62FA2F962511BDEE6C@shsmsx102.ccr.corp.intel.com> (raw)
In-Reply-To: <C37D651A908B024F974696C65296B57B0F553871@SHSMSX101.ccr.corp.intel.com>
> -----Original Message-----
> From: Xie, Huawei
> Sent: Thursday, July 2, 2015 5:29 PM
> To: Ouyang, Changchun; dev@dpdk.org
> Cc: Cao, Waterman; Xu, Qian Q
> Subject: Re: [PATCH 1/3] vhost: add log if fails to bind a socket
>
> On 7/2/2015 11:33 AM, Ouyang, Changchun wrote:
> > It adds more readable log info if a socket fails to bind to local device file
> name.
> local socket file, not device file. :).
Make sense, will update it, thanks
> >
> > Signed-off-by: Changchun Ouyang <changchun.ouyang@intel.com>
> > ---
> > lib/librte_vhost/vhost_user/vhost-net-user.c | 5 ++++-
> > 1 file changed, 4 insertions(+), 1 deletion(-)
> >
> > diff --git a/lib/librte_vhost/vhost_user/vhost-net-user.c
> b/lib/librte_vhost/vhost_user/vhost-net-user.c
> > index 87a4711..f406a94 100644
> > --- a/lib/librte_vhost/vhost_user/vhost-net-user.c
> > +++ b/lib/librte_vhost/vhost_user/vhost-net-user.c
> > @@ -122,8 +122,11 @@ uds_socket(const char *path)
> > un.sun_family = AF_UNIX;
> > snprintf(un.sun_path, sizeof(un.sun_path), "%s", path);
> > ret = bind(sockfd, (struct sockaddr *)&un, sizeof(un));
> > - if (ret == -1)
> > + if (ret == -1) {
> > + RTE_LOG(ERR, VHOST_CONFIG, "fail to bind fd:%d, remove
> file:%s and try again.\n",
> > + sockfd, path);
> > goto err;
> > + }
> > RTE_LOG(INFO, VHOST_CONFIG, "bind to %s\n", path);
> >
> > ret = listen(sockfd, MAX_VIRTIO_BACKLOG);
next prev parent reply other threads:[~2015-07-03 1:58 UTC|newest]
Thread overview: 22+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-07-02 3:33 [dpdk-dev] [PATCH 0/3] Fix vhost startup issue Ouyang Changchun
2015-07-02 3:33 ` [dpdk-dev] [PATCH 1/3] vhost: add log if fails to bind a socket Ouyang Changchun
2015-07-02 9:29 ` Xie, Huawei
2015-07-03 1:57 ` Ouyang, Changchun [this message]
2015-07-02 9:31 ` Xie, Huawei
2015-07-02 3:33 ` [dpdk-dev] [PATCH 2/3] vhost: fix the comments and log Ouyang Changchun
2015-07-02 9:25 ` Xie, Huawei
2015-07-03 1:55 ` Ouyang, Changchun
2015-07-02 9:32 ` Xie, Huawei
2015-07-02 3:33 ` [dpdk-dev] [PATCH 3/3] vhost: call api to unregister vhost driver Ouyang Changchun
2015-07-02 9:38 ` Xie, Huawei
2015-07-03 2:03 ` Ouyang, Changchun
2015-07-02 16:04 ` Xie, Huawei
2015-07-03 2:04 ` Ouyang, Changchun
2015-07-06 2:26 ` [dpdk-dev] [PATCH v2 0/3] Fix vhost startup issue Ouyang Changchun
2015-07-06 2:26 ` [dpdk-dev] [PATCH v2 1/3] vhost: add log when failing to bind a socket Ouyang Changchun
2015-07-06 2:26 ` [dpdk-dev] [PATCH v2 2/3] vhost: fix the comments and log Ouyang Changchun
2015-07-06 2:26 ` [dpdk-dev] [PATCH v2 3/3] vhost: call api to unregister vhost driver Ouyang Changchun
2015-07-06 8:09 ` [dpdk-dev] [PATCH v2 0/3] Fix vhost startup issue Xu, Qian Q
2015-07-07 2:31 ` Ouyang, Changchun
2015-07-10 14:20 ` Xie, Huawei
2015-07-17 13:13 ` Thomas Monjalon
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=F52918179C57134FAEC9EA62FA2F962511BDEE6C@shsmsx102.ccr.corp.intel.com \
--to=changchun.ouyang@intel.com \
--cc=dev@dpdk.org \
--cc=huawei.xie@intel.com \
/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).