Received: by 2002:a05:7412:b995:b0:f9:9502:5bb8 with SMTP id it21csp3128198rdb; Tue, 26 Dec 2023 18:01:32 -0800 (PST) X-Google-Smtp-Source: AGHT+IGJ/cPk8/GctZc5gPfBzsY175qlfZGlrMzwwEDh1I8GqH2i5O4UUBXnOXSOFByCANIxWP20 X-Received: by 2002:a17:903:2805:b0:1d3:c76e:e4e4 with SMTP id kp5-20020a170903280500b001d3c76ee4e4mr9291812plb.59.1703642492594; Tue, 26 Dec 2023 18:01:32 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703642492; cv=none; d=google.com; s=arc-20160816; b=P6d12gnZLh8yA1ZdzTW26o2DKW/Yfge1t+UvVoEemPEROICaFnroLp484BYguXdD7t jbf6yCfti4wCh7d25zr9qbRI/Byd7k/u2wLGsp/ooL+10XJJWvj2bqaTwFcwlysLLjbN vbeVrHKRs8QP280B0QKVj1HT0qIRTG+Ec/zaqEb3gArbmYeIRGJEAGXT3Lx39EmAR8ot sZkT6kD/Mbux4b4QfN7m0W26njiG1LnWM/t51sZ329hcnQyT34UZkAEbF1Oj1P/p1nnr YbgXzZDfploefhasOjXB2taJNHADJOmP2HggZOM0vkFSZT5YkHJ4EieAVrnDL0wP30zp dVkg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=organization:content-disposition:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:mail-followup-to:message-id :subject:cc:to:from:date; bh=Df3sJWBuMiNvV54K7NvpvzLIlMr3uhZY6T/Ex7Lege4=; fh=ibZ75v1glo5jxy5hd7wBSW4YHcxZ/QoK3LDNt4UCaY0=; b=gwtS4EJApnhhyp9oFCoYSh0ttpo3xLAhvXAuWa2NzTvEYdopbbnfaTS5ynwnVnsL4A cf8/DMAl6sXZyY8EdpDxnrrwcLz0wRuq+0eES/wcMIhL/tAvqDV64hCDKIpn1S+sFXE0 85heCz09NIveunzuxztF70Unou3SryWvbJp4I64rg5jlFBpAKVWzdCR9ofahNIp9WtCd UAX9kzWW0kuJl8/HUhBmC0tFEvo26W9wh/iWdSlQMP1xFCIOrPNyk1gIQTLrsnUgK5Mx dTomp7uucNZovxbEQHIfKYRwn93/NtNcBltel5trenOg3iy9hOROxb9hKBzkStPyfXUF lRUA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel+bounces-11769-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-11769-linux.lists.archive=gmail.com@vger.kernel.org" Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [139.178.88.99]) by mx.google.com with ESMTPS id e16-20020a17090301d000b001d4752f5423si1521532plh.495.2023.12.26.18.01.32 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 26 Dec 2023 18:01:32 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-11769-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) client-ip=139.178.88.99; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel+bounces-11769-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-11769-linux.lists.archive=gmail.com@vger.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 sv.mirrors.kernel.org (Postfix) with ESMTPS id 40D9A281456 for ; Wed, 27 Dec 2023 02:01:32 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id A99E120EE; Wed, 27 Dec 2023 02:01:26 +0000 (UTC) X-Original-To: linux-kernel@vger.kernel.org Received: from out28-81.mail.aliyun.com (out28-81.mail.aliyun.com [115.124.28.81]) (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 E0F1B1FC8 for ; Wed, 27 Dec 2023 02:01:21 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=sjterm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=sjterm.com X-Alimail-AntiSpam:AC=CONTINUE;BC=0.1100688|-1;CH=green;DM=|CONTINUE|false|;DS=CONTINUE|ham_system_inform|0.0502652-0.000180865-0.949554;FP=0|0|0|0|0|-1|-1|-1;HT=ay29a033018047206;MF=fuyao@sjterm.com;NM=1;PH=DS;RN=9;RT=9;SR=0;TI=SMTPD_---.VtpmuEK_1703642477; Received: from localhost(mailfrom:fuyao@sjterm.com fp:SMTPD_---.VtpmuEK_1703642477) by smtp.aliyun-inc.com; Wed, 27 Dec 2023 10:01:18 +0800 Date: Wed, 27 Dec 2023 10:01:17 +0800 From: Fuyao Kashizuku To: Lee Jones , Chen-Yu Tsai , Jernej Skrabec , Samuel Holland , linux-arm-kernel@lists.infradead.org, linux-sunxi@lists.linux.dev, linux-kernel@vger.kernel.org, Andre Przywara Cc: Jianzhang Mai Subject: [PATCH] mfd: sun4i-gpadc: adaptation interrupt number Message-ID: Mail-Followup-To: Lee Jones , Chen-Yu Tsai , Jernej Skrabec , Samuel Holland , linux-arm-kernel@lists.infradead.org, linux-sunxi@lists.linux.dev, linux-kernel@vger.kernel.org, Andre Przywara , Jianzhang Mai Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Organization: work_work_work The identifiers are used as IRQ resource numbers, where 0 is treated specially. This fixes sun4i-gpadc-iio probe failed when request irq. The backstack: WARNING: CPU: 3 PID: 1 at drivers/base/platform.c:451 __platform_get_irq_byname+0xb8/0xc4 0 is an invalid IRQ number Modules linked in: CPU: 3 PID: 1 Comm: swapper/0 Not tainted 6.7.0-rc6 #9 Hardware name: Allwinner sun8i Family unwind_backtrace show_stack dump_stack_lvl __warn warn_slowpath_fmt __platform_get_irq_byname platform_get_irq_byname sun4i_irq_init sun4i_gpadc_probe platform_probe really_probe __driver_probe_device driver_probe_device __driver_attach bus_for_each_dev bus_add_driver driver_register do_one_initcall do_initcall_level do_initcalls kernel_init_freeable kernel_init Log reports: sun4i-gpadc-iio sun6i-a31-gpadc-iio.0: error -EINVAL: IRQ FIFO_DATA_PENDING not found sun4i-gpadc-iio: probe of sun6i-a31-gpadc-iio.0 failed with error -22 Signed-off-by: Fuyao Kashizuku --- Changes in v2: - Fix the commit message. - Add the backstack. - Add the log reports. - Use the correct full name and email address. - Correct the subsystem to mfd. - Link to v1: https://lore.kernel.org/lkml/YwdhTlk+9h+9Mrwm@scg/ include/linux/mfd/sun4i-gpadc.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/include/linux/mfd/sun4i-gpadc.h b/include/linux/mfd/sun4i-gpadc.h index ea0ccf33a459..021f820f9d52 100644 --- a/include/linux/mfd/sun4i-gpadc.h +++ b/include/linux/mfd/sun4i-gpadc.h @@ -81,8 +81,8 @@ #define SUN4I_GPADC_TEMP_DATA 0x20 #define SUN4I_GPADC_DATA 0x24 -#define SUN4I_GPADC_IRQ_FIFO_DATA 0 -#define SUN4I_GPADC_IRQ_TEMP_DATA 1 +#define SUN4I_GPADC_IRQ_FIFO_DATA 1 +#define SUN4I_GPADC_IRQ_TEMP_DATA 2 /* 10s delay before suspending the IP */ #define SUN4I_GPADC_AUTOSUSPEND_DELAY 10000 -- 2.39.2