From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-15.8 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER, INCLUDES_PATCH,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id D1043C4338F for ; Sun, 15 Aug 2021 21:31:11 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id B865560FD8 for ; Sun, 15 Aug 2021 21:31:11 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231794AbhHOVbi (ORCPT ); Sun, 15 Aug 2021 17:31:38 -0400 Received: from Galois.linutronix.de ([193.142.43.55]:47840 "EHLO galois.linutronix.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231557AbhHOV2W (ORCPT ); Sun, 15 Aug 2021 17:28:22 -0400 Message-ID: <20210815211302.491442626@linutronix.de> DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020; t=1629062871; 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: content-transfer-encoding:content-transfer-encoding: references:references; bh=y2H9tHk2TsLPbEApgAG3HM6pFkiAV8t9phD5EzH6qEM=; b=s1Y0Yi0O9S5iMRuDUOxDIr5suqfa3Up/dttNtgkB2b4jnSOjP7A7MCPei2ppI12hXZZIrm LhZiisTVwnorPi5FxwMH/c3xZD8testIi94nSOOlOZH/MchIlhSMn2I+wLpjm+u4y6PDZ0 9rREL6kh7TNGIw5UNLGG9gun35kSSDGJyremo1FuyoiC2Vb0BgfE/xdP/Ux2+gvNJNcaf7 /k3BwwxeotgHq5tYjN0RP4jT0Z6K9sDSL8Se61yEBet2FCsNd32MKFLoRu53fr6pEcIq+L 6I3Yj5vPUPORzIeYe7M8C7eoT4NaGQ5fI7UdC47lVXkqvdlQvgnz3HXijkFGPg== DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020e; t=1629062871; 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: content-transfer-encoding:content-transfer-encoding: references:references; bh=y2H9tHk2TsLPbEApgAG3HM6pFkiAV8t9phD5EzH6qEM=; b=TADgP379a5Zsv/fX5S65vnqrQJdlQqG+csK+xNa6O0mhzCOudrwf0MKhYTTUawkb1m0WQw zIhX3xhGvDPQDkCA== From: Thomas Gleixner To: LKML Cc: Peter Zijlstra , Ingo Molnar , Juri Lelli , Steven Rostedt , Daniel Bristot de Oliveira , Will Deacon , Waiman Long , Boqun Feng , Sebastian Andrzej Siewior , Davidlohr Bueso , Mike Galbraith Subject: [patch V5 10/72] media/atomisp: Use lockdep instead of *mutex_is_locked() References: <20210815203225.710392609@linutronix.de> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-transfer-encoding: 8-bit Date: Sun, 15 Aug 2021 23:27:51 +0200 (CEST) Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Peter Zijlstra Subject: [patch V5 10/72] media/atomisp: Use lockdep instead of *mutex_is_locked() The only user of rt_mutex_is_locked() is an anti-pattern, remove it. Signed-off-by: Peter Zijlstra (Intel) Signed-off-by: Thomas Gleixner Link: https://lore.kernel.org/r/20210714100719.GA11408@worktop.programming.kicks-ass.net --- --- drivers/staging/media/atomisp/pci/atomisp_ioctl.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) --- a/drivers/staging/media/atomisp/pci/atomisp_ioctl.c +++ b/drivers/staging/media/atomisp/pci/atomisp_ioctl.c @@ -1904,8 +1904,8 @@ int __atomisp_streamoff(struct file *fil dev_dbg(isp->dev, "Stop stream on pad %d for asd%d\n", atomisp_subdev_source_pad(vdev), asd->index); - BUG_ON(!rt_mutex_is_locked(&isp->mutex)); - BUG_ON(!mutex_is_locked(&isp->streamoff_mutex)); + lockdep_assert_held(&isp->mutex); + lockdep_assert_held(&isp->streamoff_mutex); if (type != V4L2_BUF_TYPE_VIDEO_CAPTURE) { dev_dbg(isp->dev, "unsupported v4l2 buf type\n");