From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from EUR03-DB5-obe.outbound.protection.outlook.com (mail-eopbgr40088.outbound.protection.outlook.com [40.107.4.88]) by dpdk.org (Postfix) with ESMTP id E3FE458C4 for ; Thu, 13 Sep 2018 12:12:19 +0200 (CEST) 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=7W7/TAxcJd84CI6k0aZtqo6nd24AE49Sv/vkA0pf7r8=; b=nF4DUjNH9mLXyVWgah6rj6tb2vnmcrCnP/4TybBqbzO0xDdBozTi+c1/d6MtZbtAWHIhbNZsrXKDXXghLfzo9venxHDl2KaPyI+Mmei7axLpekaiskg1uAyizuKKiklt4wjqNfi/V6+AA/8qy2Q3x/MkTJ3rke9fKLle7ZggFho= Received: from DB7PR05MB4426.eurprd05.prod.outlook.com (52.134.109.15) by DB7PR05MB4379.eurprd05.prod.outlook.com (52.134.108.156) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.1122.16; Thu, 13 Sep 2018 10:12:18 +0000 Received: from DB7PR05MB4426.eurprd05.prod.outlook.com ([fe80::c8e7:d9c1:5054:693b]) by DB7PR05MB4426.eurprd05.prod.outlook.com ([fe80::c8e7:d9c1:5054:693b%6]) with mapi id 15.20.1122.020; Thu, 13 Sep 2018 10:12:18 +0000 From: Shahaf Shuler To: Bruce Richardson CC: =?iso-8859-1?Q?N=E9lio_Laranjeiro?= , Yongseok Koh , Matan Azrad , "bluca@debian.org" , "dev@dpdk.org" Thread-Topic: [dpdk-dev] [PATCH v5] net/mlx: add meson build support Thread-Index: AQHURpZizq0nHbBCHkyiGhH5oNKqZqTt+U0AgAAMTVA= Date: Thu, 13 Sep 2018 10:12:18 +0000 Message-ID: References: <9c646fc088242e679a3e4fda541f58674b064b1e.1535699721.git.nelio.laranjeiro@6wind.com> <20180905114746.117936-1-shahafs@mellanox.com> <20180907103429.GA12540@bricha3-MOBL.ger.corp.intel.com> <20180913092206.GA17576@bricha3-MOBL.ger.corp.intel.com> In-Reply-To: <20180913092206.GA17576@bricha3-MOBL.ger.corp.intel.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: authentication-results: spf=none (sender IP is ) smtp.mailfrom=shahafs@mellanox.com; x-originating-ip: [193.47.165.251] x-ms-publictraffictype: Email x-microsoft-exchange-diagnostics: 1; DB7PR05MB4379; 6:VJE64QaoqoSAKCzUfGh3LONUarvfWwiGI3A/tUSOLNVKNMLqgLpejcra1CDRPnZW8YCNS2VXAIzizT37UgNYBRiFeGsCnSrRCXjaSf+Ih3S0MSiTtL26XkhxdBuxV1VnZI6An/cK9Lw6ZQcalD7asjJhDA2bpkPcGVM82a+ZfBjJdapsSHxAxoJxgSsO0wQ61oq3AdNqKZqN4pW9lBoY7LXqn2Hq0jpPfpdxYRp6U2emjcHZckeRMF1GJamC1wDcN6IKq47e3+AO2MGA6VpV4V0G2VODDv+7RfK6t7fdtSLs/deWqnGQhmZ5zVeGai5cn5WSvPh032PdhkKkkyosL1zuPGn4SO5QpOYc77Niv/raqGz2pdDDGvUoOSi6qYLa79sy9XuleJyikFBh6RWGMXTYgk5avD4UoDmA9y7Ddu8jQnMYvNKiaI6gCP6Ut7PFxNLzfVReubm5yhJFiO72pQ==; 5:8maco3aG0zq7zOOU+HFeO5og0ychDd/McdXvWvXa9gWwIH6UvfwCUxLezxQl5/Ao3gM4WAtkpyAI9vswhVTM+Ymf4vcWBrbWP7z5aQOHYWwhs9HTaYoZbOxtSa2Rlv3d4DQH7zcvKjjxGyuYmlhyKyw7SDtXf+kxuc8vXSn7u7o=; 7:NMj39buX997jVjObTjGdU7sQtFLRNd2k+t2Gj5sIW/IXItHCiwMjTTO4C9SMaDdu+l2+Zel4xNBp2m6CzezmNahI0YK2F1LAmA0VQH0GVsk4X17+KXFkZPMpx8h2wuAZ4revLV5qzSI6qnYE6KwAXbpZJAkA3cWNXxjZw8oR84YHnx1Cn0q4yl0QnplDkWe0pmb7Rh6aFDB7BXgYdILTSVQv+8KOxwZJDujnmVfYvaq+k6JYuVdtkJ34CAGPPnaH x-ms-exchange-antispam-srfa-diagnostics: SOS; x-ms-office365-filtering-correlation-id: 02c964ff-d98f-46b7-a375-08d619616350 x-ms-office365-filtering-ht: Tenant x-microsoft-antispam: BCL:0; PCL:0; RULEID:(7020095)(4652040)(8989137)(4534165)(4627221)(201703031133081)(201702281549075)(8990107)(5600074)(711020)(4618075)(2017052603328)(7153060)(7193020); SRVR:DB7PR05MB4379; x-ms-traffictypediagnostic: DB7PR05MB4379: x-ld-processed: a652971c-7d2e-4d9b-a6a4-d149256f461b,ExtAddr x-microsoft-antispam-prvs: x-exchange-antispam-report-test: UriScan:(189930954265078)(45079756050767); x-ms-exchange-senderadcheck: 1 x-exchange-antispam-report-cfa-test: BCL:0; PCL:0; RULEID:(8211001083)(6040522)(2401047)(5005006)(8121501046)(823301075)(93006095)(93001095)(3231311)(944501410)(52105095)(3002001)(10201501046)(6055026)(149027)(150027)(6041310)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(20161123560045)(20161123564045)(20161123562045)(20161123558120)(201708071742011)(7699050); SRVR:DB7PR05MB4379; BCL:0; PCL:0; RULEID:; SRVR:DB7PR05MB4379; x-forefront-prvs: 07943272E1 x-forefront-antispam-report: SFV:NSPM; SFS:(10009020)(136003)(396003)(346002)(376002)(39860400002)(366004)(189003)(199004)(68736007)(102836004)(6246003)(4326008)(93886005)(6506007)(6916009)(186003)(316002)(26005)(8936002)(6436002)(3846002)(33656002)(81166006)(6116002)(99286004)(229853002)(81156014)(53936002)(9686003)(6306002)(55016002)(97736004)(5250100002)(25786009)(14454004)(7696005)(8676002)(5660300001)(305945005)(7736002)(476003)(2906002)(45080400002)(54906003)(14444005)(256004)(2900100001)(106356001)(11346002)(966005)(74316002)(446003)(575784001)(66066001)(86362001)(478600001)(486006)(76176011)(105586002); DIR:OUT; SFP:1101; SCL:1; SRVR:DB7PR05MB4379; H:DB7PR05MB4426.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-microsoft-antispam-message-info: f+TvjTQs+7PdTxMXarKIe4SptFpNSeKi6DNMouKF49EZTx3tCpuLiRBq8BHkYpuU4PFc/EGKyLbejhJyb3z+3GBCVGA6VUmnCtWR6VtmkkZmM3kZfIj6gidKAZKG8fSUEyxcvx8bp9JGjkeuiy5WW+94GAn/bV4OiuYkKmsxdF052CWwShUOOJQePh04r+Jyzr8PLgIJkRWI21tujRSrwLqxuky02uV5M1NzSwnrYixABG+A6A6fVjM1GNIsSYCDQdMR32OTrd3njbrr7xmh26IsfP05tFEkcwTEnbOaHekCwup2GjnaJMWTY0SyV98lXQNy/IohyW9hFlHrkuodcg1KpcfaleligsPXRnuORWU= spamdiagnosticoutput: 1:99 spamdiagnosticmetadata: NSPM Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-OriginatorOrg: Mellanox.com X-MS-Exchange-CrossTenant-Network-Message-Id: 02c964ff-d98f-46b7-a375-08d619616350 X-MS-Exchange-CrossTenant-originalarrivaltime: 13 Sep 2018 10:12:18.7754 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: a652971c-7d2e-4d9b-a6a4-d149256f461b X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB7PR05MB4379 Subject: Re: [dpdk-dev] [PATCH v5] net/mlx: add meson build support 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: , X-List-Received-Date: Thu, 13 Sep 2018 10:12:20 -0000 Hi Bruce, Sorry for the late reply. Holiday time in Israel.=20 Thursday, September 13, 2018 12:22 PM, Bruce Richardson: > Subject: Re: [dpdk-dev] [PATCH v5] net/mlx: add meson build support >=20 > On Fri, Sep 07, 2018 at 11:34:29AM +0100, Bruce Richardson wrote: > > On Wed, Sep 05, 2018 at 02:47:46PM +0300, Shahaf Shuler wrote: > > > From: Nelio Laranjeiro [...] > > couple of minor points: > > * These new additions use tab rather than space for indent. The standar= d > > with meson I think is normally spaces, but I (inadvertently) added al= l > > other DPDK meson.build files with tabs, so for consistency I think it > > would be good if the whole file used tabs i.e. change all the other l= ines > > apart from your new ones in v5. OK, all indentation will be with tab. =20 > > > > * is the "rm" command really necessary? I would expect the > configure_file() > > function to just do the right thing here when replacing the file. Yep it is not needed. Also from meson sources: output =3D kwargs['output'] = =20 ofile_rpath =3D os.path.join(self.subdir, output) = =20 if not isinstance(output, str): = =20 raise InterpreterException('Output file name must be a string')= =20 if ofile_rpath in self.configure_file_outputs: = =20 mesonbuildfile =3D os.path.join(self.subdir, 'meson.build') = =20 current_call =3D "{}:{}".format(mesonbuildfile, self.current_li= neno) =20 first_call =3D "{}:{}".format(mesonbuildfile, self.configure_fi= le_outputs[ofile_rpath]) =20 mlog.warning('Output file', mlog.bold(ofile_rpath, True), 'for = configure_file() at', current_call, 'o verwrites configure_file() output at', first_call) = =20 > > > > * Would you consider splitting the args array into two arrays, one for = the > > "type" values and another for the enum/define ones? This would mean > > having two loops, but the loops themselves would be clearer and short= er - > > as would the arrays. Especially since according to > > > https://emea01.safelinks.protection.outlook.com/?url=3Dhttp%3A%2F%2Fmes > onbuild.com%2FConfiguration.html&data=3D02%7C01%7Cshahafs%40mell > anox.com%7C38f62333815c48eaea6e08d6195a908a%7Ca652971c7d2e4d9ba6 > a4d149256f461b%7C0%7C0%7C636724274091500993&sdata=3DfZvTg16D8K > TsE7Q0DWsS9hiNnB%2BhHPuHi%2FFC7wrk8x8%3D&reserved=3D0 > > a boolean false converts to an "undef", rather than a 0/1 value. > > For example: > > > > foreach arg:has_sym_args > > config.set(arg[0], cc.has_header_symbol(arg[1], arg[3])) > > endforeach > > Done. > > * Very minor suggestion: is it neater to use "args: '-include ' + arg[1= ]", > > instead of using prefix with the #include syntax? [Assuming the forme= r > > works] I don't understand the benefit with this change. Is there?=20 > > >=20 > Any plans for a new version of this? If so, can I also suggest splitting = the patch > into two, one for mlx4 and the other for mlx5. No problem to split. Another change in plans:=20 diff --git a/meson_options.txt b/meson_options.txt index 484f3e2601..444a380d97 100644 --- a/meson_options.txt +++ b/meson_options.txt @@ -1,7 +1,7 @@ option('allow_invalid_socket_id', type: 'boolean', value: false, description: 'allow out-of-range NUMA socket id\'s for platforms th= at don\'t report the value correctly') option('enable_driver_mlx_glue', type: 'boolean', value: false, - description: 'Enable glue library for Mellanox ConnectX-3/4/5 NIC P= MD') + description: 'Enable glue library for Mellanox PMDs') option('enable_kmods', type: 'boolean', value: true, description: 'build kernel modules') option('examples', type: 'string', value: '', I don't see the need to constantly update with each device being added. =20 >=20 > Regards, > /Bruce