From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id A4B72432BA; Mon, 6 Nov 2023 17:19:35 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 3497E402B1; Mon, 6 Nov 2023 17:19:35 +0100 (CET) Received: from mail-pl1-f171.google.com (mail-pl1-f171.google.com [209.85.214.171]) by mails.dpdk.org (Postfix) with ESMTP id CC3CA4025D for ; Mon, 6 Nov 2023 17:19:33 +0100 (CET) Received: by mail-pl1-f171.google.com with SMTP id d9443c01a7336-1cc58219376so42338585ad.1 for ; Mon, 06 Nov 2023 08:19:33 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20230601.gappssmtp.com; s=20230601; t=1699287573; x=1699892373; darn=dpdk.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:subject:cc:to:from:date:from:to:cc:subject:date :message-id:reply-to; bh=NWJsefkRgAIXKFNwLoGDPZZfSPPiAfOvX0k5GEexSuY=; b=x0aX3hDWWmhrrAcJ/Ozyb0LRjAAhw8YbU1wX5Jp3I4TI4rtc7XVc+JiOnbBXYOXcvy PMN6avUm3ck4Z10X17Wb5DCj53dNATOfw//Exwl7vLtzo00IZy1vlJWeyBKLvdTIsUly WHyoma357iZ57gNpGbuUBV/Hk1QsMVudYeikaS0HHzcFuCw3ALR1XIZUQJfC33GF+Ly/ oSdg/MCHNKTqI7Qqr/Jx5UYNcKyplqmmdem7pjKiGdMGZM1/hFAH9uGfXMk8ZGwr5BGg TV/oj2O0exOmvPq2N3xasSaAmsG2tKvEuRVSabpbq8iynF1ski7VsOsSSWKOkiV5EMb4 c/gg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1699287573; x=1699892373; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:subject:cc:to:from:date:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=NWJsefkRgAIXKFNwLoGDPZZfSPPiAfOvX0k5GEexSuY=; b=NDYwkup0tgnS/de2M13YwJFctDdAdmIJHg0hxrsySP4xYtsAq08dUe/Dp8x6chri0c Rx0tOvDIGK1MvxzLOvbbPX5XuZJp1BngjL/4svCRw9YMHg/RdRTBDzG6Enr/wpQR+YwC 5WBjtRit1XYwbFi5G84hfQdQF8226TIcBwOwtlpvW7/oHZ2wwsDnSdhEhm8AL8M08hUS FfEZetn585d+QJ3oEpKItqWIPxhItZgnuBr4HaLwf1b+ZJPavfIFkqp3VLb0RfTInn3c u8AJz9QHba19q6Z2D2FZ89+ArOdC8Z3BNhzGFa1F0NYHiOjXdM8X+2b3CJ9eJ5/HrQsk Zxsw== X-Gm-Message-State: AOJu0Yw5AeSSWKkwlSWoUTL0Ra9+Y84eGSDoso6SG1MokQLeAG0Pfksu tQ89/D9Ft2dXiFv41zHpoBgxSw== X-Google-Smtp-Source: AGHT+IF3SKukpkFRmeGa21LmcabcT7tQ/FsYZwdUPL/xh3nji+NpFYj8QdF6GlZocvXRmS6/Hf51HQ== X-Received: by 2002:a17:902:c406:b0:1cc:87a5:288 with SMTP id k6-20020a170902c40600b001cc87a50288mr16457726plk.29.1699287572627; Mon, 06 Nov 2023 08:19:32 -0800 (PST) Received: from hermes.local (204-195-123-141.wavecable.com. [204.195.123.141]) by smtp.gmail.com with ESMTPSA id g13-20020a170902c38d00b001c5eb2c4d8csm6059496plg.160.2023.11.06.08.19.32 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 06 Nov 2023 08:19:32 -0800 (PST) Date: Mon, 6 Nov 2023 08:19:30 -0800 From: Stephen Hemminger To: fengchengwen Cc: , , Subject: Re: [PATCH v4 1/5] kvargs: add one new process API Message-ID: <20231106081930.48004190@hermes.local> In-Reply-To: References: <20230314124813.39521-1-fengchengwen@huawei.com> <20231105054539.22303-1-fengchengwen@huawei.com> <20231105054539.22303-2-fengchengwen@huawei.com> <20231105191804.7fc675de@hermes.local> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org On Mon, 6 Nov 2023 15:13:35 +0800 fengchengwen wrote: > >> + > > > > Looks good but may I suggest some alternatives. > > > > Since this is an API and ABI change as was not announced, maybe a little late > > in the process for this release. And since unlikely to go in 23.11 need to do something > > better in 24.03. > > > > What about changing the args to rte_kvargs_process() to add an additional default > > value. Most callers don't have a default (use key-value) but the ones that take only-key > > would pass the default value. > > The API definition changed, it may need modify most drivers. > > Although it's a little late, better continue current. > > Thanks > Chengwen Looking ahead, I would like to replace all of EAL args and KVargs processing with something more like the python parseargs library. The API is cleaner and incorporating the help with arg parsing is a real benefit. Thomas also suggested integrating help in the arg parsing. Something like: https://github.com/cofyc/argparse