Received: by 2002:a6b:500f:0:0:0:0:0 with SMTP id e15csp991739iob; Fri, 13 May 2022 18:52:09 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyczBC4QUAByQak549bAGLe+eI4NpWXYTdL/9Z2XHzFb1QcmOLxNjjrhVGgZxhoFprYYlFq X-Received: by 2002:a5d:6c65:0:b0:20c:5230:f145 with SMTP id r5-20020a5d6c65000000b0020c5230f145mr5785634wrz.337.1652493129400; Fri, 13 May 2022 18:52:09 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1652493129; cv=none; d=google.com; s=arc-20160816; b=rTuuH4iXhAMiQBDDZsEjD8dObW+Zey0aBnU2iPIDU7Q/VUyCJs8AYbldrQY1GlJ32m oNc+3G3MChsYC8ocEB+ia65ZgN4MFOIPojngyAyt6i3T7FuC9mnMKskoAGzCrr4l0PXm GZApeBeLyVlfV6FT1Vh0U0hmhy9zCx0bbWsTNQk8EI3jPfiPJRN0VKHoBjOU9shwvLn4 lDQ8CiJF2j1aKX6qb0ql5EOV6LgScOwN/kjtX8yAVM7ydlUVdzkDtCCXiPoBkXwbxDN8 a7XIuahE14fcbtbKGpn4S6mmHspygzTKNhu3J0Ph9XZ/jiUgWjwYcFyn92scDaeuuoxb Y3uA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date; bh=v9cn8Cc4DNdGk2hr1utWLptSnVVRdmLoi7wzG8LHGGs=; b=LJd1acO7hDT8GKVTqyOJ8R0D1RpfuFBxg/Lg+rEnfhgDfzumOXm7k6UCm+MtpfKR1L 8v1h317dPXGBuLVH2pwMOyfSlmQ0tvT0lY0MP4KoKJo7F1rSrVdvmXqkZ/O6TpcLpI+p /kIo3XslM9+H1HFmmFyPMSLLHb1MPOY06rF0B8D8dMUuyOUxl4g/9KUdaWY3kdet4r2q cQP754a9JKMVIwRmpe8ZlrmMFwyxoHUt/MQqXZt+92iMzm2xanaQ8+2n114nyWlrlsWn x3uoiJW51iv+5eNEFYl4fGu3+wmlIE6zZ7+dZpV/Ti2HSsZQyod23bqF/5AO5U5Dol0Q 2bKQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [2620:137:e000::1:18]) by mx.google.com with ESMTPS id t12-20020adff04c000000b0020acc5f55c2si3388654wro.134.2022.05.13.18.52.08 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 13 May 2022 18:52:09 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) client-ip=2620:137:e000::1:18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 7D20F44F767; Fri, 13 May 2022 17:15:36 -0700 (PDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1380016AbiEMLqw (ORCPT + 99 others); Fri, 13 May 2022 07:46:52 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:57036 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1380014AbiEMLqu (ORCPT ); Fri, 13 May 2022 07:46:50 -0400 Received: from metis.ext.pengutronix.de (metis.ext.pengutronix.de [IPv6:2001:67c:670:201:290:27ff:fe1d:cc33]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id CAD3353737 for ; Fri, 13 May 2022 04:46:49 -0700 (PDT) Received: from gallifrey.ext.pengutronix.de ([2001:67c:670:201:5054:ff:fe8d:eefb] helo=bjornoya.blackshift.org) by metis.ext.pengutronix.de with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1npTkr-0007eF-0E; Fri, 13 May 2022 13:46:45 +0200 Received: from pengutronix.de (unknown [IPv6:2a01:4f8:1c1c:29e9:22:41ff:fe00:1400]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) (Authenticated sender: mkl-all@blackshift.org) by smtp.blackshift.org (Postfix) with ESMTPSA id 0503D7D95B; Fri, 13 May 2022 11:46:42 +0000 (UTC) Date: Fri, 13 May 2022 13:46:42 +0200 From: Marc Kleine-Budde To: Vincent Mailhol Cc: Max Staudt , Wolfgang Grandegger , linux-can@vger.kernel.org, Greg Kroah-Hartman , Oliver Neukum , linux-kernel@vger.kernel.org Subject: Re: [PATCH v6] can, tty: can327 CAN/ldisc driver for ELM327 based OBD-II adapters Message-ID: <20220513114642.77jfdscjwzgyiwm3@pengutronix.de> References: <20220512182921.193462-1-max@enpas.org> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="m3okyqmyt2uyv2he" Content-Disposition: inline In-Reply-To: X-SA-Exim-Connect-IP: 2001:67c:670:201:5054:ff:fe8d:eefb X-SA-Exim-Mail-From: mkl@pengutronix.de X-SA-Exim-Scanned: No (on metis.ext.pengutronix.de); SAEximRunCond expanded to false X-PTX-Original-Recipient: linux-kernel@vger.kernel.org X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,RDNS_NONE, SPF_HELO_NONE,T_SCC_BODY_TEXT_LINE 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 --m3okyqmyt2uyv2he Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On 13.05.2022 11:38:31, Vincent Mailhol wrote: > > +static void elm327_parse_line(struct can327 *elm, size_t len) > > +{ > > + lockdep_assert_held(&elm->lock); >=20 > You are using many of those lockdep_assert_held(&elm->lock); >=20 > I guess you put them for debug purpose and probaly some of those can > be removed (if you see a genuine risk at some places, then OK to keep > as a safety net, but a bit of clean up can be done here, I think). >=20 > This comment applies to all use of lockdep_assert_held(). These statements document that the code must be called with the lock held. They optimize away if lockdep is not enabled. Better keep them in place. regards, Marc --=20 Pengutronix e.K. | Marc Kleine-Budde | Embedded Linux | https://www.pengutronix.de | Vertretung West/Dortmund | Phone: +49-231-2826-924 | Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 | --m3okyqmyt2uyv2he Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQEzBAABCgAdFiEEBsvAIBsPu6mG7thcrX5LkNig010FAmJ+RSAACgkQrX5LkNig 012MwwgAm4xVfAxO42VZQ8ps/XQLvThpyouR3oifOiYnXEGYdIaIqDgPWxvWBJIV wmj8CBnW2CePSkFQofw8tkT1RH1wSyLf8vPzvOPpXkFAlLT5PbAq86cfeyRxyR8L 0jPsGPrRYnQtYQ/tLMqPaCOVypsndd+kAYZGSzRkvzTiroKtgeTNbKZUYwTjvcbG rcbFsPNNJjizATaINWrR+C9irJ6E3KPixRAI/3/dn4Xt6uVEJweGGHzm/sciyczz 1TvdOsU3f0rRJ3Xh0zbc9dQRWl5npYUaA2CMBeZu9rm/J5amgmxf2EA9YTtc0YiW 7Wz3qq3BmSoUKqmoZCca4aSwCKilPA== =K50O -----END PGP SIGNATURE----- --m3okyqmyt2uyv2he--