From mboxrd@z Thu Jan 1 00:00:00 1970 From: majun258@huawei.com (majun (F)) Date: Mon, 7 Sep 2015 09:17:01 +0800 Subject: [PATCH v4 1/2] Add the driver of mbigen interrupt controller In-Reply-To: References: <55E50344.9090104@huawei.com> Message-ID: <55ECE58D.6050602@huawei.com> To: linux-arm-kernel@lists.infradead.org List-Id: linux-arm-kernel.lists.infradead.org Hi Alexey: ? 2015/9/4 8:56, Alexey Klimov ??: > Hi Ma Jun, > > On Tue, Sep 1, 2015 at 4:45 AM, majun (F) wrote: >> Hi Alexey: >> [...] >>>> + mgn_chip->base = base; >>>> + mgn_chip->node = node; >>>> + >>>> + domain = irq_domain_add_tree(node, &mbigen_domain_ops, mgn_chip); >>>> + mgn_chip->domain = domain; >>>> + >>>> + raw_spin_lock_init(&mgn_chip->lock); >>>> + INIT_LIST_HEAD(&mgn_chip->entry); >>>> + INIT_LIST_HEAD(&mgn_chip->mbigen_device_list); >>>> + >>>> + for_each_child_of_node(node, child) { >>>> + mbigen_device_init(mgn_chip, child); >>> >>> You don't check error from mbigen_device_init() >> I don't think we need to check errors here. >> mbigen_device_init() handle all errors. > > For my eyes, mbigen_device_init() is static and used only once here. > Here you don't check return value from it. If this is correct you can > convert mbigen_device_init() to return void unless you have future > plans to modify it. > > Or you have option to check return value here and add error path. Ok, This will be changed in next version. > > Please add me to cc to next version of patch set which I guess will be v5. > Got it. I will add you to cc list in next version. Thanks for you review ! Ma Jun From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753245AbbIGBWe (ORCPT ); Sun, 6 Sep 2015 21:22:34 -0400 Received: from szxga01-in.huawei.com ([58.251.152.64]:35300 "EHLO szxga01-in.huawei.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752886AbbIGBWb (ORCPT ); Sun, 6 Sep 2015 21:22:31 -0400 Subject: Re: [PATCH v4 1/2] Add the driver of mbigen interrupt controller To: Alexey Klimov References: <55E50344.9090104@huawei.com> CC: Catalin Marinas , Linux Kernel Mailing List , , Will Deacon , Mark Rutland , , , Thomas Gleixner , , , , , Kenneth Lee , , , , , Guodong Xu , Haojian Zhuang , Zhangfei Gao , "Usman Ahmad" From: "majun (F)" Message-ID: <55ECE58D.6050602@huawei.com> Date: Mon, 7 Sep 2015 09:17:01 +0800 User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:38.0) Gecko/20100101 Thunderbird/38.1.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 8bit X-Originating-IP: [10.177.235.245] X-CFilter-Loop: Reflected Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Alexey: 在 2015/9/4 8:56, Alexey Klimov 写道: > Hi Ma Jun, > > On Tue, Sep 1, 2015 at 4:45 AM, majun (F) wrote: >> Hi Alexey: >> [...] >>>> + mgn_chip->base = base; >>>> + mgn_chip->node = node; >>>> + >>>> + domain = irq_domain_add_tree(node, &mbigen_domain_ops, mgn_chip); >>>> + mgn_chip->domain = domain; >>>> + >>>> + raw_spin_lock_init(&mgn_chip->lock); >>>> + INIT_LIST_HEAD(&mgn_chip->entry); >>>> + INIT_LIST_HEAD(&mgn_chip->mbigen_device_list); >>>> + >>>> + for_each_child_of_node(node, child) { >>>> + mbigen_device_init(mgn_chip, child); >>> >>> You don't check error from mbigen_device_init() >> I don't think we need to check errors here. >> mbigen_device_init() handle all errors. > > For my eyes, mbigen_device_init() is static and used only once here. > Here you don't check return value from it. If this is correct you can > convert mbigen_device_init() to return void unless you have future > plans to modify it. > > Or you have option to check return value here and add error path. Ok, This will be changed in next version. > > Please add me to cc to next version of patch set which I guess will be v5. > Got it. I will add you to cc list in next version. Thanks for you review ! Ma Jun