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 74FBDA0524; Fri, 5 Feb 2021 15:08:16 +0100 (CET) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id DEE2040682; Fri, 5 Feb 2021 15:08:15 +0100 (CET) Received: from mail-lj1-f169.google.com (mail-lj1-f169.google.com [209.85.208.169]) by mails.dpdk.org (Postfix) with ESMTP id 8935F4067B for ; Fri, 5 Feb 2021 15:08:14 +0100 (CET) Received: by mail-lj1-f169.google.com with SMTP id a25so7934955ljn.0 for ; Fri, 05 Feb 2021 06:08:14 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:from:to:cc:subject:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=oeHUYLi/YcMuoasymRrNC6aZ46YudPsJSbEy6bJwKDo=; b=JoVKUUr0KJsIkQCLtOvExUm3gk5EfgctCduz+LzIkiavtLPFsbYTgWs1LoyggXD0gG cr8MQUKEffWxZA/yF3P6hpEsBS4japnzvu2JsZE+zS5nnvttknfInn/MPCEiqiNes08D 9EioBBZxPp5RRdKEmdEQIF4TbEtNZWJjyduoZR5n22UAB2+NKfx1n7VN2mSVgusFvdH0 m+Q41ttcJ4kXpeeqA2zG+H8mCrdnIVGgIqTFcd2JNMvY2q60DAX5UpTdlXhSghwx7GMu U5xYHUz1CYQx2KWPqSrbH4Rb1GnMMhqiibYuODekHdwN6AFXDGRzYgahwkMfCWL/l8tD m8Vg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=oeHUYLi/YcMuoasymRrNC6aZ46YudPsJSbEy6bJwKDo=; b=qch1nSEnIMaYWmswIhnT4waSKvG9k0bmnfNKmNYtyd1cxHCR+sjI0bCqXUYdm/spaB 41uky9UP8eVPspX4tPUufcMmAXdGZD9wpvaT48IV/e26LAKtbNw6ybqesWKCkhGwKSdH VP7kfFPf2w85cawoWCaRBojdvT45NQdHjnam5ewSs2jqvhzBc7eQioi06pToKSTG07WZ 5/Gj4TKjuMim9y2WlgZJl/tvjX3Go8M6bVrRtqmE26uY69/awXbY3WVwzkdRLd+m6Qkd 4wigq/eiOYAdf9hRwjcsEj8k+ONkBCGcKyiS/kQBQ3eDE4R5xqDy1en84vo1tLIfbTWr 1jIw== X-Gm-Message-State: AOAM532RdClbvDDXWVV8V5rH8msvDE1g/2qqNHEoStBp+hmuZxsuI1En jYoEOl/jauIzIkn3IhHFaTA= X-Google-Smtp-Source: ABdhPJzBfvwYaBF89r1zxCEDD68K7NIFe1ESkIbcnB8wJVC7+TC8stsXmcfEGau6KXDm1FxrtOxi0w== X-Received: by 2002:a2e:854d:: with SMTP id u13mr2634132ljj.439.1612534094165; Fri, 05 Feb 2021 06:08:14 -0800 (PST) Received: from sovereign (broadband-37-110-65-23.ip.moscow.rt.ru. [37.110.65.23]) by smtp.gmail.com with ESMTPSA id z9sm1001414lfc.125.2021.02.05.06.08.12 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 05 Feb 2021 06:08:12 -0800 (PST) Date: Fri, 5 Feb 2021 17:08:11 +0300 From: Dmitry Kozlyuk To: Feng Li Cc: David Marchand , Li Feng , Narcisa Ana Maria Vasile , Dmitry Malloy , Pallavi Kadam , dev Message-ID: <20210205170811.46be3e3d@sovereign> In-Reply-To: References: <20210205112433.1681853-1-fengli@smartx.com> X-Mailer: Claws Mail 3.17.6 (GTK+ 2.24.32; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Subject: Re: [dpdk-dev] [PATCH] log: support custom log function 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 Sender: "dev" On Fri, 5 Feb 2021 20:22:36 +0800, Feng Li wrote: > David Marchand =E4=BA=8E2021=E5=B9=B42=E6=9C= =885=E6=97=A5=E5=91=A8=E4=BA=94 =E4=B8=8B=E5=8D=887:56=E5=86=99=E9=81=93=EF= =BC=9A > > > > On Fri, Feb 5, 2021 at 12:25 PM Li Feng wrote: =20 > > > > > > Currently, the dpdk log is out to stdout/stderr and syslog. > > > We should support to output the log to another please, e.g. file or > > > glog. =20 > > > > Why not use rte_openlog_stream() / rte_log_get_stream() ? > > > > > > -- > > David Marchand > > =20 > rte_openlog_stream seems it could set an external FILE* stream. > However, in the glog or C++ io stream, it's stream like std::cout. > I think it's hard to use a FILE* stream to unify them. Also, FILE* is not a language-agnostic interface. Rust/D/etc consumers can't use this API unless they obtain a FILE* from a compatible libc.