From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id 5358FA04DD for ; Tue, 20 Oct 2020 11:02:53 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 2E768BBD2; Tue, 20 Oct 2020 11:01:45 +0200 (CEST) Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [63.128.21.124]) by dpdk.org (Postfix) with ESMTP id EBF8CAD33 for ; Tue, 20 Oct 2020 11:01:40 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1603184499; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=b0Jk5LMjUL/Nug9O2TbfCLb6zXHAcNBpCLS+bffonQo=; b=VlQ0Kzes9MqDPLgs29mgoyUYL7iLzYn7eIj4o4mhOdCk/fa71gkxz7ynBWsUXQcc9k8cTW IyVAEqdYAT/oO/FDoe/8w76T9OGbya6JfrmR6W2KsGeqPamWouqtc0epRt4kJGVFCWVskM wyQHhUEl411KTuVz2APoc64um65eahg= Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-488-M18F_IxDNtyBdhCKDhnQ6g-1; Tue, 20 Oct 2020 05:01:35 -0400 X-MC-Unique: M18F_IxDNtyBdhCKDhnQ6g-1 Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.phx2.redhat.com [10.5.11.16]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 7654E8049D7; Tue, 20 Oct 2020 09:01:34 +0000 (UTC) Received: from [10.33.36.223] (unknown [10.33.36.223]) by smtp.corp.redhat.com (Postfix) with ESMTP id 25C5A5C1A3; Tue, 20 Oct 2020 09:01:28 +0000 (UTC) To: Adrian Moreno , dev@dpdk.org Cc: yinan.wang@intel.com, patrick.fu@intel.com, stable@dpdk.org, Maxime Coquelin , Chenbo Xia , Zhihong Wang References: <20201020071628.323641-1-amorenoz@redhat.com> From: Kevin Traynor Message-ID: Date: Tue, 20 Oct 2020 10:01:27 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.3.1 MIME-Version: 1.0 In-Reply-To: <20201020071628.323641-1-amorenoz@redhat.com> X-Scanned-By: MIMEDefang 2.79 on 10.5.11.16 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=ktraynor@redhat.com X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 8bit Subject: Re: [dpdk-stable] [dpdk-dev] [PATCH] virtio-user: fix backend selection if stat fails X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches for DPDK stable branches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: stable-bounces@dpdk.org Sender: "stable" On 20/10/2020 08:16, Adrian Moreno wrote: > If stat fails it means the backend must be vhost-user in server mode > > Bugzilla ID: 559 > Fixes: f908b22ea47a ("net/virtio: move backend type selection to ethdev") > Cc: stable@dpdk.org > > Signed-off-by: Adrian Moreno > --- > drivers/net/virtio/virtio_user_ethdev.c | 5 +++-- > 1 file changed, 3 insertions(+), 2 deletions(-) > > diff --git a/drivers/net/virtio/virtio_user_ethdev.c b/drivers/net/virtio/virtio_user_ethdev.c > index 042665bc0..ce74d08ab 100644 > --- a/drivers/net/virtio/virtio_user_ethdev.c > +++ b/drivers/net/virtio/virtio_user_ethdev.c > @@ -560,9 +560,10 @@ virtio_user_backend_type(const char *path) > struct stat sb; > > if (stat(path, &sb) == -1) { > - PMD_INIT_LOG(ERR, "Stat fails: %s (%s)\n", path, > + PMD_INIT_LOG(INFO, "Stat fails: %s (%s)\n", path, > strerror(errno)); It may be accurate, but a 'fail' in the logs can be confusing for users when it is an INFO log and normal operation. Suggest to reword to something softer like 'Unable to stat' or 'Not able to get file status' > - return VIRTIO_USER_BACKEND_UNKNOWN; > + /* Must be vhost-user in server mode */ > + return VIRTIO_USER_BACKEND_VHOST_USER; > } > > if (S_ISSOCK(sb.st_mode)) { >