From patchwork Thu Jul 21 08:04:19 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Nuno Sa X-Patchwork-Id: 592641 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id DDF94CCA48C for ; Thu, 21 Jul 2022 08:03:53 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231812AbiGUIDx (ORCPT ); Thu, 21 Jul 2022 04:03:53 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:38190 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231473AbiGUIDt (ORCPT ); Thu, 21 Jul 2022 04:03:49 -0400 Received: from mx0a-00128a01.pphosted.com (mx0a-00128a01.pphosted.com [148.163.135.77]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 1DDDC4AD6F; Thu, 21 Jul 2022 01:03:49 -0700 (PDT) Received: from pps.filterd (m0167089.ppops.net [127.0.0.1]) by mx0a-00128a01.pphosted.com (8.17.1.5/8.17.1.5) with ESMTP id 26L5WAnL024853; Thu, 21 Jul 2022 04:03:40 -0400 Received: from nwd2mta4.analog.com ([137.71.173.58]) by mx0a-00128a01.pphosted.com (PPS) with ESMTPS id 3hbt860w5a-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Thu, 21 Jul 2022 04:03:39 -0400 Received: from ASHBMBX9.ad.analog.com (ASHBMBX9.ad.analog.com [10.64.17.10]) by nwd2mta4.analog.com (8.14.7/8.14.7) with ESMTP id 26L83c9i026241 (version=TLSv1/SSLv3 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=FAIL); Thu, 21 Jul 2022 04:03:38 -0400 Received: from ASHBMBX9.ad.analog.com (10.64.17.10) by ASHBMBX9.ad.analog.com (10.64.17.10) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.986.14; Thu, 21 Jul 2022 04:03:37 -0400 Received: from zeus.spd.analog.com (10.66.68.11) by ashbmbx9.ad.analog.com (10.64.17.10) with Microsoft SMTP Server id 15.2.986.14 via Frontend Transport; Thu, 21 Jul 2022 04:03:37 -0400 Received: from nsa.ad.analog.com ([10.44.3.68]) by zeus.spd.analog.com (8.15.1/8.15.1) with ESMTP id 26L83GIn028313; Thu, 21 Jul 2022 04:03:32 -0400 From: =?utf-8?q?Nuno_S=C3=A1?= To: , , CC: Linus Walleij , Krzysztof Kozlowski , Michael Hennerich , Bartosz Golaszewski , Andy Shevchenko , Rob Herring , Dmitry Torokhov Subject: [PATCH v3 06/10] input: keyboard: adp5588-keys: do not check for irq presence Date: Thu, 21 Jul 2022 10:04:19 +0200 Message-ID: <20220721080423.156151-7-nuno.sa@analog.com> X-Mailer: git-send-email 2.37.1 In-Reply-To: <20220721080423.156151-1-nuno.sa@analog.com> References: <20220721080423.156151-1-nuno.sa@analog.com> MIME-Version: 1.0 X-ADIRuleOP-NewSCL: Rule Triggered X-Proofpoint-ORIG-GUID: x3mKnyCCIvw1droKhGa4BKhk3WF8Yffu X-Proofpoint-GUID: x3mKnyCCIvw1droKhGa4BKhk3WF8Yffu X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.205,Aquarius:18.0.883,Hydra:6.0.517,FMLib:17.11.122.1 definitions=2022-07-20_12,2022-07-20_01,2022-06-22_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 mlxscore=0 malwarescore=0 adultscore=0 priorityscore=1501 bulkscore=0 suspectscore=0 phishscore=0 spamscore=0 mlxlogscore=970 impostorscore=0 clxscore=1015 lowpriorityscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2206140000 definitions=main-2207210031 Precedence: bulk List-ID: X-Mailing-List: linux-gpio@vger.kernel.org There's no need for an extra check for 'client-irq'. Just let it fail when calling 'request_irq()'. Signed-off-by: Nuno Sá Reviewed-by: Andy Shevchenko --- drivers/input/keyboard/adp5588-keys.c | 5 ----- 1 file changed, 5 deletions(-) diff --git a/drivers/input/keyboard/adp5588-keys.c b/drivers/input/keyboard/adp5588-keys.c index 982591f2070b..6499b4a94c73 100644 --- a/drivers/input/keyboard/adp5588-keys.c +++ b/drivers/input/keyboard/adp5588-keys.c @@ -722,11 +722,6 @@ static int adp5588_probe(struct i2c_client *client, return -EIO; } - if (!client->irq) { - dev_err(&client->dev, "no IRQ?\n"); - return -EINVAL; - } - kpad = devm_kzalloc(&client->dev, sizeof(*kpad), GFP_KERNEL); if (!kpad) return -ENOMEM;