Received: by 2002:a05:7412:6592:b0:d7:7d3a:4fe2 with SMTP id m18csp2376934rdg; Sun, 13 Aug 2023 23:44:50 -0700 (PDT) X-Google-Smtp-Source: AGHT+IFtmC0xzeSX//Ze75S0RGHD13+dPDLvYnUrnb4ecJNMM5E73GmdWRCcrH0S1P7CUZsoT4kA X-Received: by 2002:a05:6512:5cd:b0:4fe:8c4:44f4 with SMTP id o13-20020a05651205cd00b004fe08c444f4mr5273750lfo.62.1691995490279; Sun, 13 Aug 2023 23:44:50 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1691995490; cv=none; d=google.com; s=arc-20160816; b=j67MR9tdRPz5VULd14R2ATY7aU75imQKfuj41NXWHpaedm6nCARw6N1ovLgUKzu67q 9nSeVc7uwcGcjTc+u4d6qBZHeq48P+9Taomn7VxzhYJD6pMoIggfslgMDVyLm6w2WQmP Ig6Ja9KkWzyHOrwegiYd91zGgbNWPw+73VmX8V3cHyiYG10eXD156eCf2evGySI95YwV BqeQXiyu+EusW0nuXKinczXygoIdBbr22LRekF36qLAhNuA/ftMFfBrGzZkMu325fhWl RpYMxRheiW3kfpGLD9IF7uoTd4HHzSXBHl1tD4B85LYty4igSXwVArUuQVHkjKROh6uC 7JBA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:message-id:date:references :in-reply-to:subject:cc:to:dkim-signature:dkim-signature:from; bh=QcEI4KZg3VbQwbcZLWUE/uWIoE2bSeS0e6kRTJtHxqg=; fh=1gbfUJQbwgpDDbY/MYSC9Eiz8kcoHSn72oscnGC/rrA=; b=pRo4C7jBrb5j9weA7QYEDm6JcJ1Pv8ccxPPDC5xo9hjpvNZmPrtOYVaJDHgrtuIuMv xIQtqrwPVvGJOsSFeORxtVbrLwTwkbSB3Xcu1QCZeqn67q+Bcs04UwwxLk/q/TeKZF3s RLYeBjUEoB0ObLAuDgoN3xTAZhTtj5HBnOZdAZJIvQ1R4kkp2jGQQW2bB73WK7sCdhxG qdoxvQk4npqh7h9GZRQHTHsyUA5uLACLg0U5Lj0hNMy6m3w7d2KywF9nE7EEPNm+fWvH Cea22BKQ6IBMEg2XpW79d1HXqFMqnBbEIdNwVM/TV3jykvO2LA+73M7i22wZfG45akjs TZ1A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linutronix.de header.s=2020 header.b=XS3vPp45; dkim=neutral (no key) header.i=@linutronix.de header.s=2020e header.b=i0P8MUiX; 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=QUARANTINE dis=NONE) header.from=linutronix.de Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id h18-20020a170906829200b0099a1fb56239si7569861ejx.476.2023.08.13.23.44.26; Sun, 13 Aug 2023 23:44:50 -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=@linutronix.de header.s=2020 header.b=XS3vPp45; dkim=neutral (no key) header.i=@linutronix.de header.s=2020e header.b=i0P8MUiX; 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=QUARANTINE dis=NONE) header.from=linutronix.de Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231764AbjHNGQP (ORCPT + 99 others); Mon, 14 Aug 2023 02:16:15 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:34290 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230072AbjHNGPs (ORCPT ); Mon, 14 Aug 2023 02:15:48 -0400 Received: from galois.linutronix.de (Galois.linutronix.de [193.142.43.55]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 62B84F4; Sun, 13 Aug 2023 23:15:47 -0700 (PDT) From: John Ogness DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020; t=1691993744; 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=QcEI4KZg3VbQwbcZLWUE/uWIoE2bSeS0e6kRTJtHxqg=; b=XS3vPp45TZPoj/MwYV/78QkdPxJR23PbRilQ/Uuyxo8rPH9dzkb2+vgyGPBp5XTZh7i/Eb YZIl0Rmd8CGoTr1PO/TOGBYQCK8Nim8HnWGzY58/SnQ5oc8Q9KqH9/+gV2cMBb8TV/kxUk OnX1+HkS8SU37EVC76XI1z7woxZNgu+vFQPgrohNDU9T3Wc1NFxh/ZOvQkge/Yl1eQ0DGC xAP8682tOT5841Rb5KU5yr5NPvSne5LX2TCVcJkcJLCSoGc/iw8tRp7mnWRsVtbVP5LN35 wMc4jly7patSUrGRQJ8u2F5Ae6wrDQH2Z8kR67YQS6zY+ez1jo1Z3BFrkmtpkA== DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020e; t=1691993744; 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=QcEI4KZg3VbQwbcZLWUE/uWIoE2bSeS0e6kRTJtHxqg=; b=i0P8MUiX0s0/aFgy4dgWhHPdVSUKR2iV21BnvYSTKA7C+mWgDk4HMFtIzUkhHaRiOko6ir Yh3bjYbw+9eEtvCQ== To: "Jiri Slaby (SUSE)" , gregkh@linuxfoundation.org Cc: linux-serial@vger.kernel.org, linux-kernel@vger.kernel.org, "Jiri Slaby (SUSE)" , Vlastimil Babka , Thomas Gleixner , Petr Mladek Subject: Re: [PATCH] serial: 8250: drop lockdep annotation from serial8250_clear_IER() In-Reply-To: <20230811064340.13400-1-jirislaby@kernel.org> References: <20230811064340.13400-1-jirislaby@kernel.org> Date: Mon, 14 Aug 2023 08:21:32 +0206 Message-ID: <878rae175n.fsf@jogness.linutronix.de> MIME-Version: 1.0 Content-Type: text/plain X-Spam-Status: No, score=-1.6 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,INVALID_DATE_TZ_ABSURD, RCVD_IN_DNSWL_BLOCKED,SPF_HELO_NONE,SPF_PASS autolearn=no 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 2023-08-11, "Jiri Slaby (SUSE)" wrote: > The port lock is not always held when calling serial8250_clear_IER(). > When an oops is in progress, the lock is tried to be taken and when it > is not, a warning is issued: Yes, and that is a potential deadlock. The warning is correct. > Therefore, remove the annotation as it doesn't hold for all invocations. ... because those invocations are broken by design. > The other option would be to make the lockdep test conditional on > 'oops_in_progress' or pass 'locked' from serial8250_console_write(). I > don't think, that is worth it. The proper thing to do is to fix the invocation. The upcoming atomic console implementation for the 8250 does exactly that. If this patch gets accepted (which it appears it will be), I will revert it in my series implementing the 8250 atomic console. John Ogness