From patchwork Fri Jul 2 12:23:48 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Matthias Schiffer X-Patchwork-Id: 469660 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=-16.8 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID, HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_CR_TRAILER, INCLUDES_PATCH, MAILING_LIST_MULTI, SPF_HELO_NONE, SPF_PASS, URIBL_BLOCKED, USER_AGENT_GIT 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 2453DC11F69 for ; Fri, 2 Jul 2021 12:24:09 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id EF6C561427 for ; Fri, 2 Jul 2021 12:24:08 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232192AbhGBM0k (ORCPT ); Fri, 2 Jul 2021 08:26:40 -0400 Received: from mx1.tq-group.com ([93.104.207.81]:42419 "EHLO mx1.tq-group.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232156AbhGBM0i (ORCPT ); Fri, 2 Jul 2021 08:26:38 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=tq-group.com; i=@tq-group.com; q=dns/txt; s=key1; t=1625228647; x=1656764647; h=from:to:cc:subject:date:message-id; bh=x/cAfVv59ovK81IneX1hABOtGlTE/zThFenfoMr94bo=; b=CH7Fm6/5VJzR+9jxvp1+seSv3ZQvVWLbXMnXyAQpvc4V6C+XdfBdgzOS ClPTi9gmJbovrqzVEE+RDduBk5BOndWAXD+3lYKimh2otGm77ChzFmiov R0DDXY2xMDRHC1ciL8CChxUWeKoNGM97LXcl/7XeHVz12BNZlK/frzhL/ vDMNovR7ciRkTQ61/v2FcnThuxPP5+e0eujkXuVhP3Y6V2CgUROZD04Jb znhpxay3g5HZDmkZQipBH7IFdkelk+ofC6MQ7fEfPyI+G4L35Ld75DW2I MryujKVRALzd+zNkPNlGVwH7KtZwm4Q5cwj54tfHtTgM+PJNti8F1zdWl A==; X-IronPort-AV: E=Sophos;i="5.83,317,1616454000"; d="scan'208";a="18252570" Received: from unknown (HELO tq-pgp-pr1.tq-net.de) ([192.168.6.15]) by mx1-pgp.tq-group.com with ESMTP; 02 Jul 2021 14:24:04 +0200 Received: from mx1.tq-group.com ([192.168.6.7]) by tq-pgp-pr1.tq-net.de (PGP Universal service); Fri, 02 Jul 2021 14:24:04 +0200 X-PGP-Universal: processed; by tq-pgp-pr1.tq-net.de on Fri, 02 Jul 2021 14:24:04 +0200 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=tq-group.com; i=@tq-group.com; q=dns/txt; s=key1; t=1625228644; x=1656764644; h=from:to:cc:subject:date:message-id; bh=x/cAfVv59ovK81IneX1hABOtGlTE/zThFenfoMr94bo=; b=DIqeqhKiUQVrkuzvr+NFfAGf5daKySTR/8fvj49LbIUbOQht33UL7QOP lAep2cB+PejWF55MsR50WivARXx+xs8EYLN/+lQmrroodlodFMG53FBfR W1xM070qsZhAoZgydBUGL2CTIaTb5+uaHz9ake29hwEgSCefDSFoi4JLp DF1m847LYU3uk1he5E3SBDmwxzJEWwNsaozeSDOddJt40bLsPP63vm6r6 ph5wLZQXhjQ28h7z/Rj1eZlqVStAyBGcFjs1FpTok3onSbeSPrn1pZVOO 0GSHCWCqQRA3//2IoCWf8/qZ3NqzuJgebefD88b036seZGIOr4fBdF0/K A==; X-IronPort-AV: E=Sophos;i="5.83,317,1616454000"; d="scan'208";a="18252569" Received: from vtuxmail01.tq-net.de ([10.115.0.20]) by mx1.tq-group.com with ESMTP; 02 Jul 2021 14:24:04 +0200 Received: from schifferm-ubuntu4.tq-net.de (schifferm-ubuntu4.tq-net.de [10.121.48.12]) by vtuxmail01.tq-net.de (Postfix) with ESMTPA id A3490280078; Fri, 2 Jul 2021 14:24:04 +0200 (CEST) From: Matthias Schiffer To: Linus Walleij , Bartosz Golaszewski , Lee Jones Cc: Andrew Lunn , Andy Shevchenko , linux-gpio@vger.kernel.org, linux-kernel@vger.kernel.org, Matthias Schiffer Subject: [PATCH v2 2/7] mfd: tqmx86: clear GPIO IRQ resource when no IRQ is set Date: Fri, 2 Jul 2021 14:23:48 +0200 Message-Id: <25ee92527847b2fa15e2c82ca486a92b4fd1d44e.1625227382.git.matthias.schiffer@ew.tq-group.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: References: In-Reply-To: References: Precedence: bulk List-ID: X-Mailing-List: linux-gpio@vger.kernel.org The driver was registering IRQ 0 when no IRQ was set. This leads to warnings with newer kernels. Clear the resource flags, so no resource is registered at all in this case. Fixes: 2f17dd34ffed ("mfd: tqmx86: IO controller with I2C, Wachdog and GPIO") Signed-off-by: Matthias Schiffer --- v2: add Fixes line Andy recommended to use IORESOURCE_DISABLED instead, but this doesn't have any effect for platform_get_irq(), so I'm resubmitting this patch without functional changes. Grepping for '\.flags = 0;' shows other drivers doing the same. drivers/mfd/tqmx86.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/mfd/tqmx86.c b/drivers/mfd/tqmx86.c index ddddf08b6a4c..732013f40e4e 100644 --- a/drivers/mfd/tqmx86.c +++ b/drivers/mfd/tqmx86.c @@ -209,6 +209,8 @@ static int tqmx86_probe(struct platform_device *pdev) /* Assumes the IRQ resource is first. */ tqmx_gpio_resources[0].start = gpio_irq; + } else { + tqmx_gpio_resources[0].flags = 0; } ocores_platfom_data.clock_khz = tqmx86_board_id_to_clk_rate(board_id); From patchwork Fri Jul 2 12:23:49 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Matthias Schiffer X-Patchwork-Id: 469659 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=-16.8 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID, HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_CR_TRAILER, INCLUDES_PATCH, MAILING_LIST_MULTI, SPF_HELO_NONE, SPF_PASS, URIBL_BLOCKED, USER_AGENT_GIT 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 52093C11F69 for ; Fri, 2 Jul 2021 12:24:12 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 3E49A613B6 for ; Fri, 2 Jul 2021 12:24:12 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232215AbhGBM0l (ORCPT ); Fri, 2 Jul 2021 08:26:41 -0400 Received: from mx1.tq-group.com ([93.104.207.81]:42421 "EHLO mx1.tq-group.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232144AbhGBM0k (ORCPT ); Fri, 2 Jul 2021 08:26:40 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=tq-group.com; i=@tq-group.com; q=dns/txt; s=key1; t=1625228648; x=1656764648; h=from:to:cc:subject:date:message-id; bh=Q/64wyLAKZYuggBcQQiGTIRE0uQ5M5Ts91Z7qH6yqhc=; b=kK66NjxfmUcMdcKdzXkmVkrYC5y8lVRKTolf91BCyhzpBu+dk/j461ZJ VtyT5VIP7FAHS/6RKSRHJWIP8ZG4JnGijuNi/rwyqvvvkhTkyERZ+e+g2 xXkq8Il8acLB7nPvlVnoZG53Cbk877jx47WrnYwCPxE+BQYNWCOvx/ddy ZGDYr40oFUI8z9WOKlCtelTW1KneWlmc9T4w3sjvTCOAygcFsKmqUvllf XYoCGl/P4KjTcHbIzhO65RqKlKi20KWB4Gg9s7IiE+Zcg2JCIG9vlurmh RJ13HxdSjdxnSYvTTJzR2NOgk7jUoNnSp63NZgpSbhuHduW77d3O4j9/W w==; X-IronPort-AV: E=Sophos;i="5.83,317,1616454000"; d="scan'208";a="18252572" Received: from unknown (HELO tq-pgp-pr1.tq-net.de) ([192.168.6.15]) by mx1-pgp.tq-group.com with ESMTP; 02 Jul 2021 14:24:05 +0200 Received: from mx1.tq-group.com ([192.168.6.7]) by tq-pgp-pr1.tq-net.de (PGP Universal service); Fri, 02 Jul 2021 14:24:05 +0200 X-PGP-Universal: processed; by tq-pgp-pr1.tq-net.de on Fri, 02 Jul 2021 14:24:05 +0200 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=tq-group.com; i=@tq-group.com; q=dns/txt; s=key1; t=1625228645; x=1656764645; h=from:to:cc:subject:date:message-id; bh=Q/64wyLAKZYuggBcQQiGTIRE0uQ5M5Ts91Z7qH6yqhc=; b=VR0APtByvJisolLRAXi2Qg+61xjHowBb1TBT3TTPmNCoYjgJH77HDBPZ 2nQVxwBSvgNPsjf8yKK51AWy3SsHygQXsk5GlpK8QvTxSH3yEPIExWQ+Y 07fljPeFARyCH232LIMXW/KfZzu34kmjS/vqOzbZhTK7wZUcJWahT4hRT qpUbfaN7ZcgXkDycJOz29cIPke9fQOk+53irqP6EszTUsL50Lbg7UFb3N ugTLs3afaTnK0vmTpBjPGxjHIlsmNARwWoelQ2W8+knVhtU7F+jwyiqcx JzV6WdL52BSkFkj0Lai1Ep6LJgSK5783pIGamTdEMqPR8Wu7Z4sDAQaDF A==; X-IronPort-AV: E=Sophos;i="5.83,317,1616454000"; d="scan'208";a="18252571" Received: from vtuxmail01.tq-net.de ([10.115.0.20]) by mx1.tq-group.com with ESMTP; 02 Jul 2021 14:24:05 +0200 Received: from schifferm-ubuntu4.tq-net.de (schifferm-ubuntu4.tq-net.de [10.121.48.12]) by vtuxmail01.tq-net.de (Postfix) with ESMTPA id D340F280070; Fri, 2 Jul 2021 14:24:04 +0200 (CEST) From: Matthias Schiffer To: Linus Walleij , Bartosz Golaszewski , Lee Jones Cc: Andrew Lunn , Andy Shevchenko , linux-gpio@vger.kernel.org, linux-kernel@vger.kernel.org, Matthias Schiffer Subject: [PATCH v2 3/7] mfd: tqmx86: remove incorrect TQMx90UC board ID Date: Fri, 2 Jul 2021 14:23:49 +0200 Message-Id: <36046861067369c0569f3d955f7a390c136689b5.1625227382.git.matthias.schiffer@ew.tq-group.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: References: In-Reply-To: References: Precedence: bulk List-ID: X-Mailing-List: linux-gpio@vger.kernel.org No TQMx90UC exists at the moment, and it is undecided whether ID 10 will be used eventually (and if it is, how that SoM will be named). Fixes: 2f17dd34ffed ("mfd: tqmx86: IO controller with I2C, Wachdog and GPIO") Signed-off-by: Matthias Schiffer Reviewed-by: Andrew Lunn --- v2: new patch drivers/mfd/tqmx86.c | 4 ---- 1 file changed, 4 deletions(-) diff --git a/drivers/mfd/tqmx86.c b/drivers/mfd/tqmx86.c index 732013f40e4e..9b65dbedc1bb 100644 --- a/drivers/mfd/tqmx86.c +++ b/drivers/mfd/tqmx86.c @@ -35,7 +35,6 @@ #define TQMX86_REG_BOARD_ID_E39x 7 #define TQMX86_REG_BOARD_ID_70EB 8 #define TQMX86_REG_BOARD_ID_80UC 9 -#define TQMX86_REG_BOARD_ID_90UC 10 #define TQMX86_REG_BOARD_REV 0x21 #define TQMX86_REG_IO_EXT_INT 0x26 #define TQMX86_REG_IO_EXT_INT_NONE 0 @@ -128,8 +127,6 @@ static const char *tqmx86_board_id_to_name(u8 board_id) return "TQMx70EB"; case TQMX86_REG_BOARD_ID_80UC: return "TQMx80UC"; - case TQMX86_REG_BOARD_ID_90UC: - return "TQMx90UC"; default: return "Unknown"; } @@ -142,7 +139,6 @@ static int tqmx86_board_id_to_clk_rate(u8 board_id) case TQMX86_REG_BOARD_ID_60EB: case TQMX86_REG_BOARD_ID_70EB: case TQMX86_REG_BOARD_ID_80UC: - case TQMX86_REG_BOARD_ID_90UC: return 24000; case TQMX86_REG_BOARD_ID_E39M: case TQMX86_REG_BOARD_ID_E39C: From patchwork Fri Jul 2 12:23:52 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Matthias Schiffer X-Patchwork-Id: 469658 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=-16.8 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID, HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_CR_TRAILER, INCLUDES_PATCH, MAILING_LIST_MULTI, SPF_HELO_NONE, SPF_PASS, URIBL_BLOCKED, USER_AGENT_GIT 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 05C53C11F6C for ; Fri, 2 Jul 2021 12:24:14 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id E09016143D for ; Fri, 2 Jul 2021 12:24:13 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232100AbhGBM0o (ORCPT ); Fri, 2 Jul 2021 08:26:44 -0400 Received: from mx1.tq-group.com ([93.104.207.81]:42421 "EHLO mx1.tq-group.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232203AbhGBM0l (ORCPT ); Fri, 2 Jul 2021 08:26:41 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=tq-group.com; i=@tq-group.com; q=dns/txt; s=key1; t=1625228649; x=1656764649; h=from:to:cc:subject:date:message-id; bh=BpioOeLEu+qJSb8YvKVoIV3l4TxE6atJJi2U9xpCr4k=; b=Bug4UWkjg8algbavwd6O/gqfLXf/pHxpxJwXrmVGUmBO7hxSSEyQ5TvD cJTKitPT9UnU0o/ok1oTZS8VDm6P4akTinIXIw8XySvOX1kzd6RbAN2cX ICWk/Z2qgYbZAJJeGHV7/Qh3Nkp5DWLv7AxtkvshrUBC/84SWE+4jsfP/ vTTJgI0JDSkkx5utbhvf8j43XvLlnrGv9tmOlvR1zg4WiH7Y6NttsVuOF +4dIETML9dS7exa1DzyaOHZMUlqskxhAtG4cZXcHEyaEsptK521Fyov5a idpmw6OJCa2De0H4SbE1qfQQ0Y0LcO3OJA5v0NqUYhldFjFpIhBYzOSnX g==; X-IronPort-AV: E=Sophos;i="5.83,317,1616454000"; d="scan'208";a="18252578" Received: from unknown (HELO tq-pgp-pr1.tq-net.de) ([192.168.6.15]) by mx1-pgp.tq-group.com with ESMTP; 02 Jul 2021 14:24:05 +0200 Received: from mx1.tq-group.com ([192.168.6.7]) by tq-pgp-pr1.tq-net.de (PGP Universal service); Fri, 02 Jul 2021 14:24:05 +0200 X-PGP-Universal: processed; by tq-pgp-pr1.tq-net.de on Fri, 02 Jul 2021 14:24:05 +0200 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=tq-group.com; i=@tq-group.com; q=dns/txt; s=key1; t=1625228645; x=1656764645; h=from:to:cc:subject:date:message-id; bh=BpioOeLEu+qJSb8YvKVoIV3l4TxE6atJJi2U9xpCr4k=; b=c38PSFplvcL1/fv8MKvz2AgPtaeeuWs0nsFIAAFPLb9xLPTCl1qUHUIy 5I57iV+zXUf0AIx4hfYG1Q1mT/oyg+reZTSDKmBF0iyni5wadDtl5mKQ7 L+ey+PohCoGyDj80K4x9H1Sm5R7yJI+s9bJZuC3X7Qi2qyvqVwGswoCwz DD5/jAwW6oV73/sO0WjW1GRkpIDvqZF6hAMx/1B87ojLfMIRpsd4Dz1YY cgRL6cIFov3rhjFsa+jtrPkIGnsoVHeFJoWVAvhtYwqxXt0tJU3ytXWGS QI+KVtENgz4ocVA/SMEoQ+UGL+ffoCEntkiHqiFW2Lhd55FawJA+yx8N1 g==; X-IronPort-AV: E=Sophos;i="5.83,317,1616454000"; d="scan'208";a="18252577" Received: from vtuxmail01.tq-net.de ([10.115.0.20]) by mx1.tq-group.com with ESMTP; 02 Jul 2021 14:24:05 +0200 Received: from schifferm-ubuntu4.tq-net.de (schifferm-ubuntu4.tq-net.de [10.121.48.12]) by vtuxmail01.tq-net.de (Postfix) with ESMTPA id 509FA280070; Fri, 2 Jul 2021 14:24:05 +0200 (CEST) From: Matthias Schiffer To: Linus Walleij , Bartosz Golaszewski , Lee Jones Cc: Andrew Lunn , Andy Shevchenko , linux-gpio@vger.kernel.org, linux-kernel@vger.kernel.org, Matthias Schiffer Subject: [PATCH v2 6/7] mfd: tqmx86: add support for TQ-Systems DMI IDs Date: Fri, 2 Jul 2021 14:23:52 +0200 Message-Id: <11bef2179e4745a4edcf579ff96185cb6987931d.1625227382.git.matthias.schiffer@ew.tq-group.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: References: In-Reply-To: References: Precedence: bulk List-ID: X-Mailing-List: linux-gpio@vger.kernel.org Newer TQMx86 modules use TQ-Systems instead of TQ-Group as their vendor ID. Signed-off-by: Matthias Schiffer --- v2: new patch drivers/mfd/tqmx86.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/drivers/mfd/tqmx86.c b/drivers/mfd/tqmx86.c index 9eb05b3ef573..58f35c8b5a45 100644 --- a/drivers/mfd/tqmx86.c +++ b/drivers/mfd/tqmx86.c @@ -271,6 +271,14 @@ static const struct dmi_system_id tqmx86_dmi_table[] __initconst = { }, .callback = tqmx86_create_platform_device, }, + { + .ident = "TQMX86", + .matches = { + DMI_MATCH(DMI_SYS_VENDOR, "TQ-Systems"), + DMI_MATCH(DMI_PRODUCT_NAME, "TQMx"), + }, + .callback = tqmx86_create_platform_device, + }, {} }; MODULE_DEVICE_TABLE(dmi, tqmx86_dmi_table);