Received: by 2002:ac0:a5a6:0:0:0:0:0 with SMTP id m35-v6csp636474imm; Wed, 26 Sep 2018 04:36:11 -0700 (PDT) X-Google-Smtp-Source: ACcGV63BToql4cfT0gmKjwA4r5Yi99UoNv6Jlm17zycq0lonRKeftH/R7fY/tGcBsIECDjfbFvzd X-Received: by 2002:a63:b409:: with SMTP id s9-v6mr5262557pgf.437.1537961771567; Wed, 26 Sep 2018 04:36:11 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1537961771; cv=none; d=google.com; s=arc-20160816; b=une6AmgwzjI8r37f2qe1rqiG5oSHZk2LIqjBCXhAdFBGQodnOJIcZ1bn9lHFtNFUXM hWHGzmuo+k594fZm18g5X53q+XXjAVRaKq56kBNiTL3ipo2UkljZI15Aj6Q1Z4NaQzKY FpILfWc3P/R7CNVO0IbgDrQWo7znaB432lvybX9gglvK6DGK5i+D/l+/CGF24ENp3sHX NZZ6HqHtJ0P+azIMphqWtXyeq8LxShaNfd0YsQyjuPmQbuRD5XFDzC2knAOfLtJEyYYB nyXwIFap1hJdJ+bz620tshKyisK6QUGGpqLmnDgB7idgF8WV0Sog6yWp6QV3N4DIYKtN eOZA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:spamdiagnosticmetadata :spamdiagnosticoutput:mime-version:references:in-reply-to:message-id :date:subject:cc:to:from:dkim-signature:dkim-signature; bh=LSkTcnRrd3uLpDU4ITYybN/wy8vDLhlE4OZguhupMfU=; b=m2J3p0Og4o2K9lH625oXipf3DFU2Pilyia49TSAoiDhrBU42OLKr/XNxB9WrFcRAmD rfNE5h5v4y+cia1p0i6HExkGFonFC24EMjYV6NOdPhDkqfbM4HO/kXlalDnLe3E3f/yH U309KQWDxYAwQsdVd0Slg4vnF8lk0qxZT4C4XYRH0RI4SlcARHxU9y++NG141QJ1Mloo ypLPUwYvUghfEy7IuiUhD62TNtCJH9p9q6qgLOFeeeV/OcQXPP8xdCJYMkr7UASUzYM9 4X5aGaGngi/eIISqtF4Rcao5dcZecWD628WyIK8Wkj2YXTnFD7yjm7bvUFobl58pWZX2 SjJw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@fb.com header.s=facebook header.b=UqC0Uozu; dkim=pass header.i=@fb.onmicrosoft.com header.s=selector1-fb-com header.b=NfmqJW4E; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=fb.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id p83-v6si4489033pfa.180.2018.09.26.04.35.56; Wed, 26 Sep 2018 04:36:11 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-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=@fb.com header.s=facebook header.b=UqC0Uozu; dkim=pass header.i=@fb.onmicrosoft.com header.s=selector1-fb-com header.b=NfmqJW4E; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=fb.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728224AbeIZRqt (ORCPT + 99 others); Wed, 26 Sep 2018 13:46:49 -0400 Received: from mx0a-00082601.pphosted.com ([67.231.145.42]:42922 "EHLO mx0a-00082601.pphosted.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728101AbeIZRqt (ORCPT ); Wed, 26 Sep 2018 13:46:49 -0400 Received: from pps.filterd (m0109334.ppops.net [127.0.0.1]) by mx0a-00082601.pphosted.com (8.16.0.22/8.16.0.22) with SMTP id w8QBX3aI019774; Wed, 26 Sep 2018 04:33:56 -0700 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=fb.com; h=from : to : cc : subject : date : message-id : in-reply-to : references : mime-version : content-type; s=facebook; bh=LSkTcnRrd3uLpDU4ITYybN/wy8vDLhlE4OZguhupMfU=; b=UqC0UozuDM7/YPUweA5qUBwzMPgXbUNuOI47NeJXikBruRiJkpEYQHcTNXDt/eNk8FCq /QsEfCsJYOQxJTUahjnAeAJtMSftCVTtiOF377kns7RYLWEarKtT/cUG47SPwIVJVfRq LFqUqrVOcuz8pjs96v+YxicRfHq2vsVPO7c= Received: from maileast.thefacebook.com ([199.201.65.23]) by mx0a-00082601.pphosted.com with ESMTP id 2mr4vc0njr-3 (version=TLSv1 cipher=ECDHE-RSA-AES256-SHA bits=256 verify=NOT); Wed, 26 Sep 2018 04:33:56 -0700 Received: from NAM01-BY2-obe.outbound.protection.outlook.com (192.168.183.28) by o365-in.thefacebook.com (192.168.177.33) with Microsoft SMTP Server (TLS) id 14.3.361.1; Wed, 26 Sep 2018 07:33:55 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=fb.onmicrosoft.com; s=selector1-fb-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=LSkTcnRrd3uLpDU4ITYybN/wy8vDLhlE4OZguhupMfU=; b=NfmqJW4Emd6v0EoGr9lhek/RVQd0+EB/BIlG2nOLChWwABWNpZ1s4/0eFJy7RLEByllDs+BGt6+L+lNSue7rwyB9y71SDRAN32FcAINcsXG/Vy9TIVHi8QHJlCF+pIhxDzqrHZbilMACGV/qnzkgofZYa8hC7Zr8FVEqtq5ShWE= Received: from castle.thefacebook.com (2620:10d:c092:200::1:15cb) by BLUPR15MB0162.namprd15.prod.outlook.com (2a01:111:e400:5249::12) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.1164.20; Wed, 26 Sep 2018 11:33:53 +0000 From: Roman Gushchin To: CC: Song Liu , , , Roman Gushchin , Daniel Borkmann , Alexei Starovoitov Subject: [PATCH v3 bpf-next 04/10] bpf: don't allow create maps of per-cpu cgroup local storages Date: Wed, 26 Sep 2018 12:33:20 +0100 Message-ID: <20180926113326.29069-5-guro@fb.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20180926113326.29069-1-guro@fb.com> References: <20180926113326.29069-1-guro@fb.com> MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [2620:10d:c092:200::1:15cb] X-ClientProxiedBy: AM6P193CA0005.EURP193.PROD.OUTLOOK.COM (2603:10a6:209:3e::18) To BLUPR15MB0162.namprd15.prod.outlook.com (2a01:111:e400:5249::12) X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 7979b818-0b2c-46cc-a912-08d623a3f083 X-Microsoft-Antispam: BCL:0;PCL:0;RULEID:(7020095)(4652040)(8989299)(4534165)(4627221)(201703031133081)(201702281549075)(8990200)(5600074)(711020)(2017052603328)(7153060)(7193020);SRVR:BLUPR15MB0162; X-Microsoft-Exchange-Diagnostics: 1;BLUPR15MB0162;3:iQICqtUwrXh8eajg8cxeF0SCNMAoy4L9o4ehL0qLKmHDzujusgmdeo+7foO4gyclHQ4IWSPlQFqE8WnlTIUzzRfy+SEDdBUC7DMx3IdvOa0Bio4ZXGXTcMvAuAeLZunZlDmhcGKXU836T6k4luYmp2MSY6LyJTN7MpQ34kA9ddhrz47CoUyTXEsUO6dQ7b/xemW4GJ6ExdSIeRhzeTl15sfU8BWe66S6MlzzeKUtqf4FwazllZ8xYDG72O9T6WVg;25:3eCFVedmqcbJQ739AS68Kj07vP71mnqJBerzDWSeL7e/Af/22Q2Fs2t5uJKF+xEDEDlQYIu0x0m5+3ttgx5j8R5hc7i49YFCpGv3yKSEQoOvNYA/FsoMlW+yR7VoPZgaOgdT6ZtWbM8e6pG3y0BAwCkrYKNdfgsHdKPqaDEek0HHJPivSZiCpmGhQZE13US0uiWigE56c5ChEOxrU8YWzBwBv58dHW5g0PCl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PYyWxNP5aA+oW5jRZ9DNLw6VG5jKhme4ch3+lXhHuwE7jVuSdrP8q4Nb+oFdnSen9SgOqUH453qoG3//KDMmbadDAlttrmp7CXdvdwK83n1p9Ce6FXF3bR8bGI/rPUVIh+l6hjlh0VZ7N6oKCbzWWU3TOT8nGsHP2jOar4flVlHSFG8eJgb3vmedhud6Oisa5c X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:(67672495146484); X-MS-Exchange-SenderADCheck: 1 X-Exchange-Antispam-Report-CFA-Test: BCL:0;PCL:0;RULEID:(8211001083)(6040522)(2401047)(8121501046)(5005006)(823302057)(3002001)(10201501046)(3231355)(11241501184)(944501410)(52105095)(93006095)(93001095)(149066)(150057)(6041310)(20161123562045)(20161123564045)(20161123560045)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(20161123558120)(201708071742011)(7699051);SRVR:BLUPR15MB0162;BCL:0;PCL:0;RULEID:;SRVR:BLUPR15MB0162; X-Forefront-PRVS: 08076ABC99 X-Forefront-Antispam-Report: SFV:NSPM;SFS:(10019020)(346002)(376002)(136003)(366004)(396003)(39860400002)(199004)(189003)(446003)(16526019)(478600001)(8936002)(46003)(186003)(11346002)(36756003)(52116002)(51416003)(52396003)(76176011)(97736004)(2616005)(4326008)(7736002)(50226002)(305945005)(476003)(2906002)(486006)(106356001)(6512007)(2351001)(48376002)(69596002)(6116002)(50466002)(1076002)(53416004)(47776003)(105586002)(53936002)(6506007)(8676002)(16586007)(386003)(54906003)(25786009)(6486002)(2361001)(81166006)(316002)(81156014)(86362001)(14444005)(5660300001)(6916009)(6666003)(34290500001)(68736007)(42262002);DIR:OUT;SFP:1102;SCL:1;SRVR:BLUPR15MB0162;H:castle.thefacebook.com;FPR:;SPF:None;LANG:en;PTR:InfoNoRecords;A:1;MX:1; Received-SPF: None (protection.outlook.com: fb.com does not designate permitted sender hosts) X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1;BLUPR15MB0162;23:7FjxNd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ArrivalTime: 26 Sep 2018 11:33:53.2588 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 7979b818-0b2c-46cc-a912-08d623a3f083 X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 8ae927fe-1255-47a7-a2af-5f3a069daaa2 X-MS-Exchange-Transport-CrossTenantHeadersStamped: BLUPR15MB0162 X-OriginatorOrg: fb.com X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:,, definitions=2018-09-26_06:,, signatures=0 X-Proofpoint-Spam-Reason: safe X-FB-Internal: Safe Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Explicitly forbid creating map of per-cpu cgroup local storages. This behavior matches the behavior of shared cgroup storages. Signed-off-by: Roman Gushchin Acked-by: Song Liu Cc: Daniel Borkmann Cc: Alexei Starovoitov --- kernel/bpf/map_in_map.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/kernel/bpf/map_in_map.c b/kernel/bpf/map_in_map.c index 3bfbf4464416..99d243e1ad6e 100644 --- a/kernel/bpf/map_in_map.c +++ b/kernel/bpf/map_in_map.c @@ -24,7 +24,8 @@ struct bpf_map *bpf_map_meta_alloc(int inner_map_ufd) * in the verifier is not enough. */ if (inner_map->map_type == BPF_MAP_TYPE_PROG_ARRAY || - inner_map->map_type == BPF_MAP_TYPE_CGROUP_STORAGE) { + inner_map->map_type == BPF_MAP_TYPE_CGROUP_STORAGE || + inner_map->map_type == BPF_MAP_TYPE_PERCPU_CGROUP_STORAGE) { fdput(f); return ERR_PTR(-ENOTSUPP); } -- 2.17.1