Received: by 2002:ab2:1149:0:b0:1f3:1f8c:d0c6 with SMTP id z9csp31766lqz; Fri, 29 Mar 2024 07:43:06 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCV+PCZw2y+DfFTz9PRBH+WJpxKDISMXb6Z9BRPomOfIODlrCI+CD/3cKBeS6l49feo+gW8nqh8kfevf4dx989VhBJBFgMqjMH2im8JDlw== X-Google-Smtp-Source: AGHT+IEIQjP1AyytTTAc1Bn2FqUa6xzXE6pAUeHWnp/lEBhfXwVZC+6oH7o2S1LRy2RkFqZ48Lvl X-Received: by 2002:a50:a6dc:0:b0:568:ac53:83f9 with SMTP id f28-20020a50a6dc000000b00568ac5383f9mr1620720edc.7.1711723386429; Fri, 29 Mar 2024 07:43:06 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1711723386; cv=pass; d=google.com; s=arc-20160816; b=ryl5krWiGkAJp50JnmR+dIUZIIhOxLNLoSOPHD3rHxpUpScdWg5cQTpJKd3jTroav6 nwwekTQ3aFHY00j4Fp0Lqe0prHJ9VIfuQEm6UlwLNA+DfYjK4GSam+hrRONQRTs+MX9g bSLS/I9jg5VBfJxGLQE70RFme2cZ78ANB1RS/6DralNnfVwLBklgHSnnDub0P/GU11dG 4ISUuuaPRIKnXn7Ek61JOxmzJkSQpQppRgwQepIpIA/wbMCJJt3MweNvUu7UFrWcybCI ZI7X8x+lFVuj1V2oW8t/7UqvPdFrPGWT3gZuYMf38giYtoUSM/+zRCDe5JPGHxCKZ4NG stQQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:in-reply-to:message-id :date:subject:cc:to:from:dkim-signature; bh=5KY/xrmgVe9M9piWNEesg+Wel2jzrZvgcmpWuxY4yJs=; fh=xvxAYWimIR6dlltQ8hAfOQziL8KT2j7uOJ/uaeH25a8=; b=aN/TR/A4JEapRysqP5OocSwnZX+iBYWqYPsDrUZ3AsMgdo3oYfFZ7px2U3Aati6UpB BWGcQhadx0qGHnd6jkep6zJmiJC8xuZtFW1R/tlH8czGcCSMpqrrXn/ufg1yYEhu7tgJ 4N5wMLfRSpaXg0kxBpaboQgXwoIgLDs9CAAwVm4WSTnacek9Xvrw9Q+W+BZTe0lpbR9n FN0tniYSxD3SMPxUWRBQvgX9+zv9A4N15FTDTQubQTGCveqw6hyN9aSR//aTCxstPKlc mWQ2f46YHMUgRg2aKoqtOQzKKrPcpZRFfRhiwMJvhTiio7Yek6lm7lgPcnBLkAm52u8M jrJA==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=rZdHf55W; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-124903-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) smtp.mailfrom="linux-kernel+bounces-124903-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from am.mirrors.kernel.org (am.mirrors.kernel.org. [2604:1380:4601:e00::3]) by mx.google.com with ESMTPS id m2-20020a50c182000000b00568386368c5si1855403edf.690.2024.03.29.07.43.06 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Mar 2024 07:43:06 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-124903-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) client-ip=2604:1380:4601:e00::3; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=rZdHf55W; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-124903-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) smtp.mailfrom="linux-kernel+bounces-124903-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by am.mirrors.kernel.org (Postfix) with ESMTPS id 295A61F294D3 for ; Fri, 29 Mar 2024 14:22:39 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 1FF1D14BF8C; Fri, 29 Mar 2024 12:46:42 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="rZdHf55W" Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 36B0514A4D8; Fri, 29 Mar 2024 12:46:41 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1711716401; cv=none; b=EgOrJyOimcaJBDO0iaxVV/9d4ySQoLPqLTMw584ylr6zrPiBuTRPeCZ3OOntz32Z1CvMq2G+GkcZt9KSfufHCx8e7Ym83Je3GSmrRSDj8TAUCHMdej5L25Y3UwpIG3KX1VOoOU8UNSDRl2fwTyf+GShJUVs1f2DHPmr5jyR6vU8= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1711716401; c=relaxed/simple; bh=4U6ZUJRzFHn3X3gF90GTg7DgT5B9uVGN6YR3Wbkuxdw=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=LuD/BpzXoPsr/ZBHTPqvMFrsO5SE6lpe4GbC+oxmGi1GYRavh9mEYCLBqDa0YksYXxT27a2R3VsnDyfMcwxZMoPzO8yuoDx1SUEGtCqI3j6qE874tCDI1RZnN4tosJvQpXBlHVwVoAyz/cLzvHqWVUFGctI3f+ZlDqSIjrE/f4I= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=rZdHf55W; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id 18FE8C433F1; Fri, 29 Mar 2024 12:46:40 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1711716401; bh=4U6ZUJRzFHn3X3gF90GTg7DgT5B9uVGN6YR3Wbkuxdw=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=rZdHf55WUeSF/WpbHEDd1cClty3zx7A0fgBlM/Qqm1rzp/nf75BEuOpKvkT2p6Yq/ 8Ds7gVmwU9nxAipJf3npu/rkewX/iydUDlCad0IeG6FU+jRQKo7h5TZapZFLqHpyxc LCKH5VQiz3Ok9uw9M8o/tk3so+DIKSUwtZyoerbz7vE/x+X3LcHMOGR8YH8K+fr9Ct 7tEQ9Gs0Aep7hhLAdGx/tooIzP2h9dw7jh3r5kS+GcOAkCgTdkt2zXYsPBeNDI9RNi 8bqFY6M7+l2tc3FbxKrjFkNkNAmFmMt1Fr6EJ+ZRYtDGpiEWoJxuWozUaVToxGcDH2 Z12/ngQwh7p3g== From: Sasha Levin To: linux-kernel@vger.kernel.org, stable@vger.kernel.org Cc: Arnd Bergmann , Hans Verkuil , Sasha Levin , mchehab@kernel.org, nathan@kernel.org, linux-media@vger.kernel.org, llvm@lists.linux.dev Subject: [PATCH AUTOSEL 6.1 19/52] media: sta2x11: fix irq handler cast Date: Fri, 29 Mar 2024 08:45:13 -0400 Message-ID: <20240329124605.3091273-19-sashal@kernel.org> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240329124605.3091273-1-sashal@kernel.org> References: <20240329124605.3091273-1-sashal@kernel.org> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-stable: review X-Patchwork-Hint: Ignore X-stable-base: Linux 6.1.83 Content-Transfer-Encoding: 8bit From: Arnd Bergmann [ Upstream commit 3de49ae81c3a0f83a554ecbce4c08e019f30168e ] clang-16 warns about casting incompatible function pointers: drivers/media/pci/sta2x11/sta2x11_vip.c:1057:6: error: cast from 'irqreturn_t (*)(int, struct sta2x11_vip *)' (aka 'enum irqreturn (*)(int, struct sta2x11_vip *)') to 'irq_handler_t' (aka 'enum irqreturn (*)(int, void *)') converts to incompatible function type [-Werror,-Wcast-function-type-strict] Change the prototype of the irq handler to the regular version with a local variable to adjust the argument type. Signed-off-by: Arnd Bergmann Signed-off-by: Hans Verkuil [hverkuil: update argument documentation] Signed-off-by: Sasha Levin --- drivers/media/pci/sta2x11/sta2x11_vip.c | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/drivers/media/pci/sta2x11/sta2x11_vip.c b/drivers/media/pci/sta2x11/sta2x11_vip.c index 8535e49a4c4f9..1f7ab56de4a00 100644 --- a/drivers/media/pci/sta2x11/sta2x11_vip.c +++ b/drivers/media/pci/sta2x11/sta2x11_vip.c @@ -756,7 +756,7 @@ static const struct video_device video_dev_template = { /** * vip_irq - interrupt routine * @irq: Number of interrupt ( not used, correct number is assumed ) - * @vip: local data structure containing all information + * @data: local data structure containing all information * * check for both frame interrupts set ( top and bottom ). * check FIFO overflow, but limit number of log messages after open. @@ -766,8 +766,9 @@ static const struct video_device video_dev_template = { * * IRQ_HANDLED, interrupt done. */ -static irqreturn_t vip_irq(int irq, struct sta2x11_vip *vip) +static irqreturn_t vip_irq(int irq, void *data) { + struct sta2x11_vip *vip = data; unsigned int status; status = reg_read(vip, DVP_ITS); @@ -1049,9 +1050,7 @@ static int sta2x11_vip_init_one(struct pci_dev *pdev, spin_lock_init(&vip->slock); - ret = request_irq(pdev->irq, - (irq_handler_t) vip_irq, - IRQF_SHARED, KBUILD_MODNAME, vip); + ret = request_irq(pdev->irq, vip_irq, IRQF_SHARED, KBUILD_MODNAME, vip); if (ret) { dev_err(&pdev->dev, "request_irq failed\n"); ret = -ENODEV; -- 2.43.0