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 8D73E44028; Tue, 14 May 2024 09:57:00 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 5767C402D9; Tue, 14 May 2024 09:57:00 +0200 (CEST) Received: from mgamail.intel.com (mgamail.intel.com [192.198.163.12]) by mails.dpdk.org (Postfix) with ESMTP id 2E633402AE for ; Tue, 14 May 2024 09:56:57 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1715673418; x=1747209418; h=date:from:to:cc:subject:message-id:references: content-transfer-encoding:in-reply-to:mime-version; bh=Z5+4KCz7uHH7wGUCeqiIrN/wXCDJCCjPzQC9PCMasMg=; b=LaSInmbV9w8jxVqrN3C7AkdjFEGkAaIk1NEdjGCvpJrZG1Y3pVtwk71j GfWI0JOBgiC1B3OvM7NYzyqbIK/uT2mqEVVxcjYr9OWqAc7+h+fx/MtoC OK4KKvz+zDxhZQqN6riN+WAd1Ei7cv79fI6fYZoVxxfO2w0zY8kNFrr8X uPAD/iAVyDiDKUvQdbT8WGCXlx4sD5c5rmQoJtgnYElpdOfnrXVfqDbSd x/WL8mvxX/t25O/Rke9vAT5YC1sVSvWczsih8jOyEH1RKSWyr/8T0hMU+ eZEYWmHWb6FxMpuwnjZazghyQIKT/2xxzQOFIO3yWA5Lyy6lmPgvdQVcZ w==; X-CSE-ConnectionGUID: kqZpkTe5Sg++S4jmjT4A5w== X-CSE-MsgGUID: SgrsI68fSfqpcwuFksJRdw== X-IronPort-AV: E=McAfee;i="6600,9927,11072"; a="15460831" X-IronPort-AV: E=Sophos;i="6.08,159,1712646000"; d="scan'208";a="15460831" Received: from orviesa006.jf.intel.com ([10.64.159.146]) by fmvoesa106.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 14 May 2024 00:56:57 -0700 X-CSE-ConnectionGUID: 8TIQACdnT9SiQFbqo9pxUg== X-CSE-MsgGUID: tZD9cP9QQXeceyTQySIf2g== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.08,159,1712646000"; d="scan'208";a="31003907" Received: from fmsmsx603.amr.corp.intel.com ([10.18.126.83]) by orviesa006.jf.intel.com with ESMTP/TLS/AES256-GCM-SHA384; 14 May 2024 00:56:56 -0700 Received: from fmsmsx603.amr.corp.intel.com (10.18.126.83) by fmsmsx603.amr.corp.intel.com (10.18.126.83) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.35; Tue, 14 May 2024 00:56:55 -0700 Received: from FMSEDG603.ED.cps.intel.com (10.1.192.133) by fmsmsx603.amr.corp.intel.com (10.18.126.83) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.35 via Frontend Transport; Tue, 14 May 2024 00:56:55 -0700 Received: from NAM10-MW2-obe.outbound.protection.outlook.com (104.47.55.100) by edgegateway.intel.com (192.55.55.68) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.1.2507.35; Tue, 14 May 2024 00:56:55 -0700 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=ENZCUlPqKad00TGenL0cQakNlA0m/87e1fkR5AYnL+E5Qydp5G4SaK4d5yVL3t0XC6DT4NpPqd8KlKM6XbZtbBnB95IzR/YNZrjOAXBIlV7O8gyD6nDAWiaFRDE2w6sJgJMb7lyIK/3ItRe6QTf+cHizjpT1EwK+hL58qk7h5+IWRNSmZdiRjbxBWvqa7n+gU8L9lxNumMKh2WuaD6VlPQ2jklcDnbiELvXGGveX0pUCgaG8RYBxckdsKWiLIdb8tx7bWI4AHRorkIO1RW54cu263gQel5w4W8ddZVzMT6zbMSnlMkBF/fYYzZ6z1SEDf+fgRPiC+D31X8paO6YjzQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=gJhhdByz0YtDgOS88UskfD8ZtDNVNoiUVHVbsgInrmk=; b=lAeIfyN+aLpBYQGZTp5qlgo1iOO2YeaUWxZy5ZyfrM7/UC/2uzX3Dt+IKNOzGVol1Lw62rDh/rcael5XedQ4NHL5U9Dm7BW0fm5iCA/LosUOtCZo150uNkDL5Uq80ok0lhMmzKG+gLUfMSzyC3pFxDtRTmkQwpD0zWBuHeUgzbplCJFAOdwhMB6MQ96LB9xdkHAYjO40Kz1Pl6po9sCCckWxOqboRwOXpSphmGptffEdo5Kn48qiIZXh//f0i5hrxJ5fUIabKFub3IXw3577+Nc5c0b5zdhUguxNJUlgM4xU+h9Se8qrlR0ih1582Rpb1OBlxyVnu71S7LX7oqz1eA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=intel.com; dmarc=pass action=none header.from=intel.com; dkim=pass header.d=intel.com; arc=none Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=intel.com; Received: from DS0PR11MB7309.namprd11.prod.outlook.com (2603:10b6:8:13e::17) by MN0PR11MB6057.namprd11.prod.outlook.com (2603:10b6:208:375::9) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7544.55; Tue, 14 May 2024 07:56:54 +0000 Received: from DS0PR11MB7309.namprd11.prod.outlook.com ([fe80::69f8:59bf:3efd:9ee6]) by DS0PR11MB7309.namprd11.prod.outlook.com ([fe80::69f8:59bf:3efd:9ee6%3]) with mapi id 15.20.7587.025; Tue, 14 May 2024 07:56:53 +0000 Date: Tue, 14 May 2024 08:56:49 +0100 From: Bruce Richardson To: Morten =?iso-8859-1?Q?Br=F8rup?= CC: Stephen Hemminger , Ferruh Yigit , Abdullah =?iso-8859-1?Q?=D6mer_Yama=E7?= , Subject: Re: [PATCH v4] devtools: add .clang-format file Message-ID: References: <20240508211934.1143124-1-aomeryamac@gmail.com> <20240513085517.5e572880@hermes.local> <98CBD80474FA8B44BF855DF32C47DC35E9F449@smartserver.smartshare.dk> Content-Type: text/plain; charset="iso-8859-1" Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <98CBD80474FA8B44BF855DF32C47DC35E9F449@smartserver.smartshare.dk> X-ClientProxiedBy: DUZPR01CA0350.eurprd01.prod.exchangelabs.com (2603:10a6:10:4b8::22) To DS0PR11MB7309.namprd11.prod.outlook.com (2603:10b6:8:13e::17) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: DS0PR11MB7309:EE_|MN0PR11MB6057:EE_ X-MS-Office365-Filtering-Correlation-Id: 909ed3b2-eec1-4cb1-ac84-08dc73eb6b6f X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0;ARA:13230031|376005|366007|1800799015; X-Microsoft-Antispam-Message-Info: =?iso-8859-1?Q?cAeeDwLqYYtHcoNYzxGq2F/Ro+Vfqqz+eh4rtLf69vUrIwrgZzBioSNc4I?= =?iso-8859-1?Q?kkNqbeRNnlXStfXaxc51uMl+PTFMJKXnPq5KyANDAO5u5WLgPrjqjeXSqn?= =?iso-8859-1?Q?4Ji5KvwAt2YD8SGMUzq25infsEPYDddVQrPYWhKIX/+XmmYP7OiKjVa782?= =?iso-8859-1?Q?FVMEMljdXqX0r2/YbpZXHjDq4i8Ot2wyeRB8X9JuyrO0S4k4JIKPYvWMEX?= =?iso-8859-1?Q?KmQCCfsJeRR/anc2QsNRt5jV0EmFvIkCWNR/cP69yZTTA4JCSS/SJuV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vkl+vVGbIy3s2c0pUMXWSD2jXSwiqDfVJQTbfqrKuhP2bvuWzt?= =?iso-8859-1?Q?WlkGJN47fMtmjwSuDMwpZnKbdNoNXQ3pelH/RuMpRdEAr+5IBN0XZTrOPr?= =?iso-8859-1?Q?lKLPtOIhpII8HMs+DKuIIE+XVm3ZRXgUkMI3HRCVux/jtTFBPgeAVxtG5N?= =?iso-8859-1?Q?TLivCxTpkCCck3NSAjrEhzGy2w=3D=3D?= X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:DS0PR11MB7309.namprd11.prod.outlook.com; PTR:; CAT:NONE; SFS:(13230031)(376005)(366007)(1800799015); DIR:OUT; SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?iso-8859-1?Q?OJzJMebKhgSDkdN1voljbUBbqhgSZzHdK3W3DDsdD1yiaE/3gToHWsZtmQ?= =?iso-8859-1?Q?T8xjy/GGFYSGGgQbH/Z4oqFbVMnqlNPHotifDWCNrsDmpsnPp4Xy3pI4Jd?= =?iso-8859-1?Q?3CBsuQnoiOmTcE91Jp6lOSzQloDnIAFLX94lYmSgXiMioBFKXygutW8kTT?= =?iso-8859-1?Q?m/RI591PlgHlW0LptvfM4lJLZiWDKMi42Mw7p2dnhLe5wAlKWjBHJ2vlQ9?= =?iso-8859-1?Q?R70IHhpxVpdM21/QTpVDgUOuJnBGsDjd13ExqCzp09Tq/6RcwxFjgftvv/?= =?iso-8859-1?Q?4c0FYkWl2gcFoNwwbKFgfeQxFM/DBtixH/OdbolIarT46caxs/v2UwNQiQ?= =?iso-8859-1?Q?eIbuNYf6uV7PBWMC/Ub2mmcqWWIoJedyWNpezjTuN3fLHiWK+8jfIv63+T?= =?iso-8859-1?Q?16p5hZHk5qIthJjihex20cabW55UU1PFTQwcTUqwNtHmCodP6JY/C40rFM?= =?iso-8859-1?Q?2hQ6bZ49HEK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-1?Q?YO5YbRVerjfsob1qcV1mxFEBjtat6fSr42w/yY+jHkXWjPnENwVQffAbPm?= =?iso-8859-1?Q?79HBgF+gnEhUmO1RSudvi2lIQ3vr3jAVZaxS6RyzZC0fg4KdJuJQ1KjnD2?= =?iso-8859-1?Q?cwPGL319jvzZuO9umv3iNTOiQ3i2YoXOPkz389Nsn3qe3nkxlMi1/iDucx?= =?iso-8859-1?Q?cxhPl47zqpaboeDGsh7Q+039MVmnsO2dbqPOGDuYoSHxMubLrbcGbdp5Nn?= =?iso-8859-1?Q?tIOG/Ka+qnuBXjpPyXzyxNIRqKOp7YK7qMxW6dIaIoPeH5WaLayVBgBw?= =?iso-8859-1?Q?=3D=3D?= X-MS-Exchange-CrossTenant-Network-Message-Id: 909ed3b2-eec1-4cb1-ac84-08dc73eb6b6f X-MS-Exchange-CrossTenant-AuthSource: DS0PR11MB7309.namprd11.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 14 May 2024 07:56:53.8552 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 46c98d88-e344-4ed4-8496-4ed7712e255d X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: LST/Kt/grreTI1RvGiBVT/ef7IYAhLSncWn4bo1Kar0kPVAI/rs4sHGlT0lgbUtAOjZYWe06RDea/Qg94ecR4Mi+9+QkE6D6rEReQdFXwLQ= X-MS-Exchange-Transport-CrossTenantHeadersStamped: MN0PR11MB6057 X-OriginatorOrg: intel.com 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, May 13, 2024 at 09:11:32PM +0200, Morten Brørup wrote: > > From: Stephen Hemminger [mailto:stephen@networkplumber.org] > > Sent: Monday, 13 May 2024 17.55 > > > > On Mon, 13 May 2024 14:08:07 +0100 > > Ferruh Yigit wrote: > > > > > 2. Double tab indentation vs parenthesis align > > > if (iter->bus != NULL && > > > - /* not in middle of rte_eth_dev iteration, */ > > > - iter->class_device == NULL) { > > > + /* not in middle of rte_eth_dev iteration, */ > > > + iter->class_device == NULL) { > > > > > > DPDK coding guide suggests double tab, but also accepts alignment by > > > spaces. But as far as I can see most of code has double tab. > > > Majority of the diff caused because of this rule. > > > > > > I personally am more used the aligned style, and most tools support > > that. > > The DPDK one is unique (not done by most other projects). So can we just > > keep the kernel (what is this clang-format) version. > > I personally prefer the double tab. > It also works with editors showing tab as 4 space indentation. > > Mixing tabs and spaces only works if the editor shows tabs as 8 space indentation. > > Double tab works with both editor configurations. > > And there is no confusion if the following block happens to be aligned with the following parameters. E.g.: > > if fool(x, > y) > myfn(); > > vs. > > if fool(x, > y) > myfn(); > +1, I also prefer the double tab too for this reason. The other consideration is that double tab leads to smaller diffs on refactor - with aligning brackets if something on the first line changes it could cause whitespace changes to be needed on all subsequent lines Overall, ignoring our individual preferences, since we already have a mix in DPDK, I think it's infeasible to try and enforce a single standard now. :-( /Bruce