Received: by 2002:a25:1985:0:0:0:0:0 with SMTP id 127csp248819ybz; Tue, 21 Apr 2020 08:19:28 -0700 (PDT) X-Google-Smtp-Source: APiQypLpSDPiAao99zV7m5bK7qM0JuW72ybuLaur/+rEPKYJ/QG5fVsEbVxdyr7ILmg51a9NqzC9 X-Received: by 2002:a05:6402:17f1:: with SMTP id t17mr7822059edy.239.1587482368044; Tue, 21 Apr 2020 08:19:28 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1587482368; cv=none; d=google.com; s=arc-20160816; b=r0oi8gNe2Waw6n++2wff/mr2xeSyXhIcGridD7nk8tBbFsEVfQjNyLr8H5ruOTe/AC bT0p5UIVrCwFvmLVp+BxJEXJgbQaA+/xMP04Hwk0wGNY8LpbynLOouCd73nn78QwJzPY 2kqkANGrmwreDyxrEai4gdpz1An/Td764JkZkm7K4BoFm/mkpHcX4xrElbTtIljHVMWh zwQlQiPGN9CHJd6hFQenme4YXe4PZk2LrfnXIX4jokNNfmMIRU7wjxZoHitpg5eLCcaO wV3ameUraSu2cFOAbuSNxLM5ND7eN69m7MRws1u3z8716UrtzhBReQTDR1nI7OXL27GS 1MOg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:content-transfer-encoding :content-language:accept-language:in-reply-to:references:message-id :date:thread-index:thread-topic:subject:cc:to:from; bh=DmTiOeXv1ToYZaA9Btb3Ebzp7w7iaaoDsrXISeN1OZw=; b=VMY+6iZZbNM5fYwqNKbfyT34+6C3eTCD1S1m0X4RnuthUI/pqH1I+1oy+Waofl6V+X 5W9LgZONuIJemIMoH+FZ+NF5TNwDFGdy82eEZmOpn1W1jY07DoUrS2KU6x7b9SvdM3HR ddqzxLykV63QE5J4yZazzP9tP8fL3Th68DuukVzMEodYZL5pmewwI7YgoYxF8uI/Munr hQnqVOo5mEfGpzDHeaTQL0iYEwIb9z3rCP6yBg13vIVdhFv1OmhDlHvl+J3NohGUz3yA 0YDIysuoIKkKB1Y29gZED7ThRqCcoi1JHElWMv18xDMNJGrr+V+WXuqtKceucljoUxgG qfsw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id c9si1709201edt.576.2020.04.21.08.19.03; Tue, 21 Apr 2020 08:19:28 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726160AbgDUPSH convert rfc822-to-8bit (ORCPT + 99 others); Tue, 21 Apr 2020 11:18:07 -0400 Received: from lhrrgout.huawei.com ([185.176.76.210]:2077 "EHLO huawei.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1725613AbgDUPSH (ORCPT ); Tue, 21 Apr 2020 11:18:07 -0400 Received: from lhreml721-chm.china.huawei.com (unknown [172.18.7.108]) by Forcepoint Email with ESMTP id BF833D248BFA70D8CFB2; Tue, 21 Apr 2020 16:18:05 +0100 (IST) Received: from lhreml715-chm.china.huawei.com (10.201.108.66) by lhreml721-chm.china.huawei.com (10.201.108.72) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.1913.5; Tue, 21 Apr 2020 16:18:05 +0100 Received: from lhreml715-chm.china.huawei.com ([10.201.108.66]) by lhreml715-chm.china.huawei.com ([10.201.108.66]) with mapi id 15.01.1913.007; Tue, 21 Apr 2020 16:18:04 +0100 From: Shiju Jose To: Dan Carpenter CC: "linux-acpi@vger.kernel.org" , "linux-pci@vger.kernel.org" , "linux-kernel@vger.kernel.org" , "rjw@rjwysocki.net" , "bp@alien8.de" , "james.morse@arm.com" , "helgaas@kernel.org" , "lenb@kernel.org" , "tony.luck@intel.com" , "gregkh@linuxfoundation.org" , "zhangliguang@linux.alibaba.com" , "tglx@linutronix.de" , Linuxarm , Jonathan Cameron , tanxiaofei , yangyicong Subject: RE: [RESEND PATCH v7 4/6] ACPI / APEI: Add callback for ARM HW errors to the GHES notifier Thread-Topic: [RESEND PATCH v7 4/6] ACPI / APEI: Add callback for ARM HW errors to the GHES notifier Thread-Index: AQHWF+AgGjWUb7UHikyyLKOn1rsB1aiDjc8AgAAhSyA= Date: Tue, 21 Apr 2020 15:18:04 +0000 Message-ID: <19755019addc4fc3bbac5238157dee2c@huawei.com> References: <20200421132136.1595-1-shiju.jose@huawei.com> <20200421132136.1595-5-shiju.jose@huawei.com> <20200421141426.GD2682@kadam> In-Reply-To: <20200421141426.GD2682@kadam> Accept-Language: en-GB, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [10.47.83.77] Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 8BIT MIME-Version: 1.0 X-CFilter-Loop: Reflected Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Dan, >-----Original Message----- >From: Dan Carpenter [mailto:dan.carpenter@oracle.com] >Sent: 21 April 2020 15:14 >To: Shiju Jose >Cc: linux-acpi@vger.kernel.org; linux-pci@vger.kernel.org; linux- >kernel@vger.kernel.org; rjw@rjwysocki.net; bp@alien8.de; >james.morse@arm.com; helgaas@kernel.org; lenb@kernel.org; >tony.luck@intel.com; gregkh@linuxfoundation.org; >zhangliguang@linux.alibaba.com; tglx@linutronix.de; Linuxarm >; Jonathan Cameron >; tanxiaofei ; >yangyicong >Subject: Re: [RESEND PATCH v7 4/6] ACPI / APEI: Add callback for ARM HW >errors to the GHES notifier > >On Tue, Apr 21, 2020 at 02:21:34PM +0100, Shiju Jose wrote: >> static BLOCKING_NOTIFIER_HEAD(ghes_event_notify_list); >> @@ -670,12 +692,7 @@ static void ghes_do_proc(struct ghes *ghes, >> pr_warn(GHES_PFX "ghes event queue full\n"); >> break; >> } >> - >> - if (guid_equal(sec_type, &CPER_SEC_PROC_ARM)) { >> - struct cper_sec_proc_arm *err = >acpi_hest_get_payload(gdata); >> - >> - log_arm_hw_error(err); >> - } else { >> + { >> void *err = acpi_hest_get_payload(gdata); > >This is ugly. Just move the "void *err;" declaration to the top of the function >so we can delete this block. Ok. I will change. > >> >> log_non_standard_event(sec_type, fru_id, fru_text, >> -- > >regards, >dan carpenter Thanks, Shiju