From mboxrd@z Thu Jan 1 00:00:00 1970 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=-5.2 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED, USER_AGENT_SANE_1 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 0CB7FC3A5A2 for ; Tue, 3 Sep 2019 12:52:15 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id DF33E21883 for ; Tue, 3 Sep 2019 12:52:14 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729250AbfICMwO (ORCPT ); Tue, 3 Sep 2019 08:52:14 -0400 Received: from 8bytes.org ([81.169.241.247]:52958 "EHLO theia.8bytes.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729119AbfICMwN (ORCPT ); Tue, 3 Sep 2019 08:52:13 -0400 Received: by theia.8bytes.org (Postfix, from userid 1000) id A4DE0284; Tue, 3 Sep 2019 14:52:11 +0200 (CEST) Date: Tue, 3 Sep 2019 14:52:10 +0200 From: Joerg Roedel To: Uwe =?iso-8859-1?Q?Kleine-K=F6nig?= Cc: Rob Herring , Frank Rowand , Will Deacon , Robin Murphy , Matthias Brugger , devicetree@vger.kernel.org, iommu@lists.linux-foundation.org, linux-kernel@vger.kernel.org, linux-mediatek@lists.infradead.org, linux-arm-kernel@lists.infradead.org, kernel@pengutronix.de Subject: Re: [PATCH v1 1/2] iommu: pass cell_count = -1 to of_for_each_phandle with cells_name Message-ID: <20190903125210.GB11530@8bytes.org> References: <20190824132846.8589-1-u.kleine-koenig@pengutronix.de> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <20190824132846.8589-1-u.kleine-koenig@pengutronix.de> User-Agent: Mutt/1.10.1 (2018-07-13) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sat, Aug 24, 2019 at 03:28:45PM +0200, Uwe Kleine-König wrote: > Currently of_for_each_phandle ignores the cell_count parameter when a > cells_name is given. I intend to change that and let the iterator fall > back to a non-negative cell_count if the cells_name property is missing > in the referenced node. > > To not change how existing of_for_each_phandle's users iterate, fix them > to pass cell_count = -1 when also cells_name is given which yields the > expected behaviour with and without my change. > > Signed-off-by: Uwe Kleine-König > --- > drivers/iommu/arm-smmu.c | 2 +- > drivers/iommu/mtk_iommu_v1.c | 2 +- > 2 files changed, 2 insertions(+), 2 deletions(-) Acked-by: Joerg Roedel