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 BF07943FB9; Sun, 5 May 2024 21:43:08 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 8EBB8400EF; Sun, 5 May 2024 21:43:08 +0200 (CEST) Received: from mail-oa1-f44.google.com (mail-oa1-f44.google.com [209.85.160.44]) by mails.dpdk.org (Postfix) with ESMTP id C058840041 for ; Sun, 5 May 2024 21:43:07 +0200 (CEST) Received: by mail-oa1-f44.google.com with SMTP id 586e51a60fabf-23f29557e5dso719354fac.3 for ; Sun, 05 May 2024 12:43:07 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1714938187; x=1715542987; darn=dpdk.org; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=E+xN5CbTRmF/T8wnfkqa6teC3UD+ox8iEBYBDqwlbhs=; b=GWNByitbc/PMpjz0Ny9QbKHpRxkAb0DzcmAYNDyuYIAuAeO9IvoupWUdUVY4MAovdi 4O/jgOXDmWNkgcXvLYrc//A7auJLfaCx97pHTjx+CgmQ3jCw3QVDYpmphswPPfMlujeQ EZJmfOoPmkXL5Flct4cKFNN8pkSQ4rZdNa556773VWIBqDxKhD700vPMBpyd7/rhkHuI Y3rA9YnRLjizDCWyPE+zKQ6UEEqCn1TjNbIPjUqi8y9sbXs+C2tgYokaCV6fXFctvGbw lTgdP5iPlVzF7rD5WosMms/EDWu3bsbXzluNLTh+hjX3QF+ojOJtLqfd1vEqOe6daadB OMMQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1714938187; x=1715542987; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=E+xN5CbTRmF/T8wnfkqa6teC3UD+ox8iEBYBDqwlbhs=; b=TTvbdKAgDL+gj9hkr3b/AUHk4EkpK71NQVWIGFHKcxsQ6gyxvx4kh5ozsPV/5488d0 /akuAG1lUbAkpSe5lJJWS1VLpYvLjJGVNQdK/ADJ2tc+CJem6DKPSjP598f2051KBK5Q DDkER+RlSXogj3oTV0lJZVheA1+9L+1s98MZZ4E6dYOG8wC/ry5mpNg2FXXZOFQk4rcM XAD0p07oRVzrk8swiZZF9b0am8xN7za353IMAD1dhh0BBZRvcA6woCIK8mGpAGcuaD+S esTWNlHUwiHreqCPet99L634/IhF7IcUwl5DdeCCQAfjfxTNEVYFlYpJGe+NdW91MtKa e8qQ== X-Gm-Message-State: AOJu0Yz+WgjvlQYn+RlFE+st0wX62mlPvYT1rpv5cn6UrmLNXIv7uQJR rYOq/k5RqN5dE5jEsXNNk5rw7X7AmUx1+NqK1xV8uxWKXa2tXiCnjvwWd6JABnKR+/gi1IyDo8h dxuk1jOwZQsIguGsWJ7qpQq7XMU43zArvhb0= X-Google-Smtp-Source: AGHT+IFcqN0LJFBuNiA6VEaTTk4xGHAITC5+0AZr2uPcRRviRFr3ISfK3Uszo/5jqcIxROKmTHqV28ZGpL4knksajPU= X-Received: by 2002:a05:6871:33a9:b0:23c:b686:f5a with SMTP id ng41-20020a05687133a900b0023cb6860f5amr10167739oac.49.1714938187029; Sun, 05 May 2024 12:43:07 -0700 (PDT) MIME-Version: 1.0 References: <20240504191837.1096185-1-aomeryamac@gmail.com> <20240505092059.69486f4e@hermes.local> In-Reply-To: <20240505092059.69486f4e@hermes.local> From: =?UTF-8?B?QWJkdWxsYWggw5ZtZXIgWWFtYcOn?= Date: Sun, 5 May 2024 22:42:57 +0300 Message-ID: Subject: Re: [PATCH v3] devtools: add .clang-format file To: Stephen Hemminger Cc: dev@dpdk.org Content-Type: multipart/alternative; boundary="00000000000073243e0617ba2979" 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 --00000000000073243e0617ba2979 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Sun, May 5, 2024 at 7:21=E2=80=AFPM Stephen Hemminger wrote: > On Sat, 4 May 2024 19:18:37 +0000 > Abdullah =C3=96mer Yama=C3=A7 wrote: > > > clang-format is a tool to format C/C++/Objective-C code. It can be used > > to reformat code to match a given coding style, or to ensure that code > > adheres to a specific coding style. It helps to maintain a consistent > > coding style across the DPDK codebase. > > > > .clang-format file overrides the default style options provided by > > clang-format and large set of IDEs and text editors support it. > > > > Signed-off-by: Abdullah =C3=96mer Yama=C3=A7 > > Also, this looks wrong. The initialized arrays looked better before. > > > -static const char *tuntap_types[ETH_TUNTAP_TYPE_MAX] =3D { > - "UNKNOWN", "TUN", "TAP" > -}; > +static const char *tuntap_types[ETH_TUNTAP_TYPE_MAX] =3D {"UNKNOWN", "TU= N", > "TAP"}; > > -static const char *valid_arguments[] =3D { > - ETH_TAP_IFACE_ARG, > - ETH_TAP_REMOTE_ARG, > - ETH_TAP_MAC_ARG, > - ETH_TAP_PERSIST_ARG, > - NULL > -}; > +static const char *valid_arguments[] =3D {ETH_TAP_IFACE_ARG, > ETH_TAP_REMOTE_ARG, ETH_TAP_MAC_ARG, > + ETH_TAP_PERSIST_ARG, NULL}; > I am confused about these variables. tuntap_types list values in a single line, but valid_arguments' values are listed separately. So, it is getting more complex to handle both of them. What should we do, do you have any idea? --00000000000073243e0617ba2979 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable


