Received: by 2002:a25:6193:0:0:0:0:0 with SMTP id v141csp2608391ybb; Sun, 5 Apr 2020 11:48:32 -0700 (PDT) X-Google-Smtp-Source: APiQypKrQOUr/FAZhdfyGRAX79n9Pg2Wpl7Do8ECYaDa01dewVbsWDudb+xx84XQF4lF0P5GeRXD X-Received: by 2002:aca:4c1:: with SMTP id 184mr10531754oie.76.1586112511909; Sun, 05 Apr 2020 11:48:31 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1586112511; cv=pass; d=google.com; s=arc-20160816; b=ulankps/kEbW7rXPjIyQDBsORv7JuMwjazPQmaHltHnHl1a87HDzw5u12ZD56Cl9+U zpvSz/bSfGHKVhLfROtkcvQ/IYCt3lnxqcYm3SO/NOAr/DkIu7onhWp5INqoij4pgQTC Zj2zjwX/wzHI4CLyMOBCHQiRuxthRKmd2XL4wZQ7DvQOTEmbq6To6bwj3a7wyu1t5LrS InhBK/XPJGJKLzfgKyIpsey3QGc8wnNcFzwSrPkLyYyKP1ADQ9hoxkFbsGCH6sh9awPP WObjuaXOB8AAMpAC9sBNvQFu/u9uP7pL4+bz0T32/7VhyNp3iaT8WxRUXPS7gJWt7444 ke1A== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:content-transfer-encoding :content-id:user-agent:content-language:accept-language:in-reply-to :references:message-id:date:thread-index:thread-topic:subject:to :from:dkim-signature:ironport-sdr:ironport-sdr; bh=LB5wPqcpe3z3+DAJF4x0/X8PnrpDP6UYtcuRaGavxr0=; b=QXB2P3IEP9szefF4CQAmd2pTamaMAvd7aBdPXaZ1GT+3z1UWHIdYq4R/zqTA1tiIKj le+nepUe7CT/CmD5/61f3GH6QQpKFVhbMn/slZjitpCmEYwPPWgCBRjVcG4rzgdHNWG+ u5XLE5ZQgJuSrHc+zR2rqxbfaVrmJzNsgW65AMeY3M7tVnVmUG9zmw0JgY7xqnuMmjjL W+87v48xYdvC2G3bxPHpHnpcanMyIzZTwwAZuAXq7e6BXgONUcjKyXvGW0Rh3GHvjw/2 xN3or69sKNapP4nyzo16pw9hyYTHme+k+Fg3eQmHW0TzOqyYko5JnlZERLzuoiBWruPH XxNA== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@intel.onmicrosoft.com header.s=selector2-intel-onmicrosoft-com header.b=BzQ7t5EU; arc=pass (i=1 spf=pass spfdomain=intel.com dkim=pass dkdomain=intel.com dmarc=pass fromdomain=intel.com); spf=pass (google.com: best guess record for domain of linux-bluetooth-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-bluetooth-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id v128si6219866oig.68.2020.04.05.11.48.00; Sun, 05 Apr 2020 11:48:31 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-bluetooth-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@intel.onmicrosoft.com header.s=selector2-intel-onmicrosoft-com header.b=BzQ7t5EU; arc=pass (i=1 spf=pass spfdomain=intel.com dkim=pass dkdomain=intel.com dmarc=pass fromdomain=intel.com); spf=pass (google.com: best guess record for domain of linux-bluetooth-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-bluetooth-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727509AbgDESpp (ORCPT + 99 others); Sun, 5 Apr 2020 14:45:45 -0400 Received: from mga14.intel.com ([192.55.52.115]:64024 "EHLO mga14.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726771AbgDESpp (ORCPT ); Sun, 5 Apr 2020 14:45:45 -0400 IronPort-SDR: a1zFeJxQkxB562sKPZaetsVyvoikN1S8tmcYp+TsNNs1v1QdYaDrRFw8hFjoDO7PlFv9UlQDBL Y+KHV5sBJIwQ== X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga006.fm.intel.com ([10.253.24.20]) by fmsmga103.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 05 Apr 2020 11:45:43 -0700 IronPort-SDR: u1+vKovjg4HpiYjFf156cj8W/qGw8wCabZrG+7yJUIMjA+IqI2MZpKM2D72VP3xgJuZPrR+vrB KZiFM9EfRGQA== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.72,348,1580803200"; d="scan'208";a="451855907" Received: from orsmsx108.amr.corp.intel.com ([10.22.240.6]) by fmsmga006.fm.intel.com with ESMTP; 05 Apr 2020 11:45:43 -0700 Received: from orsmsx155.amr.corp.intel.com (10.22.240.21) by ORSMSX108.amr.corp.intel.com (10.22.240.6) with Microsoft SMTP Server (TLS) id 14.3.439.0; Sun, 5 Apr 2020 11:45:42 -0700 Received: from ORSEDG002.ED.cps.intel.com (10.7.248.5) by ORSMSX155.amr.corp.intel.com (10.22.240.21) with Microsoft SMTP Server (TLS) id 14.3.439.0; Sun, 5 Apr 2020 11:45:41 -0700 Received: from NAM11-DM6-obe.outbound.protection.outlook.com (104.47.57.172) by edgegateway.intel.com (134.134.137.101) with Microsoft SMTP Server (TLS) id 14.3.439.0; Sun, 5 Apr 2020 11:45:41 -0700 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=FIMJb62KwMwOofFr71BWXn8RnUddH1LUE7L8k1abrYwJNfO1uedR1ekO8gj80fJh4wQ3L77M7FheV7rGsqVh/JWYjInD6g9iQE8zRw4bWnuzzg9NAJpERT/8JKhQLR4ThkIGBBqHSGnwH1KYXEJ2ZI6aY5KjAh1HSrMlI91mLT7x3TB1wkl02pLCfYtwX38PmZdW+RCTA3oINQLbQMn4eSVmA8n49ABqep1S3a1FOKzASSmyG6HDVb17Zm3avtkvY7LvATSIHgQCoq5B3kigcgPFf80tsI+WzVpgYKkUFO6V6CQlI6U4PN9rsT0RTHJcJLHqhhW37Q6IwsBMedwxzA== 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-SenderADCheck; bh=LB5wPqcpe3z3+DAJF4x0/X8PnrpDP6UYtcuRaGavxr0=; b=F+rW8sKXcu17loaGX8IgB/T5b2V28jhg7Rzr7YAWeyvMFZRiTtR7k7Q0156JdcxucJLMZJeNHb5OnIWY5gLkoILZAegXfpejN4iIZ3sihZkoVmSl1t9BJc1HKa9sHCpybGOTtCVY7BkGzFTPeIr8Bt8k8fLXb7TIkKugoz5b3U+wFvtqrMgvzH5X9oYOCDKeuPXsz90IiDQTl527YJJrxvRa4YLE7bkdCPJbbvAfHtz9qWkF+35w9K0qOMb9FwVzjo/ggeoyC26O+NQqBjeMjsHoEUV34RapSOwi5OzGZjrJtOMZkCIhmf5FIu7/QjdWDczwJttWqZWLAWmhNzNbWQ== 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 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=intel.onmicrosoft.com; s=selector2-intel-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=LB5wPqcpe3z3+DAJF4x0/X8PnrpDP6UYtcuRaGavxr0=; b=BzQ7t5EUm7klDfz0CLAEWoTz/uiId4l3v/VfjhnX3TxrzHqrK5pDQGNWQp0IwCmJ0c6w+mLH5XulKgcgbgy7J2xeNdJRdKl4rK2SmG/A1TyZwHdFDXvgaP5WoA3yjGyHWp5nn9g7BPCnmTMXtvBkFRJQU+gqymSZrwmdX6mjl6A= Received: from MW3PR11MB4539.namprd11.prod.outlook.com (2603:10b6:303:2f::13) by MW3PR11MB4553.namprd11.prod.outlook.com (2603:10b6:303:2c::9) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.2878.17; Sun, 5 Apr 2020 18:45:39 +0000 Received: from MW3PR11MB4539.namprd11.prod.outlook.com ([fe80::39a4:4e3:2bb2:dd3a]) by MW3PR11MB4539.namprd11.prod.outlook.com ([fe80::39a4:4e3:2bb2:dd3a%3]) with mapi id 15.20.2878.018; Sun, 5 Apr 2020 18:45:39 +0000 From: "Gix, Brian" To: "michal.lowas-rzechonek@silvair.com" , "linux-bluetooth@vger.kernel.org" Subject: Re: [PATCH BlueZ RESEND] mesh: Remove redundant code from mesh/crypto Thread-Topic: [PATCH BlueZ RESEND] mesh: Remove redundant code from mesh/crypto Thread-Index: AQHWA7P/1NgK5Fw5002PJCTl12t5+6hq7WKA Date: Sun, 5 Apr 2020 18:45:39 +0000 Message-ID: <27728473092a638d6c97520b14eac61656c56903.camel@intel.com> References: <20200326211705.18678-1-michal.lowas-rzechonek@silvair.com> In-Reply-To: <20200326211705.18678-1-michal.lowas-rzechonek@silvair.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: user-agent: Evolution 3.32.5 (3.32.5-1.fc30) authentication-results: spf=none (sender IP is ) smtp.mailfrom=brian.gix@intel.com; x-originating-ip: [192.55.54.38] x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: f8dfcd0f-678c-4e45-1ee5-08d7d9918997 x-ms-traffictypediagnostic: MW3PR11MB4553: x-microsoft-antispam-prvs: x-ms-oob-tlc-oobclassifiers: OLM:8273; x-forefront-prvs: 03648EFF89 x-forefront-antispam-report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:MW3PR11MB4539.namprd11.prod.outlook.com;PTR:;CAT:NONE;SFTY:;SFS:(10019020)(366004)(136003)(346002)(39860400002)(376002)(396003)(66476007)(66446008)(64756008)(2616005)(66556008)(36756003)(110136005)(5660300002)(91956017)(76116006)(66946007)(86362001)(30864003)(71200400001)(8676002)(6512007)(8936002)(81166006)(478600001)(186003)(6506007)(6486002)(2906002)(316002)(26005)(81156014)(579004)(559001);DIR:OUT;SFP:1102; x-ms-exchange-senderadcheck: 1 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: c36P339bUL60lkkWePm6GeHVrcmOzvI8msvxlRUpP/qJlXzbO1R167Dsm0oqMXoKHEoQ/R/GkIMK7nmVshcYSqP2w4Kx9mTUjlBL/3jgEgszWAot+hGlx8ECl0a1yF3z0f5KjC307TH/H3STGVQ3nNrkCkepiLDYBWVBnUCe5MMu9fJCiXo/WVH8LdfxBm4SMcbwm6pQryrGir5GepCB8dl44TKQApKDOmXkHno2tAxzMBG4Fp1w/BDVz3uDd5ejbBxl4I7eHhw6XBqUH+WVlykSi+SQz+HxkXcIxmbGaDB1fovLFzHXZk3cO4o4UWp7MqM1YQVj/Kn6ESECOSIY1JO7iA4efoxMvcn5dMZH0/NOOlNTSaXpCr2i55eG10xSyeW6qMUvi/HwcSpewuoAdwzfAH7lMk/9rdUcN2QNDFLKXj13+Zxnph8VxxMhDpC5 x-ms-exchange-antispam-messagedata: tO60OlD20AfSAGfx68MSyhNZZCZxeamufZmQP2091TnYZuDtQkCfdAEyKBHzjSvIibsJoD/uwwgLWJ+qouOLWWLRAkbgQADXot4BpJ0+mZoUDbPy1eGlUyVxoxxKNg+uiN9XJ5WE5PGLqEDJTJvLQA== x-ms-exchange-transport-forked: True Content-Type: text/plain; charset="utf-8" Content-ID: Content-Transfer-Encoding: base64 MIME-Version: 1.0 X-MS-Exchange-CrossTenant-Network-Message-Id: f8dfcd0f-678c-4e45-1ee5-08d7d9918997 X-MS-Exchange-CrossTenant-originalarrivaltime: 05 Apr 2020 18:45:39.6080 (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: 7EEGE8hgwoA7m1PSlfH0OLpnX1+74i9jKzRA/PkHu/UMJXQtw07xNeKyP2W8R8gYl5K/O41WeFgy7HjcSy/faQ== X-MS-Exchange-Transport-CrossTenantHeadersStamped: MW3PR11MB4553 X-OriginatorOrg: intel.com Sender: linux-bluetooth-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-bluetooth@vger.kernel.org SGkgTWljaGHFgiwNCg0KSSB0aGluayB0aGlzIG5lZWRzIHNvbWUgbW9yZSB3b3JrLCBpbiB0aGF0 IGl0IG5vIGxvbmdlciBjb3JyZWN0bHkgZmFpbHMgdGhlIG1lc2gtdGVzdC1jcnlwdG8gdGVzdCB3 aGVuIHJ1bm5pbmc6DQoNCm1ha2UgZGlzdGNoZWNrDQoNCkl0ICphbG1vc3QqIGRvZXMgaW4gdGhh dCBpdCBmbGFncyBhbiBlcnJvciBpbiByZWQgaWYgYSAidmVyaWZ5IiBzdGVwIGZhaWxzLCBidXQg aXQgZG9lcyBub3QgZXhpdCB3aXRoIGEgZmFpbA0KY29kZS4gIFRoaXMgaXMgYW4gaW1wb3J0YW50 IHN0ZXAsIHBhcnRpY3VsYXJpbHkgd2l0aCB0aGUgZGVwZW5kYW5jZSBvbiBrZXJuZWwgYmFzZWQg Y3J5cHRvIGZ1bmN0aW9ucy4NCg0KTXkgdGVzdCBtZXRob2RvbG9neSB3YXMgdG8gZmxpcCBhIGJp dCBpbiBvbmUgb2YgdGhlIHRlc3QgcGF5bG9hZHMgIChpLmUuLCBtYWtlIGl0ICJub3QgcGVyZmVj dGx5IG1hdGNoIiB0aGUNCnNwZWNpZmljYXRpb24gc2FtcGxlIGRhdGEpLg0KDQpBcyBiZXN0IEkg Y2FuIHRlbGwsIGl0IGlzIG90aGVyd2lzZSBmdW5jdGlvbmFsLCBidXQgdGhlIHVuaXQgdGVzdHM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