From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by dpdk.space (Postfix) with ESMTP id 54DCEA05E9 for ; Sun, 17 Mar 2019 07:53:07 +0100 (CET) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 004172C54; Sun, 17 Mar 2019 07:53:05 +0100 (CET) Received: from EUR01-HE1-obe.outbound.protection.outlook.com (mail-eopbgr130072.outbound.protection.outlook.com [40.107.13.72]) by dpdk.org (Postfix) with ESMTP id D80062C16 for ; Sun, 17 Mar 2019 07:53:03 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=Mellanox.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=zN4rCw71pMwKwd7vtGNXQW840P2Bm+rDaiiur0MGdg4=; b=IXS2xi1FkvCJJ9QwcttgFlzFcjW5IOm1kjbLNxPTUsZzWP6TjBLqIHpUwI8vc5rSpjgsZ/cO+YZXnp1Sv7reJF6TzK8ijHiQulRkMrF2BAINDQRAcp9jKSjKOPpl9pIQ6I2VbVm8m3W9rC5r1RRAJCbmuryJoReP1CBu8HI8Ong= Received: from AM0PR0502MB4019.eurprd05.prod.outlook.com (52.133.39.139) by AM0PR0502MB3601.eurprd05.prod.outlook.com (52.133.46.154) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.1709.13; Sun, 17 Mar 2019 06:53:02 +0000 Received: from AM0PR0502MB4019.eurprd05.prod.outlook.com ([fe80::3cdc:e13a:204e:67a6]) by AM0PR0502MB4019.eurprd05.prod.outlook.com ([fe80::3cdc:e13a:204e:67a6%2]) with mapi id 15.20.1709.011; Sun, 17 Mar 2019 06:53:02 +0000 From: Matan Azrad To: Stephen Hemminger CC: "dev@dpdk.org" , "vpp-dev@lists.fd.io" Thread-Topic: [dpdk-dev] [RFC] net/vdev_netvsc: check for required related drivers Thread-Index: AQHU2bAb0HniiTRu/k+WmCuLSKsWwKYK+7DwgABMuYCABB120A== Date: Sun, 17 Mar 2019 06:53:02 +0000 Message-ID: References: <20190313151858.2175-1-stephen@networkplumber.org> <20190314085215.26c6daf0@shemminger-XPS-13-9360> In-Reply-To: <20190314085215.26c6daf0@shemminger-XPS-13-9360> Accept-Language: en-US, he-IL Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [193.47.165.251] x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: dcd6d432-c86c-499d-0967-08d6aaa53348 x-ms-office365-filtering-ht: Tenant x-microsoft-antispam: BCL:0; PCL:0; RULEID:(2390118)(7020095)(4652040)(8989299)(4534185)(4627221)(201703031133081)(201702281549075)(8990200)(5600127)(711020)(4605104)(4618075)(2017052603328)(7153060)(7193020); SRVR:AM0PR0502MB3601; x-ms-traffictypediagnostic: AM0PR0502MB3601: authentication-results: spf=none (sender IP is ) smtp.mailfrom=matan@mellanox.com; x-microsoft-antispam-prvs: x-forefront-prvs: 09796A1B83 x-forefront-antispam-report: SFV:NSPM; SFS:(10009020)(346002)(396003)(39850400004)(136003)(376002)(366004)(189003)(199004)(6116002)(74316002)(66066001)(186003)(478600001)(7736002)(6246003)(8936002)(14454004)(86362001)(99286004)(3846002)(97736004)(305945005)(2906002)(81156014)(486006)(476003)(6916009)(229853002)(11346002)(26005)(446003)(52536014)(76176011)(54906003)(102836004)(8676002)(316002)(6506007)(5660300002)(55016002)(9686003)(68736007)(25786009)(81166006)(105586002)(106356001)(256004)(71190400001)(71200400001)(6436002)(4326008)(7696005)(14444005)(33656002)(53936002); DIR:OUT; SFP:1101; SCL:1; SRVR:AM0PR0502MB3601; H:AM0PR0502MB4019.eurprd05.prod.outlook.com; FPR:; SPF:None; LANG:en; PTR:InfoNoRecords; MX:1; A:1; received-spf: None (protection.outlook.com: mellanox.com does not designate permitted sender hosts) x-ms-exchange-senderadcheck: 1 x-microsoft-antispam-message-info: 42RjLBiqZL4qy3xGs4eHILpNcFg66jsRq+qnjEfNJpqExIYp9OWob7QLcESobMaDgfqP75r//wN+cIqWlcbiUULowrrOHuIUpW3SpcK/dEKkbMmx2nuY+KLw2Qu3e+TQf3Q8MPH4dLX3Tu6mJ60IRhCSoIBjvTAIqllSy6gwOOKiHpheZcxoV8CxM678SyUA9zV90n8rFcF9BCbUo0fL/Y9ODoc4YflhK6ScfOdJrEpDE+zgstwBn2yudIQvWE7QQyNLNnr93cqatNsKkTNb4WT9+B80F96etsgX37L36INQct9kfN32NcovVgeYtojZhlW4sESABD6Xet/kcz7WoEb2mqGivT9vGTGgjGCrMmEYXVwPiprju50+ncrJ9gzui2G7abrrsqAAJpF/O5hUQ3a/znhHKEXKOL0hUr8yBsw= Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-OriginatorOrg: Mellanox.com X-MS-Exchange-CrossTenant-Network-Message-Id: dcd6d432-c86c-499d-0967-08d6aaa53348 X-MS-Exchange-CrossTenant-originalarrivaltime: 17 Mar 2019 06:53:02.5388 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: a652971c-7d2e-4d9b-a6a4-d149256f461b X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM0PR0502MB3601 Subject: Re: [dpdk-dev] [RFC] net/vdev_netvsc: check for required related drivers X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" Message-ID: <20190317065302.mmUSPFAZTKZhP9yisrmTI97i2wfGs0kIjlhYNXKXTo4@z> Hi From: Stephen Hemminger > wrote: >=20 > > Hi > > > > From: Stephen Hemminger > > > The vdev_netvsc virtual driver that is used to do initialization on > > > Hyper- V/Azure won't work without failsafe and tap device. > > > If the related devices aren't present, it causes confusing errors > > > later in initialization when it crafts devargs and attempts to send > > > them to a device driver that isn't there. > > > > > > Unfortunately, this is common with VPP where the TAP and FAILSAFE > > > PMD's are both optional. The suggestion here is to detect this in > > > the startup phase earlier. > > > > > > Alternative would be to use RTE_BUILD_BUG_ON(!defined(...)) but that > > > would break people doing normal VPP build. > > > > > > > The failsafe and tap devices are created by the vdev_netvsc PMD, so it = is > not expected to find them in the scan time. > > If the VM doesn't want vdev_netvsc driver to run, it have 2 options: > > 1. assign IP to the netvsc netdevs. > > 2. run --vdev=3D"vdev_netvsc0,ignore=3D1" - see documentation for more = info. > > >=20 >=20 > How do we improve the error reporting for configurations that have run > Hyper-V/Azure but forget to build failsafe, tap or mlx5 device drivers. R= ight > now the error messages are confusing, misleading and waste significant > amount of developer time. >=20 > What solution do you propose? The DPDK build system is not as smart as > kernel Kconfig, there is no way to force dependencies. Why? Can't you condition the vdev_netvsc compilation in failsafe and tap compila= tion? 1 more option: To condition the vdev_netvsc automated probing (in vdev_netvsc_custom_scan_= add) by "ifdef" statement in failsafe and tap compilation existence. Moreover, you can add clearer massage for this case if vdev_netvsc is runni= ng (vdev_netvsc_vdev_probe). Matan. =20