=
On Sun, May 5, 2024 at 7:21=E2=80=AFP= M Stephen Hemminger <steph= en@networkplumber.org> wrote:
On Sat,=C2=A0 4 May 2024 19:18:37 +0000
Abdullah =C3=96mer Yama=C3=A7 <aomeryamac@gmail.com> wrote:

> clang-format is a tool to format C/C++/Objective-C code. It can be use= d
> to reformat code to match a given coding style, or to ensure that code=
> adheres to a specific coding style. It helps to maintain a consistent<= br> > coding style across the DPDK codebase.
>
> .clang-format file overrides the default style options provided by
> clang-format and large set of IDEs and text editors support it.
>
> Signed-off-by: Abdullah =C3=96mer Yama=C3=A7 <aomeryamac@gmail.com>

Also, this looks wrong.=C2=A0 The initialized arrays looked better before.<= br>

-static const char *tuntap_types[ETH_TUNTAP_TYPE_MAX] =3D {
-=C2=A0 =C2=A0 =C2=A0 =C2=A0"UNKNOWN", "TUN", "TAP= "
-};
+static const char *tuntap_types[ETH_TUNTAP_TYPE_MAX] =3D {"UNKNOWN&qu= ot;, "TUN", "TAP"};

-static const char *valid_arguments[] =3D {
-=C2=A0 =C2=A0 =C2=A0 =C2=A0ETH_TAP_IFACE_ARG,
-=C2=A0 =C2=A0 =C2=A0 =C2=A0ETH_TAP_REMOTE_ARG,
-=C2=A0 =C2=A0 =C2=A0 =C2=A0ETH_TAP_MAC_ARG,
-=C2=A0 =C2=A0 =C2=A0 =C2=A0ETH_TAP_PERSIST_ARG,
-=C2=A0 =C2=A0 =C2=A0 =C2=A0NULL
-};
+static const char *valid_arguments[] =3D {ETH_TAP_IFACE_ARG, ETH_TAP_REMOT= E_ARG, ETH_TAP_MAC_ARG,
+=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2= =A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0ETH_TAP_P= ERSIST_ARG, NULL};

I am confused about these varia= bles.=C2=A0 tuntap_types list values in a single line, but valid_arguments&= #39; values are listed separately.
So, it is getting more complex= to handle both of them. What should we do, do you have any idea?
--00000000000073243e0617ba2979--