Received: by 2002:a6b:500f:0:0:0:0:0 with SMTP id e15csp1867694iob; Fri, 29 Apr 2022 15:00:56 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxC17DKoba6z8Rb5zDlbyExmaY5+CrDi2XqD5ZNRGtZ/FeJgExaLfXpH8xxscwLgyJ4/ytY X-Received: by 2002:a19:4341:0:b0:472:cb8:58b6 with SMTP id m1-20020a194341000000b004720cb858b6mr937750lfj.33.1651269656174; Fri, 29 Apr 2022 15:00:56 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1651269656; cv=none; d=google.com; s=arc-20160816; b=gJs6v75xMBp0KTcslcSJ9PLyF9XST9hu9vdW68m50GgEGX1nI0KGAsRI8o3l4erJpR JanqKFgTSl3TIMFVf5zrYOroQ/xZZNcNwKw0C/2R8qpR+8ZxlwwjyLU1bhcdqIUPhTLk b/JdNA5YICTRfXmeiPCrU2GPZWBKeAo61ea+4Ha/dwjcqvKZ5VeuhzGj6lSMclVZRyHG +Oak90LiMobEtb5lud0ZW8Wy0Qun29WSdgj/nGvqhwTx9udi7ZvDECOuqhjD4LHMk5n4 FIDvUq/aQmn/EqhuL8uVz+WteMVqp56UPV9AsAe2jYWET1UfKp5GChR+9vpAG/VzDN0/ 0xUA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to:from :references:cc:to:content-language:subject:user-agent:mime-version :date:message-id:dkim-signature; bh=cnVnPLkUb/9RB2RNgHsF1idbtO2poGHZos9rPqsiSh4=; b=D72ThUcIjRv+1WScMarNlqfLprJpI8B1hTl4R/vzxK1kpnN1YjDcQa0WMIYEKC2IRy 4AKyyxayvHDCIYP1+1e+NCvi3zPuSt662jHUNn8ykA3BYcCm130KsRzYM5PDWSq45TJs E5PxztYqI0VDMLHmoxvcW/MKqIKD+y6NO/dWcbafyWM55vIr1XL278xucIEp0MO3hxrh bmCRruxJo6oiH4cH41U1hKK3KAd+PnD4Xr3Ywe1WcVdkT75pVf6X64pCIMlbhwEC8WAw V3rKkuC6CDK3bXIYdQuZfL3dT0KrCKykBbT3jvkYd1/yBOAK+GeXT5AaseLURW8+ujRw E4Fg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@quicinc.com header.s=qcdkim header.b=uUyl90ht; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=quicinc.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id i6-20020a056512340600b0047205414ce6si3271918lfr.412.2022.04.29.15.00.25; Fri, 29 Apr 2022 15:00:56 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@quicinc.com header.s=qcdkim header.b=uUyl90ht; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=quicinc.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235045AbiD1LZO (ORCPT + 99 others); Thu, 28 Apr 2022 07:25:14 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:59000 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232908AbiD1LZM (ORCPT ); Thu, 28 Apr 2022 07:25:12 -0400 Received: from alexa-out-sd-02.qualcomm.com (alexa-out-sd-02.qualcomm.com [199.106.114.39]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 341565DA47; Thu, 28 Apr 2022 04:21:58 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=quicinc.com; i=@quicinc.com; q=dns/txt; s=qcdkim; t=1651144918; x=1682680918; h=message-id:date:mime-version:subject:to:cc:references: from:in-reply-to:content-transfer-encoding; bh=cnVnPLkUb/9RB2RNgHsF1idbtO2poGHZos9rPqsiSh4=; b=uUyl90htNIsh4rxHuNGsix5t3LHOmC7F+ZOCv07spZ7hZzF2pRTJFACq Mj5Ec5RMHyCUrL+hgAwKEsXd+zhqEqVv+dLvpIS8ujc5OAaPi/X9wuZcU WCN1m9K/2ZWauvAvGHr3CetyWJthicGP6y16xNS1VFj5jtudia92uJV9c 8=; Received: from unknown (HELO ironmsg05-sd.qualcomm.com) ([10.53.140.145]) by alexa-out-sd-02.qualcomm.com with ESMTP; 28 Apr 2022 04:21:57 -0700 X-QCInternal: smtphost Received: from nasanex01c.na.qualcomm.com ([10.47.97.222]) by ironmsg05-sd.qualcomm.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 28 Apr 2022 04:21:57 -0700 Received: from nalasex01a.na.qualcomm.com (10.47.209.196) by nasanex01c.na.qualcomm.com (10.47.97.222) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.986.22; Thu, 28 Apr 2022 04:21:57 -0700 Received: from [10.50.42.7] (10.80.80.8) by nalasex01a.na.qualcomm.com (10.47.209.196) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.986.22; Thu, 28 Apr 2022 04:21:53 -0700 Message-ID: <6688ffa2-ec14-9126-1296-6180bab3e1d6@quicinc.com> Date: Thu, 28 Apr 2022 16:51:49 +0530 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:91.0) Gecko/20100101 Thunderbird/91.6.1 Subject: Re: [PATCHv12 7/9] asm-generic/io: Add logging support for MMIO accessors Content-Language: en-US To: Greg KH CC: , , , , , , , , , References: <6673a2e73d3dd4c7aa01fee9b26cc4a52176ba7a.1651139070.git.quic_saipraka@quicinc.com> From: Sai Prakash Ranjan In-Reply-To: Content-Type: text/plain; charset="UTF-8"; format=flowed Content-Transfer-Encoding: 7bit X-Originating-IP: [10.80.80.8] X-ClientProxiedBy: nasanex01b.na.qualcomm.com (10.46.141.250) To nalasex01a.na.qualcomm.com (10.47.209.196) X-Spam-Status: No, score=-4.4 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,NICE_REPLY_A,RCVD_IN_DNSWL_MED, SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 4/28/2022 4:21 PM, Greg KH wrote: > On Thu, Apr 28, 2022 at 03:25:30PM +0530, Sai Prakash Ranjan wrote: >> Add logging support for MMIO high level accessors such as read{b,w,l,q} >> and their relaxed versions to aid in debugging unexpected crashes/hangs >> caused by the corresponding MMIO operation. >> >> Signed-off-by: Sai Prakash Ranjan >> --- >> include/asm-generic/io.h | 82 ++++++++++++++++++++++++++++++++++++++-- >> 1 file changed, 78 insertions(+), 4 deletions(-) >> >> diff --git a/include/asm-generic/io.h b/include/asm-generic/io.h >> index 7ce93aaf69f8..99090722cb4b 100644 >> --- a/include/asm-generic/io.h >> +++ b/include/asm-generic/io.h >> @@ -10,6 +10,7 @@ >> #include /* I/O is all done through memory accesses */ >> #include /* for memset() and memcpy() */ >> #include >> +#include >> >> #ifdef CONFIG_GENERIC_IOMAP >> #include >> @@ -61,6 +62,35 @@ >> #define __io_par(v) __io_ar(v) >> #endif >> >> +#if IS_ENABLED(CONFIG_TRACE_MMIO_ACCESS) && !(defined(__DISABLE_TRACE_MMIO__)) > Shouldn't you document __DISABLE_TRACE_MMIO__ somewhere? It's not even > in the changelog. Put a big comment above this for what is is for and > how to use it. Otherwise you will forget all about this in 6 months :) > > thanks, > > greg k-h Didn't you ask me to split the patch to the one actually adding the flag and the one using it. So I have added the description in that patch which adds the flag since we can't add description everywhere we use the flag right :) Thanks, Sai