Received: by 2002:ac0:a5a7:0:0:0:0:0 with SMTP id m36-v6csp681495imm; Wed, 1 Aug 2018 03:36:25 -0700 (PDT) X-Google-Smtp-Source: AAOMgpcH7Vx3wsUcDV4OeZXLlUHbH3gvghvWj90RMDiFAEP4cDeLoKNcMqnzQbOMkLfo/uMtv5uq X-Received: by 2002:a63:714a:: with SMTP id b10-v6mr23303889pgn.73.1533119785443; Wed, 01 Aug 2018 03:36:25 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1533119785; cv=none; d=google.com; s=arc-20160816; b=kA1Ux1JuGdvMqxayb+PQ0TRoo93XMikOQONVw6Lph0ZlUXM07tTwn0zGoMdN5B2rkL nKtnA6vogXxLgA2+bPAxJShD+euwJGF89Ng04e3yQxa7E+yHT48Nj4wVAB7AYE2QwTWO e2rE/AhwJPRCxkVOkIbTH+zzjFe5fYTipjgSftxU0ijhPnHsbP02XveEW27a7VrJ+ViL xAcHY1Flf0E4qda3dlo2pDiZ+sSMD75br2I92Yoc0O5ojwMQfs8quhKOCFAvTjEv2Aaa vuiEen0qY54qyNisiCm0lAorZTgT0wmzJm0GO7uoeKucQS1zslZgPQ11aJNvAw3BkmDW cngg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :references:in-reply-to:mime-version:dkim-signature :arc-authentication-results; bh=EJ9gZt5ymPHJQTGM6KoCLKfxnXjQCunOLq9zbJJjjus=; b=i4wh7/WTFukarIGPEtLz6ThGqjQXknqq5mXIX8kb8rvZ3Hqh/f/KEtstOgEr+J8Xcu MJfhj5N/qyHjcmeHQ8VILqxHUiUIKdERmvTYnTyTHVJQWEBEZQcAqnJHv7bLt4wszkpT gkbW25BMC6KwtZaa57Slx0D+oTNWbKTaqf/BYqCbO3OKPHORaAiSepqGhNGamybu9r7+ +qoij5pRnOt1tqdCc1LHoRxS5gvhQb3XQhQ9Gxi/5DcA9liBws/mD4e0q6oxVy9m2Mri ZEkE0QK3a+DRUTTDa4+7+IHRp8i4N3FEqf4yrWec500DCeohP/y9xl1fQPjAyu0oe4fg 31VA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b=mlUweRnX; 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=REJECT sp=REJECT dis=NONE) header.from=google.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id i186-v6si18629972pfb.362.2018.08.01.03.36.07; Wed, 01 Aug 2018 03:36:25 -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=@google.com header.s=20161025 header.b=mlUweRnX; 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=REJECT sp=REJECT dis=NONE) header.from=google.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2387610AbeHAMUX (ORCPT + 99 others); Wed, 1 Aug 2018 08:20:23 -0400 Received: from mail-pf1-f195.google.com ([209.85.210.195]:37064 "EHLO mail-pf1-f195.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2387568AbeHAMUW (ORCPT ); Wed, 1 Aug 2018 08:20:22 -0400 Received: by mail-pf1-f195.google.com with SMTP id a26-v6so7640971pfo.4 for ; Wed, 01 Aug 2018 03:35:15 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=EJ9gZt5ymPHJQTGM6KoCLKfxnXjQCunOLq9zbJJjjus=; b=mlUweRnXTB3YnTHEfnsctWnyBERxg6Yo8kRLfA8MEC+OWYKM2HF07qGdpmRCGT780j LB+2qrMC3KSP4lcFot9PwP7596Qes8BQwaW88VeXzF6s46TFVlJoEJYQJYgmH6w5yQLv aW2AEva0asLeh9SxOrepLPicQuK+8sPgQfJNH5AoPVqwta9e1Iaf1WKWLkwTC+nb1Lwc Nzre7CnGUhRb3pv6u0RFaKzLePtgQXRlIoD/ePWO9MrIKeJYyTB9iU4l8nNkNfaq4Fna vSLwB/oJolFnAsVoEYBxJBS5yyTgRVbMtm7q7On5lvK/VXqiMihr7MIHFkAj9p3BIo5m oPew== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=EJ9gZt5ymPHJQTGM6KoCLKfxnXjQCunOLq9zbJJjjus=; b=OGT4JgXFCkAOOsuplbQohxHvvkud4cTnqVV5Tx4wNEyhQg2g1Ncz8oEkNep1vAYWBR FSrMA4zOU0rezIe6gjwTXBPdv3fR4bwV0r5zbgSr5udP9JTnVK1gerg/lbH1Z6HJ90mZ x0zhugjKIBcfIOVkDlTfmC8T/tC9Jm7i+8TZkYfNyvwUl7hkAgAqhfvu45sXPdTEBeM6 y18REuBC8N6ps/oKT4WZ5RyIwfEk4KjjAJNWvmNTekiCp8K7w8VG9yYmDvuD6AbQA58u ZIn20n15Emm2xS8ySjvyzc9yHBbAPRtVrDzUHONux5x9TQzD0gzMForMrMe9OpwhntMH 6cIA== X-Gm-Message-State: AOUpUlFKzUKbSI/+9UTWjerkRJWeKcRL4pLySgO5nOJ6xF833JQN7dY2 YhPRVt0VZFhpmESwHS/24fS2sWPeRsx93JxzuAbT1g== X-Received: by 2002:a62:b604:: with SMTP id j4-v6mr17233441pff.199.1533119714664; Wed, 01 Aug 2018 03:35:14 -0700 (PDT) MIME-Version: 1.0 Received: by 2002:a17:90a:ac14:0:0:0:0 with HTTP; Wed, 1 Aug 2018 03:34:54 -0700 (PDT) In-Reply-To: References: <01000164f169bc6b-c73a8353-d7d9-47ec-a782-90aadcb86bfb-000000@email.amazonses.com> <30ee6c72-dc90-275a-8e23-54221f393cb0@virtuozzo.com> From: Dmitry Vyukov Date: Wed, 1 Aug 2018 12:34:54 +0200 Message-ID: Subject: Re: SLAB_TYPESAFE_BY_RCU without constructors (was Re: [PATCH v4 13/17] khwasan: add hooks implementation) To: Eric Dumazet Cc: Andrey Ryabinin , Linus Torvalds , Christoph Lameter , "Theodore Ts'o" , Jan Kara , linux-ext4@vger.kernel.org, Greg Kroah-Hartman , Pablo Neira Ayuso , Jozsef Kadlecsik , Florian Westphal , David Miller , NetFilter , coreteam@netfilter.org, Network Development , Gerrit Renker , dccp@vger.kernel.org, Jani Nikula , Joonas Lahtinen , Rodrigo Vivi , Dave Airlie , intel-gfx , DRI , Eric Dumazet , Alexey Kuznetsov , Hideaki YOSHIFUJI , Ursula Braun , linux-s390 , Linux Kernel Mailing List , Andrew Morton , linux-mm , Andrey Konovalov Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Aug 1, 2018 at 12:23 PM, Eric Dumazet wrote: > On 08/01/2018 02:03 AM, Andrey Ryabinin wrote: > >> I can't think of any advantage in not having the constructor. > > I can't see any advantage adding another indirect call, > in RETPOLINE world. Can you please elaborate what's the problem here? If slab ctor call have RETPOLINE, then using ctors more does not introduce any security problems and they are not _that_ slow. If slab ctors are not protected, then we have problem that needs to be fixed already. What am I missing?