Received: by 2002:ac0:a594:0:0:0:0:0 with SMTP id m20-v6csp808154imm; Mon, 21 May 2018 14:53:49 -0700 (PDT) X-Google-Smtp-Source: AB8JxZoWUBsHdN23zZ/f21YxSSwzKwuFmdYnYu/Nt+ouIAGFggCSRn2dLMffk61M8IRkMfowwE3c X-Received: by 2002:a17:902:5327:: with SMTP id b36-v6mr22538993pli.316.1526939628932; Mon, 21 May 2018 14:53:48 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1526939628; cv=none; d=google.com; s=arc-20160816; b=gB+k0dbKv/w/F1B0WCrsvA30CMpScCT0F9dO7IWHRlkwkTLkFPFZUk4acnLj+Bmv/w D+tN6XUZ3bt0Ixe/JFxWWvuW4x02K+chG/M/N1Vvc8YNWf8LzfHnZmFnxpyVWqsOB8nd whOcKmgkdniAKAtaO5we7ZoUGtJoaZpZADtYPvSuUJBLgzMrhoS8JyMX0XiIi57zPeiP aEVntRNYHIdIm0WIgBOcC9Ndyu3H05CeHtRGt6PupTF9Wj3qQfvSodTB6Xix+pcnVNSq FPOcFcyh3Qq1WVwmHXqKIAua1sb2UwLAUJNQL/onP4eGP3RMM15vzyrYK5jHjHwcIYdH wlPQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :references:in-reply-to:mime-version:dkim-signature :arc-authentication-results; bh=Fu2a5IE35GueBCxFFofGTN8v/Cs/hlSgeWDdj8Unb/0=; b=Fjt+x4nfU8urM7MmZB8YztExjWfObV2wojKHXowcG4vmoCM42NUq+ChXHoOcoH58lO iuU0X/SxTipTYgCe3g+aQv+a/XeNbY3kB5d+0Nxw2/a8szXVgoj/X0dedAWpOv9tdq+N GF1DJz40L0sldsFWVcsQMJumf/wvStnIHiD2cBJP7vH1iXXSCyx8X1yDqynFaXJis+eB SqXR0/bi9qXtAqdErSak9yIGf+Eoc/N2M9mYqlfoxbiLQkvTnzdoMlP9jiNjRiuBCych Ch9cwf12fYHiicEMMk1W5S7F503Wjp3NZrd+8NLkfae29htN9w52KCCCBCZZTXQ/e/gc Bjtw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=Yf3G9KLi; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 1-v6si14691037plv.16.2018.05.21.14.53.34; Mon, 21 May 2018 14:53:48 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=Yf3G9KLi; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754364AbeEUVx0 (ORCPT + 99 others); Mon, 21 May 2018 17:53:26 -0400 Received: from mail-qt0-f196.google.com ([209.85.216.196]:43938 "EHLO mail-qt0-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751413AbeEUVxU (ORCPT ); Mon, 21 May 2018 17:53:20 -0400 Received: by mail-qt0-f196.google.com with SMTP id f13-v6so20890668qtp.10; Mon, 21 May 2018 14:53:20 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=Fu2a5IE35GueBCxFFofGTN8v/Cs/hlSgeWDdj8Unb/0=; b=Yf3G9KLi5OLHli0hoLCTQ0GzHBeExVsvBmOlX1CzQKgdDaJp6lyNnhIWCh7CswICvU dCo9RsXITyygbkFUEi7Of8orJk39fWRuDnLJ1Yko9iLi3ajk2sAFN/dcrgCptWcMJuKV BwhwXW4Ny8y2y7Znkby7XzJdgyp0GMtUlmGe2Bp9rBdRV00dFD9O1PASr1f6QGRjJ6gq +0M2EkiJ+5MKQNdZgEGhEWJYVxcya/3lQFtecCL4HLPfuourybig5UhgWd62GtHGvxoJ CCsLLdPBRyb9cwY9pHsyNbljtXAs8U6kPPK3urn5MliIBtYBRUVCYSWb6TTom1P46fym XCZA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=Fu2a5IE35GueBCxFFofGTN8v/Cs/hlSgeWDdj8Unb/0=; b=dLaf7a2QdyYfZ44aMxr964Xk/bwbXCtoxdP+dw9VfOLuT7XfNl7wT90nBjq7w+2eqb W6AD9vxTXQfOr6yOxtHy8+HDzA1D+U8EL/4+bp076fLBOcM2blAR/gvNN30GnQgvY4tJ 4hWiv+ODTifTMgo5m8ALlH1z1aNI/INgbH8aNCk9oFG/tq5b+hK93YuEZtyN4VHIv07n DLSmNkLOFZueLOvpxYzfI6VB5TfGeZJ3bFRow9dhmNrtfZyF2RS1GA7NvkGD+plJLQJi 9IndUSK0jJq0lLoDJtrNyHFXYukCBMjFosBsXYVbtK9BjIX/TXjo0T1xvju0LjDXqjfk MJ2w== X-Gm-Message-State: ALKqPwfjSKORyuo+tS2pm98StgqWnOc3xxpH+z1WkFl6LHJCykS24/Qs ayVKMqfmFZQAXUmtW7rOIW+S5F4tbfCUBe0q89CwLQ== X-Received: by 2002:ac8:3488:: with SMTP id w8-v6mr20967615qtb.278.1526939599975; Mon, 21 May 2018 14:53:19 -0700 (PDT) MIME-Version: 1.0 Received: by 10.12.152.150 with HTTP; Mon, 21 May 2018 14:53:19 -0700 (PDT) In-Reply-To: <1526903890-35761-15-git-send-email-xieyisheng1@huawei.com> References: <1526903890-35761-1-git-send-email-xieyisheng1@huawei.com> <1526903890-35761-15-git-send-email-xieyisheng1@huawei.com> From: Andy Shevchenko Date: Tue, 22 May 2018 00:53:19 +0300 Message-ID: Subject: Re: [PATCH 14/33] clk: use match_string() helper To: Yisheng Xie Cc: Linux Kernel Mailing List , Michael Turquette , Stephen Boyd , linux-clk@vger.kernel.org Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, May 21, 2018 at 2:57 PM, Yisheng Xie wrote: > match_string() returns the index of an array for a matching string, > which can be used intead of open coded variant. > + return match_string(core->parent_names, > + core->num_parents, parent_core->name) >= 0; More logical split is to leave second parameter on the first line. P.S. I would rather to put everything to one line even if takes ~83 characters. -- With Best Regards, Andy Shevchenko