Received: by 2002:a6b:fb09:0:0:0:0:0 with SMTP id h9csp4357583iog; Tue, 21 Jun 2022 18:26:44 -0700 (PDT) X-Google-Smtp-Source: AGRyM1tYn+/+WnfNhqPOFGd/GyLe19RUbpN55F0S2bF9Zffe2p55ruiGZogeKdloUJmnegsjZIbE X-Received: by 2002:a63:5a13:0:b0:3c6:3d28:87e5 with SMTP id o19-20020a635a13000000b003c63d2887e5mr755855pgb.452.1655861204677; Tue, 21 Jun 2022 18:26:44 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1655861204; cv=none; d=google.com; s=arc-20160816; b=upTLtFe/V11gVk8hffWNwTGn5WGQBx8c5AKowk9NjXnUIk3auT4SctC7Kk75HzJm/t jQvdttFoqN+ujcKsFdMNZSb4PYrFEyHfhxTYlE1rnyDpXdWTV2yRG2O6L74c38UIxOP/ iuoT2QvsizPPqlNxXjA2EbkPGW8SD//RUPwBCoviIn5TlnFc+psE8T0Xd9PrJcBVpsOl +Waxt5/ELBlhvKRUgjIgU5oax0/1wAKBE/cmPGyABrUysIbhujVlJUPGKx2zTnT1bNfZ u4IwuR9cLtuCNG8xR88gOX/WcpCj9T0+V78h4fu+as5/UD3U/ynBCJXpM5kjZh/JiEnU 7yBw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:dkim-signature; bh=wuuPsrvpildfWMsTFBzbFCeyycT4LB8kmzw//Wg2WxM=; b=yBqM9NdkDhGYrA0fe4uXZGiLM//AMzMZFDtE6SplPw0N8NDyt+4F+BjGg2ZXOevncK 8XPdVemZRwu94uCxD7V33LiBZMmH2/HA7G8XgjlD1Q363qknbcEPiwgeaOF7sbNrD5s+ F+59ViWP1FhVRktc981iwmV+9WcJJH4gjez43MtkXyDhlWbIgr9OkUAIA7u9gMdOVJW9 wlevxwBf2eynuEtN1rwd3Narf8N9uszoKwsPgtsHzlZLlzdI7s3qKqP7kb0d4bbUBmMJ naIWNK3pEB6VtZwx8sXXI4t7LDmZF26acISUtU9trnZbF43Xjw5PK2t4uV/VvrtKeWOU 4V4g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=jSd51UwG; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id 84-20020a630757000000b0040c9f5a0e43si12474087pgh.338.2022.06.21.18.26.27; Tue, 21 Jun 2022 18:26:44 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=jSd51UwG; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1355626AbiFVBSC (ORCPT + 99 others); Tue, 21 Jun 2022 21:18:02 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37858 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229990AbiFVBSB (ORCPT ); Tue, 21 Jun 2022 21:18:01 -0400 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id C9597F22 for ; Tue, 21 Jun 2022 18:17:58 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1655860678; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=wuuPsrvpildfWMsTFBzbFCeyycT4LB8kmzw//Wg2WxM=; b=jSd51UwGvncHsdhGX+pDJ52lhf22RyNaKa9oxoR76UegXr6pFsulKL/fq/z2Qx/Coz7Eze mMCsNia5G2/BeWg5I2Kwdjoy6UREWgEijprOBcY6KvFCh5mZdtbDPNu33z/JME4XPJvpUs AnqK6Q9ho8L0DSR9slLx+euFMYf/Q5w= Received: from mail-lf1-f72.google.com (mail-lf1-f72.google.com [209.85.167.72]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-178-QvCV9aB1NXeLXya_B2RoaA-1; Tue, 21 Jun 2022 21:17:56 -0400 X-MC-Unique: QvCV9aB1NXeLXya_B2RoaA-1 Received: by mail-lf1-f72.google.com with SMTP id j3-20020a05651231c300b0047dbea7b031so7695143lfe.19 for ; Tue, 21 Jun 2022 18:17:56 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=wuuPsrvpildfWMsTFBzbFCeyycT4LB8kmzw//Wg2WxM=; b=FZpxudpVzVULuZqFwUdbDE1EsphfXsTlEvthvf+ewqJR2z4yJgu6bAEZBaZbowm9oj C4hnMDdRqLwkCz68XTeQ05EZfWtVqXoH/nNNL3vaxaPwjCTGh7IdaDl/hqaeW+Y4r6Zp mLgTQ2hKemRHXfOh4ggGe4fb6fxRewoSoLUTnEzj8amXo2M9S5vlN44Lx2tuE8LHDWmj LDvjRj5kpNSdXDjF8d9kEsKUMfEqnlT4Km+x3jyNGAE7XxNJA64pOcSu2f30ZAz3PRKC Y2i+hmsdR1PnH4053z+cqyamlQlFTJMToo1n/htAm8Uoco6s6IEsglNTqizfsFuVYNUI amzA== X-Gm-Message-State: AJIora/5yNa2s2CENhXPrVOJRBkXPJ/RPVUPWCgxNnXH96OUl6Ra99cz AzyHEh+c8BALHicR+5v9NHarinFjiuh348LpF6QIB0/XKnqXZ5Hf1fDfHCyBwHxYKAEcvkdieKh kmFcZBQUEn/D+0WEnyyZjEv5PHNQwgrrcVuA/pNGI X-Received: by 2002:a2e:8417:0:b0:25a:7fa7:fe5a with SMTP id z23-20020a2e8417000000b0025a7fa7fe5amr446421ljg.323.1655860675085; Tue, 21 Jun 2022 18:17:55 -0700 (PDT) X-Received: by 2002:a2e:8417:0:b0:25a:7fa7:fe5a with SMTP id z23-20020a2e8417000000b0025a7fa7fe5amr446411ljg.323.1655860674845; Tue, 21 Jun 2022 18:17:54 -0700 (PDT) MIME-Version: 1.0 References: <20220620024158.2505-1-jasowang@redhat.com> <87y1xq8jgw.fsf@redhat.com> <87sfny8hj8.fsf@redhat.com> In-Reply-To: <87sfny8hj8.fsf@redhat.com> From: Jason Wang Date: Wed, 22 Jun 2022 09:17:37 +0800 Message-ID: Subject: Re: [PATCH V2] virtio: disable notification hardening by default To: Cornelia Huck Cc: Halil Pasic , mst , Vasily Gorbik , Christian Borntraeger , Alexander Gordeev , linux-s390@vger.kernel.org, virtualization , kvm , linux-kernel Content-Type: text/plain; charset="UTF-8" X-Spam-Status: No, score=-3.4 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_LOW, SPF_HELO_NONE,SPF_NONE,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Jun 21, 2022 at 5:58 PM Cornelia Huck wrote: > > On Tue, Jun 21 2022, Jason Wang wrote: > > > On Tue, Jun 21, 2022 at 5:16 PM Cornelia Huck wrote: > >> > >> The ifdeffery looks a big ugly, but I don't have a better idea. > > > > I guess you meant the ccw part, I leave the spinlock here in V1, but > > Michael prefers to have that. > > Not doing the locking dance is good; I think the #ifdefs all over are a > bit ugly, but as I said, I can't think of a good, less-ugly way... Probably, but this is the way that is used by other subsystems. E.g CONFIG_HARDEN_USERCOPY etc. > > > In the future, we may consider removing that, one possible way is to > > have a per driver boolean for the hardening. > > As in "we've reviewed and tested this driver, so let's turn it on for > every device bound to it"? Right. Thanks >